[PATCH] D139883: [llvm][CallBrPrepare] add llvm.callbr.landingpad intrinsic
James Y Knight via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 19 11:53:10 PST 2023
jyknight added inline comments.
================
Comment at: llvm/lib/CodeGen/CallBrPrepare.cpp:124
+ IRBuilder<> Builder(Dest->getContext());
+ llvm::Intrinsic::ID ID = llvm::Intrinsic::callbr_landingpad;
+
----------------
Doesn't seem like much point in having this a separate variable, can just pass directly to CreateIntrinsic. And I'd merge this fn into InsertIntrinsicCalls -- with construction of Builder outside the loop, and SetInsertPoint+CreateIntrinsic in the loop.
================
Comment at: llvm/test/Transforms/SimplifyCFG/callbr-destinations.ll:62
+
+; Validate that callbr landingpad intrinsics do not get merged (via the
+; IntrNoMerge attribute).
----------------
In the expected pass pipeline, do we simplifycfg after callbrprepare? That seems a bit surprising if so?
(Not that it's wrong to mark it IntrNoMerge, of course.)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D139883/new/
https://reviews.llvm.org/D139883
More information about the llvm-commits
mailing list