Possible language changes

Ben Hutchings ben at decadentplace.org.uk
Sun Feb 27 13:27:41 GMT 2005


Here's a list I came up with some months ago, but only posted to the
mailing list that I hastily set up and which we haven't used.  I think
I'm going to have a go at drafting an actual proposal soon, but I don't
know whether I'm really up to that task.

I skimmed through the language part of the standard, looking for
anything that might be affected by concurrency.

Most importantly:

1.3 [intro.defs] We may need to add definitions of "thread" and other
terms.

1.9/6-11 [intro.execution] We need to change the specification of the
sequencing of operations and the definition of observable behaviour to
allow for concurrency and synchronisation.  We may wish to specify more
precise semantics for volatile.

3.6.1, 3.6.3 [basic.start.main, basic.start.term] We should either
specify what happens if main exits or if exit() or abort() is called
while multiple threads exist, or else state that this results in
undefined behaviour.

3.6.2/3 [basic.start.init] We should specify that static initialisation
at namespace scope is always synchronised if done while multiple threads
exist.

6.7/4 [stmt.dcl] We should specify static initialisation at local scope
in such a way that it can be or is always synchronised.

15 [except] We must change some parts of this slightly to allow for
concurrency, including at least 15.1/7, 15.1/8, 15.2/1, 15.2/2, 15.5.3

Plus optionally:

2.11 [lex.key] We may wish to add keywords.

6 [stmt.stmt] We may wish to add synchronisation statements.

7 [dcl.dcl] We may wish to add some new form of declaration.

-- 
Ben Hutchings
Life would be so much easier if we could look at the source code.



More information about the cpp-threads mailing list