[PATCH] D134490: [NFC] check for UnreachableInst first as it is cheaper compared to getTerminatingDeoptimizeCall
Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 28 15:31:54 PDT 2023
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG1ce2015f7eb0: [NFC] check for UnreachableInst first as it is cheaper compared to… (authored by AdityaK <1894981+hiraditya at users.noreply.github.com>).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D134490/new/
https://reviews.llvm.org/D134490
Files:
llvm/lib/Transforms/Utils/BasicBlockUtils.cpp
Index: llvm/lib/Transforms/Utils/BasicBlockUtils.cpp
===================================================================
--- llvm/lib/Transforms/Utils/BasicBlockUtils.cpp
+++ llvm/lib/Transforms/Utils/BasicBlockUtils.cpp
@@ -600,8 +600,8 @@
unsigned Depth = 0;
while (BB && Depth++ < MaxDeoptOrUnreachableSuccessorCheckDepth &&
VisitedBlocks.insert(BB).second) {
- if (BB->getTerminatingDeoptimizeCall() ||
- isa<UnreachableInst>(BB->getTerminator()))
+ if (isa<UnreachableInst>(BB->getTerminator()) ||
+ BB->getTerminatingDeoptimizeCall())
return true;
BB = BB->getUniqueSuccessor();
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D134490.518068.patch
Type: text/x-patch
Size: 638 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230428/bd509454/attachment.bin>
More information about the llvm-commits
mailing list