This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Pass -mtune and -march options to assembler.
Paul Brook wrote:
> On Tuesday 26 May 2009, Valdimir Volynsky wrote:
>> Dave Korn <firstname.lastname@example.org> wrote:
>>> I think your best choice would be to use the build-time
>>> autoconf tests to
>>> decide if we think we're talking to GNU as, and pass the
>>> options in that case,
>>> or not if not, optionally with a new command-line switch
>>> to override the default.
>> What about different choice - add information about
>> options to assembler file.
>> # COMMAND_LINE gcc -o test.c test.c -O2 -mtune=core2
>> .ident COMMAND_LINE gcc -o test.c test.c -O2 -mtune=core2
> Or, even better, use the .arch directive that already exists and add .tune.
That's still GAS-specific. The "# COMMAND_LINE" option vaguely resembles
the "#NO_APP" directive, so maybe has some precedent, and being a comment it
won't fail with a non-GAS assembler, but I'd suggest raising the suggestion on
the binutils list and seeing what people there think about it; right now, I'm
not sure what's the best way to go.