Re: Prototype patch for Linux-kernel memory model
From: afzal mohammed
Date: Thu Dec 21 2017 - 23:19:23 EST
On Thu, Dec 21, 2017 at 08:15:02AM -0800, Paul E. McKenney wrote:
> On Thu, Dec 21, 2017 at 09:00:55AM +0530, afzal mohammed wrote:
> > Since it is now mentioned that r1 can have final value of 0, though it
> > is understood, it might make things crystal clear and for the sake of
> > completeness to also show the non-automatic variable x being
> > initialized to 0.
> Here we rely on the C-language and Linux-kernel convention that global
> variables that are not explicitly initialized are initialized to zero.
> (Also the documented behavior of the litmus tests and the herd tool that
> uses them.) So that part should be OK as is.
Okay, that was suggested to bring parity with some of the examples in
explanation.txt, where global variables are explicitly initalized to
zero, that unconsciously made me feel that litmus tests also follow
that pattern, but checking again realize that litmus tests are not so.
> Nevertheless, thank you for your review and comments!
Thanks for taking the effort to reply.
> Have you installed and run the herd tool? Doing so would allow you
> to experiment with changes to the litmus tests.
Yes, i installed herd tool and then i was at a loss :(, so started
re-reading the documentation, yet to run any of the tests.