Allocates memory on linux using libnuma
under the hood.
libnuma 2.0.x
must be installed on your Linux machine. It is recommended to install numactl
utility also.
RHEL
or Cent OS
$ sudo yum install numactl
Ubuntu
or Debian
$ sudo apt install numactl
JDK
, C++ 11
compatible compiler (gcc >= 4.8.5
) and libnuma
headers
RHEL
or Cent OS
$ sudo yum groupinstall 'Development Tools' $ sudo yum install java-11-openjdk numactl-devel libstdc++-static
Ubuntu
or Debian
$ sudo apt install build-essential libnuma-dev openjdk-11-jdk
void *numa_alloc(size_t)
under the hood:<property name="dataStorageConfiguration"> <bean class="org.apache.ignite.configuration.DataStorageConfiguration"> <property name="defaultDataRegionConfiguration"> <bean class="org.apache.ignite.configuration.DataRegionConfiguration"> <property name="name" value="Default_Region"/> .... <property name="memoryAllocator"> <bean class="org.apache.ignite.mem.NumaAllocator"> <constructor-arg> <bean class="org.apache.ignite.mem.SimpleNumaAllocationStrategy"/> </constructor-arg> </bean> </property> </bean> </property> </bean> </property>
void *numa_alloc_onnode(size_t, int)
under the hood:<property name="dataStorageConfiguration"> <bean class="org.apache.ignite.configuration.DataStorageConfiguration"> <property name="defaultDataRegionConfiguration"> <bean class="org.apache.ignite.configuration.DataRegionConfiguration"> <property name="name" value="Default_Region"/> .... <property name="memoryAllocator"> <bean class="org.apache.ignite.mem.NumaAllocator"> <constructor-arg> <bean class="org.apache.ignite.mem.SimpleNumaAllocationStrategy"> <constructor-arg name="node" value="0"/> </bean> </constructor-arg> </bean> </property> </bean> </property> </bean> </property>
void *numa_alloc_interleaved(size_t)
under the hood:<property name="dataStorageConfiguration"> <bean class="org.apache.ignite.configuration.DataStorageConfiguration"> <property name="defaultDataRegionConfiguration"> <bean class="org.apache.ignite.configuration.DataRegionConfiguration"> <property name="name" value="Default_Region"/> .... <property name="memoryAllocator"> <bean class="org.apache.ignite.mem.NumaAllocator"> <constructor-arg> <bean class="org.apache.ignite.mem.InterleavedNumaAllocationStrategy"/> </constructor-arg> </bean> </property> </bean> </property> </bean> </property>
void *numa_alloc_interleaved_subset(size_t, struct bitmask*)
under the hood:<property name="dataStorageConfiguration"> <bean class="org.apache.ignite.configuration.DataStorageConfiguration"> <property name="defaultDataRegionConfiguration"> <bean class="org.apache.ignite.configuration.DataRegionConfiguration"> <property name="name" value="Default_Region"/> .... <property name="memoryAllocator"> <bean class="org.apache.ignite.mem.NumaAllocator"> <constructor-arg> <bean class="org.apache.ignite.mem.InterleavedNumaAllocationStrategy"> <constructor-arg name="nodes"> <array> <value>0</value> <value>1</value> </array> </constructor-arg> </bean> </constructor-arg> </bean> </property> </bean> </property> </bean> </property>
Allocation on local for process NUMA node, uses void* numa_alloc_onnode(size_t)
under the hood.
<property name="dataStorageConfiguration"> <bean class="org.apache.ignite.configuration.DataStorageConfiguration"> <property name="defaultDataRegionConfiguration"> <bean class="org.apache.ignite.configuration.DataRegionConfiguration"> <property name="name" value="Default_Region"/> .... <property name="memoryAllocator"> <bean class="org.apache.ignite.mem.NumaAllocator"> <constructor-arg> <constructor-arg> <bean class="org.apache.ignite.mem.LocalNumaAllocationStrategy"/> </constructor-arg> </constructor-arg> </bean> </property> </bean> </property> </bean> </property>