5 Replies Latest reply on Jun 1, 2010 2:40 PM by dgilmore

    huge page support

    butette

      I just installed Open64 4.2.2.2.  The release note states that it has huge page (2MB) support.  Is that done automatically.  How do you invoke huge page support ?  is it through libhugetlbfs or ???

      Oops..  I see the -HUGEPAGE option in the compiler.  I guess I better read the documentation first.

      Thanks,

      Phuong Vu

        • huge page support
          dgilmore

          Yes the huge page support is via libhugetlbfs.  We made some minor changes to allow the limiting of the number of huges pages that each process can allocate so that a limited number of pages can be evenly allocated amoung processes running on an system with multiple cores/processors.  Also we made it more straighforward to use the compiler driver to link a program that will also allow the text, data and BSS sections to be mapped via huge pages.  See the documentation for the -HP option, which you can locate using the "Option Index" bookmark in:

          http://developer.amd.com/assets/x86_open64_user_guide.pdf

          There is also initial system configuration that should be done at boot time as root:

          test -d /mnt/hugetlb  || mkdir /mnt/hugetlb
          mount -t hugetlbfs none /mnt/hugetlb
          chmod 777 /mnt/hugetlb

          sysctl vm.nr_hugepages=<n>
          or
          echo <n> > /proc/sys/vm/nr_hugepages

          where <n> is the number of huge pages you wish to allocate.

          For more information on system configuration see:

          /usr/src/linux-.../Documentation/vm/hugetlbpage.txt

          Note that more flexible huge page support is available in the mainline Linux kernel which will soon be available in the vendor distributions. So with the the aid of some kernel boot parameter settings, it will be easier to a reserve a large number of huge pages after the system is booted.

          Doug

           

            • huge page support
              butette

              Thank you for the information, Doug.  That's what I was afraid of.  I do not like huge page as supported by libhugetlbfs at all unless something has changed recently.  The fact that you have to preallocate hugepage makes it a no go for me.  I don't know why there is no support for 64KB page like what is done in both SLES and RedHat on Power6 platform.  You can most of the benefit of large page w/o the penalty of huge page reservation.

              Phuong