• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// RUN: llvm-mc -triple aarch64-- -mattr=+crc %s 2>&1 |\
2// RUN:   FileCheck %s --check-prefix=CRC
3
4// RUN: llvm-mc -triple aarch64-- -mcpu=cortex-a55 %s 2>&1 |\
5// RUN:   FileCheck %s --check-prefix=CRC
6// RUN: llvm-mc -triple aarch64-- -mcpu=cortex-a75 %s 2>&1 |\
7// RUN:   FileCheck %s --check-prefix=CRC
8
9// RUN: not llvm-mc -triple aarch64-- %s 2>&1 |\
10// RUN:   FileCheck %s --check-prefix=NOCRC
11// RUN: not llvm-mc -triple aarch64-- -mcpu=cyclone %s 2>&1 |\
12// RUN:   FileCheck %s --check-prefix=NOCRC
13
14    crc32b w0, w1, w5
15    crc32h w3, w5, w6
16    crc32w w19, wzr, w20
17    crc32x w3, w5, x20
18
19// CRC: crc32b w0, w1, w5
20// CRC: crc32h w3, w5, w6
21// CRC: crc32w w19, wzr, w20
22// CRC: crc32x w3, w5, x20
23
24// NOCRC: error: instruction requires: crc
25// NOCRC:     crc32b w0, w1, w5
26// NOCRC: error: instruction requires: crc
27// NOCRC:     crc32h w3, w5, w6
28// NOCRC: error: instruction requires: crc
29// NOCRC:     crc32w w19, wzr, w20
30// NOCRC: error: instruction requires: crc
31// NOCRC:     crc32x w3, w5, x20
32
33    crc32cb w5, w10, w15
34    crc32ch w3, w5, w7
35    crc32cw w11, w13, w17
36    crc32cx w19, w23, x29
37
38// CRC: crc32cb w5, w10, w15
39// CRC: crc32ch w3, w5, w7
40// CRC: crc32cw w11, w13, w17
41// CRC: crc32cx w19, w23, x29
42
43// NOCRC: error: instruction requires: crc
44// NOCRC:     crc32cb w5, w10, w15
45// NOCRC: error: instruction requires: crc
46// NOCRC:     crc32ch w3, w5, w7
47// NOCRC: error: instruction requires: crc
48// NOCRC:     crc32cw w11, w13, w17
49// NOCRC: error: instruction requires: crc
50// NOCRC:     crc32cx w19, w23, x29
51