This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: Current cvs 3.2 can't build current cvs binutils.
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: Graham Stott <graham dot stott at btinternet dot com>
- Cc: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 14 Jul 2002 09:46:11 +0930
- Subject: Re: Current cvs 3.2 can't build current cvs binutils.
- References: <3D30BC71.7030309@btinternet.com>
On Sun, Jul 14, 2002 at 12:49:05AM +0100, Graham Stott wrote:
> Here's a testcase distilled from gas/config/ppc-toc.c, compile with either
> -O1 or -O2
>
> --------------------------------------------------------
> typedef unsigned long valueT;
>
> valueT
> md_apply_fix3 (valueT *valP)
> {
> valueT value = * valP;
>
> return (((value) >> 32) & 0xffff);
> }
> ----------------------------------------------------------
>
> The testcase is itself a bit suspect in that it's invoking undefined
> behaviour by.shifting
> by an amount >= bits in type, but it's derived directly from code in
> gas/config/ppc-toc.c
I suspect you mean gas/config/tc-ppc.c :) The code in question will
only be executed when sizeof (valueT) == 8, as it's dealing with
relocation types for ppc64.
--
Alan Modra
IBM OzLabs - Linux Technology Centre