This is the mail archive of the
mailing list for the binutils project.
Re: tic6x: relocation truncated to fit: R_C6000_PCR_S21
Can anyone give me some pointers on how to instruct the assembler, or
linker to generate different branch/call instructions?
The usual method is called "relaxation". You have the compiler, or
assembler, generate the longest instruction sequence, ie one that is
guaranteed to work no matter what the offset. Then in the linker, once
the actual offset is known, you "relax" the instruction sequence,
replacing it with a smaller sequence, if that is viable.
Several ports do this. Search for the string "relax" in the BFD sources.