0

I am running tests in Linux-4.19.188 + patch-4.19.188-rt77, with PREEMPT_RT_FULL and NO_HZ_FULL enabled.

I put a infinite loop with SCHED_FIFO (priority of 99) on an isolated CPU. The expected result is NO tick should be seen in that isolated CPU according to NO_HZ_FULL implementation.

But the number of 'Local APCI timer interrupt' in that isolated CPU is increased with HZ (250 per second in my Linux), which means the tick is activated!

I googled internet, and found a similar issue reported in Sept 2018, https://marc.info/?t=153534185000001&r=1&w=2. It seemed that Linux has NOT fixed it since then.

The issue happens randomly not always there.
I am wondering what sets up the tick timer on that isolated CPU, where should I dig into for the root cause ?

wangt13
  • 959
  • 7
  • 17
  • Have you ensured that the CPU you are running the process on is *not* the main CPU? Even when `CONFIG_NO_HZ_FULL=y` there has to be at least one CPU ticking, which is the main CPU (usually CPU 0). – Marco Bonelli Apr 22 '21 at 15:01
  • I can ensure that. I booted the Linux on a system with 8 CPUs, I isolated CPU6 and CPU7, and set nohz_full=6,7 rcu_nocbs=6-7 in kernel command line. Then taskset -c 7 chrt -f 99 loop to run the infinite./loop on the isolated CPU 7. As I said in the question, sometimes, there is NO tick in the CPU7, but sometimes there are ticks in the CPU7. That is very confusing and difficult to debug. – wangt13 Apr 23 '21 at 00:15

0 Answers0