[msan] Fix "missing origin" in atomic store.
authorEvgeniy Stepanov <eugeni.stepanov@gmail.com>
Fri, 6 Feb 2015 21:47:39 +0000 (21:47 +0000)
committerEvgeniy Stepanov <eugeni.stepanov@gmail.com>
Fri, 6 Feb 2015 21:47:39 +0000 (21:47 +0000)
commite9f5367fed0c8f64610ba5188b5885c9ccb5902d
tree5584d156f2e113488ca57ec3cde4e5443172322f
parent67a0f806521bcfc149c355fa8d8bf06353088814
[msan] Fix "missing origin" in atomic store.

An atomic store always make the target location fully initialized (in the
current implementation). It should not store origin. Initialized memory can't
have meaningful origin, and, due to origin granularity (4 bytes) there is a
chance that this extra store would overwrite meaningfull origin for an adjacent
location.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@228444 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Instrumentation/MemorySanitizer.cpp
test/Instrumentation/MemorySanitizer/atomics.ll