Title
Data race avoidance for all containers, not only for sequences
Status
c++14
Section
[container.requirements.dataraces]
Submitter
Jonathan Wakely

Created on 2012-10-17.00:00:00 last changed 130 months ago

Messages

Date: 2013-04-19.22:36:19

Proposed resolution:

This wording is relative to N3376.

  1. Change [container.requirements.dataraces]/2 as indicated:

    -2- Notwithstanding ([res.on.data.races]), implementations are required to avoid data races when the contents of the contained object in different elements in the same sequencecontainer, excepting vector<bool>, are modified concurrently.

    -3- [Note: For a vector<int> x with a size greater than one, x[1] = 5 and *x.begin() = 10 can be executed concurrently without a data race, but x[0] = 5 and *x.begin() = 10 executed concurrently may result in a data race. As an exception to the general rule, for a vector<bool> y, y[0] = true may race with y[1] = true. — end note ]

Date: 2013-04-20.00:00:00

[ 2013-04-20 Bristol ]

Date: 2013-03-15.00:00:00

[ 2013-03-15 Issues Teleconference ]

Moved to Tentatively Ready.

Date: 2012-10-17.00:00:00

[container.requirements.dataraces]/2 says "[…] implementations are required to avoid data races when the contents of the contained object in different elements in the same sequence, excepting vector<bool>, are modified concurrently."

This should say "same container" instead of "same sequence", to avoid the interpretation that it only applies to sequence containers.

History
Date User Action Args
2014-02-20 13:20:35adminsetstatus: wp -> c++14
2013-04-25 19:07:07adminsetstatus: voting -> wp
2013-04-19 22:36:19adminsetmessages: + msg6486
2013-04-19 22:36:19adminsetstatus: ready -> voting
2013-03-18 14:33:00adminsetmessages: + msg6420
2013-03-18 13:02:36adminsetstatus: new -> ready
2012-10-21 14:42:56adminsetmessages: + msg6214
2012-10-17 00:00:00admincreate