summaryrefslogtreecommitdiff
path: root/lib/Transforms
diff options
context:
space:
mode:
authorEvgeniy Stepanov <eugeni.stepanov@gmail.com>2014-06-25 14:41:57 +0000
committerEvgeniy Stepanov <eugeni.stepanov@gmail.com>2014-06-25 14:41:57 +0000
commit6ce4a9f175830e7e981b885e4dc80bc53bda3d77 (patch)
tree5c91c8c978a757f9941e3611fa195613849c94b5 /lib/Transforms
parent95be6a7c3d841e2d30a96579d4fe8457748477fa (diff)
downloadllvm-6ce4a9f175830e7e981b885e4dc80bc53bda3d77.tar.gz
llvm-6ce4a9f175830e7e981b885e4dc80bc53bda3d77.tar.bz2
llvm-6ce4a9f175830e7e981b885e4dc80bc53bda3d77.tar.xz
[msan] Fix bad interaction between with-calls mode and chained origin tracking.
Origin history should only be recorded for uninitialized values, because it is meaningless otherwise. This change moves __msan_chain_origin to the runtime library side and makes it conditional on the corresponding shadow value. Previous code was correct, but _very_ inefficient. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@211700 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms')
-rw-r--r--lib/Transforms/Instrumentation/MemorySanitizer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Transforms/Instrumentation/MemorySanitizer.cpp b/lib/Transforms/Instrumentation/MemorySanitizer.cpp
index 75c56c2d43..4ca0323807 100644
--- a/lib/Transforms/Instrumentation/MemorySanitizer.cpp
+++ b/lib/Transforms/Instrumentation/MemorySanitizer.cpp
@@ -569,7 +569,7 @@ struct MemorySanitizerVisitor : public InstVisitor<MemorySanitizerVisitor> {
ConvertedShadow, IRB.getIntNTy(8 * (1 << SizeIndex)));
IRB.CreateCall3(Fn, ConvertedShadow2,
IRB.CreatePointerCast(Addr, IRB.getInt8PtrTy()),
- updateOrigin(Origin, IRB));
+ Origin);
} else {
Value *Cmp = IRB.CreateICmpNE(
ConvertedShadow, getCleanShadow(ConvertedShadow), "_mscmp");