리눅스에서 명령어로 아키텍처 식별방법
CPU 아키텍처는 물리적 소켓/ 프로세서 갯수, 프로세서당 코어갯수, L1/L2/L3 Cache, NUMA(Non-UNIFORM MOMORY ACCESS) 구성등이 해당됩니다.
가장흔히 사용하는 /proc/cpuinfo , dmicode 는 워낙 잘 알고들 있을테니 본문에서는 생략합니다.
혹시나 해서…
example)
# cat /proc/cpuinfo
# dmicode
위 두 방법말고 몇가지 더 소개해드립니다.
명령어에 따라 확인되는 범위나 비쥬얼에 차이가 있으니 맘에 드는걸로 골라서 쓰세요.
1. likwid
# git clone https://github.com/rrze-likwid/likwid.git
# cd likwid
# make ; make install
# likwid-topology -g
likwid-topology: Display the NUMA and cache topology.
likwid-perfctr: Display the hardware performance counters of processors.
likwid-features: Display and change hardware prefetch control bits on Intel Core 2 processors.
likwid-pin: Pin a multi-threaded application to a specific CPU.
likwid-bench: Benchmarking tool for rapid prototyping of threaded assembly kernels.
likwid-mpirun: script enabling CPU pinning of MPI and MPI/threaded hybrid applications.
likwid-perfscope: Frontend for likwid-perfctr which allows real-time plotting of performance metrics.
likwid-powermeter: Tool for accessing RAPL counters and query Turbo mode steps on Intel processor.
likwid-memsweeper: Tool to clean up ccNUMA (cache-coherent NUMA) memory domains.
2. hwloc
Ubuntu / Debian
# apt-get install hwloc
RHEL / CentOS
# yum install hwloc
3. numactl
Ubuntu / Debian
# apt-get install numactl
RHEL / CentOS
# yum install numactl