This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA:] Fix bug with #APP/#NO_APP when using macros.


Hans-Peter Nilsson <hans-peter.nilsson@axis.com> writes:

> An alternative is to remove this support completely and ignore
> #NO_APP/#APP; always scrub.  This is IMHO reasonable, since
> apparently no other GCC port uses this feature.

There are several gcc ports which currently use #NO_APP.  Grep for it
in gcc/config/*.h.  As I recall, #NO_APP was originally invented for
the m68k port.  Originally, gas was intended to only be used as the
backend of the compiler, and was not intended to support hand written
assembly code.  RMS objected to features like macros when I introduced
them, on the grounds that they would slow down the assembler, and also
that they would impose a future maintenance burden.

Of course, it would not be incorrect to ignore #NO_APP.  On the other
hand, #NO_APP was introduced to speed up the assembler, by skipping
the scrubbing.  On the gripping hand, scrubbing was a lot slower
before I rewrote the scrubber to use a state machine, back in 1995.

It would be interesting to profile the assembler to see how much time
would be lost by ignoring #NO_APP.  Try assembling the same file
twice, once with a patched assembler which always scrubs, and compare
the timings.  (I always used to use cccp.c for this sort of test case,
as a convenient very large source file; it is now gone, alas).

> Who is this JF, and why wasn't the nice string buffer functions
> that SAC wrote used?  Or do I mix up the timeline?  (Reply in
> private, if so inclined.)

JF is Jay Fenlason.  He was the gas maintainer up until 1991 or so.
You can still see his name in the docs, but the old ChangeLogs, such
as they were, have been lost.  That code in read.c is indeed at least
that old; a version of it is in my copy of gas 1.35 from March 1990.
The string buffer functions weren't written until SAC wrote gasp in
1994.  So there you go.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]