Windows Task Manager javaw.exe vs. Java mission control

I help develop a java application using my Windows 7 machine, which has Java 8 Update 45. I notice a significant difference in how much memory the Windows task manager uses by the application (via javaw. Exe Image), as well as the Eclipse Memory Analyzer / Java report Mission Control.

Example: Java Mission Control reports 150 MB of Java Heap memory, while Windows says 303 MB of the working set used for javaw.exe. I understand that there are probably some overheads for the JVM, GC, etc.

But I also see that the GC does this. After a small click to increase memory, the JMC shows that the GC has been executed and says that 200 MB of the heap is being used. Windows reports 619 MB (it never went down). Is Windows displaying Java memory usage incorrectly? Something with the application caused this?

+4
source share
1 answer

When the JVM starts, it allocates contiguous memory for the heap. This memory can be turned into real memory lazily, but almost never returns to the operating system.

A heap is just one area of ​​memory used by the JVM. This may be the most important for you, but when your heap is really small, it can be small compared to other areas that the JVM uses. This includes

  • , . direct ByteBuffers.
  • GUI.
  • .
  • jar.
  • metaspace ( perm gen)
  • .

Windows Java?

Windows , , .

- , ?

Windows , .

+4

All Articles