This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: PATCH: Add --alt-nops=short|long to x86/x86-64 assemblers
> in assembler. The reasons we haven't run into any serious problems are
>
> 1. By default, cpu_arch_flags is set to accept everything.
> 2. .arch directive isn't used much.
>
> So my -mtune=CPU switch will optimize for CPU by generating instruction
> for CPU if instruction set of CPU is available.
But you said these instructions only existed on ppro or later. You can't have
mtune= effect the choice of instruction unless you also implement -march=.
Consider gcc -march=386 -mtune=686. IIUC you're proposing that gcc doesn't
emit .arch, and doesn't pass through -march=, so gas defaults to allowing all
instructions. gas then sees -mtune= and generates instructions that don't
work on 386.
Paul