https://sourceware.org/bugzilla/show_bug.cgi?id=25750
Bug ID: 25750
Summary: GNU as has inconsistent behavior when expanding .macro
that takes as input directives with arguments
Product: binutils
Version: unspecified
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: binutils
Assignee: unassigned at sourceware dot org
Reporter: caij2003 at gmail dot com
Target Milestone: ---
Handling of spaces between directives and their arguments when expanding macros
is not consistent in GNU as -- it only supports selective directives. For
example, the following code assembled with aarch64-linux-gnu-gcc,
.macro foo insn
\insn
.endm
foo .inst (XXX)
However, if we replace the argument of the macro expansion with another
directive, such as "foo .section .sec1", it will fail. This is the case on x86
as well. Removing the space and surround the section name with parenthesis will
work, i.e. "foo .section(.sec1)". But the section name is (.sec1) instead of
.sec1 as intended. Not sure if this is intended but it introduces some
confusion IMO.
--
You are receiving this mail because:
You are on the CC list for the bug.