This is the mail archive of the gcc@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]

Re: 64 bit HPPA GCC


Yes, I have tried both the -fPIC and -fpic options. I have also compared the
assembly files generated by the HP Compiler using the +z/+Z option which
is supposed to do the same thing.

The problem I am having is with the way GCC compiler generates relocation
information for function descriptors. GCC compiler uses some intermediate
labels to store the addresses of functions that I use to initialise the
function
pointer. These labels seem to be getting initialised during link time which
results in wrong addresses for the function pointer during run time.

Thanks for the response.

Ullas



Christian Jönsson wrote:

> A long shot, I have no idea of what you are talking about really,
> but have you tried using -fPIC instead of -fpic?
>
> It's a matter of size of the table only so perhaps this is
> a totally wrong hunch...
>
> /ChJ
>
> Ullas Ponnadi wrote:
> >
> > Hi,
> >
> >    I am using the 64 bit GCC for HPPA ( gcc version 2.9-hppa-000310 ) to
> > build
> > Wide Mode binaries and using the -fpic option to generate Position
> > Independent Code.
> > I seem to have a problem with function pointers. The function
> > descriptors do not seem
> > to be getting fixed up properly for relocatable code. Could someone help
> > me in understanding
> > the issues and what is it that I need to do to use function pointers?
> >
> > Any help would be appreciated. I would also like to get a copy of the
> > response addressed
> > to me directly at uponnadi@cup.hp.com.
> >
> > Thanks,
> >
> > --
> > Ullas Ponnadi
> > e-mail : uponnadi@cup.hp.com





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