public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/34067]  New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
@ 2007-11-11 19:09 dominiq at lps dot ens dot fr
  2007-11-11 22:30 ` [Bug fortran/34067] " fxcoudert at gcc dot gnu dot org
                   ` (26 more replies)
  0 siblings, 27 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-11 19:09 UTC (permalink / raw)
  To: gcc-bugs

With revision 130081 the following tests fail:

FAIL: gfortran.dg/char_cshift_2.f90  -O3 -fomit-frame-pointer -funroll-loops 
execution test
FAIL: gfortran.dg/char_cshift_2.f90  -O3 -fomit-frame-pointer
-funroll-all-loops -finline-functions  execution test
FAIL: gfortran.dg/char_eoshift_2.f90  -O3 -fomit-frame-pointer -funroll-loops 
execution test
FAIL: gfortran.dg/char_eoshift_2.f90  -O3 -fomit-frame-pointer
-funroll-all-loops -finline-functions  execution test
FAIL: gfortran.dg/char_eoshift_4.f90  -O3 -fomit-frame-pointer -funroll-loops 
execution test
FAIL: gfortran.dg/char_eoshift_4.f90  -O3 -fomit-frame-pointer
-funroll-all-loops -finline-functions  execution test

They passed with revision 130037. 

I have looked at char_cshift_2.f90. It fails on the fourth test (shift array of
kind=8) and the failure requires one of the test with shift2 or shift3 (if I
comment the two calls, the failure disappears).


-- 
           Summary: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-
                    loops fails on Intel Darwin
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dominiq at lps dot ens dot fr
 GCC build triplet: i686-apple-darwin8
  GCC host triplet: i686-apple-darwin8
GCC target triplet: i686-apple-darwin8


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug fortran/34067] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
@ 2007-11-11 22:30 ` fxcoudert at gcc dot gnu dot org
  2007-11-12 10:22 ` dominiq at lps dot ens dot fr
                   ` (25 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2007-11-11 22:30 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from fxcoudert at gcc dot gnu dot org  2007-11-11 22:30 -------
There's only one non-trivial Fortran change in the 130037-130081 range: it's
rev. 130072. I don't see how it could be realted, but if you could revert this
patch and confirm, then it's probably an optimizer problem. The possible
culprits are: 130071 (probably not), 130069, 130067, 130052, 130050, 130045,
130043, 130042, 130041, 130040, 130039. Most of them are unlikely, but that's
the complete list for a reghunt :)


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |fxcoudert at gcc dot gnu dot
                   |                            |org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug fortran/34067] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
  2007-11-11 22:30 ` [Bug fortran/34067] " fxcoudert at gcc dot gnu dot org
@ 2007-11-12 10:22 ` dominiq at lps dot ens dot fr
  2007-11-12 10:27 ` fxcoudert at gcc dot gnu dot org
                   ` (24 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-12 10:22 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from dominiq at lps dot ens dot fr  2007-11-12 10:22 -------
Looking at the test results, the failures seem to happen only on a Core2Duo
Darwin8 (may be only my build). They require both -O(2-3) and
-funroll(-all)-loops. I have also compared the results of -fdump-tree-optimized
with -O2 -funroll-loops and with

-O1 -funroll-loops -ftree-pre -ftree-vrp -fschedule-insns -fschedule-insns2
-fstrict-aliasing -fgcse --param max-aliased-vops=500 -fgcse-lm -falign-loops
-falign-jumps -falign-functions -fregmove -freorder-blocks -freorder-functions
-frerun-cse-after-loop -fsched-interblock -fsched-spec -fthread-jumps
-fcse-follow-jumps -fcse-skip-blocks -foptimize-sibling-calls -fpeephole2
-fexpensive-optimizations -fdelete-null-pointer-checks -fstrict-overflow
-fcrossjumping -fcaller-saves -falign-labels

(according the manual the later (no abort) should be equivalent to the former
(abort), but is not) and there is no difference. However the assembly codes are
quite differents.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug fortran/34067] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
  2007-11-11 22:30 ` [Bug fortran/34067] " fxcoudert at gcc dot gnu dot org
  2007-11-12 10:22 ` dominiq at lps dot ens dot fr
@ 2007-11-12 10:27 ` fxcoudert at gcc dot gnu dot org
  2007-11-12 16:33 ` dominiq at lps dot ens dot fr
                   ` (23 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2007-11-12 10:27 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from fxcoudert at gcc dot gnu dot org  2007-11-12 10:27 -------
(In reply to comment #2)
> according the manual the later (no abort) should be equivalent to the former
> (abort), but is not

The manual only says "-On turns on the following optimization flags", but it
does a few other things that are not controlled by individual -f flags.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug fortran/34067] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (2 preceding siblings ...)
  2007-11-12 10:27 ` fxcoudert at gcc dot gnu dot org
@ 2007-11-12 16:33 ` dominiq at lps dot ens dot fr
  2007-11-12 22:23 ` [Bug fortran/34067] [4.3 regression] " dominiq at lps dot ens dot fr
                   ` (22 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-12 16:33 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from dominiq at lps dot ens dot fr  2007-11-12 16:33 -------
> The manual only says "-On turns on the following optimization flags", but it
> does a few other things that are not controlled by individual -f flags.

At least it seems to do the same thing up to -fdump-tree-optimized. So the
problem appears from here to the assembly code!-(I won't comment about the
missing controls after ~30 flags;-).

Note that the failures disappear with -m64 (missing/bad conversion).

> The possible culprits are: 130071 (probably not), 130069, 130067, 130052, 130050, 130045,
> 130043, 130042, 130041, 130040, 130039.

I have reverted revisions 130039, 130045, 130067, and 130072, and I have also
done a clean bootstrap without changes.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug fortran/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (3 preceding siblings ...)
  2007-11-12 16:33 ` dominiq at lps dot ens dot fr
@ 2007-11-12 22:23 ` dominiq at lps dot ens dot fr
  2007-11-12 22:29 ` [Bug target/34067] " pinskia at gcc dot gnu dot org
                   ` (21 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-12 22:23 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from dominiq at lps dot ens dot fr  2007-11-12 22:23 -------
The regression was caused by revision 130043:

        PR rtl-optimization/34012
        * fwprop.c (try_fwprop_subst): Do not replace if the new
        SET_SRC has a higher cost than the old one.

        * gcc.target/i386/pr34012.c: New test.

If I revert it, the failures disappear.


-- 

dominiq at lps dot ens dot fr changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (4 preceding siblings ...)
  2007-11-12 22:23 ` [Bug fortran/34067] [4.3 regression] " dominiq at lps dot ens dot fr
@ 2007-11-12 22:29 ` pinskia at gcc dot gnu dot org
  2007-11-13  7:36 ` jakub at gcc dot gnu dot org
                   ` (20 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-11-12 22:29 UTC (permalink / raw)
  To: gcc-bugs



-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pinskia at gcc dot gnu dot
                   |                            |org
          Component|fortran                     |target
   Target Milestone|---                         |4.3.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (5 preceding siblings ...)
  2007-11-12 22:29 ` [Bug target/34067] " pinskia at gcc dot gnu dot org
@ 2007-11-13  7:36 ` jakub at gcc dot gnu dot org
  2007-11-13  8:01 ` dominiq at lps dot ens dot fr
                   ` (19 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: jakub at gcc dot gnu dot org @ 2007-11-13  7:36 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from jakub at gcc dot gnu dot org  2007-11-13 07:35 -------
I certainly can't reproduce this on x86_64-linux (with neither -m32 nor -m64).
Can you please attach the good and bad char_cshift_2.s, and the from the
debugger
which field of the array caused the abort and maybe even good and bad
char_cshift_2.*.fwprop* dumps?  Can you hit breakpoint on
_gfortran_cshift1_4_char and _gfortran_cshift1_8_char and compare the incoming
and outgoing arrays between a good and bad version?
I will try to cross-compile this, but as I have no idea what to look for, it
might be a challenge.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (6 preceding siblings ...)
  2007-11-13  7:36 ` jakub at gcc dot gnu dot org
@ 2007-11-13  8:01 ` dominiq at lps dot ens dot fr
  2007-11-13  8:02 ` dominiq at lps dot ens dot fr
                   ` (18 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13  8:01 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from dominiq at lps dot ens dot fr  2007-11-13 08:01 -------
Created an attachment (id=14539)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14539&action=view)
"Good" assembly code.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (7 preceding siblings ...)
  2007-11-13  8:01 ` dominiq at lps dot ens dot fr
@ 2007-11-13  8:02 ` dominiq at lps dot ens dot fr
  2007-11-13  8:10 ` dominiq at lps dot ens dot fr
                   ` (17 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13  8:02 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from dominiq at lps dot ens dot fr  2007-11-13 08:02 -------
Created an attachment (id=14540)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14540&action=view)
"Bad" assembly code.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (8 preceding siblings ...)
  2007-11-13  8:02 ` dominiq at lps dot ens dot fr
@ 2007-11-13  8:10 ` dominiq at lps dot ens dot fr
  2007-11-13  8:16 ` bonzini at gnu dot org
                   ` (16 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13  8:10 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #9 from dominiq at lps dot ens dot fr  2007-11-13 08:10 -------
> and the from the debugger which field of the array caused the abort and maybe even good 
> and bad char_cshift_2.*.fwprop* dumps?  Can you hit breakpoint on _gfortran_cshift1_4_char 
> and _gfortran_cshift1_8_char and compare the incoming and outgoing arrays between a good 
> and bad version?

This will take a little more time (I have to restore the revision and rebuild
gcc). I have printed the
arrays a and b, and with shift4 the first 4 lines, i.e., b(:,1:2,1) is
different from the corresponding a's.

Do you know the important differences in the config files for Darwin8 and
Linux?


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (9 preceding siblings ...)
  2007-11-13  8:10 ` dominiq at lps dot ens dot fr
@ 2007-11-13  8:16 ` bonzini at gnu dot org
  2007-11-13  8:21 ` bonzini at gnu dot org
                   ` (15 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: bonzini at gnu dot org @ 2007-11-13  8:16 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #10 from bonzini at gnu dot org  2007-11-13 08:16 -------
Anyway, it looks like a latent bug somewhere else.


-- 

bonzini at gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bonzini at gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (10 preceding siblings ...)
  2007-11-13  8:16 ` bonzini at gnu dot org
@ 2007-11-13  8:21 ` bonzini at gnu dot org
  2007-11-13  8:43 ` dominiq at lps dot ens dot fr
                   ` (14 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: bonzini at gnu dot org @ 2007-11-13  8:21 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #11 from bonzini at gnu dot org  2007-11-13 08:21 -------
Since you are at it, could you test on *exactly* the involved revisions, i.e.
130042 and 130043?


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (11 preceding siblings ...)
  2007-11-13  8:21 ` bonzini at gnu dot org
@ 2007-11-13  8:43 ` dominiq at lps dot ens dot fr
  2007-11-13 10:40 ` dominiq at lps dot ens dot fr
                   ` (13 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13  8:43 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #12 from dominiq at lps dot ens dot fr  2007-11-13 08:42 -------
Subject: Re:  [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3
-funroll-loops fails on Intel Darwin

> Since you are at it, could you test on *exactly* the involved revisions, i.e.
> 130042 and 130043?

Yes, but allow for more time!-)

Meanwhile, I have restored the changes of revision 130043 and the bug did not
reappeared, wierd!-(


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (12 preceding siblings ...)
  2007-11-13  8:43 ` dominiq at lps dot ens dot fr
@ 2007-11-13 10:40 ` dominiq at lps dot ens dot fr
  2007-11-13 10:41 ` dominiq at lps dot ens dot fr
                   ` (12 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13 10:40 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #13 from dominiq at lps dot ens dot fr  2007-11-13 10:40 -------
Created an attachment (id=14542)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14542&action=view)
Comparison between revisions 130042 and 130043 with -O2 -funroll-loops and with
-O1+all the others

bzip2 tar archive with four directories r42_O1, r42_O2, r43_O1, and r43_O2
containing the result of -fdump-tree-all and the assembly codes for the
different revisions and options (see comment #2).


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (13 preceding siblings ...)
  2007-11-13 10:40 ` dominiq at lps dot ens dot fr
@ 2007-11-13 10:41 ` dominiq at lps dot ens dot fr
  2007-11-13 11:43 ` paolo dot bonzini at lu dot unisi dot ch
                   ` (11 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13 10:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #14 from dominiq at lps dot ens dot fr  2007-11-13 10:41 -------
Could you try to "compile" the assembly code in r43_O2 and see if you get the
abort?


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (14 preceding siblings ...)
  2007-11-13 10:41 ` dominiq at lps dot ens dot fr
@ 2007-11-13 11:43 ` paolo dot bonzini at lu dot unisi dot ch
  2007-11-13 13:19 ` dominiq at lps dot ens dot fr
                   ` (10 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: paolo dot bonzini at lu dot unisi dot ch @ 2007-11-13 11:43 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #15 from paolo dot bonzini at lu dot unisi dot ch  2007-11-13 11:43 -------
Subject: Re:  [4.3 regression] gfortran.dg/char_cshift_2.f90
 fails with -O3 -funroll-loops fails on Intel Darwin


> bzip2 tar archive with four directories r42_O1, r42_O2, r43_O1, and r43_O2
> containing the result of -fdump-tree-all and the assembly codes for the
> different revisions and options (see comment #2).

Please use -fdump-rtl-all since fwprop is not a tree pass. :-)

Also, please check if the bug appears disappears with

-O2 -fno-forward-propagate -funroll-loops

versus

-O2 -funroll-loops

in both 130042 and 130043.  If the -fno-forward-propagate would make a 
difference, this would be a great way to narrow the bug.

Paolo


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (15 preceding siblings ...)
  2007-11-13 11:43 ` paolo dot bonzini at lu dot unisi dot ch
@ 2007-11-13 13:19 ` dominiq at lps dot ens dot fr
  2007-11-13 13:46 ` dominiq at lps dot ens dot fr
                   ` (9 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13 13:19 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #16 from dominiq at lps dot ens dot fr  2007-11-13 13:18 -------
> Also, please check if the bug appears disappears with

> -O2 -fno-forward-propagate -funroll-loops

It disappears with -fno-forward-propagate (rev 130043).


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (16 preceding siblings ...)
  2007-11-13 13:19 ` dominiq at lps dot ens dot fr
@ 2007-11-13 13:46 ` dominiq at lps dot ens dot fr
  2007-11-13 15:58 ` dominiq at lps dot ens dot fr
                   ` (8 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13 13:46 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #17 from dominiq at lps dot ens dot fr  2007-11-13 13:46 -------
Created an attachment (id=14543)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14543&action=view)
outputs with -fdump-rtl-all

outputs with -fdump-rtl-all with -O2 -funroll-loops for revisions 130042 and
130043.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (17 preceding siblings ...)
  2007-11-13 13:46 ` dominiq at lps dot ens dot fr
@ 2007-11-13 15:58 ` dominiq at lps dot ens dot fr
  2007-11-13 16:46 ` paolo dot bonzini at lu dot unisi dot ch
                   ` (7 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13 15:58 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #18 from dominiq at lps dot ens dot fr  2007-11-13 15:58 -------
At revision 130137 the minimal flags are:

[ibook-dhum] f90/bug% gfc -O1 -funroll-loops -fschedule-insns -fregmove
-fexpensive-optimizations -fforward-propagate
char_cshift_2_red_1.f90[ibook-dhum] f90/bug% a.out
 test 2
 'adf'  'acf'  'adf'           1           1           2           1
 'bdf'  'bcf'  'bdf'           2           1           2           1
 'aef'  'adf'  'aef'           1           2           3           1
 'bef'  'bdf'  'bef'           2           2           3           1
 'acf'  'aef'  'acf'           1           3           1           1
 'bcf'  'bef'  'bcf'           2           3           1           1
Abort
[ibook-dhum] f90/bug% gfc -O1 -funroll-loops -fregmove
-fexpensive-optimizations -fforward-propagate char_cshift_2_red_1.f90
[ibook-dhum] f90/bug% a.out
 test 2
 'bdf'  'bcf'  'bdf'           2           1           2           1
 'bef'  'bdf'  'bef'           2           2           3           1
 'bcf'  'bef'  'bcf'           2           3           1           1
Abort

where the printed lines come from

             print *, "'", a (i1, i2p, i3), "'  '", b (i1, i2, i3), "'  '", b
(i1, i2p, i3), "'", i1, i2, i2p, i3


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (18 preceding siblings ...)
  2007-11-13 15:58 ` dominiq at lps dot ens dot fr
@ 2007-11-13 16:46 ` paolo dot bonzini at lu dot unisi dot ch
  2007-11-13 16:59 ` dominiq at lps dot ens dot fr
                   ` (6 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: paolo dot bonzini at lu dot unisi dot ch @ 2007-11-13 16:46 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #19 from paolo dot bonzini at lu dot unisi dot ch  2007-11-13 16:46 -------
Subject: Re:  [4.3 regression] gfortran.dg/char_cshift_2.f90
 fails with -O3 -funroll-loops fails on Intel Darwin


> [ibook-dhum] f90/bug% gfc -O1 -funroll-loops -fschedule-insns -fregmove
> -fexpensive-optimizations -fforward-propagate
> char_cshift_2_red_1.f90[ibook-dhum] f90/bug% a.out
>  test 2
>  'adf'  'acf'  'adf'           1           1           2           1
>  'bdf'  'bcf'  'bdf'           2           1           2           1
>  'aef'  'adf'  'aef'           1           2           3           1
>  'bef'  'bdf'  'bef'           2           2           3           1
>  'acf'  'aef'  'acf'           1           3           1           1
>  'bcf'  'bef'  'bcf'           2           3           1           1
> Abort
> [ibook-dhum] f90/bug% gfc -O1 -funroll-loops -fregmove
> -fexpensive-optimizations -fforward-propagate char_cshift_2_red_1.f90
> [ibook-dhum] f90/bug% a.out
>  test 2
>  'bdf'  'bcf'  'bdf'           2           1           2           1
>  'bef'  'bdf'  'bef'           2           2           3           1
>  'bcf'  'bef'  'bcf'           2           3           1           1
> Abort

Can you attach a -fdump-rtl-all tarball for these two sets of options 
for revision 130137?  Thanks!

Paolo


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (19 preceding siblings ...)
  2007-11-13 16:46 ` paolo dot bonzini at lu dot unisi dot ch
@ 2007-11-13 16:59 ` dominiq at lps dot ens dot fr
  2007-11-14 11:04 ` bonzini at gnu dot org
                   ` (5 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-13 16:59 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #20 from dominiq at lps dot ens dot fr  2007-11-13 16:59 -------
Created an attachment (id=14544)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14544&action=view)
outputs of -fdump-rtl-all for two set of options at -O1

The folder r137_O1_insns corresponds to -fschedule-insns. I have also added the
modified test whith printing.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (20 preceding siblings ...)
  2007-11-13 16:59 ` dominiq at lps dot ens dot fr
@ 2007-11-14 11:04 ` bonzini at gnu dot org
  2007-11-14 12:05 ` dominiq at lps dot ens dot fr
                   ` (4 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: bonzini at gnu dot org @ 2007-11-14 11:04 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #21 from bonzini at gnu dot org  2007-11-14 11:04 -------
I am not following you.  Why do both executions abort?  We don't want to find
two different wrong-code bugs, but to compare one correct and one wrong
execution.  Also, it would be okay to have no output as long as we can clearly
identify the comparison in the RTL dumps.

Does the bug show up if you do something like this?

          if (b (i1, i2, i3) .ne. a (i1, i2p, i3)) then
             call abort()
          end if

Also, it is not important to have a minimal set of dumps. 

Anyway, all this said, I *think* the char_cshift_rtl.tar.bz2 file should be ok.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (21 preceding siblings ...)
  2007-11-14 11:04 ` bonzini at gnu dot org
@ 2007-11-14 12:05 ` dominiq at lps dot ens dot fr
  2007-11-14 12:12 ` bonzini at gnu dot org
                   ` (3 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-14 12:05 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #22 from dominiq at lps dot ens dot fr  2007-11-14 12:05 -------
> Does the bug show up if you do something like this?

Yes, indeed! Otherwise I would not have noticed the bug (one pitfall of the
testsuite is that you know that a test has failed, but you don't kseldom know
why). I have added the modified code for completness because its output depends
of the -O1+options, but basically it does the same thing as the original code
modulo the print and the fact that it records all the failures and not the
first one.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (22 preceding siblings ...)
  2007-11-14 12:05 ` dominiq at lps dot ens dot fr
@ 2007-11-14 12:12 ` bonzini at gnu dot org
  2007-11-14 12:50 ` dominiq at lps dot ens dot fr
                   ` (2 subsequent siblings)
  26 siblings, 0 replies; 28+ messages in thread
From: bonzini at gnu dot org @ 2007-11-14 12:12 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #23 from bonzini at gnu dot org  2007-11-14 12:12 -------
Created an attachment (id=14553)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14553&action=view)
patch to test

I had this alternative patch to fix the addr-sel-1.c failure on
i686-pc-linux-gnu.  Could you check if it fixes this bug too?


-- 

bonzini at gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |bonzini at gnu dot org
                   |dot org                     |
             Status|UNCONFIRMED                 |ASSIGNED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (23 preceding siblings ...)
  2007-11-14 12:12 ` bonzini at gnu dot org
@ 2007-11-14 12:50 ` dominiq at lps dot ens dot fr
  2007-11-14 13:25 ` paolo dot bonzini at lu dot unisi dot ch
  2007-11-19  9:04 ` steven at gcc dot gnu dot org
  26 siblings, 0 replies; 28+ messages in thread
From: dominiq at lps dot ens dot fr @ 2007-11-14 12:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #24 from dominiq at lps dot ens dot fr  2007-11-14 12:50 -------
> I had this alternative patch to fix the addr-sel-1.c failure on
> i686-pc-linux-gnu.  Could you check if it fixes this bug too?

Yes, it does. Thanks a lot for the quick fix.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (24 preceding siblings ...)
  2007-11-14 12:50 ` dominiq at lps dot ens dot fr
@ 2007-11-14 13:25 ` paolo dot bonzini at lu dot unisi dot ch
  2007-11-19  9:04 ` steven at gcc dot gnu dot org
  26 siblings, 0 replies; 28+ messages in thread
From: paolo dot bonzini at lu dot unisi dot ch @ 2007-11-14 13:25 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #25 from paolo dot bonzini at lu dot unisi dot ch  2007-11-14 13:24 -------
Subject: Re:  [4.3 regression] gfortran.dg/char_cshift_2.f90
 fails with -O3 -funroll-loops fails on Intel Darwin


> Yes, it does. Thanks a lot for the quick fix.

Note that even if the patch is committed, the bug should stay open 
because as I said there is probably a latent bug somewhere.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

* [Bug target/34067] [4.3 regression] gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin
  2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
                   ` (25 preceding siblings ...)
  2007-11-14 13:25 ` paolo dot bonzini at lu dot unisi dot ch
@ 2007-11-19  9:04 ` steven at gcc dot gnu dot org
  26 siblings, 0 replies; 28+ messages in thread
From: steven at gcc dot gnu dot org @ 2007-11-19  9:04 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #26 from steven at gcc dot gnu dot org  2007-11-19 09:03 -------
If there is a latent bug, it will show up somewhen and get its own nice bug
report.


-- 

steven at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34067


^ permalink raw reply	[flat|nested] 28+ messages in thread

end of thread, other threads:[~2007-11-19  9:04 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-11-11 19:09 [Bug fortran/34067] New: gfortran.dg/char_cshift_2.f90 fails with -O3 -funroll-loops fails on Intel Darwin dominiq at lps dot ens dot fr
2007-11-11 22:30 ` [Bug fortran/34067] " fxcoudert at gcc dot gnu dot org
2007-11-12 10:22 ` dominiq at lps dot ens dot fr
2007-11-12 10:27 ` fxcoudert at gcc dot gnu dot org
2007-11-12 16:33 ` dominiq at lps dot ens dot fr
2007-11-12 22:23 ` [Bug fortran/34067] [4.3 regression] " dominiq at lps dot ens dot fr
2007-11-12 22:29 ` [Bug target/34067] " pinskia at gcc dot gnu dot org
2007-11-13  7:36 ` jakub at gcc dot gnu dot org
2007-11-13  8:01 ` dominiq at lps dot ens dot fr
2007-11-13  8:02 ` dominiq at lps dot ens dot fr
2007-11-13  8:10 ` dominiq at lps dot ens dot fr
2007-11-13  8:16 ` bonzini at gnu dot org
2007-11-13  8:21 ` bonzini at gnu dot org
2007-11-13  8:43 ` dominiq at lps dot ens dot fr
2007-11-13 10:40 ` dominiq at lps dot ens dot fr
2007-11-13 10:41 ` dominiq at lps dot ens dot fr
2007-11-13 11:43 ` paolo dot bonzini at lu dot unisi dot ch
2007-11-13 13:19 ` dominiq at lps dot ens dot fr
2007-11-13 13:46 ` dominiq at lps dot ens dot fr
2007-11-13 15:58 ` dominiq at lps dot ens dot fr
2007-11-13 16:46 ` paolo dot bonzini at lu dot unisi dot ch
2007-11-13 16:59 ` dominiq at lps dot ens dot fr
2007-11-14 11:04 ` bonzini at gnu dot org
2007-11-14 12:05 ` dominiq at lps dot ens dot fr
2007-11-14 12:12 ` bonzini at gnu dot org
2007-11-14 12:50 ` dominiq at lps dot ens dot fr
2007-11-14 13:25 ` paolo dot bonzini at lu dot unisi dot ch
2007-11-19  9:04 ` steven at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).