From a674463aac1d0b5d039da11045ccfab5e849b886 Mon Sep 17 00:00:00 2001 From: Vladimir Medic Date: Fri, 6 Sep 2013 12:30:36 +0000 Subject: This patch adds support for microMIPS disassembler and disassembler make check tests. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190144 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/MC/Disassembler/Mips/micromips_le.txt | 149 +++++++++++++++++++++++++++++ 1 file changed, 149 insertions(+) create mode 100644 test/MC/Disassembler/Mips/micromips_le.txt (limited to 'test/MC/Disassembler/Mips/micromips_le.txt') diff --git a/test/MC/Disassembler/Mips/micromips_le.txt b/test/MC/Disassembler/Mips/micromips_le.txt new file mode 100644 index 0000000..bcefeb4 --- /dev/null +++ b/test/MC/Disassembler/Mips/micromips_le.txt @@ -0,0 +1,149 @@ +# RUN: llvm-mc --disassemble %s -triple=mipsel-unknown-linux -mattr=micromips \ +# RUN: | FileCheck %s + +# CHECK: add $9, $6, $7 +0xe6 0x00 0x10 0x49 + +# CHECK: addi $9, $6, 17767 +0x26 0x11 0x67 0x45 + +# CHECK: addiu $9, $6, -15001 +0x26 0x31 0x67 0xc5 + +# CHECK: addi $9, $6, 17767 +0x26 0x11 0x67 0x45 + +# CHECK: addiu $9, $6, -15001 +0x26 0x31 0x67 0xc5 + +# CHECK: addu $9, $6, $7 +0xe6 0x00 0x50 0x49 + +# CHECK: sub $9, $6, $7 +0xe6 0x00 0x90 0x49 + +# CHECK: subu $4, $3, $5 +0xa3 0x00 0xd0 0x21 + +# CHECK: sub $6, $zero, $7 +0xe0 0x00 0x90 0x31 + +# CHECK: subu $6, $zero, $7 +0xe0 0x00 0xd0 0x31 + +# CHECK: addu $7, $8, $zero +0x08 0x00 0x50 0x39 + +# CHECK: slt $3, $3, $5 +0xa3 0x00 0x50 0x1b + +# CHECK: slti $3, $3, 103 +0x63 0x90 0x67 0x00 + +# CHECK: slti $3, $3, 103 +0x63 0x90 0x67 0x00 + +# CHECK: sltiu $3, $3, 103 +0x63 0xb0 0x67 0x00 + +# CHECK: sltu $3, $3, $5 +0xa3 0x00 0x90 0x1b + +# CHECK: and $9, $6, $7 +0xe6 0x00 0x50 0x4a + +# CHECK: andi $9, $6, 17767 +0x26 0xd1 0x67 0x45 + +# CHECK: andi $9, $6, 17767 +0x26 0xd1 0x67 0x45 + +# CHECK: or $3, $4, $5 +0xa4 0x00 0x90 0x1a + +# CHECK: ori $9, $6, 17767 +0x26 0x51 0x67 0x45 + +# CHECK: xor $3, $3, $5 +0xa3 0x00 0x10 0x1b + +# CHECK: xori $9, $6, 17767 +0x26 0x71 0x67 0x45 + +# CHECK: xori $9, $6, 17767 +0x26 0x71 0x67 0x45 + +# CHECK: nor $9, $6, $7 +0xe6 0x00 0xd0 0x4a + +# CHECK: not $7, $8 +0x08 0x00 0xd0 0x3a + +# CHECK: mul $9, $6, $7 +0xe6 0x00 0x10 0x4a + +# CHECK: mult $9, $7 +0xe9 0x00 0x3c 0x8b + +# CHECK: multu $9, $7 +0xe9 0x00 0x3c 0x9b + +# CHECK: sll $4, $3, 7 +0x83 0x00 0x00 0x38 + +# CHECK: sllv $2, $3, $5 +0x65 0x00 0x10 0x10 + +# CHECK: sra $4, $3, 7 +0x83 0x00 0x80 0x38 + +# CHECK: srav $2, $3, $5 +0x65 0x00 0x90 0x10 + +# CHECK: srl $4, $3, 7 +0x83 0x00 0x40 0x38 + +# CHECK: srlv $2, $3, $5 +0x65 0x00 0x50 0x10 + +# CHECK: rotr $9, $6, 7 +0x26 0x01 0xc0 0x38 + +# CHECK: rotrv $9, $6, $7 +0xc7 0x00 0xd0 0x48 + +# CHECK: lb $5, 8($4) +0xa4 0x1c 0x08 0x00 + +# CHECK: lbu $6, 8($4) +0xc4 0x14 0x08 0x00 + +# CHECK: lh $2, 8($4) +0x44 0x3c 0x08 0x00 + +# CHECK: lhu $4, 8($2) +0x82 0x34 0x08 0x00 + +# CHECK: lw $6, 4($5) +0xc5 0xfc 0x04 0x00 + +# CHECK: sb $5, 8($4) +0xa4 0x18 0x08 0x00 + +# CHECK: sh $2, 8($4) +0x44 0x38 0x08 0x00 + +# CHECK: sw $5, 4($6) +0xa6 0xf8 0x04 0x00 + +# CHECK: lwl $4, 16($5) +0x85 0x60 0x10 0x00 + +# CHECK: lwr $4, 16($5) +0x85 0x60 0x10 0x10 + +# CHECK: swl $4, 16($5) +0x85 0x60 0x10 0x80 + +# CHECK: swr $4, 16($5) +0x85 0x60 0x10 0x90 -- cgit v1.1