[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-06 Thread ubizjak at gmail dot com


--- Comment #15 from ubizjak at gmail dot com  2010-01-06 10:45 ---
Created an attachment (id=19483)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=19483&action=view)
preprocessed source


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-06 Thread ubizjak at gmail dot com


--- Comment #14 from ubizjak at gmail dot com  2010-01-06 10:43 ---
This bug can be now reproduced with a crosscompiler to alpha-linux-gnu with
soon to be attached preprocessed source of tree-ssa-loop-im.i (please note
noinline attributes at determine_max_movement and add_dependency).

The problem is that stage1 (or cross-) compiler miscompiles
determine_max_movement from tree-ssa-loop-im.c, where cse2 rtl pass removes
whole lot of code when -O2 is used.


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread ubizjak at gmail dot com


--- Comment #13 from ubizjak at gmail dot com  2010-01-05 21:15 ---
(In reply to comment #12)

> I will restart bootstrap now.

Bootstraps OK for --enable-languages=c.


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread ubizjak at gmail dot com


--- Comment #12 from ubizjak at gmail dot com  2010-01-05 20:47 ---
Got the problem. stage1 compiler miscompiles determine_max_movement() from
tree-ssa-loop-im.c.

Following patch fixes the testcase from comment #5:

Index: tree-ssa-loop-im.c
===
--- tree-ssa-loop-im.c  (revision 155643)
+++ tree-ssa-loop-im.c  (working copy)
@@ -677,6 +677,7 @@
 level = superloop_at_depth (loop, 1);
   lim_data->max_loop = level;

+  debug_gimple_stmt (stmt);
   FOR_EACH_SSA_TREE_OPERAND (val, stmt, iter, SSA_OP_USE)
 if (!add_dependency (val, lim_data, loop, true))
   return false;

I will restart bootstrap now.


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread ubizjak at gmail dot com


--- Comment #11 from ubizjak at gmail dot com  2010-01-05 16:24 ---
(In reply to comment #10)
> Well, I can't see how this wouldn't be a problem on other targets thus I
> re-iterate: which stages do show this behavior?  Does the stage1 cc1
> reproduce it?

No.


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread rguenth at gcc dot gnu dot org


--- Comment #10 from rguenth at gcc dot gnu dot org  2010-01-05 15:36 
---
Well, I can't see how this wouldn't be a problem on other targets thus I
re-iterate: which stages do show this behavior?  Does the stage1 cc1
reproduce it?


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread ubizjak at gmail dot com


--- Comment #9 from ubizjak at gmail dot com  2010-01-05 14:27 ---
(In reply to comment #7)
> setting BOOT_CFLAGS to -g -O1 lets the build succeed. the testcase from 
> comment
> #5 doesn't ice. 

It will ICE with default build, with checkings enabled.


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread ubizjak at gmail dot com


--- Comment #8 from ubizjak at gmail dot com  2010-01-05 14:21 ---
It looks that tree loop IM FUBARs the compilation.

All testcases compile OK with -O2 -fno-tree-loop-im.

The dump for _.c.099t.lim1 looks quite strange (it resembles _.c.024t.ssa):

--cut here--
;; Function alpha_fallback_frame_state (alpha_fallback_frame_state)



Symbols to be put in SSA form

{ .MEM fs___regfs__I_I__howfs___regfs__I_I_I.3 }


Incremental SSA update started at block: 0

Number of blocks in CFG: 6
Number of blocks to update: 5 ( 83%)




SSA replacement table
N_i -> { O_1 ... O_j } means that N_i replaces O_1, ..., O_j

fs___regfs__I_I__howfs___regfs__I_I_I.3_10 -> {
fs___regfs__I_I__howfs___regfs__I_I_I.3_9 }

Number of virtual NEW -> OLD mappings:   0
Number of real NEW -> OLD mappings:  1
Number of total NEW -> OLD mappings: 1

Number of virtual symbols: 0


Incremental SSA update started at block: 3

Number of blocks in CFG: 6
Number of blocks to update: 2 ( 33%)



alpha_fallback_frame_state (struct _Unwind_FrameState * fs)
{
  int fs___regfs__I_I__howfs___regfs__I_I_I.3;
  long int pretmp.2;
  long int i;
  long int D.2028;

:
  D.2028_3 = i_11 + 32;
  fs___regfs__I_I__howfs___regfs__I_I_I.3_8 = fs_4(D)->reg[D.2028_3].how;

:
  # i_11 = PHI 
  fs___regfs__I_I__howfs___regfs__I_I_I.3_9 = 0;
  i_5 = i_11 + 1;
  if (i_5 <= 30)
goto ;
  else
goto ;

:
  goto ;

:
  # fs___regfs__I_I__howfs___regfs__I_I_I.3_10 = PHI

  fs_4(D)->reg[D.2028_3].how = fs___regfs__I_I__howfs___regfs__I_I_I.3_10;
  return;

}
--cut here--


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread debian-gcc at lists dot debian dot org


--- Comment #7 from debian-gcc at lists dot debian dot org  2010-01-05 
14:16 ---
setting BOOT_CFLAGS to -g -O1 lets the build succeed. the testcase from comment
#5 doesn't ice. test results for this build at
http://gcc.gnu.org/ml/gcc-testresults/2010-01/msg00501.html


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread rguenth at gcc dot gnu dot org


--- Comment #6 from rguenth at gcc dot gnu dot org  2010-01-05 13:53 ---
So, which stages do ICE on the testcase?


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread ubizjak at gmail dot com


--- Comment #5 from ubizjak at gmail dot com  2010-01-05 13:52 ---
Minimized testcase (from other bootstrap failure):

--cut here--
typedef struct
{
  struct
  {
int how;
  } reg[64 + 1];
}
_Unwind_FrameState;

alpha_fallback_frame_state (_Unwind_FrameState * fs)
{
  long i;

  for (i = 0; i < 31; ++i)
fs->reg[i + 32].how = 0;
}
--cut here--

~/gcc-build-test/gcc/cc1 -O2 -quiet t1.c
t1.c: In function ‘alpha_fallback_frame_state’:
t1.c:10:1: error: definition in block 3 does not dominate use in block 2
for SSA_NAME: i_11 in statement:
D.2028_3 = i_11 + 32;
t1.c:10:1: internal compiler error: verify_ssa failed
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.


-- 


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-05 Thread ubizjak at gmail dot com


--- Comment #4 from ubizjak at gmail dot com  2010-01-05 12:29 ---
I got different error in the same place when configured with:

Target: alpha-linux-gnu
Configured with: ../gcc-svn/trunk/configure --host=alpha-linux-gnu
--build=alpha-linux-gnu --target=alpha-linux-gnu --enable-languages=c

~/gcc-build-test/gcc/cc1 -O2 -quiet regex.i
In file included from ../../src/libiberty/regex.c:638:0:
../../src/libiberty/regex.c: In function ‘byte_re_match_2_internal’:
../../src/libiberty/regex.c:5543:1: error: definition in block 8 does not
dominate use in block 7
for SSA_NAME: D.7346_246 in statement:
D.7347_247 = regstart_61 + D.7346_246;
../../src/libiberty/regex.c:5543:1: internal compiler error: verify_ssa failed
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.

This happens with stage2 compiler.


-- 

ubizjak at gmail dot com changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2010-01-05 12:29:58
   date||


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



[Bug bootstrap/42511] bootstrap error in stage3 on alpha-linux-gnu

2010-01-04 Thread debian-gcc at lists dot debian dot org


--- Comment #3 from debian-gcc at lists dot debian dot org  2010-01-04 
17:42 ---
rechecked with 20090104. setting BOOT_CFLAGS to -g -O1 lets the gcc bootstrap
pass.

  Matthias


-- 

debian-gcc at lists dot debian dot org changed:

   What|Removed |Added

   Keywords||wrong-code
Summary|boostrap error in stage3 on |bootstrap error in stage3 on
   |alpha-linux-gnu |alpha-linux-gnu


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