[llvm] r247417 - [mips] Add missing MIPS-IV disassembler tests.
Daniel Sanders via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 11 07:54:59 PDT 2015
Author: dsanders
Date: Fri Sep 11 09:54:58 2015
New Revision: 247417
URL: http://llvm.org/viewvc/llvm-project?rev=247417&view=rev
Log:
[mips] Add missing MIPS-IV disassembler tests.
Added:
llvm/trunk/test/MC/Disassembler/Mips/mips4/invalid-xfail.txt
llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-xfail.txt
Modified:
llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-mips4.txt
Added: llvm/trunk/test/MC/Disassembler/Mips/mips4/invalid-xfail.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/Disassembler/Mips/mips4/invalid-xfail.txt?rev=247417&view=auto
==============================================================================
--- llvm/trunk/test/MC/Disassembler/Mips/mips4/invalid-xfail.txt (added)
+++ llvm/trunk/test/MC/Disassembler/Mips/mips4/invalid-xfail.txt Fri Sep 11 09:54:58 2015
@@ -0,0 +1,13 @@
+# RUN: llvm-mc %s -triple=mips-unknown-linux -disassemble -mcpu=mips4 | FileCheck %s
+# XFAIL: *
+
+# Start with a valid instruction. Otherwise llvm-mc gives up immediately.
+0x00 0x00 0x00 0x00
+
+# CHECK: .text
+0x45 0x06 0x00 0x82 # bc1fl $fcc1, 520 # CHECK: :[[@LINE]]:1: warning: invalid instruction encoding
+0x45 0x07 0xd8 0x01 # bc1tl $fcc1, -40956 # CHECK: :[[@LINE]]:1: warning: invalid instruction encoding
+0x45 0x08 0x14 0x02 # bc1f $fcc2, 20488 # CHECK: :[[@LINE]]:1: warning: invalid instruction encoding
+0x45 0x09 0x01 0x01 # bc1t $fcc2, 1028 # CHECK: :[[@LINE]]:1: warning: invalid instruction encoding
+0x48 0x00 0x00 0x01 # mfc2 $zero, $0, 1 # CHECK: :[[@LINE]]:1: warning: invalid instruction encoding
+0x48 0x86 0x00 0x04 # mtc2 $6, $0, 4 # CHECK: :[[@LINE]]:1: warning: invalid instruction encoding
Modified: llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-mips4.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-mips4.txt?rev=247417&r1=247416&r2=247417&view=diff
==============================================================================
--- llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-mips4.txt (original)
+++ llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-mips4.txt Fri Sep 11 09:54:58 2015
@@ -1,12 +1,19 @@
# RUN: llvm-mc %s -triple=mips64-unknown-linux -disassemble -mcpu=mips4 | FileCheck %s
# CHECK: .text
0x00 0x00 0x00 0x00 # CHECK: nop
+0x00 0x00 0x00 0x09 # CHECK: jr $zero
+0x00 0x00 0x00 0x0c # CHECK: syscall
+0x00 0x00 0x00 0x0d # CHECK: break
+0x00 0x00 0x00 0x20 # CHECK: add $zero, $zero, $zero
0x00 0x00 0x00 0x40 # CHECK: ssnop
+0x00 0x00 0x00 0x80 # CHECK: sll $zero, $zero, 2
0x00 0x00 0x00 0xc0 # CHECK: ehb
0x00 0x00 0x04 0xb8 # CHECK: dsll $zero, $zero, 18
0x00 0x00 0x04 0xbc # CHECK: dsll32 $zero, $zero, 18
0x00 0x00 0x04 0xbc # CHECK: dsll32 $zero, $zero, 18
+0x00 0x00 0x28 0x09 # CHECK: jalr $5, $zero
0x00 0x00 0x3c 0x80 # CHECK: sll $7, $zero, 18
+0x00 0x00 0x72 0x0d # CHECK: break 0, 456
0x00 0x00 0x88 0x12 # CHECK: mflo $17
0x00 0x00 0x98 0x10 # CHECK: mfhi $19
0x00 0x00 0xe8 0x10 # CHECK: mfhi $sp
@@ -21,6 +28,8 @@
0x00 0x06 0x9d 0xfe # CHECK: dsrl32 $19, $6, 23
0x00 0x07 0x38 0x27 # CHECK: nor $7, $zero, $7
0x00 0x07 0x3c 0x80 # CHECK: sll $7, $7, 18
+0x00 0x08 0xe8 0x22 # CHECK: neg $sp, $8
+0x00 0x10 0x00 0x80 # CHECK: sll $zero, $16, 2
0x00 0x11 0x8b 0xc3 # CHECK: sra $17, $17, 15
0x00 0x12 0xe2 0xbb # CHECK: dsra $gp, $18, 10
0x00 0x12 0xe2 0xbf # CHECK: dsra32 $gp, $18, 10
@@ -30,6 +39,7 @@
0x00 0x17 0x8b 0xc3 # CHECK: sra $17, $23, 15
0x00 0x1c 0xe2 0xbb # CHECK: dsra $gp, $gp, 10
0x00 0x1c 0xe2 0xbf # CHECK: dsra32 $gp, $gp, 10
+0x00 0x3a 0x3a 0xcc # CHECK: syscall 59627
0x00 0x3f 0x98 0x2c # CHECK: dadd $19, $1, $ra
0x00 0x3f 0x98 0x2d # CHECK: daddu $19, $1, $ra
0x00 0x4c 0xb8 0x24 # CHECK: and $23, $2, $12
@@ -47,6 +57,7 @@
0x00 0xba 0x28 0x2f # CHECK: dsubu $5, $5, $26
0x00 0xc0 0xc8 0x21 # CHECK: move $25, $6
0x00 0xc0 0xc8 0x25 # CHECK: move $25, $6
+0x00 0xc0 0xc8 0x27 # CHECK: not $25, $6
0x00 0xc0 0xc8 0x2d # CHECK: move $25, $6
0x00 0xd1 0x00 0x36 # CHECK: tne $6, $17
0x00 0xe8 0xdd 0x76 # CHECK: tne $7, $8, 885
@@ -64,6 +75,7 @@
0x02 0x1d 0x60 0x25 # CHECK: or $12, $16, $sp
0x02 0x1d 0xfe 0x33 # CHECK: tltu $16, $sp, 1016
0x02 0x20 0x00 0x11 # CHECK: mthi $17
+0x02 0x27 0x00 0x0d # CHECK: break 551
0x02 0x30 0x18 0x0b # CHECK: movn $3, $17, $16
0x02 0x45 0xb8 0x20 # CHECK: add $23, $18, $5
0x02 0x6c 0xb0 0x22 # CHECK: sub $22, $19, $12
@@ -89,9 +101,11 @@
0x03 0xb4 0x00 0x18 # CHECK: mult $sp, $20
0x03 0xb7 0x88 0x07 # CHECK: srav $17, $23, $sp
0x03 0xb7 0x88 0x07 # CHECK: srav $17, $23, $sp
+0x03 0xcd 0x23 0xcd # CHECK: break 973, 143
0x04 0x11 0x14 0x9b # CHECK: bal 21104
0x04 0x83 0xf9 0x4d # CHECK: bgezl $4, -6856
0x04 0xd0 0x14 0x9b # CHECK: bltzal $6, 21104
+0x04 0xd1 0x14 0x9b # CHECK: bgezal $6, 21104
0x04 0xd2 0x00 0x7a # CHECK: bltzall $6, 492
0x05 0x8e 0x8c 0x31 # CHECK: tnei $12, 35889
0x05 0x93 0x07 0x1f # CHECK: bgezall $12, 7296
@@ -101,6 +115,9 @@
0x06 0xac 0xbb 0xa0 # CHECK: teqi $21, 48032
0x07 0xa9 0x90 0x33 # CHECK: tgeiu $sp, 36915
0x07 0xeb 0xec 0x2c # CHECK: tltiu $ra, 60460
+0x08 0x00 0x00 0x01 # CHECK: j 4
+0x09 0x33 0x00 0x2a # CHECK: j 80478376
+0x0b 0x2a 0xd1 0x44 # CHECK: j 212550928
0x21 0x08 0xff 0xfe # CHECK: addi $8, $8, -2
0x21 0x2d 0x66 0xd2 # CHECK: addi $13, $9, 26322
0x21 0xad 0xe6 0x90 # CHECK: addi $13, $13, -6512
@@ -114,7 +131,10 @@
0x2f 0x38 0xc3 0x55 # CHECK: sltiu $24, $25, -15531
0x2f 0x39 0xc3 0x55 # CHECK: sltiu $25, $25, -15531
0x30 0x42 0x00 0x04 # CHECK: andi $2, $2, 4
+0x34 0x42 0x00 0x00 # CHECK: ori $2, $2, 0
0x34 0x42 0x00 0x04 # CHECK: ori $2, $2, 4
+0x3a 0x00 0x27 0x12 # CHECK: xori $zero, $16, 10002
+0x3c 0x00 0x00 0x80 # CHECK: lui $zero, 128
0x42 0x00 0x00 0x01 # CHECK: tlbr
0x42 0x00 0x00 0x02 # CHECK: tlbwi
0x42 0x00 0x00 0x06 # CHECK: tlbwr
@@ -188,7 +208,10 @@
0x46 0x80 0x7d 0xa0 # CHECK: cvt.s.w $f22, $f15
0x46 0xa0 0x81 0x21 # CHECK: cvt.d.l $f4, $f16
0x46 0xa0 0xf3 0xe0 # CHECK: cvt.s.l $f15, $f30
+0x4c 0x20 0x01 0x01 # CHECK: ldxc1 $f4, $zero($1)
+0x4c 0x21 0x00 0x28 # CHECK: msub.s $f0, $f1, $f0, $f1
0x4d 0xca 0x58 0x09 # CHECK: sdxc1 $f11, $10($14)
+0x4e 0x20 0x3e 0xb9 # CHECK: nmsub.d $f26, $f17, $f7, $f0
0x4f 0x4c 0x98 0x08 # CHECK: swxc1 $f19, $12($26)
0x4f 0xd1 0x03 0x00 # CHECK: lwxc1 $f12, $17($fp)
0x51 0xd3 0x0c 0x40 # CHECK: beql $14, $19, 12548
@@ -218,9 +241,11 @@
0xb5 0x8b 0xb0 0x39 # CHECK: sdr $11, -20423($12)
0xb9 0xd1 0x98 0x22 # CHECK: swr $17, -26590($14)
0xbc 0xa1 0x00 0x08 # CHECK: cache 1, 8($5)
+0xbf 0x00 0xe2 0x1c # CHECK: cache 0, -7652($24)
0xc2 0x42 0xe3 0x67 # CHECK: ll $2, -7321($18)
0xc7 0x50 0x27 0xf1 # CHECK: lwc1 $f16, 10225($26)
0xc8 0xd2 0xfc 0xb7 # CHECK: lwc2 $18, -841($6)
+0xcc 0x20 0x00 0x00 # CHECK: pref 0, 0($1)
0xcc 0xa1 0x00 0x08 # CHECK: pref 1, 8($5)
0xd6 0x0a 0x40 0x07 # CHECK: ldc1 $f10, 16391($16)
0xd8 0x28 0xad 0x43 # CHECK: ldc2 $8, -21181($1)
Added: llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-xfail.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-xfail.txt?rev=247417&view=auto
==============================================================================
--- llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-xfail.txt (added)
+++ llvm/trunk/test/MC/Disassembler/Mips/mips4/valid-xfail.txt Fri Sep 11 09:54:58 2015
@@ -0,0 +1,16 @@
+# RUN: llvm-mc %s -triple=mips-unknown-linux -disassemble -mcpu=mips4 | FileCheck %s
+# XFAIL: *
+0x10 0x00 0x00 0x02 # CHECK: b 8
+0x10 0x00 0x00 0x05 # CHECK: b 20
+0x10 0x00 0x28 0x09 # CHECK: b 40996
+0x10 0x04 0x14 0xe1 # CHECK: beq $zero, $4, 21380
+0x11 0x00 0x00 0xc3 # CHECK: beqz $8, 780
+0x12 0x88 0x00 0x16 # CHECK: beq $20, $8, 88
+0x15 0x00 0x88 0x13 # CHECK: bnez $8, -122804
+0x15 0x8a 0x9f 0x89 # CHECK: bne $12, $10, -98780
+0x50 0x27 0xc7 0xf2 # CHECK: beql $1, $7, -57400
+0x50 0xc7 0x07 0xf2 # CHECK: beql $6, $7, 8136
+0x53 0x2a 0x02 0x1e # CHECK: beql $25, $10, 2168
+0x53 0x80 0x21 0x73 # CHECK: beql $gp, $zero, 34252
+0xc2 0x44 0xe3 0x67 # CHECK: lwc0 $4, -7321($18)
+0xe2 0x64 0x49 0xd8 # CHECK: swc0 $4, 18904($19)
More information about the llvm-commits
mailing list