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

Investigate adding NUMA container support to hotspot

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Won't Fix
    • P3
    • tbd
    • None
    • hotspot
    • gc
    • linux

    Description

      JDK-8146115 added support for determining if Java is running in docker containers. As part of this change, a function OSContainer::cpu_cpuset_memory_nodes was added to report how many memory nodes are available for use by the container.

      Most container images that we have worked with do not include libnuma.so causing the standard UseNUMA code to be non functional.

      It may be possible to take advantage of the OSContainer function to provide some limited NUMA support in os_linux.cpp.

      Igor Veresov suggests ...

      I think there is a way to do a poor mans NUMA-aware allocator. There is getcpu(2) that can return the numa node that a thread is currently running on. There is no libc wrapper, but the syscall is there since 2.6.19. So, that gives us an implementation of os::numa_get_group_id().

      Next, use OSContainer::cpu_cpuset_memory_nodes to implement os::numa_get_groups_num() when running in a container.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              bobv Bob Vandette (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: