summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/ARM
diff options
context:
space:
mode:
authorTim Northover <tnorthover@apple.com>2018-04-13 22:25:20 +0000
committerTim Northover <tnorthover@apple.com>2018-04-13 22:25:20 +0000
commit271d3d277172f8db05953957310cbf5665d1bafb (patch)
treef9bf11ef845d7004c266c244e2725cde074f2b15 /llvm/lib/Target/ARM
parent8db3e115e75a820dbcdfb2bc7730a11c6845f0de (diff)
downloadbcm5719-llvm-271d3d277172f8db05953957310cbf5665d1bafb.tar.gz
bcm5719-llvm-271d3d277172f8db05953957310cbf5665d1bafb.zip
MachO: trap unreachable instructions
Debugability is more important than saving 4 bytes to let us to fall through to nonense. llvm-svn: 330073
Diffstat (limited to 'llvm/lib/Target/ARM')
-rw-r--r--llvm/lib/Target/ARM/ARMTargetMachine.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/Target/ARM/ARMTargetMachine.cpp b/llvm/lib/Target/ARM/ARMTargetMachine.cpp
index 83f281b98ed..9ed0851cf22 100644
--- a/llvm/lib/Target/ARM/ARMTargetMachine.cpp
+++ b/llvm/lib/Target/ARM/ARMTargetMachine.cpp
@@ -238,6 +238,9 @@ ARMBaseTargetMachine::ARMBaseTargetMachine(const Target &T, const Triple &TT,
this->Options.EABIVersion = EABI::EABI5;
}
+ if (TT.isOSBinFormatMachO())
+ this->Options.TrapUnreachable = true;
+
initAsmInfo();
}
OpenPOWER on IntegriCloud