eugenis added inline comments. ================ Comment at: lib/CodeGen/CGExpr.cpp:3871 @@ +3870,3 @@ + isa<llvm::MDNode>(MD) && dyn_cast<llvm::MDNode>(MD)->isDistinct(); + if (CGM.getCodeGenOpts().SanitizeCfiCrossDso && !hasLocalScope) { + EmitCfiSlowPathCheck(BitSetTest, MD, CastedCallee); ---------------- pcc wrote: > Early return. It's too early to return.
================ Comment at: lib/CodeGen/CodeGenModule.cpp:996 @@ +995,3 @@ + !(isa<CXXMethodDecl>(FD) && !cast<CXXMethodDecl>(FD)->isStatic()) && + !(CodeGenOpts.SanitizeCfiCrossDso && !FD->hasBody() && + !(getContext().GetGVALinkageForFunction(FD) == ---------------- pcc wrote: > This is a little hard to read and probably needs to go back into a function > with early returns. Sorry, my bad. I also think the logic for > `available_externally` is wrong (please add a test case). Moved out to a function. Added a testcase. Looks like available_externally is handled correctly. Repository: rL LLVM http://reviews.llvm.org/D15367 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits