Problems assembling TI-style code with ARM-coff assembler
Nick Clifton
nickc@redhat.com
Thu Aug 22 03:38:00 GMT 2002
Hi Eckhard,
> I have to compile a *.c file that is written to be compiled by a TI
> compiler for TMS470 ( ARM7-core) and contains the followling lines:
> asm(" .def _entrytable ");
> asm(" .def $entrytable ");
> asm("_entrytable: ");
> asm("$entrytable: ");
> This results in
>
> /tmp/ccm7ONcX.s: Assembler messages:
> /tmp/ccm7ONcX.s:110: Warning: rest of line ignored; first ignored character is
> `"'
> /tmp/ccm7ONcX.s:112: Warning: .def pseudo-op used inside of .def/.endef:
> ignored.
> /tmp/ccm7ONcX.s:112: Warning: rest of line ignored; first ignored character is
> `$'
Presumably these are TI assembler commands to define global symbols ?
In which case their equivalent gcc entries would be:
asm(" .global _entrytable ");
asm(" .global $entrytable ");
asm("_entrytable: ");
asm("$entrytable: ");
> asm(" B #-8 ");
> produces the error
>
> /tmp/ccYZkjox.s:117: Error: bad expression -- `b #-8'
You probably want to omit the hash, like this:
asm(" B -8 ");
Cheers
Nick
More information about the Binutils
mailing list