Skip to content

JVM Linux Large Pages #13

Open
Open

Description

@zloster

Investigate how to enable and if the large memory pages help?

-XX:+UseHugeTLBFS

This option for Linux is the equivalent of specifying -XX:+UseLargePages. This option is disabled by default. This option pre-allocates all large pages up-front, when memory is reserved; consequently the JVM cannot dynamically grow or shrink large pages memory areas; see -XX:UseTransparentHugePages if you want this behavior.

For more information, see "Large Pages".

-XX:+UseLargePages

Enables the use of large page memory. By default, this option is disabled and large page memory is not used.

For more information, see "Large Pages".

Source: http://docs.oracle.com/javase/8/docs/technotes/tools/unix/java.html

Activity

  1. modified the milestone: on Apr 1, 2017
  2. zloster commented on Apr 5, 2017

    @zloster
    OwnerAuthor

    Nice short writing about this feature: https://shipilev.net/jvm-anatomy-park/2-transparent-huge-pages/

    Case in point, using 4 TB (terabyte, with a T) heap:

    $ time java -Xms4T -Xmx4T -XX:-UseTransparentHugePages -XX:+AlwaysPreTouch
    real    13m58.167s
    user    43m37.519s
    sys     1011m25.740s
    $ time java -Xms4T -Xmx4T -XX:+UseTransparentHugePages -XX:+AlwaysPreTouch
    real    2m14.758s
    user    1m56.488s
    sys     73m59.046s
    

    Committing and freeing 4 TB sure takes a while!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions