DynamoRIO / DynamoRIO/drmemory
bitfield in std::_Bit_reference in std::vector implementation
- Dominant language
- C
- Stars
- 2.7k
- Forks
- 290
- PR merge metrics
- No merged PRs in 30d
Description
_From [bruen...@google.com](https://code.google.com/u/109494838902877177630/) on February 23, 2014 18:43:04_
I'm seeing these on both Linux and Mac (so should we have part of the
default supps shared across them?!?)
I have not studied it enough to know if some heuristic will handle it, or whether it's a real bug -- but most likely it's a false positive due to a few bits in there being uninit but not mattering.
Error `#1`: UNINITIALIZED READ: reading register ecx
#0 std::_Bit_reference::operator bool [/usr/include/c++/4.2.1/bits/stl_bvector.h:81]
#1 std::_Bit_const_iterator::operator\* [/usr/include/c++/4.2.1/bits/stl_bvector.h:287]
#2 std::__copy<>::copy<> [/usr/include/c++/4.2.1/bits/stl_algobase.h:283]
#3 std::__copy_aux<> [/usr/include/c++/4.2.1/bits/stl_algobase.h:315]
#4 std::__copy_normal<>::__copy_n<> [/usr/include/c++/4.2.1/bits/stl_algobase.h:340]
#5 std::copy<> [/usr/include/c++/4.2.1/bits/stl_algobase.h:400]
#6 std::vector<>::_M_copy_aligned [/usr/include/c++/4.2.1/bits/stl_bvector.h:777]
#7 std::vector<>::vector [/usr/include/c++/4.2.1/bits/stl_bvector.h:501]
#8 std::vector<>::vector [/usr/include/c++/4.2.1/bits/stl_bvector.h:502]
#9 std::_Construct<> [/usr/include/c++/4.2.1/bits/stl_construct.h:81]
#10 std::__uninitialized_copy_aux<> [/usr/include/c++/4.2.1/bits/stl_uninitialized.h:87]
#11 std::uninitialized_copy<> [/usr/include/c++/4.2.1/bits/stl_uninitialized.h:113]
Note: @0:00:19.253 in thread 733130
Note: instruction: cmp %ecx $0x00000000
Error `#2`: UNINITIALIZED READ: reading register ecx
#0 std::_Bit_reference::operator bool [/usr/include/c++/4.2.1/bits/stl_bvector.h:81]
#1 std::_Bit_const_iterator::operator\* [/usr/include/c++/4.2.1/bits/stl_bvector.h:287]
#2 std::vector<>::operator[] [/usr/include/c++/4.2.1/bits/stl_bvector.h:609]
...
Note: @0:00:28.555 in thread 733130
Note: instruction: cmp %ecx $0x00000000
Error `#3`: UNINITIALIZED READ: reading register ecx
#0 std::_Bit_reference::operator bool [/usr/include/c++/4.2.1/bits/stl_bvector.h:81]
#1 std::_Bit_const_iterator::operator\* [/usr/include/c++/4.2.1/bits/stl_bvector.h:287]
#2 std::vector<>::operator[] [/usr/include/c++/4.2.1/bits/stl_bvector.h:609]
...
Note: @0:00:28.999 in thread 733130
Note: instruction: cmp %ecx $0x00000000
_Original issue: http://code.google.com/p/drmemory/issues/detail?id=1451_
Contributor guide
Assessment
This issue has not been assessed yet.