diff options
| author | Sander de Smalen <sander.desmalen@arm.com> | 2018-07-27 12:26:24 +0000 |
|---|---|---|
| committer | Sander de Smalen <sander.desmalen@arm.com> | 2018-07-27 12:26:24 +0000 |
| commit | 71929e7cad088113598afb36e818138b8ee52ef1 (patch) | |
| tree | 1ec25eac9213803988a3e9d6898af4282f759b90 /llvm/test | |
| parent | 5fed24a39698466952504850e8fd7703e17ce679 (diff) | |
| download | bcm5719-llvm-71929e7cad088113598afb36e818138b8ee52ef1.tar.gz bcm5719-llvm-71929e7cad088113598afb36e818138b8ee52ef1.zip | |
[AArch64][SVE] Asm: Support for FRECPE and FRSQRTE.
Support for floating-point instructions for reciprocal
estimate (FRECPE) and reciprocal square root estimate (FRSQRTE).
llvm-svn: 338120
Diffstat (limited to 'llvm/test')
| -rw-r--r-- | llvm/test/MC/AArch64/SVE/frecpe-diagnostics.s | 6 | ||||
| -rw-r--r-- | llvm/test/MC/AArch64/SVE/frecpe.s | 26 | ||||
| -rw-r--r-- | llvm/test/MC/AArch64/SVE/frsqrte-diagnostics.s | 6 | ||||
| -rw-r--r-- | llvm/test/MC/AArch64/SVE/frsqrte.s | 26 |
4 files changed, 64 insertions, 0 deletions
diff --git a/llvm/test/MC/AArch64/SVE/frecpe-diagnostics.s b/llvm/test/MC/AArch64/SVE/frecpe-diagnostics.s new file mode 100644 index 00000000000..80467f26f5a --- /dev/null +++ b/llvm/test/MC/AArch64/SVE/frecpe-diagnostics.s @@ -0,0 +1,6 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve 2>&1 < %s| FileCheck %s + +frecpe z0.b, z31.b +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width +// CHECK-NEXT: frecpe z0.b, z31.b +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
\ No newline at end of file diff --git a/llvm/test/MC/AArch64/SVE/frecpe.s b/llvm/test/MC/AArch64/SVE/frecpe.s new file mode 100644 index 00000000000..3b559d951f6 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE/frecpe.s @@ -0,0 +1,26 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \ +// RUN: | llvm-objdump -d -mattr=+sve - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN + +frecpe z0.h, z31.h +// CHECK-INST: frecpe z0.h, z31.h +// CHECK-ENCODING: [0xe0,0x33,0x4e,0x65] +// CHECK-ERROR: instruction requires: sve +// CHECK-UNKNOWN: e0 33 4e 65 <unknown> + +frecpe z0.s, z31.s +// CHECK-INST: frecpe z0.s, z31.s +// CHECK-ENCODING: [0xe0,0x33,0x8e,0x65] +// CHECK-ERROR: instruction requires: sve +// CHECK-UNKNOWN: e0 33 8e 65 <unknown> + +frecpe z0.d, z31.d +// CHECK-INST: frecpe z0.d, z31.d +// CHECK-ENCODING: [0xe0,0x33,0xce,0x65] +// CHECK-ERROR: instruction requires: sve +// CHECK-UNKNOWN: e0 33 ce 65 <unknown> diff --git a/llvm/test/MC/AArch64/SVE/frsqrte-diagnostics.s b/llvm/test/MC/AArch64/SVE/frsqrte-diagnostics.s new file mode 100644 index 00000000000..b7325e164aa --- /dev/null +++ b/llvm/test/MC/AArch64/SVE/frsqrte-diagnostics.s @@ -0,0 +1,6 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve 2>&1 < %s| FileCheck %s + +frsqrte z0.b, z31.b +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width +// CHECK-NEXT: frsqrte z0.b, z31.b +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
\ No newline at end of file diff --git a/llvm/test/MC/AArch64/SVE/frsqrte.s b/llvm/test/MC/AArch64/SVE/frsqrte.s new file mode 100644 index 00000000000..e0fa387b665 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE/frsqrte.s @@ -0,0 +1,26 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \ +// RUN: | llvm-objdump -d -mattr=+sve - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN + +frsqrte z0.h, z31.h +// CHECK-INST: frsqrte z0.h, z31.h +// CHECK-ENCODING: [0xe0,0x33,0x4f,0x65] +// CHECK-ERROR: instruction requires: sve +// CHECK-UNKNOWN: e0 33 4f 65 <unknown> + +frsqrte z0.s, z31.s +// CHECK-INST: frsqrte z0.s, z31.s +// CHECK-ENCODING: [0xe0,0x33,0x8f,0x65] +// CHECK-ERROR: instruction requires: sve +// CHECK-UNKNOWN: e0 33 8f 65 <unknown> + +frsqrte z0.d, z31.d +// CHECK-INST: frsqrte z0.d, z31.d +// CHECK-ENCODING: [0xe0,0x33,0xcf,0x65] +// CHECK-ERROR: instruction requires: sve +// CHECK-UNKNOWN: e0 33 cf 65 <unknown> |

