Make the disassembler respect the assembler dialect when printing instructions,

patch by Marius Wachtler!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101160 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2010-04-13 18:41:17 +00:00
parent 97e6992e3e
commit f23c769294

View File

@ -142,7 +142,9 @@ int Disassembler::disassemble(const Target &T, const std::string &Triple,
return -1;
}
OwningPtr<MCInstPrinter> IP(T.createMCInstPrinter(0, *AsmInfo));
int AsmPrinterVariant = AsmInfo->getAssemblerDialect();
OwningPtr<MCInstPrinter> IP(T.createMCInstPrinter(AsmPrinterVariant,
*AsmInfo));
if (!IP) {
errs() << "error: no instruction printer for target " << Triple << '\n';
return -1;