diff --git a/test/MC/SystemZ/insn-a-01.s b/test/MC/SystemZ/insn-a-01.s new file mode 100644 index 00000000000..7bb94b31ebe --- /dev/null +++ b/test/MC/SystemZ/insn-a-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: a %r0, 0 # encoding: [0x5a,0x00,0x00,0x00] +#CHECK: a %r0, 4095 # encoding: [0x5a,0x00,0x0f,0xff] +#CHECK: a %r0, 0(%r1) # encoding: [0x5a,0x00,0x10,0x00] +#CHECK: a %r0, 0(%r15) # encoding: [0x5a,0x00,0xf0,0x00] +#CHECK: a %r0, 4095(%r1,%r15) # encoding: [0x5a,0x01,0xff,0xff] +#CHECK: a %r0, 4095(%r15,%r1) # encoding: [0x5a,0x0f,0x1f,0xff] +#CHECK: a %r15, 0 # encoding: [0x5a,0xf0,0x00,0x00] + + a %r0, 0 + a %r0, 4095 + a %r0, 0(%r1) + a %r0, 0(%r15) + a %r0, 4095(%r1,%r15) + a %r0, 4095(%r15,%r1) + a %r15, 0 diff --git a/test/MC/SystemZ/insn-a-02.s b/test/MC/SystemZ/insn-a-02.s new file mode 100644 index 00000000000..9cc967e0cef --- /dev/null +++ b/test/MC/SystemZ/insn-a-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: a %r0, -1 +#CHECK: error: invalid operand +#CHECK: a %r0, 4096 + + a %r0, -1 + a %r0, 4096 diff --git a/test/MC/SystemZ/insn-adb-01.s b/test/MC/SystemZ/insn-adb-01.s new file mode 100644 index 00000000000..b54be60c6b5 --- /dev/null +++ b/test/MC/SystemZ/insn-adb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: adb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x1a] +#CHECK: adb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x1a] +#CHECK: adb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x1a] +#CHECK: adb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x1a] +#CHECK: adb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x1a] +#CHECK: adb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x1a] +#CHECK: adb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x1a] + + adb %f0, 0 + adb %f0, 4095 + adb %f0, 0(%r1) + adb %f0, 0(%r15) + adb %f0, 4095(%r1,%r15) + adb %f0, 4095(%r15,%r1) + adb %f15, 0 diff --git a/test/MC/SystemZ/insn-adb-02.s b/test/MC/SystemZ/insn-adb-02.s new file mode 100644 index 00000000000..ff97a51affa --- /dev/null +++ b/test/MC/SystemZ/insn-adb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: adb %f0, -1 +#CHECK: error: invalid operand +#CHECK: adb %f0, 4096 + + adb %f0, -1 + adb %f0, 4096 diff --git a/test/MC/SystemZ/insn-adbr-01.s b/test/MC/SystemZ/insn-adbr-01.s new file mode 100644 index 00000000000..05724d2a6a8 --- /dev/null +++ b/test/MC/SystemZ/insn-adbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: adbr %f0, %f0 # encoding: [0xb3,0x1a,0x00,0x00] +#CHECK: adbr %f0, %f15 # encoding: [0xb3,0x1a,0x00,0x0f] +#CHECK: adbr %f7, %f8 # encoding: [0xb3,0x1a,0x00,0x78] +#CHECK: adbr %f15, %f0 # encoding: [0xb3,0x1a,0x00,0xf0] + + adbr %f0, %f0 + adbr %f0, %f15 + adbr %f7, %f8 + adbr %f15, %f0 diff --git a/test/MC/SystemZ/insn-aeb-01.s b/test/MC/SystemZ/insn-aeb-01.s new file mode 100644 index 00000000000..b4268e5c72b --- /dev/null +++ b/test/MC/SystemZ/insn-aeb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: aeb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x0a] +#CHECK: aeb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x0a] +#CHECK: aeb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x0a] +#CHECK: aeb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x0a] +#CHECK: aeb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x0a] +#CHECK: aeb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x0a] +#CHECK: aeb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x0a] + + aeb %f0, 0 + aeb %f0, 4095 + aeb %f0, 0(%r1) + aeb %f0, 0(%r15) + aeb %f0, 4095(%r1,%r15) + aeb %f0, 4095(%r15,%r1) + aeb %f15, 0 diff --git a/test/MC/SystemZ/insn-aeb-02.s b/test/MC/SystemZ/insn-aeb-02.s new file mode 100644 index 00000000000..4fade8ecebc --- /dev/null +++ b/test/MC/SystemZ/insn-aeb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: aeb %f0, -1 +#CHECK: error: invalid operand +#CHECK: aeb %f0, 4096 + + aeb %f0, -1 + aeb %f0, 4096 diff --git a/test/MC/SystemZ/insn-aebr-01.s b/test/MC/SystemZ/insn-aebr-01.s new file mode 100644 index 00000000000..2147627e389 --- /dev/null +++ b/test/MC/SystemZ/insn-aebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: aebr %f0, %f0 # encoding: [0xb3,0x0a,0x00,0x00] +#CHECK: aebr %f0, %f15 # encoding: [0xb3,0x0a,0x00,0x0f] +#CHECK: aebr %f7, %f8 # encoding: [0xb3,0x0a,0x00,0x78] +#CHECK: aebr %f15, %f0 # encoding: [0xb3,0x0a,0x00,0xf0] + + aebr %f0, %f0 + aebr %f0, %f15 + aebr %f7, %f8 + aebr %f15, %f0 diff --git a/test/MC/SystemZ/insn-afi-01.s b/test/MC/SystemZ/insn-afi-01.s new file mode 100644 index 00000000000..f9a911810ca --- /dev/null +++ b/test/MC/SystemZ/insn-afi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: afi %r0, -2147483648 # encoding: [0xc2,0x09,0x80,0x00,0x00,0x00] +#CHECK: afi %r0, -1 # encoding: [0xc2,0x09,0xff,0xff,0xff,0xff] +#CHECK: afi %r0, 0 # encoding: [0xc2,0x09,0x00,0x00,0x00,0x00] +#CHECK: afi %r0, 1 # encoding: [0xc2,0x09,0x00,0x00,0x00,0x01] +#CHECK: afi %r0, 2147483647 # encoding: [0xc2,0x09,0x7f,0xff,0xff,0xff] +#CHECK: afi %r15, 0 # encoding: [0xc2,0xf9,0x00,0x00,0x00,0x00] + + afi %r0, -1 << 31 + afi %r0, -1 + afi %r0, 0 + afi %r0, 1 + afi %r0, (1 << 31) - 1 + afi %r15, 0 diff --git a/test/MC/SystemZ/insn-afi-02.s b/test/MC/SystemZ/insn-afi-02.s new file mode 100644 index 00000000000..f848e196a9a --- /dev/null +++ b/test/MC/SystemZ/insn-afi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: afi %r0, (-1 << 31) - 1 +#CHECK: error: invalid operand +#CHECK: afi %r0, (1 << 31) + + afi %r0, (-1 << 31) - 1 + afi %r0, (1 << 31) diff --git a/test/MC/SystemZ/insn-ag-01.s b/test/MC/SystemZ/insn-ag-01.s new file mode 100644 index 00000000000..63029d75e45 --- /dev/null +++ b/test/MC/SystemZ/insn-ag-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ag %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x08] +#CHECK: ag %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x08] +#CHECK: ag %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x08] +#CHECK: ag %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x08] +#CHECK: ag %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x08] +#CHECK: ag %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x08] +#CHECK: ag %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x08] +#CHECK: ag %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x08] +#CHECK: ag %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x08] +#CHECK: ag %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x08] + + ag %r0, -524288 + ag %r0, -1 + ag %r0, 0 + ag %r0, 1 + ag %r0, 524287 + ag %r0, 0(%r1) + ag %r0, 0(%r15) + ag %r0, 524287(%r1,%r15) + ag %r0, 524287(%r15,%r1) + ag %r15, 0 diff --git a/test/MC/SystemZ/insn-ag-02.s b/test/MC/SystemZ/insn-ag-02.s new file mode 100644 index 00000000000..59694cd7d5a --- /dev/null +++ b/test/MC/SystemZ/insn-ag-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ag %r0, -524289 +#CHECK: error: invalid operand +#CHECK: ag %r0, 524288 + + ag %r0, -524289 + ag %r0, 524288 diff --git a/test/MC/SystemZ/insn-agf-01.s b/test/MC/SystemZ/insn-agf-01.s new file mode 100644 index 00000000000..40a98583420 --- /dev/null +++ b/test/MC/SystemZ/insn-agf-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: agf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x18] +#CHECK: agf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x18] +#CHECK: agf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x18] +#CHECK: agf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x18] +#CHECK: agf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x18] +#CHECK: agf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x18] +#CHECK: agf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x18] +#CHECK: agf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x18] +#CHECK: agf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x18] +#CHECK: agf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x18] + + agf %r0, -524288 + agf %r0, -1 + agf %r0, 0 + agf %r0, 1 + agf %r0, 524287 + agf %r0, 0(%r1) + agf %r0, 0(%r15) + agf %r0, 524287(%r1,%r15) + agf %r0, 524287(%r15,%r1) + agf %r15, 0 diff --git a/test/MC/SystemZ/insn-agf-02.s b/test/MC/SystemZ/insn-agf-02.s new file mode 100644 index 00000000000..dee31dc1d54 --- /dev/null +++ b/test/MC/SystemZ/insn-agf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: agf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: agf %r0, 524288 + + agf %r0, -524289 + agf %r0, 524288 diff --git a/test/MC/SystemZ/insn-agfi-01.s b/test/MC/SystemZ/insn-agfi-01.s new file mode 100644 index 00000000000..a64721ddd1d --- /dev/null +++ b/test/MC/SystemZ/insn-agfi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: agfi %r0, -2147483648 # encoding: [0xc2,0x08,0x80,0x00,0x00,0x00] +#CHECK: agfi %r0, -1 # encoding: [0xc2,0x08,0xff,0xff,0xff,0xff] +#CHECK: agfi %r0, 0 # encoding: [0xc2,0x08,0x00,0x00,0x00,0x00] +#CHECK: agfi %r0, 1 # encoding: [0xc2,0x08,0x00,0x00,0x00,0x01] +#CHECK: agfi %r0, 2147483647 # encoding: [0xc2,0x08,0x7f,0xff,0xff,0xff] +#CHECK: agfi %r15, 0 # encoding: [0xc2,0xf8,0x00,0x00,0x00,0x00] + + agfi %r0, -1 << 31 + agfi %r0, -1 + agfi %r0, 0 + agfi %r0, 1 + agfi %r0, (1 << 31) - 1 + agfi %r15, 0 diff --git a/test/MC/SystemZ/insn-agfi-02.s b/test/MC/SystemZ/insn-agfi-02.s new file mode 100644 index 00000000000..1db3eaae0b6 --- /dev/null +++ b/test/MC/SystemZ/insn-agfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: agfi %r0, (-1 << 31) - 1 +#CHECK: error: invalid operand +#CHECK: agfi %r0, (1 << 31) + + agfi %r0, (-1 << 31) - 1 + agfi %r0, (1 << 31) diff --git a/test/MC/SystemZ/insn-agfr-01.s b/test/MC/SystemZ/insn-agfr-01.s new file mode 100644 index 00000000000..cd17db95f91 --- /dev/null +++ b/test/MC/SystemZ/insn-agfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: agfr %r0, %r0 # encoding: [0xb9,0x18,0x00,0x00] +#CHECK: agfr %r0, %r15 # encoding: [0xb9,0x18,0x00,0x0f] +#CHECK: agfr %r15, %r0 # encoding: [0xb9,0x18,0x00,0xf0] +#CHECK: agfr %r7, %r8 # encoding: [0xb9,0x18,0x00,0x78] + + agfr %r0,%r0 + agfr %r0,%r15 + agfr %r15,%r0 + agfr %r7,%r8 diff --git a/test/MC/SystemZ/insn-aghi-01.s b/test/MC/SystemZ/insn-aghi-01.s new file mode 100644 index 00000000000..cd77c355d24 --- /dev/null +++ b/test/MC/SystemZ/insn-aghi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: aghi %r0, -32768 # encoding: [0xa7,0x0b,0x80,0x00] +#CHECK: aghi %r0, -1 # encoding: [0xa7,0x0b,0xff,0xff] +#CHECK: aghi %r0, 0 # encoding: [0xa7,0x0b,0x00,0x00] +#CHECK: aghi %r0, 1 # encoding: [0xa7,0x0b,0x00,0x01] +#CHECK: aghi %r0, 32767 # encoding: [0xa7,0x0b,0x7f,0xff] +#CHECK: aghi %r15, 0 # encoding: [0xa7,0xfb,0x00,0x00] + + aghi %r0, -32768 + aghi %r0, -1 + aghi %r0, 0 + aghi %r0, 1 + aghi %r0, 32767 + aghi %r15, 0 diff --git a/test/MC/SystemZ/insn-aghi-02.s b/test/MC/SystemZ/insn-aghi-02.s new file mode 100644 index 00000000000..e2657c6869e --- /dev/null +++ b/test/MC/SystemZ/insn-aghi-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: aghi %r0, -32769 +#CHECK: error: invalid operand +#CHECK: aghi %r0, 32768 +#CHECK: error: invalid operand +#CHECK: aghi %r0, foo + + aghi %r0, -32769 + aghi %r0, 32768 + aghi %r0, foo diff --git a/test/MC/SystemZ/insn-agr-01.s b/test/MC/SystemZ/insn-agr-01.s new file mode 100644 index 00000000000..a84ff3d2262 --- /dev/null +++ b/test/MC/SystemZ/insn-agr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: agr %r0, %r0 # encoding: [0xb9,0x08,0x00,0x00] +#CHECK: agr %r0, %r15 # encoding: [0xb9,0x08,0x00,0x0f] +#CHECK: agr %r15, %r0 # encoding: [0xb9,0x08,0x00,0xf0] +#CHECK: agr %r7, %r8 # encoding: [0xb9,0x08,0x00,0x78] + + agr %r0,%r0 + agr %r0,%r15 + agr %r15,%r0 + agr %r7,%r8 diff --git a/test/MC/SystemZ/insn-agsi-01.s b/test/MC/SystemZ/insn-agsi-01.s new file mode 100644 index 00000000000..9b2fe4b80e8 --- /dev/null +++ b/test/MC/SystemZ/insn-agsi-01.s @@ -0,0 +1,29 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: agsi -524288, 0 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x7a] +#CHECK: agsi -1, 0 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x7a] +#CHECK: agsi 0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x7a] +#CHECK: agsi 1, 0 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x7a] +#CHECK: agsi 524287, 0 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x7a] +#CHECK: agsi 0, -128 # encoding: [0xeb,0x80,0x00,0x00,0x00,0x7a] +#CHECK: agsi 0, -1 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x7a] +#CHECK: agsi 0, 1 # encoding: [0xeb,0x01,0x00,0x00,0x00,0x7a] +#CHECK: agsi 0, 127 # encoding: [0xeb,0x7f,0x00,0x00,0x00,0x7a] +#CHECK: agsi 0(%r1), 42 # encoding: [0xeb,0x2a,0x10,0x00,0x00,0x7a] +#CHECK: agsi 0(%r15), 42 # encoding: [0xeb,0x2a,0xf0,0x00,0x00,0x7a] +#CHECK: agsi 524287(%r1), 42 # encoding: [0xeb,0x2a,0x1f,0xff,0x7f,0x7a] +#CHECK: agsi 524287(%r15), 42 # encoding: [0xeb,0x2a,0xff,0xff,0x7f,0x7a] + + agsi -524288, 0 + agsi -1, 0 + agsi 0, 0 + agsi 1, 0 + agsi 524287, 0 + agsi 0, -128 + agsi 0, -1 + agsi 0, 1 + agsi 0, 127 + agsi 0(%r1), 42 + agsi 0(%r15), 42 + agsi 524287(%r1), 42 + agsi 524287(%r15), 42 diff --git a/test/MC/SystemZ/insn-agsi-02.s b/test/MC/SystemZ/insn-agsi-02.s new file mode 100644 index 00000000000..a4b3d9a8883 --- /dev/null +++ b/test/MC/SystemZ/insn-agsi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: agsi -524289, 0 +#CHECK: error: invalid operand +#CHECK: agsi 524288, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: agsi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: agsi 0, -129 +#CHECK: error: invalid operand +#CHECK: agsi 0, 128 + + agsi -524289, 0 + agsi 524288, 0 + agsi 0(%r1,%r2), 0 + agsi 0, -129 + agsi 0, 128 diff --git a/test/MC/SystemZ/insn-ah-01.s b/test/MC/SystemZ/insn-ah-01.s new file mode 100644 index 00000000000..35012f0678e --- /dev/null +++ b/test/MC/SystemZ/insn-ah-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ah %r0, 0 # encoding: [0x4a,0x00,0x00,0x00] +#CHECK: ah %r0, 4095 # encoding: [0x4a,0x00,0x0f,0xff] +#CHECK: ah %r0, 0(%r1) # encoding: [0x4a,0x00,0x10,0x00] +#CHECK: ah %r0, 0(%r15) # encoding: [0x4a,0x00,0xf0,0x00] +#CHECK: ah %r0, 4095(%r1,%r15) # encoding: [0x4a,0x01,0xff,0xff] +#CHECK: ah %r0, 4095(%r15,%r1) # encoding: [0x4a,0x0f,0x1f,0xff] +#CHECK: ah %r15, 0 # encoding: [0x4a,0xf0,0x00,0x00] + + ah %r0, 0 + ah %r0, 4095 + ah %r0, 0(%r1) + ah %r0, 0(%r15) + ah %r0, 4095(%r1,%r15) + ah %r0, 4095(%r15,%r1) + ah %r15, 0 diff --git a/test/MC/SystemZ/insn-ah-02.s b/test/MC/SystemZ/insn-ah-02.s new file mode 100644 index 00000000000..1a20cd715f7 --- /dev/null +++ b/test/MC/SystemZ/insn-ah-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ah %r0, -1 +#CHECK: error: invalid operand +#CHECK: ah %r0, 4096 + + ah %r0, -1 + ah %r0, 4096 diff --git a/test/MC/SystemZ/insn-ahi-01.s b/test/MC/SystemZ/insn-ahi-01.s new file mode 100644 index 00000000000..e0a5fb389e6 --- /dev/null +++ b/test/MC/SystemZ/insn-ahi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ahi %r0, -32768 # encoding: [0xa7,0x0a,0x80,0x00] +#CHECK: ahi %r0, -1 # encoding: [0xa7,0x0a,0xff,0xff] +#CHECK: ahi %r0, 0 # encoding: [0xa7,0x0a,0x00,0x00] +#CHECK: ahi %r0, 1 # encoding: [0xa7,0x0a,0x00,0x01] +#CHECK: ahi %r0, 32767 # encoding: [0xa7,0x0a,0x7f,0xff] +#CHECK: ahi %r15, 0 # encoding: [0xa7,0xfa,0x00,0x00] + + ahi %r0, -32768 + ahi %r0, -1 + ahi %r0, 0 + ahi %r0, 1 + ahi %r0, 32767 + ahi %r15, 0 diff --git a/test/MC/SystemZ/insn-ahi-02.s b/test/MC/SystemZ/insn-ahi-02.s new file mode 100644 index 00000000000..d41e2da2a21 --- /dev/null +++ b/test/MC/SystemZ/insn-ahi-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ahi %r0, -32769 +#CHECK: error: invalid operand +#CHECK: ahi %r0, 32768 +#CHECK: error: invalid operand +#CHECK: ahi %r0, foo + + ahi %r0, -32769 + ahi %r0, 32768 + ahi %r0, foo diff --git a/test/MC/SystemZ/insn-ahy-01.s b/test/MC/SystemZ/insn-ahy-01.s new file mode 100644 index 00000000000..ff25dc503c6 --- /dev/null +++ b/test/MC/SystemZ/insn-ahy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ahy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x7a] +#CHECK: ahy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x7a] +#CHECK: ahy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x7a] +#CHECK: ahy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x7a] +#CHECK: ahy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x7a] +#CHECK: ahy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x7a] +#CHECK: ahy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x7a] +#CHECK: ahy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x7a] +#CHECK: ahy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x7a] +#CHECK: ahy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x7a] + + ahy %r0, -524288 + ahy %r0, -1 + ahy %r0, 0 + ahy %r0, 1 + ahy %r0, 524287 + ahy %r0, 0(%r1) + ahy %r0, 0(%r15) + ahy %r0, 524287(%r1,%r15) + ahy %r0, 524287(%r15,%r1) + ahy %r15, 0 diff --git a/test/MC/SystemZ/insn-ahy-02.s b/test/MC/SystemZ/insn-ahy-02.s new file mode 100644 index 00000000000..e725e146df5 --- /dev/null +++ b/test/MC/SystemZ/insn-ahy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ahy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: ahy %r0, 524288 + + ahy %r0, -524289 + ahy %r0, 524288 diff --git a/test/MC/SystemZ/insn-al-01.s b/test/MC/SystemZ/insn-al-01.s new file mode 100644 index 00000000000..1efc33f0e98 --- /dev/null +++ b/test/MC/SystemZ/insn-al-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: al %r0, 0 # encoding: [0x5e,0x00,0x00,0x00] +#CHECK: al %r0, 4095 # encoding: [0x5e,0x00,0x0f,0xff] +#CHECK: al %r0, 0(%r1) # encoding: [0x5e,0x00,0x10,0x00] +#CHECK: al %r0, 0(%r15) # encoding: [0x5e,0x00,0xf0,0x00] +#CHECK: al %r0, 4095(%r1,%r15) # encoding: [0x5e,0x01,0xff,0xff] +#CHECK: al %r0, 4095(%r15,%r1) # encoding: [0x5e,0x0f,0x1f,0xff] +#CHECK: al %r15, 0 # encoding: [0x5e,0xf0,0x00,0x00] + + al %r0, 0 + al %r0, 4095 + al %r0, 0(%r1) + al %r0, 0(%r15) + al %r0, 4095(%r1,%r15) + al %r0, 4095(%r15,%r1) + al %r15, 0 diff --git a/test/MC/SystemZ/insn-al-02.s b/test/MC/SystemZ/insn-al-02.s new file mode 100644 index 00000000000..39b1b06a1ba --- /dev/null +++ b/test/MC/SystemZ/insn-al-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: al %r0, -1 +#CHECK: error: invalid operand +#CHECK: al %r0, 4096 + + al %r0, -1 + al %r0, 4096 diff --git a/test/MC/SystemZ/insn-alc-01.s b/test/MC/SystemZ/insn-alc-01.s new file mode 100644 index 00000000000..5f8be6a7d5a --- /dev/null +++ b/test/MC/SystemZ/insn-alc-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: alc %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x98] +#CHECK: alc %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x98] +#CHECK: alc %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x98] +#CHECK: alc %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x98] +#CHECK: alc %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x98] +#CHECK: alc %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x98] +#CHECK: alc %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x98] +#CHECK: alc %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x98] +#CHECK: alc %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x98] +#CHECK: alc %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x98] + + alc %r0, -524288 + alc %r0, -1 + alc %r0, 0 + alc %r0, 1 + alc %r0, 524287 + alc %r0, 0(%r1) + alc %r0, 0(%r15) + alc %r0, 524287(%r1,%r15) + alc %r0, 524287(%r15,%r1) + alc %r15, 0 diff --git a/test/MC/SystemZ/insn-alc-02.s b/test/MC/SystemZ/insn-alc-02.s new file mode 100644 index 00000000000..9c082f2dfb7 --- /dev/null +++ b/test/MC/SystemZ/insn-alc-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: alc %r0, -524289 +#CHECK: error: invalid operand +#CHECK: alc %r0, 524288 + + alc %r0, -524289 + alc %r0, 524288 diff --git a/test/MC/SystemZ/insn-alcg-01.s b/test/MC/SystemZ/insn-alcg-01.s new file mode 100644 index 00000000000..c05207ec9e9 --- /dev/null +++ b/test/MC/SystemZ/insn-alcg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: alcg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x88] +#CHECK: alcg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x88] +#CHECK: alcg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x88] +#CHECK: alcg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x88] +#CHECK: alcg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x88] +#CHECK: alcg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x88] +#CHECK: alcg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x88] +#CHECK: alcg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x88] +#CHECK: alcg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x88] +#CHECK: alcg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x88] + + alcg %r0, -524288 + alcg %r0, -1 + alcg %r0, 0 + alcg %r0, 1 + alcg %r0, 524287 + alcg %r0, 0(%r1) + alcg %r0, 0(%r15) + alcg %r0, 524287(%r1,%r15) + alcg %r0, 524287(%r15,%r1) + alcg %r15, 0 diff --git a/test/MC/SystemZ/insn-alcg-02.s b/test/MC/SystemZ/insn-alcg-02.s new file mode 100644 index 00000000000..3dab6ddc5dd --- /dev/null +++ b/test/MC/SystemZ/insn-alcg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: alcg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: alcg %r0, 524288 + + alcg %r0, -524289 + alcg %r0, 524288 diff --git a/test/MC/SystemZ/insn-alcgr-01.s b/test/MC/SystemZ/insn-alcgr-01.s new file mode 100644 index 00000000000..c9f3ce29341 --- /dev/null +++ b/test/MC/SystemZ/insn-alcgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: alcgr %r0, %r0 # encoding: [0xb9,0x88,0x00,0x00] +#CHECK: alcgr %r0, %r15 # encoding: [0xb9,0x88,0x00,0x0f] +#CHECK: alcgr %r15, %r0 # encoding: [0xb9,0x88,0x00,0xf0] +#CHECK: alcgr %r7, %r8 # encoding: [0xb9,0x88,0x00,0x78] + + alcgr %r0,%r0 + alcgr %r0,%r15 + alcgr %r15,%r0 + alcgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-alcr-01.s b/test/MC/SystemZ/insn-alcr-01.s new file mode 100644 index 00000000000..7369224a1be --- /dev/null +++ b/test/MC/SystemZ/insn-alcr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: alcr %r0, %r0 # encoding: [0xb9,0x98,0x00,0x00] +#CHECK: alcr %r0, %r15 # encoding: [0xb9,0x98,0x00,0x0f] +#CHECK: alcr %r15, %r0 # encoding: [0xb9,0x98,0x00,0xf0] +#CHECK: alcr %r7, %r8 # encoding: [0xb9,0x98,0x00,0x78] + + alcr %r0,%r0 + alcr %r0,%r15 + alcr %r15,%r0 + alcr %r7,%r8 diff --git a/test/MC/SystemZ/insn-alfi-01.s b/test/MC/SystemZ/insn-alfi-01.s new file mode 100644 index 00000000000..332a74fdc7a --- /dev/null +++ b/test/MC/SystemZ/insn-alfi-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: alfi %r0, 0 # encoding: [0xc2,0x0b,0x00,0x00,0x00,0x00] +#CHECK: alfi %r0, 4294967295 # encoding: [0xc2,0x0b,0xff,0xff,0xff,0xff] +#CHECK: alfi %r15, 0 # encoding: [0xc2,0xfb,0x00,0x00,0x00,0x00] + + alfi %r0, 0 + alfi %r0, (1 << 32) - 1 + alfi %r15, 0 diff --git a/test/MC/SystemZ/insn-alfi-02.s b/test/MC/SystemZ/insn-alfi-02.s new file mode 100644 index 00000000000..a5d38942257 --- /dev/null +++ b/test/MC/SystemZ/insn-alfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: alfi %r0, -1 +#CHECK: error: invalid operand +#CHECK: alfi %r0, (1 << 32) + + alfi %r0, -1 + alfi %r0, (1 << 32) diff --git a/test/MC/SystemZ/insn-alg-01.s b/test/MC/SystemZ/insn-alg-01.s new file mode 100644 index 00000000000..6df084c02b2 --- /dev/null +++ b/test/MC/SystemZ/insn-alg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: alg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x0a] +#CHECK: alg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x0a] +#CHECK: alg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x0a] +#CHECK: alg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x0a] +#CHECK: alg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x0a] +#CHECK: alg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x0a] +#CHECK: alg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x0a] +#CHECK: alg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x0a] +#CHECK: alg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x0a] +#CHECK: alg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x0a] + + alg %r0, -524288 + alg %r0, -1 + alg %r0, 0 + alg %r0, 1 + alg %r0, 524287 + alg %r0, 0(%r1) + alg %r0, 0(%r15) + alg %r0, 524287(%r1,%r15) + alg %r0, 524287(%r15,%r1) + alg %r15, 0 diff --git a/test/MC/SystemZ/insn-alg-02.s b/test/MC/SystemZ/insn-alg-02.s new file mode 100644 index 00000000000..407d73d2bd5 --- /dev/null +++ b/test/MC/SystemZ/insn-alg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: alg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: alg %r0, 524288 + + alg %r0, -524289 + alg %r0, 524288 diff --git a/test/MC/SystemZ/insn-algf-01.s b/test/MC/SystemZ/insn-algf-01.s new file mode 100644 index 00000000000..751b59059f1 --- /dev/null +++ b/test/MC/SystemZ/insn-algf-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: algf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x1a] +#CHECK: algf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x1a] +#CHECK: algf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x1a] +#CHECK: algf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x1a] +#CHECK: algf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x1a] +#CHECK: algf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x1a] +#CHECK: algf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x1a] +#CHECK: algf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x1a] +#CHECK: algf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x1a] +#CHECK: algf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x1a] + + algf %r0, -524288 + algf %r0, -1 + algf %r0, 0 + algf %r0, 1 + algf %r0, 524287 + algf %r0, 0(%r1) + algf %r0, 0(%r15) + algf %r0, 524287(%r1,%r15) + algf %r0, 524287(%r15,%r1) + algf %r15, 0 diff --git a/test/MC/SystemZ/insn-algf-02.s b/test/MC/SystemZ/insn-algf-02.s new file mode 100644 index 00000000000..64ef1c975b7 --- /dev/null +++ b/test/MC/SystemZ/insn-algf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: algf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: algf %r0, 524288 + + algf %r0, -524289 + algf %r0, 524288 diff --git a/test/MC/SystemZ/insn-algfi-01.s b/test/MC/SystemZ/insn-algfi-01.s new file mode 100644 index 00000000000..b6ccb336b3b --- /dev/null +++ b/test/MC/SystemZ/insn-algfi-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: algfi %r0, 0 # encoding: [0xc2,0x0a,0x00,0x00,0x00,0x00] +#CHECK: algfi %r0, 4294967295 # encoding: [0xc2,0x0a,0xff,0xff,0xff,0xff] +#CHECK: algfi %r15, 0 # encoding: [0xc2,0xfa,0x00,0x00,0x00,0x00] + + algfi %r0, 0 + algfi %r0, (1 << 32) - 1 + algfi %r15, 0 diff --git a/test/MC/SystemZ/insn-algfi-02.s b/test/MC/SystemZ/insn-algfi-02.s new file mode 100644 index 00000000000..a5ed4b04e55 --- /dev/null +++ b/test/MC/SystemZ/insn-algfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: algfi %r0, -1 +#CHECK: error: invalid operand +#CHECK: algfi %r0, (1 << 32) + + algfi %r0, -1 + algfi %r0, (1 << 32) diff --git a/test/MC/SystemZ/insn-algfr-01.s b/test/MC/SystemZ/insn-algfr-01.s new file mode 100644 index 00000000000..3ccb692ab94 --- /dev/null +++ b/test/MC/SystemZ/insn-algfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: algfr %r0, %r0 # encoding: [0xb9,0x1a,0x00,0x00] +#CHECK: algfr %r0, %r15 # encoding: [0xb9,0x1a,0x00,0x0f] +#CHECK: algfr %r15, %r0 # encoding: [0xb9,0x1a,0x00,0xf0] +#CHECK: algfr %r7, %r8 # encoding: [0xb9,0x1a,0x00,0x78] + + algfr %r0,%r0 + algfr %r0,%r15 + algfr %r15,%r0 + algfr %r7,%r8 diff --git a/test/MC/SystemZ/insn-algr-01.s b/test/MC/SystemZ/insn-algr-01.s new file mode 100644 index 00000000000..c3758ee74df --- /dev/null +++ b/test/MC/SystemZ/insn-algr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: algr %r0, %r0 # encoding: [0xb9,0x0a,0x00,0x00] +#CHECK: algr %r0, %r15 # encoding: [0xb9,0x0a,0x00,0x0f] +#CHECK: algr %r15, %r0 # encoding: [0xb9,0x0a,0x00,0xf0] +#CHECK: algr %r7, %r8 # encoding: [0xb9,0x0a,0x00,0x78] + + algr %r0,%r0 + algr %r0,%r15 + algr %r15,%r0 + algr %r7,%r8 diff --git a/test/MC/SystemZ/insn-alr-01.s b/test/MC/SystemZ/insn-alr-01.s new file mode 100644 index 00000000000..e85173ef151 --- /dev/null +++ b/test/MC/SystemZ/insn-alr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: alr %r0, %r0 # encoding: [0x1e,0x00] +#CHECK: alr %r0, %r15 # encoding: [0x1e,0x0f] +#CHECK: alr %r15, %r0 # encoding: [0x1e,0xf0] +#CHECK: alr %r7, %r8 # encoding: [0x1e,0x78] + + alr %r0,%r0 + alr %r0,%r15 + alr %r15,%r0 + alr %r7,%r8 diff --git a/test/MC/SystemZ/insn-aly-01.s b/test/MC/SystemZ/insn-aly-01.s new file mode 100644 index 00000000000..94afb07578f --- /dev/null +++ b/test/MC/SystemZ/insn-aly-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: aly %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x5e] +#CHECK: aly %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x5e] +#CHECK: aly %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x5e] +#CHECK: aly %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x5e] +#CHECK: aly %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x5e] +#CHECK: aly %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x5e] +#CHECK: aly %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x5e] +#CHECK: aly %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x5e] +#CHECK: aly %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x5e] +#CHECK: aly %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x5e] + + aly %r0, -524288 + aly %r0, -1 + aly %r0, 0 + aly %r0, 1 + aly %r0, 524287 + aly %r0, 0(%r1) + aly %r0, 0(%r15) + aly %r0, 524287(%r1,%r15) + aly %r0, 524287(%r15,%r1) + aly %r15, 0 diff --git a/test/MC/SystemZ/insn-aly-02.s b/test/MC/SystemZ/insn-aly-02.s new file mode 100644 index 00000000000..01c6f3dcdd1 --- /dev/null +++ b/test/MC/SystemZ/insn-aly-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: aly %r0, -524289 +#CHECK: error: invalid operand +#CHECK: aly %r0, 524288 + + aly %r0, -524289 + aly %r0, 524288 diff --git a/test/MC/SystemZ/insn-ar-01.s b/test/MC/SystemZ/insn-ar-01.s new file mode 100644 index 00000000000..7cd627a1702 --- /dev/null +++ b/test/MC/SystemZ/insn-ar-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ar %r0, %r0 # encoding: [0x1a,0x00] +#CHECK: ar %r0, %r15 # encoding: [0x1a,0x0f] +#CHECK: ar %r15, %r0 # encoding: [0x1a,0xf0] +#CHECK: ar %r7, %r8 # encoding: [0x1a,0x78] + + ar %r0,%r0 + ar %r0,%r15 + ar %r15,%r0 + ar %r7,%r8 diff --git a/test/MC/SystemZ/insn-asi-01.s b/test/MC/SystemZ/insn-asi-01.s new file mode 100644 index 00000000000..7a1d241e235 --- /dev/null +++ b/test/MC/SystemZ/insn-asi-01.s @@ -0,0 +1,29 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: asi -524288, 0 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x6a] +#CHECK: asi -1, 0 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x6a] +#CHECK: asi 0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x6a] +#CHECK: asi 1, 0 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x6a] +#CHECK: asi 524287, 0 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x6a] +#CHECK: asi 0, -128 # encoding: [0xeb,0x80,0x00,0x00,0x00,0x6a] +#CHECK: asi 0, -1 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x6a] +#CHECK: asi 0, 1 # encoding: [0xeb,0x01,0x00,0x00,0x00,0x6a] +#CHECK: asi 0, 127 # encoding: [0xeb,0x7f,0x00,0x00,0x00,0x6a] +#CHECK: asi 0(%r1), 42 # encoding: [0xeb,0x2a,0x10,0x00,0x00,0x6a] +#CHECK: asi 0(%r15), 42 # encoding: [0xeb,0x2a,0xf0,0x00,0x00,0x6a] +#CHECK: asi 524287(%r1), 42 # encoding: [0xeb,0x2a,0x1f,0xff,0x7f,0x6a] +#CHECK: asi 524287(%r15), 42 # encoding: [0xeb,0x2a,0xff,0xff,0x7f,0x6a] + + asi -524288, 0 + asi -1, 0 + asi 0, 0 + asi 1, 0 + asi 524287, 0 + asi 0, -128 + asi 0, -1 + asi 0, 1 + asi 0, 127 + asi 0(%r1), 42 + asi 0(%r15), 42 + asi 524287(%r1), 42 + asi 524287(%r15), 42 diff --git a/test/MC/SystemZ/insn-asi-02.s b/test/MC/SystemZ/insn-asi-02.s new file mode 100644 index 00000000000..3c09f905038 --- /dev/null +++ b/test/MC/SystemZ/insn-asi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: asi -524289, 0 +#CHECK: error: invalid operand +#CHECK: asi 524288, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: asi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: asi 0, -129 +#CHECK: error: invalid operand +#CHECK: asi 0, 128 + + asi -524289, 0 + asi 524288, 0 + asi 0(%r1,%r2), 0 + asi 0, -129 + asi 0, 128 diff --git a/test/MC/SystemZ/insn-axbr-01.s b/test/MC/SystemZ/insn-axbr-01.s new file mode 100644 index 00000000000..cb592efba6a --- /dev/null +++ b/test/MC/SystemZ/insn-axbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: axbr %f0, %f0 # encoding: [0xb3,0x4a,0x00,0x00] +#CHECK: axbr %f0, %f13 # encoding: [0xb3,0x4a,0x00,0x0d] +#CHECK: axbr %f8, %f8 # encoding: [0xb3,0x4a,0x00,0x88] +#CHECK: axbr %f13, %f0 # encoding: [0xb3,0x4a,0x00,0xd0] + + axbr %f0, %f0 + axbr %f0, %f13 + axbr %f8, %f8 + axbr %f13, %f0 diff --git a/test/MC/SystemZ/insn-axbr-02.s b/test/MC/SystemZ/insn-axbr-02.s new file mode 100644 index 00000000000..307664d51e5 --- /dev/null +++ b/test/MC/SystemZ/insn-axbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: axbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: axbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: axbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: axbr %f14, %f0 + + axbr %f0, %f2 + axbr %f0, %f14 + axbr %f2, %f0 + axbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-ay-01.s b/test/MC/SystemZ/insn-ay-01.s new file mode 100644 index 00000000000..3b65c9a7c0e --- /dev/null +++ b/test/MC/SystemZ/insn-ay-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ay %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x5a] +#CHECK: ay %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x5a] +#CHECK: ay %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x5a] +#CHECK: ay %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x5a] +#CHECK: ay %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x5a] +#CHECK: ay %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x5a] +#CHECK: ay %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x5a] +#CHECK: ay %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x5a] +#CHECK: ay %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x5a] +#CHECK: ay %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x5a] + + ay %r0, -524288 + ay %r0, -1 + ay %r0, 0 + ay %r0, 1 + ay %r0, 524287 + ay %r0, 0(%r1) + ay %r0, 0(%r15) + ay %r0, 524287(%r1,%r15) + ay %r0, 524287(%r15,%r1) + ay %r15, 0 diff --git a/test/MC/SystemZ/insn-ay-02.s b/test/MC/SystemZ/insn-ay-02.s new file mode 100644 index 00000000000..09704dfb9f4 --- /dev/null +++ b/test/MC/SystemZ/insn-ay-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ay %r0, -524289 +#CHECK: error: invalid operand +#CHECK: ay %r0, 524288 + + ay %r0, -524289 + ay %r0, 524288 diff --git a/test/MC/SystemZ/insn-basr-01.s b/test/MC/SystemZ/insn-basr-01.s new file mode 100644 index 00000000000..a66cee8f635 --- /dev/null +++ b/test/MC/SystemZ/insn-basr-01.s @@ -0,0 +1,12 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: basr %r0, %r1 # encoding: [0x0d,0x01] +#CHECK: basr %r0, %r15 # encoding: [0x0d,0x0f] +#CHECK: basr %r14, %r9 # encoding: [0x0d,0xe9] +#CHECK: basr %r15, %r1 # encoding: [0x0d,0xf1] + + basr %r0,%r1 + basr %r0,%r15 + basr %r14,%r9 + basr %r15,%r1 + diff --git a/test/MC/SystemZ/insn-br-01.s b/test/MC/SystemZ/insn-br-01.s new file mode 100644 index 00000000000..8e2f2aac78a --- /dev/null +++ b/test/MC/SystemZ/insn-br-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: br %r1 # encoding: [0x07,0xf1] +#CHECK: br %r14 # encoding: [0x07,0xfe] +#CHECK: br %r15 # encoding: [0x07,0xff] + + br %r1 + br %r14 + br %r15 diff --git a/test/MC/SystemZ/insn-bras-01.s b/test/MC/SystemZ/insn-bras-01.s new file mode 100644 index 00000000000..89f7f77477d --- /dev/null +++ b/test/MC/SystemZ/insn-bras-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: bras %r0, foo # encoding: [0xa7,0x05,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: bras %r14, foo # encoding: [0xa7,0xe5,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: bras %r15, foo # encoding: [0xa7,0xf5,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + bras %r0,foo + bras %r14,foo + bras %r15,foo + +#CHECK: bras %r0, bar+100 # encoding: [0xa7,0x05,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL +#CHECK: bras %r14, bar+100 # encoding: [0xa7,0xe5,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL +#CHECK: bras %r15, bar+100 # encoding: [0xa7,0xf5,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + bras %r0,bar+100 + bras %r14,bar+100 + bras %r15,bar+100 + +#CHECK: bras %r0, bar@PLT # encoding: [0xa7,0x05,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL +#CHECK: bras %r14, bar@PLT # encoding: [0xa7,0xe5,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL +#CHECK: bras %r15, bar@PLT # encoding: [0xa7,0xf5,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + bras %r0,bar@PLT + bras %r14,bar@PLT + bras %r15,bar@PLT diff --git a/test/MC/SystemZ/insn-brasl-01.s b/test/MC/SystemZ/insn-brasl-01.s new file mode 100644 index 00000000000..86d0ced9b33 --- /dev/null +++ b/test/MC/SystemZ/insn-brasl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: brasl %r0, foo # encoding: [0xc0,0x05,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: brasl %r14, foo # encoding: [0xc0,0xe5,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: brasl %r15, foo # encoding: [0xc0,0xf5,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brasl %r0,foo + brasl %r14,foo + brasl %r15,foo + +#CHECK: brasl %r0, bar+100 # encoding: [0xc0,0x05,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: brasl %r14, bar+100 # encoding: [0xc0,0xe5,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: brasl %r15, bar+100 # encoding: [0xc0,0xf5,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + brasl %r0,bar+100 + brasl %r14,bar+100 + brasl %r15,bar+100 + +#CHECK: brasl %r0, bar@PLT # encoding: [0xc0,0x05,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL +#CHECK: brasl %r14, bar@PLT # encoding: [0xc0,0xe5,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL +#CHECK: brasl %r15, bar@PLT # encoding: [0xc0,0xf5,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + brasl %r0,bar@PLT + brasl %r14,bar@PLT + brasl %r15,bar@PLT diff --git a/test/MC/SystemZ/insn-brc-01.s b/test/MC/SystemZ/insn-brc-01.s new file mode 100644 index 00000000000..a92ea45ecfc --- /dev/null +++ b/test/MC/SystemZ/insn-brc-01.s @@ -0,0 +1,238 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: brc 0, foo # encoding: [0xa7,0x04,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 0, foo + +#CHECK: brc 1, foo # encoding: [0xa7,0x14,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jo foo # encoding: [0xa7,0x14,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 1, foo + jo foo + +#CHECK: brc 2, foo # encoding: [0xa7,0x24,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jh foo # encoding: [0xa7,0x24,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 2, foo + jh foo + +#CHECK: brc 3, foo # encoding: [0xa7,0x34,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jnle foo # encoding: [0xa7,0x34,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 3, foo + jnle foo + +#CHECK: brc 4, foo # encoding: [0xa7,0x44,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jl foo # encoding: [0xa7,0x44,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 4, foo + jl foo + +#CHECK: brc 5, foo # encoding: [0xa7,0x54,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jnhe foo # encoding: [0xa7,0x54,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 5, foo + jnhe foo + +#CHECK: brc 6, foo # encoding: [0xa7,0x64,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jlh foo # encoding: [0xa7,0x64,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 6, foo + jlh foo + +#CHECK: brc 7, foo # encoding: [0xa7,0x74,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jne foo # encoding: [0xa7,0x74,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 7, foo + jne foo + +#CHECK: brc 8, foo # encoding: [0xa7,0x84,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: je foo # encoding: [0xa7,0x84,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 8, foo + je foo + +#CHECK: brc 9, foo # encoding: [0xa7,0x94,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jnlh foo # encoding: [0xa7,0x94,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 9, foo + jnlh foo + +#CHECK: brc 10, foo # encoding: [0xa7,0xa4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jhe foo # encoding: [0xa7,0xa4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 10, foo + jhe foo + +#CHECK: brc 11, foo # encoding: [0xa7,0xb4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jnl foo # encoding: [0xa7,0xb4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 11, foo + jnl foo + +#CHECK: brc 12, foo # encoding: [0xa7,0xc4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jle foo # encoding: [0xa7,0xc4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 12, foo + jle foo + +#CHECK: brc 13, foo # encoding: [0xa7,0xd4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jnh foo # encoding: [0xa7,0xd4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 13, foo + jnh foo + +#CHECK: brc 14, foo # encoding: [0xa7,0xe4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: jno foo # encoding: [0xa7,0xe4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 14, foo + jno foo + +#CHECK: brc 15, foo # encoding: [0xa7,0xf4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL +#CHECK: j foo # encoding: [0xa7,0xf4,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC16DBL + brc 15, foo + j foo + +#CHECK: brc 0, bar+100 # encoding: [0xa7,0x04,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + brc 0, bar+100 + +#CHECK: jo bar+100 # encoding: [0xa7,0x14,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jo bar+100 + +#CHECK: jh bar+100 # encoding: [0xa7,0x24,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jh bar+100 + +#CHECK: jnle bar+100 # encoding: [0xa7,0x34,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jnle bar+100 + +#CHECK: jl bar+100 # encoding: [0xa7,0x44,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jl bar+100 + +#CHECK: jnhe bar+100 # encoding: [0xa7,0x54,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jnhe bar+100 + +#CHECK: jlh bar+100 # encoding: [0xa7,0x64,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jlh bar+100 + +#CHECK: jne bar+100 # encoding: [0xa7,0x74,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jne bar+100 + +#CHECK: je bar+100 # encoding: [0xa7,0x84,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + je bar+100 + +#CHECK: jnlh bar+100 # encoding: [0xa7,0x94,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jnlh bar+100 + +#CHECK: jhe bar+100 # encoding: [0xa7,0xa4,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jhe bar+100 + +#CHECK: jnl bar+100 # encoding: [0xa7,0xb4,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jnl bar+100 + +#CHECK: jle bar+100 # encoding: [0xa7,0xc4,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jle bar+100 + +#CHECK: jnh bar+100 # encoding: [0xa7,0xd4,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jnh bar+100 + +#CHECK: jno bar+100 # encoding: [0xa7,0xe4,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + jno bar+100 + +#CHECK: j bar+100 # encoding: [0xa7,0xf4,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC16DBL + j bar+100 + +#CHECK: brc 0, bar@PLT # encoding: [0xa7,0x04,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + brc 0, bar@PLT + +#CHECK: jo bar@PLT # encoding: [0xa7,0x14,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jo bar@PLT + +#CHECK: jh bar@PLT # encoding: [0xa7,0x24,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jh bar@PLT + +#CHECK: jnle bar@PLT # encoding: [0xa7,0x34,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jnle bar@PLT + +#CHECK: jl bar@PLT # encoding: [0xa7,0x44,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jl bar@PLT + +#CHECK: jnhe bar@PLT # encoding: [0xa7,0x54,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jnhe bar@PLT + +#CHECK: jlh bar@PLT # encoding: [0xa7,0x64,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jlh bar@PLT + +#CHECK: jne bar@PLT # encoding: [0xa7,0x74,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jne bar@PLT + +#CHECK: je bar@PLT # encoding: [0xa7,0x84,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + je bar@PLT + +#CHECK: jnlh bar@PLT # encoding: [0xa7,0x94,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jnlh bar@PLT + +#CHECK: jhe bar@PLT # encoding: [0xa7,0xa4,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jhe bar@PLT + +#CHECK: jnl bar@PLT # encoding: [0xa7,0xb4,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jnl bar@PLT + +#CHECK: jle bar@PLT # encoding: [0xa7,0xc4,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jle bar@PLT + +#CHECK: jnh bar@PLT # encoding: [0xa7,0xd4,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jnh bar@PLT + +#CHECK: jno bar@PLT # encoding: [0xa7,0xe4,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + jno bar@PLT + +#CHECK: j bar@PLT # encoding: [0xa7,0xf4,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC16DBL + j bar@PLT diff --git a/test/MC/SystemZ/insn-brc-02.s b/test/MC/SystemZ/insn-brc-02.s new file mode 100644 index 00000000000..941cc459f38 --- /dev/null +++ b/test/MC/SystemZ/insn-brc-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: brc foo, bar +#CHECK: error: invalid operand +#CHECK: brc -1, bar +#CHECK: error: invalid operand +#CHECK: brc 16, bar + + brc foo, bar + brc -1, bar + brc 16, bar diff --git a/test/MC/SystemZ/insn-brcl-01.s b/test/MC/SystemZ/insn-brcl-01.s new file mode 100644 index 00000000000..f7138bf5be3 --- /dev/null +++ b/test/MC/SystemZ/insn-brcl-01.s @@ -0,0 +1,238 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: brcl 0, foo # encoding: [0xc0,0x04,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 0, foo + +#CHECK: brcl 1, foo # encoding: [0xc0,0x14,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgo foo # encoding: [0xc0,0x14,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 1, foo + jgo foo + +#CHECK: brcl 2, foo # encoding: [0xc0,0x24,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgh foo # encoding: [0xc0,0x24,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 2, foo + jgh foo + +#CHECK: brcl 3, foo # encoding: [0xc0,0x34,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgnle foo # encoding: [0xc0,0x34,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 3, foo + jgnle foo + +#CHECK: brcl 4, foo # encoding: [0xc0,0x44,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgl foo # encoding: [0xc0,0x44,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 4, foo + jgl foo + +#CHECK: brcl 5, foo # encoding: [0xc0,0x54,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgnhe foo # encoding: [0xc0,0x54,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 5, foo + jgnhe foo + +#CHECK: brcl 6, foo # encoding: [0xc0,0x64,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jglh foo # encoding: [0xc0,0x64,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 6, foo + jglh foo + +#CHECK: brcl 7, foo # encoding: [0xc0,0x74,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgne foo # encoding: [0xc0,0x74,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 7, foo + jgne foo + +#CHECK: brcl 8, foo # encoding: [0xc0,0x84,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jge foo # encoding: [0xc0,0x84,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 8, foo + jge foo + +#CHECK: brcl 9, foo # encoding: [0xc0,0x94,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgnlh foo # encoding: [0xc0,0x94,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 9, foo + jgnlh foo + +#CHECK: brcl 10, foo # encoding: [0xc0,0xa4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jghe foo # encoding: [0xc0,0xa4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 10, foo + jghe foo + +#CHECK: brcl 11, foo # encoding: [0xc0,0xb4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgnl foo # encoding: [0xc0,0xb4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 11, foo + jgnl foo + +#CHECK: brcl 12, foo # encoding: [0xc0,0xc4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgle foo # encoding: [0xc0,0xc4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 12, foo + jgle foo + +#CHECK: brcl 13, foo # encoding: [0xc0,0xd4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgnh foo # encoding: [0xc0,0xd4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 13, foo + jgnh foo + +#CHECK: brcl 14, foo # encoding: [0xc0,0xe4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jgno foo # encoding: [0xc0,0xe4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 14, foo + jgno foo + +#CHECK: brcl 15, foo # encoding: [0xc0,0xf4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: jg foo # encoding: [0xc0,0xf4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + brcl 15, foo + jg foo + +#CHECK: brcl 0, bar+100 # encoding: [0xc0,0x04,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + brcl 0, bar+100 + +#CHECK: jgo bar+100 # encoding: [0xc0,0x14,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgo bar+100 + +#CHECK: jgh bar+100 # encoding: [0xc0,0x24,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgh bar+100 + +#CHECK: jgnle bar+100 # encoding: [0xc0,0x34,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgnle bar+100 + +#CHECK: jgl bar+100 # encoding: [0xc0,0x44,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgl bar+100 + +#CHECK: jgnhe bar+100 # encoding: [0xc0,0x54,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgnhe bar+100 + +#CHECK: jglh bar+100 # encoding: [0xc0,0x64,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jglh bar+100 + +#CHECK: jgne bar+100 # encoding: [0xc0,0x74,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgne bar+100 + +#CHECK: jge bar+100 # encoding: [0xc0,0x84,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jge bar+100 + +#CHECK: jgnlh bar+100 # encoding: [0xc0,0x94,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgnlh bar+100 + +#CHECK: jghe bar+100 # encoding: [0xc0,0xa4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jghe bar+100 + +#CHECK: jgnl bar+100 # encoding: [0xc0,0xb4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgnl bar+100 + +#CHECK: jgle bar+100 # encoding: [0xc0,0xc4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgle bar+100 + +#CHECK: jgnh bar+100 # encoding: [0xc0,0xd4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgnh bar+100 + +#CHECK: jgno bar+100 # encoding: [0xc0,0xe4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jgno bar+100 + +#CHECK: jg bar+100 # encoding: [0xc0,0xf4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + jg bar+100 + +#CHECK: brcl 0, bar@PLT # encoding: [0xc0,0x04,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + brcl 0, bar@PLT + +#CHECK: jgo bar@PLT # encoding: [0xc0,0x14,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgo bar@PLT + +#CHECK: jgh bar@PLT # encoding: [0xc0,0x24,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgh bar@PLT + +#CHECK: jgnle bar@PLT # encoding: [0xc0,0x34,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgnle bar@PLT + +#CHECK: jgl bar@PLT # encoding: [0xc0,0x44,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgl bar@PLT + +#CHECK: jgnhe bar@PLT # encoding: [0xc0,0x54,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgnhe bar@PLT + +#CHECK: jglh bar@PLT # encoding: [0xc0,0x64,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jglh bar@PLT + +#CHECK: jgne bar@PLT # encoding: [0xc0,0x74,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgne bar@PLT + +#CHECK: jge bar@PLT # encoding: [0xc0,0x84,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jge bar@PLT + +#CHECK: jgnlh bar@PLT # encoding: [0xc0,0x94,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgnlh bar@PLT + +#CHECK: jghe bar@PLT # encoding: [0xc0,0xa4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jghe bar@PLT + +#CHECK: jgnl bar@PLT # encoding: [0xc0,0xb4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgnl bar@PLT + +#CHECK: jgle bar@PLT # encoding: [0xc0,0xc4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgle bar@PLT + +#CHECK: jgnh bar@PLT # encoding: [0xc0,0xd4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgnh bar@PLT + +#CHECK: jgno bar@PLT # encoding: [0xc0,0xe4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jgno bar@PLT + +#CHECK: jg bar@PLT # encoding: [0xc0,0xf4,A,A,A,A] +#CHECK: fixup A - offset: 2, value: bar@PLT+2, kind: FK_390_PC32DBL + jg bar@PLT diff --git a/test/MC/SystemZ/insn-brcl-02.s b/test/MC/SystemZ/insn-brcl-02.s new file mode 100644 index 00000000000..ded5f7e4a6e --- /dev/null +++ b/test/MC/SystemZ/insn-brcl-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: brcl foo, bar +#CHECK: error: invalid operand +#CHECK: brcl -1, bar +#CHECK: error: invalid operand +#CHECK: brcl 16, bar + + brcl foo, bar + brcl -1, bar + brcl 16, bar diff --git a/test/MC/SystemZ/insn-c-01.s b/test/MC/SystemZ/insn-c-01.s new file mode 100644 index 00000000000..e8a8ada30d8 --- /dev/null +++ b/test/MC/SystemZ/insn-c-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: c %r0, 0 # encoding: [0x59,0x00,0x00,0x00] +#CHECK: c %r0, 4095 # encoding: [0x59,0x00,0x0f,0xff] +#CHECK: c %r0, 0(%r1) # encoding: [0x59,0x00,0x10,0x00] +#CHECK: c %r0, 0(%r15) # encoding: [0x59,0x00,0xf0,0x00] +#CHECK: c %r0, 4095(%r1,%r15) # encoding: [0x59,0x01,0xff,0xff] +#CHECK: c %r0, 4095(%r15,%r1) # encoding: [0x59,0x0f,0x1f,0xff] +#CHECK: c %r15, 0 # encoding: [0x59,0xf0,0x00,0x00] + + c %r0, 0 + c %r0, 4095 + c %r0, 0(%r1) + c %r0, 0(%r15) + c %r0, 4095(%r1,%r15) + c %r0, 4095(%r15,%r1) + c %r15, 0 diff --git a/test/MC/SystemZ/insn-c-02.s b/test/MC/SystemZ/insn-c-02.s new file mode 100644 index 00000000000..81fe2518196 --- /dev/null +++ b/test/MC/SystemZ/insn-c-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: c %r0, -1 +#CHECK: error: invalid operand +#CHECK: c %r0, 4096 + + c %r0, -1 + c %r0, 4096 diff --git a/test/MC/SystemZ/insn-cdb-01.s b/test/MC/SystemZ/insn-cdb-01.s new file mode 100644 index 00000000000..7f6bb59956c --- /dev/null +++ b/test/MC/SystemZ/insn-cdb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cdb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x19] +#CHECK: cdb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x19] +#CHECK: cdb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x19] +#CHECK: cdb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x19] +#CHECK: cdb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x19] +#CHECK: cdb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x19] +#CHECK: cdb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x19] + + cdb %f0, 0 + cdb %f0, 4095 + cdb %f0, 0(%r1) + cdb %f0, 0(%r15) + cdb %f0, 4095(%r1,%r15) + cdb %f0, 4095(%r15,%r1) + cdb %f15, 0 diff --git a/test/MC/SystemZ/insn-cdb-02.s b/test/MC/SystemZ/insn-cdb-02.s new file mode 100644 index 00000000000..5f02b84c149 --- /dev/null +++ b/test/MC/SystemZ/insn-cdb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cdb %f0, -1 +#CHECK: error: invalid operand +#CHECK: cdb %f0, 4096 + + cdb %f0, -1 + cdb %f0, 4096 diff --git a/test/MC/SystemZ/insn-cdbr-01.s b/test/MC/SystemZ/insn-cdbr-01.s new file mode 100644 index 00000000000..d2acfc01a25 --- /dev/null +++ b/test/MC/SystemZ/insn-cdbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cdbr %f0, %f0 # encoding: [0xb3,0x19,0x00,0x00] +#CHECK: cdbr %f0, %f15 # encoding: [0xb3,0x19,0x00,0x0f] +#CHECK: cdbr %f7, %f8 # encoding: [0xb3,0x19,0x00,0x78] +#CHECK: cdbr %f15, %f0 # encoding: [0xb3,0x19,0x00,0xf0] + + cdbr %f0, %f0 + cdbr %f0, %f15 + cdbr %f7, %f8 + cdbr %f15, %f0 diff --git a/test/MC/SystemZ/insn-cdfbr-01.s b/test/MC/SystemZ/insn-cdfbr-01.s new file mode 100644 index 00000000000..94c9b0779c7 --- /dev/null +++ b/test/MC/SystemZ/insn-cdfbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cdfbr %f0, %r0 # encoding: [0xb3,0x95,0x00,0x00] +#CHECK: cdfbr %f0, %r15 # encoding: [0xb3,0x95,0x00,0x0f] +#CHECK: cdfbr %f15, %r0 # encoding: [0xb3,0x95,0x00,0xf0] +#CHECK: cdfbr %f7, %r8 # encoding: [0xb3,0x95,0x00,0x78] +#CHECK: cdfbr %f15, %r15 # encoding: [0xb3,0x95,0x00,0xff] + + cdfbr %f0, %r0 + cdfbr %f0, %r15 + cdfbr %f15, %r0 + cdfbr %f7, %r8 + cdfbr %f15, %r15 diff --git a/test/MC/SystemZ/insn-cdfbr-02.s b/test/MC/SystemZ/insn-cdfbr-02.s new file mode 100644 index 00000000000..14caa1e3c0d --- /dev/null +++ b/test/MC/SystemZ/insn-cdfbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cdfbr %r0, %r0 +#CHECK: error: invalid register +#CHECK: cdfbr %f0, %f0 +#CHECK: error: invalid register +#CHECK: cdfbr %f0, %a0 +#CHECK: error: invalid register +#CHECK: cdfbr %a0, %r0 + + cdfbr %r0, %r0 + cdfbr %f0, %f0 + cdfbr %f0, %a0 + cdfbr %a0, %r0 diff --git a/test/MC/SystemZ/insn-cdgbr-01.s b/test/MC/SystemZ/insn-cdgbr-01.s new file mode 100644 index 00000000000..6a994af744e --- /dev/null +++ b/test/MC/SystemZ/insn-cdgbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cdgbr %f0, %r0 # encoding: [0xb3,0xa5,0x00,0x00] +#CHECK: cdgbr %f0, %r15 # encoding: [0xb3,0xa5,0x00,0x0f] +#CHECK: cdgbr %f15, %r0 # encoding: [0xb3,0xa5,0x00,0xf0] +#CHECK: cdgbr %f7, %r8 # encoding: [0xb3,0xa5,0x00,0x78] +#CHECK: cdgbr %f15, %r15 # encoding: [0xb3,0xa5,0x00,0xff] + + cdgbr %f0, %r0 + cdgbr %f0, %r15 + cdgbr %f15, %r0 + cdgbr %f7, %r8 + cdgbr %f15, %r15 diff --git a/test/MC/SystemZ/insn-cdgbr-02.s b/test/MC/SystemZ/insn-cdgbr-02.s new file mode 100644 index 00000000000..8fa9d4fa5c2 --- /dev/null +++ b/test/MC/SystemZ/insn-cdgbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cdgbr %r0, %r0 +#CHECK: error: invalid register +#CHECK: cdgbr %f0, %f0 +#CHECK: error: invalid register +#CHECK: cdgbr %f0, %a0 +#CHECK: error: invalid register +#CHECK: cdgbr %a0, %r0 + + cdgbr %r0, %r0 + cdgbr %f0, %f0 + cdgbr %f0, %a0 + cdgbr %a0, %r0 diff --git a/test/MC/SystemZ/insn-ceb-01.s b/test/MC/SystemZ/insn-ceb-01.s new file mode 100644 index 00000000000..d576e9d572d --- /dev/null +++ b/test/MC/SystemZ/insn-ceb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ceb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x09] +#CHECK: ceb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x09] +#CHECK: ceb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x09] +#CHECK: ceb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x09] +#CHECK: ceb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x09] +#CHECK: ceb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x09] +#CHECK: ceb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x09] + + ceb %f0, 0 + ceb %f0, 4095 + ceb %f0, 0(%r1) + ceb %f0, 0(%r15) + ceb %f0, 4095(%r1,%r15) + ceb %f0, 4095(%r15,%r1) + ceb %f15, 0 diff --git a/test/MC/SystemZ/insn-ceb-02.s b/test/MC/SystemZ/insn-ceb-02.s new file mode 100644 index 00000000000..90829dbe12f --- /dev/null +++ b/test/MC/SystemZ/insn-ceb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ceb %f0, -1 +#CHECK: error: invalid operand +#CHECK: ceb %f0, 4096 + + ceb %f0, -1 + ceb %f0, 4096 diff --git a/test/MC/SystemZ/insn-cebr-01.s b/test/MC/SystemZ/insn-cebr-01.s new file mode 100644 index 00000000000..b820e3901a6 --- /dev/null +++ b/test/MC/SystemZ/insn-cebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cebr %f0, %f0 # encoding: [0xb3,0x09,0x00,0x00] +#CHECK: cebr %f0, %f15 # encoding: [0xb3,0x09,0x00,0x0f] +#CHECK: cebr %f7, %f8 # encoding: [0xb3,0x09,0x00,0x78] +#CHECK: cebr %f15, %f0 # encoding: [0xb3,0x09,0x00,0xf0] + + cebr %f0, %f0 + cebr %f0, %f15 + cebr %f7, %f8 + cebr %f15, %f0 diff --git a/test/MC/SystemZ/insn-cefbr-01.s b/test/MC/SystemZ/insn-cefbr-01.s new file mode 100644 index 00000000000..f1068f506c5 --- /dev/null +++ b/test/MC/SystemZ/insn-cefbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cefbr %f0, %r0 # encoding: [0xb3,0x94,0x00,0x00] +#CHECK: cefbr %f0, %r15 # encoding: [0xb3,0x94,0x00,0x0f] +#CHECK: cefbr %f15, %r0 # encoding: [0xb3,0x94,0x00,0xf0] +#CHECK: cefbr %f7, %r8 # encoding: [0xb3,0x94,0x00,0x78] +#CHECK: cefbr %f15, %r15 # encoding: [0xb3,0x94,0x00,0xff] + + cefbr %f0, %r0 + cefbr %f0, %r15 + cefbr %f15, %r0 + cefbr %f7, %r8 + cefbr %f15, %r15 diff --git a/test/MC/SystemZ/insn-cefbr-02.s b/test/MC/SystemZ/insn-cefbr-02.s new file mode 100644 index 00000000000..b894fb9f325 --- /dev/null +++ b/test/MC/SystemZ/insn-cefbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cefbr %r0, %r0 +#CHECK: error: invalid register +#CHECK: cefbr %f0, %f0 +#CHECK: error: invalid register +#CHECK: cefbr %f0, %a0 +#CHECK: error: invalid register +#CHECK: cefbr %a0, %r0 + + cefbr %r0, %r0 + cefbr %f0, %f0 + cefbr %f0, %a0 + cefbr %a0, %r0 diff --git a/test/MC/SystemZ/insn-cegbr-01.s b/test/MC/SystemZ/insn-cegbr-01.s new file mode 100644 index 00000000000..5b2e6caf12c --- /dev/null +++ b/test/MC/SystemZ/insn-cegbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cegbr %f0, %r0 # encoding: [0xb3,0xa4,0x00,0x00] +#CHECK: cegbr %f0, %r15 # encoding: [0xb3,0xa4,0x00,0x0f] +#CHECK: cegbr %f15, %r0 # encoding: [0xb3,0xa4,0x00,0xf0] +#CHECK: cegbr %f7, %r8 # encoding: [0xb3,0xa4,0x00,0x78] +#CHECK: cegbr %f15, %r15 # encoding: [0xb3,0xa4,0x00,0xff] + + cegbr %f0, %r0 + cegbr %f0, %r15 + cegbr %f15, %r0 + cegbr %f7, %r8 + cegbr %f15, %r15 diff --git a/test/MC/SystemZ/insn-cegbr-02.s b/test/MC/SystemZ/insn-cegbr-02.s new file mode 100644 index 00000000000..bf0c31ad13f --- /dev/null +++ b/test/MC/SystemZ/insn-cegbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cegbr %r0, %r0 +#CHECK: error: invalid register +#CHECK: cegbr %f0, %f0 +#CHECK: error: invalid register +#CHECK: cegbr %f0, %a0 +#CHECK: error: invalid register +#CHECK: cegbr %a0, %r0 + + cegbr %r0, %r0 + cegbr %f0, %f0 + cegbr %f0, %a0 + cegbr %a0, %r0 diff --git a/test/MC/SystemZ/insn-cfdbr-01.s b/test/MC/SystemZ/insn-cfdbr-01.s new file mode 100644 index 00000000000..be4f87fb29e --- /dev/null +++ b/test/MC/SystemZ/insn-cfdbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cfdbr %r0, 0, %f0 # encoding: [0xb3,0x99,0x00,0x00] +#CHECK: cfdbr %r0, 0, %f15 # encoding: [0xb3,0x99,0x00,0x0f] +#CHECK: cfdbr %r0, 15, %f0 # encoding: [0xb3,0x99,0xf0,0x00] +#CHECK: cfdbr %r4, 5, %f6 # encoding: [0xb3,0x99,0x50,0x46] +#CHECK: cfdbr %r15, 0, %f0 # encoding: [0xb3,0x99,0x00,0xf0] + + cfdbr %r0, 0, %f0 + cfdbr %r0, 0, %f15 + cfdbr %r0, 15, %f0 + cfdbr %r4, 5, %f6 + cfdbr %r15, 0, %f0 diff --git a/test/MC/SystemZ/insn-cfdbr-02.s b/test/MC/SystemZ/insn-cfdbr-02.s new file mode 100644 index 00000000000..00175955f25 --- /dev/null +++ b/test/MC/SystemZ/insn-cfdbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cfdbr %r0, 0, %r0 +#CHECK: error: invalid register +#CHECK: cfdbr %f0, 0, %f0 +#CHECK: error: invalid operand +#CHECK: cfdbr %r0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: cfdbr %r0, 16, %f0 + + cfdbr %r0, 0, %r0 + cfdbr %f0, 0, %f0 + cfdbr %r0, -1, %f0 + cfdbr %r0, 16, %f0 diff --git a/test/MC/SystemZ/insn-cfebr-01.s b/test/MC/SystemZ/insn-cfebr-01.s new file mode 100644 index 00000000000..6f7ab2c0e03 --- /dev/null +++ b/test/MC/SystemZ/insn-cfebr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cfebr %r0, 0, %f0 # encoding: [0xb3,0x98,0x00,0x00] +#CHECK: cfebr %r0, 0, %f15 # encoding: [0xb3,0x98,0x00,0x0f] +#CHECK: cfebr %r0, 15, %f0 # encoding: [0xb3,0x98,0xf0,0x00] +#CHECK: cfebr %r4, 5, %f6 # encoding: [0xb3,0x98,0x50,0x46] +#CHECK: cfebr %r15, 0, %f0 # encoding: [0xb3,0x98,0x00,0xf0] + + cfebr %r0, 0, %f0 + cfebr %r0, 0, %f15 + cfebr %r0, 15, %f0 + cfebr %r4, 5, %f6 + cfebr %r15, 0, %f0 diff --git a/test/MC/SystemZ/insn-cfebr-02.s b/test/MC/SystemZ/insn-cfebr-02.s new file mode 100644 index 00000000000..c3c5adaed2c --- /dev/null +++ b/test/MC/SystemZ/insn-cfebr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cfebr %r0, 0, %r0 +#CHECK: error: invalid register +#CHECK: cfebr %f0, 0, %f0 +#CHECK: error: invalid operand +#CHECK: cfebr %r0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: cfebr %r0, 16, %f0 + + cfebr %r0, 0, %r0 + cfebr %f0, 0, %f0 + cfebr %r0, -1, %f0 + cfebr %r0, 16, %f0 diff --git a/test/MC/SystemZ/insn-cfi-01.s b/test/MC/SystemZ/insn-cfi-01.s new file mode 100644 index 00000000000..52e34c02e89 --- /dev/null +++ b/test/MC/SystemZ/insn-cfi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cfi %r0, -2147483648 # encoding: [0xc2,0x0d,0x80,0x00,0x00,0x00] +#CHECK: cfi %r0, -1 # encoding: [0xc2,0x0d,0xff,0xff,0xff,0xff] +#CHECK: cfi %r0, 0 # encoding: [0xc2,0x0d,0x00,0x00,0x00,0x00] +#CHECK: cfi %r0, 1 # encoding: [0xc2,0x0d,0x00,0x00,0x00,0x01] +#CHECK: cfi %r0, 2147483647 # encoding: [0xc2,0x0d,0x7f,0xff,0xff,0xff] +#CHECK: cfi %r15, 0 # encoding: [0xc2,0xfd,0x00,0x00,0x00,0x00] + + cfi %r0, -1 << 31 + cfi %r0, -1 + cfi %r0, 0 + cfi %r0, 1 + cfi %r0, (1 << 31) - 1 + cfi %r15, 0 diff --git a/test/MC/SystemZ/insn-cfi-02.s b/test/MC/SystemZ/insn-cfi-02.s new file mode 100644 index 00000000000..cf7c72621b7 --- /dev/null +++ b/test/MC/SystemZ/insn-cfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cfi %r0, (-1 << 31) - 1 +#CHECK: error: invalid operand +#CHECK: cfi %r0, (1 << 31) + + cfi %r0, (-1 << 31) - 1 + cfi %r0, (1 << 31) diff --git a/test/MC/SystemZ/insn-cfxbr-01.s b/test/MC/SystemZ/insn-cfxbr-01.s new file mode 100644 index 00000000000..c509106b543 --- /dev/null +++ b/test/MC/SystemZ/insn-cfxbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cfxbr %r0, 0, %f0 # encoding: [0xb3,0x9a,0x00,0x00] +#CHECK: cfxbr %r0, 0, %f13 # encoding: [0xb3,0x9a,0x00,0x0d] +#CHECK: cfxbr %r0, 15, %f0 # encoding: [0xb3,0x9a,0xf0,0x00] +#CHECK: cfxbr %r4, 5, %f8 # encoding: [0xb3,0x9a,0x50,0x48] +#CHECK: cfxbr %r15, 0, %f0 # encoding: [0xb3,0x9a,0x00,0xf0] + + cfxbr %r0, 0, %f0 + cfxbr %r0, 0, %f13 + cfxbr %r0, 15, %f0 + cfxbr %r4, 5, %f8 + cfxbr %r15, 0, %f0 diff --git a/test/MC/SystemZ/insn-cfxbr-02.s b/test/MC/SystemZ/insn-cfxbr-02.s new file mode 100644 index 00000000000..3802c514332 --- /dev/null +++ b/test/MC/SystemZ/insn-cfxbr-02.s @@ -0,0 +1,23 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cfxbr %r0, 0, %r0 +#CHECK: error: invalid register +#CHECK: cfxbr %f0, 0, %f0 +#CHECK: error: invalid operand +#CHECK: cfxbr %r0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: cfxbr %r0, 16, %f0 +#CHECK: error: invalid register +#CHECK: cfxbr %r0, 0, %f2 +#CHECK: error: invalid register +#CHECK: cfxbr %r0, 0, %f14 + + cfxbr %r0, 0, %r0 + cfxbr %f0, 0, %f0 + cfxbr %r0, -1, %f0 + cfxbr %r0, 16, %f0 + cfxbr %r0, 0, %f2 + cfxbr %r0, 0, %f14 + diff --git a/test/MC/SystemZ/insn-cg-01.s b/test/MC/SystemZ/insn-cg-01.s new file mode 100644 index 00000000000..1eb185f0ec6 --- /dev/null +++ b/test/MC/SystemZ/insn-cg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x20] +#CHECK: cg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x20] +#CHECK: cg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x20] +#CHECK: cg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x20] +#CHECK: cg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x20] +#CHECK: cg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x20] +#CHECK: cg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x20] +#CHECK: cg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x20] +#CHECK: cg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x20] +#CHECK: cg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x20] + + cg %r0, -524288 + cg %r0, -1 + cg %r0, 0 + cg %r0, 1 + cg %r0, 524287 + cg %r0, 0(%r1) + cg %r0, 0(%r15) + cg %r0, 524287(%r1,%r15) + cg %r0, 524287(%r15,%r1) + cg %r15, 0 diff --git a/test/MC/SystemZ/insn-cg-02.s b/test/MC/SystemZ/insn-cg-02.s new file mode 100644 index 00000000000..e093ccd7511 --- /dev/null +++ b/test/MC/SystemZ/insn-cg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: cg %r0, 524288 + + cg %r0, -524289 + cg %r0, 524288 diff --git a/test/MC/SystemZ/insn-cgdbr-01.s b/test/MC/SystemZ/insn-cgdbr-01.s new file mode 100644 index 00000000000..718f50a9ea9 --- /dev/null +++ b/test/MC/SystemZ/insn-cgdbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgdbr %r0, 0, %f0 # encoding: [0xb3,0xa9,0x00,0x00] +#CHECK: cgdbr %r0, 0, %f15 # encoding: [0xb3,0xa9,0x00,0x0f] +#CHECK: cgdbr %r0, 15, %f0 # encoding: [0xb3,0xa9,0xf0,0x00] +#CHECK: cgdbr %r4, 5, %f6 # encoding: [0xb3,0xa9,0x50,0x46] +#CHECK: cgdbr %r15, 0, %f0 # encoding: [0xb3,0xa9,0x00,0xf0] + + cgdbr %r0, 0, %f0 + cgdbr %r0, 0, %f15 + cgdbr %r0, 15, %f0 + cgdbr %r4, 5, %f6 + cgdbr %r15, 0, %f0 diff --git a/test/MC/SystemZ/insn-cgdbr-02.s b/test/MC/SystemZ/insn-cgdbr-02.s new file mode 100644 index 00000000000..3a3e01fde0f --- /dev/null +++ b/test/MC/SystemZ/insn-cgdbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cgdbr %r0, 0, %r0 +#CHECK: error: invalid register +#CHECK: cgdbr %f0, 0, %f0 +#CHECK: error: invalid operand +#CHECK: cgdbr %r0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: cgdbr %r0, 16, %f0 + + cgdbr %r0, 0, %r0 + cgdbr %f0, 0, %f0 + cgdbr %r0, -1, %f0 + cgdbr %r0, 16, %f0 diff --git a/test/MC/SystemZ/insn-cgebr-01.s b/test/MC/SystemZ/insn-cgebr-01.s new file mode 100644 index 00000000000..dc6a7dbfafd --- /dev/null +++ b/test/MC/SystemZ/insn-cgebr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgebr %r0, 0, %f0 # encoding: [0xb3,0xa8,0x00,0x00] +#CHECK: cgebr %r0, 0, %f15 # encoding: [0xb3,0xa8,0x00,0x0f] +#CHECK: cgebr %r0, 15, %f0 # encoding: [0xb3,0xa8,0xf0,0x00] +#CHECK: cgebr %r4, 5, %f6 # encoding: [0xb3,0xa8,0x50,0x46] +#CHECK: cgebr %r15, 0, %f0 # encoding: [0xb3,0xa8,0x00,0xf0] + + cgebr %r0, 0, %f0 + cgebr %r0, 0, %f15 + cgebr %r0, 15, %f0 + cgebr %r4, 5, %f6 + cgebr %r15, 0, %f0 diff --git a/test/MC/SystemZ/insn-cgebr-02.s b/test/MC/SystemZ/insn-cgebr-02.s new file mode 100644 index 00000000000..9b817a41728 --- /dev/null +++ b/test/MC/SystemZ/insn-cgebr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cgebr %r0, 0, %r0 +#CHECK: error: invalid register +#CHECK: cgebr %f0, 0, %f0 +#CHECK: error: invalid operand +#CHECK: cgebr %r0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: cgebr %r0, 16, %f0 + + cgebr %r0, 0, %r0 + cgebr %f0, 0, %f0 + cgebr %r0, -1, %f0 + cgebr %r0, 16, %f0 diff --git a/test/MC/SystemZ/insn-cgf-01.s b/test/MC/SystemZ/insn-cgf-01.s new file mode 100644 index 00000000000..03c439f1f5d --- /dev/null +++ b/test/MC/SystemZ/insn-cgf-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x30] +#CHECK: cgf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x30] +#CHECK: cgf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x30] +#CHECK: cgf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x30] +#CHECK: cgf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x30] +#CHECK: cgf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x30] +#CHECK: cgf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x30] +#CHECK: cgf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x30] +#CHECK: cgf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x30] +#CHECK: cgf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x30] + + cgf %r0, -524288 + cgf %r0, -1 + cgf %r0, 0 + cgf %r0, 1 + cgf %r0, 524287 + cgf %r0, 0(%r1) + cgf %r0, 0(%r15) + cgf %r0, 524287(%r1,%r15) + cgf %r0, 524287(%r15,%r1) + cgf %r15, 0 diff --git a/test/MC/SystemZ/insn-cgf-02.s b/test/MC/SystemZ/insn-cgf-02.s new file mode 100644 index 00000000000..7171c6e3881 --- /dev/null +++ b/test/MC/SystemZ/insn-cgf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cgf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: cgf %r0, 524288 + + cgf %r0, -524289 + cgf %r0, 524288 diff --git a/test/MC/SystemZ/insn-cgfi-01.s b/test/MC/SystemZ/insn-cgfi-01.s new file mode 100644 index 00000000000..d6f72d5d671 --- /dev/null +++ b/test/MC/SystemZ/insn-cgfi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgfi %r0, -2147483648 # encoding: [0xc2,0x0c,0x80,0x00,0x00,0x00] +#CHECK: cgfi %r0, -1 # encoding: [0xc2,0x0c,0xff,0xff,0xff,0xff] +#CHECK: cgfi %r0, 0 # encoding: [0xc2,0x0c,0x00,0x00,0x00,0x00] +#CHECK: cgfi %r0, 1 # encoding: [0xc2,0x0c,0x00,0x00,0x00,0x01] +#CHECK: cgfi %r0, 2147483647 # encoding: [0xc2,0x0c,0x7f,0xff,0xff,0xff] +#CHECK: cgfi %r15, 0 # encoding: [0xc2,0xfc,0x00,0x00,0x00,0x00] + + cgfi %r0, -1 << 31 + cgfi %r0, -1 + cgfi %r0, 0 + cgfi %r0, 1 + cgfi %r0, (1 << 31) - 1 + cgfi %r15, 0 diff --git a/test/MC/SystemZ/insn-cgfi-02.s b/test/MC/SystemZ/insn-cgfi-02.s new file mode 100644 index 00000000000..6f72a24e690 --- /dev/null +++ b/test/MC/SystemZ/insn-cgfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cgfi %r0, (-1 << 31) - 1 +#CHECK: error: invalid operand +#CHECK: cgfi %r0, (1 << 31) + + cgfi %r0, (-1 << 31) - 1 + cgfi %r0, (1 << 31) diff --git a/test/MC/SystemZ/insn-cgfr-01.s b/test/MC/SystemZ/insn-cgfr-01.s new file mode 100644 index 00000000000..6bd1792ea02 --- /dev/null +++ b/test/MC/SystemZ/insn-cgfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgfr %r0, %r0 # encoding: [0xb9,0x30,0x00,0x00] +#CHECK: cgfr %r0, %r15 # encoding: [0xb9,0x30,0x00,0x0f] +#CHECK: cgfr %r15, %r0 # encoding: [0xb9,0x30,0x00,0xf0] +#CHECK: cgfr %r7, %r8 # encoding: [0xb9,0x30,0x00,0x78] + + cgfr %r0,%r0 + cgfr %r0,%r15 + cgfr %r15,%r0 + cgfr %r7,%r8 diff --git a/test/MC/SystemZ/insn-cgfrl-01.s b/test/MC/SystemZ/insn-cgfrl-01.s new file mode 100644 index 00000000000..2792fb4a93b --- /dev/null +++ b/test/MC/SystemZ/insn-cgfrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgfrl %r0, 2864434397 # encoding: [0xc6,0x0c,0x55,0x5d,0xe6,0x6e] +#CHECK: cgfrl %r15, 2864434397 # encoding: [0xc6,0xfc,0x55,0x5d,0xe6,0x6e] + + cgfrl %r0,0xaabbccdd + cgfrl %r15,0xaabbccdd + +#CHECK: cgfrl %r0, foo # encoding: [0xc6,0x0c,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: cgfrl %r15, foo # encoding: [0xc6,0xfc,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + cgfrl %r0,foo + cgfrl %r15,foo + +#CHECK: cgfrl %r3, bar+100 # encoding: [0xc6,0x3c,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: cgfrl %r4, bar+100 # encoding: [0xc6,0x4c,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + cgfrl %r3,bar+100 + cgfrl %r4,bar+100 + +#CHECK: cgfrl %r7, frob@PLT # encoding: [0xc6,0x7c,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: cgfrl %r8, frob@PLT # encoding: [0xc6,0x8c,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + cgfrl %r7,frob@PLT + cgfrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-cgh-01.s b/test/MC/SystemZ/insn-cgh-01.s new file mode 100644 index 00000000000..31c86abdda7 --- /dev/null +++ b/test/MC/SystemZ/insn-cgh-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgh %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x34] +#CHECK: cgh %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x34] +#CHECK: cgh %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x34] +#CHECK: cgh %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x34] +#CHECK: cgh %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x34] +#CHECK: cgh %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x34] +#CHECK: cgh %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x34] +#CHECK: cgh %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x34] +#CHECK: cgh %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x34] +#CHECK: cgh %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x34] + + cgh %r0, -524288 + cgh %r0, -1 + cgh %r0, 0 + cgh %r0, 1 + cgh %r0, 524287 + cgh %r0, 0(%r1) + cgh %r0, 0(%r15) + cgh %r0, 524287(%r1,%r15) + cgh %r0, 524287(%r15,%r1) + cgh %r15, 0 diff --git a/test/MC/SystemZ/insn-cgh-02.s b/test/MC/SystemZ/insn-cgh-02.s new file mode 100644 index 00000000000..60e665f2dd8 --- /dev/null +++ b/test/MC/SystemZ/insn-cgh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cgh %r0, -524289 +#CHECK: error: invalid operand +#CHECK: cgh %r0, 524288 + + cgh %r0, -524289 + cgh %r0, 524288 diff --git a/test/MC/SystemZ/insn-cghi-01.s b/test/MC/SystemZ/insn-cghi-01.s new file mode 100644 index 00000000000..575ad89023a --- /dev/null +++ b/test/MC/SystemZ/insn-cghi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cghi %r0, -32768 # encoding: [0xa7,0x0f,0x80,0x00] +#CHECK: cghi %r0, -1 # encoding: [0xa7,0x0f,0xff,0xff] +#CHECK: cghi %r0, 0 # encoding: [0xa7,0x0f,0x00,0x00] +#CHECK: cghi %r0, 1 # encoding: [0xa7,0x0f,0x00,0x01] +#CHECK: cghi %r0, 32767 # encoding: [0xa7,0x0f,0x7f,0xff] +#CHECK: cghi %r15, 0 # encoding: [0xa7,0xff,0x00,0x00] + + cghi %r0, -32768 + cghi %r0, -1 + cghi %r0, 0 + cghi %r0, 1 + cghi %r0, 32767 + cghi %r15, 0 diff --git a/test/MC/SystemZ/insn-cghi-02.s b/test/MC/SystemZ/insn-cghi-02.s new file mode 100644 index 00000000000..bd4a52a6b72 --- /dev/null +++ b/test/MC/SystemZ/insn-cghi-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cghi %r0, -32769 +#CHECK: error: invalid operand +#CHECK: cghi %r0, 32768 +#CHECK: error: invalid operand +#CHECK: cghi %r0, foo + + cghi %r0, -32769 + cghi %r0, 32768 + cghi %r0, foo diff --git a/test/MC/SystemZ/insn-cghrl-01.s b/test/MC/SystemZ/insn-cghrl-01.s new file mode 100644 index 00000000000..c48c5ec3efd --- /dev/null +++ b/test/MC/SystemZ/insn-cghrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cghrl %r0, 2864434397 # encoding: [0xc6,0x04,0x55,0x5d,0xe6,0x6e] +#CHECK: cghrl %r15, 2864434397 # encoding: [0xc6,0xf4,0x55,0x5d,0xe6,0x6e] + + cghrl %r0,0xaabbccdd + cghrl %r15,0xaabbccdd + +#CHECK: cghrl %r0, foo # encoding: [0xc6,0x04,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: cghrl %r15, foo # encoding: [0xc6,0xf4,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + cghrl %r0,foo + cghrl %r15,foo + +#CHECK: cghrl %r3, bar+100 # encoding: [0xc6,0x34,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: cghrl %r4, bar+100 # encoding: [0xc6,0x44,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + cghrl %r3,bar+100 + cghrl %r4,bar+100 + +#CHECK: cghrl %r7, frob@PLT # encoding: [0xc6,0x74,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: cghrl %r8, frob@PLT # encoding: [0xc6,0x84,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + cghrl %r7,frob@PLT + cghrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-cghsi-01.s b/test/MC/SystemZ/insn-cghsi-01.s new file mode 100644 index 00000000000..7d67e20b5b7 --- /dev/null +++ b/test/MC/SystemZ/insn-cghsi-01.s @@ -0,0 +1,25 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cghsi 0, 0 # encoding: [0xe5,0x58,0x00,0x00,0x00,0x00] +#CHECK: cghsi 4095, 0 # encoding: [0xe5,0x58,0x0f,0xff,0x00,0x00] +#CHECK: cghsi 0, -32768 # encoding: [0xe5,0x58,0x00,0x00,0x80,0x00] +#CHECK: cghsi 0, -1 # encoding: [0xe5,0x58,0x00,0x00,0xff,0xff] +#CHECK: cghsi 0, 0 # encoding: [0xe5,0x58,0x00,0x00,0x00,0x00] +#CHECK: cghsi 0, 1 # encoding: [0xe5,0x58,0x00,0x00,0x00,0x01] +#CHECK: cghsi 0, 32767 # encoding: [0xe5,0x58,0x00,0x00,0x7f,0xff] +#CHECK: cghsi 0(%r1), 42 # encoding: [0xe5,0x58,0x10,0x00,0x00,0x2a] +#CHECK: cghsi 0(%r15), 42 # encoding: [0xe5,0x58,0xf0,0x00,0x00,0x2a] +#CHECK: cghsi 4095(%r1), 42 # encoding: [0xe5,0x58,0x1f,0xff,0x00,0x2a] +#CHECK: cghsi 4095(%r15), 42 # encoding: [0xe5,0x58,0xff,0xff,0x00,0x2a] + + cghsi 0, 0 + cghsi 4095, 0 + cghsi 0, -32768 + cghsi 0, -1 + cghsi 0, 0 + cghsi 0, 1 + cghsi 0, 32767 + cghsi 0(%r1), 42 + cghsi 0(%r15), 42 + cghsi 4095(%r1), 42 + cghsi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-cghsi-02.s b/test/MC/SystemZ/insn-cghsi-02.s new file mode 100644 index 00000000000..773ee5cd9e9 --- /dev/null +++ b/test/MC/SystemZ/insn-cghsi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cghsi -1, 0 +#CHECK: error: invalid operand +#CHECK: cghsi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: cghsi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: cghsi 0, -32769 +#CHECK: error: invalid operand +#CHECK: cghsi 0, 32768 + + cghsi -1, 0 + cghsi 4096, 0 + cghsi 0(%r1,%r2), 0 + cghsi 0, -32769 + cghsi 0, 32768 diff --git a/test/MC/SystemZ/insn-cgr-01.s b/test/MC/SystemZ/insn-cgr-01.s new file mode 100644 index 00000000000..334a0f63f82 --- /dev/null +++ b/test/MC/SystemZ/insn-cgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgr %r0, %r0 # encoding: [0xb9,0x20,0x00,0x00] +#CHECK: cgr %r0, %r15 # encoding: [0xb9,0x20,0x00,0x0f] +#CHECK: cgr %r15, %r0 # encoding: [0xb9,0x20,0x00,0xf0] +#CHECK: cgr %r7, %r8 # encoding: [0xb9,0x20,0x00,0x78] + + cgr %r0,%r0 + cgr %r0,%r15 + cgr %r15,%r0 + cgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-cgrl-01.s b/test/MC/SystemZ/insn-cgrl-01.s new file mode 100644 index 00000000000..af878cbf450 --- /dev/null +++ b/test/MC/SystemZ/insn-cgrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgrl %r0, 2864434397 # encoding: [0xc6,0x08,0x55,0x5d,0xe6,0x6e] +#CHECK: cgrl %r15, 2864434397 # encoding: [0xc6,0xf8,0x55,0x5d,0xe6,0x6e] + + cgrl %r0,0xaabbccdd + cgrl %r15,0xaabbccdd + +#CHECK: cgrl %r0, foo # encoding: [0xc6,0x08,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: cgrl %r15, foo # encoding: [0xc6,0xf8,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + cgrl %r0,foo + cgrl %r15,foo + +#CHECK: cgrl %r3, bar+100 # encoding: [0xc6,0x38,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: cgrl %r4, bar+100 # encoding: [0xc6,0x48,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + cgrl %r3,bar+100 + cgrl %r4,bar+100 + +#CHECK: cgrl %r7, frob@PLT # encoding: [0xc6,0x78,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: cgrl %r8, frob@PLT # encoding: [0xc6,0x88,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + cgrl %r7,frob@PLT + cgrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-cgxbr-01.s b/test/MC/SystemZ/insn-cgxbr-01.s new file mode 100644 index 00000000000..0250b52955a --- /dev/null +++ b/test/MC/SystemZ/insn-cgxbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cgxbr %r0, 0, %f0 # encoding: [0xb3,0xaa,0x00,0x00] +#CHECK: cgxbr %r0, 0, %f13 # encoding: [0xb3,0xaa,0x00,0x0d] +#CHECK: cgxbr %r0, 15, %f0 # encoding: [0xb3,0xaa,0xf0,0x00] +#CHECK: cgxbr %r4, 5, %f8 # encoding: [0xb3,0xaa,0x50,0x48] +#CHECK: cgxbr %r15, 0, %f0 # encoding: [0xb3,0xaa,0x00,0xf0] + + cgxbr %r0, 0, %f0 + cgxbr %r0, 0, %f13 + cgxbr %r0, 15, %f0 + cgxbr %r4, 5, %f8 + cgxbr %r15, 0, %f0 diff --git a/test/MC/SystemZ/insn-cgxbr-02.s b/test/MC/SystemZ/insn-cgxbr-02.s new file mode 100644 index 00000000000..9caab9fc401 --- /dev/null +++ b/test/MC/SystemZ/insn-cgxbr-02.s @@ -0,0 +1,23 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cgxbr %r0, 0, %r0 +#CHECK: error: invalid register +#CHECK: cgxbr %f0, 0, %f0 +#CHECK: error: invalid operand +#CHECK: cgxbr %r0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: cgxbr %r0, 16, %f0 +#CHECK: error: invalid register +#CHECK: cgxbr %r0, 0, %f2 +#CHECK: error: invalid register +#CHECK: cgxbr %r0, 0, %f14 + + cgxbr %r0, 0, %r0 + cgxbr %f0, 0, %f0 + cgxbr %r0, -1, %f0 + cgxbr %r0, 16, %f0 + cgxbr %r0, 0, %f2 + cgxbr %r0, 0, %f14 + diff --git a/test/MC/SystemZ/insn-ch-01.s b/test/MC/SystemZ/insn-ch-01.s new file mode 100644 index 00000000000..dfb0b7fcca0 --- /dev/null +++ b/test/MC/SystemZ/insn-ch-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ch %r0, 0 # encoding: [0x49,0x00,0x00,0x00] +#CHECK: ch %r0, 4095 # encoding: [0x49,0x00,0x0f,0xff] +#CHECK: ch %r0, 0(%r1) # encoding: [0x49,0x00,0x10,0x00] +#CHECK: ch %r0, 0(%r15) # encoding: [0x49,0x00,0xf0,0x00] +#CHECK: ch %r0, 4095(%r1,%r15) # encoding: [0x49,0x01,0xff,0xff] +#CHECK: ch %r0, 4095(%r15,%r1) # encoding: [0x49,0x0f,0x1f,0xff] +#CHECK: ch %r15, 0 # encoding: [0x49,0xf0,0x00,0x00] + + ch %r0, 0 + ch %r0, 4095 + ch %r0, 0(%r1) + ch %r0, 0(%r15) + ch %r0, 4095(%r1,%r15) + ch %r0, 4095(%r15,%r1) + ch %r15, 0 diff --git a/test/MC/SystemZ/insn-ch-02.s b/test/MC/SystemZ/insn-ch-02.s new file mode 100644 index 00000000000..2034c2b8d4e --- /dev/null +++ b/test/MC/SystemZ/insn-ch-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ch %r0, -1 +#CHECK: error: invalid operand +#CHECK: ch %r0, 4096 + + ch %r0, -1 + ch %r0, 4096 diff --git a/test/MC/SystemZ/insn-chhsi-01.s b/test/MC/SystemZ/insn-chhsi-01.s new file mode 100644 index 00000000000..0fd50bc5e10 --- /dev/null +++ b/test/MC/SystemZ/insn-chhsi-01.s @@ -0,0 +1,25 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: chhsi 0, 0 # encoding: [0xe5,0x54,0x00,0x00,0x00,0x00] +#CHECK: chhsi 4095, 0 # encoding: [0xe5,0x54,0x0f,0xff,0x00,0x00] +#CHECK: chhsi 0, -32768 # encoding: [0xe5,0x54,0x00,0x00,0x80,0x00] +#CHECK: chhsi 0, -1 # encoding: [0xe5,0x54,0x00,0x00,0xff,0xff] +#CHECK: chhsi 0, 0 # encoding: [0xe5,0x54,0x00,0x00,0x00,0x00] +#CHECK: chhsi 0, 1 # encoding: [0xe5,0x54,0x00,0x00,0x00,0x01] +#CHECK: chhsi 0, 32767 # encoding: [0xe5,0x54,0x00,0x00,0x7f,0xff] +#CHECK: chhsi 0(%r1), 42 # encoding: [0xe5,0x54,0x10,0x00,0x00,0x2a] +#CHECK: chhsi 0(%r15), 42 # encoding: [0xe5,0x54,0xf0,0x00,0x00,0x2a] +#CHECK: chhsi 4095(%r1), 42 # encoding: [0xe5,0x54,0x1f,0xff,0x00,0x2a] +#CHECK: chhsi 4095(%r15), 42 # encoding: [0xe5,0x54,0xff,0xff,0x00,0x2a] + + chhsi 0, 0 + chhsi 4095, 0 + chhsi 0, -32768 + chhsi 0, -1 + chhsi 0, 0 + chhsi 0, 1 + chhsi 0, 32767 + chhsi 0(%r1), 42 + chhsi 0(%r15), 42 + chhsi 4095(%r1), 42 + chhsi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-chhsi-02.s b/test/MC/SystemZ/insn-chhsi-02.s new file mode 100644 index 00000000000..24e8c0cfbd3 --- /dev/null +++ b/test/MC/SystemZ/insn-chhsi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: chhsi -1, 0 +#CHECK: error: invalid operand +#CHECK: chhsi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: chhsi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: chhsi 0, -32769 +#CHECK: error: invalid operand +#CHECK: chhsi 0, 32768 + + chhsi -1, 0 + chhsi 4096, 0 + chhsi 0(%r1,%r2), 0 + chhsi 0, -32769 + chhsi 0, 32768 diff --git a/test/MC/SystemZ/insn-chi-01.s b/test/MC/SystemZ/insn-chi-01.s new file mode 100644 index 00000000000..fb44cfc2170 --- /dev/null +++ b/test/MC/SystemZ/insn-chi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: chi %r0, -32768 # encoding: [0xa7,0x0e,0x80,0x00] +#CHECK: chi %r0, -1 # encoding: [0xa7,0x0e,0xff,0xff] +#CHECK: chi %r0, 0 # encoding: [0xa7,0x0e,0x00,0x00] +#CHECK: chi %r0, 1 # encoding: [0xa7,0x0e,0x00,0x01] +#CHECK: chi %r0, 32767 # encoding: [0xa7,0x0e,0x7f,0xff] +#CHECK: chi %r15, 0 # encoding: [0xa7,0xfe,0x00,0x00] + + chi %r0, -32768 + chi %r0, -1 + chi %r0, 0 + chi %r0, 1 + chi %r0, 32767 + chi %r15, 0 diff --git a/test/MC/SystemZ/insn-chi-02.s b/test/MC/SystemZ/insn-chi-02.s new file mode 100644 index 00000000000..bb9ffdc7e6b --- /dev/null +++ b/test/MC/SystemZ/insn-chi-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: chi %r0, -32769 +#CHECK: error: invalid operand +#CHECK: chi %r0, 32768 +#CHECK: error: invalid operand +#CHECK: chi %r0, foo + + chi %r0, -32769 + chi %r0, 32768 + chi %r0, foo diff --git a/test/MC/SystemZ/insn-chrl-01.s b/test/MC/SystemZ/insn-chrl-01.s new file mode 100644 index 00000000000..c133a326d2b --- /dev/null +++ b/test/MC/SystemZ/insn-chrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: chrl %r0, 2864434397 # encoding: [0xc6,0x05,0x55,0x5d,0xe6,0x6e] +#CHECK: chrl %r15, 2864434397 # encoding: [0xc6,0xf5,0x55,0x5d,0xe6,0x6e] + + chrl %r0,0xaabbccdd + chrl %r15,0xaabbccdd + +#CHECK: chrl %r0, foo # encoding: [0xc6,0x05,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: chrl %r15, foo # encoding: [0xc6,0xf5,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + chrl %r0,foo + chrl %r15,foo + +#CHECK: chrl %r3, bar+100 # encoding: [0xc6,0x35,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: chrl %r4, bar+100 # encoding: [0xc6,0x45,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + chrl %r3,bar+100 + chrl %r4,bar+100 + +#CHECK: chrl %r7, frob@PLT # encoding: [0xc6,0x75,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: chrl %r8, frob@PLT # encoding: [0xc6,0x85,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + chrl %r7,frob@PLT + chrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-chsi-01.s b/test/MC/SystemZ/insn-chsi-01.s new file mode 100644 index 00000000000..6d92202185a --- /dev/null +++ b/test/MC/SystemZ/insn-chsi-01.s @@ -0,0 +1,25 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: chsi 0, 0 # encoding: [0xe5,0x5c,0x00,0x00,0x00,0x00] +#CHECK: chsi 4095, 0 # encoding: [0xe5,0x5c,0x0f,0xff,0x00,0x00] +#CHECK: chsi 0, -32768 # encoding: [0xe5,0x5c,0x00,0x00,0x80,0x00] +#CHECK: chsi 0, -1 # encoding: [0xe5,0x5c,0x00,0x00,0xff,0xff] +#CHECK: chsi 0, 0 # encoding: [0xe5,0x5c,0x00,0x00,0x00,0x00] +#CHECK: chsi 0, 1 # encoding: [0xe5,0x5c,0x00,0x00,0x00,0x01] +#CHECK: chsi 0, 32767 # encoding: [0xe5,0x5c,0x00,0x00,0x7f,0xff] +#CHECK: chsi 0(%r1), 42 # encoding: [0xe5,0x5c,0x10,0x00,0x00,0x2a] +#CHECK: chsi 0(%r15), 42 # encoding: [0xe5,0x5c,0xf0,0x00,0x00,0x2a] +#CHECK: chsi 4095(%r1), 42 # encoding: [0xe5,0x5c,0x1f,0xff,0x00,0x2a] +#CHECK: chsi 4095(%r15), 42 # encoding: [0xe5,0x5c,0xff,0xff,0x00,0x2a] + + chsi 0, 0 + chsi 4095, 0 + chsi 0, -32768 + chsi 0, -1 + chsi 0, 0 + chsi 0, 1 + chsi 0, 32767 + chsi 0(%r1), 42 + chsi 0(%r15), 42 + chsi 4095(%r1), 42 + chsi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-chsi-02.s b/test/MC/SystemZ/insn-chsi-02.s new file mode 100644 index 00000000000..16ace53d671 --- /dev/null +++ b/test/MC/SystemZ/insn-chsi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: chsi -1, 0 +#CHECK: error: invalid operand +#CHECK: chsi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: chsi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: chsi 0, -32769 +#CHECK: error: invalid operand +#CHECK: chsi 0, 32768 + + chsi -1, 0 + chsi 4096, 0 + chsi 0(%r1,%r2), 0 + chsi 0, -32769 + chsi 0, 32768 diff --git a/test/MC/SystemZ/insn-chy-01.s b/test/MC/SystemZ/insn-chy-01.s new file mode 100644 index 00000000000..9ecc0551cf2 --- /dev/null +++ b/test/MC/SystemZ/insn-chy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: chy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x79] +#CHECK: chy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x79] +#CHECK: chy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x79] +#CHECK: chy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x79] +#CHECK: chy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x79] +#CHECK: chy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x79] +#CHECK: chy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x79] +#CHECK: chy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x79] +#CHECK: chy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x79] +#CHECK: chy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x79] + + chy %r0, -524288 + chy %r0, -1 + chy %r0, 0 + chy %r0, 1 + chy %r0, 524287 + chy %r0, 0(%r1) + chy %r0, 0(%r15) + chy %r0, 524287(%r1,%r15) + chy %r0, 524287(%r15,%r1) + chy %r15, 0 diff --git a/test/MC/SystemZ/insn-chy-02.s b/test/MC/SystemZ/insn-chy-02.s new file mode 100644 index 00000000000..8ab849f0908 --- /dev/null +++ b/test/MC/SystemZ/insn-chy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: chy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: chy %r0, 524288 + + chy %r0, -524289 + chy %r0, 524288 diff --git a/test/MC/SystemZ/insn-cl-01.s b/test/MC/SystemZ/insn-cl-01.s new file mode 100644 index 00000000000..7face8f8543 --- /dev/null +++ b/test/MC/SystemZ/insn-cl-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cl %r0, 0 # encoding: [0x55,0x00,0x00,0x00] +#CHECK: cl %r0, 4095 # encoding: [0x55,0x00,0x0f,0xff] +#CHECK: cl %r0, 0(%r1) # encoding: [0x55,0x00,0x10,0x00] +#CHECK: cl %r0, 0(%r15) # encoding: [0x55,0x00,0xf0,0x00] +#CHECK: cl %r0, 4095(%r1,%r15) # encoding: [0x55,0x01,0xff,0xff] +#CHECK: cl %r0, 4095(%r15,%r1) # encoding: [0x55,0x0f,0x1f,0xff] +#CHECK: cl %r15, 0 # encoding: [0x55,0xf0,0x00,0x00] + + cl %r0, 0 + cl %r0, 4095 + cl %r0, 0(%r1) + cl %r0, 0(%r15) + cl %r0, 4095(%r1,%r15) + cl %r0, 4095(%r15,%r1) + cl %r15, 0 diff --git a/test/MC/SystemZ/insn-cl-02.s b/test/MC/SystemZ/insn-cl-02.s new file mode 100644 index 00000000000..ec3e1df996f --- /dev/null +++ b/test/MC/SystemZ/insn-cl-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cl %r0, -1 +#CHECK: error: invalid operand +#CHECK: cl %r0, 4096 + + cl %r0, -1 + cl %r0, 4096 diff --git a/test/MC/SystemZ/insn-clfhsi-01.s b/test/MC/SystemZ/insn-clfhsi-01.s new file mode 100644 index 00000000000..910515d96b7 --- /dev/null +++ b/test/MC/SystemZ/insn-clfhsi-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clfhsi 0, 0 # encoding: [0xe5,0x5d,0x00,0x00,0x00,0x00] +#CHECK: clfhsi 4095, 0 # encoding: [0xe5,0x5d,0x0f,0xff,0x00,0x00] +#CHECK: clfhsi 0, 65535 # encoding: [0xe5,0x5d,0x00,0x00,0xff,0xff] +#CHECK: clfhsi 0(%r1), 42 # encoding: [0xe5,0x5d,0x10,0x00,0x00,0x2a] +#CHECK: clfhsi 0(%r15), 42 # encoding: [0xe5,0x5d,0xf0,0x00,0x00,0x2a] +#CHECK: clfhsi 4095(%r1), 42 # encoding: [0xe5,0x5d,0x1f,0xff,0x00,0x2a] +#CHECK: clfhsi 4095(%r15), 42 # encoding: [0xe5,0x5d,0xff,0xff,0x00,0x2a] + + clfhsi 0, 0 + clfhsi 4095, 0 + clfhsi 0, 65535 + clfhsi 0(%r1), 42 + clfhsi 0(%r15), 42 + clfhsi 4095(%r1), 42 + clfhsi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-clfhsi-02.s b/test/MC/SystemZ/insn-clfhsi-02.s new file mode 100644 index 00000000000..4a6f4049c58 --- /dev/null +++ b/test/MC/SystemZ/insn-clfhsi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: clfhsi -1, 0 +#CHECK: error: invalid operand +#CHECK: clfhsi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: clfhsi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: clfhsi 0, -1 +#CHECK: error: invalid operand +#CHECK: clfhsi 0, 65536 + + clfhsi -1, 0 + clfhsi 4096, 0 + clfhsi 0(%r1,%r2), 0 + clfhsi 0, -1 + clfhsi 0, 65536 diff --git a/test/MC/SystemZ/insn-clfi-01.s b/test/MC/SystemZ/insn-clfi-01.s new file mode 100644 index 00000000000..4156c7f6e8e --- /dev/null +++ b/test/MC/SystemZ/insn-clfi-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clfi %r0, 0 # encoding: [0xc2,0x0f,0x00,0x00,0x00,0x00] +#CHECK: clfi %r0, 4294967295 # encoding: [0xc2,0x0f,0xff,0xff,0xff,0xff] +#CHECK: clfi %r15, 0 # encoding: [0xc2,0xff,0x00,0x00,0x00,0x00] + + clfi %r0, 0 + clfi %r0, (1 << 32) - 1 + clfi %r15, 0 diff --git a/test/MC/SystemZ/insn-clfi-02.s b/test/MC/SystemZ/insn-clfi-02.s new file mode 100644 index 00000000000..9d3f80630ef --- /dev/null +++ b/test/MC/SystemZ/insn-clfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: clfi %r0, -1 +#CHECK: error: invalid operand +#CHECK: clfi %r0, (1 << 32) + + clfi %r0, -1 + clfi %r0, (1 << 32) diff --git a/test/MC/SystemZ/insn-clg-01.s b/test/MC/SystemZ/insn-clg-01.s new file mode 100644 index 00000000000..596bae1c813 --- /dev/null +++ b/test/MC/SystemZ/insn-clg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x21] +#CHECK: clg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x21] +#CHECK: clg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x21] +#CHECK: clg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x21] +#CHECK: clg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x21] +#CHECK: clg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x21] +#CHECK: clg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x21] +#CHECK: clg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x21] +#CHECK: clg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x21] +#CHECK: clg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x21] + + clg %r0, -524288 + clg %r0, -1 + clg %r0, 0 + clg %r0, 1 + clg %r0, 524287 + clg %r0, 0(%r1) + clg %r0, 0(%r15) + clg %r0, 524287(%r1,%r15) + clg %r0, 524287(%r15,%r1) + clg %r15, 0 diff --git a/test/MC/SystemZ/insn-clg-02.s b/test/MC/SystemZ/insn-clg-02.s new file mode 100644 index 00000000000..a17aab52049 --- /dev/null +++ b/test/MC/SystemZ/insn-clg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: clg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: clg %r0, 524288 + + clg %r0, -524289 + clg %r0, 524288 diff --git a/test/MC/SystemZ/insn-clgf-01.s b/test/MC/SystemZ/insn-clgf-01.s new file mode 100644 index 00000000000..003ba838028 --- /dev/null +++ b/test/MC/SystemZ/insn-clgf-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clgf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x31] +#CHECK: clgf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x31] +#CHECK: clgf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x31] +#CHECK: clgf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x31] +#CHECK: clgf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x31] +#CHECK: clgf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x31] +#CHECK: clgf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x31] +#CHECK: clgf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x31] +#CHECK: clgf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x31] +#CHECK: clgf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x31] + + clgf %r0, -524288 + clgf %r0, -1 + clgf %r0, 0 + clgf %r0, 1 + clgf %r0, 524287 + clgf %r0, 0(%r1) + clgf %r0, 0(%r15) + clgf %r0, 524287(%r1,%r15) + clgf %r0, 524287(%r15,%r1) + clgf %r15, 0 diff --git a/test/MC/SystemZ/insn-clgf-02.s b/test/MC/SystemZ/insn-clgf-02.s new file mode 100644 index 00000000000..9de49ae79b6 --- /dev/null +++ b/test/MC/SystemZ/insn-clgf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: clgf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: clgf %r0, 524288 + + clgf %r0, -524289 + clgf %r0, 524288 diff --git a/test/MC/SystemZ/insn-clgfi-01.s b/test/MC/SystemZ/insn-clgfi-01.s new file mode 100644 index 00000000000..dbf4a0e8f0a --- /dev/null +++ b/test/MC/SystemZ/insn-clgfi-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clgfi %r0, 0 # encoding: [0xc2,0x0e,0x00,0x00,0x00,0x00] +#CHECK: clgfi %r0, 4294967295 # encoding: [0xc2,0x0e,0xff,0xff,0xff,0xff] +#CHECK: clgfi %r15, 0 # encoding: [0xc2,0xfe,0x00,0x00,0x00,0x00] + + clgfi %r0, 0 + clgfi %r0, (1 << 32) - 1 + clgfi %r15, 0 diff --git a/test/MC/SystemZ/insn-clgfi-02.s b/test/MC/SystemZ/insn-clgfi-02.s new file mode 100644 index 00000000000..3f2db33d836 --- /dev/null +++ b/test/MC/SystemZ/insn-clgfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: clgfi %r0, -1 +#CHECK: error: invalid operand +#CHECK: clgfi %r0, (1 << 32) + + clgfi %r0, -1 + clgfi %r0, (1 << 32) diff --git a/test/MC/SystemZ/insn-clgfr-01.s b/test/MC/SystemZ/insn-clgfr-01.s new file mode 100644 index 00000000000..37f1e24452d --- /dev/null +++ b/test/MC/SystemZ/insn-clgfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clgfr %r0, %r0 # encoding: [0xb9,0x31,0x00,0x00] +#CHECK: clgfr %r0, %r15 # encoding: [0xb9,0x31,0x00,0x0f] +#CHECK: clgfr %r15, %r0 # encoding: [0xb9,0x31,0x00,0xf0] +#CHECK: clgfr %r7, %r8 # encoding: [0xb9,0x31,0x00,0x78] + + clgfr %r0,%r0 + clgfr %r0,%r15 + clgfr %r15,%r0 + clgfr %r7,%r8 diff --git a/test/MC/SystemZ/insn-clgfrl-01.s b/test/MC/SystemZ/insn-clgfrl-01.s new file mode 100644 index 00000000000..6fc6d5eb3ba --- /dev/null +++ b/test/MC/SystemZ/insn-clgfrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clgfrl %r0, 2864434397 # encoding: [0xc6,0x0e,0x55,0x5d,0xe6,0x6e] +#CHECK: clgfrl %r15, 2864434397 # encoding: [0xc6,0xfe,0x55,0x5d,0xe6,0x6e] + + clgfrl %r0,0xaabbccdd + clgfrl %r15,0xaabbccdd + +#CHECK: clgfrl %r0, foo # encoding: [0xc6,0x0e,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: clgfrl %r15, foo # encoding: [0xc6,0xfe,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + clgfrl %r0,foo + clgfrl %r15,foo + +#CHECK: clgfrl %r3, bar+100 # encoding: [0xc6,0x3e,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: clgfrl %r4, bar+100 # encoding: [0xc6,0x4e,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + clgfrl %r3,bar+100 + clgfrl %r4,bar+100 + +#CHECK: clgfrl %r7, frob@PLT # encoding: [0xc6,0x7e,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: clgfrl %r8, frob@PLT # encoding: [0xc6,0x8e,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + clgfrl %r7,frob@PLT + clgfrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-clghrl-01.s b/test/MC/SystemZ/insn-clghrl-01.s new file mode 100644 index 00000000000..41c2580abde --- /dev/null +++ b/test/MC/SystemZ/insn-clghrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clghrl %r0, 2864434397 # encoding: [0xc6,0x06,0x55,0x5d,0xe6,0x6e] +#CHECK: clghrl %r15, 2864434397 # encoding: [0xc6,0xf6,0x55,0x5d,0xe6,0x6e] + + clghrl %r0,0xaabbccdd + clghrl %r15,0xaabbccdd + +#CHECK: clghrl %r0, foo # encoding: [0xc6,0x06,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: clghrl %r15, foo # encoding: [0xc6,0xf6,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + clghrl %r0,foo + clghrl %r15,foo + +#CHECK: clghrl %r3, bar+100 # encoding: [0xc6,0x36,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: clghrl %r4, bar+100 # encoding: [0xc6,0x46,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + clghrl %r3,bar+100 + clghrl %r4,bar+100 + +#CHECK: clghrl %r7, frob@PLT # encoding: [0xc6,0x76,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: clghrl %r8, frob@PLT # encoding: [0xc6,0x86,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + clghrl %r7,frob@PLT + clghrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-clghsi-01.s b/test/MC/SystemZ/insn-clghsi-01.s new file mode 100644 index 00000000000..05e0c585c0a --- /dev/null +++ b/test/MC/SystemZ/insn-clghsi-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clghsi 0, 0 # encoding: [0xe5,0x59,0x00,0x00,0x00,0x00] +#CHECK: clghsi 4095, 0 # encoding: [0xe5,0x59,0x0f,0xff,0x00,0x00] +#CHECK: clghsi 0, 65535 # encoding: [0xe5,0x59,0x00,0x00,0xff,0xff] +#CHECK: clghsi 0(%r1), 42 # encoding: [0xe5,0x59,0x10,0x00,0x00,0x2a] +#CHECK: clghsi 0(%r15), 42 # encoding: [0xe5,0x59,0xf0,0x00,0x00,0x2a] +#CHECK: clghsi 4095(%r1), 42 # encoding: [0xe5,0x59,0x1f,0xff,0x00,0x2a] +#CHECK: clghsi 4095(%r15), 42 # encoding: [0xe5,0x59,0xff,0xff,0x00,0x2a] + + clghsi 0, 0 + clghsi 4095, 0 + clghsi 0, 65535 + clghsi 0(%r1), 42 + clghsi 0(%r15), 42 + clghsi 4095(%r1), 42 + clghsi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-clghsi-02.s b/test/MC/SystemZ/insn-clghsi-02.s new file mode 100644 index 00000000000..f0361280705 --- /dev/null +++ b/test/MC/SystemZ/insn-clghsi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: clghsi -1, 0 +#CHECK: error: invalid operand +#CHECK: clghsi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: clghsi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: clghsi 0, -1 +#CHECK: error: invalid operand +#CHECK: clghsi 0, 65536 + + clghsi -1, 0 + clghsi 4096, 0 + clghsi 0(%r1,%r2), 0 + clghsi 0, -1 + clghsi 0, 65536 diff --git a/test/MC/SystemZ/insn-clgr-01.s b/test/MC/SystemZ/insn-clgr-01.s new file mode 100644 index 00000000000..7e9d2ad4398 --- /dev/null +++ b/test/MC/SystemZ/insn-clgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clgr %r0, %r0 # encoding: [0xb9,0x21,0x00,0x00] +#CHECK: clgr %r0, %r15 # encoding: [0xb9,0x21,0x00,0x0f] +#CHECK: clgr %r15, %r0 # encoding: [0xb9,0x21,0x00,0xf0] +#CHECK: clgr %r7, %r8 # encoding: [0xb9,0x21,0x00,0x78] + + clgr %r0,%r0 + clgr %r0,%r15 + clgr %r15,%r0 + clgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-clgrl-01.s b/test/MC/SystemZ/insn-clgrl-01.s new file mode 100644 index 00000000000..439bcd94ff8 --- /dev/null +++ b/test/MC/SystemZ/insn-clgrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clgrl %r0, 2864434397 # encoding: [0xc6,0x0a,0x55,0x5d,0xe6,0x6e] +#CHECK: clgrl %r15, 2864434397 # encoding: [0xc6,0xfa,0x55,0x5d,0xe6,0x6e] + + clgrl %r0,0xaabbccdd + clgrl %r15,0xaabbccdd + +#CHECK: clgrl %r0, foo # encoding: [0xc6,0x0a,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: clgrl %r15, foo # encoding: [0xc6,0xfa,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + clgrl %r0,foo + clgrl %r15,foo + +#CHECK: clgrl %r3, bar+100 # encoding: [0xc6,0x3a,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: clgrl %r4, bar+100 # encoding: [0xc6,0x4a,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + clgrl %r3,bar+100 + clgrl %r4,bar+100 + +#CHECK: clgrl %r7, frob@PLT # encoding: [0xc6,0x7a,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: clgrl %r8, frob@PLT # encoding: [0xc6,0x8a,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + clgrl %r7,frob@PLT + clgrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-clhhsi-01.s b/test/MC/SystemZ/insn-clhhsi-01.s new file mode 100644 index 00000000000..ae72ffa018a --- /dev/null +++ b/test/MC/SystemZ/insn-clhhsi-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clhhsi 0, 0 # encoding: [0xe5,0x55,0x00,0x00,0x00,0x00] +#CHECK: clhhsi 4095, 0 # encoding: [0xe5,0x55,0x0f,0xff,0x00,0x00] +#CHECK: clhhsi 0, 65535 # encoding: [0xe5,0x55,0x00,0x00,0xff,0xff] +#CHECK: clhhsi 0(%r1), 42 # encoding: [0xe5,0x55,0x10,0x00,0x00,0x2a] +#CHECK: clhhsi 0(%r15), 42 # encoding: [0xe5,0x55,0xf0,0x00,0x00,0x2a] +#CHECK: clhhsi 4095(%r1), 42 # encoding: [0xe5,0x55,0x1f,0xff,0x00,0x2a] +#CHECK: clhhsi 4095(%r15), 42 # encoding: [0xe5,0x55,0xff,0xff,0x00,0x2a] + + clhhsi 0, 0 + clhhsi 4095, 0 + clhhsi 0, 65535 + clhhsi 0(%r1), 42 + clhhsi 0(%r15), 42 + clhhsi 4095(%r1), 42 + clhhsi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-clhhsi-02.s b/test/MC/SystemZ/insn-clhhsi-02.s new file mode 100644 index 00000000000..bbdf7cd0da6 --- /dev/null +++ b/test/MC/SystemZ/insn-clhhsi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: clhhsi -1, 0 +#CHECK: error: invalid operand +#CHECK: clhhsi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: clhhsi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: clhhsi 0, -1 +#CHECK: error: invalid operand +#CHECK: clhhsi 0, 65536 + + clhhsi -1, 0 + clhhsi 4096, 0 + clhhsi 0(%r1,%r2), 0 + clhhsi 0, -1 + clhhsi 0, 65536 diff --git a/test/MC/SystemZ/insn-clhrl-01.s b/test/MC/SystemZ/insn-clhrl-01.s new file mode 100644 index 00000000000..b424de8f667 --- /dev/null +++ b/test/MC/SystemZ/insn-clhrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clhrl %r0, 2864434397 # encoding: [0xc6,0x07,0x55,0x5d,0xe6,0x6e] +#CHECK: clhrl %r15, 2864434397 # encoding: [0xc6,0xf7,0x55,0x5d,0xe6,0x6e] + + clhrl %r0,0xaabbccdd + clhrl %r15,0xaabbccdd + +#CHECK: clhrl %r0, foo # encoding: [0xc6,0x07,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: clhrl %r15, foo # encoding: [0xc6,0xf7,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + clhrl %r0,foo + clhrl %r15,foo + +#CHECK: clhrl %r3, bar+100 # encoding: [0xc6,0x37,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: clhrl %r4, bar+100 # encoding: [0xc6,0x47,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + clhrl %r3,bar+100 + clhrl %r4,bar+100 + +#CHECK: clhrl %r7, frob@PLT # encoding: [0xc6,0x77,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: clhrl %r8, frob@PLT # encoding: [0xc6,0x87,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + clhrl %r7,frob@PLT + clhrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-cli-01.s b/test/MC/SystemZ/insn-cli-01.s new file mode 100644 index 00000000000..23bccfab4b7 --- /dev/null +++ b/test/MC/SystemZ/insn-cli-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cli 0, 0 # encoding: [0x95,0x00,0x00,0x00] +#CHECK: cli 4095, 0 # encoding: [0x95,0x00,0x0f,0xff] +#CHECK: cli 0, 255 # encoding: [0x95,0xff,0x00,0x00] +#CHECK: cli 0(%r1), 42 # encoding: [0x95,0x2a,0x10,0x00] +#CHECK: cli 0(%r15), 42 # encoding: [0x95,0x2a,0xf0,0x00] +#CHECK: cli 4095(%r1), 42 # encoding: [0x95,0x2a,0x1f,0xff] +#CHECK: cli 4095(%r15), 42 # encoding: [0x95,0x2a,0xff,0xff] + + cli 0, 0 + cli 4095, 0 + cli 0, 255 + cli 0(%r1), 42 + cli 0(%r15), 42 + cli 4095(%r1), 42 + cli 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-cli-02.s b/test/MC/SystemZ/insn-cli-02.s new file mode 100644 index 00000000000..7fe6fdabfd3 --- /dev/null +++ b/test/MC/SystemZ/insn-cli-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cli -1, 0 +#CHECK: error: invalid operand +#CHECK: cli 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: cli 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: cli 0, -1 +#CHECK: error: invalid operand +#CHECK: cli 0, 256 + + cli -1, 0 + cli 4096, 0 + cli 0(%r1,%r2), 0 + cli 0, -1 + cli 0, 256 diff --git a/test/MC/SystemZ/insn-cliy-01.s b/test/MC/SystemZ/insn-cliy-01.s new file mode 100644 index 00000000000..1a26f605d8b --- /dev/null +++ b/test/MC/SystemZ/insn-cliy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cliy -524288, 0 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x55] +#CHECK: cliy -1, 0 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x55] +#CHECK: cliy 0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x55] +#CHECK: cliy 1, 0 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x55] +#CHECK: cliy 524287, 0 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x55] +#CHECK: cliy 0, 255 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x55] +#CHECK: cliy 0(%r1), 42 # encoding: [0xeb,0x2a,0x10,0x00,0x00,0x55] +#CHECK: cliy 0(%r15), 42 # encoding: [0xeb,0x2a,0xf0,0x00,0x00,0x55] +#CHECK: cliy 524287(%r1), 42 # encoding: [0xeb,0x2a,0x1f,0xff,0x7f,0x55] +#CHECK: cliy 524287(%r15), 42 # encoding: [0xeb,0x2a,0xff,0xff,0x7f,0x55] + + cliy -524288, 0 + cliy -1, 0 + cliy 0, 0 + cliy 1, 0 + cliy 524287, 0 + cliy 0, 255 + cliy 0(%r1), 42 + cliy 0(%r15), 42 + cliy 524287(%r1), 42 + cliy 524287(%r15), 42 diff --git a/test/MC/SystemZ/insn-cliy-02.s b/test/MC/SystemZ/insn-cliy-02.s new file mode 100644 index 00000000000..3e8056315d7 --- /dev/null +++ b/test/MC/SystemZ/insn-cliy-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cliy -524289, 0 +#CHECK: error: invalid operand +#CHECK: cliy 524288, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: cliy 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: cliy 0, -1 +#CHECK: error: invalid operand +#CHECK: cliy 0, 256 + + cliy -524289, 0 + cliy 524288, 0 + cliy 0(%r1,%r2), 0 + cliy 0, -1 + cliy 0, 256 diff --git a/test/MC/SystemZ/insn-clr-01.s b/test/MC/SystemZ/insn-clr-01.s new file mode 100644 index 00000000000..d187d4e3e82 --- /dev/null +++ b/test/MC/SystemZ/insn-clr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clr %r0, %r0 # encoding: [0x15,0x00] +#CHECK: clr %r0, %r15 # encoding: [0x15,0x0f] +#CHECK: clr %r15, %r0 # encoding: [0x15,0xf0] +#CHECK: clr %r7, %r8 # encoding: [0x15,0x78] + + clr %r0,%r0 + clr %r0,%r15 + clr %r15,%r0 + clr %r7,%r8 diff --git a/test/MC/SystemZ/insn-clrl-01.s b/test/MC/SystemZ/insn-clrl-01.s new file mode 100644 index 00000000000..4c6e649b439 --- /dev/null +++ b/test/MC/SystemZ/insn-clrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: clrl %r0, 2864434397 # encoding: [0xc6,0x0f,0x55,0x5d,0xe6,0x6e] +#CHECK: clrl %r15, 2864434397 # encoding: [0xc6,0xff,0x55,0x5d,0xe6,0x6e] + + clrl %r0,0xaabbccdd + clrl %r15,0xaabbccdd + +#CHECK: clrl %r0, foo # encoding: [0xc6,0x0f,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: clrl %r15, foo # encoding: [0xc6,0xff,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + clrl %r0,foo + clrl %r15,foo + +#CHECK: clrl %r3, bar+100 # encoding: [0xc6,0x3f,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: clrl %r4, bar+100 # encoding: [0xc6,0x4f,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + clrl %r3,bar+100 + clrl %r4,bar+100 + +#CHECK: clrl %r7, frob@PLT # encoding: [0xc6,0x7f,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: clrl %r8, frob@PLT # encoding: [0xc6,0x8f,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + clrl %r7,frob@PLT + clrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-cly-01.s b/test/MC/SystemZ/insn-cly-01.s new file mode 100644 index 00000000000..8fb4af683e6 --- /dev/null +++ b/test/MC/SystemZ/insn-cly-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cly %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x55] +#CHECK: cly %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x55] +#CHECK: cly %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x55] +#CHECK: cly %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x55] +#CHECK: cly %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x55] +#CHECK: cly %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x55] +#CHECK: cly %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x55] +#CHECK: cly %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x55] +#CHECK: cly %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x55] +#CHECK: cly %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x55] + + cly %r0, -524288 + cly %r0, -1 + cly %r0, 0 + cly %r0, 1 + cly %r0, 524287 + cly %r0, 0(%r1) + cly %r0, 0(%r15) + cly %r0, 524287(%r1,%r15) + cly %r0, 524287(%r15,%r1) + cly %r15, 0 diff --git a/test/MC/SystemZ/insn-cly-02.s b/test/MC/SystemZ/insn-cly-02.s new file mode 100644 index 00000000000..23f37a96cc4 --- /dev/null +++ b/test/MC/SystemZ/insn-cly-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cly %r0, -524289 +#CHECK: error: invalid operand +#CHECK: cly %r0, 524288 + + cly %r0, -524289 + cly %r0, 524288 diff --git a/test/MC/SystemZ/insn-cpsdr-01.s b/test/MC/SystemZ/insn-cpsdr-01.s new file mode 100644 index 00000000000..23d773dfc9c --- /dev/null +++ b/test/MC/SystemZ/insn-cpsdr-01.s @@ -0,0 +1,16 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cpsdr %f0, %f0, %f0 # encoding: [0xb3,0x72,0x00,0x00] +#CHECK: cpsdr %f0, %f0, %f15 # encoding: [0xb3,0x72,0x00,0x0f] +#CHECK: cpsdr %f0, %f15, %f0 # encoding: [0xb3,0x72,0xf0,0x00] +#CHECK: cpsdr %f15, %f0, %f0 # encoding: [0xb3,0x72,0x00,0xf0] +#CHECK: cpsdr %f1, %f2, %f3 # encoding: [0xb3,0x72,0x20,0x13] +#CHECK: cpsdr %f15, %f15, %f15 # encoding: [0xb3,0x72,0xf0,0xff] + + cpsdr %f0, %f0, %f0 + cpsdr %f0, %f0, %f15 + cpsdr %f0, %f15, %f0 + cpsdr %f15, %f0, %f0 + cpsdr %f1, %f2, %f3 + cpsdr %f15, %f15, %f15 + diff --git a/test/MC/SystemZ/insn-cr-01.s b/test/MC/SystemZ/insn-cr-01.s new file mode 100644 index 00000000000..d77e08513fc --- /dev/null +++ b/test/MC/SystemZ/insn-cr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cr %r0, %r0 # encoding: [0x19,0x00] +#CHECK: cr %r0, %r15 # encoding: [0x19,0x0f] +#CHECK: cr %r15, %r0 # encoding: [0x19,0xf0] +#CHECK: cr %r7, %r8 # encoding: [0x19,0x78] + + cr %r0,%r0 + cr %r0,%r15 + cr %r15,%r0 + cr %r7,%r8 diff --git a/test/MC/SystemZ/insn-crl-01.s b/test/MC/SystemZ/insn-crl-01.s new file mode 100644 index 00000000000..2451b4c9f82 --- /dev/null +++ b/test/MC/SystemZ/insn-crl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: crl %r0, 2864434397 # encoding: [0xc6,0x0d,0x55,0x5d,0xe6,0x6e] +#CHECK: crl %r15, 2864434397 # encoding: [0xc6,0xfd,0x55,0x5d,0xe6,0x6e] + + crl %r0,0xaabbccdd + crl %r15,0xaabbccdd + +#CHECK: crl %r0, foo # encoding: [0xc6,0x0d,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: crl %r15, foo # encoding: [0xc6,0xfd,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + crl %r0,foo + crl %r15,foo + +#CHECK: crl %r3, bar+100 # encoding: [0xc6,0x3d,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: crl %r4, bar+100 # encoding: [0xc6,0x4d,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + crl %r3,bar+100 + crl %r4,bar+100 + +#CHECK: crl %r7, frob@PLT # encoding: [0xc6,0x7d,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: crl %r8, frob@PLT # encoding: [0xc6,0x8d,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + crl %r7,frob@PLT + crl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-cs-01.s b/test/MC/SystemZ/insn-cs-01.s new file mode 100644 index 00000000000..3fc6c34b740 --- /dev/null +++ b/test/MC/SystemZ/insn-cs-01.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cs %r0, %r0, 0 # encoding: [0xba,0x00,0x00,0x00] +#CHECK: cs %r0, %r0, 4095 # encoding: [0xba,0x00,0x0f,0xff] +#CHECK: cs %r0, %r0, 0(%r1) # encoding: [0xba,0x00,0x10,0x00] +#CHECK: cs %r0, %r0, 0(%r15) # encoding: [0xba,0x00,0xf0,0x00] +#CHECK: cs %r0, %r0, 4095(%r1) # encoding: [0xba,0x00,0x1f,0xff] +#CHECK: cs %r0, %r0, 4095(%r15) # encoding: [0xba,0x00,0xff,0xff] +#CHECK: cs %r0, %r15, 0 # encoding: [0xba,0x0f,0x00,0x00] +#CHECK: cs %r15, %r0, 0 # encoding: [0xba,0xf0,0x00,0x00] + + cs %r0, %r0, 0 + cs %r0, %r0, 4095 + cs %r0, %r0, 0(%r1) + cs %r0, %r0, 0(%r15) + cs %r0, %r0, 4095(%r1) + cs %r0, %r0, 4095(%r15) + cs %r0, %r15, 0 + cs %r15, %r0, 0 diff --git a/test/MC/SystemZ/insn-cs-02.s b/test/MC/SystemZ/insn-cs-02.s new file mode 100644 index 00000000000..c22795998dd --- /dev/null +++ b/test/MC/SystemZ/insn-cs-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cs %r0, %r0, -1 +#CHECK: error: invalid operand +#CHECK: cs %r0, %r0, 4096 +#CHECK: error: invalid use of indexed addressing +#CHECK: cs %r0, %r0, 0(%r1,%r2) + + cs %r0, %r0, -1 + cs %r0, %r0, 4096 + cs %r0, %r0, 0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-csg-01.s b/test/MC/SystemZ/insn-csg-01.s new file mode 100644 index 00000000000..b0fcfa6450a --- /dev/null +++ b/test/MC/SystemZ/insn-csg-01.s @@ -0,0 +1,25 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: csg %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x30] +#CHECK: csg %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x30] +#CHECK: csg %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x30] +#CHECK: csg %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x30] +#CHECK: csg %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x30] +#CHECK: csg %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x30] +#CHECK: csg %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x30] +#CHECK: csg %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x30] +#CHECK: csg %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x30] +#CHECK: csg %r0, %r15, 0 # encoding: [0xeb,0x0f,0x00,0x00,0x00,0x30] +#CHECK: csg %r15, %r0, 0 # encoding: [0xeb,0xf0,0x00,0x00,0x00,0x30] + + csg %r0, %r0, -524288 + csg %r0, %r0, -1 + csg %r0, %r0, 0 + csg %r0, %r0, 1 + csg %r0, %r0, 524287 + csg %r0, %r0, 0(%r1) + csg %r0, %r0, 0(%r15) + csg %r0, %r0, 524287(%r1) + csg %r0, %r0, 524287(%r15) + csg %r0, %r15, 0 + csg %r15, %r0, 0 diff --git a/test/MC/SystemZ/insn-csg-02.s b/test/MC/SystemZ/insn-csg-02.s new file mode 100644 index 00000000000..816b155930b --- /dev/null +++ b/test/MC/SystemZ/insn-csg-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: csg %r0, %r0, -524289 +#CHECK: error: invalid operand +#CHECK: csg %r0, %r0, 524288 +#CHECK: error: invalid use of indexed addressing +#CHECK: csg %r0, %r0, 0(%r1,%r2) + + csg %r0, %r0, -524289 + csg %r0, %r0, 524288 + csg %r0, %r0, 0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-csy-01.s b/test/MC/SystemZ/insn-csy-01.s new file mode 100644 index 00000000000..d19b2df703c --- /dev/null +++ b/test/MC/SystemZ/insn-csy-01.s @@ -0,0 +1,25 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: csy %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x14] +#CHECK: csy %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x14] +#CHECK: csy %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x14] +#CHECK: csy %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x14] +#CHECK: csy %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x14] +#CHECK: csy %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x14] +#CHECK: csy %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x14] +#CHECK: csy %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x14] +#CHECK: csy %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x14] +#CHECK: csy %r0, %r15, 0 # encoding: [0xeb,0x0f,0x00,0x00,0x00,0x14] +#CHECK: csy %r15, %r0, 0 # encoding: [0xeb,0xf0,0x00,0x00,0x00,0x14] + + csy %r0, %r0, -524288 + csy %r0, %r0, -1 + csy %r0, %r0, 0 + csy %r0, %r0, 1 + csy %r0, %r0, 524287 + csy %r0, %r0, 0(%r1) + csy %r0, %r0, 0(%r15) + csy %r0, %r0, 524287(%r1) + csy %r0, %r0, 524287(%r15) + csy %r0, %r15, 0 + csy %r15, %r0, 0 diff --git a/test/MC/SystemZ/insn-csy-02.s b/test/MC/SystemZ/insn-csy-02.s new file mode 100644 index 00000000000..3ff795909b4 --- /dev/null +++ b/test/MC/SystemZ/insn-csy-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: csy %r0, %r0, -524289 +#CHECK: error: invalid operand +#CHECK: csy %r0, %r0, 524288 +#CHECK: error: invalid use of indexed addressing +#CHECK: csy %r0, %r0, 0(%r1,%r2) + + csy %r0, %r0, -524289 + csy %r0, %r0, 524288 + csy %r0, %r0, 0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-cxbr-01.s b/test/MC/SystemZ/insn-cxbr-01.s new file mode 100644 index 00000000000..79527f0c503 --- /dev/null +++ b/test/MC/SystemZ/insn-cxbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cxbr %f0, %f0 # encoding: [0xb3,0x49,0x00,0x00] +#CHECK: cxbr %f0, %f13 # encoding: [0xb3,0x49,0x00,0x0d] +#CHECK: cxbr %f8, %f8 # encoding: [0xb3,0x49,0x00,0x88] +#CHECK: cxbr %f13, %f0 # encoding: [0xb3,0x49,0x00,0xd0] + + cxbr %f0, %f0 + cxbr %f0, %f13 + cxbr %f8, %f8 + cxbr %f13, %f0 diff --git a/test/MC/SystemZ/insn-cxbr-02.s b/test/MC/SystemZ/insn-cxbr-02.s new file mode 100644 index 00000000000..7aaca91c5f2 --- /dev/null +++ b/test/MC/SystemZ/insn-cxbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: cxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: cxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: cxbr %f14, %f0 + + cxbr %f0, %f2 + cxbr %f0, %f14 + cxbr %f2, %f0 + cxbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-cxfbr-01.s b/test/MC/SystemZ/insn-cxfbr-01.s new file mode 100644 index 00000000000..14bafd12071 --- /dev/null +++ b/test/MC/SystemZ/insn-cxfbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cxfbr %f0, %r0 # encoding: [0xb3,0x96,0x00,0x00] +#CHECK: cxfbr %f0, %r15 # encoding: [0xb3,0x96,0x00,0x0f] +#CHECK: cxfbr %f13, %r0 # encoding: [0xb3,0x96,0x00,0xd0] +#CHECK: cxfbr %f8, %r7 # encoding: [0xb3,0x96,0x00,0x87] +#CHECK: cxfbr %f13, %r15 # encoding: [0xb3,0x96,0x00,0xdf] + + cxfbr %f0, %r0 + cxfbr %f0, %r15 + cxfbr %f13, %r0 + cxfbr %f8, %r7 + cxfbr %f13, %r15 diff --git a/test/MC/SystemZ/insn-cxfbr-02.s b/test/MC/SystemZ/insn-cxfbr-02.s new file mode 100644 index 00000000000..5343378569c --- /dev/null +++ b/test/MC/SystemZ/insn-cxfbr-02.s @@ -0,0 +1,22 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cxfbr %r0, %r0 +#CHECK: error: invalid register +#CHECK: cxfbr %f0, %f0 +#CHECK: error: invalid register +#CHECK: cxfbr %f0, %a0 +#CHECK: error: invalid register +#CHECK: cxfbr %a0, %r0 +#CHECK: error: invalid register +#CHECK: cxfbr %f2, %r0 +#CHECK: error: invalid register +#CHECK: cxfbr %f14, %r0 + + cxfbr %r0, %r0 + cxfbr %f0, %f0 + cxfbr %f0, %a0 + cxfbr %a0, %r0 + cxfbr %f2, %r0 + cxfbr %f14, %r0 diff --git a/test/MC/SystemZ/insn-cxgbr-01.s b/test/MC/SystemZ/insn-cxgbr-01.s new file mode 100644 index 00000000000..90914b44e9a --- /dev/null +++ b/test/MC/SystemZ/insn-cxgbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cxgbr %f0, %r0 # encoding: [0xb3,0xa6,0x00,0x00] +#CHECK: cxgbr %f0, %r15 # encoding: [0xb3,0xa6,0x00,0x0f] +#CHECK: cxgbr %f13, %r0 # encoding: [0xb3,0xa6,0x00,0xd0] +#CHECK: cxgbr %f8, %r7 # encoding: [0xb3,0xa6,0x00,0x87] +#CHECK: cxgbr %f13, %r15 # encoding: [0xb3,0xa6,0x00,0xdf] + + cxgbr %f0, %r0 + cxgbr %f0, %r15 + cxgbr %f13, %r0 + cxgbr %f8, %r7 + cxgbr %f13, %r15 diff --git a/test/MC/SystemZ/insn-cxgbr-02.s b/test/MC/SystemZ/insn-cxgbr-02.s new file mode 100644 index 00000000000..d10664dba7c --- /dev/null +++ b/test/MC/SystemZ/insn-cxgbr-02.s @@ -0,0 +1,22 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: cxgbr %r0, %r0 +#CHECK: error: invalid register +#CHECK: cxgbr %f0, %f0 +#CHECK: error: invalid register +#CHECK: cxgbr %f0, %a0 +#CHECK: error: invalid register +#CHECK: cxgbr %a0, %r0 +#CHECK: error: invalid register +#CHECK: cxgbr %f2, %r0 +#CHECK: error: invalid register +#CHECK: cxgbr %f14, %r0 + + cxgbr %r0, %r0 + cxgbr %f0, %f0 + cxgbr %f0, %a0 + cxgbr %a0, %r0 + cxgbr %f2, %r0 + cxgbr %f14, %r0 diff --git a/test/MC/SystemZ/insn-cy-01.s b/test/MC/SystemZ/insn-cy-01.s new file mode 100644 index 00000000000..5f21b963ff9 --- /dev/null +++ b/test/MC/SystemZ/insn-cy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: cy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x59] +#CHECK: cy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x59] +#CHECK: cy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x59] +#CHECK: cy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x59] +#CHECK: cy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x59] +#CHECK: cy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x59] +#CHECK: cy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x59] +#CHECK: cy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x59] +#CHECK: cy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x59] +#CHECK: cy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x59] + + cy %r0, -524288 + cy %r0, -1 + cy %r0, 0 + cy %r0, 1 + cy %r0, 524287 + cy %r0, 0(%r1) + cy %r0, 0(%r15) + cy %r0, 524287(%r1,%r15) + cy %r0, 524287(%r15,%r1) + cy %r15, 0 diff --git a/test/MC/SystemZ/insn-cy-02.s b/test/MC/SystemZ/insn-cy-02.s new file mode 100644 index 00000000000..1c996cdced3 --- /dev/null +++ b/test/MC/SystemZ/insn-cy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: cy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: cy %r0, 524288 + + cy %r0, -524289 + cy %r0, 524288 diff --git a/test/MC/SystemZ/insn-ddb-01.s b/test/MC/SystemZ/insn-ddb-01.s new file mode 100644 index 00000000000..417af11c08a --- /dev/null +++ b/test/MC/SystemZ/insn-ddb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ddb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x1d] +#CHECK: ddb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x1d] +#CHECK: ddb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x1d] +#CHECK: ddb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x1d] +#CHECK: ddb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x1d] +#CHECK: ddb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x1d] +#CHECK: ddb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x1d] + + ddb %f0, 0 + ddb %f0, 4095 + ddb %f0, 0(%r1) + ddb %f0, 0(%r15) + ddb %f0, 4095(%r1,%r15) + ddb %f0, 4095(%r15,%r1) + ddb %f15, 0 diff --git a/test/MC/SystemZ/insn-ddb-02.s b/test/MC/SystemZ/insn-ddb-02.s new file mode 100644 index 00000000000..c6357d10e42 --- /dev/null +++ b/test/MC/SystemZ/insn-ddb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ddb %f0, -1 +#CHECK: error: invalid operand +#CHECK: ddb %f0, 4096 + + ddb %f0, -1 + ddb %f0, 4096 diff --git a/test/MC/SystemZ/insn-ddbr-01.s b/test/MC/SystemZ/insn-ddbr-01.s new file mode 100644 index 00000000000..7ee1fee5b37 --- /dev/null +++ b/test/MC/SystemZ/insn-ddbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ddbr %f0, %f0 # encoding: [0xb3,0x1d,0x00,0x00] +#CHECK: ddbr %f0, %f15 # encoding: [0xb3,0x1d,0x00,0x0f] +#CHECK: ddbr %f7, %f8 # encoding: [0xb3,0x1d,0x00,0x78] +#CHECK: ddbr %f15, %f0 # encoding: [0xb3,0x1d,0x00,0xf0] + + ddbr %f0, %f0 + ddbr %f0, %f15 + ddbr %f7, %f8 + ddbr %f15, %f0 diff --git a/test/MC/SystemZ/insn-deb-01.s b/test/MC/SystemZ/insn-deb-01.s new file mode 100644 index 00000000000..93cfb024648 --- /dev/null +++ b/test/MC/SystemZ/insn-deb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: deb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x0d] +#CHECK: deb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x0d] +#CHECK: deb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x0d] +#CHECK: deb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x0d] +#CHECK: deb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x0d] +#CHECK: deb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x0d] +#CHECK: deb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x0d] + + deb %f0, 0 + deb %f0, 4095 + deb %f0, 0(%r1) + deb %f0, 0(%r15) + deb %f0, 4095(%r1,%r15) + deb %f0, 4095(%r15,%r1) + deb %f15, 0 diff --git a/test/MC/SystemZ/insn-deb-02.s b/test/MC/SystemZ/insn-deb-02.s new file mode 100644 index 00000000000..e4edd4ef86d --- /dev/null +++ b/test/MC/SystemZ/insn-deb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: deb %f0, -1 +#CHECK: error: invalid operand +#CHECK: deb %f0, 4096 + + deb %f0, -1 + deb %f0, 4096 diff --git a/test/MC/SystemZ/insn-debr-01.s b/test/MC/SystemZ/insn-debr-01.s new file mode 100644 index 00000000000..02ee16c9cf4 --- /dev/null +++ b/test/MC/SystemZ/insn-debr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: debr %f0, %f0 # encoding: [0xb3,0x0d,0x00,0x00] +#CHECK: debr %f0, %f15 # encoding: [0xb3,0x0d,0x00,0x0f] +#CHECK: debr %f7, %f8 # encoding: [0xb3,0x0d,0x00,0x78] +#CHECK: debr %f15, %f0 # encoding: [0xb3,0x0d,0x00,0xf0] + + debr %f0, %f0 + debr %f0, %f15 + debr %f7, %f8 + debr %f15, %f0 diff --git a/test/MC/SystemZ/insn-dl-01.s b/test/MC/SystemZ/insn-dl-01.s new file mode 100644 index 00000000000..50b24e7a00d --- /dev/null +++ b/test/MC/SystemZ/insn-dl-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dl %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x97] +#CHECK: dl %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x97] +#CHECK: dl %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x97] +#CHECK: dl %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x97] +#CHECK: dl %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x97] +#CHECK: dl %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x97] +#CHECK: dl %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x97] +#CHECK: dl %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x97] +#CHECK: dl %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x97] +#CHECK: dl %r14, 0 # encoding: [0xe3,0xe0,0x00,0x00,0x00,0x97] + + dl %r0, -524288 + dl %r0, -1 + dl %r0, 0 + dl %r0, 1 + dl %r0, 524287 + dl %r0, 0(%r1) + dl %r0, 0(%r15) + dl %r0, 524287(%r1,%r15) + dl %r0, 524287(%r15,%r1) + dl %r14, 0 diff --git a/test/MC/SystemZ/insn-dl-02.s b/test/MC/SystemZ/insn-dl-02.s new file mode 100644 index 00000000000..8f9f37320b8 --- /dev/null +++ b/test/MC/SystemZ/insn-dl-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: dl %r0, -524289 +#CHECK: error: invalid operand +#CHECK: dl %r0, 524288 +#CHECK: error: invalid register +#CHECK: dl %r1, 0 +#CHECK: error: invalid register +#CHECK: dl %r15, 0 + + dl %r0, -524289 + dl %r0, 524288 + dl %r1, 0 + dl %r15, 0 diff --git a/test/MC/SystemZ/insn-dlg-01.s b/test/MC/SystemZ/insn-dlg-01.s new file mode 100644 index 00000000000..8a304f828ec --- /dev/null +++ b/test/MC/SystemZ/insn-dlg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dlg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x87] +#CHECK: dlg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x87] +#CHECK: dlg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x87] +#CHECK: dlg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x87] +#CHECK: dlg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x87] +#CHECK: dlg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x87] +#CHECK: dlg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x87] +#CHECK: dlg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x87] +#CHECK: dlg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x87] +#CHECK: dlg %r14, 0 # encoding: [0xe3,0xe0,0x00,0x00,0x00,0x87] + + dlg %r0, -524288 + dlg %r0, -1 + dlg %r0, 0 + dlg %r0, 1 + dlg %r0, 524287 + dlg %r0, 0(%r1) + dlg %r0, 0(%r15) + dlg %r0, 524287(%r1,%r15) + dlg %r0, 524287(%r15,%r1) + dlg %r14, 0 diff --git a/test/MC/SystemZ/insn-dlg-02.s b/test/MC/SystemZ/insn-dlg-02.s new file mode 100644 index 00000000000..cbed8981732 --- /dev/null +++ b/test/MC/SystemZ/insn-dlg-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: dlg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: dlg %r0, 524288 +#CHECK: error: invalid register +#CHECK: dlg %r1, 0 +#CHECK: error: invalid register +#CHECK: dlg %r15, 0 + + dlg %r0, -524289 + dlg %r0, 524288 + dlg %r1, 0 + dlg %r15, 0 diff --git a/test/MC/SystemZ/insn-dlgr-01.s b/test/MC/SystemZ/insn-dlgr-01.s new file mode 100644 index 00000000000..b2a4de5f91f --- /dev/null +++ b/test/MC/SystemZ/insn-dlgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dlgr %r0, %r0 # encoding: [0xb9,0x87,0x00,0x00] +#CHECK: dlgr %r0, %r15 # encoding: [0xb9,0x87,0x00,0x0f] +#CHECK: dlgr %r14, %r0 # encoding: [0xb9,0x87,0x00,0xe0] +#CHECK: dlgr %r6, %r9 # encoding: [0xb9,0x87,0x00,0x69] + + dlgr %r0,%r0 + dlgr %r0,%r15 + dlgr %r14,%r0 + dlgr %r6,%r9 diff --git a/test/MC/SystemZ/insn-dlgr-02.s b/test/MC/SystemZ/insn-dlgr-02.s new file mode 100644 index 00000000000..c407b4fb0bf --- /dev/null +++ b/test/MC/SystemZ/insn-dlgr-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: dlgr %r1, %r0 +#CHECK: error: invalid register +#CHECK: dlgr %r15, %r0 + + dlgr %r1, %r0 + dlgr %r15, %r0 diff --git a/test/MC/SystemZ/insn-dlr-01.s b/test/MC/SystemZ/insn-dlr-01.s new file mode 100644 index 00000000000..7e8be79e46a --- /dev/null +++ b/test/MC/SystemZ/insn-dlr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dlr %r0, %r0 # encoding: [0xb9,0x97,0x00,0x00] +#CHECK: dlr %r0, %r15 # encoding: [0xb9,0x97,0x00,0x0f] +#CHECK: dlr %r14, %r0 # encoding: [0xb9,0x97,0x00,0xe0] +#CHECK: dlr %r6, %r9 # encoding: [0xb9,0x97,0x00,0x69] + + dlr %r0,%r0 + dlr %r0,%r15 + dlr %r14,%r0 + dlr %r6,%r9 diff --git a/test/MC/SystemZ/insn-dlr-02.s b/test/MC/SystemZ/insn-dlr-02.s new file mode 100644 index 00000000000..eb31e18fd87 --- /dev/null +++ b/test/MC/SystemZ/insn-dlr-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: dlr %r1, %r0 +#CHECK: error: invalid register +#CHECK: dlr %r15, %r0 + + dlr %r1, %r0 + dlr %r15, %r0 diff --git a/test/MC/SystemZ/insn-dsg-01.s b/test/MC/SystemZ/insn-dsg-01.s new file mode 100644 index 00000000000..5cd0b40a9fb --- /dev/null +++ b/test/MC/SystemZ/insn-dsg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dsg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x0d] +#CHECK: dsg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x0d] +#CHECK: dsg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x0d] +#CHECK: dsg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x0d] +#CHECK: dsg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x0d] +#CHECK: dsg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x0d] +#CHECK: dsg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x0d] +#CHECK: dsg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x0d] +#CHECK: dsg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x0d] +#CHECK: dsg %r14, 0 # encoding: [0xe3,0xe0,0x00,0x00,0x00,0x0d] + + dsg %r0, -524288 + dsg %r0, -1 + dsg %r0, 0 + dsg %r0, 1 + dsg %r0, 524287 + dsg %r0, 0(%r1) + dsg %r0, 0(%r15) + dsg %r0, 524287(%r1,%r15) + dsg %r0, 524287(%r15,%r1) + dsg %r14, 0 diff --git a/test/MC/SystemZ/insn-dsg-02.s b/test/MC/SystemZ/insn-dsg-02.s new file mode 100644 index 00000000000..16979418c48 --- /dev/null +++ b/test/MC/SystemZ/insn-dsg-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: dsg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: dsg %r0, 524288 +#CHECK: error: invalid register +#CHECK: dsg %r1, 0 +#CHECK: error: invalid register +#CHECK: dsg %r15, 0 + + dsg %r0, -524289 + dsg %r0, 524288 + dsg %r1, 0 + dsg %r15, 0 diff --git a/test/MC/SystemZ/insn-dsgf-01.s b/test/MC/SystemZ/insn-dsgf-01.s new file mode 100644 index 00000000000..2cde0c79d9d --- /dev/null +++ b/test/MC/SystemZ/insn-dsgf-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dsgf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x1d] +#CHECK: dsgf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x1d] +#CHECK: dsgf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x1d] +#CHECK: dsgf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x1d] +#CHECK: dsgf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x1d] +#CHECK: dsgf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x1d] +#CHECK: dsgf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x1d] +#CHECK: dsgf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x1d] +#CHECK: dsgf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x1d] +#CHECK: dsgf %r14, 0 # encoding: [0xe3,0xe0,0x00,0x00,0x00,0x1d] + + dsgf %r0, -524288 + dsgf %r0, -1 + dsgf %r0, 0 + dsgf %r0, 1 + dsgf %r0, 524287 + dsgf %r0, 0(%r1) + dsgf %r0, 0(%r15) + dsgf %r0, 524287(%r1,%r15) + dsgf %r0, 524287(%r15,%r1) + dsgf %r14, 0 diff --git a/test/MC/SystemZ/insn-dsgf-02.s b/test/MC/SystemZ/insn-dsgf-02.s new file mode 100644 index 00000000000..253d9ad70be --- /dev/null +++ b/test/MC/SystemZ/insn-dsgf-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: dsgf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: dsgf %r0, 524288 +#CHECK: error: invalid register +#CHECK: dsgf %r1, 0 +#CHECK: error: invalid register +#CHECK: dsgf %r15, 0 + + dsgf %r0, -524289 + dsgf %r0, 524288 + dsgf %r1, 0 + dsgf %r15, 0 diff --git a/test/MC/SystemZ/insn-dsgfr-01.s b/test/MC/SystemZ/insn-dsgfr-01.s new file mode 100644 index 00000000000..9b61550ffcb --- /dev/null +++ b/test/MC/SystemZ/insn-dsgfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dsgfr %r0, %r0 # encoding: [0xb9,0x1d,0x00,0x00] +#CHECK: dsgfr %r0, %r15 # encoding: [0xb9,0x1d,0x00,0x0f] +#CHECK: dsgfr %r14, %r0 # encoding: [0xb9,0x1d,0x00,0xe0] +#CHECK: dsgfr %r6, %r9 # encoding: [0xb9,0x1d,0x00,0x69] + + dsgfr %r0,%r0 + dsgfr %r0,%r15 + dsgfr %r14,%r0 + dsgfr %r6,%r9 diff --git a/test/MC/SystemZ/insn-dsgfr-02.s b/test/MC/SystemZ/insn-dsgfr-02.s new file mode 100644 index 00000000000..2eb8b239472 --- /dev/null +++ b/test/MC/SystemZ/insn-dsgfr-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: dsgfr %r1, %r0 +#CHECK: error: invalid register +#CHECK: dsgfr %r15, %r0 + + dsgfr %r1, %r0 + dsgfr %r15, %r0 diff --git a/test/MC/SystemZ/insn-dsgr-01.s b/test/MC/SystemZ/insn-dsgr-01.s new file mode 100644 index 00000000000..02b4099cfaa --- /dev/null +++ b/test/MC/SystemZ/insn-dsgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dsgr %r0, %r0 # encoding: [0xb9,0x0d,0x00,0x00] +#CHECK: dsgr %r0, %r15 # encoding: [0xb9,0x0d,0x00,0x0f] +#CHECK: dsgr %r14, %r0 # encoding: [0xb9,0x0d,0x00,0xe0] +#CHECK: dsgr %r6, %r9 # encoding: [0xb9,0x0d,0x00,0x69] + + dsgr %r0,%r0 + dsgr %r0,%r15 + dsgr %r14,%r0 + dsgr %r6,%r9 diff --git a/test/MC/SystemZ/insn-dsgr-02.s b/test/MC/SystemZ/insn-dsgr-02.s new file mode 100644 index 00000000000..01942958069 --- /dev/null +++ b/test/MC/SystemZ/insn-dsgr-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: dsgr %r1, %r0 +#CHECK: error: invalid register +#CHECK: dsgr %r15, %r0 + + dsgr %r1, %r0 + dsgr %r15, %r0 diff --git a/test/MC/SystemZ/insn-dxbr-01.s b/test/MC/SystemZ/insn-dxbr-01.s new file mode 100644 index 00000000000..6a452080ced --- /dev/null +++ b/test/MC/SystemZ/insn-dxbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dxbr %f0, %f0 # encoding: [0xb3,0x4d,0x00,0x00] +#CHECK: dxbr %f0, %f13 # encoding: [0xb3,0x4d,0x00,0x0d] +#CHECK: dxbr %f8, %f8 # encoding: [0xb3,0x4d,0x00,0x88] +#CHECK: dxbr %f13, %f0 # encoding: [0xb3,0x4d,0x00,0xd0] + + dxbr %f0, %f0 + dxbr %f0, %f13 + dxbr %f8, %f8 + dxbr %f13, %f0 diff --git a/test/MC/SystemZ/insn-dxbr-02.s b/test/MC/SystemZ/insn-dxbr-02.s new file mode 100644 index 00000000000..cac64191b8b --- /dev/null +++ b/test/MC/SystemZ/insn-dxbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: dxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: dxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: dxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: dxbr %f14, %f0 + + dxbr %f0, %f2 + dxbr %f0, %f14 + dxbr %f2, %f0 + dxbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-ear-01.s b/test/MC/SystemZ/insn-ear-01.s new file mode 100644 index 00000000000..f614f86999b --- /dev/null +++ b/test/MC/SystemZ/insn-ear-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ear %r0, %a0 # encoding: [0xb2,0x4f,0x00,0x00] +#CHECK: ear %r0, %a15 # encoding: [0xb2,0x4f,0x00,0x0f] +#CHECK: ear %r15, %a0 # encoding: [0xb2,0x4f,0x00,0xf0] +#CHECK: ear %r7, %a8 # encoding: [0xb2,0x4f,0x00,0x78] +#CHECK: ear %r15, %a15 # encoding: [0xb2,0x4f,0x00,0xff] + + ear %r0, %a0 + ear %r0, %a15 + ear %r15, %a0 + ear %r7, %a8 + ear %r15, %a15 diff --git a/test/MC/SystemZ/insn-ear-02.s b/test/MC/SystemZ/insn-ear-02.s new file mode 100644 index 00000000000..7fb35eaa535 --- /dev/null +++ b/test/MC/SystemZ/insn-ear-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ear %r0, 0 +#CHECK: error: invalid register +#CHECK: ear %r0, %r0 +#CHECK: error: invalid register +#CHECK: ear %a0, %r0 + + ear %r0, 0 + ear %r0, %r0 + ear %a0, %r0 diff --git a/test/MC/SystemZ/insn-fidbr-01.s b/test/MC/SystemZ/insn-fidbr-01.s new file mode 100644 index 00000000000..e52c91c2114 --- /dev/null +++ b/test/MC/SystemZ/insn-fidbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: fidbr %f0, 0, %f0 # encoding: [0xb3,0x5f,0x00,0x00] +#CHECK: fidbr %f0, 0, %f15 # encoding: [0xb3,0x5f,0x00,0x0f] +#CHECK: fidbr %f0, 15, %f0 # encoding: [0xb3,0x5f,0xf0,0x00] +#CHECK: fidbr %f4, 5, %f6 # encoding: [0xb3,0x5f,0x50,0x46] +#CHECK: fidbr %f15, 0, %f0 # encoding: [0xb3,0x5f,0x00,0xf0] + + fidbr %f0, 0, %f0 + fidbr %f0, 0, %f15 + fidbr %f0, 15, %f0 + fidbr %f4, 5, %f6 + fidbr %f15, 0, %f0 diff --git a/test/MC/SystemZ/insn-fidbr-02.s b/test/MC/SystemZ/insn-fidbr-02.s new file mode 100644 index 00000000000..5a35f46589b --- /dev/null +++ b/test/MC/SystemZ/insn-fidbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: fidbr %r0, 0, %f0 +#CHECK: error: invalid register +#CHECK: fidbr %f0, 0, %r0 +#CHECK: error: invalid operand +#CHECK: fidbr %f0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: fidbr %f0, 16, %f0 + + fidbr %r0, 0, %f0 + fidbr %f0, 0, %r0 + fidbr %f0, -1, %f0 + fidbr %f0, 16, %f0 diff --git a/test/MC/SystemZ/insn-fiebr-01.s b/test/MC/SystemZ/insn-fiebr-01.s new file mode 100644 index 00000000000..0b4e633a1ed --- /dev/null +++ b/test/MC/SystemZ/insn-fiebr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: fiebr %f0, 0, %f0 # encoding: [0xb3,0x57,0x00,0x00] +#CHECK: fiebr %f0, 0, %f15 # encoding: [0xb3,0x57,0x00,0x0f] +#CHECK: fiebr %f0, 15, %f0 # encoding: [0xb3,0x57,0xf0,0x00] +#CHECK: fiebr %f4, 5, %f6 # encoding: [0xb3,0x57,0x50,0x46] +#CHECK: fiebr %f15, 0, %f0 # encoding: [0xb3,0x57,0x00,0xf0] + + fiebr %f0, 0, %f0 + fiebr %f0, 0, %f15 + fiebr %f0, 15, %f0 + fiebr %f4, 5, %f6 + fiebr %f15, 0, %f0 diff --git a/test/MC/SystemZ/insn-fiebr-02.s b/test/MC/SystemZ/insn-fiebr-02.s new file mode 100644 index 00000000000..2ecdd4d1bc0 --- /dev/null +++ b/test/MC/SystemZ/insn-fiebr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: fiebr %r0, 0, %f0 +#CHECK: error: invalid register +#CHECK: fiebr %f0, 0, %r0 +#CHECK: error: invalid operand +#CHECK: fiebr %f0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: fiebr %f0, 16, %f0 + + fiebr %r0, 0, %f0 + fiebr %f0, 0, %r0 + fiebr %f0, -1, %f0 + fiebr %f0, 16, %f0 diff --git a/test/MC/SystemZ/insn-fixbr-01.s b/test/MC/SystemZ/insn-fixbr-01.s new file mode 100644 index 00000000000..02676ed76d3 --- /dev/null +++ b/test/MC/SystemZ/insn-fixbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: fixbr %f0, 0, %f0 # encoding: [0xb3,0x47,0x00,0x00] +#CHECK: fixbr %f0, 0, %f13 # encoding: [0xb3,0x47,0x00,0x0d] +#CHECK: fixbr %f0, 15, %f0 # encoding: [0xb3,0x47,0xf0,0x00] +#CHECK: fixbr %f4, 5, %f8 # encoding: [0xb3,0x47,0x50,0x48] +#CHECK: fixbr %f13, 0, %f0 # encoding: [0xb3,0x47,0x00,0xd0] + + fixbr %f0, 0, %f0 + fixbr %f0, 0, %f13 + fixbr %f0, 15, %f0 + fixbr %f4, 5, %f8 + fixbr %f13, 0, %f0 diff --git a/test/MC/SystemZ/insn-fixbr-02.s b/test/MC/SystemZ/insn-fixbr-02.s new file mode 100644 index 00000000000..3f687342920 --- /dev/null +++ b/test/MC/SystemZ/insn-fixbr-02.s @@ -0,0 +1,28 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: fixbr %r0, 0, %f0 +#CHECK: error: invalid register +#CHECK: fixbr %f0, 0, %r0 +#CHECK: error: invalid operand +#CHECK: fixbr %f0, -1, %f0 +#CHECK: error: invalid operand +#CHECK: fixbr %f0, 16, %f0 +#CHECK: error: invalid register +#CHECK: fixbr %f0, 0, %f2 +#CHECK: error: invalid register +#CHECK: fixbr %f0, 0, %f14 +#CHECK: error: invalid register +#CHECK: fixbr %f2, 0, %f0 +#CHECK: error: invalid register +#CHECK: fixbr %f14, 0, %f0 + + fixbr %r0, 0, %f0 + fixbr %f0, 0, %r0 + fixbr %f0, -1, %f0 + fixbr %f0, 16, %f0 + fixbr %f0, 0, %f2 + fixbr %f0, 0, %f14 + fixbr %f2, 0, %f0 + fixbr %f14, 0, %f0 diff --git a/test/MC/SystemZ/insn-flogr-01.s b/test/MC/SystemZ/insn-flogr-01.s new file mode 100644 index 00000000000..f6031ce3b67 --- /dev/null +++ b/test/MC/SystemZ/insn-flogr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: flogr %r0, %r0 # encoding: [0xb9,0x83,0x00,0x00] +#CHECK: flogr %r0, %r15 # encoding: [0xb9,0x83,0x00,0x0f] +#CHECK: flogr %r10, %r9 # encoding: [0xb9,0x83,0x00,0xa9] +#CHECK: flogr %r14, %r0 # encoding: [0xb9,0x83,0x00,0xe0] + + flogr %r0, %r0 + flogr %r0, %r15 + flogr %r10, %r9 + flogr %r14, %r0 diff --git a/test/MC/SystemZ/insn-flogr-02.s b/test/MC/SystemZ/insn-flogr-02.s new file mode 100644 index 00000000000..e0d117c3be7 --- /dev/null +++ b/test/MC/SystemZ/insn-flogr-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: flogr %r1, %r0 +#CHECK: error: invalid register +#CHECK: flogr %r15, %r0 + + flogr %r1, %r0 + flogr %r15, %r0 diff --git a/test/MC/SystemZ/insn-ic-01.s b/test/MC/SystemZ/insn-ic-01.s new file mode 100644 index 00000000000..76772f9d1a0 --- /dev/null +++ b/test/MC/SystemZ/insn-ic-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ic %r0, 0 # encoding: [0x43,0x00,0x00,0x00] +#CHECK: ic %r0, 4095 # encoding: [0x43,0x00,0x0f,0xff] +#CHECK: ic %r0, 0(%r1) # encoding: [0x43,0x00,0x10,0x00] +#CHECK: ic %r0, 0(%r15) # encoding: [0x43,0x00,0xf0,0x00] +#CHECK: ic %r0, 4095(%r1,%r15) # encoding: [0x43,0x01,0xff,0xff] +#CHECK: ic %r0, 4095(%r15,%r1) # encoding: [0x43,0x0f,0x1f,0xff] +#CHECK: ic %r15, 0 # encoding: [0x43,0xf0,0x00,0x00] + + ic %r0, 0 + ic %r0, 4095 + ic %r0, 0(%r1) + ic %r0, 0(%r15) + ic %r0, 4095(%r1,%r15) + ic %r0, 4095(%r15,%r1) + ic %r15, 0 diff --git a/test/MC/SystemZ/insn-ic-02.s b/test/MC/SystemZ/insn-ic-02.s new file mode 100644 index 00000000000..e70ef1c58db --- /dev/null +++ b/test/MC/SystemZ/insn-ic-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ic %r0, -1 +#CHECK: error: invalid operand +#CHECK: ic %r0, 4096 + + ic %r0, -1 + ic %r0, 4096 diff --git a/test/MC/SystemZ/insn-icy-01.s b/test/MC/SystemZ/insn-icy-01.s new file mode 100644 index 00000000000..079ae2142f1 --- /dev/null +++ b/test/MC/SystemZ/insn-icy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: icy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x73] +#CHECK: icy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x73] +#CHECK: icy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x73] +#CHECK: icy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x73] +#CHECK: icy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x73] +#CHECK: icy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x73] +#CHECK: icy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x73] +#CHECK: icy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x73] +#CHECK: icy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x73] +#CHECK: icy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x73] + + icy %r0, -524288 + icy %r0, -1 + icy %r0, 0 + icy %r0, 1 + icy %r0, 524287 + icy %r0, 0(%r1) + icy %r0, 0(%r15) + icy %r0, 524287(%r1,%r15) + icy %r0, 524287(%r15,%r1) + icy %r15, 0 diff --git a/test/MC/SystemZ/insn-icy-02.s b/test/MC/SystemZ/insn-icy-02.s new file mode 100644 index 00000000000..321c86f9dff --- /dev/null +++ b/test/MC/SystemZ/insn-icy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: icy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: icy %r0, 524288 + + icy %r0, -524289 + icy %r0, 524288 diff --git a/test/MC/SystemZ/insn-iihf-01.s b/test/MC/SystemZ/insn-iihf-01.s new file mode 100644 index 00000000000..bf8d48fbc63 --- /dev/null +++ b/test/MC/SystemZ/insn-iihf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: iihf %r0, 0 # encoding: [0xc0,0x08,0x00,0x00,0x00,0x00] +#CHECK: iihf %r0, 4294967295 # encoding: [0xc0,0x08,0xff,0xff,0xff,0xff] +#CHECK: iihf %r15, 0 # encoding: [0xc0,0xf8,0x00,0x00,0x00,0x00] + + iihf %r0, 0 + iihf %r0, 0xffffffff + iihf %r15, 0 diff --git a/test/MC/SystemZ/insn-iihf-02.s b/test/MC/SystemZ/insn-iihf-02.s new file mode 100644 index 00000000000..1c7a69addf6 --- /dev/null +++ b/test/MC/SystemZ/insn-iihf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: iihf %r0, -1 +#CHECK: error: invalid operand +#CHECK: iihf %r0, 1 << 32 + + iihf %r0, -1 + iihf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-iihh-01.s b/test/MC/SystemZ/insn-iihh-01.s new file mode 100644 index 00000000000..a2ba9a33a45 --- /dev/null +++ b/test/MC/SystemZ/insn-iihh-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: iihh %r0, 0 # encoding: [0xa5,0x00,0x00,0x00] +#CHECK: iihh %r0, 32768 # encoding: [0xa5,0x00,0x80,0x00] +#CHECK: iihh %r0, 65535 # encoding: [0xa5,0x00,0xff,0xff] +#CHECK: iihh %r15, 0 # encoding: [0xa5,0xf0,0x00,0x00] + + iihh %r0, 0 + iihh %r0, 0x8000 + iihh %r0, 0xffff + iihh %r15, 0 diff --git a/test/MC/SystemZ/insn-iihh-02.s b/test/MC/SystemZ/insn-iihh-02.s new file mode 100644 index 00000000000..2d8f8541dd0 --- /dev/null +++ b/test/MC/SystemZ/insn-iihh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: iihh %r0, -1 +#CHECK: error: invalid operand +#CHECK: iihh %r0, 0x10000 + + iihh %r0, -1 + iihh %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-iihl-01.s b/test/MC/SystemZ/insn-iihl-01.s new file mode 100644 index 00000000000..ff591e8b869 --- /dev/null +++ b/test/MC/SystemZ/insn-iihl-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: iihl %r0, 0 # encoding: [0xa5,0x01,0x00,0x00] +#CHECK: iihl %r0, 32768 # encoding: [0xa5,0x01,0x80,0x00] +#CHECK: iihl %r0, 65535 # encoding: [0xa5,0x01,0xff,0xff] +#CHECK: iihl %r15, 0 # encoding: [0xa5,0xf1,0x00,0x00] + + iihl %r0, 0 + iihl %r0, 0x8000 + iihl %r0, 0xffff + iihl %r15, 0 diff --git a/test/MC/SystemZ/insn-iihl-02.s b/test/MC/SystemZ/insn-iihl-02.s new file mode 100644 index 00000000000..262955e38d3 --- /dev/null +++ b/test/MC/SystemZ/insn-iihl-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: iihl %r0, -1 +#CHECK: error: invalid operand +#CHECK: iihl %r0, 0x10000 + + iihl %r0, -1 + iihl %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-iilf-01.s b/test/MC/SystemZ/insn-iilf-01.s new file mode 100644 index 00000000000..228e1476764 --- /dev/null +++ b/test/MC/SystemZ/insn-iilf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: iilf %r0, 0 # encoding: [0xc0,0x09,0x00,0x00,0x00,0x00] +#CHECK: iilf %r0, 4294967295 # encoding: [0xc0,0x09,0xff,0xff,0xff,0xff] +#CHECK: iilf %r15, 0 # encoding: [0xc0,0xf9,0x00,0x00,0x00,0x00] + + iilf %r0, 0 + iilf %r0, 0xffffffff + iilf %r15, 0 diff --git a/test/MC/SystemZ/insn-iilf-02.s b/test/MC/SystemZ/insn-iilf-02.s new file mode 100644 index 00000000000..c7571e8f6d1 --- /dev/null +++ b/test/MC/SystemZ/insn-iilf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: iilf %r0, -1 +#CHECK: error: invalid operand +#CHECK: iilf %r0, 1 << 32 + + iilf %r0, -1 + iilf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-iilh-01.s b/test/MC/SystemZ/insn-iilh-01.s new file mode 100644 index 00000000000..045ccfe80b6 --- /dev/null +++ b/test/MC/SystemZ/insn-iilh-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: iilh %r0, 0 # encoding: [0xa5,0x02,0x00,0x00] +#CHECK: iilh %r0, 32768 # encoding: [0xa5,0x02,0x80,0x00] +#CHECK: iilh %r0, 65535 # encoding: [0xa5,0x02,0xff,0xff] +#CHECK: iilh %r15, 0 # encoding: [0xa5,0xf2,0x00,0x00] + + iilh %r0, 0 + iilh %r0, 0x8000 + iilh %r0, 0xffff + iilh %r15, 0 diff --git a/test/MC/SystemZ/insn-iilh-02.s b/test/MC/SystemZ/insn-iilh-02.s new file mode 100644 index 00000000000..af5bdacaff8 --- /dev/null +++ b/test/MC/SystemZ/insn-iilh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: iilh %r0, -1 +#CHECK: error: invalid operand +#CHECK: iilh %r0, 0x10000 + + iilh %r0, -1 + iilh %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-iill-01.s b/test/MC/SystemZ/insn-iill-01.s new file mode 100644 index 00000000000..bf50eeb0f67 --- /dev/null +++ b/test/MC/SystemZ/insn-iill-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: iill %r0, 0 # encoding: [0xa5,0x03,0x00,0x00] +#CHECK: iill %r0, 32768 # encoding: [0xa5,0x03,0x80,0x00] +#CHECK: iill %r0, 65535 # encoding: [0xa5,0x03,0xff,0xff] +#CHECK: iill %r15, 0 # encoding: [0xa5,0xf3,0x00,0x00] + + iill %r0, 0 + iill %r0, 0x8000 + iill %r0, 0xffff + iill %r15, 0 diff --git a/test/MC/SystemZ/insn-iill-02.s b/test/MC/SystemZ/insn-iill-02.s new file mode 100644 index 00000000000..fe31e44ee66 --- /dev/null +++ b/test/MC/SystemZ/insn-iill-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: iill %r0, -1 +#CHECK: error: invalid operand +#CHECK: iill %r0, 0x10000 + + iill %r0, -1 + iill %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-l-01.s b/test/MC/SystemZ/insn-l-01.s new file mode 100644 index 00000000000..a589116ebf4 --- /dev/null +++ b/test/MC/SystemZ/insn-l-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: l %r0, 0 # encoding: [0x58,0x00,0x00,0x00] +#CHECK: l %r0, 4095 # encoding: [0x58,0x00,0x0f,0xff] +#CHECK: l %r0, 0(%r1) # encoding: [0x58,0x00,0x10,0x00] +#CHECK: l %r0, 0(%r15) # encoding: [0x58,0x00,0xf0,0x00] +#CHECK: l %r0, 4095(%r1,%r15) # encoding: [0x58,0x01,0xff,0xff] +#CHECK: l %r0, 4095(%r15,%r1) # encoding: [0x58,0x0f,0x1f,0xff] +#CHECK: l %r15, 0 # encoding: [0x58,0xf0,0x00,0x00] + + l %r0, 0 + l %r0, 4095 + l %r0, 0(%r1) + l %r0, 0(%r15) + l %r0, 4095(%r1,%r15) + l %r0, 4095(%r15,%r1) + l %r15, 0 diff --git a/test/MC/SystemZ/insn-l-02.s b/test/MC/SystemZ/insn-l-02.s new file mode 100644 index 00000000000..fad96ff6ce2 --- /dev/null +++ b/test/MC/SystemZ/insn-l-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: l %r0, -1 +#CHECK: error: invalid operand +#CHECK: l %r0, 4096 + + l %r0, -1 + l %r0, 4096 diff --git a/test/MC/SystemZ/insn-la-01.s b/test/MC/SystemZ/insn-la-01.s new file mode 100644 index 00000000000..d4776ab5857 --- /dev/null +++ b/test/MC/SystemZ/insn-la-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: la %r0, 0 # encoding: [0x41,0x00,0x00,0x00] +#CHECK: la %r0, 4095 # encoding: [0x41,0x00,0x0f,0xff] +#CHECK: la %r0, 0(%r1) # encoding: [0x41,0x00,0x10,0x00] +#CHECK: la %r0, 0(%r15) # encoding: [0x41,0x00,0xf0,0x00] +#CHECK: la %r0, 4095(%r1,%r15) # encoding: [0x41,0x01,0xff,0xff] +#CHECK: la %r0, 4095(%r15,%r1) # encoding: [0x41,0x0f,0x1f,0xff] +#CHECK: la %r15, 0 # encoding: [0x41,0xf0,0x00,0x00] + + la %r0, 0 + la %r0, 4095 + la %r0, 0(%r1) + la %r0, 0(%r15) + la %r0, 4095(%r1,%r15) + la %r0, 4095(%r15,%r1) + la %r15, 0 diff --git a/test/MC/SystemZ/insn-la-02.s b/test/MC/SystemZ/insn-la-02.s new file mode 100644 index 00000000000..35c1ab04b5e --- /dev/null +++ b/test/MC/SystemZ/insn-la-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: la %r0, -1 +#CHECK: error: invalid operand +#CHECK: la %r0, 4096 + + la %r0, -1 + la %r0, 4096 diff --git a/test/MC/SystemZ/insn-larl-01.s b/test/MC/SystemZ/insn-larl-01.s new file mode 100644 index 00000000000..3d0f98f562a --- /dev/null +++ b/test/MC/SystemZ/insn-larl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: larl %r0, 2864434397 # encoding: [0xc0,0x00,0x55,0x5d,0xe6,0x6e] +#CHECK: larl %r15, 2864434397 # encoding: [0xc0,0xf0,0x55,0x5d,0xe6,0x6e] + + larl %r0,0xaabbccdd + larl %r15,0xaabbccdd + +#CHECK: larl %r0, foo # encoding: [0xc0,0x00,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: larl %r15, foo # encoding: [0xc0,0xf0,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + larl %r0,foo + larl %r15,foo + +#CHECK: larl %r3, bar+100 # encoding: [0xc0,0x30,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: larl %r4, bar+100 # encoding: [0xc0,0x40,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + larl %r3,bar+100 + larl %r4,bar+100 + +#CHECK: larl %r7, frob@PLT # encoding: [0xc0,0x70,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: larl %r8, frob@PLT # encoding: [0xc0,0x80,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + larl %r7,frob@PLT + larl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-lay-01.s b/test/MC/SystemZ/insn-lay-01.s new file mode 100644 index 00000000000..daa88288ab5 --- /dev/null +++ b/test/MC/SystemZ/insn-lay-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lay %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x71] +#CHECK: lay %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x71] +#CHECK: lay %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x71] +#CHECK: lay %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x71] +#CHECK: lay %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x71] +#CHECK: lay %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x71] +#CHECK: lay %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x71] +#CHECK: lay %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x71] +#CHECK: lay %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x71] +#CHECK: lay %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x71] + + lay %r0, -524288 + lay %r0, -1 + lay %r0, 0 + lay %r0, 1 + lay %r0, 524287 + lay %r0, 0(%r1) + lay %r0, 0(%r15) + lay %r0, 524287(%r1,%r15) + lay %r0, 524287(%r15,%r1) + lay %r15, 0 diff --git a/test/MC/SystemZ/insn-lay-02.s b/test/MC/SystemZ/insn-lay-02.s new file mode 100644 index 00000000000..2729eead22a --- /dev/null +++ b/test/MC/SystemZ/insn-lay-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lay %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lay %r0, 524288 + + lay %r0, -524289 + lay %r0, 524288 diff --git a/test/MC/SystemZ/insn-lb-01.s b/test/MC/SystemZ/insn-lb-01.s new file mode 100644 index 00000000000..e9ee0fab226 --- /dev/null +++ b/test/MC/SystemZ/insn-lb-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lb %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x76] +#CHECK: lb %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x76] +#CHECK: lb %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x76] +#CHECK: lb %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x76] +#CHECK: lb %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x76] +#CHECK: lb %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x76] +#CHECK: lb %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x76] +#CHECK: lb %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x76] +#CHECK: lb %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x76] +#CHECK: lb %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x76] + + lb %r0, -524288 + lb %r0, -1 + lb %r0, 0 + lb %r0, 1 + lb %r0, 524287 + lb %r0, 0(%r1) + lb %r0, 0(%r15) + lb %r0, 524287(%r1,%r15) + lb %r0, 524287(%r15,%r1) + lb %r15, 0 diff --git a/test/MC/SystemZ/insn-lb-02.s b/test/MC/SystemZ/insn-lb-02.s new file mode 100644 index 00000000000..e65edaf09da --- /dev/null +++ b/test/MC/SystemZ/insn-lb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lb %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lb %r0, 524288 + + lb %r0, -524289 + lb %r0, 524288 diff --git a/test/MC/SystemZ/insn-lbr-01.s b/test/MC/SystemZ/insn-lbr-01.s new file mode 100644 index 00000000000..cb4ead04308 --- /dev/null +++ b/test/MC/SystemZ/insn-lbr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lbr %r0, %r15 # encoding: [0xb9,0x26,0x00,0x0f] +#CHECK: lbr %r7, %r8 # encoding: [0xb9,0x26,0x00,0x78] +#CHECK: lbr %r15, %r0 # encoding: [0xb9,0x26,0x00,0xf0] + + lbr %r0, %r15 + lbr %r7, %r8 + lbr %r15, %r0 diff --git a/test/MC/SystemZ/insn-lcdbr-01.s b/test/MC/SystemZ/insn-lcdbr-01.s new file mode 100644 index 00000000000..347cab51411 --- /dev/null +++ b/test/MC/SystemZ/insn-lcdbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lcdbr %f0, %f9 # encoding: [0xb3,0x13,0x00,0x09] +#CHECK: lcdbr %f0, %f15 # encoding: [0xb3,0x13,0x00,0x0f] +#CHECK: lcdbr %f15, %f0 # encoding: [0xb3,0x13,0x00,0xf0] +#CHECK: lcdbr %f15, %f9 # encoding: [0xb3,0x13,0x00,0xf9] + + lcdbr %f0,%f9 + lcdbr %f0,%f15 + lcdbr %f15,%f0 + lcdbr %f15,%f9 diff --git a/test/MC/SystemZ/insn-lcebr-01.s b/test/MC/SystemZ/insn-lcebr-01.s new file mode 100644 index 00000000000..e31822f0046 --- /dev/null +++ b/test/MC/SystemZ/insn-lcebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lcebr %f0, %f9 # encoding: [0xb3,0x03,0x00,0x09] +#CHECK: lcebr %f0, %f15 # encoding: [0xb3,0x03,0x00,0x0f] +#CHECK: lcebr %f15, %f0 # encoding: [0xb3,0x03,0x00,0xf0] +#CHECK: lcebr %f15, %f9 # encoding: [0xb3,0x03,0x00,0xf9] + + lcebr %f0,%f9 + lcebr %f0,%f15 + lcebr %f15,%f0 + lcebr %f15,%f9 diff --git a/test/MC/SystemZ/insn-lcgfr-01.s b/test/MC/SystemZ/insn-lcgfr-01.s new file mode 100644 index 00000000000..bca430b8015 --- /dev/null +++ b/test/MC/SystemZ/insn-lcgfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lcgfr %r0, %r0 # encoding: [0xb9,0x13,0x00,0x00] +#CHECK: lcgfr %r0, %r15 # encoding: [0xb9,0x13,0x00,0x0f] +#CHECK: lcgfr %r15, %r0 # encoding: [0xb9,0x13,0x00,0xf0] +#CHECK: lcgfr %r7, %r8 # encoding: [0xb9,0x13,0x00,0x78] + + lcgfr %r0,%r0 + lcgfr %r0,%r15 + lcgfr %r15,%r0 + lcgfr %r7,%r8 diff --git a/test/MC/SystemZ/insn-lcgr-01.s b/test/MC/SystemZ/insn-lcgr-01.s new file mode 100644 index 00000000000..dc4e94f03ee --- /dev/null +++ b/test/MC/SystemZ/insn-lcgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lcgr %r0, %r0 # encoding: [0xb9,0x03,0x00,0x00] +#CHECK: lcgr %r0, %r15 # encoding: [0xb9,0x03,0x00,0x0f] +#CHECK: lcgr %r15, %r0 # encoding: [0xb9,0x03,0x00,0xf0] +#CHECK: lcgr %r7, %r8 # encoding: [0xb9,0x03,0x00,0x78] + + lcgr %r0,%r0 + lcgr %r0,%r15 + lcgr %r15,%r0 + lcgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-lcr-01.s b/test/MC/SystemZ/insn-lcr-01.s new file mode 100644 index 00000000000..52471cbbdc5 --- /dev/null +++ b/test/MC/SystemZ/insn-lcr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lcr %r0, %r0 # encoding: [0x13,0x00] +#CHECK: lcr %r0, %r15 # encoding: [0x13,0x0f] +#CHECK: lcr %r15, %r0 # encoding: [0x13,0xf0] +#CHECK: lcr %r7, %r8 # encoding: [0x13,0x78] + + lcr %r0,%r0 + lcr %r0,%r15 + lcr %r15,%r0 + lcr %r7,%r8 diff --git a/test/MC/SystemZ/insn-lcxbr-01.s b/test/MC/SystemZ/insn-lcxbr-01.s new file mode 100644 index 00000000000..48c0b8a7721 --- /dev/null +++ b/test/MC/SystemZ/insn-lcxbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lcxbr %f0, %f8 # encoding: [0xb3,0x43,0x00,0x08] +#CHECK: lcxbr %f0, %f13 # encoding: [0xb3,0x43,0x00,0x0d] +#CHECK: lcxbr %f13, %f0 # encoding: [0xb3,0x43,0x00,0xd0] +#CHECK: lcxbr %f13, %f9 # encoding: [0xb3,0x43,0x00,0xd9] + + lcxbr %f0,%f8 + lcxbr %f0,%f13 + lcxbr %f13,%f0 + lcxbr %f13,%f9 diff --git a/test/MC/SystemZ/insn-lcxbr-02.s b/test/MC/SystemZ/insn-lcxbr-02.s new file mode 100644 index 00000000000..ab3d6bfe9cd --- /dev/null +++ b/test/MC/SystemZ/insn-lcxbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lcxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: lcxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: lcxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: lcxbr %f14, %f0 + + lcxbr %f0, %f2 + lcxbr %f0, %f14 + lcxbr %f2, %f0 + lcxbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-ld-01.s b/test/MC/SystemZ/insn-ld-01.s new file mode 100644 index 00000000000..653eab5e0a5 --- /dev/null +++ b/test/MC/SystemZ/insn-ld-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ld %f0, 0 # encoding: [0x68,0x00,0x00,0x00] +#CHECK: ld %f0, 4095 # encoding: [0x68,0x00,0x0f,0xff] +#CHECK: ld %f0, 0(%r1) # encoding: [0x68,0x00,0x10,0x00] +#CHECK: ld %f0, 0(%r15) # encoding: [0x68,0x00,0xf0,0x00] +#CHECK: ld %f0, 4095(%r1,%r15) # encoding: [0x68,0x01,0xff,0xff] +#CHECK: ld %f0, 4095(%r15,%r1) # encoding: [0x68,0x0f,0x1f,0xff] +#CHECK: ld %f15, 0 # encoding: [0x68,0xf0,0x00,0x00] + + ld %f0, 0 + ld %f0, 4095 + ld %f0, 0(%r1) + ld %f0, 0(%r15) + ld %f0, 4095(%r1,%r15) + ld %f0, 4095(%r15,%r1) + ld %f15, 0 diff --git a/test/MC/SystemZ/insn-ld-02.s b/test/MC/SystemZ/insn-ld-02.s new file mode 100644 index 00000000000..5d786b55570 --- /dev/null +++ b/test/MC/SystemZ/insn-ld-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ld %f0, -1 +#CHECK: error: invalid operand +#CHECK: ld %f0, 4096 + + ld %f0, -1 + ld %f0, 4096 diff --git a/test/MC/SystemZ/insn-ldeb-01.s b/test/MC/SystemZ/insn-ldeb-01.s new file mode 100644 index 00000000000..a06344d27d9 --- /dev/null +++ b/test/MC/SystemZ/insn-ldeb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ldeb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x04] +#CHECK: ldeb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x04] +#CHECK: ldeb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x04] +#CHECK: ldeb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x04] +#CHECK: ldeb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x04] +#CHECK: ldeb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x04] +#CHECK: ldeb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x04] + + ldeb %f0, 0 + ldeb %f0, 4095 + ldeb %f0, 0(%r1) + ldeb %f0, 0(%r15) + ldeb %f0, 4095(%r1,%r15) + ldeb %f0, 4095(%r15,%r1) + ldeb %f15, 0 diff --git a/test/MC/SystemZ/insn-ldeb-02.s b/test/MC/SystemZ/insn-ldeb-02.s new file mode 100644 index 00000000000..6df5e7b46d0 --- /dev/null +++ b/test/MC/SystemZ/insn-ldeb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ldeb %f0, -1 +#CHECK: error: invalid operand +#CHECK: ldeb %f0, 4096 + + ldeb %f0, -1 + ldeb %f0, 4096 diff --git a/test/MC/SystemZ/insn-ldebr-01.s b/test/MC/SystemZ/insn-ldebr-01.s new file mode 100644 index 00000000000..2df932c6686 --- /dev/null +++ b/test/MC/SystemZ/insn-ldebr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ldebr %f0, %f15 # encoding: [0xb3,0x04,0x00,0x0f] +#CHECK: ldebr %f7, %f8 # encoding: [0xb3,0x04,0x00,0x78] +#CHECK: ldebr %f15, %f0 # encoding: [0xb3,0x04,0x00,0xf0] + + ldebr %f0, %f15 + ldebr %f7, %f8 + ldebr %f15, %f0 diff --git a/test/MC/SystemZ/insn-ldgr-01.s b/test/MC/SystemZ/insn-ldgr-01.s new file mode 100644 index 00000000000..61a4529bee7 --- /dev/null +++ b/test/MC/SystemZ/insn-ldgr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ldgr %f0, %r0 # encoding: [0xb3,0xc1,0x00,0x00] +#CHECK: ldgr %f0, %r15 # encoding: [0xb3,0xc1,0x00,0x0f] +#CHECK: ldgr %f15, %r0 # encoding: [0xb3,0xc1,0x00,0xf0] +#CHECK: ldgr %f7, %r9 # encoding: [0xb3,0xc1,0x00,0x79] +#CHECK: ldgr %f15, %r15 # encoding: [0xb3,0xc1,0x00,0xff] + + ldgr %f0,%r0 + ldgr %f0,%r15 + ldgr %f15,%r0 + ldgr %f7,%r9 + ldgr %f15,%r15 diff --git a/test/MC/SystemZ/insn-ldgr-02.s b/test/MC/SystemZ/insn-ldgr-02.s new file mode 100644 index 00000000000..900174ab1f1 --- /dev/null +++ b/test/MC/SystemZ/insn-ldgr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: ldgr %f0, %f0 +#CHECK: error: invalid register +#CHECK: ldgr %r0, %r0 +#CHECK: error: invalid register +#CHECK: ldgr %f0, %a0 +#CHECK: error: invalid register +#CHECK: ldgr %a0, %r0 + + ldgr %f0, %f0 + ldgr %r0, %r0 + ldgr %f0, %a0 + ldgr %a0, %r0 diff --git a/test/MC/SystemZ/insn-ldr-01.s b/test/MC/SystemZ/insn-ldr-01.s new file mode 100644 index 00000000000..895ed3439fc --- /dev/null +++ b/test/MC/SystemZ/insn-ldr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ldr %f0, %f9 # encoding: [0x28,0x09] +#CHECK: ldr %f0, %f15 # encoding: [0x28,0x0f] +#CHECK: ldr %f15, %f0 # encoding: [0x28,0xf0] +#CHECK: ldr %f15, %f9 # encoding: [0x28,0xf9] + + ldr %f0,%f9 + ldr %f0,%f15 + ldr %f15,%f0 + ldr %f15,%f9 diff --git a/test/MC/SystemZ/insn-ldxbr-01.s b/test/MC/SystemZ/insn-ldxbr-01.s new file mode 100644 index 00000000000..49e1d2adfb1 --- /dev/null +++ b/test/MC/SystemZ/insn-ldxbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ldxbr %f0, %f0 # encoding: [0xb3,0x45,0x00,0x00] +#CHECK: ldxbr %f0, %f13 # encoding: [0xb3,0x45,0x00,0x0d] +#CHECK: ldxbr %f8, %f12 # encoding: [0xb3,0x45,0x00,0x8c] +#CHECK: ldxbr %f13, %f0 # encoding: [0xb3,0x45,0x00,0xd0] +#CHECK: ldxbr %f13, %f13 # encoding: [0xb3,0x45,0x00,0xdd] + + ldxbr %f0, %f0 + ldxbr %f0, %f13 + ldxbr %f8, %f12 + ldxbr %f13, %f0 + ldxbr %f13, %f13 diff --git a/test/MC/SystemZ/insn-ldxbr-02.s b/test/MC/SystemZ/insn-ldxbr-02.s new file mode 100644 index 00000000000..89914dff9d4 --- /dev/null +++ b/test/MC/SystemZ/insn-ldxbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: ldxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: ldxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: ldxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: ldxbr %f14, %f0 + + ldxbr %f0, %f2 + ldxbr %f0, %f14 + ldxbr %f2, %f0 + ldxbr %f14, %f0 diff --git a/test/MC/SystemZ/insn-ldy-01.s b/test/MC/SystemZ/insn-ldy-01.s new file mode 100644 index 00000000000..5c2d145af12 --- /dev/null +++ b/test/MC/SystemZ/insn-ldy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ldy %f0, -524288 # encoding: [0xed,0x00,0x00,0x00,0x80,0x65] +#CHECK: ldy %f0, -1 # encoding: [0xed,0x00,0x0f,0xff,0xff,0x65] +#CHECK: ldy %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x65] +#CHECK: ldy %f0, 1 # encoding: [0xed,0x00,0x00,0x01,0x00,0x65] +#CHECK: ldy %f0, 524287 # encoding: [0xed,0x00,0x0f,0xff,0x7f,0x65] +#CHECK: ldy %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x65] +#CHECK: ldy %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x65] +#CHECK: ldy %f0, 524287(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x7f,0x65] +#CHECK: ldy %f0, 524287(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x7f,0x65] +#CHECK: ldy %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x65] + + ldy %f0, -524288 + ldy %f0, -1 + ldy %f0, 0 + ldy %f0, 1 + ldy %f0, 524287 + ldy %f0, 0(%r1) + ldy %f0, 0(%r15) + ldy %f0, 524287(%r1,%r15) + ldy %f0, 524287(%r15,%r1) + ldy %f15, 0 diff --git a/test/MC/SystemZ/insn-ldy-02.s b/test/MC/SystemZ/insn-ldy-02.s new file mode 100644 index 00000000000..b16e0149ee7 --- /dev/null +++ b/test/MC/SystemZ/insn-ldy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ldy %f0, -524289 +#CHECK: error: invalid operand +#CHECK: ldy %f0, 524288 + + ldy %f0, -524289 + ldy %f0, 524288 diff --git a/test/MC/SystemZ/insn-le-01.s b/test/MC/SystemZ/insn-le-01.s new file mode 100644 index 00000000000..15bbce26a51 --- /dev/null +++ b/test/MC/SystemZ/insn-le-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: le %f0, 0 # encoding: [0x78,0x00,0x00,0x00] +#CHECK: le %f0, 4095 # encoding: [0x78,0x00,0x0f,0xff] +#CHECK: le %f0, 0(%r1) # encoding: [0x78,0x00,0x10,0x00] +#CHECK: le %f0, 0(%r15) # encoding: [0x78,0x00,0xf0,0x00] +#CHECK: le %f0, 4095(%r1,%r15) # encoding: [0x78,0x01,0xff,0xff] +#CHECK: le %f0, 4095(%r15,%r1) # encoding: [0x78,0x0f,0x1f,0xff] +#CHECK: le %f15, 0 # encoding: [0x78,0xf0,0x00,0x00] + + le %f0, 0 + le %f0, 4095 + le %f0, 0(%r1) + le %f0, 0(%r15) + le %f0, 4095(%r1,%r15) + le %f0, 4095(%r15,%r1) + le %f15, 0 diff --git a/test/MC/SystemZ/insn-le-02.s b/test/MC/SystemZ/insn-le-02.s new file mode 100644 index 00000000000..f784ea1c901 --- /dev/null +++ b/test/MC/SystemZ/insn-le-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: le %f0, -1 +#CHECK: error: invalid operand +#CHECK: le %f0, 4096 + + le %f0, -1 + le %f0, 4096 diff --git a/test/MC/SystemZ/insn-ledbr-01.s b/test/MC/SystemZ/insn-ledbr-01.s new file mode 100644 index 00000000000..6582d6344f7 --- /dev/null +++ b/test/MC/SystemZ/insn-ledbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ledbr %f0, %f0 # encoding: [0xb3,0x44,0x00,0x00] +#CHECK: ledbr %f0, %f15 # encoding: [0xb3,0x44,0x00,0x0f] +#CHECK: ledbr %f7, %f8 # encoding: [0xb3,0x44,0x00,0x78] +#CHECK: ledbr %f15, %f0 # encoding: [0xb3,0x44,0x00,0xf0] +#CHECK: ledbr %f15, %f15 # encoding: [0xb3,0x44,0x00,0xff] + + ledbr %f0, %f0 + ledbr %f0, %f15 + ledbr %f7, %f8 + ledbr %f15, %f0 + ledbr %f15, %f15 diff --git a/test/MC/SystemZ/insn-ler-01.s b/test/MC/SystemZ/insn-ler-01.s new file mode 100644 index 00000000000..775e5232186 --- /dev/null +++ b/test/MC/SystemZ/insn-ler-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ler %f0, %f9 # encoding: [0x38,0x09] +#CHECK: ler %f0, %f15 # encoding: [0x38,0x0f] +#CHECK: ler %f15, %f0 # encoding: [0x38,0xf0] +#CHECK: ler %f15, %f9 # encoding: [0x38,0xf9] + + ler %f0,%f9 + ler %f0,%f15 + ler %f15,%f0 + ler %f15,%f9 diff --git a/test/MC/SystemZ/insn-lexbr-01.s b/test/MC/SystemZ/insn-lexbr-01.s new file mode 100644 index 00000000000..ce32103c66c --- /dev/null +++ b/test/MC/SystemZ/insn-lexbr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lexbr %f0, %f0 # encoding: [0xb3,0x46,0x00,0x00] +#CHECK: lexbr %f0, %f13 # encoding: [0xb3,0x46,0x00,0x0d] +#CHECK: lexbr %f8, %f12 # encoding: [0xb3,0x46,0x00,0x8c] +#CHECK: lexbr %f13, %f0 # encoding: [0xb3,0x46,0x00,0xd0] +#CHECK: lexbr %f13, %f13 # encoding: [0xb3,0x46,0x00,0xdd] + + lexbr %f0, %f0 + lexbr %f0, %f13 + lexbr %f8, %f12 + lexbr %f13, %f0 + lexbr %f13, %f13 diff --git a/test/MC/SystemZ/insn-lexbr-02.s b/test/MC/SystemZ/insn-lexbr-02.s new file mode 100644 index 00000000000..8c9bb9ed600 --- /dev/null +++ b/test/MC/SystemZ/insn-lexbr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lexbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: lexbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: lexbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: lexbr %f14, %f0 + + lexbr %f0, %f2 + lexbr %f0, %f14 + lexbr %f2, %f0 + lexbr %f14, %f0 diff --git a/test/MC/SystemZ/insn-ley-01.s b/test/MC/SystemZ/insn-ley-01.s new file mode 100644 index 00000000000..b854dc148c7 --- /dev/null +++ b/test/MC/SystemZ/insn-ley-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ley %f0, -524288 # encoding: [0xed,0x00,0x00,0x00,0x80,0x64] +#CHECK: ley %f0, -1 # encoding: [0xed,0x00,0x0f,0xff,0xff,0x64] +#CHECK: ley %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x64] +#CHECK: ley %f0, 1 # encoding: [0xed,0x00,0x00,0x01,0x00,0x64] +#CHECK: ley %f0, 524287 # encoding: [0xed,0x00,0x0f,0xff,0x7f,0x64] +#CHECK: ley %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x64] +#CHECK: ley %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x64] +#CHECK: ley %f0, 524287(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x7f,0x64] +#CHECK: ley %f0, 524287(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x7f,0x64] +#CHECK: ley %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x64] + + ley %f0, -524288 + ley %f0, -1 + ley %f0, 0 + ley %f0, 1 + ley %f0, 524287 + ley %f0, 0(%r1) + ley %f0, 0(%r15) + ley %f0, 524287(%r1,%r15) + ley %f0, 524287(%r15,%r1) + ley %f15, 0 diff --git a/test/MC/SystemZ/insn-ley-02.s b/test/MC/SystemZ/insn-ley-02.s new file mode 100644 index 00000000000..98bbd94dc17 --- /dev/null +++ b/test/MC/SystemZ/insn-ley-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ley %f0, -524289 +#CHECK: error: invalid operand +#CHECK: ley %f0, 524288 + + ley %f0, -524289 + ley %f0, 524288 diff --git a/test/MC/SystemZ/insn-lg-01.s b/test/MC/SystemZ/insn-lg-01.s new file mode 100644 index 00000000000..10a95cc8958 --- /dev/null +++ b/test/MC/SystemZ/insn-lg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x04] +#CHECK: lg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x04] +#CHECK: lg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x04] +#CHECK: lg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x04] +#CHECK: lg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x04] +#CHECK: lg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x04] +#CHECK: lg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x04] +#CHECK: lg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x04] +#CHECK: lg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x04] +#CHECK: lg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x04] + + lg %r0, -524288 + lg %r0, -1 + lg %r0, 0 + lg %r0, 1 + lg %r0, 524287 + lg %r0, 0(%r1) + lg %r0, 0(%r15) + lg %r0, 524287(%r1,%r15) + lg %r0, 524287(%r15,%r1) + lg %r15, 0 diff --git a/test/MC/SystemZ/insn-lg-02.s b/test/MC/SystemZ/insn-lg-02.s new file mode 100644 index 00000000000..85b29fff553 --- /dev/null +++ b/test/MC/SystemZ/insn-lg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lg %r0, 524288 + + lg %r0, -524289 + lg %r0, 524288 diff --git a/test/MC/SystemZ/insn-lgb-01.s b/test/MC/SystemZ/insn-lgb-01.s new file mode 100644 index 00000000000..82b92f16727 --- /dev/null +++ b/test/MC/SystemZ/insn-lgb-01.s @@ -0,0 +1,24 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgb %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x77] +#CHECK: lgb %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x77] +#CHECK: lgb %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x77] +#CHECK: lgb %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x77] +#CHECK: lgb %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x77] +#CHECK: lgb %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x77] +#CHECK: lgb %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x77] +#CHECK: lgb %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x77] +#CHECK: lgb %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x77] +#CHECK: lgb %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x77] + + lgb %r0, -524288 + lgb %r0, -1 + lgb %r0, 0 + lgb %r0, 1 + lgb %r0, 524287 + lgb %r0, 0(%r1) + lgb %r0, 0(%r15) + lgb %r0, 524287(%r1,%r15) + lgb %r0, 524287(%r15,%r1) + lgb %r15, 0 + diff --git a/test/MC/SystemZ/insn-lgb-02.s b/test/MC/SystemZ/insn-lgb-02.s new file mode 100644 index 00000000000..7acc1762b51 --- /dev/null +++ b/test/MC/SystemZ/insn-lgb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lgb %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lgb %r0, 524288 + + lgb %r0, -524289 + lgb %r0, 524288 diff --git a/test/MC/SystemZ/insn-lgbr-01.s b/test/MC/SystemZ/insn-lgbr-01.s new file mode 100644 index 00000000000..ec2e6220091 --- /dev/null +++ b/test/MC/SystemZ/insn-lgbr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgbr %r0, %r15 # encoding: [0xb9,0x06,0x00,0x0f] +#CHECK: lgbr %r7, %r8 # encoding: [0xb9,0x06,0x00,0x78] +#CHECK: lgbr %r15, %r0 # encoding: [0xb9,0x06,0x00,0xf0] + + lgbr %r0, %r15 + lgbr %r7, %r8 + lgbr %r15, %r0 diff --git a/test/MC/SystemZ/insn-lgdr-01.s b/test/MC/SystemZ/insn-lgdr-01.s new file mode 100644 index 00000000000..56d1e035b42 --- /dev/null +++ b/test/MC/SystemZ/insn-lgdr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgdr %r0, %f0 # encoding: [0xb3,0xcd,0x00,0x00] +#CHECK: lgdr %r0, %f15 # encoding: [0xb3,0xcd,0x00,0x0f] +#CHECK: lgdr %r15, %f0 # encoding: [0xb3,0xcd,0x00,0xf0] +#CHECK: lgdr %r8, %f8 # encoding: [0xb3,0xcd,0x00,0x88] +#CHECK: lgdr %r15, %f15 # encoding: [0xb3,0xcd,0x00,0xff] + + lgdr %r0,%f0 + lgdr %r0,%f15 + lgdr %r15,%f0 + lgdr %r8,%f8 + lgdr %r15,%f15 diff --git a/test/MC/SystemZ/insn-lgdr-02.s b/test/MC/SystemZ/insn-lgdr-02.s new file mode 100644 index 00000000000..3bf014d90ec --- /dev/null +++ b/test/MC/SystemZ/insn-lgdr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lgdr %f0, %f0 +#CHECK: error: invalid register +#CHECK: lgdr %r0, %r0 +#CHECK: error: invalid register +#CHECK: lgdr %r0, %a0 +#CHECK: error: invalid register +#CHECK: lgdr %a0, %f0 + + lgdr %f0, %f0 + lgdr %r0, %r0 + lgdr %r0, %a0 + lgdr %a0, %f0 diff --git a/test/MC/SystemZ/insn-lgf-01.s b/test/MC/SystemZ/insn-lgf-01.s new file mode 100644 index 00000000000..9ed917228a8 --- /dev/null +++ b/test/MC/SystemZ/insn-lgf-01.s @@ -0,0 +1,24 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x14] +#CHECK: lgf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x14] +#CHECK: lgf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x14] +#CHECK: lgf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x14] +#CHECK: lgf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x14] +#CHECK: lgf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x14] +#CHECK: lgf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x14] +#CHECK: lgf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x14] +#CHECK: lgf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x14] +#CHECK: lgf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x14] + + lgf %r0, -524288 + lgf %r0, -1 + lgf %r0, 0 + lgf %r0, 1 + lgf %r0, 524287 + lgf %r0, 0(%r1) + lgf %r0, 0(%r15) + lgf %r0, 524287(%r1,%r15) + lgf %r0, 524287(%r15,%r1) + lgf %r15, 0 + diff --git a/test/MC/SystemZ/insn-lgf-02.s b/test/MC/SystemZ/insn-lgf-02.s new file mode 100644 index 00000000000..32095a84093 --- /dev/null +++ b/test/MC/SystemZ/insn-lgf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lgf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lgf %r0, 524288 + + lgf %r0, -524289 + lgf %r0, 524288 diff --git a/test/MC/SystemZ/insn-lgfi-01.s b/test/MC/SystemZ/insn-lgfi-01.s new file mode 100644 index 00000000000..a5ca7a59b5d --- /dev/null +++ b/test/MC/SystemZ/insn-lgfi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgfi %r0, -2147483648 # encoding: [0xc0,0x01,0x80,0x00,0x00,0x00] +#CHECK: lgfi %r0, -1 # encoding: [0xc0,0x01,0xff,0xff,0xff,0xff] +#CHECK: lgfi %r0, 0 # encoding: [0xc0,0x01,0x00,0x00,0x00,0x00] +#CHECK: lgfi %r0, 1 # encoding: [0xc0,0x01,0x00,0x00,0x00,0x01] +#CHECK: lgfi %r0, 2147483647 # encoding: [0xc0,0x01,0x7f,0xff,0xff,0xff] +#CHECK: lgfi %r15, 0 # encoding: [0xc0,0xf1,0x00,0x00,0x00,0x00] + + lgfi %r0, -1 << 31 + lgfi %r0, -1 + lgfi %r0, 0 + lgfi %r0, 1 + lgfi %r0, (1 << 31) - 1 + lgfi %r15, 0 diff --git a/test/MC/SystemZ/insn-lgfi-02.s b/test/MC/SystemZ/insn-lgfi-02.s new file mode 100644 index 00000000000..a45cfeb46d0 --- /dev/null +++ b/test/MC/SystemZ/insn-lgfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lgfi %r0, (-1 << 31) - 1 +#CHECK: error: invalid operand +#CHECK: lgfi %r0, (1 << 31) + + lgfi %r0, (-1 << 31) - 1 + lgfi %r0, (1 << 31) diff --git a/test/MC/SystemZ/insn-lgfr-01.s b/test/MC/SystemZ/insn-lgfr-01.s new file mode 100644 index 00000000000..bc375a67b00 --- /dev/null +++ b/test/MC/SystemZ/insn-lgfr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgfr %r0, %r15 # encoding: [0xb9,0x14,0x00,0x0f] +#CHECK: lgfr %r7, %r8 # encoding: [0xb9,0x14,0x00,0x78] +#CHECK: lgfr %r15, %r0 # encoding: [0xb9,0x14,0x00,0xf0] + + lgfr %r0, %r15 + lgfr %r7, %r8 + lgfr %r15, %r0 diff --git a/test/MC/SystemZ/insn-lgfrl-01.s b/test/MC/SystemZ/insn-lgfrl-01.s new file mode 100644 index 00000000000..85c9ea764c8 --- /dev/null +++ b/test/MC/SystemZ/insn-lgfrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgfrl %r0, 2864434397 # encoding: [0xc4,0x0c,0x55,0x5d,0xe6,0x6e] +#CHECK: lgfrl %r15, 2864434397 # encoding: [0xc4,0xfc,0x55,0x5d,0xe6,0x6e] + + lgfrl %r0,0xaabbccdd + lgfrl %r15,0xaabbccdd + +#CHECK: lgfrl %r0, foo # encoding: [0xc4,0x0c,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: lgfrl %r15, foo # encoding: [0xc4,0xfc,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + lgfrl %r0,foo + lgfrl %r15,foo + +#CHECK: lgfrl %r3, bar+100 # encoding: [0xc4,0x3c,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: lgfrl %r4, bar+100 # encoding: [0xc4,0x4c,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + lgfrl %r3,bar+100 + lgfrl %r4,bar+100 + +#CHECK: lgfrl %r7, frob@PLT # encoding: [0xc4,0x7c,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: lgfrl %r8, frob@PLT # encoding: [0xc4,0x8c,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + lgfrl %r7,frob@PLT + lgfrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-lgh-01.s b/test/MC/SystemZ/insn-lgh-01.s new file mode 100644 index 00000000000..9dae6212b2c --- /dev/null +++ b/test/MC/SystemZ/insn-lgh-01.s @@ -0,0 +1,24 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgh %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x15] +#CHECK: lgh %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x15] +#CHECK: lgh %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x15] +#CHECK: lgh %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x15] +#CHECK: lgh %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x15] +#CHECK: lgh %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x15] +#CHECK: lgh %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x15] +#CHECK: lgh %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x15] +#CHECK: lgh %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x15] +#CHECK: lgh %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x15] + + lgh %r0, -524288 + lgh %r0, -1 + lgh %r0, 0 + lgh %r0, 1 + lgh %r0, 524287 + lgh %r0, 0(%r1) + lgh %r0, 0(%r15) + lgh %r0, 524287(%r1,%r15) + lgh %r0, 524287(%r15,%r1) + lgh %r15, 0 + diff --git a/test/MC/SystemZ/insn-lgh-02.s b/test/MC/SystemZ/insn-lgh-02.s new file mode 100644 index 00000000000..62b7341d827 --- /dev/null +++ b/test/MC/SystemZ/insn-lgh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lgh %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lgh %r0, 524288 + + lgh %r0, -524289 + lgh %r0, 524288 diff --git a/test/MC/SystemZ/insn-lghi-01.s b/test/MC/SystemZ/insn-lghi-01.s new file mode 100644 index 00000000000..d9d12ae1bb3 --- /dev/null +++ b/test/MC/SystemZ/insn-lghi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lghi %r0, -32768 # encoding: [0xa7,0x09,0x80,0x00] +#CHECK: lghi %r0, -1 # encoding: [0xa7,0x09,0xff,0xff] +#CHECK: lghi %r0, 0 # encoding: [0xa7,0x09,0x00,0x00] +#CHECK: lghi %r0, 1 # encoding: [0xa7,0x09,0x00,0x01] +#CHECK: lghi %r0, 32767 # encoding: [0xa7,0x09,0x7f,0xff] +#CHECK: lghi %r15, 0 # encoding: [0xa7,0xf9,0x00,0x00] + + lghi %r0, -32768 + lghi %r0, -1 + lghi %r0, 0 + lghi %r0, 1 + lghi %r0, 32767 + lghi %r15, 0 diff --git a/test/MC/SystemZ/insn-lghi-02.s b/test/MC/SystemZ/insn-lghi-02.s new file mode 100644 index 00000000000..b1af7a0c54a --- /dev/null +++ b/test/MC/SystemZ/insn-lghi-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lghi %r0, -32769 +#CHECK: error: invalid operand +#CHECK: lghi %r0, 32768 +#CHECK: error: invalid operand +#CHECK: lghi %r0, foo + + lghi %r0, -32769 + lghi %r0, 32768 + lghi %r0, foo diff --git a/test/MC/SystemZ/insn-lghr-01.s b/test/MC/SystemZ/insn-lghr-01.s new file mode 100644 index 00000000000..a1dc842339b --- /dev/null +++ b/test/MC/SystemZ/insn-lghr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lghr %r0, %r15 # encoding: [0xb9,0x07,0x00,0x0f] +#CHECK: lghr %r7, %r8 # encoding: [0xb9,0x07,0x00,0x78] +#CHECK: lghr %r15, %r0 # encoding: [0xb9,0x07,0x00,0xf0] + + lghr %r0, %r15 + lghr %r7, %r8 + lghr %r15, %r0 diff --git a/test/MC/SystemZ/insn-lghrl-01.s b/test/MC/SystemZ/insn-lghrl-01.s new file mode 100644 index 00000000000..34992e6ff26 --- /dev/null +++ b/test/MC/SystemZ/insn-lghrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lghrl %r0, 2864434397 # encoding: [0xc4,0x04,0x55,0x5d,0xe6,0x6e] +#CHECK: lghrl %r15, 2864434397 # encoding: [0xc4,0xf4,0x55,0x5d,0xe6,0x6e] + + lghrl %r0,0xaabbccdd + lghrl %r15,0xaabbccdd + +#CHECK: lghrl %r0, foo # encoding: [0xc4,0x04,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: lghrl %r15, foo # encoding: [0xc4,0xf4,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + lghrl %r0,foo + lghrl %r15,foo + +#CHECK: lghrl %r3, bar+100 # encoding: [0xc4,0x34,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: lghrl %r4, bar+100 # encoding: [0xc4,0x44,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + lghrl %r3,bar+100 + lghrl %r4,bar+100 + +#CHECK: lghrl %r7, frob@PLT # encoding: [0xc4,0x74,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: lghrl %r8, frob@PLT # encoding: [0xc4,0x84,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + lghrl %r7,frob@PLT + lghrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-lgr-01.s b/test/MC/SystemZ/insn-lgr-01.s new file mode 100644 index 00000000000..e50295682bd --- /dev/null +++ b/test/MC/SystemZ/insn-lgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgr %r0, %r9 # encoding: [0xb9,0x04,0x00,0x09] +#CHECK: lgr %r0, %r15 # encoding: [0xb9,0x04,0x00,0x0f] +#CHECK: lgr %r15, %r0 # encoding: [0xb9,0x04,0x00,0xf0] +#CHECK: lgr %r15, %r9 # encoding: [0xb9,0x04,0x00,0xf9] + + lgr %r0,%r9 + lgr %r0,%r15 + lgr %r15,%r0 + lgr %r15,%r9 diff --git a/test/MC/SystemZ/insn-lgrl-01.s b/test/MC/SystemZ/insn-lgrl-01.s new file mode 100644 index 00000000000..7a18908f9ab --- /dev/null +++ b/test/MC/SystemZ/insn-lgrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgrl %r0, 2864434397 # encoding: [0xc4,0x08,0x55,0x5d,0xe6,0x6e] +#CHECK: lgrl %r15, 2864434397 # encoding: [0xc4,0xf8,0x55,0x5d,0xe6,0x6e] + + lgrl %r0,0xaabbccdd + lgrl %r15,0xaabbccdd + +#CHECK: lgrl %r0, foo # encoding: [0xc4,0x08,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: lgrl %r15, foo # encoding: [0xc4,0xf8,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + lgrl %r0,foo + lgrl %r15,foo + +#CHECK: lgrl %r3, bar+100 # encoding: [0xc4,0x38,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: lgrl %r4, bar+100 # encoding: [0xc4,0x48,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + lgrl %r3,bar+100 + lgrl %r4,bar+100 + +#CHECK: lgrl %r7, frob@PLT # encoding: [0xc4,0x78,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: lgrl %r8, frob@PLT # encoding: [0xc4,0x88,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + lgrl %r7,frob@PLT + lgrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-lh-01.s b/test/MC/SystemZ/insn-lh-01.s new file mode 100644 index 00000000000..07be0127569 --- /dev/null +++ b/test/MC/SystemZ/insn-lh-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lh %r0, 0 # encoding: [0x48,0x00,0x00,0x00] +#CHECK: lh %r0, 4095 # encoding: [0x48,0x00,0x0f,0xff] +#CHECK: lh %r0, 0(%r1) # encoding: [0x48,0x00,0x10,0x00] +#CHECK: lh %r0, 0(%r15) # encoding: [0x48,0x00,0xf0,0x00] +#CHECK: lh %r0, 4095(%r1,%r15) # encoding: [0x48,0x01,0xff,0xff] +#CHECK: lh %r0, 4095(%r15,%r1) # encoding: [0x48,0x0f,0x1f,0xff] +#CHECK: lh %r15, 0 # encoding: [0x48,0xf0,0x00,0x00] + + lh %r0, 0 + lh %r0, 4095 + lh %r0, 0(%r1) + lh %r0, 0(%r15) + lh %r0, 4095(%r1,%r15) + lh %r0, 4095(%r15,%r1) + lh %r15, 0 diff --git a/test/MC/SystemZ/insn-lh-02.s b/test/MC/SystemZ/insn-lh-02.s new file mode 100644 index 00000000000..80566d8d37e --- /dev/null +++ b/test/MC/SystemZ/insn-lh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lh %r0, -1 +#CHECK: error: invalid operand +#CHECK: lh %r0, 4096 + + lh %r0, -1 + lh %r0, 4096 diff --git a/test/MC/SystemZ/insn-lhi-01.s b/test/MC/SystemZ/insn-lhi-01.s new file mode 100644 index 00000000000..43b7df08f01 --- /dev/null +++ b/test/MC/SystemZ/insn-lhi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lhi %r0, -32768 # encoding: [0xa7,0x08,0x80,0x00] +#CHECK: lhi %r0, -1 # encoding: [0xa7,0x08,0xff,0xff] +#CHECK: lhi %r0, 0 # encoding: [0xa7,0x08,0x00,0x00] +#CHECK: lhi %r0, 1 # encoding: [0xa7,0x08,0x00,0x01] +#CHECK: lhi %r0, 32767 # encoding: [0xa7,0x08,0x7f,0xff] +#CHECK: lhi %r15, 0 # encoding: [0xa7,0xf8,0x00,0x00] + + lhi %r0, -32768 + lhi %r0, -1 + lhi %r0, 0 + lhi %r0, 1 + lhi %r0, 32767 + lhi %r15, 0 diff --git a/test/MC/SystemZ/insn-lhi-02.s b/test/MC/SystemZ/insn-lhi-02.s new file mode 100644 index 00000000000..8e38464b828 --- /dev/null +++ b/test/MC/SystemZ/insn-lhi-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lhi %r0, -32769 +#CHECK: error: invalid operand +#CHECK: lhi %r0, 32768 +#CHECK: error: invalid operand +#CHECK: lhi %r0, foo + + lhi %r0, -32769 + lhi %r0, 32768 + lhi %r0, foo diff --git a/test/MC/SystemZ/insn-lhr-01.s b/test/MC/SystemZ/insn-lhr-01.s new file mode 100644 index 00000000000..a31cbc65f44 --- /dev/null +++ b/test/MC/SystemZ/insn-lhr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lhr %r0, %r15 # encoding: [0xb9,0x27,0x00,0x0f] +#CHECK: lhr %r7, %r8 # encoding: [0xb9,0x27,0x00,0x78] +#CHECK: lhr %r15, %r0 # encoding: [0xb9,0x27,0x00,0xf0] + + lhr %r0, %r15 + lhr %r7, %r8 + lhr %r15, %r0 diff --git a/test/MC/SystemZ/insn-lhrl-01.s b/test/MC/SystemZ/insn-lhrl-01.s new file mode 100644 index 00000000000..87925fe0987 --- /dev/null +++ b/test/MC/SystemZ/insn-lhrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lhrl %r0, 2864434397 # encoding: [0xc4,0x05,0x55,0x5d,0xe6,0x6e] +#CHECK: lhrl %r15, 2864434397 # encoding: [0xc4,0xf5,0x55,0x5d,0xe6,0x6e] + + lhrl %r0,0xaabbccdd + lhrl %r15,0xaabbccdd + +#CHECK: lhrl %r0, foo # encoding: [0xc4,0x05,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: lhrl %r15, foo # encoding: [0xc4,0xf5,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + lhrl %r0,foo + lhrl %r15,foo + +#CHECK: lhrl %r3, bar+100 # encoding: [0xc4,0x35,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: lhrl %r4, bar+100 # encoding: [0xc4,0x45,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + lhrl %r3,bar+100 + lhrl %r4,bar+100 + +#CHECK: lhrl %r7, frob@PLT # encoding: [0xc4,0x75,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: lhrl %r8, frob@PLT # encoding: [0xc4,0x85,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + lhrl %r7,frob@PLT + lhrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-lhy-01.s b/test/MC/SystemZ/insn-lhy-01.s new file mode 100644 index 00000000000..db811a41a4a --- /dev/null +++ b/test/MC/SystemZ/insn-lhy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lhy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x78] +#CHECK: lhy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x78] +#CHECK: lhy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x78] +#CHECK: lhy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x78] +#CHECK: lhy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x78] +#CHECK: lhy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x78] +#CHECK: lhy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x78] +#CHECK: lhy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x78] +#CHECK: lhy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x78] +#CHECK: lhy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x78] + + lhy %r0, -524288 + lhy %r0, -1 + lhy %r0, 0 + lhy %r0, 1 + lhy %r0, 524287 + lhy %r0, 0(%r1) + lhy %r0, 0(%r15) + lhy %r0, 524287(%r1,%r15) + lhy %r0, 524287(%r15,%r1) + lhy %r15, 0 diff --git a/test/MC/SystemZ/insn-lhy-02.s b/test/MC/SystemZ/insn-lhy-02.s new file mode 100644 index 00000000000..6f1caa59faf --- /dev/null +++ b/test/MC/SystemZ/insn-lhy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lhy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lhy %r0, 524288 + + lhy %r0, -524289 + lhy %r0, 524288 diff --git a/test/MC/SystemZ/insn-llc-01.s b/test/MC/SystemZ/insn-llc-01.s new file mode 100644 index 00000000000..74a819b2ee3 --- /dev/null +++ b/test/MC/SystemZ/insn-llc-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llc %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x94] +#CHECK: llc %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x94] +#CHECK: llc %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x94] +#CHECK: llc %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x94] +#CHECK: llc %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x94] +#CHECK: llc %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x94] +#CHECK: llc %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x94] +#CHECK: llc %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x94] +#CHECK: llc %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x94] +#CHECK: llc %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x94] + + llc %r0, -524288 + llc %r0, -1 + llc %r0, 0 + llc %r0, 1 + llc %r0, 524287 + llc %r0, 0(%r1) + llc %r0, 0(%r15) + llc %r0, 524287(%r1,%r15) + llc %r0, 524287(%r15,%r1) + llc %r15, 0 diff --git a/test/MC/SystemZ/insn-llc-02.s b/test/MC/SystemZ/insn-llc-02.s new file mode 100644 index 00000000000..4a65f6c55e7 --- /dev/null +++ b/test/MC/SystemZ/insn-llc-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llc %r0, -524289 +#CHECK: error: invalid operand +#CHECK: llc %r0, 524288 + + llc %r0, -524289 + llc %r0, 524288 diff --git a/test/MC/SystemZ/insn-llcr-01.s b/test/MC/SystemZ/insn-llcr-01.s new file mode 100644 index 00000000000..72a695ceffa --- /dev/null +++ b/test/MC/SystemZ/insn-llcr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llcr %r0, %r15 # encoding: [0xb9,0x94,0x00,0x0f] +#CHECK: llcr %r7, %r8 # encoding: [0xb9,0x94,0x00,0x78] +#CHECK: llcr %r15, %r0 # encoding: [0xb9,0x94,0x00,0xf0] + + llcr %r0, %r15 + llcr %r7, %r8 + llcr %r15, %r0 diff --git a/test/MC/SystemZ/insn-llgc-01.s b/test/MC/SystemZ/insn-llgc-01.s new file mode 100644 index 00000000000..297c6d62db4 --- /dev/null +++ b/test/MC/SystemZ/insn-llgc-01.s @@ -0,0 +1,24 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llgc %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x90] +#CHECK: llgc %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x90] +#CHECK: llgc %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x90] +#CHECK: llgc %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x90] +#CHECK: llgc %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x90] +#CHECK: llgc %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x90] +#CHECK: llgc %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x90] +#CHECK: llgc %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x90] +#CHECK: llgc %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x90] +#CHECK: llgc %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x90] + + llgc %r0, -524288 + llgc %r0, -1 + llgc %r0, 0 + llgc %r0, 1 + llgc %r0, 524287 + llgc %r0, 0(%r1) + llgc %r0, 0(%r15) + llgc %r0, 524287(%r1,%r15) + llgc %r0, 524287(%r15,%r1) + llgc %r15, 0 + diff --git a/test/MC/SystemZ/insn-llgc-02.s b/test/MC/SystemZ/insn-llgc-02.s new file mode 100644 index 00000000000..76fca0f2512 --- /dev/null +++ b/test/MC/SystemZ/insn-llgc-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llgc %r0, -524289 +#CHECK: error: invalid operand +#CHECK: llgc %r0, 524288 + + llgc %r0, -524289 + llgc %r0, 524288 diff --git a/test/MC/SystemZ/insn-llgcr-01.s b/test/MC/SystemZ/insn-llgcr-01.s new file mode 100644 index 00000000000..5d653bfff90 --- /dev/null +++ b/test/MC/SystemZ/insn-llgcr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llgcr %r0, %r15 # encoding: [0xb9,0x84,0x00,0x0f] +#CHECK: llgcr %r7, %r8 # encoding: [0xb9,0x84,0x00,0x78] +#CHECK: llgcr %r15, %r0 # encoding: [0xb9,0x84,0x00,0xf0] + + llgcr %r0, %r15 + llgcr %r7, %r8 + llgcr %r15, %r0 diff --git a/test/MC/SystemZ/insn-llgf-01.s b/test/MC/SystemZ/insn-llgf-01.s new file mode 100644 index 00000000000..0394140dab8 --- /dev/null +++ b/test/MC/SystemZ/insn-llgf-01.s @@ -0,0 +1,24 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llgf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x16] +#CHECK: llgf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x16] +#CHECK: llgf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x16] +#CHECK: llgf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x16] +#CHECK: llgf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x16] +#CHECK: llgf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x16] +#CHECK: llgf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x16] +#CHECK: llgf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x16] +#CHECK: llgf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x16] +#CHECK: llgf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x16] + + llgf %r0, -524288 + llgf %r0, -1 + llgf %r0, 0 + llgf %r0, 1 + llgf %r0, 524287 + llgf %r0, 0(%r1) + llgf %r0, 0(%r15) + llgf %r0, 524287(%r1,%r15) + llgf %r0, 524287(%r15,%r1) + llgf %r15, 0 + diff --git a/test/MC/SystemZ/insn-llgf-02.s b/test/MC/SystemZ/insn-llgf-02.s new file mode 100644 index 00000000000..0b2fab033aa --- /dev/null +++ b/test/MC/SystemZ/insn-llgf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llgf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: llgf %r0, 524288 + + llgf %r0, -524289 + llgf %r0, 524288 diff --git a/test/MC/SystemZ/insn-llgfr-01.s b/test/MC/SystemZ/insn-llgfr-01.s new file mode 100644 index 00000000000..74f1074d150 --- /dev/null +++ b/test/MC/SystemZ/insn-llgfr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llgfr %r0, %r15 # encoding: [0xb9,0x16,0x00,0x0f] +#CHECK: llgfr %r7, %r8 # encoding: [0xb9,0x16,0x00,0x78] +#CHECK: llgfr %r15, %r0 # encoding: [0xb9,0x16,0x00,0xf0] + + llgfr %r0, %r15 + llgfr %r7, %r8 + llgfr %r15, %r0 diff --git a/test/MC/SystemZ/insn-llgfrl-01.s b/test/MC/SystemZ/insn-llgfrl-01.s new file mode 100644 index 00000000000..85fc9f4b3c3 --- /dev/null +++ b/test/MC/SystemZ/insn-llgfrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llgfrl %r0, 2864434397 # encoding: [0xc4,0x0e,0x55,0x5d,0xe6,0x6e] +#CHECK: llgfrl %r15, 2864434397 # encoding: [0xc4,0xfe,0x55,0x5d,0xe6,0x6e] + + llgfrl %r0,0xaabbccdd + llgfrl %r15,0xaabbccdd + +#CHECK: llgfrl %r0, foo # encoding: [0xc4,0x0e,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: llgfrl %r15, foo # encoding: [0xc4,0xfe,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + llgfrl %r0,foo + llgfrl %r15,foo + +#CHECK: llgfrl %r3, bar+100 # encoding: [0xc4,0x3e,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: llgfrl %r4, bar+100 # encoding: [0xc4,0x4e,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + llgfrl %r3,bar+100 + llgfrl %r4,bar+100 + +#CHECK: llgfrl %r7, frob@PLT # encoding: [0xc4,0x7e,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: llgfrl %r8, frob@PLT # encoding: [0xc4,0x8e,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + llgfrl %r7,frob@PLT + llgfrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-llgh-01.s b/test/MC/SystemZ/insn-llgh-01.s new file mode 100644 index 00000000000..acbab004382 --- /dev/null +++ b/test/MC/SystemZ/insn-llgh-01.s @@ -0,0 +1,24 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llgh %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x91] +#CHECK: llgh %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x91] +#CHECK: llgh %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x91] +#CHECK: llgh %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x91] +#CHECK: llgh %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x91] +#CHECK: llgh %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x91] +#CHECK: llgh %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x91] +#CHECK: llgh %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x91] +#CHECK: llgh %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x91] +#CHECK: llgh %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x91] + + llgh %r0, -524288 + llgh %r0, -1 + llgh %r0, 0 + llgh %r0, 1 + llgh %r0, 524287 + llgh %r0, 0(%r1) + llgh %r0, 0(%r15) + llgh %r0, 524287(%r1,%r15) + llgh %r0, 524287(%r15,%r1) + llgh %r15, 0 + diff --git a/test/MC/SystemZ/insn-llgh-02.s b/test/MC/SystemZ/insn-llgh-02.s new file mode 100644 index 00000000000..95b6b12c91e --- /dev/null +++ b/test/MC/SystemZ/insn-llgh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llgh %r0, -524289 +#CHECK: error: invalid operand +#CHECK: llgh %r0, 524288 + + llgh %r0, -524289 + llgh %r0, 524288 diff --git a/test/MC/SystemZ/insn-llghr-01.s b/test/MC/SystemZ/insn-llghr-01.s new file mode 100644 index 00000000000..3e2f6de2ae8 --- /dev/null +++ b/test/MC/SystemZ/insn-llghr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llghr %r0, %r15 # encoding: [0xb9,0x85,0x00,0x0f] +#CHECK: llghr %r7, %r8 # encoding: [0xb9,0x85,0x00,0x78] +#CHECK: llghr %r15, %r0 # encoding: [0xb9,0x85,0x00,0xf0] + + llghr %r0, %r15 + llghr %r7, %r8 + llghr %r15, %r0 diff --git a/test/MC/SystemZ/insn-llghrl-01.s b/test/MC/SystemZ/insn-llghrl-01.s new file mode 100644 index 00000000000..af3fa8b9d78 --- /dev/null +++ b/test/MC/SystemZ/insn-llghrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llghrl %r0, 2864434397 # encoding: [0xc4,0x06,0x55,0x5d,0xe6,0x6e] +#CHECK: llghrl %r15, 2864434397 # encoding: [0xc4,0xf6,0x55,0x5d,0xe6,0x6e] + + llghrl %r0,0xaabbccdd + llghrl %r15,0xaabbccdd + +#CHECK: llghrl %r0, foo # encoding: [0xc4,0x06,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: llghrl %r15, foo # encoding: [0xc4,0xf6,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + llghrl %r0,foo + llghrl %r15,foo + +#CHECK: llghrl %r3, bar+100 # encoding: [0xc4,0x36,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: llghrl %r4, bar+100 # encoding: [0xc4,0x46,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + llghrl %r3,bar+100 + llghrl %r4,bar+100 + +#CHECK: llghrl %r7, frob@PLT # encoding: [0xc4,0x76,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: llghrl %r8, frob@PLT # encoding: [0xc4,0x86,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + llghrl %r7,frob@PLT + llghrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-llh-01.s b/test/MC/SystemZ/insn-llh-01.s new file mode 100644 index 00000000000..7e15f3f6d60 --- /dev/null +++ b/test/MC/SystemZ/insn-llh-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llh %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x95] +#CHECK: llh %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x95] +#CHECK: llh %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x95] +#CHECK: llh %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x95] +#CHECK: llh %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x95] +#CHECK: llh %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x95] +#CHECK: llh %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x95] +#CHECK: llh %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x95] +#CHECK: llh %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x95] +#CHECK: llh %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x95] + + llh %r0, -524288 + llh %r0, -1 + llh %r0, 0 + llh %r0, 1 + llh %r0, 524287 + llh %r0, 0(%r1) + llh %r0, 0(%r15) + llh %r0, 524287(%r1,%r15) + llh %r0, 524287(%r15,%r1) + llh %r15, 0 diff --git a/test/MC/SystemZ/insn-llh-02.s b/test/MC/SystemZ/insn-llh-02.s new file mode 100644 index 00000000000..92c49bb59c2 --- /dev/null +++ b/test/MC/SystemZ/insn-llh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llh %r0, -524289 +#CHECK: error: invalid operand +#CHECK: llh %r0, 524288 + + llh %r0, -524289 + llh %r0, 524288 diff --git a/test/MC/SystemZ/insn-llhr-01.s b/test/MC/SystemZ/insn-llhr-01.s new file mode 100644 index 00000000000..bb1d3b5d32f --- /dev/null +++ b/test/MC/SystemZ/insn-llhr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llhr %r0, %r15 # encoding: [0xb9,0x95,0x00,0x0f] +#CHECK: llhr %r7, %r8 # encoding: [0xb9,0x95,0x00,0x78] +#CHECK: llhr %r15, %r0 # encoding: [0xb9,0x95,0x00,0xf0] + + llhr %r0, %r15 + llhr %r7, %r8 + llhr %r15, %r0 diff --git a/test/MC/SystemZ/insn-llhrl-01.s b/test/MC/SystemZ/insn-llhrl-01.s new file mode 100644 index 00000000000..30ed4f90565 --- /dev/null +++ b/test/MC/SystemZ/insn-llhrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llhrl %r0, 2864434397 # encoding: [0xc4,0x02,0x55,0x5d,0xe6,0x6e] +#CHECK: llhrl %r15, 2864434397 # encoding: [0xc4,0xf2,0x55,0x5d,0xe6,0x6e] + + llhrl %r0,0xaabbccdd + llhrl %r15,0xaabbccdd + +#CHECK: llhrl %r0, foo # encoding: [0xc4,0x02,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: llhrl %r15, foo # encoding: [0xc4,0xf2,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + llhrl %r0,foo + llhrl %r15,foo + +#CHECK: llhrl %r3, bar+100 # encoding: [0xc4,0x32,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: llhrl %r4, bar+100 # encoding: [0xc4,0x42,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + llhrl %r3,bar+100 + llhrl %r4,bar+100 + +#CHECK: llhrl %r7, frob@PLT # encoding: [0xc4,0x72,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: llhrl %r8, frob@PLT # encoding: [0xc4,0x82,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + llhrl %r7,frob@PLT + llhrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-llihf-01.s b/test/MC/SystemZ/insn-llihf-01.s new file mode 100644 index 00000000000..6ddd29ffa37 --- /dev/null +++ b/test/MC/SystemZ/insn-llihf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llihf %r0, 0 # encoding: [0xc0,0x0e,0x00,0x00,0x00,0x00] +#CHECK: llihf %r0, 4294967295 # encoding: [0xc0,0x0e,0xff,0xff,0xff,0xff] +#CHECK: llihf %r15, 0 # encoding: [0xc0,0xfe,0x00,0x00,0x00,0x00] + + llihf %r0, 0 + llihf %r0, 0xffffffff + llihf %r15, 0 diff --git a/test/MC/SystemZ/insn-llihf-02.s b/test/MC/SystemZ/insn-llihf-02.s new file mode 100644 index 00000000000..e1b4537b02c --- /dev/null +++ b/test/MC/SystemZ/insn-llihf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llihf %r0, -1 +#CHECK: error: invalid operand +#CHECK: llihf %r0, 1 << 32 + + llihf %r0, -1 + llihf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-llihh-01.s b/test/MC/SystemZ/insn-llihh-01.s new file mode 100644 index 00000000000..06060765c74 --- /dev/null +++ b/test/MC/SystemZ/insn-llihh-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llihh %r0, 0 # encoding: [0xa5,0x0c,0x00,0x00] +#CHECK: llihh %r0, 32768 # encoding: [0xa5,0x0c,0x80,0x00] +#CHECK: llihh %r0, 65535 # encoding: [0xa5,0x0c,0xff,0xff] +#CHECK: llihh %r15, 0 # encoding: [0xa5,0xfc,0x00,0x00] + + llihh %r0, 0 + llihh %r0, 0x8000 + llihh %r0, 0xffff + llihh %r15, 0 diff --git a/test/MC/SystemZ/insn-llihh-02.s b/test/MC/SystemZ/insn-llihh-02.s new file mode 100644 index 00000000000..1309f1440f5 --- /dev/null +++ b/test/MC/SystemZ/insn-llihh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llihh %r0, -1 +#CHECK: error: invalid operand +#CHECK: llihh %r0, 0x10000 + + llihh %r0, -1 + llihh %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-llihl-01.s b/test/MC/SystemZ/insn-llihl-01.s new file mode 100644 index 00000000000..6353353321c --- /dev/null +++ b/test/MC/SystemZ/insn-llihl-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llihl %r0, 0 # encoding: [0xa5,0x0d,0x00,0x00] +#CHECK: llihl %r0, 32768 # encoding: [0xa5,0x0d,0x80,0x00] +#CHECK: llihl %r0, 65535 # encoding: [0xa5,0x0d,0xff,0xff] +#CHECK: llihl %r15, 0 # encoding: [0xa5,0xfd,0x00,0x00] + + llihl %r0, 0 + llihl %r0, 0x8000 + llihl %r0, 0xffff + llihl %r15, 0 diff --git a/test/MC/SystemZ/insn-llihl-02.s b/test/MC/SystemZ/insn-llihl-02.s new file mode 100644 index 00000000000..6891c421962 --- /dev/null +++ b/test/MC/SystemZ/insn-llihl-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llihl %r0, -1 +#CHECK: error: invalid operand +#CHECK: llihl %r0, 0x10000 + + llihl %r0, -1 + llihl %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-llilf-01.s b/test/MC/SystemZ/insn-llilf-01.s new file mode 100644 index 00000000000..8166583a2c0 --- /dev/null +++ b/test/MC/SystemZ/insn-llilf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llilf %r0, 0 # encoding: [0xc0,0x0f,0x00,0x00,0x00,0x00] +#CHECK: llilf %r0, 4294967295 # encoding: [0xc0,0x0f,0xff,0xff,0xff,0xff] +#CHECK: llilf %r15, 0 # encoding: [0xc0,0xff,0x00,0x00,0x00,0x00] + + llilf %r0, 0 + llilf %r0, 0xffffffff + llilf %r15, 0 diff --git a/test/MC/SystemZ/insn-llilf-02.s b/test/MC/SystemZ/insn-llilf-02.s new file mode 100644 index 00000000000..dc10cc34ee0 --- /dev/null +++ b/test/MC/SystemZ/insn-llilf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llilf %r0, -1 +#CHECK: error: invalid operand +#CHECK: llilf %r0, 1 << 32 + + llilf %r0, -1 + llilf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-llilh-01.s b/test/MC/SystemZ/insn-llilh-01.s new file mode 100644 index 00000000000..2ec5a7952f0 --- /dev/null +++ b/test/MC/SystemZ/insn-llilh-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llilh %r0, 0 # encoding: [0xa5,0x0e,0x00,0x00] +#CHECK: llilh %r0, 32768 # encoding: [0xa5,0x0e,0x80,0x00] +#CHECK: llilh %r0, 65535 # encoding: [0xa5,0x0e,0xff,0xff] +#CHECK: llilh %r15, 0 # encoding: [0xa5,0xfe,0x00,0x00] + + llilh %r0, 0 + llilh %r0, 0x8000 + llilh %r0, 0xffff + llilh %r15, 0 diff --git a/test/MC/SystemZ/insn-llilh-02.s b/test/MC/SystemZ/insn-llilh-02.s new file mode 100644 index 00000000000..bdfa1e77435 --- /dev/null +++ b/test/MC/SystemZ/insn-llilh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llilh %r0, -1 +#CHECK: error: invalid operand +#CHECK: llilh %r0, 0x10000 + + llilh %r0, -1 + llilh %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-llill-01.s b/test/MC/SystemZ/insn-llill-01.s new file mode 100644 index 00000000000..b95841da4d0 --- /dev/null +++ b/test/MC/SystemZ/insn-llill-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: llill %r0, 0 # encoding: [0xa5,0x0f,0x00,0x00] +#CHECK: llill %r0, 32768 # encoding: [0xa5,0x0f,0x80,0x00] +#CHECK: llill %r0, 65535 # encoding: [0xa5,0x0f,0xff,0xff] +#CHECK: llill %r15, 0 # encoding: [0xa5,0xff,0x00,0x00] + + llill %r0, 0 + llill %r0, 0x8000 + llill %r0, 0xffff + llill %r15, 0 diff --git a/test/MC/SystemZ/insn-llill-02.s b/test/MC/SystemZ/insn-llill-02.s new file mode 100644 index 00000000000..2503b533317 --- /dev/null +++ b/test/MC/SystemZ/insn-llill-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: llill %r0, -1 +#CHECK: error: invalid operand +#CHECK: llill %r0, 0x10000 + + llill %r0, -1 + llill %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-lmg-01.s b/test/MC/SystemZ/insn-lmg-01.s new file mode 100644 index 00000000000..24a2768192c --- /dev/null +++ b/test/MC/SystemZ/insn-lmg-01.s @@ -0,0 +1,29 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lmg %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x04] +#CHECK: lmg %r0, %r15, 0 # encoding: [0xeb,0x0f,0x00,0x00,0x00,0x04] +#CHECK: lmg %r14, %r15, 0 # encoding: [0xeb,0xef,0x00,0x00,0x00,0x04] +#CHECK: lmg %r15, %r15, 0 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x04] +#CHECK: lmg %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x04] +#CHECK: lmg %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x04] +#CHECK: lmg %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x04] +#CHECK: lmg %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x04] +#CHECK: lmg %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x04] +#CHECK: lmg %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x04] +#CHECK: lmg %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x04] +#CHECK: lmg %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x04] +#CHECK: lmg %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x04] + + lmg %r0,%r0,0 + lmg %r0,%r15,0 + lmg %r14,%r15,0 + lmg %r15,%r15,0 + lmg %r0,%r0,-524288 + lmg %r0,%r0,-1 + lmg %r0,%r0,0 + lmg %r0,%r0,1 + lmg %r0,%r0,524287 + lmg %r0,%r0,0(%r1) + lmg %r0,%r0,0(%r15) + lmg %r0,%r0,524287(%r1) + lmg %r0,%r0,524287(%r15) diff --git a/test/MC/SystemZ/insn-lmg-02.s b/test/MC/SystemZ/insn-lmg-02.s new file mode 100644 index 00000000000..9a67c08ee64 --- /dev/null +++ b/test/MC/SystemZ/insn-lmg-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lmg %r0, %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lmg %r0, %r0, 524288 +#CHECK: error: invalid use of indexed addressing +#CHECK: lmg %r0, %r0, 0(%r1,%r2) + + lmg %r0, %r0, -524289 + lmg %r0, %r0, 524288 + lmg %r0, %r0, 0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-lndbr-01.s b/test/MC/SystemZ/insn-lndbr-01.s new file mode 100644 index 00000000000..22786238ab5 --- /dev/null +++ b/test/MC/SystemZ/insn-lndbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lndbr %f0, %f9 # encoding: [0xb3,0x11,0x00,0x09] +#CHECK: lndbr %f0, %f15 # encoding: [0xb3,0x11,0x00,0x0f] +#CHECK: lndbr %f15, %f0 # encoding: [0xb3,0x11,0x00,0xf0] +#CHECK: lndbr %f15, %f9 # encoding: [0xb3,0x11,0x00,0xf9] + + lndbr %f0,%f9 + lndbr %f0,%f15 + lndbr %f15,%f0 + lndbr %f15,%f9 diff --git a/test/MC/SystemZ/insn-lnebr-01.s b/test/MC/SystemZ/insn-lnebr-01.s new file mode 100644 index 00000000000..cf32734ad21 --- /dev/null +++ b/test/MC/SystemZ/insn-lnebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lnebr %f0, %f9 # encoding: [0xb3,0x01,0x00,0x09] +#CHECK: lnebr %f0, %f15 # encoding: [0xb3,0x01,0x00,0x0f] +#CHECK: lnebr %f15, %f0 # encoding: [0xb3,0x01,0x00,0xf0] +#CHECK: lnebr %f15, %f9 # encoding: [0xb3,0x01,0x00,0xf9] + + lnebr %f0,%f9 + lnebr %f0,%f15 + lnebr %f15,%f0 + lnebr %f15,%f9 diff --git a/test/MC/SystemZ/insn-lnxbr-01.s b/test/MC/SystemZ/insn-lnxbr-01.s new file mode 100644 index 00000000000..bf3794859ed --- /dev/null +++ b/test/MC/SystemZ/insn-lnxbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lnxbr %f0, %f8 # encoding: [0xb3,0x41,0x00,0x08] +#CHECK: lnxbr %f0, %f13 # encoding: [0xb3,0x41,0x00,0x0d] +#CHECK: lnxbr %f13, %f0 # encoding: [0xb3,0x41,0x00,0xd0] +#CHECK: lnxbr %f13, %f9 # encoding: [0xb3,0x41,0x00,0xd9] + + lnxbr %f0,%f8 + lnxbr %f0,%f13 + lnxbr %f13,%f0 + lnxbr %f13,%f9 diff --git a/test/MC/SystemZ/insn-lnxbr-02.s b/test/MC/SystemZ/insn-lnxbr-02.s new file mode 100644 index 00000000000..9a69f48a063 --- /dev/null +++ b/test/MC/SystemZ/insn-lnxbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lnxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: lnxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: lnxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: lnxbr %f14, %f0 + + lnxbr %f0, %f2 + lnxbr %f0, %f14 + lnxbr %f2, %f0 + lnxbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-lpdbr-01.s b/test/MC/SystemZ/insn-lpdbr-01.s new file mode 100644 index 00000000000..869b0c9117e --- /dev/null +++ b/test/MC/SystemZ/insn-lpdbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lpdbr %f0, %f9 # encoding: [0xb3,0x10,0x00,0x09] +#CHECK: lpdbr %f0, %f15 # encoding: [0xb3,0x10,0x00,0x0f] +#CHECK: lpdbr %f15, %f0 # encoding: [0xb3,0x10,0x00,0xf0] +#CHECK: lpdbr %f15, %f9 # encoding: [0xb3,0x10,0x00,0xf9] + + lpdbr %f0,%f9 + lpdbr %f0,%f15 + lpdbr %f15,%f0 + lpdbr %f15,%f9 diff --git a/test/MC/SystemZ/insn-lpebr-01.s b/test/MC/SystemZ/insn-lpebr-01.s new file mode 100644 index 00000000000..917f26e9aee --- /dev/null +++ b/test/MC/SystemZ/insn-lpebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lpebr %f0, %f9 # encoding: [0xb3,0x00,0x00,0x09] +#CHECK: lpebr %f0, %f15 # encoding: [0xb3,0x00,0x00,0x0f] +#CHECK: lpebr %f15, %f0 # encoding: [0xb3,0x00,0x00,0xf0] +#CHECK: lpebr %f15, %f9 # encoding: [0xb3,0x00,0x00,0xf9] + + lpebr %f0,%f9 + lpebr %f0,%f15 + lpebr %f15,%f0 + lpebr %f15,%f9 diff --git a/test/MC/SystemZ/insn-lpxbr-01.s b/test/MC/SystemZ/insn-lpxbr-01.s new file mode 100644 index 00000000000..56a628ab96c --- /dev/null +++ b/test/MC/SystemZ/insn-lpxbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lpxbr %f0, %f8 # encoding: [0xb3,0x40,0x00,0x08] +#CHECK: lpxbr %f0, %f13 # encoding: [0xb3,0x40,0x00,0x0d] +#CHECK: lpxbr %f13, %f0 # encoding: [0xb3,0x40,0x00,0xd0] +#CHECK: lpxbr %f13, %f9 # encoding: [0xb3,0x40,0x00,0xd9] + + lpxbr %f0,%f8 + lpxbr %f0,%f13 + lpxbr %f13,%f0 + lpxbr %f13,%f9 diff --git a/test/MC/SystemZ/insn-lpxbr-02.s b/test/MC/SystemZ/insn-lpxbr-02.s new file mode 100644 index 00000000000..6fa3697111e --- /dev/null +++ b/test/MC/SystemZ/insn-lpxbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lpxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: lpxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: lpxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: lpxbr %f14, %f0 + + lpxbr %f0, %f2 + lpxbr %f0, %f14 + lpxbr %f2, %f0 + lpxbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-lr-01.s b/test/MC/SystemZ/insn-lr-01.s new file mode 100644 index 00000000000..8ce4a00678d --- /dev/null +++ b/test/MC/SystemZ/insn-lr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lr %r0, %r9 # encoding: [0x18,0x09] +#CHECK: lr %r0, %r15 # encoding: [0x18,0x0f] +#CHECK: lr %r15, %r0 # encoding: [0x18,0xf0] +#CHECK: lr %r15, %r9 # encoding: [0x18,0xf9] + + lr %r0,%r9 + lr %r0,%r15 + lr %r15,%r0 + lr %r15,%r9 diff --git a/test/MC/SystemZ/insn-lrl-01.s b/test/MC/SystemZ/insn-lrl-01.s new file mode 100644 index 00000000000..32d0eeb2b84 --- /dev/null +++ b/test/MC/SystemZ/insn-lrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lrl %r0, 2864434397 # encoding: [0xc4,0x0d,0x55,0x5d,0xe6,0x6e] +#CHECK: lrl %r15, 2864434397 # encoding: [0xc4,0xfd,0x55,0x5d,0xe6,0x6e] + + lrl %r0,0xaabbccdd + lrl %r15,0xaabbccdd + +#CHECK: lrl %r0, foo # encoding: [0xc4,0x0d,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: lrl %r15, foo # encoding: [0xc4,0xfd,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + lrl %r0,foo + lrl %r15,foo + +#CHECK: lrl %r3, bar+100 # encoding: [0xc4,0x3d,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: lrl %r4, bar+100 # encoding: [0xc4,0x4d,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + lrl %r3,bar+100 + lrl %r4,bar+100 + +#CHECK: lrl %r7, frob@PLT # encoding: [0xc4,0x7d,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: lrl %r8, frob@PLT # encoding: [0xc4,0x8d,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + lrl %r7,frob@PLT + lrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-lrv-01.s b/test/MC/SystemZ/insn-lrv-01.s new file mode 100644 index 00000000000..75b973a22d0 --- /dev/null +++ b/test/MC/SystemZ/insn-lrv-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lrv %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x1e] +#CHECK: lrv %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x1e] +#CHECK: lrv %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x1e] +#CHECK: lrv %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x1e] +#CHECK: lrv %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x1e] +#CHECK: lrv %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x1e] +#CHECK: lrv %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x1e] +#CHECK: lrv %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x1e] +#CHECK: lrv %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x1e] +#CHECK: lrv %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x1e] + + lrv %r0,-524288 + lrv %r0,-1 + lrv %r0,0 + lrv %r0,1 + lrv %r0,524287 + lrv %r0,0(%r1) + lrv %r0,0(%r15) + lrv %r0,524287(%r1,%r15) + lrv %r0,524287(%r15,%r1) + lrv %r15,0 diff --git a/test/MC/SystemZ/insn-lrv-02.s b/test/MC/SystemZ/insn-lrv-02.s new file mode 100644 index 00000000000..f2dcfa777a2 --- /dev/null +++ b/test/MC/SystemZ/insn-lrv-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lrv %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lrv %r0, 524288 + + lrv %r0, -524289 + lrv %r0, 524288 diff --git a/test/MC/SystemZ/insn-lrvg-01.s b/test/MC/SystemZ/insn-lrvg-01.s new file mode 100644 index 00000000000..d2d8b2db43d --- /dev/null +++ b/test/MC/SystemZ/insn-lrvg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lrvg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x0f] +#CHECK: lrvg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x0f] +#CHECK: lrvg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x0f] +#CHECK: lrvg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x0f] +#CHECK: lrvg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x0f] +#CHECK: lrvg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x0f] +#CHECK: lrvg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x0f] +#CHECK: lrvg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x0f] +#CHECK: lrvg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x0f] +#CHECK: lrvg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x0f] + + lrvg %r0,-524288 + lrvg %r0,-1 + lrvg %r0,0 + lrvg %r0,1 + lrvg %r0,524287 + lrvg %r0,0(%r1) + lrvg %r0,0(%r15) + lrvg %r0,524287(%r1,%r15) + lrvg %r0,524287(%r15,%r1) + lrvg %r15,0 diff --git a/test/MC/SystemZ/insn-lrvg-02.s b/test/MC/SystemZ/insn-lrvg-02.s new file mode 100644 index 00000000000..690fa135009 --- /dev/null +++ b/test/MC/SystemZ/insn-lrvg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: lrvg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: lrvg %r0, 524288 + + lrvg %r0, -524289 + lrvg %r0, 524288 diff --git a/test/MC/SystemZ/insn-lrvgr-01.s b/test/MC/SystemZ/insn-lrvgr-01.s new file mode 100644 index 00000000000..1b6e8841ee2 --- /dev/null +++ b/test/MC/SystemZ/insn-lrvgr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lrvgr %r0, %r0 # encoding: [0xb9,0x0f,0x00,0x00] +#CHECK: lrvgr %r0, %r15 # encoding: [0xb9,0x0f,0x00,0x0f] +#CHECK: lrvgr %r15, %r0 # encoding: [0xb9,0x0f,0x00,0xf0] +#CHECK: lrvgr %r7, %r8 # encoding: [0xb9,0x0f,0x00,0x78] +#CHECK: lrvgr %r15, %r15 # encoding: [0xb9,0x0f,0x00,0xff] + + lrvgr %r0,%r0 + lrvgr %r0,%r15 + lrvgr %r15,%r0 + lrvgr %r7,%r8 + lrvgr %r15,%r15 diff --git a/test/MC/SystemZ/insn-lrvr-01.s b/test/MC/SystemZ/insn-lrvr-01.s new file mode 100644 index 00000000000..c0d5d895b8b --- /dev/null +++ b/test/MC/SystemZ/insn-lrvr-01.s @@ -0,0 +1,13 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lrvr %r0, %r0 # encoding: [0xb9,0x1f,0x00,0x00] +#CHECK: lrvr %r0, %r15 # encoding: [0xb9,0x1f,0x00,0x0f] +#CHECK: lrvr %r15, %r0 # encoding: [0xb9,0x1f,0x00,0xf0] +#CHECK: lrvr %r7, %r8 # encoding: [0xb9,0x1f,0x00,0x78] +#CHECK: lrvr %r15, %r15 # encoding: [0xb9,0x1f,0x00,0xff] + + lrvr %r0,%r0 + lrvr %r0,%r15 + lrvr %r15,%r0 + lrvr %r7,%r8 + lrvr %r15,%r15 diff --git a/test/MC/SystemZ/insn-lxr-01.s b/test/MC/SystemZ/insn-lxr-01.s new file mode 100644 index 00000000000..a04cdf74728 --- /dev/null +++ b/test/MC/SystemZ/insn-lxr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lxr %f0, %f8 # encoding: [0xb3,0x65,0x00,0x08] +#CHECK: lxr %f0, %f13 # encoding: [0xb3,0x65,0x00,0x0d] +#CHECK: lxr %f13, %f0 # encoding: [0xb3,0x65,0x00,0xd0] +#CHECK: lxr %f13, %f9 # encoding: [0xb3,0x65,0x00,0xd9] + + lxr %f0,%f8 + lxr %f0,%f13 + lxr %f13,%f0 + lxr %f13,%f9 diff --git a/test/MC/SystemZ/insn-lxr-02.s b/test/MC/SystemZ/insn-lxr-02.s new file mode 100644 index 00000000000..b18ad756b12 --- /dev/null +++ b/test/MC/SystemZ/insn-lxr-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lxr %f2, %f0 +#CHECK: error: invalid register +#CHECK: lxr %f15, %f0 +#CHECK: error: invalid register +#CHECK: lxr %f0, %f2 +#CHECK: error: invalid register +#CHECK: lxr %f0, %f15 + + lxr %f2, %f0 + lxr %f15, %f0 + lxr %f0, %f2 + lxr %f0, %f15 diff --git a/test/MC/SystemZ/insn-ly-01.s b/test/MC/SystemZ/insn-ly-01.s new file mode 100644 index 00000000000..25bc3e8a34c --- /dev/null +++ b/test/MC/SystemZ/insn-ly-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ly %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x58] +#CHECK: ly %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x58] +#CHECK: ly %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x58] +#CHECK: ly %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x58] +#CHECK: ly %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x58] +#CHECK: ly %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x58] +#CHECK: ly %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x58] +#CHECK: ly %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x58] +#CHECK: ly %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x58] +#CHECK: ly %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x58] + + ly %r0, -524288 + ly %r0, -1 + ly %r0, 0 + ly %r0, 1 + ly %r0, 524287 + ly %r0, 0(%r1) + ly %r0, 0(%r15) + ly %r0, 524287(%r1,%r15) + ly %r0, 524287(%r15,%r1) + ly %r15, 0 diff --git a/test/MC/SystemZ/insn-ly-02.s b/test/MC/SystemZ/insn-ly-02.s new file mode 100644 index 00000000000..b2d424e1152 --- /dev/null +++ b/test/MC/SystemZ/insn-ly-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ly %r0, -524289 +#CHECK: error: invalid operand +#CHECK: ly %r0, 524288 + + ly %r0, -524289 + ly %r0, 524288 diff --git a/test/MC/SystemZ/insn-lzdr-01.s b/test/MC/SystemZ/insn-lzdr-01.s new file mode 100644 index 00000000000..c95082f47b7 --- /dev/null +++ b/test/MC/SystemZ/insn-lzdr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lzdr %f0 # encoding: [0xb3,0x75,0x00,0x00] +#CHECK: lzdr %f7 # encoding: [0xb3,0x75,0x00,0x70] +#CHECK: lzdr %f15 # encoding: [0xb3,0x75,0x00,0xf0] + + lzdr %f0 + lzdr %f7 + lzdr %f15 diff --git a/test/MC/SystemZ/insn-lzer-01.s b/test/MC/SystemZ/insn-lzer-01.s new file mode 100644 index 00000000000..0944047a5ba --- /dev/null +++ b/test/MC/SystemZ/insn-lzer-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lzer %f0 # encoding: [0xb3,0x74,0x00,0x00] +#CHECK: lzer %f7 # encoding: [0xb3,0x74,0x00,0x70] +#CHECK: lzer %f15 # encoding: [0xb3,0x74,0x00,0xf0] + + lzer %f0 + lzer %f7 + lzer %f15 diff --git a/test/MC/SystemZ/insn-lzxr-01.s b/test/MC/SystemZ/insn-lzxr-01.s new file mode 100644 index 00000000000..bd5a5c2ea13 --- /dev/null +++ b/test/MC/SystemZ/insn-lzxr-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lzxr %f0 # encoding: [0xb3,0x76,0x00,0x00] +#CHECK: lzxr %f8 # encoding: [0xb3,0x76,0x00,0x80] +#CHECK: lzxr %f13 # encoding: [0xb3,0x76,0x00,0xd0] + + lzxr %f0 + lzxr %f8 + lzxr %f13 diff --git a/test/MC/SystemZ/insn-lzxr-02.s b/test/MC/SystemZ/insn-lzxr-02.s new file mode 100644 index 00000000000..4ce2ad04bc6 --- /dev/null +++ b/test/MC/SystemZ/insn-lzxr-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lzxr %f2 +#CHECK: error: invalid register +#CHECK: lzxr %f14 +#CHECK: error: invalid register +#CHECK: lzxr %f15 + + lzxr %f2 + lzxr %f14 + lzxr %f15 diff --git a/test/MC/SystemZ/insn-madb-01.s b/test/MC/SystemZ/insn-madb-01.s new file mode 100644 index 00000000000..6eec4beb37a --- /dev/null +++ b/test/MC/SystemZ/insn-madb-01.s @@ -0,0 +1,21 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: madb %f0, %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x1e] +#CHECK: madb %f0, %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x1e] +#CHECK: madb %f0, %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x1e] +#CHECK: madb %f0, %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x1e] +#CHECK: madb %f0, %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x1e] +#CHECK: madb %f0, %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x1e] +#CHECK: madb %f0, %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x1e] +#CHECK: madb %f15, %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0xf0,0x1e] +#CHECK: madb %f15, %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0xf0,0x1e] + + madb %f0, %f0, 0 + madb %f0, %f0, 4095 + madb %f0, %f0, 0(%r1) + madb %f0, %f0, 0(%r15) + madb %f0, %f0, 4095(%r1,%r15) + madb %f0, %f0, 4095(%r15,%r1) + madb %f0, %f15, 0 + madb %f15, %f0, 0 + madb %f15, %f15, 0 diff --git a/test/MC/SystemZ/insn-madb-02.s b/test/MC/SystemZ/insn-madb-02.s new file mode 100644 index 00000000000..f7fdee978e1 --- /dev/null +++ b/test/MC/SystemZ/insn-madb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: madb %f0, %f0, -1 +#CHECK: error: invalid operand +#CHECK: madb %f0, %f0, 4096 + + madb %f0, %f0, -1 + madb %f0, %f0, 4096 diff --git a/test/MC/SystemZ/insn-madbr-01.s b/test/MC/SystemZ/insn-madbr-01.s new file mode 100644 index 00000000000..42142be99e5 --- /dev/null +++ b/test/MC/SystemZ/insn-madbr-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: madbr %f0, %f0, %f0 # encoding: [0xb3,0x1e,0x00,0x00] +#CHECK: madbr %f0, %f0, %f15 # encoding: [0xb3,0x1e,0x00,0x0f] +#CHECK: madbr %f0, %f15, %f0 # encoding: [0xb3,0x1e,0x00,0xf0] +#CHECK: madbr %f15, %f0, %f0 # encoding: [0xb3,0x1e,0xf0,0x00] +#CHECK: madbr %f7, %f8, %f9 # encoding: [0xb3,0x1e,0x70,0x89] +#CHECK: madbr %f15, %f15, %f15 # encoding: [0xb3,0x1e,0xf0,0xff] + + madbr %f0, %f0, %f0 + madbr %f0, %f0, %f15 + madbr %f0, %f15, %f0 + madbr %f15, %f0, %f0 + madbr %f7, %f8, %f9 + madbr %f15, %f15, %f15 diff --git a/test/MC/SystemZ/insn-maeb-01.s b/test/MC/SystemZ/insn-maeb-01.s new file mode 100644 index 00000000000..7a998fd79ff --- /dev/null +++ b/test/MC/SystemZ/insn-maeb-01.s @@ -0,0 +1,21 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: maeb %f0, %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x0e] +#CHECK: maeb %f0, %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x0e] +#CHECK: maeb %f0, %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x0e] +#CHECK: maeb %f0, %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x0e] +#CHECK: maeb %f0, %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x0e] +#CHECK: maeb %f0, %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x0e] +#CHECK: maeb %f0, %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x0e] +#CHECK: maeb %f15, %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0xf0,0x0e] +#CHECK: maeb %f15, %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0xf0,0x0e] + + maeb %f0, %f0, 0 + maeb %f0, %f0, 4095 + maeb %f0, %f0, 0(%r1) + maeb %f0, %f0, 0(%r15) + maeb %f0, %f0, 4095(%r1,%r15) + maeb %f0, %f0, 4095(%r15,%r1) + maeb %f0, %f15, 0 + maeb %f15, %f0, 0 + maeb %f15, %f15, 0 diff --git a/test/MC/SystemZ/insn-maeb-02.s b/test/MC/SystemZ/insn-maeb-02.s new file mode 100644 index 00000000000..e12407acc2d --- /dev/null +++ b/test/MC/SystemZ/insn-maeb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: maeb %f0, %f0, -1 +#CHECK: error: invalid operand +#CHECK: maeb %f0, %f0, 4096 + + maeb %f0, %f0, -1 + maeb %f0, %f0, 4096 diff --git a/test/MC/SystemZ/insn-maebr-01.s b/test/MC/SystemZ/insn-maebr-01.s new file mode 100644 index 00000000000..be92aaf8748 --- /dev/null +++ b/test/MC/SystemZ/insn-maebr-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: maebr %f0, %f0, %f0 # encoding: [0xb3,0x0e,0x00,0x00] +#CHECK: maebr %f0, %f0, %f15 # encoding: [0xb3,0x0e,0x00,0x0f] +#CHECK: maebr %f0, %f15, %f0 # encoding: [0xb3,0x0e,0x00,0xf0] +#CHECK: maebr %f15, %f0, %f0 # encoding: [0xb3,0x0e,0xf0,0x00] +#CHECK: maebr %f7, %f8, %f9 # encoding: [0xb3,0x0e,0x70,0x89] +#CHECK: maebr %f15, %f15, %f15 # encoding: [0xb3,0x0e,0xf0,0xff] + + maebr %f0, %f0, %f0 + maebr %f0, %f0, %f15 + maebr %f0, %f15, %f0 + maebr %f15, %f0, %f0 + maebr %f7, %f8, %f9 + maebr %f15, %f15, %f15 diff --git a/test/MC/SystemZ/insn-mdb-01.s b/test/MC/SystemZ/insn-mdb-01.s new file mode 100644 index 00000000000..58be9779fc5 --- /dev/null +++ b/test/MC/SystemZ/insn-mdb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mdb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x1c] +#CHECK: mdb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x1c] +#CHECK: mdb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x1c] +#CHECK: mdb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x1c] +#CHECK: mdb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x1c] +#CHECK: mdb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x1c] +#CHECK: mdb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x1c] + + mdb %f0, 0 + mdb %f0, 4095 + mdb %f0, 0(%r1) + mdb %f0, 0(%r15) + mdb %f0, 4095(%r1,%r15) + mdb %f0, 4095(%r15,%r1) + mdb %f15, 0 diff --git a/test/MC/SystemZ/insn-mdb-02.s b/test/MC/SystemZ/insn-mdb-02.s new file mode 100644 index 00000000000..f1bdab015f1 --- /dev/null +++ b/test/MC/SystemZ/insn-mdb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mdb %f0, -1 +#CHECK: error: invalid operand +#CHECK: mdb %f0, 4096 + + mdb %f0, -1 + mdb %f0, 4096 diff --git a/test/MC/SystemZ/insn-mdbr-01.s b/test/MC/SystemZ/insn-mdbr-01.s new file mode 100644 index 00000000000..4ff16b9c0b3 --- /dev/null +++ b/test/MC/SystemZ/insn-mdbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mdbr %f0, %f0 # encoding: [0xb3,0x1c,0x00,0x00] +#CHECK: mdbr %f0, %f15 # encoding: [0xb3,0x1c,0x00,0x0f] +#CHECK: mdbr %f7, %f8 # encoding: [0xb3,0x1c,0x00,0x78] +#CHECK: mdbr %f15, %f0 # encoding: [0xb3,0x1c,0x00,0xf0] + + mdbr %f0, %f0 + mdbr %f0, %f15 + mdbr %f7, %f8 + mdbr %f15, %f0 diff --git a/test/MC/SystemZ/insn-mdeb-01.s b/test/MC/SystemZ/insn-mdeb-01.s new file mode 100644 index 00000000000..5d85c079db1 --- /dev/null +++ b/test/MC/SystemZ/insn-mdeb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mdeb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x0c] +#CHECK: mdeb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x0c] +#CHECK: mdeb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x0c] +#CHECK: mdeb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x0c] +#CHECK: mdeb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x0c] +#CHECK: mdeb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x0c] +#CHECK: mdeb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x0c] + + mdeb %f0, 0 + mdeb %f0, 4095 + mdeb %f0, 0(%r1) + mdeb %f0, 0(%r15) + mdeb %f0, 4095(%r1,%r15) + mdeb %f0, 4095(%r15,%r1) + mdeb %f15, 0 diff --git a/test/MC/SystemZ/insn-mdeb-02.s b/test/MC/SystemZ/insn-mdeb-02.s new file mode 100644 index 00000000000..87ec6767d4e --- /dev/null +++ b/test/MC/SystemZ/insn-mdeb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mdeb %f0, -1 +#CHECK: error: invalid operand +#CHECK: mdeb %f0, 4096 + + mdeb %f0, -1 + mdeb %f0, 4096 diff --git a/test/MC/SystemZ/insn-mdebr-01.s b/test/MC/SystemZ/insn-mdebr-01.s new file mode 100644 index 00000000000..17c495581d3 --- /dev/null +++ b/test/MC/SystemZ/insn-mdebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mdebr %f0, %f0 # encoding: [0xb3,0x0c,0x00,0x00] +#CHECK: mdebr %f0, %f15 # encoding: [0xb3,0x0c,0x00,0x0f] +#CHECK: mdebr %f7, %f8 # encoding: [0xb3,0x0c,0x00,0x78] +#CHECK: mdebr %f15, %f0 # encoding: [0xb3,0x0c,0x00,0xf0] + + mdebr %f0, %f0 + mdebr %f0, %f15 + mdebr %f7, %f8 + mdebr %f15, %f0 diff --git a/test/MC/SystemZ/insn-meeb-01.s b/test/MC/SystemZ/insn-meeb-01.s new file mode 100644 index 00000000000..bb14d043557 --- /dev/null +++ b/test/MC/SystemZ/insn-meeb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: meeb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x17] +#CHECK: meeb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x17] +#CHECK: meeb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x17] +#CHECK: meeb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x17] +#CHECK: meeb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x17] +#CHECK: meeb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x17] +#CHECK: meeb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x17] + + meeb %f0, 0 + meeb %f0, 4095 + meeb %f0, 0(%r1) + meeb %f0, 0(%r15) + meeb %f0, 4095(%r1,%r15) + meeb %f0, 4095(%r15,%r1) + meeb %f15, 0 diff --git a/test/MC/SystemZ/insn-meeb-02.s b/test/MC/SystemZ/insn-meeb-02.s new file mode 100644 index 00000000000..ba5e3b28e3c --- /dev/null +++ b/test/MC/SystemZ/insn-meeb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: meeb %f0, -1 +#CHECK: error: invalid operand +#CHECK: meeb %f0, 4096 + + meeb %f0, -1 + meeb %f0, 4096 diff --git a/test/MC/SystemZ/insn-meebr-01.s b/test/MC/SystemZ/insn-meebr-01.s new file mode 100644 index 00000000000..99cd8a38e00 --- /dev/null +++ b/test/MC/SystemZ/insn-meebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: meebr %f0, %f0 # encoding: [0xb3,0x17,0x00,0x00] +#CHECK: meebr %f0, %f15 # encoding: [0xb3,0x17,0x00,0x0f] +#CHECK: meebr %f7, %f8 # encoding: [0xb3,0x17,0x00,0x78] +#CHECK: meebr %f15, %f0 # encoding: [0xb3,0x17,0x00,0xf0] + + meebr %f0, %f0 + meebr %f0, %f15 + meebr %f7, %f8 + meebr %f15, %f0 diff --git a/test/MC/SystemZ/insn-mghi-01.s b/test/MC/SystemZ/insn-mghi-01.s new file mode 100644 index 00000000000..d07278f20a1 --- /dev/null +++ b/test/MC/SystemZ/insn-mghi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mghi %r0, -32768 # encoding: [0xa7,0x0d,0x80,0x00] +#CHECK: mghi %r0, -1 # encoding: [0xa7,0x0d,0xff,0xff] +#CHECK: mghi %r0, 0 # encoding: [0xa7,0x0d,0x00,0x00] +#CHECK: mghi %r0, 1 # encoding: [0xa7,0x0d,0x00,0x01] +#CHECK: mghi %r0, 32767 # encoding: [0xa7,0x0d,0x7f,0xff] +#CHECK: mghi %r15, 0 # encoding: [0xa7,0xfd,0x00,0x00] + + mghi %r0, -32768 + mghi %r0, -1 + mghi %r0, 0 + mghi %r0, 1 + mghi %r0, 32767 + mghi %r15, 0 diff --git a/test/MC/SystemZ/insn-mghi-02.s b/test/MC/SystemZ/insn-mghi-02.s new file mode 100644 index 00000000000..860fa3b7875 --- /dev/null +++ b/test/MC/SystemZ/insn-mghi-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mghi %r0, -32769 +#CHECK: error: invalid operand +#CHECK: mghi %r0, 32768 +#CHECK: error: invalid operand +#CHECK: mghi %r0, foo + + mghi %r0, -32769 + mghi %r0, 32768 + mghi %r0, foo diff --git a/test/MC/SystemZ/insn-mh-01.s b/test/MC/SystemZ/insn-mh-01.s new file mode 100644 index 00000000000..59d5515438a --- /dev/null +++ b/test/MC/SystemZ/insn-mh-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mh %r0, 0 # encoding: [0x4c,0x00,0x00,0x00] +#CHECK: mh %r0, 4095 # encoding: [0x4c,0x00,0x0f,0xff] +#CHECK: mh %r0, 0(%r1) # encoding: [0x4c,0x00,0x10,0x00] +#CHECK: mh %r0, 0(%r15) # encoding: [0x4c,0x00,0xf0,0x00] +#CHECK: mh %r0, 4095(%r1,%r15) # encoding: [0x4c,0x01,0xff,0xff] +#CHECK: mh %r0, 4095(%r15,%r1) # encoding: [0x4c,0x0f,0x1f,0xff] +#CHECK: mh %r15, 0 # encoding: [0x4c,0xf0,0x00,0x00] + + mh %r0, 0 + mh %r0, 4095 + mh %r0, 0(%r1) + mh %r0, 0(%r15) + mh %r0, 4095(%r1,%r15) + mh %r0, 4095(%r15,%r1) + mh %r15, 0 diff --git a/test/MC/SystemZ/insn-mh-02.s b/test/MC/SystemZ/insn-mh-02.s new file mode 100644 index 00000000000..4ea35fca591 --- /dev/null +++ b/test/MC/SystemZ/insn-mh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mh %r0, -1 +#CHECK: error: invalid operand +#CHECK: mh %r0, 4096 + + mh %r0, -1 + mh %r0, 4096 diff --git a/test/MC/SystemZ/insn-mhi-01.s b/test/MC/SystemZ/insn-mhi-01.s new file mode 100644 index 00000000000..adf42ae7346 --- /dev/null +++ b/test/MC/SystemZ/insn-mhi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mhi %r0, -32768 # encoding: [0xa7,0x0c,0x80,0x00] +#CHECK: mhi %r0, -1 # encoding: [0xa7,0x0c,0xff,0xff] +#CHECK: mhi %r0, 0 # encoding: [0xa7,0x0c,0x00,0x00] +#CHECK: mhi %r0, 1 # encoding: [0xa7,0x0c,0x00,0x01] +#CHECK: mhi %r0, 32767 # encoding: [0xa7,0x0c,0x7f,0xff] +#CHECK: mhi %r15, 0 # encoding: [0xa7,0xfc,0x00,0x00] + + mhi %r0, -32768 + mhi %r0, -1 + mhi %r0, 0 + mhi %r0, 1 + mhi %r0, 32767 + mhi %r15, 0 diff --git a/test/MC/SystemZ/insn-mhi-02.s b/test/MC/SystemZ/insn-mhi-02.s new file mode 100644 index 00000000000..74e83576e91 --- /dev/null +++ b/test/MC/SystemZ/insn-mhi-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mhi %r0, -32769 +#CHECK: error: invalid operand +#CHECK: mhi %r0, 32768 +#CHECK: error: invalid operand +#CHECK: mhi %r0, foo + + mhi %r0, -32769 + mhi %r0, 32768 + mhi %r0, foo diff --git a/test/MC/SystemZ/insn-mhy-01.s b/test/MC/SystemZ/insn-mhy-01.s new file mode 100644 index 00000000000..89c394bd81e --- /dev/null +++ b/test/MC/SystemZ/insn-mhy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mhy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x7c] +#CHECK: mhy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x7c] +#CHECK: mhy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x7c] +#CHECK: mhy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x7c] +#CHECK: mhy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x7c] +#CHECK: mhy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x7c] +#CHECK: mhy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x7c] +#CHECK: mhy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x7c] +#CHECK: mhy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x7c] +#CHECK: mhy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x7c] + + mhy %r0, -524288 + mhy %r0, -1 + mhy %r0, 0 + mhy %r0, 1 + mhy %r0, 524287 + mhy %r0, 0(%r1) + mhy %r0, 0(%r15) + mhy %r0, 524287(%r1,%r15) + mhy %r0, 524287(%r15,%r1) + mhy %r15, 0 diff --git a/test/MC/SystemZ/insn-mhy-02.s b/test/MC/SystemZ/insn-mhy-02.s new file mode 100644 index 00000000000..bce62f096c1 --- /dev/null +++ b/test/MC/SystemZ/insn-mhy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mhy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: mhy %r0, 524288 + + mhy %r0, -524289 + mhy %r0, 524288 diff --git a/test/MC/SystemZ/insn-mlg-01.s b/test/MC/SystemZ/insn-mlg-01.s new file mode 100644 index 00000000000..e9bd6510fc6 --- /dev/null +++ b/test/MC/SystemZ/insn-mlg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mlg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x86] +#CHECK: mlg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x86] +#CHECK: mlg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x86] +#CHECK: mlg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x86] +#CHECK: mlg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x86] +#CHECK: mlg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x86] +#CHECK: mlg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x86] +#CHECK: mlg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x86] +#CHECK: mlg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x86] +#CHECK: mlg %r14, 0 # encoding: [0xe3,0xe0,0x00,0x00,0x00,0x86] + + mlg %r0, -524288 + mlg %r0, -1 + mlg %r0, 0 + mlg %r0, 1 + mlg %r0, 524287 + mlg %r0, 0(%r1) + mlg %r0, 0(%r15) + mlg %r0, 524287(%r1,%r15) + mlg %r0, 524287(%r15,%r1) + mlg %r14, 0 diff --git a/test/MC/SystemZ/insn-mlg-02.s b/test/MC/SystemZ/insn-mlg-02.s new file mode 100644 index 00000000000..7174bc50c2f --- /dev/null +++ b/test/MC/SystemZ/insn-mlg-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mlg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: mlg %r0, 524288 +#CHECK: error: invalid register +#CHECK: mlg %r1, 0 +#CHECK: error: invalid register +#CHECK: mlg %r15, 0 + + mlg %r0, -524289 + mlg %r0, 524288 + mlg %r1, 0 + mlg %r15, 0 diff --git a/test/MC/SystemZ/insn-mlgr-01.s b/test/MC/SystemZ/insn-mlgr-01.s new file mode 100644 index 00000000000..215bde09915 --- /dev/null +++ b/test/MC/SystemZ/insn-mlgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mlgr %r0, %r0 # encoding: [0xb9,0x86,0x00,0x00] +#CHECK: mlgr %r0, %r15 # encoding: [0xb9,0x86,0x00,0x0f] +#CHECK: mlgr %r14, %r0 # encoding: [0xb9,0x86,0x00,0xe0] +#CHECK: mlgr %r6, %r9 # encoding: [0xb9,0x86,0x00,0x69] + + mlgr %r0,%r0 + mlgr %r0,%r15 + mlgr %r14,%r0 + mlgr %r6,%r9 diff --git a/test/MC/SystemZ/insn-mlgr-02.s b/test/MC/SystemZ/insn-mlgr-02.s new file mode 100644 index 00000000000..30f4259031b --- /dev/null +++ b/test/MC/SystemZ/insn-mlgr-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: mlgr %r1, %r0 +#CHECK: error: invalid register +#CHECK: mlgr %r15, %r0 + + mlgr %r1, %r0 + mlgr %r15, %r0 diff --git a/test/MC/SystemZ/insn-ms-01.s b/test/MC/SystemZ/insn-ms-01.s new file mode 100644 index 00000000000..e104e09a1bf --- /dev/null +++ b/test/MC/SystemZ/insn-ms-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ms %r0, 0 # encoding: [0x71,0x00,0x00,0x00] +#CHECK: ms %r0, 4095 # encoding: [0x71,0x00,0x0f,0xff] +#CHECK: ms %r0, 0(%r1) # encoding: [0x71,0x00,0x10,0x00] +#CHECK: ms %r0, 0(%r15) # encoding: [0x71,0x00,0xf0,0x00] +#CHECK: ms %r0, 4095(%r1,%r15) # encoding: [0x71,0x01,0xff,0xff] +#CHECK: ms %r0, 4095(%r15,%r1) # encoding: [0x71,0x0f,0x1f,0xff] +#CHECK: ms %r15, 0 # encoding: [0x71,0xf0,0x00,0x00] + + ms %r0, 0 + ms %r0, 4095 + ms %r0, 0(%r1) + ms %r0, 0(%r15) + ms %r0, 4095(%r1,%r15) + ms %r0, 4095(%r15,%r1) + ms %r15, 0 diff --git a/test/MC/SystemZ/insn-ms-02.s b/test/MC/SystemZ/insn-ms-02.s new file mode 100644 index 00000000000..9cc7ecda340 --- /dev/null +++ b/test/MC/SystemZ/insn-ms-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ms %r0, -1 +#CHECK: error: invalid operand +#CHECK: ms %r0, 4096 + + ms %r0, -1 + ms %r0, 4096 diff --git a/test/MC/SystemZ/insn-msdb-01.s b/test/MC/SystemZ/insn-msdb-01.s new file mode 100644 index 00000000000..50ef45bfc42 --- /dev/null +++ b/test/MC/SystemZ/insn-msdb-01.s @@ -0,0 +1,21 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msdb %f0, %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x1f] +#CHECK: msdb %f0, %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x1f] +#CHECK: msdb %f0, %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x1f] +#CHECK: msdb %f0, %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x1f] +#CHECK: msdb %f0, %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x1f] +#CHECK: msdb %f0, %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x1f] +#CHECK: msdb %f0, %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x1f] +#CHECK: msdb %f15, %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0xf0,0x1f] +#CHECK: msdb %f15, %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0xf0,0x1f] + + msdb %f0, %f0, 0 + msdb %f0, %f0, 4095 + msdb %f0, %f0, 0(%r1) + msdb %f0, %f0, 0(%r15) + msdb %f0, %f0, 4095(%r1,%r15) + msdb %f0, %f0, 4095(%r15,%r1) + msdb %f0, %f15, 0 + msdb %f15, %f0, 0 + msdb %f15, %f15, 0 diff --git a/test/MC/SystemZ/insn-msdb-02.s b/test/MC/SystemZ/insn-msdb-02.s new file mode 100644 index 00000000000..552fc72223d --- /dev/null +++ b/test/MC/SystemZ/insn-msdb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: msdb %f0, %f0, -1 +#CHECK: error: invalid operand +#CHECK: msdb %f0, %f0, 4096 + + msdb %f0, %f0, -1 + msdb %f0, %f0, 4096 diff --git a/test/MC/SystemZ/insn-msdbr-01.s b/test/MC/SystemZ/insn-msdbr-01.s new file mode 100644 index 00000000000..0c816578a2a --- /dev/null +++ b/test/MC/SystemZ/insn-msdbr-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msdbr %f0, %f0, %f0 # encoding: [0xb3,0x1f,0x00,0x00] +#CHECK: msdbr %f0, %f0, %f15 # encoding: [0xb3,0x1f,0x00,0x0f] +#CHECK: msdbr %f0, %f15, %f0 # encoding: [0xb3,0x1f,0x00,0xf0] +#CHECK: msdbr %f15, %f0, %f0 # encoding: [0xb3,0x1f,0xf0,0x00] +#CHECK: msdbr %f7, %f8, %f9 # encoding: [0xb3,0x1f,0x70,0x89] +#CHECK: msdbr %f15, %f15, %f15 # encoding: [0xb3,0x1f,0xf0,0xff] + + msdbr %f0, %f0, %f0 + msdbr %f0, %f0, %f15 + msdbr %f0, %f15, %f0 + msdbr %f15, %f0, %f0 + msdbr %f7, %f8, %f9 + msdbr %f15, %f15, %f15 diff --git a/test/MC/SystemZ/insn-mseb-01.s b/test/MC/SystemZ/insn-mseb-01.s new file mode 100644 index 00000000000..4464cfb803c --- /dev/null +++ b/test/MC/SystemZ/insn-mseb-01.s @@ -0,0 +1,21 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mseb %f0, %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x0f] +#CHECK: mseb %f0, %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x0f] +#CHECK: mseb %f0, %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x0f] +#CHECK: mseb %f0, %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x0f] +#CHECK: mseb %f0, %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x0f] +#CHECK: mseb %f0, %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x0f] +#CHECK: mseb %f0, %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x0f] +#CHECK: mseb %f15, %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0xf0,0x0f] +#CHECK: mseb %f15, %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0xf0,0x0f] + + mseb %f0, %f0, 0 + mseb %f0, %f0, 4095 + mseb %f0, %f0, 0(%r1) + mseb %f0, %f0, 0(%r15) + mseb %f0, %f0, 4095(%r1,%r15) + mseb %f0, %f0, 4095(%r15,%r1) + mseb %f0, %f15, 0 + mseb %f15, %f0, 0 + mseb %f15, %f15, 0 diff --git a/test/MC/SystemZ/insn-mseb-02.s b/test/MC/SystemZ/insn-mseb-02.s new file mode 100644 index 00000000000..03aaa0fb8a6 --- /dev/null +++ b/test/MC/SystemZ/insn-mseb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mseb %f0, %f0, -1 +#CHECK: error: invalid operand +#CHECK: mseb %f0, %f0, 4096 + + mseb %f0, %f0, -1 + mseb %f0, %f0, 4096 diff --git a/test/MC/SystemZ/insn-msebr-01.s b/test/MC/SystemZ/insn-msebr-01.s new file mode 100644 index 00000000000..f936cb63252 --- /dev/null +++ b/test/MC/SystemZ/insn-msebr-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msebr %f0, %f0, %f0 # encoding: [0xb3,0x0f,0x00,0x00] +#CHECK: msebr %f0, %f0, %f15 # encoding: [0xb3,0x0f,0x00,0x0f] +#CHECK: msebr %f0, %f15, %f0 # encoding: [0xb3,0x0f,0x00,0xf0] +#CHECK: msebr %f15, %f0, %f0 # encoding: [0xb3,0x0f,0xf0,0x00] +#CHECK: msebr %f7, %f8, %f9 # encoding: [0xb3,0x0f,0x70,0x89] +#CHECK: msebr %f15, %f15, %f15 # encoding: [0xb3,0x0f,0xf0,0xff] + + msebr %f0, %f0, %f0 + msebr %f0, %f0, %f15 + msebr %f0, %f15, %f0 + msebr %f15, %f0, %f0 + msebr %f7, %f8, %f9 + msebr %f15, %f15, %f15 diff --git a/test/MC/SystemZ/insn-msfi-01.s b/test/MC/SystemZ/insn-msfi-01.s new file mode 100644 index 00000000000..629260e4206 --- /dev/null +++ b/test/MC/SystemZ/insn-msfi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msfi %r0, -2147483648 # encoding: [0xc2,0x01,0x80,0x00,0x00,0x00] +#CHECK: msfi %r0, -1 # encoding: [0xc2,0x01,0xff,0xff,0xff,0xff] +#CHECK: msfi %r0, 0 # encoding: [0xc2,0x01,0x00,0x00,0x00,0x00] +#CHECK: msfi %r0, 1 # encoding: [0xc2,0x01,0x00,0x00,0x00,0x01] +#CHECK: msfi %r0, 2147483647 # encoding: [0xc2,0x01,0x7f,0xff,0xff,0xff] +#CHECK: msfi %r15, 0 # encoding: [0xc2,0xf1,0x00,0x00,0x00,0x00] + + msfi %r0, -1 << 31 + msfi %r0, -1 + msfi %r0, 0 + msfi %r0, 1 + msfi %r0, (1 << 31) - 1 + msfi %r15, 0 diff --git a/test/MC/SystemZ/insn-msfi-02.s b/test/MC/SystemZ/insn-msfi-02.s new file mode 100644 index 00000000000..2700ce78b8e --- /dev/null +++ b/test/MC/SystemZ/insn-msfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: msfi %r0, (-1 << 31) - 1 +#CHECK: error: invalid operand +#CHECK: msfi %r0, (1 << 31) + + msfi %r0, (-1 << 31) - 1 + msfi %r0, (1 << 31) diff --git a/test/MC/SystemZ/insn-msg-01.s b/test/MC/SystemZ/insn-msg-01.s new file mode 100644 index 00000000000..298811c1e96 --- /dev/null +++ b/test/MC/SystemZ/insn-msg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x0c] +#CHECK: msg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x0c] +#CHECK: msg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x0c] +#CHECK: msg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x0c] +#CHECK: msg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x0c] +#CHECK: msg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x0c] +#CHECK: msg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x0c] +#CHECK: msg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x0c] +#CHECK: msg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x0c] +#CHECK: msg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x0c] + + msg %r0, -524288 + msg %r0, -1 + msg %r0, 0 + msg %r0, 1 + msg %r0, 524287 + msg %r0, 0(%r1) + msg %r0, 0(%r15) + msg %r0, 524287(%r1,%r15) + msg %r0, 524287(%r15,%r1) + msg %r15, 0 diff --git a/test/MC/SystemZ/insn-msg-02.s b/test/MC/SystemZ/insn-msg-02.s new file mode 100644 index 00000000000..3326f40e56a --- /dev/null +++ b/test/MC/SystemZ/insn-msg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: msg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: msg %r0, 524288 + + msg %r0, -524289 + msg %r0, 524288 diff --git a/test/MC/SystemZ/insn-msgf-01.s b/test/MC/SystemZ/insn-msgf-01.s new file mode 100644 index 00000000000..9812bcc9cb4 --- /dev/null +++ b/test/MC/SystemZ/insn-msgf-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msgf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x1c] +#CHECK: msgf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x1c] +#CHECK: msgf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x1c] +#CHECK: msgf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x1c] +#CHECK: msgf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x1c] +#CHECK: msgf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x1c] +#CHECK: msgf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x1c] +#CHECK: msgf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x1c] +#CHECK: msgf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x1c] +#CHECK: msgf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x1c] + + msgf %r0, -524288 + msgf %r0, -1 + msgf %r0, 0 + msgf %r0, 1 + msgf %r0, 524287 + msgf %r0, 0(%r1) + msgf %r0, 0(%r15) + msgf %r0, 524287(%r1,%r15) + msgf %r0, 524287(%r15,%r1) + msgf %r15, 0 diff --git a/test/MC/SystemZ/insn-msgf-02.s b/test/MC/SystemZ/insn-msgf-02.s new file mode 100644 index 00000000000..03983b305f0 --- /dev/null +++ b/test/MC/SystemZ/insn-msgf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: msgf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: msgf %r0, 524288 + + msgf %r0, -524289 + msgf %r0, 524288 diff --git a/test/MC/SystemZ/insn-msgfi-01.s b/test/MC/SystemZ/insn-msgfi-01.s new file mode 100644 index 00000000000..802ad143a50 --- /dev/null +++ b/test/MC/SystemZ/insn-msgfi-01.s @@ -0,0 +1,15 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msgfi %r0, -2147483648 # encoding: [0xc2,0x00,0x80,0x00,0x00,0x00] +#CHECK: msgfi %r0, -1 # encoding: [0xc2,0x00,0xff,0xff,0xff,0xff] +#CHECK: msgfi %r0, 0 # encoding: [0xc2,0x00,0x00,0x00,0x00,0x00] +#CHECK: msgfi %r0, 1 # encoding: [0xc2,0x00,0x00,0x00,0x00,0x01] +#CHECK: msgfi %r0, 2147483647 # encoding: [0xc2,0x00,0x7f,0xff,0xff,0xff] +#CHECK: msgfi %r15, 0 # encoding: [0xc2,0xf0,0x00,0x00,0x00,0x00] + + msgfi %r0, -1 << 31 + msgfi %r0, -1 + msgfi %r0, 0 + msgfi %r0, 1 + msgfi %r0, (1 << 31) - 1 + msgfi %r15, 0 diff --git a/test/MC/SystemZ/insn-msgfi-02.s b/test/MC/SystemZ/insn-msgfi-02.s new file mode 100644 index 00000000000..82e1f8f9b44 --- /dev/null +++ b/test/MC/SystemZ/insn-msgfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: msgfi %r0, (-1 << 31) - 1 +#CHECK: error: invalid operand +#CHECK: msgfi %r0, (1 << 31) + + msgfi %r0, (-1 << 31) - 1 + msgfi %r0, (1 << 31) diff --git a/test/MC/SystemZ/insn-msgfr-01.s b/test/MC/SystemZ/insn-msgfr-01.s new file mode 100644 index 00000000000..e25f6302ac6 --- /dev/null +++ b/test/MC/SystemZ/insn-msgfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msgfr %r0, %r0 # encoding: [0xb9,0x1c,0x00,0x00] +#CHECK: msgfr %r0, %r15 # encoding: [0xb9,0x1c,0x00,0x0f] +#CHECK: msgfr %r15, %r0 # encoding: [0xb9,0x1c,0x00,0xf0] +#CHECK: msgfr %r7, %r8 # encoding: [0xb9,0x1c,0x00,0x78] + + msgfr %r0,%r0 + msgfr %r0,%r15 + msgfr %r15,%r0 + msgfr %r7,%r8 diff --git a/test/MC/SystemZ/insn-msgr-01.s b/test/MC/SystemZ/insn-msgr-01.s new file mode 100644 index 00000000000..0b9cd360c8f --- /dev/null +++ b/test/MC/SystemZ/insn-msgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msgr %r0, %r0 # encoding: [0xb9,0x0c,0x00,0x00] +#CHECK: msgr %r0, %r15 # encoding: [0xb9,0x0c,0x00,0x0f] +#CHECK: msgr %r15, %r0 # encoding: [0xb9,0x0c,0x00,0xf0] +#CHECK: msgr %r7, %r8 # encoding: [0xb9,0x0c,0x00,0x78] + + msgr %r0,%r0 + msgr %r0,%r15 + msgr %r15,%r0 + msgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-msr-01.s b/test/MC/SystemZ/insn-msr-01.s new file mode 100644 index 00000000000..6f7d917a16c --- /dev/null +++ b/test/MC/SystemZ/insn-msr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msr %r0, %r0 # encoding: [0xb2,0x52,0x00,0x00] +#CHECK: msr %r0, %r15 # encoding: [0xb2,0x52,0x00,0x0f] +#CHECK: msr %r15, %r0 # encoding: [0xb2,0x52,0x00,0xf0] +#CHECK: msr %r7, %r8 # encoding: [0xb2,0x52,0x00,0x78] + + msr %r0,%r0 + msr %r0,%r15 + msr %r15,%r0 + msr %r7,%r8 diff --git a/test/MC/SystemZ/insn-msy-01.s b/test/MC/SystemZ/insn-msy-01.s new file mode 100644 index 00000000000..aed9318a8a5 --- /dev/null +++ b/test/MC/SystemZ/insn-msy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: msy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x51] +#CHECK: msy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x51] +#CHECK: msy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x51] +#CHECK: msy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x51] +#CHECK: msy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x51] +#CHECK: msy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x51] +#CHECK: msy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x51] +#CHECK: msy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x51] +#CHECK: msy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x51] +#CHECK: msy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x51] + + msy %r0, -524288 + msy %r0, -1 + msy %r0, 0 + msy %r0, 1 + msy %r0, 524287 + msy %r0, 0(%r1) + msy %r0, 0(%r15) + msy %r0, 524287(%r1,%r15) + msy %r0, 524287(%r15,%r1) + msy %r15, 0 diff --git a/test/MC/SystemZ/insn-msy-02.s b/test/MC/SystemZ/insn-msy-02.s new file mode 100644 index 00000000000..6f10069ae70 --- /dev/null +++ b/test/MC/SystemZ/insn-msy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: msy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: msy %r0, 524288 + + msy %r0, -524289 + msy %r0, 524288 diff --git a/test/MC/SystemZ/insn-mvghi-01.s b/test/MC/SystemZ/insn-mvghi-01.s new file mode 100644 index 00000000000..191aa49cd85 --- /dev/null +++ b/test/MC/SystemZ/insn-mvghi-01.s @@ -0,0 +1,25 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mvghi 0, 0 # encoding: [0xe5,0x48,0x00,0x00,0x00,0x00] +#CHECK: mvghi 4095, 0 # encoding: [0xe5,0x48,0x0f,0xff,0x00,0x00] +#CHECK: mvghi 0, -32768 # encoding: [0xe5,0x48,0x00,0x00,0x80,0x00] +#CHECK: mvghi 0, -1 # encoding: [0xe5,0x48,0x00,0x00,0xff,0xff] +#CHECK: mvghi 0, 0 # encoding: [0xe5,0x48,0x00,0x00,0x00,0x00] +#CHECK: mvghi 0, 1 # encoding: [0xe5,0x48,0x00,0x00,0x00,0x01] +#CHECK: mvghi 0, 32767 # encoding: [0xe5,0x48,0x00,0x00,0x7f,0xff] +#CHECK: mvghi 0(%r1), 42 # encoding: [0xe5,0x48,0x10,0x00,0x00,0x2a] +#CHECK: mvghi 0(%r15), 42 # encoding: [0xe5,0x48,0xf0,0x00,0x00,0x2a] +#CHECK: mvghi 4095(%r1), 42 # encoding: [0xe5,0x48,0x1f,0xff,0x00,0x2a] +#CHECK: mvghi 4095(%r15), 42 # encoding: [0xe5,0x48,0xff,0xff,0x00,0x2a] + + mvghi 0, 0 + mvghi 4095, 0 + mvghi 0, -32768 + mvghi 0, -1 + mvghi 0, 0 + mvghi 0, 1 + mvghi 0, 32767 + mvghi 0(%r1), 42 + mvghi 0(%r15), 42 + mvghi 4095(%r1), 42 + mvghi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-mvghi-02.s b/test/MC/SystemZ/insn-mvghi-02.s new file mode 100644 index 00000000000..38b38a517a0 --- /dev/null +++ b/test/MC/SystemZ/insn-mvghi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mvghi -1, 0 +#CHECK: error: invalid operand +#CHECK: mvghi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: mvghi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: mvghi 0, -32769 +#CHECK: error: invalid operand +#CHECK: mvghi 0, 32768 + + mvghi -1, 0 + mvghi 4096, 0 + mvghi 0(%r1,%r2), 0 + mvghi 0, -32769 + mvghi 0, 32768 diff --git a/test/MC/SystemZ/insn-mvhhi-01.s b/test/MC/SystemZ/insn-mvhhi-01.s new file mode 100644 index 00000000000..63574a487f9 --- /dev/null +++ b/test/MC/SystemZ/insn-mvhhi-01.s @@ -0,0 +1,25 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mvhhi 0, 0 # encoding: [0xe5,0x44,0x00,0x00,0x00,0x00] +#CHECK: mvhhi 4095, 0 # encoding: [0xe5,0x44,0x0f,0xff,0x00,0x00] +#CHECK: mvhhi 0, -32768 # encoding: [0xe5,0x44,0x00,0x00,0x80,0x00] +#CHECK: mvhhi 0, -1 # encoding: [0xe5,0x44,0x00,0x00,0xff,0xff] +#CHECK: mvhhi 0, 0 # encoding: [0xe5,0x44,0x00,0x00,0x00,0x00] +#CHECK: mvhhi 0, 1 # encoding: [0xe5,0x44,0x00,0x00,0x00,0x01] +#CHECK: mvhhi 0, 32767 # encoding: [0xe5,0x44,0x00,0x00,0x7f,0xff] +#CHECK: mvhhi 0(%r1), 42 # encoding: [0xe5,0x44,0x10,0x00,0x00,0x2a] +#CHECK: mvhhi 0(%r15), 42 # encoding: [0xe5,0x44,0xf0,0x00,0x00,0x2a] +#CHECK: mvhhi 4095(%r1), 42 # encoding: [0xe5,0x44,0x1f,0xff,0x00,0x2a] +#CHECK: mvhhi 4095(%r15), 42 # encoding: [0xe5,0x44,0xff,0xff,0x00,0x2a] + + mvhhi 0, 0 + mvhhi 4095, 0 + mvhhi 0, -32768 + mvhhi 0, -1 + mvhhi 0, 0 + mvhhi 0, 1 + mvhhi 0, 32767 + mvhhi 0(%r1), 42 + mvhhi 0(%r15), 42 + mvhhi 4095(%r1), 42 + mvhhi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-mvhhi-02.s b/test/MC/SystemZ/insn-mvhhi-02.s new file mode 100644 index 00000000000..58abb025ebd --- /dev/null +++ b/test/MC/SystemZ/insn-mvhhi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mvhhi -1, 0 +#CHECK: error: invalid operand +#CHECK: mvhhi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: mvhhi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: mvhhi 0, -32769 +#CHECK: error: invalid operand +#CHECK: mvhhi 0, 32768 + + mvhhi -1, 0 + mvhhi 4096, 0 + mvhhi 0(%r1,%r2), 0 + mvhhi 0, -32769 + mvhhi 0, 32768 diff --git a/test/MC/SystemZ/insn-mvhi-01.s b/test/MC/SystemZ/insn-mvhi-01.s new file mode 100644 index 00000000000..5bf9fd31216 --- /dev/null +++ b/test/MC/SystemZ/insn-mvhi-01.s @@ -0,0 +1,25 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mvhi 0, 0 # encoding: [0xe5,0x4c,0x00,0x00,0x00,0x00] +#CHECK: mvhi 4095, 0 # encoding: [0xe5,0x4c,0x0f,0xff,0x00,0x00] +#CHECK: mvhi 0, -32768 # encoding: [0xe5,0x4c,0x00,0x00,0x80,0x00] +#CHECK: mvhi 0, -1 # encoding: [0xe5,0x4c,0x00,0x00,0xff,0xff] +#CHECK: mvhi 0, 0 # encoding: [0xe5,0x4c,0x00,0x00,0x00,0x00] +#CHECK: mvhi 0, 1 # encoding: [0xe5,0x4c,0x00,0x00,0x00,0x01] +#CHECK: mvhi 0, 32767 # encoding: [0xe5,0x4c,0x00,0x00,0x7f,0xff] +#CHECK: mvhi 0(%r1), 42 # encoding: [0xe5,0x4c,0x10,0x00,0x00,0x2a] +#CHECK: mvhi 0(%r15), 42 # encoding: [0xe5,0x4c,0xf0,0x00,0x00,0x2a] +#CHECK: mvhi 4095(%r1), 42 # encoding: [0xe5,0x4c,0x1f,0xff,0x00,0x2a] +#CHECK: mvhi 4095(%r15), 42 # encoding: [0xe5,0x4c,0xff,0xff,0x00,0x2a] + + mvhi 0, 0 + mvhi 4095, 0 + mvhi 0, -32768 + mvhi 0, -1 + mvhi 0, 0 + mvhi 0, 1 + mvhi 0, 32767 + mvhi 0(%r1), 42 + mvhi 0(%r15), 42 + mvhi 4095(%r1), 42 + mvhi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-mvhi-02.s b/test/MC/SystemZ/insn-mvhi-02.s new file mode 100644 index 00000000000..517301c5135 --- /dev/null +++ b/test/MC/SystemZ/insn-mvhi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mvhi -1, 0 +#CHECK: error: invalid operand +#CHECK: mvhi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: mvhi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: mvhi 0, -32769 +#CHECK: error: invalid operand +#CHECK: mvhi 0, 32768 + + mvhi -1, 0 + mvhi 4096, 0 + mvhi 0(%r1,%r2), 0 + mvhi 0, -32769 + mvhi 0, 32768 diff --git a/test/MC/SystemZ/insn-mvi-01.s b/test/MC/SystemZ/insn-mvi-01.s new file mode 100644 index 00000000000..83e30900ac3 --- /dev/null +++ b/test/MC/SystemZ/insn-mvi-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mvi 0, 0 # encoding: [0x92,0x00,0x00,0x00] +#CHECK: mvi 4095, 0 # encoding: [0x92,0x00,0x0f,0xff] +#CHECK: mvi 0, 255 # encoding: [0x92,0xff,0x00,0x00] +#CHECK: mvi 0(%r1), 42 # encoding: [0x92,0x2a,0x10,0x00] +#CHECK: mvi 0(%r15), 42 # encoding: [0x92,0x2a,0xf0,0x00] +#CHECK: mvi 4095(%r1), 42 # encoding: [0x92,0x2a,0x1f,0xff] +#CHECK: mvi 4095(%r15), 42 # encoding: [0x92,0x2a,0xff,0xff] + + mvi 0, 0 + mvi 4095, 0 + mvi 0, 255 + mvi 0(%r1), 42 + mvi 0(%r15), 42 + mvi 4095(%r1), 42 + mvi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-mvi-02.s b/test/MC/SystemZ/insn-mvi-02.s new file mode 100644 index 00000000000..ddd5909d459 --- /dev/null +++ b/test/MC/SystemZ/insn-mvi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mvi -1, 0 +#CHECK: error: invalid operand +#CHECK: mvi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: mvi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: mvi 0, -1 +#CHECK: error: invalid operand +#CHECK: mvi 0, 256 + + mvi -1, 0 + mvi 4096, 0 + mvi 0(%r1,%r2), 0 + mvi 0, -1 + mvi 0, 256 diff --git a/test/MC/SystemZ/insn-mviy-01.s b/test/MC/SystemZ/insn-mviy-01.s new file mode 100644 index 00000000000..8bd6979b81e --- /dev/null +++ b/test/MC/SystemZ/insn-mviy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mviy -524288, 0 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x52] +#CHECK: mviy -1, 0 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x52] +#CHECK: mviy 0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x52] +#CHECK: mviy 1, 0 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x52] +#CHECK: mviy 524287, 0 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x52] +#CHECK: mviy 0, 255 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x52] +#CHECK: mviy 0(%r1), 42 # encoding: [0xeb,0x2a,0x10,0x00,0x00,0x52] +#CHECK: mviy 0(%r15), 42 # encoding: [0xeb,0x2a,0xf0,0x00,0x00,0x52] +#CHECK: mviy 524287(%r1), 42 # encoding: [0xeb,0x2a,0x1f,0xff,0x7f,0x52] +#CHECK: mviy 524287(%r15), 42 # encoding: [0xeb,0x2a,0xff,0xff,0x7f,0x52] + + mviy -524288, 0 + mviy -1, 0 + mviy 0, 0 + mviy 1, 0 + mviy 524287, 0 + mviy 0, 255 + mviy 0(%r1), 42 + mviy 0(%r15), 42 + mviy 524287(%r1), 42 + mviy 524287(%r15), 42 diff --git a/test/MC/SystemZ/insn-mviy-02.s b/test/MC/SystemZ/insn-mviy-02.s new file mode 100644 index 00000000000..ab78dab5c97 --- /dev/null +++ b/test/MC/SystemZ/insn-mviy-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: mviy -524289, 0 +#CHECK: error: invalid operand +#CHECK: mviy 524288, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: mviy 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: mviy 0, -1 +#CHECK: error: invalid operand +#CHECK: mviy 0, 256 + + mviy -524289, 0 + mviy 524288, 0 + mviy 0(%r1,%r2), 0 + mviy 0, -1 + mviy 0, 256 diff --git a/test/MC/SystemZ/insn-mxbr-01.s b/test/MC/SystemZ/insn-mxbr-01.s new file mode 100644 index 00000000000..60c8ebadfba --- /dev/null +++ b/test/MC/SystemZ/insn-mxbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mxbr %f0, %f0 # encoding: [0xb3,0x4c,0x00,0x00] +#CHECK: mxbr %f0, %f13 # encoding: [0xb3,0x4c,0x00,0x0d] +#CHECK: mxbr %f8, %f5 # encoding: [0xb3,0x4c,0x00,0x85] +#CHECK: mxbr %f13, %f13 # encoding: [0xb3,0x4c,0x00,0xdd] + + mxbr %f0, %f0 + mxbr %f0, %f13 + mxbr %f8, %f5 + mxbr %f13, %f13 diff --git a/test/MC/SystemZ/insn-mxbr-02.s b/test/MC/SystemZ/insn-mxbr-02.s new file mode 100644 index 00000000000..92820234139 --- /dev/null +++ b/test/MC/SystemZ/insn-mxbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: mxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: mxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: mxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: mxbr %f14, %f0 + + mxbr %f0, %f2 + mxbr %f0, %f14 + mxbr %f2, %f0 + mxbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-mxdb-01.s b/test/MC/SystemZ/insn-mxdb-01.s new file mode 100644 index 00000000000..46a723e8426 --- /dev/null +++ b/test/MC/SystemZ/insn-mxdb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mxdb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x07] +#CHECK: mxdb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x07] +#CHECK: mxdb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x07] +#CHECK: mxdb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x07] +#CHECK: mxdb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x07] +#CHECK: mxdb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x07] +#CHECK: mxdb %f13, 0 # encoding: [0xed,0xd0,0x00,0x00,0x00,0x07] + + mxdb %f0, 0 + mxdb %f0, 4095 + mxdb %f0, 0(%r1) + mxdb %f0, 0(%r15) + mxdb %f0, 4095(%r1,%r15) + mxdb %f0, 4095(%r15,%r1) + mxdb %f13, 0 diff --git a/test/MC/SystemZ/insn-mxdb-02.s b/test/MC/SystemZ/insn-mxdb-02.s new file mode 100644 index 00000000000..44c821cad03 --- /dev/null +++ b/test/MC/SystemZ/insn-mxdb-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: mxdb %f2, 0 +#CHECK: error: invalid register +#CHECK: mxdb %f15, 0 +#CHECK: error: invalid operand +#CHECK: mxdb %f0, -1 +#CHECK: error: invalid operand +#CHECK: mxdb %f0, 4096 + + mxdb %f2, 0 + mxdb %f15, 0 + mxdb %f0, -1 + mxdb %f0, 4096 diff --git a/test/MC/SystemZ/insn-mxdbr-01.s b/test/MC/SystemZ/insn-mxdbr-01.s new file mode 100644 index 00000000000..dfb898fbdaf --- /dev/null +++ b/test/MC/SystemZ/insn-mxdbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: mxdbr %f0, %f0 # encoding: [0xb3,0x07,0x00,0x00] +#CHECK: mxdbr %f0, %f15 # encoding: [0xb3,0x07,0x00,0x0f] +#CHECK: mxdbr %f8, %f8 # encoding: [0xb3,0x07,0x00,0x88] +#CHECK: mxdbr %f13, %f0 # encoding: [0xb3,0x07,0x00,0xd0] + + mxdbr %f0, %f0 + mxdbr %f0, %f15 + mxdbr %f8, %f8 + mxdbr %f13, %f0 diff --git a/test/MC/SystemZ/insn-mxdbr-02.s b/test/MC/SystemZ/insn-mxdbr-02.s new file mode 100644 index 00000000000..90260481f2a --- /dev/null +++ b/test/MC/SystemZ/insn-mxdbr-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: mxdbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: mxdbr %f15, %f0 + + mxdbr %f2, %f0 + mxdbr %f15, %f0 diff --git a/test/MC/SystemZ/insn-n-01.s b/test/MC/SystemZ/insn-n-01.s new file mode 100644 index 00000000000..75fa141e2c8 --- /dev/null +++ b/test/MC/SystemZ/insn-n-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: n %r0, 0 # encoding: [0x54,0x00,0x00,0x00] +#CHECK: n %r0, 4095 # encoding: [0x54,0x00,0x0f,0xff] +#CHECK: n %r0, 0(%r1) # encoding: [0x54,0x00,0x10,0x00] +#CHECK: n %r0, 0(%r15) # encoding: [0x54,0x00,0xf0,0x00] +#CHECK: n %r0, 4095(%r1,%r15) # encoding: [0x54,0x01,0xff,0xff] +#CHECK: n %r0, 4095(%r15,%r1) # encoding: [0x54,0x0f,0x1f,0xff] +#CHECK: n %r15, 0 # encoding: [0x54,0xf0,0x00,0x00] + + n %r0, 0 + n %r0, 4095 + n %r0, 0(%r1) + n %r0, 0(%r15) + n %r0, 4095(%r1,%r15) + n %r0, 4095(%r15,%r1) + n %r15, 0 diff --git a/test/MC/SystemZ/insn-n-02.s b/test/MC/SystemZ/insn-n-02.s new file mode 100644 index 00000000000..7c14b1fe1c0 --- /dev/null +++ b/test/MC/SystemZ/insn-n-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: n %r0, -1 +#CHECK: error: invalid operand +#CHECK: n %r0, 4096 + + n %r0, -1 + n %r0, 4096 diff --git a/test/MC/SystemZ/insn-ng-01.s b/test/MC/SystemZ/insn-ng-01.s new file mode 100644 index 00000000000..bf71a2183f4 --- /dev/null +++ b/test/MC/SystemZ/insn-ng-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ng %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x80] +#CHECK: ng %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x80] +#CHECK: ng %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x80] +#CHECK: ng %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x80] +#CHECK: ng %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x80] +#CHECK: ng %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x80] +#CHECK: ng %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x80] +#CHECK: ng %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x80] +#CHECK: ng %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x80] +#CHECK: ng %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x80] + + ng %r0, -524288 + ng %r0, -1 + ng %r0, 0 + ng %r0, 1 + ng %r0, 524287 + ng %r0, 0(%r1) + ng %r0, 0(%r15) + ng %r0, 524287(%r1,%r15) + ng %r0, 524287(%r15,%r1) + ng %r15, 0 diff --git a/test/MC/SystemZ/insn-ng-02.s b/test/MC/SystemZ/insn-ng-02.s new file mode 100644 index 00000000000..a6f32605268 --- /dev/null +++ b/test/MC/SystemZ/insn-ng-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ng %r0, -524289 +#CHECK: error: invalid operand +#CHECK: ng %r0, 524288 + + ng %r0, -524289 + ng %r0, 524288 diff --git a/test/MC/SystemZ/insn-ngr-01.s b/test/MC/SystemZ/insn-ngr-01.s new file mode 100644 index 00000000000..714b9fa7129 --- /dev/null +++ b/test/MC/SystemZ/insn-ngr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ngr %r0, %r0 # encoding: [0xb9,0x80,0x00,0x00] +#CHECK: ngr %r0, %r15 # encoding: [0xb9,0x80,0x00,0x0f] +#CHECK: ngr %r15, %r0 # encoding: [0xb9,0x80,0x00,0xf0] +#CHECK: ngr %r7, %r8 # encoding: [0xb9,0x80,0x00,0x78] + + ngr %r0,%r0 + ngr %r0,%r15 + ngr %r15,%r0 + ngr %r7,%r8 diff --git a/test/MC/SystemZ/insn-ni-01.s b/test/MC/SystemZ/insn-ni-01.s new file mode 100644 index 00000000000..d075674feaa --- /dev/null +++ b/test/MC/SystemZ/insn-ni-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ni 0, 0 # encoding: [0x94,0x00,0x00,0x00] +#CHECK: ni 4095, 0 # encoding: [0x94,0x00,0x0f,0xff] +#CHECK: ni 0, 255 # encoding: [0x94,0xff,0x00,0x00] +#CHECK: ni 0(%r1), 42 # encoding: [0x94,0x2a,0x10,0x00] +#CHECK: ni 0(%r15), 42 # encoding: [0x94,0x2a,0xf0,0x00] +#CHECK: ni 4095(%r1), 42 # encoding: [0x94,0x2a,0x1f,0xff] +#CHECK: ni 4095(%r15), 42 # encoding: [0x94,0x2a,0xff,0xff] + + ni 0, 0 + ni 4095, 0 + ni 0, 255 + ni 0(%r1), 42 + ni 0(%r15), 42 + ni 4095(%r1), 42 + ni 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-ni-02.s b/test/MC/SystemZ/insn-ni-02.s new file mode 100644 index 00000000000..1b9a6a748de --- /dev/null +++ b/test/MC/SystemZ/insn-ni-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ni -1, 0 +#CHECK: error: invalid operand +#CHECK: ni 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: ni 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: ni 0, -1 +#CHECK: error: invalid operand +#CHECK: ni 0, 256 + + ni -1, 0 + ni 4096, 0 + ni 0(%r1,%r2), 0 + ni 0, -1 + ni 0, 256 diff --git a/test/MC/SystemZ/insn-nihf-01.s b/test/MC/SystemZ/insn-nihf-01.s new file mode 100644 index 00000000000..dceb8d1297c --- /dev/null +++ b/test/MC/SystemZ/insn-nihf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: nihf %r0, 0 # encoding: [0xc0,0x0a,0x00,0x00,0x00,0x00] +#CHECK: nihf %r0, 4294967295 # encoding: [0xc0,0x0a,0xff,0xff,0xff,0xff] +#CHECK: nihf %r15, 0 # encoding: [0xc0,0xfa,0x00,0x00,0x00,0x00] + + nihf %r0, 0 + nihf %r0, 0xffffffff + nihf %r15, 0 diff --git a/test/MC/SystemZ/insn-nihf-02.s b/test/MC/SystemZ/insn-nihf-02.s new file mode 100644 index 00000000000..5f7f10a6b3f --- /dev/null +++ b/test/MC/SystemZ/insn-nihf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: nihf %r0, -1 +#CHECK: error: invalid operand +#CHECK: nihf %r0, 1 << 32 + + nihf %r0, -1 + nihf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-nihh-01.s b/test/MC/SystemZ/insn-nihh-01.s new file mode 100644 index 00000000000..a87540d04c0 --- /dev/null +++ b/test/MC/SystemZ/insn-nihh-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: nihh %r0, 0 # encoding: [0xa5,0x04,0x00,0x00] +#CHECK: nihh %r0, 32768 # encoding: [0xa5,0x04,0x80,0x00] +#CHECK: nihh %r0, 65535 # encoding: [0xa5,0x04,0xff,0xff] +#CHECK: nihh %r15, 0 # encoding: [0xa5,0xf4,0x00,0x00] + + nihh %r0, 0 + nihh %r0, 0x8000 + nihh %r0, 0xffff + nihh %r15, 0 diff --git a/test/MC/SystemZ/insn-nihh-02.s b/test/MC/SystemZ/insn-nihh-02.s new file mode 100644 index 00000000000..3df88e40a28 --- /dev/null +++ b/test/MC/SystemZ/insn-nihh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: nihh %r0, -1 +#CHECK: error: invalid operand +#CHECK: nihh %r0, 0x10000 + + nihh %r0, -1 + nihh %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-nihl-01.s b/test/MC/SystemZ/insn-nihl-01.s new file mode 100644 index 00000000000..6eab58c7e7b --- /dev/null +++ b/test/MC/SystemZ/insn-nihl-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: nihl %r0, 0 # encoding: [0xa5,0x05,0x00,0x00] +#CHECK: nihl %r0, 32768 # encoding: [0xa5,0x05,0x80,0x00] +#CHECK: nihl %r0, 65535 # encoding: [0xa5,0x05,0xff,0xff] +#CHECK: nihl %r15, 0 # encoding: [0xa5,0xf5,0x00,0x00] + + nihl %r0, 0 + nihl %r0, 0x8000 + nihl %r0, 0xffff + nihl %r15, 0 diff --git a/test/MC/SystemZ/insn-nihl-02.s b/test/MC/SystemZ/insn-nihl-02.s new file mode 100644 index 00000000000..6e2d52f5a91 --- /dev/null +++ b/test/MC/SystemZ/insn-nihl-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: nihl %r0, -1 +#CHECK: error: invalid operand +#CHECK: nihl %r0, 0x10000 + + nihl %r0, -1 + nihl %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-nilf-01.s b/test/MC/SystemZ/insn-nilf-01.s new file mode 100644 index 00000000000..0b3a13e752c --- /dev/null +++ b/test/MC/SystemZ/insn-nilf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: nilf %r0, 0 # encoding: [0xc0,0x0b,0x00,0x00,0x00,0x00] +#CHECK: nilf %r0, 4294967295 # encoding: [0xc0,0x0b,0xff,0xff,0xff,0xff] +#CHECK: nilf %r15, 0 # encoding: [0xc0,0xfb,0x00,0x00,0x00,0x00] + + nilf %r0, 0 + nilf %r0, 0xffffffff + nilf %r15, 0 diff --git a/test/MC/SystemZ/insn-nilf-02.s b/test/MC/SystemZ/insn-nilf-02.s new file mode 100644 index 00000000000..87b65e46fe9 --- /dev/null +++ b/test/MC/SystemZ/insn-nilf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: nilf %r0, -1 +#CHECK: error: invalid operand +#CHECK: nilf %r0, 1 << 32 + + nilf %r0, -1 + nilf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-nilh-01.s b/test/MC/SystemZ/insn-nilh-01.s new file mode 100644 index 00000000000..4bc9353dd28 --- /dev/null +++ b/test/MC/SystemZ/insn-nilh-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: nilh %r0, 0 # encoding: [0xa5,0x06,0x00,0x00] +#CHECK: nilh %r0, 32768 # encoding: [0xa5,0x06,0x80,0x00] +#CHECK: nilh %r0, 65535 # encoding: [0xa5,0x06,0xff,0xff] +#CHECK: nilh %r15, 0 # encoding: [0xa5,0xf6,0x00,0x00] + + nilh %r0, 0 + nilh %r0, 0x8000 + nilh %r0, 0xffff + nilh %r15, 0 diff --git a/test/MC/SystemZ/insn-nilh-02.s b/test/MC/SystemZ/insn-nilh-02.s new file mode 100644 index 00000000000..ae5a852a6c6 --- /dev/null +++ b/test/MC/SystemZ/insn-nilh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: nilh %r0, -1 +#CHECK: error: invalid operand +#CHECK: nilh %r0, 0x10000 + + nilh %r0, -1 + nilh %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-nill-01.s b/test/MC/SystemZ/insn-nill-01.s new file mode 100644 index 00000000000..5f4f87785bf --- /dev/null +++ b/test/MC/SystemZ/insn-nill-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: nill %r0, 0 # encoding: [0xa5,0x07,0x00,0x00] +#CHECK: nill %r0, 32768 # encoding: [0xa5,0x07,0x80,0x00] +#CHECK: nill %r0, 65535 # encoding: [0xa5,0x07,0xff,0xff] +#CHECK: nill %r15, 0 # encoding: [0xa5,0xf7,0x00,0x00] + + nill %r0, 0 + nill %r0, 0x8000 + nill %r0, 0xffff + nill %r15, 0 diff --git a/test/MC/SystemZ/insn-nill-02.s b/test/MC/SystemZ/insn-nill-02.s new file mode 100644 index 00000000000..27fbc4a5065 --- /dev/null +++ b/test/MC/SystemZ/insn-nill-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: nill %r0, -1 +#CHECK: error: invalid operand +#CHECK: nill %r0, 0x10000 + + nill %r0, -1 + nill %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-niy-01.s b/test/MC/SystemZ/insn-niy-01.s new file mode 100644 index 00000000000..4c007e91729 --- /dev/null +++ b/test/MC/SystemZ/insn-niy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: niy -524288, 0 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x54] +#CHECK: niy -1, 0 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x54] +#CHECK: niy 0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x54] +#CHECK: niy 1, 0 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x54] +#CHECK: niy 524287, 0 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x54] +#CHECK: niy 0, 255 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x54] +#CHECK: niy 0(%r1), 42 # encoding: [0xeb,0x2a,0x10,0x00,0x00,0x54] +#CHECK: niy 0(%r15), 42 # encoding: [0xeb,0x2a,0xf0,0x00,0x00,0x54] +#CHECK: niy 524287(%r1), 42 # encoding: [0xeb,0x2a,0x1f,0xff,0x7f,0x54] +#CHECK: niy 524287(%r15), 42 # encoding: [0xeb,0x2a,0xff,0xff,0x7f,0x54] + + niy -524288, 0 + niy -1, 0 + niy 0, 0 + niy 1, 0 + niy 524287, 0 + niy 0, 255 + niy 0(%r1), 42 + niy 0(%r15), 42 + niy 524287(%r1), 42 + niy 524287(%r15), 42 diff --git a/test/MC/SystemZ/insn-niy-02.s b/test/MC/SystemZ/insn-niy-02.s new file mode 100644 index 00000000000..ca398e6fca8 --- /dev/null +++ b/test/MC/SystemZ/insn-niy-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: niy -524289, 0 +#CHECK: error: invalid operand +#CHECK: niy 524288, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: niy 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: niy 0, -1 +#CHECK: error: invalid operand +#CHECK: niy 0, 256 + + niy -524289, 0 + niy 524288, 0 + niy 0(%r1,%r2), 0 + niy 0, -1 + niy 0, 256 diff --git a/test/MC/SystemZ/insn-nr-01.s b/test/MC/SystemZ/insn-nr-01.s new file mode 100644 index 00000000000..c10216d68f4 --- /dev/null +++ b/test/MC/SystemZ/insn-nr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: nr %r0, %r0 # encoding: [0x14,0x00] +#CHECK: nr %r0, %r15 # encoding: [0x14,0x0f] +#CHECK: nr %r15, %r0 # encoding: [0x14,0xf0] +#CHECK: nr %r7, %r8 # encoding: [0x14,0x78] + + nr %r0,%r0 + nr %r0,%r15 + nr %r15,%r0 + nr %r7,%r8 diff --git a/test/MC/SystemZ/insn-ny-01.s b/test/MC/SystemZ/insn-ny-01.s new file mode 100644 index 00000000000..a12bb67e2b0 --- /dev/null +++ b/test/MC/SystemZ/insn-ny-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ny %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x54] +#CHECK: ny %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x54] +#CHECK: ny %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x54] +#CHECK: ny %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x54] +#CHECK: ny %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x54] +#CHECK: ny %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x54] +#CHECK: ny %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x54] +#CHECK: ny %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x54] +#CHECK: ny %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x54] +#CHECK: ny %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x54] + + ny %r0, -524288 + ny %r0, -1 + ny %r0, 0 + ny %r0, 1 + ny %r0, 524287 + ny %r0, 0(%r1) + ny %r0, 0(%r15) + ny %r0, 524287(%r1,%r15) + ny %r0, 524287(%r15,%r1) + ny %r15, 0 diff --git a/test/MC/SystemZ/insn-ny-02.s b/test/MC/SystemZ/insn-ny-02.s new file mode 100644 index 00000000000..5f53ebd3e11 --- /dev/null +++ b/test/MC/SystemZ/insn-ny-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ny %r0, -524289 +#CHECK: error: invalid operand +#CHECK: ny %r0, 524288 + + ny %r0, -524289 + ny %r0, 524288 diff --git a/test/MC/SystemZ/insn-o-01.s b/test/MC/SystemZ/insn-o-01.s new file mode 100644 index 00000000000..0c74e9ccc6d --- /dev/null +++ b/test/MC/SystemZ/insn-o-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: o %r0, 0 # encoding: [0x56,0x00,0x00,0x00] +#CHECK: o %r0, 4095 # encoding: [0x56,0x00,0x0f,0xff] +#CHECK: o %r0, 0(%r1) # encoding: [0x56,0x00,0x10,0x00] +#CHECK: o %r0, 0(%r15) # encoding: [0x56,0x00,0xf0,0x00] +#CHECK: o %r0, 4095(%r1,%r15) # encoding: [0x56,0x01,0xff,0xff] +#CHECK: o %r0, 4095(%r15,%r1) # encoding: [0x56,0x0f,0x1f,0xff] +#CHECK: o %r15, 0 # encoding: [0x56,0xf0,0x00,0x00] + + o %r0, 0 + o %r0, 4095 + o %r0, 0(%r1) + o %r0, 0(%r15) + o %r0, 4095(%r1,%r15) + o %r0, 4095(%r15,%r1) + o %r15, 0 diff --git a/test/MC/SystemZ/insn-o-02.s b/test/MC/SystemZ/insn-o-02.s new file mode 100644 index 00000000000..34b741803b4 --- /dev/null +++ b/test/MC/SystemZ/insn-o-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: o %r0, -1 +#CHECK: error: invalid operand +#CHECK: o %r0, 4096 + + o %r0, -1 + o %r0, 4096 diff --git a/test/MC/SystemZ/insn-og-01.s b/test/MC/SystemZ/insn-og-01.s new file mode 100644 index 00000000000..3c9811b008a --- /dev/null +++ b/test/MC/SystemZ/insn-og-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: og %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x81] +#CHECK: og %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x81] +#CHECK: og %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x81] +#CHECK: og %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x81] +#CHECK: og %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x81] +#CHECK: og %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x81] +#CHECK: og %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x81] +#CHECK: og %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x81] +#CHECK: og %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x81] +#CHECK: og %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x81] + + og %r0, -524288 + og %r0, -1 + og %r0, 0 + og %r0, 1 + og %r0, 524287 + og %r0, 0(%r1) + og %r0, 0(%r15) + og %r0, 524287(%r1,%r15) + og %r0, 524287(%r15,%r1) + og %r15, 0 diff --git a/test/MC/SystemZ/insn-og-02.s b/test/MC/SystemZ/insn-og-02.s new file mode 100644 index 00000000000..7f4e45328be --- /dev/null +++ b/test/MC/SystemZ/insn-og-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: og %r0, -524289 +#CHECK: error: invalid operand +#CHECK: og %r0, 524288 + + og %r0, -524289 + og %r0, 524288 diff --git a/test/MC/SystemZ/insn-ogr-01.s b/test/MC/SystemZ/insn-ogr-01.s new file mode 100644 index 00000000000..25ba913ac55 --- /dev/null +++ b/test/MC/SystemZ/insn-ogr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ogr %r0, %r0 # encoding: [0xb9,0x81,0x00,0x00] +#CHECK: ogr %r0, %r15 # encoding: [0xb9,0x81,0x00,0x0f] +#CHECK: ogr %r15, %r0 # encoding: [0xb9,0x81,0x00,0xf0] +#CHECK: ogr %r7, %r8 # encoding: [0xb9,0x81,0x00,0x78] + + ogr %r0,%r0 + ogr %r0,%r15 + ogr %r15,%r0 + ogr %r7,%r8 diff --git a/test/MC/SystemZ/insn-oi-01.s b/test/MC/SystemZ/insn-oi-01.s new file mode 100644 index 00000000000..5d52fd2500b --- /dev/null +++ b/test/MC/SystemZ/insn-oi-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oi 0, 0 # encoding: [0x96,0x00,0x00,0x00] +#CHECK: oi 4095, 0 # encoding: [0x96,0x00,0x0f,0xff] +#CHECK: oi 0, 255 # encoding: [0x96,0xff,0x00,0x00] +#CHECK: oi 0(%r1), 42 # encoding: [0x96,0x2a,0x10,0x00] +#CHECK: oi 0(%r15), 42 # encoding: [0x96,0x2a,0xf0,0x00] +#CHECK: oi 4095(%r1), 42 # encoding: [0x96,0x2a,0x1f,0xff] +#CHECK: oi 4095(%r15), 42 # encoding: [0x96,0x2a,0xff,0xff] + + oi 0, 0 + oi 4095, 0 + oi 0, 255 + oi 0(%r1), 42 + oi 0(%r15), 42 + oi 4095(%r1), 42 + oi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-oi-02.s b/test/MC/SystemZ/insn-oi-02.s new file mode 100644 index 00000000000..330a290aa36 --- /dev/null +++ b/test/MC/SystemZ/insn-oi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oi -1, 0 +#CHECK: error: invalid operand +#CHECK: oi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: oi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: oi 0, -1 +#CHECK: error: invalid operand +#CHECK: oi 0, 256 + + oi -1, 0 + oi 4096, 0 + oi 0(%r1,%r2), 0 + oi 0, -1 + oi 0, 256 diff --git a/test/MC/SystemZ/insn-oihf-01.s b/test/MC/SystemZ/insn-oihf-01.s new file mode 100644 index 00000000000..627820d31dc --- /dev/null +++ b/test/MC/SystemZ/insn-oihf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oihf %r0, 0 # encoding: [0xc0,0x0c,0x00,0x00,0x00,0x00] +#CHECK: oihf %r0, 4294967295 # encoding: [0xc0,0x0c,0xff,0xff,0xff,0xff] +#CHECK: oihf %r15, 0 # encoding: [0xc0,0xfc,0x00,0x00,0x00,0x00] + + oihf %r0, 0 + oihf %r0, 0xffffffff + oihf %r15, 0 diff --git a/test/MC/SystemZ/insn-oihf-02.s b/test/MC/SystemZ/insn-oihf-02.s new file mode 100644 index 00000000000..a944cb013cd --- /dev/null +++ b/test/MC/SystemZ/insn-oihf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oihf %r0, -1 +#CHECK: error: invalid operand +#CHECK: oihf %r0, 1 << 32 + + oihf %r0, -1 + oihf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-oihh-01.s b/test/MC/SystemZ/insn-oihh-01.s new file mode 100644 index 00000000000..f62f61f03f8 --- /dev/null +++ b/test/MC/SystemZ/insn-oihh-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oihh %r0, 0 # encoding: [0xa5,0x08,0x00,0x00] +#CHECK: oihh %r0, 32768 # encoding: [0xa5,0x08,0x80,0x00] +#CHECK: oihh %r0, 65535 # encoding: [0xa5,0x08,0xff,0xff] +#CHECK: oihh %r15, 0 # encoding: [0xa5,0xf8,0x00,0x00] + + oihh %r0, 0 + oihh %r0, 0x8000 + oihh %r0, 0xffff + oihh %r15, 0 diff --git a/test/MC/SystemZ/insn-oihh-02.s b/test/MC/SystemZ/insn-oihh-02.s new file mode 100644 index 00000000000..6bf7e237e03 --- /dev/null +++ b/test/MC/SystemZ/insn-oihh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oihh %r0, -1 +#CHECK: error: invalid operand +#CHECK: oihh %r0, 0x10000 + + oihh %r0, -1 + oihh %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-oihl-01.s b/test/MC/SystemZ/insn-oihl-01.s new file mode 100644 index 00000000000..437b15c39c1 --- /dev/null +++ b/test/MC/SystemZ/insn-oihl-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oihl %r0, 0 # encoding: [0xa5,0x09,0x00,0x00] +#CHECK: oihl %r0, 32768 # encoding: [0xa5,0x09,0x80,0x00] +#CHECK: oihl %r0, 65535 # encoding: [0xa5,0x09,0xff,0xff] +#CHECK: oihl %r15, 0 # encoding: [0xa5,0xf9,0x00,0x00] + + oihl %r0, 0 + oihl %r0, 0x8000 + oihl %r0, 0xffff + oihl %r15, 0 diff --git a/test/MC/SystemZ/insn-oihl-02.s b/test/MC/SystemZ/insn-oihl-02.s new file mode 100644 index 00000000000..f4f7a59b774 --- /dev/null +++ b/test/MC/SystemZ/insn-oihl-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oihl %r0, -1 +#CHECK: error: invalid operand +#CHECK: oihl %r0, 0x10000 + + oihl %r0, -1 + oihl %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-oilf-01.s b/test/MC/SystemZ/insn-oilf-01.s new file mode 100644 index 00000000000..6f0c0717bd0 --- /dev/null +++ b/test/MC/SystemZ/insn-oilf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oilf %r0, 0 # encoding: [0xc0,0x0d,0x00,0x00,0x00,0x00] +#CHECK: oilf %r0, 4294967295 # encoding: [0xc0,0x0d,0xff,0xff,0xff,0xff] +#CHECK: oilf %r15, 0 # encoding: [0xc0,0xfd,0x00,0x00,0x00,0x00] + + oilf %r0, 0 + oilf %r0, 0xffffffff + oilf %r15, 0 diff --git a/test/MC/SystemZ/insn-oilf-02.s b/test/MC/SystemZ/insn-oilf-02.s new file mode 100644 index 00000000000..5501724d54c --- /dev/null +++ b/test/MC/SystemZ/insn-oilf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oilf %r0, -1 +#CHECK: error: invalid operand +#CHECK: oilf %r0, 1 << 32 + + oilf %r0, -1 + oilf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-oilh-01.s b/test/MC/SystemZ/insn-oilh-01.s new file mode 100644 index 00000000000..0140500e340 --- /dev/null +++ b/test/MC/SystemZ/insn-oilh-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oilh %r0, 0 # encoding: [0xa5,0x0a,0x00,0x00] +#CHECK: oilh %r0, 32768 # encoding: [0xa5,0x0a,0x80,0x00] +#CHECK: oilh %r0, 65535 # encoding: [0xa5,0x0a,0xff,0xff] +#CHECK: oilh %r15, 0 # encoding: [0xa5,0xfa,0x00,0x00] + + oilh %r0, 0 + oilh %r0, 0x8000 + oilh %r0, 0xffff + oilh %r15, 0 diff --git a/test/MC/SystemZ/insn-oilh-02.s b/test/MC/SystemZ/insn-oilh-02.s new file mode 100644 index 00000000000..d2f180d6abd --- /dev/null +++ b/test/MC/SystemZ/insn-oilh-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oilh %r0, -1 +#CHECK: error: invalid operand +#CHECK: oilh %r0, 0x10000 + + oilh %r0, -1 + oilh %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-oill-01.s b/test/MC/SystemZ/insn-oill-01.s new file mode 100644 index 00000000000..ef95d2d90f5 --- /dev/null +++ b/test/MC/SystemZ/insn-oill-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oill %r0, 0 # encoding: [0xa5,0x0b,0x00,0x00] +#CHECK: oill %r0, 32768 # encoding: [0xa5,0x0b,0x80,0x00] +#CHECK: oill %r0, 65535 # encoding: [0xa5,0x0b,0xff,0xff] +#CHECK: oill %r15, 0 # encoding: [0xa5,0xfb,0x00,0x00] + + oill %r0, 0 + oill %r0, 0x8000 + oill %r0, 0xffff + oill %r15, 0 diff --git a/test/MC/SystemZ/insn-oill-02.s b/test/MC/SystemZ/insn-oill-02.s new file mode 100644 index 00000000000..01321db3093 --- /dev/null +++ b/test/MC/SystemZ/insn-oill-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oill %r0, -1 +#CHECK: error: invalid operand +#CHECK: oill %r0, 0x10000 + + oill %r0, -1 + oill %r0, 0x10000 diff --git a/test/MC/SystemZ/insn-oiy-01.s b/test/MC/SystemZ/insn-oiy-01.s new file mode 100644 index 00000000000..ba060cad1ef --- /dev/null +++ b/test/MC/SystemZ/insn-oiy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oiy -524288, 0 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x56] +#CHECK: oiy -1, 0 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x56] +#CHECK: oiy 0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x56] +#CHECK: oiy 1, 0 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x56] +#CHECK: oiy 524287, 0 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x56] +#CHECK: oiy 0, 255 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x56] +#CHECK: oiy 0(%r1), 42 # encoding: [0xeb,0x2a,0x10,0x00,0x00,0x56] +#CHECK: oiy 0(%r15), 42 # encoding: [0xeb,0x2a,0xf0,0x00,0x00,0x56] +#CHECK: oiy 524287(%r1), 42 # encoding: [0xeb,0x2a,0x1f,0xff,0x7f,0x56] +#CHECK: oiy 524287(%r15), 42 # encoding: [0xeb,0x2a,0xff,0xff,0x7f,0x56] + + oiy -524288, 0 + oiy -1, 0 + oiy 0, 0 + oiy 1, 0 + oiy 524287, 0 + oiy 0, 255 + oiy 0(%r1), 42 + oiy 0(%r15), 42 + oiy 524287(%r1), 42 + oiy 524287(%r15), 42 diff --git a/test/MC/SystemZ/insn-oiy-02.s b/test/MC/SystemZ/insn-oiy-02.s new file mode 100644 index 00000000000..c1c556931da --- /dev/null +++ b/test/MC/SystemZ/insn-oiy-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oiy -524289, 0 +#CHECK: error: invalid operand +#CHECK: oiy 524288, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: oiy 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: oiy 0, -1 +#CHECK: error: invalid operand +#CHECK: oiy 0, 256 + + oiy -524289, 0 + oiy 524288, 0 + oiy 0(%r1,%r2), 0 + oiy 0, -1 + oiy 0, 256 diff --git a/test/MC/SystemZ/insn-or-01.s b/test/MC/SystemZ/insn-or-01.s new file mode 100644 index 00000000000..8ac366d32ac --- /dev/null +++ b/test/MC/SystemZ/insn-or-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: or %r0, %r0 # encoding: [0x16,0x00] +#CHECK: or %r0, %r15 # encoding: [0x16,0x0f] +#CHECK: or %r15, %r0 # encoding: [0x16,0xf0] +#CHECK: or %r7, %r8 # encoding: [0x16,0x78] + + or %r0,%r0 + or %r0,%r15 + or %r15,%r0 + or %r7,%r8 diff --git a/test/MC/SystemZ/insn-oy-01.s b/test/MC/SystemZ/insn-oy-01.s new file mode 100644 index 00000000000..58013d0cabb --- /dev/null +++ b/test/MC/SystemZ/insn-oy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: oy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x56] +#CHECK: oy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x56] +#CHECK: oy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x56] +#CHECK: oy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x56] +#CHECK: oy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x56] +#CHECK: oy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x56] +#CHECK: oy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x56] +#CHECK: oy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x56] +#CHECK: oy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x56] +#CHECK: oy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x56] + + oy %r0, -524288 + oy %r0, -1 + oy %r0, 0 + oy %r0, 1 + oy %r0, 524287 + oy %r0, 0(%r1) + oy %r0, 0(%r15) + oy %r0, 524287(%r1,%r15) + oy %r0, 524287(%r15,%r1) + oy %r15, 0 diff --git a/test/MC/SystemZ/insn-oy-02.s b/test/MC/SystemZ/insn-oy-02.s new file mode 100644 index 00000000000..a9ae5b23954 --- /dev/null +++ b/test/MC/SystemZ/insn-oy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: oy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: oy %r0, 524288 + + oy %r0, -524289 + oy %r0, 524288 diff --git a/test/MC/SystemZ/insn-risbg-01.s b/test/MC/SystemZ/insn-risbg-01.s new file mode 100644 index 00000000000..b50fbe7f96b --- /dev/null +++ b/test/MC/SystemZ/insn-risbg-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: risbg %r0, %r0, 0, 0, 0 # encoding: [0xec,0x00,0x00,0x00,0x00,0x55] +#CHECK: risbg %r0, %r0, 0, 0, 63 # encoding: [0xec,0x00,0x00,0x00,0x3f,0x55] +#CHECK: risbg %r0, %r0, 0, 63, 0 # encoding: [0xec,0x00,0x00,0x3f,0x00,0x55] +#CHECK: risbg %r0, %r0, 63, 0, 0 # encoding: [0xec,0x00,0x3f,0x00,0x00,0x55] +#CHECK: risbg %r0, %r15, 0, 0, 0 # encoding: [0xec,0x0f,0x00,0x00,0x00,0x55] +#CHECK: risbg %r15, %r0, 0, 0, 0 # encoding: [0xec,0xf0,0x00,0x00,0x00,0x55] +#CHECK: risbg %r4, %r5, 6, 7, 8 # encoding: [0xec,0x45,0x06,0x07,0x08,0x55] + + risbg %r0,%r0,0,0,0 + risbg %r0,%r0,0,0,63 + risbg %r0,%r0,0,63,0 + risbg %r0,%r0,63,0,0 + risbg %r0,%r15,0,0,0 + risbg %r15,%r0,0,0,0 + risbg %r4,%r5,6,7,8 diff --git a/test/MC/SystemZ/insn-risbg-02.s b/test/MC/SystemZ/insn-risbg-02.s new file mode 100644 index 00000000000..781cb563c84 --- /dev/null +++ b/test/MC/SystemZ/insn-risbg-02.s @@ -0,0 +1,22 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: risbg %r0,%r0,0,0,-1 +#CHECK: error: invalid operand +#CHECK: risbg %r0,%r0,0,0,64 +#CHECK: error: invalid operand +#CHECK: risbg %r0,%r0,0,-1,0 +#CHECK: error: invalid operand +#CHECK: risbg %r0,%r0,0,64,0 +#CHECK: error: invalid operand +#CHECK: risbg %r0,%r0,-1,0,0 +#CHECK: error: invalid operand +#CHECK: risbg %r0,%r0,64,0,0 + + risbg %r0,%r0,0,0,-1 + risbg %r0,%r0,0,0,64 + risbg %r0,%r0,0,-1,0 + risbg %r0,%r0,0,64,0 + risbg %r0,%r0,-1,0,0 + risbg %r0,%r0,64,0,0 diff --git a/test/MC/SystemZ/insn-rll-01.s b/test/MC/SystemZ/insn-rll-01.s new file mode 100644 index 00000000000..06e3774786c --- /dev/null +++ b/test/MC/SystemZ/insn-rll-01.s @@ -0,0 +1,27 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: rll %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x1d] +#CHECK: rll %r15, %r1, 0 # encoding: [0xeb,0xf1,0x00,0x00,0x00,0x1d] +#CHECK: rll %r1, %r15, 0 # encoding: [0xeb,0x1f,0x00,0x00,0x00,0x1d] +#CHECK: rll %r15, %r15, 0 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x1d] +#CHECK: rll %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x1d] +#CHECK: rll %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x1d] +#CHECK: rll %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x1d] +#CHECK: rll %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x1d] +#CHECK: rll %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x1d] +#CHECK: rll %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x1d] +#CHECK: rll %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x1d] +#CHECK: rll %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x1d] + + rll %r0,%r0,0 + rll %r15,%r1,0 + rll %r1,%r15,0 + rll %r15,%r15,0 + rll %r0,%r0,-524288 + rll %r0,%r0,-1 + rll %r0,%r0,1 + rll %r0,%r0,524287 + rll %r0,%r0,0(%r1) + rll %r0,%r0,0(%r15) + rll %r0,%r0,524287(%r1) + rll %r0,%r0,524287(%r15) diff --git a/test/MC/SystemZ/insn-rll-02.s b/test/MC/SystemZ/insn-rll-02.s new file mode 100644 index 00000000000..baf160700fc --- /dev/null +++ b/test/MC/SystemZ/insn-rll-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: rll %r0,%r0,-524289 +#CHECK: error: invalid operand +#CHECK: rll %r0,%r0,524288 +#CHECK: error: %r0 used in an address +#CHECK: rll %r0,%r0,0(%r0) +#CHECK: error: invalid use of indexed addressing +#CHECK: rll %r0,%r0,0(%r1,%r2) + + rll %r0,%r0,-524289 + rll %r0,%r0,524288 + rll %r0,%r0,0(%r0) + rll %r0,%r0,0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-rllg-01.s b/test/MC/SystemZ/insn-rllg-01.s new file mode 100644 index 00000000000..c36dc6daf20 --- /dev/null +++ b/test/MC/SystemZ/insn-rllg-01.s @@ -0,0 +1,27 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: rllg %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x1c] +#CHECK: rllg %r15, %r1, 0 # encoding: [0xeb,0xf1,0x00,0x00,0x00,0x1c] +#CHECK: rllg %r1, %r15, 0 # encoding: [0xeb,0x1f,0x00,0x00,0x00,0x1c] +#CHECK: rllg %r15, %r15, 0 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x1c] +#CHECK: rllg %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x1c] +#CHECK: rllg %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x1c] +#CHECK: rllg %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x1c] +#CHECK: rllg %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x1c] +#CHECK: rllg %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x1c] +#CHECK: rllg %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x1c] +#CHECK: rllg %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x1c] +#CHECK: rllg %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x1c] + + rllg %r0,%r0,0 + rllg %r15,%r1,0 + rllg %r1,%r15,0 + rllg %r15,%r15,0 + rllg %r0,%r0,-524288 + rllg %r0,%r0,-1 + rllg %r0,%r0,1 + rllg %r0,%r0,524287 + rllg %r0,%r0,0(%r1) + rllg %r0,%r0,0(%r15) + rllg %r0,%r0,524287(%r1) + rllg %r0,%r0,524287(%r15) diff --git a/test/MC/SystemZ/insn-rllg-02.s b/test/MC/SystemZ/insn-rllg-02.s new file mode 100644 index 00000000000..7f82845aa64 --- /dev/null +++ b/test/MC/SystemZ/insn-rllg-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: rllg %r0,%r0,-524289 +#CHECK: error: invalid operand +#CHECK: rllg %r0,%r0,524288 +#CHECK: error: %r0 used in an address +#CHECK: rllg %r0,%r0,0(%r0) +#CHECK: error: invalid use of indexed addressing +#CHECK: rllg %r0,%r0,0(%r1,%r2) + + rllg %r0,%r0,-524289 + rllg %r0,%r0,524288 + rllg %r0,%r0,0(%r0) + rllg %r0,%r0,0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-s-01.s b/test/MC/SystemZ/insn-s-01.s new file mode 100644 index 00000000000..2effedbc6c8 --- /dev/null +++ b/test/MC/SystemZ/insn-s-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: s %r0, 0 # encoding: [0x5b,0x00,0x00,0x00] +#CHECK: s %r0, 4095 # encoding: [0x5b,0x00,0x0f,0xff] +#CHECK: s %r0, 0(%r1) # encoding: [0x5b,0x00,0x10,0x00] +#CHECK: s %r0, 0(%r15) # encoding: [0x5b,0x00,0xf0,0x00] +#CHECK: s %r0, 4095(%r1,%r15) # encoding: [0x5b,0x01,0xff,0xff] +#CHECK: s %r0, 4095(%r15,%r1) # encoding: [0x5b,0x0f,0x1f,0xff] +#CHECK: s %r15, 0 # encoding: [0x5b,0xf0,0x00,0x00] + + s %r0, 0 + s %r0, 4095 + s %r0, 0(%r1) + s %r0, 0(%r15) + s %r0, 4095(%r1,%r15) + s %r0, 4095(%r15,%r1) + s %r15, 0 diff --git a/test/MC/SystemZ/insn-s-02.s b/test/MC/SystemZ/insn-s-02.s new file mode 100644 index 00000000000..f0b4a137ec7 --- /dev/null +++ b/test/MC/SystemZ/insn-s-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: s %r0, -1 +#CHECK: error: invalid operand +#CHECK: s %r0, 4096 + + s %r0, -1 + s %r0, 4096 diff --git a/test/MC/SystemZ/insn-sdb-01.s b/test/MC/SystemZ/insn-sdb-01.s new file mode 100644 index 00000000000..9267796ece4 --- /dev/null +++ b/test/MC/SystemZ/insn-sdb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sdb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x1b] +#CHECK: sdb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x1b] +#CHECK: sdb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x1b] +#CHECK: sdb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x1b] +#CHECK: sdb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x1b] +#CHECK: sdb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x1b] +#CHECK: sdb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x1b] + + sdb %f0, 0 + sdb %f0, 4095 + sdb %f0, 0(%r1) + sdb %f0, 0(%r15) + sdb %f0, 4095(%r1,%r15) + sdb %f0, 4095(%r15,%r1) + sdb %f15, 0 diff --git a/test/MC/SystemZ/insn-sdb-02.s b/test/MC/SystemZ/insn-sdb-02.s new file mode 100644 index 00000000000..c77284fb9a8 --- /dev/null +++ b/test/MC/SystemZ/insn-sdb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sdb %f0, -1 +#CHECK: error: invalid operand +#CHECK: sdb %f0, 4096 + + sdb %f0, -1 + sdb %f0, 4096 diff --git a/test/MC/SystemZ/insn-sdbr-01.s b/test/MC/SystemZ/insn-sdbr-01.s new file mode 100644 index 00000000000..b07f5f2cd8f --- /dev/null +++ b/test/MC/SystemZ/insn-sdbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sdbr %f0, %f0 # encoding: [0xb3,0x1b,0x00,0x00] +#CHECK: sdbr %f0, %f15 # encoding: [0xb3,0x1b,0x00,0x0f] +#CHECK: sdbr %f7, %f8 # encoding: [0xb3,0x1b,0x00,0x78] +#CHECK: sdbr %f15, %f0 # encoding: [0xb3,0x1b,0x00,0xf0] + + sdbr %f0, %f0 + sdbr %f0, %f15 + sdbr %f7, %f8 + sdbr %f15, %f0 diff --git a/test/MC/SystemZ/insn-seb-01.s b/test/MC/SystemZ/insn-seb-01.s new file mode 100644 index 00000000000..4bf5cfa0627 --- /dev/null +++ b/test/MC/SystemZ/insn-seb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: seb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x0b] +#CHECK: seb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x0b] +#CHECK: seb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x0b] +#CHECK: seb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x0b] +#CHECK: seb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x0b] +#CHECK: seb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x0b] +#CHECK: seb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x0b] + + seb %f0, 0 + seb %f0, 4095 + seb %f0, 0(%r1) + seb %f0, 0(%r15) + seb %f0, 4095(%r1,%r15) + seb %f0, 4095(%r15,%r1) + seb %f15, 0 diff --git a/test/MC/SystemZ/insn-seb-02.s b/test/MC/SystemZ/insn-seb-02.s new file mode 100644 index 00000000000..e185a20fdc2 --- /dev/null +++ b/test/MC/SystemZ/insn-seb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: seb %f0, -1 +#CHECK: error: invalid operand +#CHECK: seb %f0, 4096 + + seb %f0, -1 + seb %f0, 4096 diff --git a/test/MC/SystemZ/insn-sebr-01.s b/test/MC/SystemZ/insn-sebr-01.s new file mode 100644 index 00000000000..467b57cabe0 --- /dev/null +++ b/test/MC/SystemZ/insn-sebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sebr %f0, %f0 # encoding: [0xb3,0x0b,0x00,0x00] +#CHECK: sebr %f0, %f15 # encoding: [0xb3,0x0b,0x00,0x0f] +#CHECK: sebr %f7, %f8 # encoding: [0xb3,0x0b,0x00,0x78] +#CHECK: sebr %f15, %f0 # encoding: [0xb3,0x0b,0x00,0xf0] + + sebr %f0, %f0 + sebr %f0, %f15 + sebr %f7, %f8 + sebr %f15, %f0 diff --git a/test/MC/SystemZ/insn-sg-01.s b/test/MC/SystemZ/insn-sg-01.s new file mode 100644 index 00000000000..153df1ae2d6 --- /dev/null +++ b/test/MC/SystemZ/insn-sg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x09] +#CHECK: sg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x09] +#CHECK: sg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x09] +#CHECK: sg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x09] +#CHECK: sg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x09] +#CHECK: sg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x09] +#CHECK: sg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x09] +#CHECK: sg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x09] +#CHECK: sg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x09] +#CHECK: sg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x09] + + sg %r0, -524288 + sg %r0, -1 + sg %r0, 0 + sg %r0, 1 + sg %r0, 524287 + sg %r0, 0(%r1) + sg %r0, 0(%r15) + sg %r0, 524287(%r1,%r15) + sg %r0, 524287(%r15,%r1) + sg %r15, 0 diff --git a/test/MC/SystemZ/insn-sg-02.s b/test/MC/SystemZ/insn-sg-02.s new file mode 100644 index 00000000000..f183e58f7b7 --- /dev/null +++ b/test/MC/SystemZ/insn-sg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: sg %r0, 524288 + + sg %r0, -524289 + sg %r0, 524288 diff --git a/test/MC/SystemZ/insn-sgf-01.s b/test/MC/SystemZ/insn-sgf-01.s new file mode 100644 index 00000000000..844c09998d3 --- /dev/null +++ b/test/MC/SystemZ/insn-sgf-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sgf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x19] +#CHECK: sgf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x19] +#CHECK: sgf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x19] +#CHECK: sgf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x19] +#CHECK: sgf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x19] +#CHECK: sgf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x19] +#CHECK: sgf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x19] +#CHECK: sgf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x19] +#CHECK: sgf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x19] +#CHECK: sgf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x19] + + sgf %r0, -524288 + sgf %r0, -1 + sgf %r0, 0 + sgf %r0, 1 + sgf %r0, 524287 + sgf %r0, 0(%r1) + sgf %r0, 0(%r15) + sgf %r0, 524287(%r1,%r15) + sgf %r0, 524287(%r15,%r1) + sgf %r15, 0 diff --git a/test/MC/SystemZ/insn-sgf-02.s b/test/MC/SystemZ/insn-sgf-02.s new file mode 100644 index 00000000000..7eba3abe2c3 --- /dev/null +++ b/test/MC/SystemZ/insn-sgf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sgf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: sgf %r0, 524288 + + sgf %r0, -524289 + sgf %r0, 524288 diff --git a/test/MC/SystemZ/insn-sgfr-01.s b/test/MC/SystemZ/insn-sgfr-01.s new file mode 100644 index 00000000000..49a1412f881 --- /dev/null +++ b/test/MC/SystemZ/insn-sgfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sgfr %r0, %r0 # encoding: [0xb9,0x19,0x00,0x00] +#CHECK: sgfr %r0, %r15 # encoding: [0xb9,0x19,0x00,0x0f] +#CHECK: sgfr %r15, %r0 # encoding: [0xb9,0x19,0x00,0xf0] +#CHECK: sgfr %r7, %r8 # encoding: [0xb9,0x19,0x00,0x78] + + sgfr %r0,%r0 + sgfr %r0,%r15 + sgfr %r15,%r0 + sgfr %r7,%r8 diff --git a/test/MC/SystemZ/insn-sgr-01.s b/test/MC/SystemZ/insn-sgr-01.s new file mode 100644 index 00000000000..86c59a14525 --- /dev/null +++ b/test/MC/SystemZ/insn-sgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sgr %r0, %r0 # encoding: [0xb9,0x09,0x00,0x00] +#CHECK: sgr %r0, %r15 # encoding: [0xb9,0x09,0x00,0x0f] +#CHECK: sgr %r15, %r0 # encoding: [0xb9,0x09,0x00,0xf0] +#CHECK: sgr %r7, %r8 # encoding: [0xb9,0x09,0x00,0x78] + + sgr %r0,%r0 + sgr %r0,%r15 + sgr %r15,%r0 + sgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-sl-01.s b/test/MC/SystemZ/insn-sl-01.s new file mode 100644 index 00000000000..c2186da486c --- /dev/null +++ b/test/MC/SystemZ/insn-sl-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sl %r0, 0 # encoding: [0x5f,0x00,0x00,0x00] +#CHECK: sl %r0, 4095 # encoding: [0x5f,0x00,0x0f,0xff] +#CHECK: sl %r0, 0(%r1) # encoding: [0x5f,0x00,0x10,0x00] +#CHECK: sl %r0, 0(%r15) # encoding: [0x5f,0x00,0xf0,0x00] +#CHECK: sl %r0, 4095(%r1,%r15) # encoding: [0x5f,0x01,0xff,0xff] +#CHECK: sl %r0, 4095(%r15,%r1) # encoding: [0x5f,0x0f,0x1f,0xff] +#CHECK: sl %r15, 0 # encoding: [0x5f,0xf0,0x00,0x00] + + sl %r0, 0 + sl %r0, 4095 + sl %r0, 0(%r1) + sl %r0, 0(%r15) + sl %r0, 4095(%r1,%r15) + sl %r0, 4095(%r15,%r1) + sl %r15, 0 diff --git a/test/MC/SystemZ/insn-sl-02.s b/test/MC/SystemZ/insn-sl-02.s new file mode 100644 index 00000000000..8abd99d2351 --- /dev/null +++ b/test/MC/SystemZ/insn-sl-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sl %r0, -1 +#CHECK: error: invalid operand +#CHECK: sl %r0, 4096 + + sl %r0, -1 + sl %r0, 4096 diff --git a/test/MC/SystemZ/insn-slb-01.s b/test/MC/SystemZ/insn-slb-01.s new file mode 100644 index 00000000000..4bc79f6746a --- /dev/null +++ b/test/MC/SystemZ/insn-slb-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slb %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x99] +#CHECK: slb %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x99] +#CHECK: slb %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x99] +#CHECK: slb %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x99] +#CHECK: slb %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x99] +#CHECK: slb %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x99] +#CHECK: slb %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x99] +#CHECK: slb %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x99] +#CHECK: slb %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x99] +#CHECK: slb %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x99] + + slb %r0, -524288 + slb %r0, -1 + slb %r0, 0 + slb %r0, 1 + slb %r0, 524287 + slb %r0, 0(%r1) + slb %r0, 0(%r15) + slb %r0, 524287(%r1,%r15) + slb %r0, 524287(%r15,%r1) + slb %r15, 0 diff --git a/test/MC/SystemZ/insn-slb-02.s b/test/MC/SystemZ/insn-slb-02.s new file mode 100644 index 00000000000..ac87128ffc4 --- /dev/null +++ b/test/MC/SystemZ/insn-slb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: slb %r0, -524289 +#CHECK: error: invalid operand +#CHECK: slb %r0, 524288 + + slb %r0, -524289 + slb %r0, 524288 diff --git a/test/MC/SystemZ/insn-slbg-01.s b/test/MC/SystemZ/insn-slbg-01.s new file mode 100644 index 00000000000..8878aeda5ed --- /dev/null +++ b/test/MC/SystemZ/insn-slbg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slbg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x89] +#CHECK: slbg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x89] +#CHECK: slbg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x89] +#CHECK: slbg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x89] +#CHECK: slbg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x89] +#CHECK: slbg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x89] +#CHECK: slbg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x89] +#CHECK: slbg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x89] +#CHECK: slbg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x89] +#CHECK: slbg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x89] + + slbg %r0, -524288 + slbg %r0, -1 + slbg %r0, 0 + slbg %r0, 1 + slbg %r0, 524287 + slbg %r0, 0(%r1) + slbg %r0, 0(%r15) + slbg %r0, 524287(%r1,%r15) + slbg %r0, 524287(%r15,%r1) + slbg %r15, 0 diff --git a/test/MC/SystemZ/insn-slbg-02.s b/test/MC/SystemZ/insn-slbg-02.s new file mode 100644 index 00000000000..ce09c8a9de5 --- /dev/null +++ b/test/MC/SystemZ/insn-slbg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: slbg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: slbg %r0, 524288 + + slbg %r0, -524289 + slbg %r0, 524288 diff --git a/test/MC/SystemZ/insn-slbgr-01.s b/test/MC/SystemZ/insn-slbgr-01.s new file mode 100644 index 00000000000..bcc2b535ba7 --- /dev/null +++ b/test/MC/SystemZ/insn-slbgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slbgr %r0, %r0 # encoding: [0xb9,0x89,0x00,0x00] +#CHECK: slbgr %r0, %r15 # encoding: [0xb9,0x89,0x00,0x0f] +#CHECK: slbgr %r15, %r0 # encoding: [0xb9,0x89,0x00,0xf0] +#CHECK: slbgr %r7, %r8 # encoding: [0xb9,0x89,0x00,0x78] + + slbgr %r0,%r0 + slbgr %r0,%r15 + slbgr %r15,%r0 + slbgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-slbr-01.s b/test/MC/SystemZ/insn-slbr-01.s new file mode 100644 index 00000000000..9c10dbd0210 --- /dev/null +++ b/test/MC/SystemZ/insn-slbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slbr %r0, %r0 # encoding: [0xb9,0x99,0x00,0x00] +#CHECK: slbr %r0, %r15 # encoding: [0xb9,0x99,0x00,0x0f] +#CHECK: slbr %r15, %r0 # encoding: [0xb9,0x99,0x00,0xf0] +#CHECK: slbr %r7, %r8 # encoding: [0xb9,0x99,0x00,0x78] + + slbr %r0,%r0 + slbr %r0,%r15 + slbr %r15,%r0 + slbr %r7,%r8 diff --git a/test/MC/SystemZ/insn-slfi-01.s b/test/MC/SystemZ/insn-slfi-01.s new file mode 100644 index 00000000000..4c8e5b4a84d --- /dev/null +++ b/test/MC/SystemZ/insn-slfi-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slfi %r0, 0 # encoding: [0xc2,0x05,0x00,0x00,0x00,0x00] +#CHECK: slfi %r0, 4294967295 # encoding: [0xc2,0x05,0xff,0xff,0xff,0xff] +#CHECK: slfi %r15, 0 # encoding: [0xc2,0xf5,0x00,0x00,0x00,0x00] + + slfi %r0, 0 + slfi %r0, (1 << 32) - 1 + slfi %r15, 0 diff --git a/test/MC/SystemZ/insn-slfi-02.s b/test/MC/SystemZ/insn-slfi-02.s new file mode 100644 index 00000000000..12e14f6164b --- /dev/null +++ b/test/MC/SystemZ/insn-slfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: slfi %r0, -1 +#CHECK: error: invalid operand +#CHECK: slfi %r0, (1 << 32) + + slfi %r0, -1 + slfi %r0, (1 << 32) diff --git a/test/MC/SystemZ/insn-slg-01.s b/test/MC/SystemZ/insn-slg-01.s new file mode 100644 index 00000000000..0b4f99e2e13 --- /dev/null +++ b/test/MC/SystemZ/insn-slg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x0b] +#CHECK: slg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x0b] +#CHECK: slg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x0b] +#CHECK: slg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x0b] +#CHECK: slg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x0b] +#CHECK: slg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x0b] +#CHECK: slg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x0b] +#CHECK: slg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x0b] +#CHECK: slg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x0b] +#CHECK: slg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x0b] + + slg %r0, -524288 + slg %r0, -1 + slg %r0, 0 + slg %r0, 1 + slg %r0, 524287 + slg %r0, 0(%r1) + slg %r0, 0(%r15) + slg %r0, 524287(%r1,%r15) + slg %r0, 524287(%r15,%r1) + slg %r15, 0 diff --git a/test/MC/SystemZ/insn-slg-02.s b/test/MC/SystemZ/insn-slg-02.s new file mode 100644 index 00000000000..1ad04c6111d --- /dev/null +++ b/test/MC/SystemZ/insn-slg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: slg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: slg %r0, 524288 + + slg %r0, -524289 + slg %r0, 524288 diff --git a/test/MC/SystemZ/insn-slgf-01.s b/test/MC/SystemZ/insn-slgf-01.s new file mode 100644 index 00000000000..bca480ecd77 --- /dev/null +++ b/test/MC/SystemZ/insn-slgf-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slgf %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x1b] +#CHECK: slgf %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x1b] +#CHECK: slgf %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x1b] +#CHECK: slgf %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x1b] +#CHECK: slgf %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x1b] +#CHECK: slgf %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x1b] +#CHECK: slgf %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x1b] +#CHECK: slgf %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x1b] +#CHECK: slgf %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x1b] +#CHECK: slgf %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x1b] + + slgf %r0, -524288 + slgf %r0, -1 + slgf %r0, 0 + slgf %r0, 1 + slgf %r0, 524287 + slgf %r0, 0(%r1) + slgf %r0, 0(%r15) + slgf %r0, 524287(%r1,%r15) + slgf %r0, 524287(%r15,%r1) + slgf %r15, 0 diff --git a/test/MC/SystemZ/insn-slgf-02.s b/test/MC/SystemZ/insn-slgf-02.s new file mode 100644 index 00000000000..71a9aa7812e --- /dev/null +++ b/test/MC/SystemZ/insn-slgf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: slgf %r0, -524289 +#CHECK: error: invalid operand +#CHECK: slgf %r0, 524288 + + slgf %r0, -524289 + slgf %r0, 524288 diff --git a/test/MC/SystemZ/insn-slgfi-01.s b/test/MC/SystemZ/insn-slgfi-01.s new file mode 100644 index 00000000000..c9fef187f5a --- /dev/null +++ b/test/MC/SystemZ/insn-slgfi-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slgfi %r0, 0 # encoding: [0xc2,0x04,0x00,0x00,0x00,0x00] +#CHECK: slgfi %r0, 4294967295 # encoding: [0xc2,0x04,0xff,0xff,0xff,0xff] +#CHECK: slgfi %r15, 0 # encoding: [0xc2,0xf4,0x00,0x00,0x00,0x00] + + slgfi %r0, 0 + slgfi %r0, (1 << 32) - 1 + slgfi %r15, 0 diff --git a/test/MC/SystemZ/insn-slgfi-02.s b/test/MC/SystemZ/insn-slgfi-02.s new file mode 100644 index 00000000000..696408d377e --- /dev/null +++ b/test/MC/SystemZ/insn-slgfi-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: slgfi %r0, -1 +#CHECK: error: invalid operand +#CHECK: slgfi %r0, (1 << 32) + + slgfi %r0, -1 + slgfi %r0, (1 << 32) diff --git a/test/MC/SystemZ/insn-slgfr-01.s b/test/MC/SystemZ/insn-slgfr-01.s new file mode 100644 index 00000000000..94c10edcd3b --- /dev/null +++ b/test/MC/SystemZ/insn-slgfr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slgfr %r0, %r0 # encoding: [0xb9,0x1b,0x00,0x00] +#CHECK: slgfr %r0, %r15 # encoding: [0xb9,0x1b,0x00,0x0f] +#CHECK: slgfr %r15, %r0 # encoding: [0xb9,0x1b,0x00,0xf0] +#CHECK: slgfr %r7, %r8 # encoding: [0xb9,0x1b,0x00,0x78] + + slgfr %r0,%r0 + slgfr %r0,%r15 + slgfr %r15,%r0 + slgfr %r7,%r8 diff --git a/test/MC/SystemZ/insn-slgr-01.s b/test/MC/SystemZ/insn-slgr-01.s new file mode 100644 index 00000000000..4d226be83e6 --- /dev/null +++ b/test/MC/SystemZ/insn-slgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slgr %r0, %r0 # encoding: [0xb9,0x0b,0x00,0x00] +#CHECK: slgr %r0, %r15 # encoding: [0xb9,0x0b,0x00,0x0f] +#CHECK: slgr %r15, %r0 # encoding: [0xb9,0x0b,0x00,0xf0] +#CHECK: slgr %r7, %r8 # encoding: [0xb9,0x0b,0x00,0x78] + + slgr %r0,%r0 + slgr %r0,%r15 + slgr %r15,%r0 + slgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-sll-01.s b/test/MC/SystemZ/insn-sll-01.s new file mode 100644 index 00000000000..5bc112856d7 --- /dev/null +++ b/test/MC/SystemZ/insn-sll-01.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sll %r0, 0 # encoding: [0x89,0x00,0x00,0x00] +#CHECK: sll %r7, 0 # encoding: [0x89,0x70,0x00,0x00] +#CHECK: sll %r15, 0 # encoding: [0x89,0xf0,0x00,0x00] +#CHECK: sll %r0, 4095 # encoding: [0x89,0x00,0x0f,0xff] +#CHECK: sll %r0, 0(%r1) # encoding: [0x89,0x00,0x10,0x00] +#CHECK: sll %r0, 0(%r15) # encoding: [0x89,0x00,0xf0,0x00] +#CHECK: sll %r0, 4095(%r1) # encoding: [0x89,0x00,0x1f,0xff] +#CHECK: sll %r0, 4095(%r15) # encoding: [0x89,0x00,0xff,0xff] + + sll %r0,0 + sll %r7,0 + sll %r15,0 + sll %r0,4095 + sll %r0,0(%r1) + sll %r0,0(%r15) + sll %r0,4095(%r1) + sll %r0,4095(%r15) diff --git a/test/MC/SystemZ/insn-sll-02.s b/test/MC/SystemZ/insn-sll-02.s new file mode 100644 index 00000000000..1b951be02c2 --- /dev/null +++ b/test/MC/SystemZ/insn-sll-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sll %r0,-1 +#CHECK: error: invalid operand +#CHECK: sll %r0,4096 +#CHECK: error: %r0 used in an address +#CHECK: sll %r0,0(%r0) +#CHECK: error: invalid use of indexed addressing +#CHECK: sll %r0,0(%r1,%r2) + + sll %r0,-1 + sll %r0,4096 + sll %r0,0(%r0) + sll %r0,0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-sllg-01.s b/test/MC/SystemZ/insn-sllg-01.s new file mode 100644 index 00000000000..1b0f0094676 --- /dev/null +++ b/test/MC/SystemZ/insn-sllg-01.s @@ -0,0 +1,27 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sllg %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x0d] +#CHECK: sllg %r15, %r1, 0 # encoding: [0xeb,0xf1,0x00,0x00,0x00,0x0d] +#CHECK: sllg %r1, %r15, 0 # encoding: [0xeb,0x1f,0x00,0x00,0x00,0x0d] +#CHECK: sllg %r15, %r15, 0 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x0d] +#CHECK: sllg %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x0d] +#CHECK: sllg %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x0d] +#CHECK: sllg %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x0d] +#CHECK: sllg %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x0d] +#CHECK: sllg %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x0d] +#CHECK: sllg %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x0d] +#CHECK: sllg %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x0d] +#CHECK: sllg %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x0d] + + sllg %r0,%r0,0 + sllg %r15,%r1,0 + sllg %r1,%r15,0 + sllg %r15,%r15,0 + sllg %r0,%r0,-524288 + sllg %r0,%r0,-1 + sllg %r0,%r0,1 + sllg %r0,%r0,524287 + sllg %r0,%r0,0(%r1) + sllg %r0,%r0,0(%r15) + sllg %r0,%r0,524287(%r1) + sllg %r0,%r0,524287(%r15) diff --git a/test/MC/SystemZ/insn-sllg-02.s b/test/MC/SystemZ/insn-sllg-02.s new file mode 100644 index 00000000000..68c3d1da29f --- /dev/null +++ b/test/MC/SystemZ/insn-sllg-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sllg %r0,%r0,-524289 +#CHECK: error: invalid operand +#CHECK: sllg %r0,%r0,524288 +#CHECK: error: %r0 used in an address +#CHECK: sllg %r0,%r0,0(%r0) +#CHECK: error: invalid use of indexed addressing +#CHECK: sllg %r0,%r0,0(%r1,%r2) + + sllg %r0,%r0,-524289 + sllg %r0,%r0,524288 + sllg %r0,%r0,0(%r0) + sllg %r0,%r0,0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-slr-01.s b/test/MC/SystemZ/insn-slr-01.s new file mode 100644 index 00000000000..c142407cff6 --- /dev/null +++ b/test/MC/SystemZ/insn-slr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: slr %r0, %r0 # encoding: [0x1f,0x00] +#CHECK: slr %r0, %r15 # encoding: [0x1f,0x0f] +#CHECK: slr %r15, %r0 # encoding: [0x1f,0xf0] +#CHECK: slr %r7, %r8 # encoding: [0x1f,0x78] + + slr %r0,%r0 + slr %r0,%r15 + slr %r15,%r0 + slr %r7,%r8 diff --git a/test/MC/SystemZ/insn-sly-01.s b/test/MC/SystemZ/insn-sly-01.s new file mode 100644 index 00000000000..59d2907a4d8 --- /dev/null +++ b/test/MC/SystemZ/insn-sly-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sly %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x5f] +#CHECK: sly %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x5f] +#CHECK: sly %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x5f] +#CHECK: sly %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x5f] +#CHECK: sly %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x5f] +#CHECK: sly %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x5f] +#CHECK: sly %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x5f] +#CHECK: sly %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x5f] +#CHECK: sly %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x5f] +#CHECK: sly %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x5f] + + sly %r0, -524288 + sly %r0, -1 + sly %r0, 0 + sly %r0, 1 + sly %r0, 524287 + sly %r0, 0(%r1) + sly %r0, 0(%r15) + sly %r0, 524287(%r1,%r15) + sly %r0, 524287(%r15,%r1) + sly %r15, 0 diff --git a/test/MC/SystemZ/insn-sly-02.s b/test/MC/SystemZ/insn-sly-02.s new file mode 100644 index 00000000000..9abd53e1ab1 --- /dev/null +++ b/test/MC/SystemZ/insn-sly-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sly %r0, -524289 +#CHECK: error: invalid operand +#CHECK: sly %r0, 524288 + + sly %r0, -524289 + sly %r0, 524288 diff --git a/test/MC/SystemZ/insn-sqdb-01.s b/test/MC/SystemZ/insn-sqdb-01.s new file mode 100644 index 00000000000..b79aae14442 --- /dev/null +++ b/test/MC/SystemZ/insn-sqdb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sqdb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x15] +#CHECK: sqdb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x15] +#CHECK: sqdb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x15] +#CHECK: sqdb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x15] +#CHECK: sqdb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x15] +#CHECK: sqdb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x15] +#CHECK: sqdb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x15] + + sqdb %f0, 0 + sqdb %f0, 4095 + sqdb %f0, 0(%r1) + sqdb %f0, 0(%r15) + sqdb %f0, 4095(%r1,%r15) + sqdb %f0, 4095(%r15,%r1) + sqdb %f15, 0 diff --git a/test/MC/SystemZ/insn-sqdb-02.s b/test/MC/SystemZ/insn-sqdb-02.s new file mode 100644 index 00000000000..68df2677704 --- /dev/null +++ b/test/MC/SystemZ/insn-sqdb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sqdb %f0, -1 +#CHECK: error: invalid operand +#CHECK: sqdb %f0, 4096 + + sqdb %f0, -1 + sqdb %f0, 4096 diff --git a/test/MC/SystemZ/insn-sqdbr-01.s b/test/MC/SystemZ/insn-sqdbr-01.s new file mode 100644 index 00000000000..d66415fa052 --- /dev/null +++ b/test/MC/SystemZ/insn-sqdbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sqdbr %f0, %f0 # encoding: [0xb3,0x15,0x00,0x00] +#CHECK: sqdbr %f0, %f15 # encoding: [0xb3,0x15,0x00,0x0f] +#CHECK: sqdbr %f7, %f8 # encoding: [0xb3,0x15,0x00,0x78] +#CHECK: sqdbr %f15, %f0 # encoding: [0xb3,0x15,0x00,0xf0] + + sqdbr %f0, %f0 + sqdbr %f0, %f15 + sqdbr %f7, %f8 + sqdbr %f15, %f0 diff --git a/test/MC/SystemZ/insn-sqeb-01.s b/test/MC/SystemZ/insn-sqeb-01.s new file mode 100644 index 00000000000..60f6e906357 --- /dev/null +++ b/test/MC/SystemZ/insn-sqeb-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sqeb %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x14] +#CHECK: sqeb %f0, 4095 # encoding: [0xed,0x00,0x0f,0xff,0x00,0x14] +#CHECK: sqeb %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x14] +#CHECK: sqeb %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x14] +#CHECK: sqeb %f0, 4095(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x00,0x14] +#CHECK: sqeb %f0, 4095(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x00,0x14] +#CHECK: sqeb %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x14] + + sqeb %f0, 0 + sqeb %f0, 4095 + sqeb %f0, 0(%r1) + sqeb %f0, 0(%r15) + sqeb %f0, 4095(%r1,%r15) + sqeb %f0, 4095(%r15,%r1) + sqeb %f15, 0 diff --git a/test/MC/SystemZ/insn-sqeb-02.s b/test/MC/SystemZ/insn-sqeb-02.s new file mode 100644 index 00000000000..efb09fcfbc7 --- /dev/null +++ b/test/MC/SystemZ/insn-sqeb-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sqeb %f0, -1 +#CHECK: error: invalid operand +#CHECK: sqeb %f0, 4096 + + sqeb %f0, -1 + sqeb %f0, 4096 diff --git a/test/MC/SystemZ/insn-sqebr-01.s b/test/MC/SystemZ/insn-sqebr-01.s new file mode 100644 index 00000000000..2d13dbeb265 --- /dev/null +++ b/test/MC/SystemZ/insn-sqebr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sqebr %f0, %f0 # encoding: [0xb3,0x14,0x00,0x00] +#CHECK: sqebr %f0, %f15 # encoding: [0xb3,0x14,0x00,0x0f] +#CHECK: sqebr %f7, %f8 # encoding: [0xb3,0x14,0x00,0x78] +#CHECK: sqebr %f15, %f0 # encoding: [0xb3,0x14,0x00,0xf0] + + sqebr %f0, %f0 + sqebr %f0, %f15 + sqebr %f7, %f8 + sqebr %f15, %f0 diff --git a/test/MC/SystemZ/insn-sqxbr-01.s b/test/MC/SystemZ/insn-sqxbr-01.s new file mode 100644 index 00000000000..78ba908d5af --- /dev/null +++ b/test/MC/SystemZ/insn-sqxbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sqxbr %f0, %f0 # encoding: [0xb3,0x16,0x00,0x00] +#CHECK: sqxbr %f0, %f13 # encoding: [0xb3,0x16,0x00,0x0d] +#CHECK: sqxbr %f8, %f8 # encoding: [0xb3,0x16,0x00,0x88] +#CHECK: sqxbr %f13, %f0 # encoding: [0xb3,0x16,0x00,0xd0] + + sqxbr %f0, %f0 + sqxbr %f0, %f13 + sqxbr %f8, %f8 + sqxbr %f13, %f0 diff --git a/test/MC/SystemZ/insn-sqxbr-02.s b/test/MC/SystemZ/insn-sqxbr-02.s new file mode 100644 index 00000000000..e51e552fb70 --- /dev/null +++ b/test/MC/SystemZ/insn-sqxbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: sqxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: sqxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: sqxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: sqxbr %f14, %f0 + + sqxbr %f0, %f2 + sqxbr %f0, %f14 + sqxbr %f2, %f0 + sqxbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-sr-01.s b/test/MC/SystemZ/insn-sr-01.s new file mode 100644 index 00000000000..856bef5eac9 --- /dev/null +++ b/test/MC/SystemZ/insn-sr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sr %r0, %r0 # encoding: [0x1b,0x00] +#CHECK: sr %r0, %r15 # encoding: [0x1b,0x0f] +#CHECK: sr %r15, %r0 # encoding: [0x1b,0xf0] +#CHECK: sr %r7, %r8 # encoding: [0x1b,0x78] + + sr %r0,%r0 + sr %r0,%r15 + sr %r15,%r0 + sr %r7,%r8 diff --git a/test/MC/SystemZ/insn-sra-01.s b/test/MC/SystemZ/insn-sra-01.s new file mode 100644 index 00000000000..fcdaf5de162 --- /dev/null +++ b/test/MC/SystemZ/insn-sra-01.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sra %r0, 0 # encoding: [0x8a,0x00,0x00,0x00] +#CHECK: sra %r7, 0 # encoding: [0x8a,0x70,0x00,0x00] +#CHECK: sra %r15, 0 # encoding: [0x8a,0xf0,0x00,0x00] +#CHECK: sra %r0, 4095 # encoding: [0x8a,0x00,0x0f,0xff] +#CHECK: sra %r0, 0(%r1) # encoding: [0x8a,0x00,0x10,0x00] +#CHECK: sra %r0, 0(%r15) # encoding: [0x8a,0x00,0xf0,0x00] +#CHECK: sra %r0, 4095(%r1) # encoding: [0x8a,0x00,0x1f,0xff] +#CHECK: sra %r0, 4095(%r15) # encoding: [0x8a,0x00,0xff,0xff] + + sra %r0,0 + sra %r7,0 + sra %r15,0 + sra %r0,4095 + sra %r0,0(%r1) + sra %r0,0(%r15) + sra %r0,4095(%r1) + sra %r0,4095(%r15) diff --git a/test/MC/SystemZ/insn-sra-02.s b/test/MC/SystemZ/insn-sra-02.s new file mode 100644 index 00000000000..7a84f177433 --- /dev/null +++ b/test/MC/SystemZ/insn-sra-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sra %r0,-1 +#CHECK: error: invalid operand +#CHECK: sra %r0,4096 +#CHECK: error: %r0 used in an address +#CHECK: sra %r0,0(%r0) +#CHECK: error: invalid use of indexed addressing +#CHECK: sra %r0,0(%r1,%r2) + + sra %r0,-1 + sra %r0,4096 + sra %r0,0(%r0) + sra %r0,0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-srag-01.s b/test/MC/SystemZ/insn-srag-01.s new file mode 100644 index 00000000000..9271db237d9 --- /dev/null +++ b/test/MC/SystemZ/insn-srag-01.s @@ -0,0 +1,27 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: srag %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x0a] +#CHECK: srag %r15, %r1, 0 # encoding: [0xeb,0xf1,0x00,0x00,0x00,0x0a] +#CHECK: srag %r1, %r15, 0 # encoding: [0xeb,0x1f,0x00,0x00,0x00,0x0a] +#CHECK: srag %r15, %r15, 0 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x0a] +#CHECK: srag %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x0a] +#CHECK: srag %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x0a] +#CHECK: srag %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x0a] +#CHECK: srag %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x0a] +#CHECK: srag %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x0a] +#CHECK: srag %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x0a] +#CHECK: srag %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x0a] +#CHECK: srag %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x0a] + + srag %r0,%r0,0 + srag %r15,%r1,0 + srag %r1,%r15,0 + srag %r15,%r15,0 + srag %r0,%r0,-524288 + srag %r0,%r0,-1 + srag %r0,%r0,1 + srag %r0,%r0,524287 + srag %r0,%r0,0(%r1) + srag %r0,%r0,0(%r15) + srag %r0,%r0,524287(%r1) + srag %r0,%r0,524287(%r15) diff --git a/test/MC/SystemZ/insn-srag-02.s b/test/MC/SystemZ/insn-srag-02.s new file mode 100644 index 00000000000..7413cbaf9fc --- /dev/null +++ b/test/MC/SystemZ/insn-srag-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: srag %r0,%r0,-524289 +#CHECK: error: invalid operand +#CHECK: srag %r0,%r0,524288 +#CHECK: error: %r0 used in an address +#CHECK: srag %r0,%r0,0(%r0) +#CHECK: error: invalid use of indexed addressing +#CHECK: srag %r0,%r0,0(%r1,%r2) + + srag %r0,%r0,-524289 + srag %r0,%r0,524288 + srag %r0,%r0,0(%r0) + srag %r0,%r0,0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-srl-01.s b/test/MC/SystemZ/insn-srl-01.s new file mode 100644 index 00000000000..a3a5df8a2bc --- /dev/null +++ b/test/MC/SystemZ/insn-srl-01.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: srl %r0, 0 # encoding: [0x88,0x00,0x00,0x00] +#CHECK: srl %r7, 0 # encoding: [0x88,0x70,0x00,0x00] +#CHECK: srl %r15, 0 # encoding: [0x88,0xf0,0x00,0x00] +#CHECK: srl %r0, 4095 # encoding: [0x88,0x00,0x0f,0xff] +#CHECK: srl %r0, 0(%r1) # encoding: [0x88,0x00,0x10,0x00] +#CHECK: srl %r0, 0(%r15) # encoding: [0x88,0x00,0xf0,0x00] +#CHECK: srl %r0, 4095(%r1) # encoding: [0x88,0x00,0x1f,0xff] +#CHECK: srl %r0, 4095(%r15) # encoding: [0x88,0x00,0xff,0xff] + + srl %r0,0 + srl %r7,0 + srl %r15,0 + srl %r0,4095 + srl %r0,0(%r1) + srl %r0,0(%r15) + srl %r0,4095(%r1) + srl %r0,4095(%r15) diff --git a/test/MC/SystemZ/insn-srl-02.s b/test/MC/SystemZ/insn-srl-02.s new file mode 100644 index 00000000000..212d16bd8d5 --- /dev/null +++ b/test/MC/SystemZ/insn-srl-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: srl %r0,-1 +#CHECK: error: invalid operand +#CHECK: srl %r0,4096 +#CHECK: error: %r0 used in an address +#CHECK: srl %r0,0(%r0) +#CHECK: error: invalid use of indexed addressing +#CHECK: srl %r0,0(%r1,%r2) + + srl %r0,-1 + srl %r0,4096 + srl %r0,0(%r0) + srl %r0,0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-srlg-01.s b/test/MC/SystemZ/insn-srlg-01.s new file mode 100644 index 00000000000..0087fefd928 --- /dev/null +++ b/test/MC/SystemZ/insn-srlg-01.s @@ -0,0 +1,27 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: srlg %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x0c] +#CHECK: srlg %r15, %r1, 0 # encoding: [0xeb,0xf1,0x00,0x00,0x00,0x0c] +#CHECK: srlg %r1, %r15, 0 # encoding: [0xeb,0x1f,0x00,0x00,0x00,0x0c] +#CHECK: srlg %r15, %r15, 0 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x0c] +#CHECK: srlg %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x0c] +#CHECK: srlg %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x0c] +#CHECK: srlg %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x0c] +#CHECK: srlg %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x0c] +#CHECK: srlg %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x0c] +#CHECK: srlg %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x0c] +#CHECK: srlg %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x0c] +#CHECK: srlg %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x0c] + + srlg %r0,%r0,0 + srlg %r15,%r1,0 + srlg %r1,%r15,0 + srlg %r15,%r15,0 + srlg %r0,%r0,-524288 + srlg %r0,%r0,-1 + srlg %r0,%r0,1 + srlg %r0,%r0,524287 + srlg %r0,%r0,0(%r1) + srlg %r0,%r0,0(%r15) + srlg %r0,%r0,524287(%r1) + srlg %r0,%r0,524287(%r15) diff --git a/test/MC/SystemZ/insn-srlg-02.s b/test/MC/SystemZ/insn-srlg-02.s new file mode 100644 index 00000000000..1e24d0e407f --- /dev/null +++ b/test/MC/SystemZ/insn-srlg-02.s @@ -0,0 +1,16 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: srlg %r0,%r0,-524289 +#CHECK: error: invalid operand +#CHECK: srlg %r0,%r0,524288 +#CHECK: error: %r0 used in an address +#CHECK: srlg %r0,%r0,0(%r0) +#CHECK: error: invalid use of indexed addressing +#CHECK: srlg %r0,%r0,0(%r1,%r2) + + srlg %r0,%r0,-524289 + srlg %r0,%r0,524288 + srlg %r0,%r0,0(%r0) + srlg %r0,%r0,0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-st-01.s b/test/MC/SystemZ/insn-st-01.s new file mode 100644 index 00000000000..0b5fdb682c6 --- /dev/null +++ b/test/MC/SystemZ/insn-st-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: st %r0, 0 # encoding: [0x50,0x00,0x00,0x00] +#CHECK: st %r0, 4095 # encoding: [0x50,0x00,0x0f,0xff] +#CHECK: st %r0, 0(%r1) # encoding: [0x50,0x00,0x10,0x00] +#CHECK: st %r0, 0(%r15) # encoding: [0x50,0x00,0xf0,0x00] +#CHECK: st %r0, 4095(%r1,%r15) # encoding: [0x50,0x01,0xff,0xff] +#CHECK: st %r0, 4095(%r15,%r1) # encoding: [0x50,0x0f,0x1f,0xff] +#CHECK: st %r15, 0 # encoding: [0x50,0xf0,0x00,0x00] + + st %r0, 0 + st %r0, 4095 + st %r0, 0(%r1) + st %r0, 0(%r15) + st %r0, 4095(%r1,%r15) + st %r0, 4095(%r15,%r1) + st %r15, 0 diff --git a/test/MC/SystemZ/insn-st-02.s b/test/MC/SystemZ/insn-st-02.s new file mode 100644 index 00000000000..63e547a92bc --- /dev/null +++ b/test/MC/SystemZ/insn-st-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: st %r0, -1 +#CHECK: error: invalid operand +#CHECK: st %r0, 4096 + + st %r0, -1 + st %r0, 4096 diff --git a/test/MC/SystemZ/insn-stc-01.s b/test/MC/SystemZ/insn-stc-01.s new file mode 100644 index 00000000000..563f8914b64 --- /dev/null +++ b/test/MC/SystemZ/insn-stc-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: stc %r0, 0 # encoding: [0x42,0x00,0x00,0x00] +#CHECK: stc %r0, 4095 # encoding: [0x42,0x00,0x0f,0xff] +#CHECK: stc %r0, 0(%r1) # encoding: [0x42,0x00,0x10,0x00] +#CHECK: stc %r0, 0(%r15) # encoding: [0x42,0x00,0xf0,0x00] +#CHECK: stc %r0, 4095(%r1,%r15) # encoding: [0x42,0x01,0xff,0xff] +#CHECK: stc %r0, 4095(%r15,%r1) # encoding: [0x42,0x0f,0x1f,0xff] +#CHECK: stc %r15, 0 # encoding: [0x42,0xf0,0x00,0x00] + + stc %r0, 0 + stc %r0, 4095 + stc %r0, 0(%r1) + stc %r0, 0(%r15) + stc %r0, 4095(%r1,%r15) + stc %r0, 4095(%r15,%r1) + stc %r15, 0 diff --git a/test/MC/SystemZ/insn-stc-02.s b/test/MC/SystemZ/insn-stc-02.s new file mode 100644 index 00000000000..aa7dcb29df6 --- /dev/null +++ b/test/MC/SystemZ/insn-stc-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: stc %r0, -1 +#CHECK: error: invalid operand +#CHECK: stc %r0, 4096 + + stc %r0, -1 + stc %r0, 4096 diff --git a/test/MC/SystemZ/insn-stcy-01.s b/test/MC/SystemZ/insn-stcy-01.s new file mode 100644 index 00000000000..acc7ac5996e --- /dev/null +++ b/test/MC/SystemZ/insn-stcy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: stcy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x72] +#CHECK: stcy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x72] +#CHECK: stcy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x72] +#CHECK: stcy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x72] +#CHECK: stcy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x72] +#CHECK: stcy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x72] +#CHECK: stcy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x72] +#CHECK: stcy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x72] +#CHECK: stcy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x72] +#CHECK: stcy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x72] + + stcy %r0, -524288 + stcy %r0, -1 + stcy %r0, 0 + stcy %r0, 1 + stcy %r0, 524287 + stcy %r0, 0(%r1) + stcy %r0, 0(%r15) + stcy %r0, 524287(%r1,%r15) + stcy %r0, 524287(%r15,%r1) + stcy %r15, 0 diff --git a/test/MC/SystemZ/insn-stcy-02.s b/test/MC/SystemZ/insn-stcy-02.s new file mode 100644 index 00000000000..cbd7f7abdec --- /dev/null +++ b/test/MC/SystemZ/insn-stcy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: stcy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: stcy %r0, 524288 + + stcy %r0, -524289 + stcy %r0, 524288 diff --git a/test/MC/SystemZ/insn-std-01.s b/test/MC/SystemZ/insn-std-01.s new file mode 100644 index 00000000000..6867df8bb16 --- /dev/null +++ b/test/MC/SystemZ/insn-std-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: std %f0, 0 # encoding: [0x60,0x00,0x00,0x00] +#CHECK: std %f0, 4095 # encoding: [0x60,0x00,0x0f,0xff] +#CHECK: std %f0, 0(%r1) # encoding: [0x60,0x00,0x10,0x00] +#CHECK: std %f0, 0(%r15) # encoding: [0x60,0x00,0xf0,0x00] +#CHECK: std %f0, 4095(%r1,%r15) # encoding: [0x60,0x01,0xff,0xff] +#CHECK: std %f0, 4095(%r15,%r1) # encoding: [0x60,0x0f,0x1f,0xff] +#CHECK: std %f15, 0 # encoding: [0x60,0xf0,0x00,0x00] + + std %f0, 0 + std %f0, 4095 + std %f0, 0(%r1) + std %f0, 0(%r15) + std %f0, 4095(%r1,%r15) + std %f0, 4095(%r15,%r1) + std %f15, 0 diff --git a/test/MC/SystemZ/insn-std-02.s b/test/MC/SystemZ/insn-std-02.s new file mode 100644 index 00000000000..62bb9eb7fac --- /dev/null +++ b/test/MC/SystemZ/insn-std-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: std %f0, -1 +#CHECK: error: invalid operand +#CHECK: std %f0, 4096 + + std %f0, -1 + std %f0, 4096 diff --git a/test/MC/SystemZ/insn-stdy-01.s b/test/MC/SystemZ/insn-stdy-01.s new file mode 100644 index 00000000000..1ae9a7d3d01 --- /dev/null +++ b/test/MC/SystemZ/insn-stdy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: stdy %f0, -524288 # encoding: [0xed,0x00,0x00,0x00,0x80,0x67] +#CHECK: stdy %f0, -1 # encoding: [0xed,0x00,0x0f,0xff,0xff,0x67] +#CHECK: stdy %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x67] +#CHECK: stdy %f0, 1 # encoding: [0xed,0x00,0x00,0x01,0x00,0x67] +#CHECK: stdy %f0, 524287 # encoding: [0xed,0x00,0x0f,0xff,0x7f,0x67] +#CHECK: stdy %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x67] +#CHECK: stdy %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x67] +#CHECK: stdy %f0, 524287(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x7f,0x67] +#CHECK: stdy %f0, 524287(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x7f,0x67] +#CHECK: stdy %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x67] + + stdy %f0, -524288 + stdy %f0, -1 + stdy %f0, 0 + stdy %f0, 1 + stdy %f0, 524287 + stdy %f0, 0(%r1) + stdy %f0, 0(%r15) + stdy %f0, 524287(%r1,%r15) + stdy %f0, 524287(%r15,%r1) + stdy %f15, 0 diff --git a/test/MC/SystemZ/insn-stdy-02.s b/test/MC/SystemZ/insn-stdy-02.s new file mode 100644 index 00000000000..f9a09a59f1c --- /dev/null +++ b/test/MC/SystemZ/insn-stdy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: stdy %f0, -524289 +#CHECK: error: invalid operand +#CHECK: stdy %f0, 524288 + + stdy %f0, -524289 + stdy %f0, 524288 diff --git a/test/MC/SystemZ/insn-ste-01.s b/test/MC/SystemZ/insn-ste-01.s new file mode 100644 index 00000000000..8e245df9857 --- /dev/null +++ b/test/MC/SystemZ/insn-ste-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ste %f0, 0 # encoding: [0x70,0x00,0x00,0x00] +#CHECK: ste %f0, 4095 # encoding: [0x70,0x00,0x0f,0xff] +#CHECK: ste %f0, 0(%r1) # encoding: [0x70,0x00,0x10,0x00] +#CHECK: ste %f0, 0(%r15) # encoding: [0x70,0x00,0xf0,0x00] +#CHECK: ste %f0, 4095(%r1,%r15) # encoding: [0x70,0x01,0xff,0xff] +#CHECK: ste %f0, 4095(%r15,%r1) # encoding: [0x70,0x0f,0x1f,0xff] +#CHECK: ste %f15, 0 # encoding: [0x70,0xf0,0x00,0x00] + + ste %f0, 0 + ste %f0, 4095 + ste %f0, 0(%r1) + ste %f0, 0(%r15) + ste %f0, 4095(%r1,%r15) + ste %f0, 4095(%r15,%r1) + ste %f15, 0 diff --git a/test/MC/SystemZ/insn-ste-02.s b/test/MC/SystemZ/insn-ste-02.s new file mode 100644 index 00000000000..acc50eada84 --- /dev/null +++ b/test/MC/SystemZ/insn-ste-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: ste %f0, -1 +#CHECK: error: invalid operand +#CHECK: ste %f0, 4096 + + ste %f0, -1 + ste %f0, 4096 diff --git a/test/MC/SystemZ/insn-stey-01.s b/test/MC/SystemZ/insn-stey-01.s new file mode 100644 index 00000000000..1f825936508 --- /dev/null +++ b/test/MC/SystemZ/insn-stey-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: stey %f0, -524288 # encoding: [0xed,0x00,0x00,0x00,0x80,0x66] +#CHECK: stey %f0, -1 # encoding: [0xed,0x00,0x0f,0xff,0xff,0x66] +#CHECK: stey %f0, 0 # encoding: [0xed,0x00,0x00,0x00,0x00,0x66] +#CHECK: stey %f0, 1 # encoding: [0xed,0x00,0x00,0x01,0x00,0x66] +#CHECK: stey %f0, 524287 # encoding: [0xed,0x00,0x0f,0xff,0x7f,0x66] +#CHECK: stey %f0, 0(%r1) # encoding: [0xed,0x00,0x10,0x00,0x00,0x66] +#CHECK: stey %f0, 0(%r15) # encoding: [0xed,0x00,0xf0,0x00,0x00,0x66] +#CHECK: stey %f0, 524287(%r1,%r15) # encoding: [0xed,0x01,0xff,0xff,0x7f,0x66] +#CHECK: stey %f0, 524287(%r15,%r1) # encoding: [0xed,0x0f,0x1f,0xff,0x7f,0x66] +#CHECK: stey %f15, 0 # encoding: [0xed,0xf0,0x00,0x00,0x00,0x66] + + stey %f0, -524288 + stey %f0, -1 + stey %f0, 0 + stey %f0, 1 + stey %f0, 524287 + stey %f0, 0(%r1) + stey %f0, 0(%r15) + stey %f0, 524287(%r1,%r15) + stey %f0, 524287(%r15,%r1) + stey %f15, 0 diff --git a/test/MC/SystemZ/insn-stey-02.s b/test/MC/SystemZ/insn-stey-02.s new file mode 100644 index 00000000000..203b016e314 --- /dev/null +++ b/test/MC/SystemZ/insn-stey-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: stey %f0, -524289 +#CHECK: error: invalid operand +#CHECK: stey %f0, 524288 + + stey %f0, -524289 + stey %f0, 524288 diff --git a/test/MC/SystemZ/insn-stg-01.s b/test/MC/SystemZ/insn-stg-01.s new file mode 100644 index 00000000000..e8508d9f4e5 --- /dev/null +++ b/test/MC/SystemZ/insn-stg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: stg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x24] +#CHECK: stg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x24] +#CHECK: stg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x24] +#CHECK: stg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x24] +#CHECK: stg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x24] +#CHECK: stg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x24] +#CHECK: stg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x24] +#CHECK: stg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x24] +#CHECK: stg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x24] +#CHECK: stg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x24] + + stg %r0, -524288 + stg %r0, -1 + stg %r0, 0 + stg %r0, 1 + stg %r0, 524287 + stg %r0, 0(%r1) + stg %r0, 0(%r15) + stg %r0, 524287(%r1,%r15) + stg %r0, 524287(%r15,%r1) + stg %r15, 0 diff --git a/test/MC/SystemZ/insn-stg-02.s b/test/MC/SystemZ/insn-stg-02.s new file mode 100644 index 00000000000..1214ad1998c --- /dev/null +++ b/test/MC/SystemZ/insn-stg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: stg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: stg %r0, 524288 + + stg %r0, -524289 + stg %r0, 524288 diff --git a/test/MC/SystemZ/insn-stgrl-01.s b/test/MC/SystemZ/insn-stgrl-01.s new file mode 100644 index 00000000000..729b01dc115 --- /dev/null +++ b/test/MC/SystemZ/insn-stgrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: stgrl %r0, 2864434397 # encoding: [0xc4,0x0b,0x55,0x5d,0xe6,0x6e] +#CHECK: stgrl %r15, 2864434397 # encoding: [0xc4,0xfb,0x55,0x5d,0xe6,0x6e] + + stgrl %r0,0xaabbccdd + stgrl %r15,0xaabbccdd + +#CHECK: stgrl %r0, foo # encoding: [0xc4,0x0b,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: stgrl %r15, foo # encoding: [0xc4,0xfb,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + stgrl %r0,foo + stgrl %r15,foo + +#CHECK: stgrl %r3, bar+100 # encoding: [0xc4,0x3b,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: stgrl %r4, bar+100 # encoding: [0xc4,0x4b,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + stgrl %r3,bar+100 + stgrl %r4,bar+100 + +#CHECK: stgrl %r7, frob@PLT # encoding: [0xc4,0x7b,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: stgrl %r8, frob@PLT # encoding: [0xc4,0x8b,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + stgrl %r7,frob@PLT + stgrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-sth-01.s b/test/MC/SystemZ/insn-sth-01.s new file mode 100644 index 00000000000..0dabe345b59 --- /dev/null +++ b/test/MC/SystemZ/insn-sth-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sth %r0, 0 # encoding: [0x40,0x00,0x00,0x00] +#CHECK: sth %r0, 4095 # encoding: [0x40,0x00,0x0f,0xff] +#CHECK: sth %r0, 0(%r1) # encoding: [0x40,0x00,0x10,0x00] +#CHECK: sth %r0, 0(%r15) # encoding: [0x40,0x00,0xf0,0x00] +#CHECK: sth %r0, 4095(%r1,%r15) # encoding: [0x40,0x01,0xff,0xff] +#CHECK: sth %r0, 4095(%r15,%r1) # encoding: [0x40,0x0f,0x1f,0xff] +#CHECK: sth %r15, 0 # encoding: [0x40,0xf0,0x00,0x00] + + sth %r0, 0 + sth %r0, 4095 + sth %r0, 0(%r1) + sth %r0, 0(%r15) + sth %r0, 4095(%r1,%r15) + sth %r0, 4095(%r15,%r1) + sth %r15, 0 diff --git a/test/MC/SystemZ/insn-sth-02.s b/test/MC/SystemZ/insn-sth-02.s new file mode 100644 index 00000000000..e73c28917b0 --- /dev/null +++ b/test/MC/SystemZ/insn-sth-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sth %r0, -1 +#CHECK: error: invalid operand +#CHECK: sth %r0, 4096 + + sth %r0, -1 + sth %r0, 4096 diff --git a/test/MC/SystemZ/insn-sthrl-01.s b/test/MC/SystemZ/insn-sthrl-01.s new file mode 100644 index 00000000000..0bcdbd4bc8f --- /dev/null +++ b/test/MC/SystemZ/insn-sthrl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sthrl %r0, 2864434397 # encoding: [0xc4,0x07,0x55,0x5d,0xe6,0x6e] +#CHECK: sthrl %r15, 2864434397 # encoding: [0xc4,0xf7,0x55,0x5d,0xe6,0x6e] + + sthrl %r0,0xaabbccdd + sthrl %r15,0xaabbccdd + +#CHECK: sthrl %r0, foo # encoding: [0xc4,0x07,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: sthrl %r15, foo # encoding: [0xc4,0xf7,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + sthrl %r0,foo + sthrl %r15,foo + +#CHECK: sthrl %r3, bar+100 # encoding: [0xc4,0x37,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: sthrl %r4, bar+100 # encoding: [0xc4,0x47,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + sthrl %r3,bar+100 + sthrl %r4,bar+100 + +#CHECK: sthrl %r7, frob@PLT # encoding: [0xc4,0x77,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: sthrl %r8, frob@PLT # encoding: [0xc4,0x87,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + sthrl %r7,frob@PLT + sthrl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-sthy-01.s b/test/MC/SystemZ/insn-sthy-01.s new file mode 100644 index 00000000000..259c5e1c82f --- /dev/null +++ b/test/MC/SystemZ/insn-sthy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sthy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x70] +#CHECK: sthy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x70] +#CHECK: sthy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x70] +#CHECK: sthy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x70] +#CHECK: sthy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x70] +#CHECK: sthy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x70] +#CHECK: sthy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x70] +#CHECK: sthy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x70] +#CHECK: sthy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x70] +#CHECK: sthy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x70] + + sthy %r0, -524288 + sthy %r0, -1 + sthy %r0, 0 + sthy %r0, 1 + sthy %r0, 524287 + sthy %r0, 0(%r1) + sthy %r0, 0(%r15) + sthy %r0, 524287(%r1,%r15) + sthy %r0, 524287(%r15,%r1) + sthy %r15, 0 diff --git a/test/MC/SystemZ/insn-sthy-02.s b/test/MC/SystemZ/insn-sthy-02.s new file mode 100644 index 00000000000..0ad547b4b81 --- /dev/null +++ b/test/MC/SystemZ/insn-sthy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sthy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: sthy %r0, 524288 + + sthy %r0, -524289 + sthy %r0, 524288 diff --git a/test/MC/SystemZ/insn-stmg-01.s b/test/MC/SystemZ/insn-stmg-01.s new file mode 100644 index 00000000000..d1890144227 --- /dev/null +++ b/test/MC/SystemZ/insn-stmg-01.s @@ -0,0 +1,29 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: stmg %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x24] +#CHECK: stmg %r0, %r15, 0 # encoding: [0xeb,0x0f,0x00,0x00,0x00,0x24] +#CHECK: stmg %r14, %r15, 0 # encoding: [0xeb,0xef,0x00,0x00,0x00,0x24] +#CHECK: stmg %r15, %r15, 0 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x24] +#CHECK: stmg %r0, %r0, -524288 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x24] +#CHECK: stmg %r0, %r0, -1 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x24] +#CHECK: stmg %r0, %r0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x24] +#CHECK: stmg %r0, %r0, 1 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x24] +#CHECK: stmg %r0, %r0, 524287 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x24] +#CHECK: stmg %r0, %r0, 0(%r1) # encoding: [0xeb,0x00,0x10,0x00,0x00,0x24] +#CHECK: stmg %r0, %r0, 0(%r15) # encoding: [0xeb,0x00,0xf0,0x00,0x00,0x24] +#CHECK: stmg %r0, %r0, 524287(%r1) # encoding: [0xeb,0x00,0x1f,0xff,0x7f,0x24] +#CHECK: stmg %r0, %r0, 524287(%r15) # encoding: [0xeb,0x00,0xff,0xff,0x7f,0x24] + + stmg %r0,%r0,0 + stmg %r0,%r15,0 + stmg %r14,%r15,0 + stmg %r15,%r15,0 + stmg %r0,%r0,-524288 + stmg %r0,%r0,-1 + stmg %r0,%r0,0 + stmg %r0,%r0,1 + stmg %r0,%r0,524287 + stmg %r0,%r0,0(%r1) + stmg %r0,%r0,0(%r15) + stmg %r0,%r0,524287(%r1) + stmg %r0,%r0,524287(%r15) diff --git a/test/MC/SystemZ/insn-stmg-02.s b/test/MC/SystemZ/insn-stmg-02.s new file mode 100644 index 00000000000..342c38aec99 --- /dev/null +++ b/test/MC/SystemZ/insn-stmg-02.s @@ -0,0 +1,13 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: stmg %r0, %r0, -524289 +#CHECK: error: invalid operand +#CHECK: stmg %r0, %r0, 524288 +#CHECK: error: invalid use of indexed addressing +#CHECK: stmg %r0, %r0, 0(%r1,%r2) + + stmg %r0, %r0, -524289 + stmg %r0, %r0, 524288 + stmg %r0, %r0, 0(%r1,%r2) diff --git a/test/MC/SystemZ/insn-strl-01.s b/test/MC/SystemZ/insn-strl-01.s new file mode 100644 index 00000000000..84bd41f4c0c --- /dev/null +++ b/test/MC/SystemZ/insn-strl-01.s @@ -0,0 +1,31 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: strl %r0, 2864434397 # encoding: [0xc4,0x0f,0x55,0x5d,0xe6,0x6e] +#CHECK: strl %r15, 2864434397 # encoding: [0xc4,0xff,0x55,0x5d,0xe6,0x6e] + + strl %r0,0xaabbccdd + strl %r15,0xaabbccdd + +#CHECK: strl %r0, foo # encoding: [0xc4,0x0f,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL +#CHECK: strl %r15, foo # encoding: [0xc4,0xff,A,A,A,A] +# fixup A - offset: 2, value: foo+2, kind: FK_390_PC32DBL + + strl %r0,foo + strl %r15,foo + +#CHECK: strl %r3, bar+100 # encoding: [0xc4,0x3f,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL +#CHECK: strl %r4, bar+100 # encoding: [0xc4,0x4f,A,A,A,A] +# fixup A - offset: 2, value: (bar+100)+2, kind: FK_390_PC32DBL + + strl %r3,bar+100 + strl %r4,bar+100 + +#CHECK: strl %r7, frob@PLT # encoding: [0xc4,0x7f,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL +#CHECK: strl %r8, frob@PLT # encoding: [0xc4,0x8f,A,A,A,A] +# fixup A - offset: 2, value: frob@PLT+2, kind: FK_390_PC32DBL + + strl %r7,frob@PLT + strl %r8,frob@PLT diff --git a/test/MC/SystemZ/insn-strv-01.s b/test/MC/SystemZ/insn-strv-01.s new file mode 100644 index 00000000000..6a818a8b9ea --- /dev/null +++ b/test/MC/SystemZ/insn-strv-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: strv %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x3e] +#CHECK: strv %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x3e] +#CHECK: strv %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x3e] +#CHECK: strv %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x3e] +#CHECK: strv %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x3e] +#CHECK: strv %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x3e] +#CHECK: strv %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x3e] +#CHECK: strv %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x3e] +#CHECK: strv %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x3e] +#CHECK: strv %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x3e] + + strv %r0,-524288 + strv %r0,-1 + strv %r0,0 + strv %r0,1 + strv %r0,524287 + strv %r0,0(%r1) + strv %r0,0(%r15) + strv %r0,524287(%r1,%r15) + strv %r0,524287(%r15,%r1) + strv %r15,0 diff --git a/test/MC/SystemZ/insn-strv-02.s b/test/MC/SystemZ/insn-strv-02.s new file mode 100644 index 00000000000..24460edfed3 --- /dev/null +++ b/test/MC/SystemZ/insn-strv-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: strv %r0, -524289 +#CHECK: error: invalid operand +#CHECK: strv %r0, 524288 + + strv %r0, -524289 + strv %r0, 524288 diff --git a/test/MC/SystemZ/insn-strvg-01.s b/test/MC/SystemZ/insn-strvg-01.s new file mode 100644 index 00000000000..6a4d49d3bcc --- /dev/null +++ b/test/MC/SystemZ/insn-strvg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: strvg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x2f] +#CHECK: strvg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x2f] +#CHECK: strvg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x2f] +#CHECK: strvg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x2f] +#CHECK: strvg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x2f] +#CHECK: strvg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x2f] +#CHECK: strvg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x2f] +#CHECK: strvg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x2f] +#CHECK: strvg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x2f] +#CHECK: strvg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x2f] + + strvg %r0,-524288 + strvg %r0,-1 + strvg %r0,0 + strvg %r0,1 + strvg %r0,524287 + strvg %r0,0(%r1) + strvg %r0,0(%r15) + strvg %r0,524287(%r1,%r15) + strvg %r0,524287(%r15,%r1) + strvg %r15,0 diff --git a/test/MC/SystemZ/insn-strvg-02.s b/test/MC/SystemZ/insn-strvg-02.s new file mode 100644 index 00000000000..ebb0d5bffba --- /dev/null +++ b/test/MC/SystemZ/insn-strvg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: strvg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: strvg %r0, 524288 + + strvg %r0, -524289 + strvg %r0, 524288 diff --git a/test/MC/SystemZ/insn-sty-01.s b/test/MC/SystemZ/insn-sty-01.s new file mode 100644 index 00000000000..1ca2d5c5502 --- /dev/null +++ b/test/MC/SystemZ/insn-sty-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sty %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x50] +#CHECK: sty %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x50] +#CHECK: sty %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x50] +#CHECK: sty %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x50] +#CHECK: sty %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x50] +#CHECK: sty %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x50] +#CHECK: sty %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x50] +#CHECK: sty %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x50] +#CHECK: sty %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x50] +#CHECK: sty %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x50] + + sty %r0, -524288 + sty %r0, -1 + sty %r0, 0 + sty %r0, 1 + sty %r0, 524287 + sty %r0, 0(%r1) + sty %r0, 0(%r15) + sty %r0, 524287(%r1,%r15) + sty %r0, 524287(%r15,%r1) + sty %r15, 0 diff --git a/test/MC/SystemZ/insn-sty-02.s b/test/MC/SystemZ/insn-sty-02.s new file mode 100644 index 00000000000..fea7c089ab9 --- /dev/null +++ b/test/MC/SystemZ/insn-sty-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sty %r0, -524289 +#CHECK: error: invalid operand +#CHECK: sty %r0, 524288 + + sty %r0, -524289 + sty %r0, 524288 diff --git a/test/MC/SystemZ/insn-sxbr-01.s b/test/MC/SystemZ/insn-sxbr-01.s new file mode 100644 index 00000000000..e7f4ed25bf4 --- /dev/null +++ b/test/MC/SystemZ/insn-sxbr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sxbr %f0, %f0 # encoding: [0xb3,0x4b,0x00,0x00] +#CHECK: sxbr %f0, %f13 # encoding: [0xb3,0x4b,0x00,0x0d] +#CHECK: sxbr %f8, %f8 # encoding: [0xb3,0x4b,0x00,0x88] +#CHECK: sxbr %f13, %f0 # encoding: [0xb3,0x4b,0x00,0xd0] + + sxbr %f0, %f0 + sxbr %f0, %f13 + sxbr %f8, %f8 + sxbr %f13, %f0 diff --git a/test/MC/SystemZ/insn-sxbr-02.s b/test/MC/SystemZ/insn-sxbr-02.s new file mode 100644 index 00000000000..397238bd392 --- /dev/null +++ b/test/MC/SystemZ/insn-sxbr-02.s @@ -0,0 +1,17 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: sxbr %f0, %f2 +#CHECK: error: invalid register +#CHECK: sxbr %f0, %f14 +#CHECK: error: invalid register +#CHECK: sxbr %f2, %f0 +#CHECK: error: invalid register +#CHECK: sxbr %f14, %f0 + + sxbr %f0, %f2 + sxbr %f0, %f14 + sxbr %f2, %f0 + sxbr %f14, %f0 + diff --git a/test/MC/SystemZ/insn-sy-01.s b/test/MC/SystemZ/insn-sy-01.s new file mode 100644 index 00000000000..bc56bd790ec --- /dev/null +++ b/test/MC/SystemZ/insn-sy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: sy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x5b] +#CHECK: sy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x5b] +#CHECK: sy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x5b] +#CHECK: sy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x5b] +#CHECK: sy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x5b] +#CHECK: sy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x5b] +#CHECK: sy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x5b] +#CHECK: sy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x5b] +#CHECK: sy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x5b] +#CHECK: sy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x5b] + + sy %r0, -524288 + sy %r0, -1 + sy %r0, 0 + sy %r0, 1 + sy %r0, 524287 + sy %r0, 0(%r1) + sy %r0, 0(%r15) + sy %r0, 524287(%r1,%r15) + sy %r0, 524287(%r15,%r1) + sy %r15, 0 diff --git a/test/MC/SystemZ/insn-sy-02.s b/test/MC/SystemZ/insn-sy-02.s new file mode 100644 index 00000000000..7d64ca922d1 --- /dev/null +++ b/test/MC/SystemZ/insn-sy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: sy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: sy %r0, 524288 + + sy %r0, -524289 + sy %r0, 524288 diff --git a/test/MC/SystemZ/insn-x-01.s b/test/MC/SystemZ/insn-x-01.s new file mode 100644 index 00000000000..a2e3a2605a2 --- /dev/null +++ b/test/MC/SystemZ/insn-x-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: x %r0, 0 # encoding: [0x57,0x00,0x00,0x00] +#CHECK: x %r0, 4095 # encoding: [0x57,0x00,0x0f,0xff] +#CHECK: x %r0, 0(%r1) # encoding: [0x57,0x00,0x10,0x00] +#CHECK: x %r0, 0(%r15) # encoding: [0x57,0x00,0xf0,0x00] +#CHECK: x %r0, 4095(%r1,%r15) # encoding: [0x57,0x01,0xff,0xff] +#CHECK: x %r0, 4095(%r15,%r1) # encoding: [0x57,0x0f,0x1f,0xff] +#CHECK: x %r15, 0 # encoding: [0x57,0xf0,0x00,0x00] + + x %r0, 0 + x %r0, 4095 + x %r0, 0(%r1) + x %r0, 0(%r15) + x %r0, 4095(%r1,%r15) + x %r0, 4095(%r15,%r1) + x %r15, 0 diff --git a/test/MC/SystemZ/insn-x-02.s b/test/MC/SystemZ/insn-x-02.s new file mode 100644 index 00000000000..37197404641 --- /dev/null +++ b/test/MC/SystemZ/insn-x-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: x %r0, -1 +#CHECK: error: invalid operand +#CHECK: x %r0, 4096 + + x %r0, -1 + x %r0, 4096 diff --git a/test/MC/SystemZ/insn-xg-01.s b/test/MC/SystemZ/insn-xg-01.s new file mode 100644 index 00000000000..6cf5e7e4b48 --- /dev/null +++ b/test/MC/SystemZ/insn-xg-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: xg %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x82] +#CHECK: xg %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x82] +#CHECK: xg %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x82] +#CHECK: xg %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x82] +#CHECK: xg %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x82] +#CHECK: xg %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x82] +#CHECK: xg %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x82] +#CHECK: xg %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x82] +#CHECK: xg %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x82] +#CHECK: xg %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x82] + + xg %r0, -524288 + xg %r0, -1 + xg %r0, 0 + xg %r0, 1 + xg %r0, 524287 + xg %r0, 0(%r1) + xg %r0, 0(%r15) + xg %r0, 524287(%r1,%r15) + xg %r0, 524287(%r15,%r1) + xg %r15, 0 diff --git a/test/MC/SystemZ/insn-xg-02.s b/test/MC/SystemZ/insn-xg-02.s new file mode 100644 index 00000000000..0505b9facfe --- /dev/null +++ b/test/MC/SystemZ/insn-xg-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: xg %r0, -524289 +#CHECK: error: invalid operand +#CHECK: xg %r0, 524288 + + xg %r0, -524289 + xg %r0, 524288 diff --git a/test/MC/SystemZ/insn-xgr-01.s b/test/MC/SystemZ/insn-xgr-01.s new file mode 100644 index 00000000000..1a5a6d6e1c6 --- /dev/null +++ b/test/MC/SystemZ/insn-xgr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: xgr %r0, %r0 # encoding: [0xb9,0x82,0x00,0x00] +#CHECK: xgr %r0, %r15 # encoding: [0xb9,0x82,0x00,0x0f] +#CHECK: xgr %r15, %r0 # encoding: [0xb9,0x82,0x00,0xf0] +#CHECK: xgr %r7, %r8 # encoding: [0xb9,0x82,0x00,0x78] + + xgr %r0,%r0 + xgr %r0,%r15 + xgr %r15,%r0 + xgr %r7,%r8 diff --git a/test/MC/SystemZ/insn-xi-01.s b/test/MC/SystemZ/insn-xi-01.s new file mode 100644 index 00000000000..2a7670c732c --- /dev/null +++ b/test/MC/SystemZ/insn-xi-01.s @@ -0,0 +1,17 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: xi 0, 0 # encoding: [0x97,0x00,0x00,0x00] +#CHECK: xi 4095, 0 # encoding: [0x97,0x00,0x0f,0xff] +#CHECK: xi 0, 255 # encoding: [0x97,0xff,0x00,0x00] +#CHECK: xi 0(%r1), 42 # encoding: [0x97,0x2a,0x10,0x00] +#CHECK: xi 0(%r15), 42 # encoding: [0x97,0x2a,0xf0,0x00] +#CHECK: xi 4095(%r1), 42 # encoding: [0x97,0x2a,0x1f,0xff] +#CHECK: xi 4095(%r15), 42 # encoding: [0x97,0x2a,0xff,0xff] + + xi 0, 0 + xi 4095, 0 + xi 0, 255 + xi 0(%r1), 42 + xi 0(%r15), 42 + xi 4095(%r1), 42 + xi 4095(%r15), 42 diff --git a/test/MC/SystemZ/insn-xi-02.s b/test/MC/SystemZ/insn-xi-02.s new file mode 100644 index 00000000000..a1ce668a693 --- /dev/null +++ b/test/MC/SystemZ/insn-xi-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: xi -1, 0 +#CHECK: error: invalid operand +#CHECK: xi 4096, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: xi 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: xi 0, -1 +#CHECK: error: invalid operand +#CHECK: xi 0, 256 + + xi -1, 0 + xi 4096, 0 + xi 0(%r1,%r2), 0 + xi 0, -1 + xi 0, 256 diff --git a/test/MC/SystemZ/insn-xihf-01.s b/test/MC/SystemZ/insn-xihf-01.s new file mode 100644 index 00000000000..ad2ec1946a0 --- /dev/null +++ b/test/MC/SystemZ/insn-xihf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: xihf %r0, 0 # encoding: [0xc0,0x06,0x00,0x00,0x00,0x00] +#CHECK: xihf %r0, 4294967295 # encoding: [0xc0,0x06,0xff,0xff,0xff,0xff] +#CHECK: xihf %r15, 0 # encoding: [0xc0,0xf6,0x00,0x00,0x00,0x00] + + xihf %r0, 0 + xihf %r0, 0xffffffff + xihf %r15, 0 diff --git a/test/MC/SystemZ/insn-xihf-02.s b/test/MC/SystemZ/insn-xihf-02.s new file mode 100644 index 00000000000..945993b8224 --- /dev/null +++ b/test/MC/SystemZ/insn-xihf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: xihf %r0, -1 +#CHECK: error: invalid operand +#CHECK: xihf %r0, 1 << 32 + + xihf %r0, -1 + xihf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-xilf-01.s b/test/MC/SystemZ/insn-xilf-01.s new file mode 100644 index 00000000000..475e5733210 --- /dev/null +++ b/test/MC/SystemZ/insn-xilf-01.s @@ -0,0 +1,9 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: xilf %r0, 0 # encoding: [0xc0,0x07,0x00,0x00,0x00,0x00] +#CHECK: xilf %r0, 4294967295 # encoding: [0xc0,0x07,0xff,0xff,0xff,0xff] +#CHECK: xilf %r15, 0 # encoding: [0xc0,0xf7,0x00,0x00,0x00,0x00] + + xilf %r0, 0 + xilf %r0, 0xffffffff + xilf %r15, 0 diff --git a/test/MC/SystemZ/insn-xilf-02.s b/test/MC/SystemZ/insn-xilf-02.s new file mode 100644 index 00000000000..df02b7cc947 --- /dev/null +++ b/test/MC/SystemZ/insn-xilf-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: xilf %r0, -1 +#CHECK: error: invalid operand +#CHECK: xilf %r0, 1 << 32 + + xilf %r0, -1 + xilf %r0, 1 << 32 diff --git a/test/MC/SystemZ/insn-xiy-01.s b/test/MC/SystemZ/insn-xiy-01.s new file mode 100644 index 00000000000..c329ce05726 --- /dev/null +++ b/test/MC/SystemZ/insn-xiy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: xiy -524288, 0 # encoding: [0xeb,0x00,0x00,0x00,0x80,0x57] +#CHECK: xiy -1, 0 # encoding: [0xeb,0x00,0x0f,0xff,0xff,0x57] +#CHECK: xiy 0, 0 # encoding: [0xeb,0x00,0x00,0x00,0x00,0x57] +#CHECK: xiy 1, 0 # encoding: [0xeb,0x00,0x00,0x01,0x00,0x57] +#CHECK: xiy 524287, 0 # encoding: [0xeb,0x00,0x0f,0xff,0x7f,0x57] +#CHECK: xiy 0, 255 # encoding: [0xeb,0xff,0x00,0x00,0x00,0x57] +#CHECK: xiy 0(%r1), 42 # encoding: [0xeb,0x2a,0x10,0x00,0x00,0x57] +#CHECK: xiy 0(%r15), 42 # encoding: [0xeb,0x2a,0xf0,0x00,0x00,0x57] +#CHECK: xiy 524287(%r1), 42 # encoding: [0xeb,0x2a,0x1f,0xff,0x7f,0x57] +#CHECK: xiy 524287(%r15), 42 # encoding: [0xeb,0x2a,0xff,0xff,0x7f,0x57] + + xiy -524288, 0 + xiy -1, 0 + xiy 0, 0 + xiy 1, 0 + xiy 524287, 0 + xiy 0, 255 + xiy 0(%r1), 42 + xiy 0(%r15), 42 + xiy 524287(%r1), 42 + xiy 524287(%r15), 42 diff --git a/test/MC/SystemZ/insn-xiy-02.s b/test/MC/SystemZ/insn-xiy-02.s new file mode 100644 index 00000000000..519c26c9659 --- /dev/null +++ b/test/MC/SystemZ/insn-xiy-02.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: xiy -524289, 0 +#CHECK: error: invalid operand +#CHECK: xiy 524288, 0 +#CHECK: error: invalid use of indexed addressing +#CHECK: xiy 0(%r1,%r2), 0 +#CHECK: error: invalid operand +#CHECK: xiy 0, -1 +#CHECK: error: invalid operand +#CHECK: xiy 0, 256 + + xiy -524289, 0 + xiy 524288, 0 + xiy 0(%r1,%r2), 0 + xiy 0, -1 + xiy 0, 256 diff --git a/test/MC/SystemZ/insn-xr-01.s b/test/MC/SystemZ/insn-xr-01.s new file mode 100644 index 00000000000..471e6a63d6f --- /dev/null +++ b/test/MC/SystemZ/insn-xr-01.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: xr %r0, %r0 # encoding: [0x17,0x00] +#CHECK: xr %r0, %r15 # encoding: [0x17,0x0f] +#CHECK: xr %r15, %r0 # encoding: [0x17,0xf0] +#CHECK: xr %r7, %r8 # encoding: [0x17,0x78] + + xr %r0,%r0 + xr %r0,%r15 + xr %r15,%r0 + xr %r7,%r8 diff --git a/test/MC/SystemZ/insn-xy-01.s b/test/MC/SystemZ/insn-xy-01.s new file mode 100644 index 00000000000..132db04bf56 --- /dev/null +++ b/test/MC/SystemZ/insn-xy-01.s @@ -0,0 +1,23 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: xy %r0, -524288 # encoding: [0xe3,0x00,0x00,0x00,0x80,0x57] +#CHECK: xy %r0, -1 # encoding: [0xe3,0x00,0x0f,0xff,0xff,0x57] +#CHECK: xy %r0, 0 # encoding: [0xe3,0x00,0x00,0x00,0x00,0x57] +#CHECK: xy %r0, 1 # encoding: [0xe3,0x00,0x00,0x01,0x00,0x57] +#CHECK: xy %r0, 524287 # encoding: [0xe3,0x00,0x0f,0xff,0x7f,0x57] +#CHECK: xy %r0, 0(%r1) # encoding: [0xe3,0x00,0x10,0x00,0x00,0x57] +#CHECK: xy %r0, 0(%r15) # encoding: [0xe3,0x00,0xf0,0x00,0x00,0x57] +#CHECK: xy %r0, 524287(%r1,%r15) # encoding: [0xe3,0x01,0xff,0xff,0x7f,0x57] +#CHECK: xy %r0, 524287(%r15,%r1) # encoding: [0xe3,0x0f,0x1f,0xff,0x7f,0x57] +#CHECK: xy %r15, 0 # encoding: [0xe3,0xf0,0x00,0x00,0x00,0x57] + + xy %r0, -524288 + xy %r0, -1 + xy %r0, 0 + xy %r0, 1 + xy %r0, 524287 + xy %r0, 0(%r1) + xy %r0, 0(%r15) + xy %r0, 524287(%r1,%r15) + xy %r0, 524287(%r15,%r1) + xy %r15, 0 diff --git a/test/MC/SystemZ/insn-xy-02.s b/test/MC/SystemZ/insn-xy-02.s new file mode 100644 index 00000000000..6ba3bad48c9 --- /dev/null +++ b/test/MC/SystemZ/insn-xy-02.s @@ -0,0 +1,10 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid operand +#CHECK: xy %r0, -524289 +#CHECK: error: invalid operand +#CHECK: xy %r0, 524288 + + xy %r0, -524289 + xy %r0, 524288 diff --git a/test/MC/SystemZ/lit.local.cfg b/test/MC/SystemZ/lit.local.cfg new file mode 100644 index 00000000000..abb697406d6 --- /dev/null +++ b/test/MC/SystemZ/lit.local.cfg @@ -0,0 +1,6 @@ +config.suffixes = ['.ll', '.c', '.cpp', '.s'] + +targets = set(config.root.targets_to_build.split()) +if not 'SystemZ' in targets: + config.unsupported = True + diff --git a/test/MC/SystemZ/regs-01.s b/test/MC/SystemZ/regs-01.s new file mode 100644 index 00000000000..df11fee691b --- /dev/null +++ b/test/MC/SystemZ/regs-01.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lr %r0, %r1 # encoding: [0x18,0x01] +#CHECK: lr %r2, %r3 # encoding: [0x18,0x23] +#CHECK: lr %r4, %r5 # encoding: [0x18,0x45] +#CHECK: lr %r6, %r7 # encoding: [0x18,0x67] +#CHECK: lr %r8, %r9 # encoding: [0x18,0x89] +#CHECK: lr %r10, %r11 # encoding: [0x18,0xab] +#CHECK: lr %r12, %r13 # encoding: [0x18,0xcd] +#CHECK: lr %r14, %r15 # encoding: [0x18,0xef] + + lr %r0,%r1 + lr %r2,%r3 + lr %r4,%r5 + lr %r6,%r7 + lr %r8,%r9 + lr %r10,%r11 + lr %r12,%r13 + lr %r14,%r15 diff --git a/test/MC/SystemZ/regs-02.s b/test/MC/SystemZ/regs-02.s new file mode 100644 index 00000000000..baaa0f9f978 --- /dev/null +++ b/test/MC/SystemZ/regs-02.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lgr %r0, %r1 # encoding: [0xb9,0x04,0x00,0x01] +#CHECK: lgr %r2, %r3 # encoding: [0xb9,0x04,0x00,0x23] +#CHECK: lgr %r4, %r5 # encoding: [0xb9,0x04,0x00,0x45] +#CHECK: lgr %r6, %r7 # encoding: [0xb9,0x04,0x00,0x67] +#CHECK: lgr %r8, %r9 # encoding: [0xb9,0x04,0x00,0x89] +#CHECK: lgr %r10, %r11 # encoding: [0xb9,0x04,0x00,0xab] +#CHECK: lgr %r12, %r13 # encoding: [0xb9,0x04,0x00,0xcd] +#CHECK: lgr %r14, %r15 # encoding: [0xb9,0x04,0x00,0xef] + + lgr %r0,%r1 + lgr %r2,%r3 + lgr %r4,%r5 + lgr %r6,%r7 + lgr %r8,%r9 + lgr %r10,%r11 + lgr %r12,%r13 + lgr %r14,%r15 diff --git a/test/MC/SystemZ/regs-03.s b/test/MC/SystemZ/regs-03.s new file mode 100644 index 00000000000..6ced4157b45 --- /dev/null +++ b/test/MC/SystemZ/regs-03.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: dlr %r0, %r0 # encoding: [0xb9,0x97,0x00,0x00] +#CHECK: dlr %r2, %r0 # encoding: [0xb9,0x97,0x00,0x20] +#CHECK: dlr %r4, %r0 # encoding: [0xb9,0x97,0x00,0x40] +#CHECK: dlr %r6, %r0 # encoding: [0xb9,0x97,0x00,0x60] +#CHECK: dlr %r8, %r0 # encoding: [0xb9,0x97,0x00,0x80] +#CHECK: dlr %r10, %r0 # encoding: [0xb9,0x97,0x00,0xa0] +#CHECK: dlr %r12, %r0 # encoding: [0xb9,0x97,0x00,0xc0] +#CHECK: dlr %r14, %r0 # encoding: [0xb9,0x97,0x00,0xe0] + + dlr %r0,%r0 + dlr %r2,%r0 + dlr %r4,%r0 + dlr %r6,%r0 + dlr %r8,%r0 + dlr %r10,%r0 + dlr %r12,%r0 + dlr %r14,%r0 diff --git a/test/MC/SystemZ/regs-04.s b/test/MC/SystemZ/regs-04.s new file mode 100644 index 00000000000..a2da67186f2 --- /dev/null +++ b/test/MC/SystemZ/regs-04.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ler %f0, %f1 # encoding: [0x38,0x01] +#CHECK: ler %f2, %f3 # encoding: [0x38,0x23] +#CHECK: ler %f4, %f5 # encoding: [0x38,0x45] +#CHECK: ler %f6, %f7 # encoding: [0x38,0x67] +#CHECK: ler %f8, %f9 # encoding: [0x38,0x89] +#CHECK: ler %f10, %f11 # encoding: [0x38,0xab] +#CHECK: ler %f12, %f13 # encoding: [0x38,0xcd] +#CHECK: ler %f14, %f15 # encoding: [0x38,0xef] + + ler %f0,%f1 + ler %f2,%f3 + ler %f4,%f5 + ler %f6,%f7 + ler %f8,%f9 + ler %f10,%f11 + ler %f12,%f13 + ler %f14,%f15 diff --git a/test/MC/SystemZ/regs-05.s b/test/MC/SystemZ/regs-05.s new file mode 100644 index 00000000000..b5f50b51a3b --- /dev/null +++ b/test/MC/SystemZ/regs-05.s @@ -0,0 +1,19 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: ldr %f0, %f1 # encoding: [0x28,0x01] +#CHECK: ldr %f2, %f3 # encoding: [0x28,0x23] +#CHECK: ldr %f4, %f5 # encoding: [0x28,0x45] +#CHECK: ldr %f6, %f7 # encoding: [0x28,0x67] +#CHECK: ldr %f8, %f9 # encoding: [0x28,0x89] +#CHECK: ldr %f10, %f11 # encoding: [0x28,0xab] +#CHECK: ldr %f12, %f13 # encoding: [0x28,0xcd] +#CHECK: ldr %f14, %f15 # encoding: [0x28,0xef] + + ldr %f0,%f1 + ldr %f2,%f3 + ldr %f4,%f5 + ldr %f6,%f7 + ldr %f8,%f9 + ldr %f10,%f11 + ldr %f12,%f13 + ldr %f14,%f15 diff --git a/test/MC/SystemZ/regs-06.s b/test/MC/SystemZ/regs-06.s new file mode 100644 index 00000000000..43bf38c9c4b --- /dev/null +++ b/test/MC/SystemZ/regs-06.s @@ -0,0 +1,11 @@ +# RUN: llvm-mc -triple s390x-linux-gnu -show-encoding %s | FileCheck %s + +#CHECK: lxr %f0, %f1 # encoding: [0xb3,0x65,0x00,0x01] +#CHECK: lxr %f4, %f5 # encoding: [0xb3,0x65,0x00,0x45] +#CHECK: lxr %f8, %f9 # encoding: [0xb3,0x65,0x00,0x89] +#CHECK: lxr %f12, %f13 # encoding: [0xb3,0x65,0x00,0xcd] + + lxr %f0,%f1 + lxr %f4,%f5 + lxr %f8,%f9 + lxr %f12,%f13 diff --git a/test/MC/SystemZ/regs-07.s b/test/MC/SystemZ/regs-07.s new file mode 100644 index 00000000000..d3585a6e2cc --- /dev/null +++ b/test/MC/SystemZ/regs-07.s @@ -0,0 +1,28 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lr %r16,%r1 +#CHECK: error: invalid register +#CHECK: lr %f0,%r1 +#CHECK: error: invalid register +#CHECK: lr %a0,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: lr %arid,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: lr %0,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: lr 0,%r1 +#CHECK: error: unknown token in expression +#CHECK: lr (%r0),%r1 +#CHECK: error: unknown token in expression +#CHECK: lr %,%r1 + + lr %r16,%r1 + lr %f0,%r1 + lr %a0,%r1 + lr %arid,%r1 + lr %0,%r1 + lr 0,%r1 + lr (%r0),%r1 + lr %,%r1 diff --git a/test/MC/SystemZ/regs-08.s b/test/MC/SystemZ/regs-08.s new file mode 100644 index 00000000000..f11c45737a4 --- /dev/null +++ b/test/MC/SystemZ/regs-08.s @@ -0,0 +1,28 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lgr %r16,%r1 +#CHECK: error: invalid register +#CHECK: lgr %f0,%r1 +#CHECK: error: invalid register +#CHECK: lgr %a0,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: lgr %arid,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: lgr %0,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: lgr 0,%r1 +#CHECK: error: unknown token in expression +#CHECK: lgr (%r0),%r1 +#CHECK: error: unknown token in expression +#CHECK: lgr %,%r1 + + lgr %r16,%r1 + lgr %f0,%r1 + lgr %a0,%r1 + lgr %arid,%r1 + lgr %0,%r1 + lgr 0,%r1 + lgr (%r0),%r1 + lgr %,%r1 diff --git a/test/MC/SystemZ/regs-09.s b/test/MC/SystemZ/regs-09.s new file mode 100644 index 00000000000..60f4d391403 --- /dev/null +++ b/test/MC/SystemZ/regs-09.s @@ -0,0 +1,31 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: dlr %r1,%r8 +#CHECK: error: invalid register +#CHECK: dlr %r16,%r1 +#CHECK: error: invalid register +#CHECK: dlr %f0,%r1 +#CHECK: error: invalid register +#CHECK: dlr %a0,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: dlr %arid,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: dlr %0,%r1 +#CHECK: error: invalid operand for instruction +#CHECK: dlr 0,%r1 +#CHECK: error: unknown token in expression +#CHECK: dlr (%r0),%r1 +#CHECK: error: unknown token in expression +#CHECK: dlr %,%r1 + + dlr %r1,%r8 + dlr %r16,%r1 + dlr %f0,%r1 + dlr %a0,%r1 + dlr %arid,%r1 + dlr %0,%r1 + dlr 0,%r1 + dlr (%r0),%r1 + dlr %,%r1 diff --git a/test/MC/SystemZ/regs-10.s b/test/MC/SystemZ/regs-10.s new file mode 100644 index 00000000000..865aa82532f --- /dev/null +++ b/test/MC/SystemZ/regs-10.s @@ -0,0 +1,28 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: ler %f1,%f16 +#CHECK: error: invalid register +#CHECK: ler %f1,%r0 +#CHECK: error: invalid register +#CHECK: ler %f1,%a0 +#CHECK: error: invalid operand for instruction +#CHECK: ler %f1,%fly +#CHECK: error: invalid operand for instruction +#CHECK: ler %f1,%0 +#CHECK: error: invalid operand for instruction +#CHECK: ler %f1,0 +#CHECK: error: unknown token in expression +#CHECK: ler %f1,(%f0) +#CHECK: error: unknown token in expression +#CHECK: ler %f1,% + + ler %f1,%f16 + ler %f1,%r0 + ler %f1,%a0 + ler %f1,%fly + ler %f1,%0 + ler %f1,0 + ler %f1,(%f0) + ler %f1,% diff --git a/test/MC/SystemZ/regs-11.s b/test/MC/SystemZ/regs-11.s new file mode 100644 index 00000000000..5d0f04f0434 --- /dev/null +++ b/test/MC/SystemZ/regs-11.s @@ -0,0 +1,28 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: ldr %f1,%f16 +#CHECK: error: invalid register +#CHECK: ldr %f1,%r0 +#CHECK: error: invalid register +#CHECK: ldr %f1,%a0 +#CHECK: error: invalid operand for instruction +#CHECK: ldr %f1,%fly +#CHECK: error: invalid operand for instruction +#CHECK: ldr %f1,%0 +#CHECK: error: invalid operand for instruction +#CHECK: ldr %f1,0 +#CHECK: error: unknown token in expression +#CHECK: ldr %f1,(%f0) +#CHECK: error: unknown token in expression +#CHECK: ldr %f1,% + + ldr %f1,%f16 + ldr %f1,%r0 + ldr %f1,%a0 + ldr %f1,%fly + ldr %f1,%0 + ldr %f1,0 + ldr %f1,(%f0) + ldr %f1,% diff --git a/test/MC/SystemZ/regs-12.s b/test/MC/SystemZ/regs-12.s new file mode 100644 index 00000000000..f6cf0e75844 --- /dev/null +++ b/test/MC/SystemZ/regs-12.s @@ -0,0 +1,31 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: lxr %f1,%f2 +#CHECK: error: invalid register +#CHECK: lxr %f1,%f16 +#CHECK: error: invalid register +#CHECK: lxr %f1,%r0 +#CHECK: error: invalid register +#CHECK: lxr %f1,%a0 +#CHECK: error: invalid operand for instruction +#CHECK: lxr %f1,%fly +#CHECK: error: invalid operand for instruction +#CHECK: lxr %f1,%0 +#CHECK: error: invalid operand for instruction +#CHECK: lxr %f1,0 +#CHECK: error: unknown token in expression +#CHECK: lxr %f1,(%f0) +#CHECK: error: unknown token in expression +#CHECK: lxr %f1,% + + lxr %f1,%f2 + lxr %f1,%f16 + lxr %f1,%r0 + lxr %f1,%a0 + lxr %f1,%fly + lxr %f1,%0 + lxr %f1,0 + lxr %f1,(%f0) + lxr %f1,% diff --git a/test/MC/SystemZ/regs-13.s b/test/MC/SystemZ/regs-13.s new file mode 100644 index 00000000000..88b0c05b86f --- /dev/null +++ b/test/MC/SystemZ/regs-13.s @@ -0,0 +1,69 @@ +# RUN: llvm-mc -triple s390x-linux-gnu < %s | FileCheck %s + +#CHECK: .cfi_offset %r0, 0 +#CHECK: .cfi_offset %r1, 8 +#CHECK: .cfi_offset %r2, 16 +#CHECK: .cfi_offset %r3, 24 +#CHECK: .cfi_offset %r4, 32 +#CHECK: .cfi_offset %r5, 40 +#CHECK: .cfi_offset %r6, 48 +#CHECK: .cfi_offset %r7, 56 +#CHECK: .cfi_offset %r8, 64 +#CHECK: .cfi_offset %r9, 72 +#CHECK: .cfi_offset %r10, 80 +#CHECK: .cfi_offset %r11, 88 +#CHECK: .cfi_offset %r12, 96 +#CHECK: .cfi_offset %r13, 104 +#CHECK: .cfi_offset %r14, 112 +#CHECK: .cfi_offset %r15, 120 +#CHECK: .cfi_offset %f0, 128 +#CHECK: .cfi_offset %f1, 136 +#CHECK: .cfi_offset %f2, 144 +#CHECK: .cfi_offset %f3, 152 +#CHECK: .cfi_offset %f4, 160 +#CHECK: .cfi_offset %f5, 168 +#CHECK: .cfi_offset %f6, 176 +#CHECK: .cfi_offset %f7, 184 +#CHECK: .cfi_offset %f8, 192 +#CHECK: .cfi_offset %f9, 200 +#CHECK: .cfi_offset %f10, 208 +#CHECK: .cfi_offset %f11, 216 +#CHECK: .cfi_offset %f12, 224 +#CHECK: .cfi_offset %f13, 232 +#CHECK: .cfi_offset %f14, 240 +#CHECK: .cfi_offset %f15, 248 + + .cfi_startproc + .cfi_offset %r0,0 + .cfi_offset %r1,8 + .cfi_offset %r2,16 + .cfi_offset %r3,24 + .cfi_offset %r4,32 + .cfi_offset %r5,40 + .cfi_offset %r6,48 + .cfi_offset %r7,56 + .cfi_offset %r8,64 + .cfi_offset %r9,72 + .cfi_offset %r10,80 + .cfi_offset %r11,88 + .cfi_offset %r12,96 + .cfi_offset %r13,104 + .cfi_offset %r14,112 + .cfi_offset %r15,120 + .cfi_offset %f0,128 + .cfi_offset %f1,136 + .cfi_offset %f2,144 + .cfi_offset %f3,152 + .cfi_offset %f4,160 + .cfi_offset %f5,168 + .cfi_offset %f6,176 + .cfi_offset %f7,184 + .cfi_offset %f8,192 + .cfi_offset %f9,200 + .cfi_offset %f10,208 + .cfi_offset %f11,216 + .cfi_offset %f12,224 + .cfi_offset %f13,232 + .cfi_offset %f14,240 + .cfi_offset %f15,248 + .cfi_endproc diff --git a/test/MC/SystemZ/regs-14.s b/test/MC/SystemZ/regs-14.s new file mode 100644 index 00000000000..e22307d49ce --- /dev/null +++ b/test/MC/SystemZ/regs-14.s @@ -0,0 +1,18 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: invalid register +#CHECK: .cfi_offset %a0,0 +#CHECK: error: register expected +#CHECK: .cfi_offset %foo,0 +#CHECK: error: register expected +#CHECK: .cfi_offset %,0 +#CHECK: error: register expected +#CHECK: .cfi_offset r0,0 + + .cfi_startproc + .cfi_offset %a0,0 + .cfi_offset %foo,0 + .cfi_offset %,0 + .cfi_offset r0,0 + .cfi_endproc diff --git a/test/MC/SystemZ/regs-15.s b/test/MC/SystemZ/regs-15.s new file mode 100644 index 00000000000..baec6a639bb --- /dev/null +++ b/test/MC/SystemZ/regs-15.s @@ -0,0 +1,19 @@ +# RUN: not llvm-mc -triple s390x-linux-gnu < %s 2> %t +# RUN: FileCheck < %t %s + +#CHECK: error: %r0 used in an address +#CHECK: sll %r2,8(%r0) +#CHECK: error: %r0 used in an address +#CHECK: br %r0 +#CHECK: error: %r0 used in an address +#CHECK: l %r1,8(%r0) +#CHECK: error: %r0 used in an address +#CHECK: l %r1,8(%r0,%r15) +#CHECK: error: %r0 used in an address +#CHECK: l %r1,8(%r15,%r0) + + sll %r2,8(%r0) + br %r0 + l %r1,8(%r0) + l %r1,8(%r0,%r15) + l %r1,8(%r15,%r0)