Re: Using versioned symbols in assembler parts of a source file

Richard Henderson (rth@cygnus.com)
Tue, 12 Aug 1997 18:25:51 -0700 (PDT)


> the driver for transputer link adapter "link" from transputer-08c.tar.gz
> has the option to use Assembler in som critical routines.
> Here is a part of the code:
> "pushl %%edx\n\t" /* call the scheduler */
> "call " SYMBOL_NAME_STR(schedule)"\n\t" /* scheduler */
> "popl %%edx\n\t"

The implementation of SYMBOL_NAME_STR, whereever your patch got it
from, is likely wrong. ANSI C preprocessor rules require this be
done with indirection, e.g.

#define SYMBOL_NAME_STR1(x) #x
#define SYMBOL_NAME_STR(x) SYMBOL_NAME_STR1(x)

r~