This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Expand PIC calls without PLT with -fno-plt
- From: Jeff Law <law at redhat dot com>
- To: Alexander Monakov <amonakov at ispras dot ru>, gcc-patches at gcc dot gnu dot org
- Cc: Rich Felker <dalias at libc dot org>
- Date: Mon, 04 May 2015 11:34:05 -0600
- Subject: Re: [PATCH] Expand PIC calls without PLT with -fno-plt
- Authentication-results: sourceware.org; auth=none
- References: <1430757479-14241-1-git-send-email-amonakov at ispras dot ru> <1430757479-14241-6-git-send-email-amonakov at ispras dot ru>
On 05/04/2015 10:37 AM, Alexander Monakov wrote:
This patch introduces option -fno-plt that allows to expand calls that would
go via PLT to load the address of the function immediately at call site (which
introduces a GOT load). Cover letter explains the motivation for this patch.
New option documentation for invoke.texi is missing from the patch; if this is
accepted I'll be happy to send a v2 with documentation added.
* calls.c (prepare_call_address): Transform PLT call to GOT lookup and
indirect call by forcing address into a pseudo with -fno-plt.
* common.opt (flag_plt): New option.
OK once you cobble together the invoke.texi changes.