aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-04-07 05:27:36 +0000
committerChris Lattner <sabre@nondot.org>2010-04-07 05:27:36 +0000
commitfee455ea6a7e209a3cac5fc8e601f8e85cfb3792 (patch)
treec39dd70b135572863365777305a9d9ec90ca3543 /lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
parentdecc2671516e6c52ee2f29f7746f8d02753845ea (diff)
remove another magic number.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100606 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp')
-rw-r--r--lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp b/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
index 255bcd413f..46f3faf00b 100644
--- a/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
+++ b/lib/CodeGen/AsmPrinter/AsmPrinterInlineAsm.cpp
@@ -167,10 +167,9 @@ void AsmPrinter::EmitInlineAsm(const MachineInstr *MI) const {
break;
case '(': // $( -> same as GCC's { character.
++LastEmitted; // Consume '(' character.
- if (CurVariant != -1) {
+ if (CurVariant != -1)
llvm_report_error("Nested variants found in inline asm string: '"
+ std::string(AsmStr) + "'");
- }
CurVariant = 0; // We're in the first variant now.
break;
case '|':
@@ -273,7 +272,7 @@ void AsmPrinter::EmitInlineAsm(const MachineInstr *MI) const {
OS << *MI->getOperand(OpNo).getMBB()->getSymbol();
else {
AsmPrinter *AP = const_cast<AsmPrinter*>(this);
- if ((OpFlags & 7) == 4) {
+ if (InlineAsm::isMemKind(OpFlags)) {
Error = AP->PrintAsmMemoryOperand(MI, OpNo, AsmPrinterVariant,
Modifier[0] ? Modifier : 0,
OS);