kda abandoned this revision. kda added a comment. will attempt in smaller pieces.
================ Comment at: llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp:3317 ConstantInt::get(IntptrTy, LocalStackSize)); - IRB.SetInsertPoint(InsBefore); - FakeStack = createPHI(IRB, UseAfterReturnIsEnabled, FakeStackValue, Term, - ConstantInt::get(IntptrTy, 0)); - - Value *NoFakeStack = - IRB.CreateICmpEQ(FakeStack, Constant::getNullValue(IntptrTy)); - Term = SplitBlockAndInsertIfThen(NoFakeStack, InsBefore, false); - IRBIf.SetInsertPoint(Term); - Value *AllocaValue = - DoDynamicAlloca ? createAllocaForLayout(IRBIf, L, true) : StaticAlloca; - - IRB.SetInsertPoint(InsBefore); - LocalStackBase = createPHI(IRB, NoFakeStack, AllocaValue, Term, FakeStack); - IRB.CreateStore(LocalStackBase, LocalStackBaseAlloca); - DIExprFlags |= DIExpression::DerefBefore; + IRB.SetInsertPoint(InsBefore); + PHINode *FakeStack = IRB.CreatePHI(IntptrTy, 1); ---------------- I think this is where things start going wrong, but after a few hours looking, I'm not sure what the code should look like. I know I don't want a branch, but I don't know how to just stick the call in to the stack allocator. I think once that is right, then the pieces after it follow in a straightforwad manner. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D99630/new/ https://reviews.llvm.org/D99630 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits