[llvm] r344632 - [PATCH] [NFC][AArch64] Fix refactoring of macro fusion
Evandro Menezes via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 16 10:41:45 PDT 2018
Author: evandro
Date: Tue Oct 16 10:41:45 2018
New Revision: 344632
URL: http://llvm.org/viewvc/llvm-project?rev=344632&view=rev
Log:
[PATCH] [NFC][AArch64] Fix refactoring of macro fusion
Fix compiler error.
Modified:
llvm/trunk/lib/Target/AArch64/AArch64MacroFusion.cpp
Modified: llvm/trunk/lib/Target/AArch64/AArch64MacroFusion.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AArch64/AArch64MacroFusion.cpp?rev=344632&r1=344631&r2=344632&view=diff
==============================================================================
--- llvm/trunk/lib/Target/AArch64/AArch64MacroFusion.cpp (original)
+++ llvm/trunk/lib/Target/AArch64/AArch64MacroFusion.cpp Tue Oct 16 10:41:45 2018
@@ -64,15 +64,11 @@ static bool isArithmeticBccPair(const Ma
/// ALU operations followed by CBZ/CBNZ.
static bool isArithmeticCbzPair(const MachineInstr *FirstMI,
const MachineInstr &SecondMI) {
- switch (SecondMI.getOpcode()) {
- default:
+ if (SecondMI.getOpcode() != AArch64::CBZW &&
+ SecondMI.getOpcode() != AArch64::CBZX &&
+ SecondMI.getOpcode() != AArch64::CBNZW &&
+ SecondMI.getOpcode() != AArch64::CBNZX)
return false;
- case AArch64::CBNZW:
- case AArch64::CBNZX:
- case AArch64::CBZW:
- case AArch64::CBZX:
- LLVM_FALLTHROUGH;
- }
// Assume the 1st instr to be a wildcard if it is unspecified.
if (FirstMI == nullptr)
More information about the llvm-commits
mailing list