Affinity
Example
Query affinity domain information:
julia> aff = LIKWID.get_affinity()
LIKWID.AffinityDomains
├ numberOfSocketDomains: 2
├ numberOfNumaDomains: 2
├ numberOfProcessorsPerSocket: 24
├ numberOfCacheDomains: 2
├ numberOfCoresPerCache: 12
├ numberOfProcessorsPerCache: 24
├ numberOfAffinityDomains: 9
└ domains: ... (9 elements)
julia> aff.domains
9-element Vector{LIKWID.AffinityDomain}:
LIKWID.AffinityDomain("N", 48, 24, [0, 24, 1, 25, 2, 26, 3, 27, 4, 28 … 19, 43, 20, 44, 21, 45, 22, 46, 23, 47])
LIKWID.AffinityDomain("S0", 24, 12, [0, 24, 1, 25, 2, 26, 3, 27, 4, 28 … 7, 31, 8, 32, 9, 33, 10, 34, 11, 35])
LIKWID.AffinityDomain("S1", 24, 12, [12, 36, 13, 37, 14, 38, 15, 39, 16, 40 … 19, 43, 20, 44, 21, 45, 22, 46, 23, 47])
LIKWID.AffinityDomain("D0", 24, 12, [0, 24, 1, 25, 2, 26, 3, 27, 4, 28 … 7, 31, 8, 32, 9, 33, 10, 34, 11, 35])
LIKWID.AffinityDomain("D1", 24, 12, [12, 36, 13, 37, 14, 38, 15, 39, 16, 40 … 19, 43, 20, 44, 21, 45, 22, 46, 23, 47])
LIKWID.AffinityDomain("C0", 24, 12, [0, 24, 1, 25, 2, 26, 3, 27, 4, 28 … 7, 31, 8, 32, 9, 33, 10, 34, 11, 35])
LIKWID.AffinityDomain("C1", 24, 12, [12, 36, 13, 37, 14, 38, 15, 39, 16, 40 … 19, 43, 20, 44, 21, 45, 22, 46, 23, 47])
LIKWID.AffinityDomain("M0", 24, 12, [0, 24, 1, 25, 2, 26, 3, 27, 4, 28 … 7, 31, 8, 32, 9, 33, 10, 34, 11, 35])
LIKWID.AffinityDomain("M1", 24, 12, [12, 36, 13, 37, 14, 38, 15, 39, 16, 40 … 19, 43, 20, 44, 21, 45, 22, 46, 23, 47])
Index
LIKWID.cpustr_to_cpulist
LIKWID.finalize_affinity
LIKWID.get_affinity
LIKWID.get_processor_id
LIKWID.get_processor_id_glibc
LIKWID.get_processor_ids
LIKWID.init_affinity
LIKWID.pinprocess
LIKWID.pinthread
LIKWID.pinthreads
LIKWID.AffinityDomain
LIKWID.AffinityDomains
Functions
LIKWID.init_affinity
— FunctionInitialize LIKWIDs affinity domain module.
LIKWID.finalize_affinity
— FunctionClose and finalize LIKWIDs affinity domain module.
LIKWID.get_affinity
— FunctionQuery affinity domain information
LIKWID.cpustr_to_cpulist
— FunctionTransform a valid cpu string in LIKWID syntax into a list of CPU IDs
LIKWID.get_processor_id
— FunctionReturns the ID of the currently executing CPU.
LIKWID.get_processor_ids
— FunctionGet the CPU core IDs of the Julia threads.
LIKWID.get_processor_id_glibc
— FunctionReturns the ID of the currently executing CPU via glibc
s sched_getcpu
function.
LIKWID.pinprocess
— Functionpinprocess(cpuid::Integer)
Pins the current process to the CPU given as cpuid
. Returns true on success.
LIKWID.pinthread
— Functionpinthread(cpuid::Integer)
Pins the current thread to the CPU given as cpuid
. Returns true on success.
LIKWID.pinthreads
— FunctionPin all Julia threads to the CPU cores coreids
. Note that length(coreids) == Threads.nthreads()
must hold!
Types
LIKWID.AffinityDomains
— TypeInformation about the affinity domains
LIKWID.AffinityDomain
— TypeAn affinity domain