Re: i370 port - music/sp - possible generic gcc problem

2009-11-28 Thread Paul Edwards
: In function `acos': :137: Internal compiler error in ?, at :724 Please submit a full bug report, with preprocessed source if appropriate. See http://gcc.gnu.org/bugs.html> for instructions. I might be able to trace it from a different approach, getting more information about that internal error

Re: avr: optimizing assignment to a bit field

2009-11-28 Thread Shaun Jackman
2009/11/28 Richard Guenther : > On Sat, Nov 28, 2009 at 11:43 PM, Shaun Jackman wrote: >> When assigning a bool to a single bit of a bitfield located in the >> bit-addressable region of memory, better code is produced by >>        if (flag) >>                bitfield.bit = true; >>        else >>

Re: i370 port - music/sp - possible generic gcc problem

2009-11-28 Thread Paul Edwards
If GC does that, then how come there is all this effort to do mmap testing to see if it has the facility to zero memory, and I can't see what you are refering to. I obviously misinterpreted that then. why is the surrounding code (in GCC 4.4's alloc_page()) calling XCNEWVEC instead of XNEWVE

Re: avr: optimizing assignment to a bit field

2009-11-28 Thread Richard Guenther
On Sat, Nov 28, 2009 at 11:43 PM, Shaun Jackman wrote: > When assigning a bool to a single bit of a bitfield located in the > bit-addressable region of memory, better code is produced by >        if (flag) >                bitfield.bit = true; >        else >                bitfield.bit = false; >

avr: optimizing assignment to a bit field

2009-11-28 Thread Shaun Jackman
When assigning a bool to a single bit of a bitfield located in the bit-addressable region of memory, better code is produced by if (flag) bitfield.bit = true; else bitfield.bit = false; than bitfield.bit = flag; I've included a short test and

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Tim Prince
Toon Moene wrote: Toon Moene wrote: Tim Prince wrote: > If you want those, you must request them with -mtune=barcelona. OK, so it is an alignment issue (with -mtune=barcelona): .L6: movups 0(%rbp,%rax), %xmm0 movups (%rbx,%rax), %xmm1 incl%ecx addps %

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Toon Moene
Toon Moene wrote: Tim Prince wrote: > If you want those, you must request them with -mtune=barcelona. OK, so it is an alignment issue (with -mtune=barcelona): .L6: movups 0(%rbp,%rax), %xmm0 movups (%rbx,%rax), %xmm1 incl%ecx addps %xmm1, %xmm0

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Toon Moene
Tim Prince wrote: > If you want those, you must request them with -mtune=barcelona. OK, so it is an alignment issue (with -mtune=barcelona): .L6: movups 0(%rbp,%rax), %xmm0 movups (%rbx,%rax), %xmm1 incl%ecx addps %xmm1, %xmm0 movaps %xmm0, (%r8,

Re: i370 port - music/sp - possible generic gcc problem

2009-11-28 Thread Richard Guenther
On Sat, Nov 28, 2009 at 5:35 PM, Paul Edwards wrote: >>> Anyway, I tracked down the particular malloc() which gave changed >>> behaviour depending on whether the malloc() did a memory initialization >>> to NULs or not. > >> Well, GC hands out non-zeroed memory - the callers are responsible >> for

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Richard Guenther
On Sat, Nov 28, 2009 at 5:31 PM, Tim Prince wrote: > Richard Guenther wrote: >> >> On Sat, Nov 28, 2009 at 4:26 PM, Tim Prince wrote: >>> >>> Toon Moene wrote: H.J. Lu wrote: > > On Sat, Nov 28, 2009 at 3:21 AM, Toon Moene wrote: >> >> L.S., >> >> Due to the dis

Re: i370 port - music/sp - possible generic gcc problem

2009-11-28 Thread Paul Edwards
Anyway, I tracked down the particular malloc() which gave changed behaviour depending on whether the malloc() did a memory initialization to NULs or not. Well, GC hands out non-zeroed memory - the callers are responsible for initializing it. So the fix below is not a fix but papering over an i

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Tim Prince
Richard Guenther wrote: On Sat, Nov 28, 2009 at 4:26 PM, Tim Prince wrote: Toon Moene wrote: H.J. Lu wrote: On Sat, Nov 28, 2009 at 3:21 AM, Toon Moene wrote: L.S., Due to the discussion on register allocation, I went back to a hobby of mine: Studying the assembly output of the compiler.

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Richard Guenther
On Sat, Nov 28, 2009 at 4:26 PM, Tim Prince wrote: > Toon Moene wrote: >> >> H.J. Lu wrote: >>> >>> On Sat, Nov 28, 2009 at 3:21 AM, Toon Moene wrote: L.S., Due to the discussion on register allocation, I went back to a hobby of mine: Studying the assembly output of the c

Re: i370 port - music/sp - possible generic gcc problem

2009-11-28 Thread Richard Guenther
On Sat, Nov 28, 2009 at 4:13 PM, Paul Edwards wrote: > I think I have found a bug in gcc, that still exists in gcc 4.4 > > I found the problem on 3.2.3 though. > > While MVS and VM have basically been working fine, when I did > the port to MUSIC/SP I started getting strange compilation failures. >

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Tim Prince
Toon Moene wrote: H.J. Lu wrote: On Sat, Nov 28, 2009 at 3:21 AM, Toon Moene wrote: L.S., Due to the discussion on register allocation, I went back to a hobby of mine: Studying the assembly output of the compiler. For this Fortran subroutine (note: unless otherwise told to the Fortran front

i370 port - music/sp - possible generic gcc problem

2009-11-28 Thread Paul Edwards
I think I have found a bug in gcc, that still exists in gcc 4.4 I found the problem on 3.2.3 though. While MVS and VM have basically been working fine, when I did the port to MUSIC/SP I started getting strange compilation failures. Initializing the stack to NULs made the problem go away, but I

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Toon Moene
H.J. Lu wrote: On Sat, Nov 28, 2009 at 3:21 AM, Toon Moene wrote: L.S., Due to the discussion on register allocation, I went back to a hobby of mine: Studying the assembly output of the compiler. For this Fortran subroutine (note: unless otherwise told to the Fortran front end, reals are 32 b

Re: On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread H.J. Lu
On Sat, Nov 28, 2009 at 3:21 AM, Toon Moene wrote: > L.S., > > Due to the discussion on register allocation, I went back to a hobby of > mine: Studying the assembly output of the compiler. > > For this Fortran subroutine (note: unless otherwise told to the Fortran > front end, reals are 32 bit flo

On the x86_64, does one have to zero a vector register before filling it completely ?

2009-11-28 Thread Toon Moene
L.S., Due to the discussion on register allocation, I went back to a hobby of mine: Studying the assembly output of the compiler. For this Fortran subroutine (note: unless otherwise told to the Fortran front end, reals are 32 bit floating point numbers): subroutine sum(a, b, c, n)