[llvm] 0bbf4bb - GlobalISel: Remove redundant check for empty blocks

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 10 05:58:22 PDT 2020


Author: Matt Arsenault
Date: 2020-08-10T08:46:30-04:00
New Revision: 0bbf4bb8db29bd97ae54fe741baebc3062be60d9

URL: https://github.com/llvm/llvm-project/commit/0bbf4bb8db29bd97ae54fe741baebc3062be60d9
DIFF: https://github.com/llvm/llvm-project/commit/0bbf4bb8db29bd97ae54fe741baebc3062be60d9.diff

LOG: GlobalISel: Remove redundant check for empty blocks

Added: 
    

Modified: 
    llvm/lib/CodeGen/GlobalISel/Combiner.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/CodeGen/GlobalISel/Combiner.cpp b/llvm/lib/CodeGen/GlobalISel/Combiner.cpp
index b4562a5c6601..48f4c5b0f371 100644
--- a/llvm/lib/CodeGen/GlobalISel/Combiner.cpp
+++ b/llvm/lib/CodeGen/GlobalISel/Combiner.cpp
@@ -130,8 +130,6 @@ bool Combiner::combineMachineInstrs(MachineFunction &MF,
       WrapperObserver.addObserver(CSEInfo);
     RAIIDelegateInstaller DelInstall(MF, &WrapperObserver);
     for (MachineBasicBlock *MBB : post_order(&MF)) {
-      if (MBB->empty())
-        continue;
       for (auto MII = MBB->rbegin(), MIE = MBB->rend(); MII != MIE;) {
         MachineInstr *CurMI = &*MII;
         ++MII;


        


More information about the llvm-commits mailing list