linux-kernel-module-cheat icon indicating copy to clipboard operation
linux-kernel-module-cheat copied to clipboard

Multithreading in gem5 aarch64 FS using taskset

Open itamarbon opened this issue 5 years ago • 2 comments

I am trying to explore multithreading on a gem5 simulator running through LKMC. I want to run different processes on different CPUs, and am trying to bind the tasks to each CPU using taskset. I get -/bin/sh: taskset: not found when I try to run the command. What can I do to enable this utility in for aarch64 FS? Thanks, Itamar

itamarbon avatar Dec 02 '20 11:12 itamarbon

Ah, now I understood the problem taskset is not built in by default, can you rebuild the image with:

./build-buildroot \
  --arch aarch64 \
  --config 'BR2_PACKAGE_UTIL_LINUX=y' \
  --config 'BR2_PACKAGE_UTIL_LINUX_SCHEDUTILS=y' \
;

This is mentioned at: https://cirosantilli.com/linux-kernel-module-cheat/#gdb-step-debug-multicore-userland but might not be clear from other sections.

cirosantilli avatar Dec 02 '20 12:12 cirosantilli

thanks, this works

itamarbon avatar Dec 03 '20 09:12 itamarbon