File tree Expand file tree Collapse file tree 2 files changed +0
-23
lines changed
lib/Transforms/Instrumentation
test/Instrumentation/MemorySanitizer Expand file tree Collapse file tree 2 files changed +0
-23
lines changed Original file line number Diff line number Diff line change @@ -2356,12 +2356,6 @@ struct MemorySanitizerVisitor : public InstVisitor<MemorySanitizerVisitor> {
2356
2356
VAHelper->visitCallSite (CS, IRB);
2357
2357
}
2358
2358
2359
- // If this is a musttail call site, we can't insert propagation code here.
2360
- // The return type of the caller must match the callee, so the shadow should
2361
- // already be set up for an immediate return.
2362
- if (CS.isMustTailCall ())
2363
- return ;
2364
-
2365
2359
// Now, get the shadow for the RetVal.
2366
2360
if (!I.getType ()->isSized ()) return ;
2367
2361
IRBuilder<> IRBBefore (&I);
@@ -2395,10 +2389,6 @@ struct MemorySanitizerVisitor : public InstVisitor<MemorySanitizerVisitor> {
2395
2389
}
2396
2390
2397
2391
void visitReturnInst (ReturnInst &I) {
2398
- // Don't propagate shadow between musttail calls and the return.
2399
- if (I.getParent ()->getTerminatingMustTailCall ())
2400
- return ;
2401
-
2402
2392
IRBuilder<> IRB (&I);
2403
2393
Value *RetVal = I.getReturnValue ();
2404
2394
if (!RetVal) return ;
Original file line number Diff line number Diff line change @@ -878,16 +878,3 @@ define void @MismatchedReturnTypeTailCall(i32 %a) sanitize_memory {
878
878
; CHECK-LABEL: define void @MismatchedReturnTypeTailCall
879
879
; CHECK: tail call i32 @InnerTailCall
880
880
; CHECK: ret void
881
-
882
- declare i32 @InnerMustTailCall (i32 %a )
883
-
884
- define i32 @MustTailCall (i32 %a ) {
885
- %b = musttail call i32 @InnerMustTailCall (i32 %a )
886
- ret i32 %b
887
- }
888
-
889
- ; Test that 'musttail' is preserved. The ABI should make this work.
890
-
891
- ; CHECK-LABEL: define i32 @MustTailCall
892
- ; CHECK: musttail call i32 @InnerMustTailCall
893
- ; CHECK-NEXT: ret i32
You can’t perform that action at this time.
0 commit comments