[PATCH] D26765: GlobalISel: Fix unconditional fallback with global isel abort is disabled
Tom Stellard via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 16 12:51:38 PST 2016
tstellarAMD created this revision.
tstellarAMD added reviewers: qcolombet, t.p.northover, ab.
tstellarAMD added a subscriber: llvm-commits.
Herald added subscribers: rovka, dberris, wdng, vkalintiris, mehdi_amini.
https://reviews.llvm.org/D26765
Files:
lib/CodeGen/GlobalISel/InstructionSelect.cpp
test/CodeGen/AArch64/GlobalISel/gisel-abort.ll
Index: test/CodeGen/AArch64/GlobalISel/gisel-abort.ll
===================================================================
--- /dev/null
+++ test/CodeGen/AArch64/GlobalISel/gisel-abort.ll
@@ -0,0 +1,8 @@
+; RUN: llc -march aarch64 -global-isel -global-isel-abort=2 -verify-machineinstrs %s -o - 2>&1 | FileCheck %s
+
+; CHECK-NOT: fallback
+; CHECK: empty
+define void @empty() {
+ ret void
+}
+
Index: lib/CodeGen/GlobalISel/InstructionSelect.cpp
===================================================================
--- lib/CodeGen/GlobalISel/InstructionSelect.cpp
+++ lib/CodeGen/GlobalISel/InstructionSelect.cpp
@@ -164,7 +164,7 @@
MRI.getVRegToType().clear();
- if (!TPC.isGlobalISelAbortEnabled() && (Failed || MF.size() == NumBlocks)) {
+ if (!TPC.isGlobalISelAbortEnabled() && (Failed || MF.size() != NumBlocks)) {
MF.getProperties().set(MachineFunctionProperties::Property::FailedISel);
return false;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D26765.78247.patch
Type: text/x-patch
Size: 932 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161116/3a7fe312/attachment.bin>
More information about the llvm-commits
mailing list