Andi Kleen wrote: > On Wed, Jan 28, 2009 at 09:39:39AM +0100, Paolo Bonzini wrote: >>> He'll get much better code by putting the program into a -fPIC .so, >>> loading it from a small stub and then unmap the stub. >>> large model generates really very bad code because all jumps >>> will be indirect. >> Is it also true with -fpie? > > Not sure what you mean?
Right, sorry. I meant "can you also use -fpie and use a linker script to relocate the text section", if you want to place it high but the code is not gigantic? > AFAIK -fpie code is the same quality as -fPIC. Both > are much much better than large model. Exactly. Paolo