Messages in this thread |  | | Date | Tue, 2 Sep 2008 08:18:06 +0200 | | From | Andi Kleen <> | | Subject | Re: [PATCH, RFC, tip/core/rcu] v3 scalable classic RCU implementation |
| |
> > It would be better if you hung rcu_irq_enter in the irq_enter() if > > statement that checks if the task was idle or not. This way it would > > be zero overhead for interruptions of non busy CPUs, keeping
Sorry that should have been "non idle CPUs" of course.
> > it out of many fast paths. > > > > Haven't read everything, sorry. > > So that I lose the #else above, and so that irq_enter() and irq_exit() > look something like the following (with additional adjustments to suit)?
Yes looks good.
BTW I wonder if the compiler CSEs the idle_cpu() check properly.
> void irq_enter(void) > { > #ifdef CONFIG_NO_HZ > int cpu = smp_processor_id(); > if (idle_cpu(cpu) && !in_interrupt()) > tick_nohz_stop_idle(cpu); > #endif > __irq_enter(); > #ifdef CONFIG_NO_HZ > if (idle_cpu(cpu)) { > rcu_irq_enter(); > tick_nohz_update_jiffies(); > } > #endif
-Andi
|  |