diff options
author | Justin Bogner <mail@justinbogner.com> | 2017-01-13 23:46:11 +0000 |
---|---|---|
committer | Justin Bogner <mail@justinbogner.com> | 2017-01-13 23:46:11 +0000 |
commit | 1a314dac4b067ec2d9bf0a3e56c6b572871c69bf (patch) | |
tree | 4f28525f8f51e82955fd794157e70148dc2443f9 /llvm/lib/CodeGen/LLVMTargetMachine.cpp | |
parent | faf2a81380e5ae97fcb420735cb66e978c943b27 (diff) | |
download | llvm-1a314dac4b067ec2d9bf0a3e56c6b572871c69bf.zip llvm-1a314dac4b067ec2d9bf0a3e56c6b572871c69bf.tar.gz llvm-1a314dac4b067ec2d9bf0a3e56c6b572871c69bf.tar.bz2 |
GlobalISel: Abort in ResetMachineFunctionPass if fallback isn't enabled
When GlobalISel is configured to abort rather than fallback the only
thing that resetting the machine function does is make things harder
to debug. If we ever get to this point in the abort configuration it
indicates that we've already hit a bug, so this changes the behaviour
to abort instead.
llvm-svn: 291977
Diffstat (limited to 'llvm/lib/CodeGen/LLVMTargetMachine.cpp')
-rw-r--r-- | llvm/lib/CodeGen/LLVMTargetMachine.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/LLVMTargetMachine.cpp b/llvm/lib/CodeGen/LLVMTargetMachine.cpp index cb79d3a..367fd66 100644 --- a/llvm/lib/CodeGen/LLVMTargetMachine.cpp +++ b/llvm/lib/CodeGen/LLVMTargetMachine.cpp @@ -172,7 +172,8 @@ addPassesToGenerateCode(LLVMTargetMachine *TM, PassManagerBase &PM, // Pass to reset the MachineFunction if the ISel failed. PM.add(createResetMachineFunctionPass( - PassConfig->reportDiagnosticWhenGlobalISelFallback())); + PassConfig->reportDiagnosticWhenGlobalISelFallback(), + PassConfig->isGlobalISelAbortEnabled())); // Provide a fallback path when we do not want to abort on // not-yet-supported input. |