aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/DwarfWriter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/CodeGen/DwarfWriter.cpp')
-rw-r--r--lib/CodeGen/DwarfWriter.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/DwarfWriter.cpp b/lib/CodeGen/DwarfWriter.cpp
index 0fa956e097..010dfa0a79 100644
--- a/lib/CodeGen/DwarfWriter.cpp
+++ b/lib/CodeGen/DwarfWriter.cpp
@@ -3415,7 +3415,7 @@ public:
void BeginFunction(MachineFunction *MF) {
this->MF = MF;
shouldEmitTable = shouldEmitMoves = false;
- if (TAI->doesSupportExceptionHandling()) {
+ if (MMI && TAI->doesSupportExceptionHandling()) {
// Map all labels and get rid of any dead landing pads.
MMI->TidyLandingPads();