2010-04-02 22:27:38 +00:00
|
|
|
# RUN: llvm-mc --disassemble %s -triple=arm-apple-darwin9 | FileCheck %s
|
|
|
|
|
2011-03-24 20:42:48 +00:00
|
|
|
# CHECK: addpl r4, pc, #19, 8
|
|
|
|
0x4c 0x45 0x8f 0x52
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: b #0
|
2011-03-15 22:27:33 +00:00
|
|
|
0x00 0x00 0x00 0xea
|
|
|
|
|
|
|
|
# CHECK: bl #7732
|
|
|
|
0x8d 0x07 0x00 0xeb
|
|
|
|
|
|
|
|
# CHECK: bleq #-4
|
|
|
|
0xff 0xff 0xff 0x0b
|
2010-04-02 22:27:38 +00:00
|
|
|
|
|
|
|
# CHECK: bfc r8, #0, #16
|
|
|
|
0x1f 0x80 0xcf 0xe7
|
|
|
|
|
|
|
|
# CHECK: bfi r8, r0, #16, #1
|
|
|
|
0x10 0x88 0xd0 0xe7
|
|
|
|
|
2011-01-28 17:50:30 +00:00
|
|
|
# CHECK: mov pc, lr
|
|
|
|
0x0e 0xf0 0xa0 0xe1
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: cmn r0, #1
|
|
|
|
0x01 0x00 0x70 0xe3
|
|
|
|
|
2010-08-11 23:35:12 +00:00
|
|
|
# CHECK: dmb
|
|
|
|
0x5f 0xf0 0x7f 0xf5
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: dmb nshst
|
|
|
|
0x56 0xf0 0x7f 0xf5
|
|
|
|
|
2010-08-11 23:35:12 +00:00
|
|
|
# CHECK: dsb
|
|
|
|
0x4f 0xf0 0x7f 0xf5
|
|
|
|
|
2010-08-12 20:46:17 +00:00
|
|
|
# CHECK: dsb st
|
|
|
|
0x4e 0xf0 0x7f 0xf5
|
|
|
|
|
|
|
|
# CHECK: isb
|
|
|
|
0x6f 0xf0 0x7f 0xf5
|
|
|
|
|
2010-04-16 19:33:23 +00:00
|
|
|
# CHECK: ldclvc p5, cr15, [r8], #-0
|
|
|
|
0x00 0xf5 0x78 0x7c
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: ldr r0, [r2], #15
|
|
|
|
0x0f 0x00 0x92 0xe4
|
|
|
|
|
2010-04-16 19:57:21 +00:00
|
|
|
# CHECK: ldrh r0, [r2], #0
|
|
|
|
0xb0 0x00 0xd2 0xe0
|
|
|
|
|
2010-04-15 23:23:40 +00:00
|
|
|
# CHECK: ldrht r0, [r2], #15
|
|
|
|
0xbf 0x00 0xf2 0xe0
|
|
|
|
|
2010-04-15 23:12:47 +00:00
|
|
|
# CHECK: ldrsbtvs lr, [r2], -r9
|
|
|
|
0xd9 0xe9 0x32 0x60
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: lsls r0, r2, #31
|
|
|
|
0x82 0x0f 0xb0 0xe1
|
|
|
|
|
2011-01-13 22:38:16 +00:00
|
|
|
# CHECK: mcr2 p0, #0, r2, c1, c0, #7
|
2010-04-02 22:27:38 +00:00
|
|
|
0xf0 0x20 0x01 0xfe
|
|
|
|
|
|
|
|
# CHECK: movt r8, #65535
|
|
|
|
0xff 0x8f 0x4f 0xe3
|
|
|
|
|
2010-10-15 03:23:44 +00:00
|
|
|
# CHECK: mvnspl r7, #245, 2
|
Fixed a crasher in arm disassembler within ARMInstPrinter.cpp after calling
ARM_AM::getSoImmVal(V) with a legitimate so_imm value: #245 rotate right by 2.
Introduce ARM_AM::getSOImmValOneOrNoRotate(unsigned Arg) which is called from
ARMInstPrinter.cpp's printSOImm() function, replacing ARM_AM::getSOImmVal(V).
[12:44:43] johnny:/Volumes/data/llvm/git/trunk (local-trunk) $ gdb Debug/bin/llvm-mc
GNU gdb 6.3.50-20050815 (Apple version gdb-1346) (Fri Sep 18 20:40:51 UTC 2009)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "x86_64-apple-darwin"...Reading symbols for shared libraries ... done
(gdb) set args -triple=arm-apple-darwin9 -debug-only=arm-disassembler --disassemble
(gdb) r
Starting program: /Volumes/data/llvm/git/trunk/Debug/bin/llvm-mc -triple=arm-apple-darwin9 -debug-only=arm-disassembler --disassemble
Reading symbols for shared libraries ++. done
0xf5 0x71 0xf0 0x53
Opcode=201 Name=MVNi Format=ARM_FORMAT_DPFRM(4)
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
-------------------------------------------------------------------------------------------------
| 0: 1: 0: 1| 0: 0: 1: 1| 1: 1: 1: 1| 0: 0: 0: 0| 0: 1: 1: 1| 0: 0: 0: 1| 1: 1: 1: 1| 0: 1: 0: 1|
-------------------------------------------------------------------------------------------------
mvnpls r7, Assertion failed: (V != -1 && "Not a valid so_imm value!"), function printSOImm, file ARMInstPrinter.cpp, line 229.
Program received signal SIGABRT, Aborted.
0x00007fff88c65886 in __kill ()
(gdb) bt
#0 0x00007fff88c65886 in __kill ()
#1 0x00007fff88d05eae in abort ()
#2 0x00007fff88cf2ef0 in __assert_rtn ()
#3 0x000000010020e422 in printSOImm (O=@0x1010bdf80, V=-1, VerboseAsm=false, MAI=0x1020106d0) at ARMInstPrinter.cpp:229
#4 0x000000010020e5fe in llvm::ARMInstPrinter::printSOImmOperand (this=0x1020107e0, MI=0x7fff5fbfee70, OpNum=1, O=@0x1010bdf80) at ARMInstPrinter.cpp:254
#5 0x00000001001ffbc0 in llvm::ARMInstPrinter::printInstruction (this=0x1020107e0, MI=0x7fff5fbfee70, O=@0x1010bdf80) at ARMGenAsmWriter.inc:3236
#6 0x000000010020c27c in llvm::ARMInstPrinter::printInst (this=0x1020107e0, MI=0x7fff5fbfee70, O=@0x1010bdf80) at ARMInstPrinter.cpp:182
#7 0x000000010003cbff in PrintInsts (DisAsm=@0x10200f4e0, Printer=@0x1020107e0, Bytes=@0x7fff5fbff060, SM=@0x7fff5fbff078) at Disassembler.cpp:65
#8 0x000000010003c8b4 in llvm::Disassembler::disassemble (T=@0x1010c13c0, Triple=@0x1010b6798, Buffer=@0x102010690) at Disassembler.cpp:153
#9 0x000000010004095c in DisassembleInput (ProgName=0x7fff5fbff3f0 "/Volumes/data/llvm/git/trunk/Debug/bin/llvm-mc") at llvm-mc.cpp:347
#10 0x000000010003eefb in main (argc=4, argv=0x7fff5fbff298) at llvm-mc.cpp:374
(gdb) q
The program is running. Exit anyway? (y or n) y
[13:36:26] johnny:/Volumes/data/llvm/git/trunk (local-trunk) $
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101053 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-12 18:46:53 +00:00
|
|
|
0xf5 0x71 0xf0 0x53
|
|
|
|
|
2010-08-05 00:34:42 +00:00
|
|
|
# CHECK-NOT: orr r7, r8, r7, rrx #0
|
|
|
|
# CHECK: orr r7, r8, r7, rrx
|
|
|
|
0x67 0x70 0x88 0xe1
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: pkhbt r8, r9, r10, lsl #4
|
|
|
|
0x1a 0x82 0x89 0xe6
|
|
|
|
|
2010-08-17 17:23:19 +00:00
|
|
|
# CHECK-NOT: pkhbtls pc, r11, r11, lsl #0
|
|
|
|
# CHECK: pkhbtls pc, r11, r11
|
|
|
|
0x1b 0xf0 0x8b 0x96
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: pop {r0, r2, r4, r6, r8, r10}
|
|
|
|
0x55 0x05 0xbd 0xe8
|
|
|
|
|
|
|
|
# CHECK: push {r0, r2, r4, r6, r8, r10}
|
|
|
|
0x55 0x05 0x2d 0xe9
|
|
|
|
|
|
|
|
# CHECK: qsax r8, r9, r10
|
|
|
|
0x5a 0x8f 0x29 0xe6
|
|
|
|
|
|
|
|
# CHECK: rfedb r0!
|
|
|
|
0x00 0x0a 0x30 0xf9
|
|
|
|
|
2010-08-05 18:23:43 +00:00
|
|
|
# CHECK-NOT: rsbeq r0, r2, r0, lsl #0
|
|
|
|
# CHECK: rsbeq r0, r2, r0
|
|
|
|
0x00 0x00 0x62 0x00
|
|
|
|
|
2010-10-15 03:23:44 +00:00
|
|
|
# CHECK-NOT: rscseq r0, r0, r1, lsl #0
|
|
|
|
# CHECK: rscseq r0, r0, r1
|
2010-08-05 18:59:36 +00:00
|
|
|
0x01 0x00 0xf0 0x00
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: sbcs r0, pc, #1
|
|
|
|
0x01 0x00 0xdf 0xe2
|
|
|
|
|
|
|
|
# CHECK: sbfx r0, r1, #0, #8
|
|
|
|
0x51 0x00 0xa7 0xe7
|
|
|
|
|
|
|
|
# CHECK: ssat r8, #1, r10, lsl #8
|
|
|
|
0x1a 0x84 0xa0 0xe6
|
|
|
|
|
2010-08-11 23:10:46 +00:00
|
|
|
# CHECK-NOT: ssatmi r0, #17, r12, lsl #0
|
|
|
|
# CHECK: ssatmi r0, #17, r12
|
|
|
|
0x1c 0x00 0xb0 0x46
|
|
|
|
|
2010-04-02 22:27:38 +00:00
|
|
|
# CHECK: stmdb r10!, {r4, r5, r6, r7, lr}
|
|
|
|
0xf0 0x40 0x2a 0xe9
|
|
|
|
|
|
|
|
# CHECK: teq r0, #31
|
|
|
|
0x1f 0x00 0x30 0xe3
|
|
|
|
|
|
|
|
# CHECK: ubfx r0, r0, #16, #1
|
|
|
|
0x50 0x08 0xe0 0xe7
|
|
|
|
|
2010-08-12 01:40:54 +00:00
|
|
|
# CHECK: usat r8, #0, r10, asr #32
|
|
|
|
0x5a 0x80 0xe0 0xe6
|
2010-10-13 21:00:04 +00:00
|
|
|
|
|
|
|
# CHECK: setend be
|
|
|
|
0x00 0x02 0x01 0xf1
|
|
|
|
|
|
|
|
# CHECK: setend le
|
|
|
|
0x00 0x00 0x01 0xf1
|
2011-02-14 13:09:44 +00:00
|
|
|
|
|
|
|
# CHECK: cpsie aif
|
|
|
|
0xc0 0x01 0x08 0xf1
|
|
|
|
|
|
|
|
# CHECK: cps #15
|
|
|
|
0x0f 0x00 0x02 0xf1
|
|
|
|
|
|
|
|
# CHECK: cpsie if, #10
|
|
|
|
0xca 0x00 0x0a 0xf1
|
2011-02-18 19:45:59 +00:00
|
|
|
|
|
|
|
# CHECK: msr cpsr_fc, r0
|
|
|
|
0x00 0xf0 0x29 0xe1
|
2011-03-02 23:08:33 +00:00
|
|
|
|
|
|
|
# CHECK: rsbs r6, r7, r8
|
|
|
|
0x08 0x60 0x77 0xe0
|
2011-03-03 01:41:01 +00:00
|
|
|
|
|
|
|
# CHECK: blxeq r5
|
|
|
|
0x35 0xff 0x2f 0x01
|
2011-03-03 07:19:52 +00:00
|
|
|
|
|
|
|
# CHECK: bx r12
|
|
|
|
0x1c 0xff 0x2f 0xe1
|
2011-03-09 20:01:14 +00:00
|
|
|
|
|
|
|
# CHECK: uqadd16mi r6, r11, r8
|
|
|
|
0x18 0x60 0x6b 0x46
|
2011-03-15 01:13:17 +00:00
|
|
|
|
|
|
|
# CHECK: str r0, [sp, #4]
|
|
|
|
0x04 0x00 0x8d 0xe5
|
|
|
|
|
|
|
|
# CHECK: str r1, [sp]
|
|
|
|
0x00 0x10 0x8d 0xe5
|
|
|
|
|
|
|
|
# CHECK: ldr r3, [pc, #144]
|
|
|
|
0x90 0x30 0x9f 0xe5
|
|
|
|
|
|
|
|
# CHECK: strdeq r2, r3, [r0], -r8
|
|
|
|
0xf8 0x24 0x00 0x00
|
2011-03-19 01:16:20 +00:00
|
|
|
|
|
|
|
# CHECK: ldrdeq r2, [r0], -r12
|
|
|
|
0xdc 0x24 0x00 0x00
|
2011-03-22 22:28:49 +00:00
|
|
|
|
|
|
|
# CHECK: ldrbt r3, [r4], -r5, lsl #12
|
|
|
|
0x05 0x36 0x74 0xe6
|
2011-03-22 23:08:56 +00:00
|
|
|
|
|
|
|
# CHECK: vcmpe.f64 d8, #0
|
|
|
|
0xc0 0x8b 0xb5 0xee
|
2011-03-24 00:28:38 +00:00
|
|
|
|
2011-03-24 01:07:26 +00:00
|
|
|
# CHECK: strtvc r5, [r3], r0, lsr #20
|
|
|
|
0x30 0x5a 0xa3 0x76
|
2011-03-24 01:40:42 +00:00
|
|
|
|
|
|
|
# CHECK: stmiblo sp, {r0, r4, r8, r11, r12, pc}
|
|
|
|
0x11 0x99 0x8d 0x39
|
|
|
|
|
|
|
|
# CHECK: ldmdb sp, {r0, r4, r8, r11, r12, pc}
|
|
|
|
0x11 0x99 0x1d 0xe9
|
2011-03-25 17:31:16 +00:00
|
|
|
|
|
|
|
# CHECK: swpge r3, r2, [r6]
|
|
|
|
0x92 0x30 0x06 0xa1
|
2011-03-25 23:02:58 +00:00
|
|
|
|
|
|
|
# CHECK: umull r1, r2, r3, r4
|
|
|
|
0x93 0x14 0x82 0xe0
|
2011-03-28 18:41:58 +00:00
|
|
|
|
|
|
|
# CHECK: pld [pc, #-0]
|
|
|
|
0x00 0xf0 0x1f 0xf5
|
|
|
|
|
|
|
|
# CHECK: pli [pc, #-0]
|
|
|
|
0x00 0xf0 0x5f 0xf4
|
|
|
|
|
|
|
|
# CHECK: pli [r3, r1, lsl #2]
|
|
|
|
0x01 0xf1 0xd3 0xf6
|