eugenis added inline comments.
================ Comment at: clang/lib/CodeGen/CGAtomic.cpp:315 + llvm::FunctionCallee fn = + CGF.CGM.CreateRuntimeFunction(fnTy, fnName, fnAttrs); auto callee = CGCallee::forDirect(fn); ---------------- This needs a clang test, and better move it to a separate change. ================ Comment at: llvm/lib/Transforms/Instrumentation/MemorySanitizer.cpp:3509 + Instruction *InsPoint = CB.getNextNode(); + if (!InsPoint) { + llvm::errs() << "MSAN -- cannot instrument libatomic call with no " ---------------- Better explicitly check that this an invoke and not call. Call always has a next instruction. And move this check to the parent function to apply regular call instrumentation to the unrecognized call. ================ Comment at: llvm/lib/Transforms/Instrumentation/MemorySanitizer.cpp:3511 + llvm::errs() << "MSAN -- cannot instrument libatomic call with no " + "successor. Ignoring!\n"; + return; ---------------- It has a successor. Two successors, actually. I'd rather say something like "invoke of __atomic_load". Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D85559/new/ https://reviews.llvm.org/D85559 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits