Re: [PATCH] rcu: speed up quiescent state detection

From: Manfred Spraul
Date: Thu Dec 30 2004 - 10:40:17 EST


Oleg Nesterov wrote:

On top of Manfred's 'rcu: simplify quiescent state detection', see
http://marc.theaimsgroup.com/?l=linux-kernel&m=110433412126392

Let's suppose that cpu is running idle thread or user level process,
and the grace period was started.

Afaics, currently we need 2 local timer interrupts to happen before
this cpu can end its grace period.



I agree with you that the design is not optimal, but I must think about it a bit more.
Right now the grace period handling consists out of three steps for each cpu:
- start grace period (from timer irq)
- log quiescent state in ->passed_quiesc (from timer or schedule())
- end grace period (from timer irq)

This requires at least two timer ticks. Your patch would reduce that to one timer tick, without changing the approach. I'm still thinking about the design change I proposed: In each quiescent state: check if there is a running grace period and if there is one, then mark the current cpu as done.

Dipankar: What do you think?

--
Manfred
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/