This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: duplicate -mdisable-got with gcc-3.0
Hi!
(Richard, your comments were totally equivalent to Philips, so I'll only
reply once)
Thank you for your comments to my hack - but I'll remind people of my
real question - see the subject and the originial mail. I'm sure not to
be the first trying to use gcc-3 and uClinux/ARM:
How can I get all code generated pc-relative (so it still is pic, but
doesn't need a got) and all data adressed relative to pic-register?
Philip Blundell wrote:
>
> In message <3BE16CCD.8C43719B@acter.ch>, Adrian von Bidder writes:
> >- | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* | -os2*)
> >+ | -storm-chaos* | -tops10* | -tenex* | -tops20* \
> >+ | -its* | -os2* | -uclinux*)
>
> You need to send this bit to config-patches@gnu.org.
Apparently some people have done this previously without success.
Nevertheless, I shall try it.
>
> >+ unsigned long temp; \
> >+ __asm __volatile ( \
> >+ "adr %1, 0f\n" \
> >+" bx %1\n" \
> >+" .code 32\n" \
> >+"0: swi 0x9f0002 @ sys_cacheflush\n" \
>
> I don't think this is good. You probably want to either
>
> - code this using the native Thumb system call ABI
this seems not to be implemented in uClinux 2.0.38 so far. But it would
probably be the final goal, so in the mean time I'll probably
> - generate a call to out-of-line ARM code to make the system call
Is there some obvious place to put the function definition in?
> Assuming the kernel supports it, the first is the best. You might have to use
> some kind of undefined instruction rather than the interface for "normal"
> syscalls.
referring to my previous conversation with you and Russel this would be
swi 0 with the syscall # in r0.
> >--- gcc-3.0.2.orig/gcc/config/arm/t-arm-elf Thu Sep 21 19:36:19 2000
> >+++ gcc-3.0.2/gcc/config/arm/t-arm-elf Tue Oct 30 15:37:32 2001
> >@@ -37,9 +37,9 @@
> > # MULTILIB_OPTIONS += mapcs-32/mapcs-26
> > # MULTILIB_DIRNAMES += 32bit 26bit
> > #
> >-# MULTILIB_OPTIONS += mno-thumb-interwork/mthumb-interwork
> >-# MULTILIB_DIRNAMES += normal interwork
> >-# MULTILIB_EXCEPTIONS += *mapcs-26/*mthumb-interwork*
> >+MULTILIB_OPTIONS += mno-thumb-interwork/mthumb-interwork
> >+MULTILIB_DIRNAMES += normal interwork
> >+MULTILIB_EXCEPTIONS += *mapcs-26/*mthumb-interwork*
>
> This can't be right at all. You need to make a t-uclinux and call it in from
> config.gcc.
Ok. (But one does wonder why the normal arm target does not build the
interworking libraries.)
greets from Zürich
-- vbi