Profile Image
vishnupriya

What is Use large pages: -XX:+UseLargePages?

What is Use large pages: -XX:+UseLargePages? Have you used this JVM argument before? What are the pros & cons of using this Java argument? Can you share your perspective/experience in using this JVM argument?

  • jvm-argument

  • xx-uselargepages

  • x-uselargepages

  • Use large pages

Please Sign In or to post your comment or answer

Profile Image

Pavel Khodakovsky

Usage:

 

You can set the flag to use large pages like this:

 

-XX:+UseLargePages

 

Description:

 

Large pages is a technique to remove some work from the processors TLB caches. They are used to speed up the time to translate virtual to physical memory addresses. Most architectures support multiple page sizes, often with a base page size of 4 KB. For heavy-memory consuming applications it makes sense to have the memory mapped with a larger page granularity to increase the chance of a hit in the TLB. On x86-64, 2 MB and 1 GB pages can be used for this purpose and for memory intense workloads this can have a really big impact.

 

Default Value:

 

JVM is system-dependent, by default, the JVM will use the environments default large page size when trying to reserve large pages.

 

Errors:

 

None

 

Arguments related:

 

TODO link LargePageSizeInBytes

 

Related Posts:

NOTE:

If you have additional comments, interesting experiences or even point of disagreement with this JVM argument description, please leave a comment. Your insights will help the entire 10+ million java developer community to develop one standard source of documentation for all the JVM arguments.

Got something else on mind? Post Your Question

Not the answer you're looking for? Browse other questions tagged
  • jvm-argument

  • xx-uselargepages

  • x-uselargepages

  • Use large pages