[Ffmpeg-devel] Broken trunk on AMD64 with PIC enabled

Trent Piepho xyzzy
Wed Apr 4 13:09:27 CEST 2007

On Wed, 4 Apr 2007, Reimar [iso-8859-1] D?ffinger wrote:
B Hello,
> On Wed, Apr 04, 2007 at 02:48:09AM -0700, Trent Piepho wrote:
> [...]
> > That's probably a bad idea since segment overrides are expensive outside of
> > real mode, and I'm not sure if it even works on x86-64.
> The documentation says nothing about them being expensive on x86-64
> (after all, no bounds checking), but you can only use fs or gs.

I was wrong, sticking the table in the code segment won't help either.  It
works for call instructions, because those are relative to the instruction
pointer.  PIC code can have "call 0x1234" and is still PIC without needing
a TEXTREL.  But "mov %cs:0x1234(%eax,%edx,4), %ecx" isn't EIP relative even
with the cs override, so it doesn't solve anything.

More information about the ffmpeg-devel mailing list