Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6850720

(process) Use clone(CLONE_VM), not fork, on Linux to avoid swap exhaustion

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 6
    • Fix Version/s: 7
    • Component/s: core-libs
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b62
    • CPU:
      unknown
    • OS:
      linux

      Description

      On Linux it is possible to use clone with CLONE_VM, but not CLONE_THREAD,
      which is like fork() but much cheaper and avoids swap exhaustion due to momentary
      overcommit of swap space. One has to be very careful in this case to not mutate global
      variables such as environ, but it's worth it.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              michaelm Michael McMahon
              Reporter:
              michaelm Michael McMahon
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: