This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] libgcc: m68k: avoid TEXTRELs in shared library (PR 86224)


On Sat, Jul 28, 2018 at 08:47:33PM +0200, Andreas Schwab wrote:
> On Jul 28 2018, slyfox@inbox.ru wrote:
> 
> > From: Sergei Trofimovich <slyfox@gentoo.org>
> >
> > Cc: Ian Lance Taylor <ian@airs.com>
> > Cc: Jeff Law <law@redhat.com>
> > Cc: Andreas Schwab <schwab@linux-m68k.org>
> > Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
> > ---
> >  libgcc/config/m68k/lb1sf68.S | 19 ++++++++++++++-----
> >  1 file changed, 14 insertions(+), 5 deletions(-)
> >
> > diff --git a/libgcc/config/m68k/lb1sf68.S b/libgcc/config/m68k/lb1sf68.S
> > index 325a7c17d9b..16c6dc3f5a7 100644
> > --- a/libgcc/config/m68k/lb1sf68.S
> > +++ b/libgcc/config/m68k/lb1sf68.S
> > @@ -435,7 +435,10 @@ $_exception_handler:
> >  	.text
> >  	FUNC(__mulsi3)
> >  	.globl	SYM (__mulsi3)
> > +	.globl	SYM (__mulsi3_internal)
> > +	.hidden	SYM (__mulsi3_internal)
> 
> No need for extra entry symbols, just mark the real entry point as
> hidden, like in the static library.

That's clearly not correct or valid, as these are public interfaces.
If you make them hidden they'll be dropped from the dynamic symbol
table of libgcc_s.so.

Of course for libgcc.a they need to be hidden (it's an ABI bug if
they're not hidden there already but I think there's a separate layer
of the build system that forces them to be hidden).

Rich


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]