diff options
author | Kevin Enderby <enderby@apple.com> | 2010-05-21 23:01:38 +0000 |
---|---|---|
committer | Kevin Enderby <enderby@apple.com> | 2010-05-21 23:01:38 +0000 |
commit | 9d31d79493be05ab9cbf5b7fb16b52e79712eff3 (patch) | |
tree | 8d76ff54a265f245a1f9ced772d482404e8809e2 | |
parent | 0df4a80e2063424929bbfaa61dd7973062218ad4 (diff) |
Added retl for 32-bit x86 and added retq for 64-bit x86.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104394 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/Target/X86/AsmParser/X86AsmParser.cpp | 2 | ||||
-rw-r--r-- | test/MC/AsmParser/X86/x86_32-new-encoder.s | 5 | ||||
-rw-r--r-- | test/MC/AsmParser/X86/x86_64-new-encoder.s | 5 |
3 files changed, 12 insertions, 0 deletions
diff --git a/lib/Target/X86/AsmParser/X86AsmParser.cpp b/lib/Target/X86/AsmParser/X86AsmParser.cpp index 479f4e43df..7ce39ef423 100644 --- a/lib/Target/X86/AsmParser/X86AsmParser.cpp +++ b/lib/Target/X86/AsmParser/X86AsmParser.cpp @@ -584,6 +584,8 @@ ParseInstruction(const StringRef &Name, SMLoc NameLoc, .Case("repnz", "repne") .Case("pushf", Is64Bit ? "pushfq" : "pushfl") .Case("popf", Is64Bit ? "popfq" : "popfl") + .Case("retl", Is64Bit ? "retl" : "ret") + .Case("retq", Is64Bit ? "ret" : "retq") .Default(Name); Operands.push_back(X86Operand::CreateToken(PatchedName, NameLoc)); diff --git a/test/MC/AsmParser/X86/x86_32-new-encoder.s b/test/MC/AsmParser/X86/x86_32-new-encoder.s index 1c02f8823a..9d0fd6d06c 100644 --- a/test/MC/AsmParser/X86/x86_32-new-encoder.s +++ b/test/MC/AsmParser/X86/x86_32-new-encoder.s @@ -84,3 +84,8 @@ int $255 popf // CHECK: popfl # encoding: [0x9d] popfl + +// rdar://8014869 +retl +// CHECK: ret +// CHECK: encoding: [0xc3] diff --git a/test/MC/AsmParser/X86/x86_64-new-encoder.s b/test/MC/AsmParser/X86/x86_64-new-encoder.s index 589c719158..8ecb91b691 100644 --- a/test/MC/AsmParser/X86/x86_64-new-encoder.s +++ b/test/MC/AsmParser/X86/x86_64-new-encoder.s @@ -104,3 +104,8 @@ movl 0, %eax // CHECK: movl 0, %eax # encoding: [0x8b,0x04,0x25,A,A,A,A] // CHECK: movq $10, %rax // CHECK: encoding: [0x48,0xc7,0xc0,0x0a,0x00,0x00,0x00] movq $10, %rax + +// rdar://8014869 +retq +// CHECK: ret +// CHECK: encoding: [0xc3] |