This is the mail archive of the
mailing list for the GCC project.
Re: [RFC][PATCH][X86_64] Eliminate PLT stubs for specified external functions via -fno-plt=
- From: Pedro Alves <palves at redhat dot com>
- To: Sriraman Tallam <tmsriram at google dot com>, "H.J. Lu" <hjl dot tools at gmail dot com>, Michael Matz <matz at suse dot de>
- Cc: David Li <davidxl at google dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 21 May 2015 22:51:50 +0100
- Subject: Re: [RFC][PATCH][X86_64] Eliminate PLT stubs for specified external functions via -fno-plt=
- Authentication-results: sourceware.org; auth=none
- References: <CAMe9rOpF996wsqCjCUtApvSh8tNcf--=+OnfnNuSyKm0VPoUKQ at mail dot gmail dot com> <CAAs8HmwWSDY+KjKcB4W=TiYV0Pz7NSvfL_8igp+hPT-LU1utTg at mail dot gmail dot com> <CAAs8Hmz4XpJn2vVUYd8gXS9Frq-TtSNqKUFkRWbCFi84ArBQDA at mail dot gmail dot com>
On 05/21/2015 10:12 PM, Sriraman Tallam wrote:
> My original proposal, for x86_64 only, was to add
> -fno-plt=<function-name>. This lets the user decide for which
> functions PLT must be avoided. Let the compiler always generate an
> indirect call using call *func@GOTPCREL(%rip). We could do this for
> non-PIC code too. No need for linker fixups since this relies on the
> user to know that func is from a shared object.
Having to pass function names on the command line seems like an odd
interface. E.g, you'll need to pass the mangled name for
C++ functions. Any reason this isn't a function attribute?