December updates
cover December updates
Hi Paul,
Here is a small set of patches for December.
Patch 1/5 is another routine update of rcu-test.dat
Patch 2/5 mediates longer run time of RCU related litmus tests under kltimus7 by exclude those tests from default list of tests. Patch 3/5 works around a strict policy on ghostscript (gs) under Ubuntu 25.10's apparmor.
Patches 4/5 and 5/5 are obvious fixes to your recent updates in toyrcu.
As for Patch 2/5, klitmus7 converts synchronize_rcu() into synchronize_rcu_expedited() by default ever since herdtools7 7.45 released in 2017. So, the longer time to run suggests decreasing trend in "throughput of synchronize_rcu_expedited()". Have you done any benchmark on such a thing/concept?
Thanks, Akira
--
Akira Yokosawa (5):
CodeSamples/formal: Update rcu-test.dat for v6.18 CodeSamples/formal/herd/Makefile: Add KLITMUS7_EXTRAOPTS variable
Makefile: Let ghostscript access under /tmp
toyrcu: Replace \co{} with \cref{}
toyrcu: Mark inline enumerate list as such
CodeSamples/formal/data/rcu-test.dat | 1 + CodeSamples/formal/herd/Makefile | 3 +- Makefile | 5 ++- a2ping-rule.mk | 40 +++++++++++++++++------ appendix/toyrcu/toyrcu.tex | 13 +++++--- epstopdf-rule.mk | 48 +++++++++++++++++++++------- 6 files changed, 83 insertions(+), 27 deletions(-)
base-commit: f10ba2161229db12af9a1e38fd23850483721b7d
Signature · 1 line
2.43.0
PATCH 1/5 CodeSamples/formal: Update rcu-test.dat for v6.18
--- CodeSamples/formal/data/rcu-test.dat | 1 + 1 file changed, 1 insertion(+)
CodeSamples/formal/data/rcu-test.dat +1 -0
@@ -105,3 +105,4 @@ v6.12 22834 12313 35147 35.0 "" 22300 12758 35058 36.4 v6.16 22370 12983 35353 36.7 "" 22437 13261 35698 37.1 +v6.18 22542 13299 35841 37.1
Signature · 1 line
2.43.0
PATCH 2/5 CodeSamples/formal/herd/Makefile: Add KLITMUS7_EXTRAOPTS variable
In reply to Akira Yokosawaklitmus tests involving RCU, expecially with unconditional rcu_synchronize(), tend to take much longer these days even with the default "-expedited true" klitmus7 option.
Remove explicit "-rcu yes" from klitmus7's command arg and add a variable KLITMUS7_EXTRAOPTS so that those tests can be added by saying:
make KLITMUS7_EXTRAOPTS='-rcu yes' cross-klitmus7
--- CodeSamples/formal/herd/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
CodeSamples/formal/herd/Makefile +2 -1
@@ -114,7 +114,7 @@ cross-klitmus: klitmus.tar klitmus.tar: litmus2herd $(KLITMUS_TEST) mkdir -p klitmus - klitmus7 -rcu yes -o klitmus $(LITMUS7_HERD_TEST) $(KLITMUS_TEST) + klitmus7 -o klitmus $(KLITMUS7_EXTRAOPTS) $(LITMUS7_HERD_TEST) $(KLITMUS_TEST) tar cf klitmus.tar ./klitmus help:
@@ -124,6 +124,7 @@ help: @echo "Other targets:" @echo " run-herd7: Examine transformed litmus tests by herd7 with LKMM" @echo " cross-klitmus7: Cross-compile transformed litmus tests by klitmus7" + @echo " Say \"make KLITMUS7_EXTRAOPTS='-rcu yes' cross-klitmus7\" to include RCU tests." @echo " run-absperf: Run memory model benchmark tests of absperf" @echo " run-absperf-all: Run all absperf tests (including those take quite a while)" @echo " run-dblcheck4: Run C-double-check-rcu-4 (takes 20 mins or so)"
Signature · 1 line
2.43.0
PATCH 3/5 Makefile: Let ghostscript access under /tmp
In reply to Akira YokosawaUbuntu 25.10 has got an AppArmor policy for gs (ghostscript) which prevents its accesses to files outside of $HOME/:
[in /etc/apparmoer.d/gs]
# allow access to files with selected extensions under HOME owner file rw @{HOME}/**.@{gs_file_ext},
This change has resulted in build errors under Git repos not under $HOME/ [1].
As a workaround, tweak recipes involving ghostscript so that their input/output files are under /tmp, where rw accesses are allowed by a policy included from abstructions/user-tmp.
--- Makefile | 5 ++++- a2ping-rule.mk | 40 +++++++++++++++++++++++++++++++--------- epstopdf-rule.mk | 48 ++++++++++++++++++++++++++++++++++++------------ 3 files changed, 71 insertions(+), 22 deletions(-)
Makefile +4 -1
@@ -503,7 +503,10 @@ endif $(PDFTARGETS_OF_SVG_CROP): %-crop.pdf: %.pdf @echo "Crop $< (pdfcrop)" - @pdfcrop $< $@ > /dev/null + @TMP=`mktemp -d` && cp $< $$TMP/$(notdir $<) && \ + pdfcrop $$TMP/$(notdir $<) $$TMP/$(notdir $@) > /dev/null && \ + mv -f $$TMP/$(notdir $@) $@ && \ + rm -rf $$TMP/ ifdef RSVG_CONVERT FALLBACK_RSVG_CONVERT = || (cat $<i | rsvg-convert $(RSVG_FMT_OPT) > $@ && echo "$< --> $(suffix $@) (fallback rsvg-convert)")
a2ping-rule.mk +31 -9
@@ -38,10 +38,14 @@ endif ifeq ($(A2PING_GSCNFL),1) $(error You need to update a2ping. See #7 in FAQ-BUILD.txt) endif - @cp $< $<i - @sh $(FIXANEPSFONTS) $<i - @a2ping --below --hires --bboxfrom=compute-gs $<i $@ > /dev/null 2>&1 - @rm -f $<i + @TMP=`mktemp -d` && \ + TMP1=$$TMP/$(notdir $<i) && \ + TMPDST=$$TMP/$(notdir $@) && \ + cp $< $$TMP1 && \ + sh $(FIXANEPSFONTS) $$TMP1 && \ + a2ping --below --hires --bboxfrom=compute-gs $$TMP1 $$TMPDST > /dev/null 2>&1 && \ + mv -f $$TMPDST $@ && \ + rm -rf $$TMP $(PDFTARGETS_OF_TEX): %.pdf: %.eps @echo "$< --> $(suffix $@) (by a2ping)"
@@ -52,11 +56,23 @@ ifeq ($(A2PING_GSCNFL),1) $(error a2ping version conflict. See #7 in FAQ-BUILD.txt) endif ifeq ($(A2PING_GSCNFL),2) - @a2ping --below --gsextra=-dALLOWPSTRANSPARENCY $< $(basename $@)__.pdf > /dev/null 2>&1 - @pdfcrop --hires $(basename $@)__.pdf $@ > /dev/null - @rm -f $(basename $@)__.pdf + @TMP=`mktemp -d` && \ + TMPSRC=$$TMP/$(notdir $<) && \ + TMP1=$$TMP/$(notdir $(basename $@)__.pdf) && \ + TMPDST=$$TMP/$(notdir $@) && \ + cp $< $$TMPSRC && \ + a2ping --below --gsextra=-dALLOWPSTRANSPARENCY $$TMPSRC $$TMP1 > /dev/null 2>&1 && \ + pdfcrop --hires $$TMP1 $$TMPDST > /dev/null && \ + mv -f $$TMPDST $@ && \ + rm -rf $$TMP else - @a2ping --below --hires --bboxfrom=compute-gs $< $@ > /dev/null 2>&1 + @TMP=`mktemp -d` && \ + TMPSRC=$$TMP/$(notdir $<) && \ + TMPDST=$$TMP/$(notdir $@) && \ + cp $< $$TMPSRC && \ + a2ping --below --hires --bboxfrom=compute-gs $$TMPSRC $$TMPDST > /dev/null 2>&1 && \ + mv -f $$TMPDST $@ && \ + rm -rf $$TMP endif $(PDFTARGETS_OF_EPSORIG_NOFIXFONTS) $(PDFTARGETS_OF_EPSOTHER): %.pdf: %.eps
@@ -67,4 +83,10 @@ endif ifeq ($(A2PING_GSCNFL),1) $(error a2ping version conflict. See #7 in FAQ-BUILD.txt) endif - @a2ping --below --hires --bboxfrom=compute-gs $< $@ > /dev/null 2>&1 + @TMP=`mktemp -d` && \ + TMPSRC=$$TMP/$(notdir $<) && \ + TMPDST=$$TMP/$(notdir $@) && \ + cp $< $$TMPSRC && \ + a2ping --below --hires --bboxfrom=compute-gs $$TMPSRC $$TMPDST > /dev/null 2>&1 && \ + mv -f $$TMPDST $@ && \ + rm -rf $$TMP
epstopdf-rule.mk +36 -12
65 lines not on this page · raw message
Signature · 1 line
2.43.0
PATCH 4/5 toyrcu: Replace \co{} with \cref{}
In reply to Akira YokosawaTrivial typo fix.
--- appendix/toyrcu/toyrcu.tex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
appendix/toyrcu/toyrcu.tex +1 -1
@@ -861,7 +861,7 @@ grace periods, preventing grace-period sharing. Fourth, the need to consult \co{rcu_idx} slows readers slightly compared to the implementation presented in -\co{sec:app:toyrcu:Scalable Single-Counter RCU}. +\cref{sec:app:toyrcu:Scalable Single-Counter RCU}. Finally, as noted in the text, the need for per-thread variables and for enumerating threads may be problematic in some software
Signature · 1 line
2.43.0
PATCH 5/5 toyrcu: Mark inline enumerate list as such
In reply to Akira YokosawaUse the "enumerate*" environment provided by the "enumitem" package to make the inline list construct obvious, with non-breakable spaces applied implicitly.
{} at the head of each item is to escape warnings from punctcheck.
--- appendix/toyrcu/toyrcu.tex | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-)
appendix/toyrcu/toyrcu.tex +8 -3
@@ -744,9 +744,14 @@ that polls each per-thread counter in turn. \end{fcvref} This RCU implementation imposes important new requirements on its -software environment, namely, (1) that it be possible to declare -per-thread variables, (2) that these per-thread variables be accessible -from other threads, and (3) that it is possible to enumerate all threads. +software environment, namely, +% +\begin{enumerate*}[(1)] +\item {}that it be possible to declare per-thread variables, +\item {}that these per-thread variables be accessible from other threads, and +\item {}that it is possible to enumerate all threads. +\end{enumerate*} +% These requirements can be met in almost all software environments, but often result in fixed upper bounds on the number of threads. More-complex implementations might avoid such bounds, for example, by using
Signature · 1 line
2.43.0
Paul E. McKenney
AppliedQuoted 11 lines · Akira Yokosawa
Hi Paul,
Here is a small set of patches for December.
Patch 1/5 is another routine update of rcu-test.dat
Patch 2/5 mediates longer run time of RCU related litmus tests under kltimus7 by exclude those tests from default list of tests. Patch 3/5 works around a strict policy on ghostscript (gs) under Ubuntu 25.10's apparmor.
Patches 4/5 and 5/5 are obvious fixes to your recent updates in toyrcu.
Quoted 7 lines
As for Patch 2/5, klitmus7 converts
synchronize_rcu()intosynchronize_rcu_expedited()by default ever since herdtools7 7.45 released in 2017. So, the longer time to run suggests decreasing trend in "throughput ofsynchronize_rcu_expedited()". Have you done any benchmark on such a thing/concept?Thanks, Akira
Queued and pushed, thank you!
I clearly was not doing well when I added that \co{} to toyrcu! Thank you for fixing that and for converting the list.
On synchronize_rcu_expedited(), my usual runs focus on functionality and further just check synchronize_rcu(), and I have not set up anything to check trends. I will run tests on various kernel versions. I will be running this via rcuscale in a guest OS, initially on my laptop in a preemptible kernel. Please let me know if there are any special settings I should be using.
My first run on a recent kernel showed surprisingly long expedited grace periods, enough to make me suspect that they are somehow being mapped into normal grace periods. Ditto for v6.0. More later!
Thanx, Paul
Quoted 21 lines
--
Akira Yokosawa (5):
CodeSamples/formal: Update rcu-test.dat for v6.18 CodeSamples/formal/herd/Makefile: AddKLITMUS7_EXTRAOPTSvariable
Makefile: Let ghostscript access under /tmp
toyrcu: Replace \co{} with \cref{}
toyrcu: Mark inline enumerate list as suchCodeSamples/formal/data/rcu-test.dat | 1 + CodeSamples/formal/herd/Makefile | 3 +- Makefile | 5 ++- a2ping-rule.mk | 40 +++++++++++++++++------ appendix/toyrcu/toyrcu.tex | 13 +++++--- epstopdf-rule.mk | 48 +++++++++++++++++++++------- 6 files changed, 83 insertions(+), 27 deletions(-)base-commit:
f10ba2161229db12af9a1e38fd23850483721b7dSignature · 1 line
2.43.0