[llvm-bugs] [Bug 36110] New: Erratic behavior with inline asm macros
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Jan 26 09:25:37 PST 2018
https://bugs.llvm.org/show_bug.cgi?id=36110
Bug ID: 36110
Summary: Erratic behavior with inline asm macros
Product: clang
Version: 6.0
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: -New Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: royger at freebsd.org
CC: llvm-bugs at lists.llvm.org
It seems like clang has some specific behavior when dealing with .macros
defined inside of inline asm. Given the following example:
# cat snip.c
int main(void)
{
asm ( ".macro FOO\n.endm" );
asm ( ".macro FOO\n.endm" );
}
# clang -o snip snip.c
# clang -no-integrated-as -o snip snip.c
/tmp/snip-a5a133.s: Assembler messages:
/tmp/snip-a5a133.s:19: Error: Macro `foo' was already defined
clang: error: assembler command failed with exit code 1 (use -v to see
invocation)
Would it be possible to fix clang so it keeps .macro-s defined in other asm()-s
on the same compilation unit? (ie: so that it has the same behavior as gnu as)
Thanks, Roger.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180126/1d39c931/attachment.html>
More information about the llvm-bugs
mailing list