Issue |
132074
|
Summary |
[ms] [llvm-ml] Support macros with parenthesis and commas delimiters between arguments
|
Labels |
new issue
|
Assignees |
|
Reporter |
MisterDA
|
I have a MASM file that has a macro that I call with parenthesis and which uses a comma as a delimiter between arguments, as parameters may contain spaces:
```asm
i = 0
SubstitutionMacro MACRO _type:REQ, name:REQ
field_&name EQU i
i = i + 1
EXITM <>
ENDM
SubstitutionMacro(int, a)
SubstitutionMacro(int*, b)
SubstitutionMacro(struct type, c)
SubstitutionMacro(struct type*, d)
.CODE
mov r12, field_a
mov r13, field_b
mov r14, field_c
mov r15, field_d
END
```
`llvm-ml` currently fails at assembling this file:
``` console
$ ml64 -nologo -Cp -c -Fo test.obj test.asm
Assembling: test.asm
$ objdump -D --section='.text$mn' test.obj
test.obj: file format pe-x86-64
Disassembly of section .text$mn:
0000000000000000 <.text$mn>:
0: 49 c7 c4 00 00 00 00 mov $0x0,%r12
7: 49 c7 c5 01 00 00 00 mov $0x1,%r13
e: 49 c7 c6 02 00 00 00 mov $0x2,%r14
15: 49 c7 c7 03 00 00 00 mov $0x3,%r15
```
Cf #129905 cc @ericastor
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs