cd74f7d4aa88e400c81b5587b8b7758abc50f604
[oota-llvm.git] / test / MC / Mips / mips-expansions-bad.s
1 # RUN: not llvm-mc %s -arch=mips -mcpu=mips32r2 2>%t1
2 # RUN: FileCheck %s < %t1 --check-prefix=32-BIT
3 # RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n32 2>&1 | \
4 # RUN:   FileCheck %s --check-prefix=64-BIT --check-prefix=N32-ONLY
5 # RUN: not llvm-mc %s -arch=mips64 -mcpu=mips64 -target-abi n64 2>&1 | \
6 # RUN:   FileCheck %s --check-prefix=64-BIT --check-prefix=N64-ONLY
7
8   .text
9   dli $5, 1
10   # 32-BIT: :[[@LINE-1]]:3: error: instruction requires a 64-bit architecture
11   bne $2, 0x100010001, 1332
12   # 32-BIT: :[[@LINE-1]]:3: error: instruction requires a 32-bit immediate
13   beq $2, 0x100010001, 1332
14   # 32-BIT: :[[@LINE-1]]:3: error: instruction requires a 32-bit immediate
15   .set mips32r6
16   ulhu $5, 0
17   # 32-BIT: :[[@LINE-1]]:3: error: instruction not supported on mips32r6 or mips64r6
18   # 64-BIT: :[[@LINE-2]]:3: error: instruction not supported on mips32r6 or mips64r6
19   .set mips32
20   ulhu $5, 1
21   # 32-BIT-NOT: :[[@LINE-1]]:3: error: instruction not supported on mips32r6 or mips64r6
22   # 64-BIT-NOT: :[[@LINE-2]]:3: error: instruction not supported on mips32r6 or mips64r6
23   .set mips64r6
24   ulhu $5, 2
25   # 32-BIT: :[[@LINE-1]]:3: error: instruction not supported on mips32r6 or mips64r6
26   # 64-BIT: :[[@LINE-2]]:3: error: instruction not supported on mips32r6 or mips64r6
27
28   .set mips32r6
29   ulw $5, 0
30   # 32-BIT: :[[@LINE-1]]:3: error: instruction not supported on mips32r6 or mips64r6
31   # 64-BIT: :[[@LINE-2]]:3: error: instruction not supported on mips32r6 or mips64r6
32   .set mips32
33   ulw $5, 1
34   # 32-BIT-NOT: :[[@LINE-1]]:3: error: instruction not supported on mips32r6 or mips64r6
35   # 64-BIT-NOT: :[[@LINE-2]]:3: error: instruction not supported on mips32r6 or mips64r6
36   .set mips64r6
37   ulw $5, 2
38   # 32-BIT: :[[@LINE-1]]:3: error: instruction not supported on mips32r6 or mips64r6
39   # 64-BIT: :[[@LINE-2]]:3: error: instruction not supported on mips32r6 or mips64r6