This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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: target/3925: [ARM/Thumb] Assembler chokes on branches with (PLT)


On Tue, 2002-03-19 at 11:55, Richard Earnshaw wrote:
> OK, so that clears up that side of the problem.  Now, what about the issue 
> that PLT32 and ARM24 aren't really different relocs?

Well, that depends on your point of view.

Obviously they are the same in terms of the fundamental bit operations
that they perform on the instruction.  But the PLT32 reloc has some
extra semantics stacked on top: if the symbol isn't known to be local,
it generates a plt entry and redirects the branch through it.

You could more or less dispose of the issue by adding an option to the
linker to say you wanted to generate a PIC executable.  If that was set,
you would treat all PC24 relocs like PLT32s are now; if not, you would
treat them as straight PC24.  I think the situation where someone is
deliberately mixing PIC and PDC objects in order to get a hybrid output
file is rare enough that it can be neglected.  On the other hand, people
are accustomed to controlling this with -fPIC at the compilation stage,
and changing it to be a linker option might turn out to be a nightmare.

p.


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