davem at davemloft.net
Mon Jan 14 23:39:00 CET 2013
From: Torbjorn Granlund <tg at gmplib.org>
Date: Mon, 14 Jan 2013 23:19:40 +0100
> David Miller <davem at davemloft.net> writes:
> From: nisse at lysator.liu.se (Niels Möller)
> Date: Mon, 14 Jan 2013 22:22:28 +0100
> > Furthermore, gmp needs to be portable to non-glibc systems as well. We
> > have a "fat binary" machinery that tries to solve the same problem, but
> > in a more portable way. Choosing between using IFUNC or the portable
> > machinery at configure time sounds like it could be a lots of additional
> > complexity.
> I don't like this kind of logic.
> What is the point in creating significantly beneficial facilities like
> IFUNC if the greatest potential benefactors, such as libgmp, use
> straw-men like this to justify not using it?
> This just rude. Why don't you give valid arguments instead? We'd like
> to hear your opinion!
My opinion is that IFUNC is valuable for the sake of turning what
would be two calls, into one through the PLT which is the minimum you
can get away with.
If you use function pointer tables, you have to do this through
another function so that you are at liberty to change the layout and
size of that function pointer table. That's one call through the PLT
for a shared library.
Then you need to do the indirect call through the function table itself.
With IFUNC the PLT resolves to the method that gets choosen by the
IFUNC resolver, and that's it.
More information about the gmp-devel