diff --git a/lib/MC/MCAsmStreamer.cpp b/lib/MC/MCAsmStreamer.cpp index d1ea3c90440..eabf4c44b2d 100644 --- a/lib/MC/MCAsmStreamer.cpp +++ b/lib/MC/MCAsmStreamer.cpp @@ -1605,7 +1605,11 @@ MCStreamer *llvm::createAsmStreamer(MCContext &Context, bool useCFI, MCInstPrinter *IP, MCCodeEmitter *CE, TargetAsmBackend *TAB, bool ShowInst) { - if (isVerboseAsm) + ExceptionHandling::ExceptionsType ET = + Context.getAsmInfo().getExceptionHandlingType(); + + if (isVerboseAsm && + (ET == ExceptionHandling::SjLj || ET == ExceptionHandling::DwarfCFI)) return new MCLSDADecoderAsmStreamer(Context, OS, isVerboseAsm, useLoc, useCFI, IP, CE, TAB, ShowInst);