From d50bbf0c7a73ee6f817535e9d0e7792ea7894a65 Mon Sep 17 00:00:00 2001 From: Richard Braun Date: Sun, 12 Aug 2018 14:59:33 +0200 Subject: kern/rcu: explain the need for separate work/reader window flips --- kern/rcu.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'kern/rcu.c') diff --git a/kern/rcu.c b/kern/rcu.c index 6126a7a7..e4508f38 100644 --- a/kern/rcu.c +++ b/kern/rcu.c @@ -72,7 +72,20 @@ * | * +------------- * - * TODO Explain the need for separate work/reader window flips. + * On each processor, work window flips are separate from reader window + * flips in order to correctly handle situations such as this one, where + * "wf" denotes a window flip for both works and readers : + * + * t ----> + * + * CPU0 wf load flush + * CPU1 wf flush + * global no-new-reader ... no-ref loaded value now invalid + * + * After its window flip, CPU0 may load data from the previous window with + * a reader linked to the current window, because it doesn't know that there + * may still be new works queued on the previous window. + * * TODO Improve atomic acknowledgment scalability. * TODO Handle large amounts of deferred works. * TODO Priority boosting of slow readers. -- cgit v1.2.3