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

NMT does not track the mapped shared spaces as 'committed'

    XMLWordPrintable

Details

    • Bug
    • Resolution: Won't Fix
    • P4
    • 10
    • 9
    • hotspot
    • generic
    • generic

    Description

      MemTracker::record_virtual_memory_reserve_and_commit() should record the memory as both ‘reserved’ and ‘committed’. However, that only happens if the memory region is not known by the VirtualMemoryTracker. If the memory overlaps with a known region in the VirtualMemoryTracker, MemTracker::record_virtual_memory_reserve_and_commit() could be a ‘nop' in certain case. The mapped CDS shared space is one example. Here are the call sequences related to the shared memory region:

      1. ReservedSpace::ReservedSpace - reserve the memory for shared region. VirtualMemorySummary::record_reserved_memory is called and the memory is recored as ‘reserved’.
      2.os::map_memory - each shared space within the shared memory region is mapped. MemTracker::record_virtual_memory_reserve_and_commit is called, the memory is not recounted. So the shared memory region is only counted as ‘reserved’ in NMT by previous VirtualMemorySummary::record_reserved_memory call.

      Attachments

        Issue Links

          Activity

            People

              mockner Max Ockner (Inactive)
              jiangli Jiangli Zhou
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: