[llvm] r278366 - AArch64: Assert on analyzeBranch failing
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 11 10:23:00 PDT 2016
Author: arsenm
Date: Thu Aug 11 12:22:59 2016
New Revision: 278366
URL: http://llvm.org/viewvc/llvm-project?rev=278366&view=rev
Log:
AArch64: Assert on analyzeBranch failing
Modified:
llvm/trunk/lib/Target/AArch64/AArch64BranchRelaxation.cpp
Modified: llvm/trunk/lib/Target/AArch64/AArch64BranchRelaxation.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AArch64/AArch64BranchRelaxation.cpp?rev=278366&r1=278365&r2=278366&view=diff
==============================================================================
--- llvm/trunk/lib/Target/AArch64/AArch64BranchRelaxation.cpp (original)
+++ llvm/trunk/lib/Target/AArch64/AArch64BranchRelaxation.cpp Thu Aug 11 12:22:59 2016
@@ -424,9 +424,11 @@ bool AArch64BranchRelaxation::fixupCondi
if (NeedSplit) {
// Analyze the branch so we know how to update the successor lists.
- MachineBasicBlock *TBB, *FBB;
+ MachineBasicBlock *TBB = nullptr, *FBB = nullptr;
SmallVector<MachineOperand, 2> Cond;
- TII->analyzeBranch(*MBB, TBB, FBB, Cond, false);
+ bool Fail = TII->analyzeBranch(*MBB, TBB, FBB, Cond, false);
+ assert(!Fail && "branches to relax should be analyzable");
+ (void)Fail;
MachineBasicBlock *NewBB = splitBlockBeforeInstr(MI);
// No need for the branch to the next block. We're adding an unconditional
More information about the llvm-commits
mailing list