aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorKevin Enderby <enderby@apple.com>2010-05-03 20:45:05 +0000
committerKevin Enderby <enderby@apple.com>2010-05-03 20:45:05 +0000
commit3c979b06c041544b97b13c5adac1a91d6cde6582 (patch)
treec0f1edec0f5a24e5a24691945dbbc2c071faf5d9 /test
parent5f84c0293f2150ac0f8fab8b7fb14f87161c8bf2 (diff)
downloadexternal_llvm-3c979b06c041544b97b13c5adac1a91d6cde6582.zip
external_llvm-3c979b06c041544b97b13c5adac1a91d6cde6582.tar.gz
external_llvm-3c979b06c041544b97b13c5adac1a91d6cde6582.tar.bz2
Fixed the encoding of the x86 push instructions. Using a 32-bit immediate value
caused the a pushl instruction to be incorrectly encoding using only two bytes of immediate, causing the following 2 instruction bytes to be part of the 32-bit immediate value. Also fixed the one byte form of push to be used when the immediate would fit in a signed extended byte. Lastly changed the names to not include the 32 of PUSH32 since they actually push the size of the stack pointer. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102951 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/MC/AsmParser/X86/x86_32-encoding.s13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/MC/AsmParser/X86/x86_32-encoding.s b/test/MC/AsmParser/X86/x86_32-encoding.s
index b5472ca..475632c 100644
--- a/test/MC/AsmParser/X86/x86_32-encoding.s
+++ b/test/MC/AsmParser/X86/x86_32-encoding.s
@@ -9984,3 +9984,16 @@ pshufb CPI1_0(%rip), %xmm1
// CHECK: bsrw 305419896, %bx
// CHECK: encoding: [0x66,0x0f,0xbd,0x1d,0x78,0x56,0x34,0x12]
bsrw 305419896, %bx
+
+// radr://7901779
+// CHECK: pushl $127
+// CHECK: encoding: [0x6a,0xfe]
+ pushl $127
+
+// CHECK: pushw $254
+// CHECK: encoding: [0x66,0x68,0xfe,0x00]
+ pushw $254
+
+// CHECK: pushl $254
+// CHECK: encoding: [0x68,0xfe,0x00,0x00,0x00]
+ pushl $254