diff options
author | Kevin Enderby <enderby@apple.com> | 2010-12-08 23:57:59 +0000 |
---|---|---|
committer | Kevin Enderby <enderby@apple.com> | 2010-12-08 23:57:59 +0000 |
commit | 87bc591fc50c66bc9304bba61610dcb637c7e44e (patch) | |
tree | 5342e3456e37ad547c0d77a0e7864b49b9d21af2 | |
parent | 8c5f0c3115d3066bf35b5e0c2456356d8dbb6c07 (diff) | |
download | bcm5719-llvm-87bc591fc50c66bc9304bba61610dcb637c7e44e.tar.gz bcm5719-llvm-87bc591fc50c66bc9304bba61610dcb637c7e44e.zip |
Allow a slash, '/', as a prefix separator for X86. rdar://8741045
llvm-svn: 121320
-rw-r--r-- | llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp | 2 | ||||
-rw-r--r-- | llvm/test/MC/X86/x86-64.s | 5 |
2 files changed, 7 insertions, 0 deletions
diff --git a/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp b/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp index 1064effbbc6..b3f3dbbedd0 100644 --- a/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp +++ b/llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp @@ -758,6 +758,8 @@ ParseInstruction(StringRef Name, SMLoc NameLoc, if (getLexer().is(AsmToken::EndOfStatement)) Parser.Lex(); // Consume the EndOfStatement + else if (isPrefix && getLexer().is(AsmToken::Slash)) + Parser.Lex(); // Consume the prefix separator Slash // This is a terrible hack to handle "out[bwl]? %al, (%dx)" -> // "outb %al, %dx". Out doesn't take a memory form, but this is a widely diff --git a/llvm/test/MC/X86/x86-64.s b/llvm/test/MC/X86/x86-64.s index 17f00faafc0..a285c6f6456 100644 --- a/llvm/test/MC/X86/x86-64.s +++ b/llvm/test/MC/X86/x86-64.s @@ -738,6 +738,11 @@ lock incl 1(%rsp) // CHECK: lock // CHECK: incl 1(%rsp) +// rdar://8741045 +lock/incl 1(%rsp) +// CHECK: lock +// CHECK: incl 1(%rsp) + // rdar://8033482 rep movsl // CHECK: rep |