diff options
author | Quentin Colombet <qcolombet@apple.com> | 2016-08-27 00:18:24 +0000 |
---|---|---|
committer | Quentin Colombet <qcolombet@apple.com> | 2016-08-27 00:18:24 +0000 |
commit | 6049524d37de125850fffd1c2e571c96dcaad97b (patch) | |
tree | af70ee89ad10c5273d9878acf628d07d4df94742 /llvm/lib/CodeGen/GlobalISel/RegBankSelect.cpp | |
parent | aea50f8b84527110d5c3a4a238154eec4539b4a2 (diff) | |
download | bcm5719-llvm-6049524d37de125850fffd1c2e571c96dcaad97b.tar.gz bcm5719-llvm-6049524d37de125850fffd1c2e571c96dcaad97b.zip |
[GlobalISel] Teach the core pipeline not to run if ISel failed.
llvm-svn: 279889
Diffstat (limited to 'llvm/lib/CodeGen/GlobalISel/RegBankSelect.cpp')
-rw-r--r-- | llvm/lib/CodeGen/GlobalISel/RegBankSelect.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/GlobalISel/RegBankSelect.cpp b/llvm/lib/CodeGen/GlobalISel/RegBankSelect.cpp index bf88d742dba..9efe48adec7 100644 --- a/llvm/lib/CodeGen/GlobalISel/RegBankSelect.cpp +++ b/llvm/lib/CodeGen/GlobalISel/RegBankSelect.cpp @@ -537,6 +537,11 @@ void RegBankSelect::assignInstr(MachineInstr &MI) { } bool RegBankSelect::runOnMachineFunction(MachineFunction &MF) { + // If the ISel pipeline failed, do not bother running that pass. + if (MF.getProperties().hasProperty( + MachineFunctionProperties::Property::FailedISel)) + return false; + DEBUG(dbgs() << "Assign register banks for: " << MF.getName() << '\n'); const Function *F = MF.getFunction(); Mode SaveOptMode = OptMode; |