mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-24 23:28:41 +00:00
Make machine verifier check the first instruction of the last bundle instead of
the last instruction of a basic block. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158468 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -476,8 +476,8 @@ MachineVerifier::visitMachineBasicBlockBefore(const MachineBasicBlock *MBB) {
|
||||
report("MBB exits via unconditional fall-through but its successor "
|
||||
"differs from its CFG successor!", MBB);
|
||||
}
|
||||
if (!MBB->empty() && MBB->back().isBarrier() &&
|
||||
!TII->isPredicated(&MBB->back())) {
|
||||
if (!MBB->empty() && getBundleStart(&MBB->back())->isBarrier() &&
|
||||
!TII->isPredicated(getBundleStart(&MBB->back()))) {
|
||||
report("MBB exits via unconditional fall-through but ends with a "
|
||||
"barrier instruction!", MBB);
|
||||
}
|
||||
@@ -497,10 +497,10 @@ MachineVerifier::visitMachineBasicBlockBefore(const MachineBasicBlock *MBB) {
|
||||
if (MBB->empty()) {
|
||||
report("MBB exits via unconditional branch but doesn't contain "
|
||||
"any instructions!", MBB);
|
||||
} else if (!MBB->back().isBarrier()) {
|
||||
} else if (!getBundleStart(&MBB->back())->isBarrier()) {
|
||||
report("MBB exits via unconditional branch but doesn't end with a "
|
||||
"barrier instruction!", MBB);
|
||||
} else if (!MBB->back().isTerminator()) {
|
||||
} else if (!getBundleStart(&MBB->back())->isTerminator()) {
|
||||
report("MBB exits via unconditional branch but the branch isn't a "
|
||||
"terminator instruction!", MBB);
|
||||
}
|
||||
@@ -520,10 +520,10 @@ MachineVerifier::visitMachineBasicBlockBefore(const MachineBasicBlock *MBB) {
|
||||
if (MBB->empty()) {
|
||||
report("MBB exits via conditional branch/fall-through but doesn't "
|
||||
"contain any instructions!", MBB);
|
||||
} else if (MBB->back().isBarrier()) {
|
||||
} else if (getBundleStart(&MBB->back())->isBarrier()) {
|
||||
report("MBB exits via conditional branch/fall-through but ends with a "
|
||||
"barrier instruction!", MBB);
|
||||
} else if (!MBB->back().isTerminator()) {
|
||||
} else if (!getBundleStart(&MBB->back())->isTerminator()) {
|
||||
report("MBB exits via conditional branch/fall-through but the branch "
|
||||
"isn't a terminator instruction!", MBB);
|
||||
}
|
||||
@@ -540,10 +540,10 @@ MachineVerifier::visitMachineBasicBlockBefore(const MachineBasicBlock *MBB) {
|
||||
if (MBB->empty()) {
|
||||
report("MBB exits via conditional branch/branch but doesn't "
|
||||
"contain any instructions!", MBB);
|
||||
} else if (!MBB->back().isBarrier()) {
|
||||
} else if (!getBundleStart(&MBB->back())->isBarrier()) {
|
||||
report("MBB exits via conditional branch/branch but doesn't end with a "
|
||||
"barrier instruction!", MBB);
|
||||
} else if (!MBB->back().isTerminator()) {
|
||||
} else if (!getBundleStart(&MBB->back())->isTerminator()) {
|
||||
report("MBB exits via conditional branch/branch but the branch "
|
||||
"isn't a terminator instruction!", MBB);
|
||||
}
|
||||
|
Reference in New Issue
Block a user