This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: ver_test_8_2.so
- From: David Miller <davem at davemloft dot net>
- To: iant at google dot com
- Cc: binutils at sourceware dot org
- Date: Sat, 14 Jun 2008 16:06:54 -0700 (PDT)
- Subject: Re: ver_test_8_2.so
- References: <20080519.232740.196464453.davem@davemloft.net> <m3d4nhf5h5.fsf@google.com> <20080520.145127.10101691.davem@davemloft.net>
From: David Miller <davem@davemloft.net>
Date: Tue, 20 May 2008 14:51:27 -0700 (PDT)
Ian, have you had a chance to make some progress on the
fix for this testsuite failure on Sparc? Your most recent
reply was:
http://sourceware.org/ml/binutils/2008-05/msg00162.html
Indicating that you could look into it :-)
Thanks!
> From: Ian Lance Taylor <iant@google.com>
> Date: Tue, 20 May 2008 06:52:06 -0700
>
> > David Miller <davem@davemloft.net> writes:
> >
> > > g++ -m32 -W -Wall -Werror -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fmerge-constants -g -O2 -o ver_test_8_2.so -Bgcctestdir/ -shared -Wl,--version-script,../../../src/gold/testsuite/ver_test_8.script two_file_test_2_pic.o
> > > gcctestdir/ld: /usr/lib/gcc/sparc-linux-gnu/4.1.3/../../../../lib/crti.o: requires unsupported dynamic reloc 17; recompile with -fPIC
> >
> > Can you set a breakpoint on line 1940 of sparc.cc, which looks like
> > this:
> > if (target->may_need_copy_reloc(gsym))
> > for the case where r_type == R_SPARC_PC22, and see why the immediately
> > preceding call to gsym->needs_dynamic_reloc(flags) returned true?
>
> Sure.
>
> BTW, this might be a stupid question, but I have a devil of a time setting
> breakpoints on the templated functions in sparc.cc, and I wonder if it's
> because the code in that file gets put into an anonymous namespace?
>
> For example, if I wanted to set a breakpoint on:
>
> Target_sparc<32, true>::Scan::local()
>
> how might I specify that to gdb?
>
> Anyways, back to the bug.
>
> During the call to gsyms->need_dynamic_reloc() flags is 2
> (NON_PIC_REF).
>
> gsym->is_weak_undefined() is false
>
> gsym->is_absolute() is false
>
> gsym->is_from_dynobj() is false
>
> gsym->is_undefined() is true
>
> That last one seems to be the trigger.
>
> gsym->name() is "_GLOBAL_OFFSET_TABLE_"