m68k binutils patch

Pauli pauli@moreton.com.au
Wed Jun 20 20:19:00 GMT 2001


Hi all,


Another patch to the m68k gas support which assists building position
independent code for ColdFire and other processors without the bra.l
instructions.


The problem is that the jbra instruction produces one of the following
instructions:

	bra.s
	bra.w
	jmp

The exact choice being made based on the distance to be branched.  The
hassle here is that the assembler will *silently* convert a relative
branch instruction into an absolute one which will cause position
independent code to fail in very mysterious ways.

My patch attempts to address this problem by adding a new command line
option "--relative-branches" which inhibits the conversion from
relative branches to absolute ones (generating an error if such is
required).

This problem also occurs for other instructions and the patch
addresses these cases too.


Regards,

Pauli
binutils-2.10-reloc.patch.gz

-------------- next part --------------
A non-text attachment was scrubbed...
Name: binutils-2.10-reloc.patch.gz
Type: application/x-gzip
Size: 1640 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20010620/7fcc537f/attachment.bin>


More information about the Binutils mailing list