[AMDGPU][True16][CodeGen] true16 codegen pattern for v_med3_u/i16 (#121850)
[llvm-project.git] / llvm / test / MC / AsmParser / altmacro-expr-err.s
blobbe8c66eefcc9f140f0912f053cc06ff8aa2e904b
1 # RUN: not llvm-mc -triple i386-linux-gnu %s 2>&1 | FileCheck %s
3 # This test is a negative test for the altmacro expression.
4 # In this test we check the '.noaltmacro' directive.
5 # We expect that '.altmacro' and '.noaltmacro' will act as a switch on/off directives to the alternate macro mode.
6 # .noaltmacro returns the format into a regular macro handling.
7 # The default mode is ".noaltmacro" as first test checks.
9 # CHECK: error: expected immediate expression
10 # CHECK-NEXT: addl $%(1%4), %eax
11 .macro inner_percent arg
12 addl $\arg, %eax
13 .endm
15 inner_percent %(1%4)
17 .altmacro
18 .noaltmacro
20 # CHECK: multi_args_macro %(1+4-5) 1 %2+1
21 # CHECK: error: expected immediate expression
22 # CHECK-NEXT: addl $%(1+4-5), %eax
25 # CHECK: multi_args_macro %(1+4-5),1,%4%10
26 # CHECK: error: expected immediate expression
27 # CHECK-NEXT: addl $%(1+4-5), %eax
28 .macro multi_args_macro arg1 arg2 arg3
29 label\arg1\arg2\arg3:
30 addl $\arg1, %eax
31 .endm
33 multi_args_macro %(1+4-5) 1 %2+1
34 multi_args_macro %(1+4-5),1,%4%10