File tree 2 files changed +2
-9
lines changed
lib/Transforms/Instrumentation
test/Instrumentation/MemorySanitizer
2 files changed +2
-9
lines changed Original file line number Diff line number Diff line change @@ -284,9 +284,6 @@ static cl::opt<bool> ClHandleLifetimeIntrinsics(
284
284
// passed into an assembly call. Note that this may cause false positives.
285
285
// Because it's impossible to figure out the array sizes, we can only unpoison
286
286
// the first sizeof(type) bytes for each type* pointer.
287
- // The instrumentation is only enabled in KMSAN builds, and only if
288
- // -msan-handle-asm-conservative is on. This is done because we may want to
289
- // quickly disable assembly instrumentation when it breaks.
290
287
static cl::opt<bool > ClHandleAsmConservative (
291
288
" msan-handle-asm-conservative" ,
292
289
cl::desc (" conservative handling of inline assembly" ), cl::Hidden,
@@ -4103,11 +4100,7 @@ struct MemorySanitizerVisitor : public InstVisitor<MemorySanitizerVisitor> {
4103
4100
// do the usual thing: check argument shadow and mark all outputs as
4104
4101
// clean. Note that any side effects of the inline asm that are not
4105
4102
// immediately visible in its constraints are not handled.
4106
- // For now, handle inline asm by default for KMSAN.
4107
- bool HandleAsm = ClHandleAsmConservative.getNumOccurrences ()
4108
- ? ClHandleAsmConservative
4109
- : MS.CompileKernel ;
4110
- if (HandleAsm)
4103
+ if (ClHandleAsmConservative)
4111
4104
visitAsmInstruction (CB);
4112
4105
else
4113
4106
visitInstruction (CB);
Original file line number Diff line number Diff line change 1
1
; Test for handling of asm constraints in MSan instrumentation.
2
2
; RUN: opt < %s -msan-check-access-address=0 -msan-handle-asm-conservative=0 -S -passes=msan 2>&1 | \
3
3
; RUN: FileCheck %s
4
- ; RUN: opt < %s -msan-check-access-address=0 -msan-handle-asm-conservative=1 - S -passes=msan 2>&1 | \
4
+ ; RUN: opt < %s -msan-check-access-address=0 -S -passes=msan 2>&1 | \
5
5
; RUN: FileCheck --check-prefixes=CHECK,USER-CONS %s
6
6
; RUN: opt < %s -msan-kernel=1 -msan-check-access-address=0 \
7
7
; RUN: -msan-handle-asm-conservative=0 -S -passes=msan 2>&1 | FileCheck \
You can’t perform that action at this time.
0 commit comments