This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of Resolved status.
Section: 21.2.2 [container.requirements.dataraces] Status: Resolved Submitter: Jeffrey Yaskin Opened: 2010-03-09 Last modified: 2016-12-23
Priority: Not Prioritized
View all other issues in [container.requirements.dataraces].
View all issues with Resolved status.
The common implementation of vector<bool> is as an unsynchronized bitfield. The addition of 21.2.2 [container.requirements.dataraces]/2 would require either a change in representation or a change in access synchronization, both of which are undesireable with respect to compatibility and performance.
2010 Pittsburgh: Moved to
NAD Editorial. Rationale added below.
Solved by N3069.
Container data races 21.2.2 [container.requirements.dataraces]
Paragraph 1 is unchanged as follows:
1 For purposes of avoiding data races (220.127.116.11), implementations shall consider the following functions to be
equal_range, and, except in associative containers,
Edit paragraph 2 as follows:
2 Notwithstanding (18.104.22.168), implementations are required to avoid data races when the contents of the contained object in different elements in the same sequence are modified concurrently.
Edit paragraph 3 as follows:
3 [Note: For a
vector<int> xwith a size greater than one,
x = 5and
*x.begin() = 10can be executed concurrently without a data race, but
x = 5and
*x.begin() = 10executed concurrently may result in a data race. —end note]