public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/32889]  New: ICE in delete_output_reload, at reload1.c:7926
@ 2007-07-25  8:19 b dot gunreben at web dot de
  2007-07-25  8:20 ` [Bug c/32889] " b dot gunreben at web dot de
                   ` (18 more replies)
  0 siblings, 19 replies; 20+ messages in thread
From: b dot gunreben at web dot de @ 2007-07-25  8:19 UTC (permalink / raw)
  To: gcc-bugs

in gcc (GCC) 4.2.1 20070705 (prerelease) (SUSE Linux)

# gcc -c -O2 -fPIC x.i
x.i: In function 'mi_open':
x.i:104: warning: incompatible implicit declaration of built-in function
'strlen'
x.i:111: internal compiler error: in delete_output_reload, at reload1.c:7926

attaching testcase to this bug


-- 
           Summary: ICE in delete_output_reload, at reload1.c:7926
           Product: gcc
           Version: 4.2.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: b dot gunreben at web dot de
  GCC host triplet: hppa2.0-suse-linux
GCC target triplet: hppa2.0-suse-linux


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


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

* [Bug c/32889] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
@ 2007-07-25  8:20 ` b dot gunreben at web dot de
  2007-07-25  8:26 ` b dot gunreben at web dot de
                   ` (17 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: b dot gunreben at web dot de @ 2007-07-25  8:20 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from b dot gunreben at web dot de  2007-07-25 08:20 -------
Created an attachment (id=13971)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=13971&action=view)
testcase x.i


-- 


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


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

* [Bug c/32889] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
  2007-07-25  8:20 ` [Bug c/32889] " b dot gunreben at web dot de
@ 2007-07-25  8:26 ` b dot gunreben at web dot de
  2007-10-09  7:27 ` [Bug target/32889] " debian-gcc at lists dot debian dot org
                   ` (16 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: b dot gunreben at web dot de @ 2007-07-25  8:26 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from b dot gunreben at web dot de  2007-07-25 08:26 -------
just to add some more information:

# gcc -v
Using built-in specs.
Target: hppa2.0-suse-linux
Configured with: ../configure --enable-threads=posix --prefix=/usr
--with-local-prefix=/usr/local --infodir=/usr/share/info
--mandir=/usr/share/man --libdir=/usr/lib --libexecdir=/usr/lib
--enable-languages=c,c++,objc,obj-c++,java --enable-checking=release
--with-gxx-include-dir=/usr/include/c++/4.2.1 --enable-ssp --disable-libssp
--disable-libgcj --with-slibdir=/lib --with-system-zlib --enable-shared
--enable-__cxa_atexit --enable-libstdcxx-allocator=new --disable-libstdcxx-pch
--program-suffix=-4.2 --enable-version-specific-runtime-libs
--without-system-libunwind --host=hppa2.0-suse-linux
Thread model: posix
gcc version 4.2.1 20070705 (prerelease) (SUSE Linux)


-- 


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


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

* [Bug target/32889] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
  2007-07-25  8:20 ` [Bug c/32889] " b dot gunreben at web dot de
  2007-07-25  8:26 ` b dot gunreben at web dot de
@ 2007-10-09  7:27 ` debian-gcc at lists dot debian dot org
  2007-10-19 21:30 ` tbm at cyrius dot com
                   ` (15 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: debian-gcc at lists dot debian dot org @ 2007-10-09  7:27 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from debian-gcc at lists dot debian dot org  2007-10-09 07:27 -------
works with 4.1 and current trunk (not allowed to change anything in this
report)

  Matthias

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=445336
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=444873


-- 


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


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

* [Bug target/32889] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (2 preceding siblings ...)
  2007-10-09  7:27 ` [Bug target/32889] " debian-gcc at lists dot debian dot org
@ 2007-10-19 21:30 ` tbm at cyrius dot com
  2007-10-19 21:31 ` [Bug target/32889] [4.2 Regression] " tbm at gcc dot gnu dot org
                   ` (14 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: tbm at cyrius dot com @ 2007-10-19 21:30 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from tbm at cyrius dot com  2007-10-19 21:29 -------
Adding Dave.


-- 

tbm at cyrius dot com changed:

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


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (3 preceding siblings ...)
  2007-10-19 21:30 ` tbm at cyrius dot com
@ 2007-10-19 21:31 ` tbm at gcc dot gnu dot org
  2007-10-19 21:33 ` tbm at cyrius dot com
                   ` (13 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: tbm at gcc dot gnu dot org @ 2007-10-19 21:31 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from tbm at gcc dot gnu dot org  2007-10-19 21:31 -------
Confirmed.


-- 

tbm at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
           Keywords|                            |ice-on-valid-code
   Last reconfirmed|0000-00-00 00:00:00         |2007-10-19 21:31:13
               date|                            |
            Summary|ICE in delete_output_reload,|[4.2 Regression] ICE in
                   |at reload1.c:7926           |delete_output_reload, at
                   |                            |reload1.c:7926


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (4 preceding siblings ...)
  2007-10-19 21:31 ` [Bug target/32889] [4.2 Regression] " tbm at gcc dot gnu dot org
@ 2007-10-19 21:33 ` tbm at cyrius dot com
  2007-10-19 21:37 ` tbm at cyrius dot com
                   ` (12 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: tbm at cyrius dot com @ 2007-10-19 21:33 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from tbm at cyrius dot com  2007-10-19 21:33 -------
Here's the reduced testcase from delta.  I can try to reduce it further
manually
tomorrow.


typedef unsigned long int ulong;
typedef unsigned int uint;
typedef unsigned char uchar;
typedef unsigned long long int ulonglong;
typedef struct st_mi_state_info
{
  struct
  {
    uchar file_version[4];
    uchar header_length[2];
    uchar base_pos[2];
  }
  header;
  ulong *rec_per_key_part;
}
MI_STATE_INFO;
typedef struct st_mi_base_info
{
  long max_data_file_length;
}
MI_BASE_INFO;
typedef struct st_mi_isam_share
{
  MI_STATE_INFO state;
  MI_BASE_INFO base;
  char *unique_file_name;
  ulong options;
}
MYISAM_SHARE;
extern uchar myisam_file_magic[], myisam_pack_file_magic[];
mi_open (const char *name, int mode, uint open_flags)
{
  int kfile;
  uint base_pos, info_length;
  char name_buff[512], org_name[512], index_name[512], data_name[512];
  char *disk_cache, *disk_pos, *end_pos;
  MYISAM_SHARE share_buff, *share;
  ulong rec_per_key_part[255 * 16];
  long max_key_file_length, max_data_file_length;
  my_realpath (name_buff, fn_format (org_name, name, "", "", 4), (0));
  if (!(test_if_reopen (name_buff)))
    {
      share = &share_buff;
      share_buff.state.rec_per_key_part = rec_per_key_part;
      if ((kfile = my_open (name_buff, 0, (0))) < 0)
        {
        }
      if (memcmp
          ((char *) share->state.header.file_version,
           (char *) myisam_file_magic, 4))
        {
          goto err;
        }
      if (__builtin_strcmp (name_buff, org_name)
          || my_readlink (index_name, org_name))
        __builtin_stpcpy (index_name, org_name);
      info_length =
        (share->state.header.header_length[1]) +
        (share->state.header.header_length[0]);
      base_pos =
        (share->state.header.base_pos)[1] + (share->state.header.base_pos[0]);
      if (disk_cache = __builtin_alloca (128));
      my_seek (kfile, 0, 0, 0);
      if (!(open_flags & 4))
        {
          goto err;
        }
      my_read (kfile, disk_cache);
      mi_state_info_read (base_pos, share->state);
      max_data_file_length =
        (share->options) ? (((ulonglong) 1 << (info_length)) -
                            1) : (mi_safe_mul ((ulonglong) 1 << (info_length))
                                  - 1);
        mi_safe_mul ((ulonglong) 1 << (strlen (index_name)));
      share->base.max_data_file_length = max_data_file_length;
      my_multi_malloc (share->unique_file_name, 1);
    }
err:return (0);
}


-- 


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (5 preceding siblings ...)
  2007-10-19 21:33 ` tbm at cyrius dot com
@ 2007-10-19 21:37 ` tbm at cyrius dot com
  2007-10-19 22:16 ` dave at hiauly1 dot hia dot nrc dot ca
                   ` (11 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: tbm at cyrius dot com @ 2007-10-19 21:37 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from tbm at cyrius dot com  2007-10-19 21:36 -------
Breakpoint 1, fancy_abort (file=0x7c02a8 "gcc-4.2/gcc/reload1.c", line=7932,
    function=0x7c01f0 "delete_output_reload") at gcc-4.2/gcc/diagnostic.c:640
640     {
(gdb) where
#0  fancy_abort (file=0x7c02a8 "gcc-4.2/gcc/reload1.c", line=7932,
    function=0x7c01f0 "delete_output_reload") at gcc-4.2/gcc/diagnostic.c:640
#1  0x0000000000601eac in delete_output_reload (insn=0x2b78f71e4140, j=1,
last_reload_reg=21)
    at gcc-4.2/gcc/reload1.c:7932
#2  0x0000000000602d88 in do_output_reload (chain=0x9d6e30, rl=0x983be8, j=1)
    at gcc-4.2/gcc/reload1.c:7128
#3  0x000000000060352d in emit_reload_insns (chain=0x9d6e30)
    at gcc-4.2/gcc/reload1.c:7229
#4  0x000000000060732f in reload_as_needed (live_known=1)
    at gcc-4.2/gcc/reload1.c:3997
#5  0x000000000060a3cf in reload (first=0x2b78f71bd140, global=1)
    at gcc-4.2/gcc/reload1.c:1082
#6  0x00000000006d4c57 in global_alloc () at gcc-4.2/gcc/global.c:626
#7  0x00000000006d4ec2 in rest_of_handle_global_alloc ()
    at gcc-4.2/gcc/global.c:2514
#8  0x0000000000643678 in execute_one_pass (pass=0x949440)
    at gcc-4.2/gcc/passes.c:881
#9  0x00000000006437dc in execute_pass_list (pass=0x949440)
    at gcc-4.2/gcc/passes.c:932
#10 0x00000000006437ee in execute_pass_list (pass=0x947d00)
    at gcc-4.2/gcc/passes.c:933
#11 0x0000000000465d6e in tree_rest_of_compilation (fndecl=0x2b78f716e2a0)
    at gcc-4.2/gcc/tree-optimize.c:462
#12 0x000000000040b168 in c_expand_body (fndecl=0x2b78f716e2a0)
    at gcc-4.2/gcc/c-decl.c:6835
#13 0x00000000006796b4 in cgraph_expand_function (node=0x2b78f71a9840)
    at gcc-4.2/gcc/cgraphunit.c:1243
#14 0x0000000000679ff5 in cgraph_optimize () at gcc-4.2/gcc/cgraphunit.c:1308
#15 0x000000000040ea72 in c_write_global_declarations ()
    at gcc-4.2/gcc/c-decl.c:7950
#16 0x0000000000625acf in toplev_main (argc=<value optimized out>, argv=<value
optimized out>)
    at gcc-4.2/gcc/toplev.c:1045
#17 0x00002b78f6d014ca in __libc_start_main () from /lib/libc.so.6
#18 0x000000000040273a in _start () at ../sysdeps/x86_64/elf/start.S:113
(gdb)


-- 


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (6 preceding siblings ...)
  2007-10-19 21:37 ` tbm at cyrius dot com
@ 2007-10-19 22:16 ` dave at hiauly1 dot hia dot nrc dot ca
  2007-10-20  6:10 ` tbm at cyrius dot com
                   ` (10 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: dave at hiauly1 dot hia dot nrc dot ca @ 2007-10-19 22:16 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from dave at hiauly1 dot hia dot nrc dot ca  2007-10-19 22:16 -------
Subject: Re:  [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926

> #1  0x0000000000601eac in delete_output_reload (insn=0x2b78f71e4140, j=1,
> last_reload_reg=21)
>     at gcc-4.2/gcc/reload1.c:7932

Would you do the following for the failing assert?
p debug_rtx (insn)
p debug_rtx (i1)
p debug_rtx (substed)

If i1 or substed have been optimized away, you can get at them
in rtx_equal_p as using $r26 and $r25.

It's doubtful there will be a quick fix for this as the problem likely
isn't in the backend.

Dave


-- 


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (7 preceding siblings ...)
  2007-10-19 22:16 ` dave at hiauly1 dot hia dot nrc dot ca
@ 2007-10-20  6:10 ` tbm at cyrius dot com
  2007-10-22  8:45 ` pinskia at gcc dot gnu dot org
                   ` (9 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: tbm at cyrius dot com @ 2007-10-20  6:10 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #9 from tbm at cyrius dot com  2007-10-20 06:10 -------
(In reply to comment #8)
> Would you do the following for the failing assert?
> p debug_rtx (insn)
> p debug_rtx (i1)
> p debug_rtx (substed)

Breakpoint 3, delete_output_reload (insn=0x2ab2d757c140, j=1,
last_reload_reg=21)
    at /home/tbm/scratch/gcc-4.2/gcc/reload1.c:7932
7932          gcc_assert (!rtx_equal_p (XEXP (i1, 0), substed));
(gdb) p debug_rtx (insn)
(insn 73 78 76 5 (set (mem/c:SI (plus:SI (reg/f:SI 3 %r3)
                (const_int 17888 [0x45e0])) [19 S4 A32])
        (plus:SI (reg/f:SI 3 %r3)
            (const_int 1056 [0x420]))) 114 {addsi3} (nil)
    (expr_list:REG_EQUIV (plus:SI (reg/f:SI 3 %r3)
            (const_int 1056 [0x420]))
        (nil)))
$1 = void
(gdb) p debug_rtx (i1)
(expr_list:REG_EQUIV (mem/c:SI (plus:SI (reg/f:SI 3 %r3)
            (const_int 17888 [0x45e0])) [19 S4 A32])
    (nil))
$2 = void
(gdb) p debug_rtx (substed)
(mem/c:SI (plus:SI (reg/f:SI 3 %r3)
        (const_int 17888 [0x45e0])) [19 S4 A32])
$3 = void
(gdb)


-- 


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (8 preceding siblings ...)
  2007-10-20  6:10 ` tbm at cyrius dot com
@ 2007-10-22  8:45 ` pinskia at gcc dot gnu dot org
  2007-11-11 16:50 ` [Bug middle-end/32889] " danglin at gcc dot gnu dot org
                   ` (8 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-10-22  8:45 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
   Target Milestone|---                         |4.2.3


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


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

* [Bug middle-end/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (9 preceding siblings ...)
  2007-10-22  8:45 ` pinskia at gcc dot gnu dot org
@ 2007-11-11 16:50 ` danglin at gcc dot gnu dot org
  2007-11-11 23:28 ` danglin at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: danglin at gcc dot gnu dot org @ 2007-11-11 16:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #10 from danglin at gcc dot gnu dot org  2007-11-11 16:49 -------
This is a regression in reload.

(gdb) p debug_rtx (insn)
(insn 73 78 76 5 (set (mem/c:SI (plus:SI (reg/f:SI 3 %r3)
                (const_int 17888 [0x45e0])) [19 S4 A32])
        (plus:SI (reg/f:SI 3 %r3)
            (const_int 1056 [0x420]))) 114 {addsi3} (nil)
    (expr_list:REG_EQUIV (plus:SI (reg/f:SI 3 %r3)
            (const_int 1056 [0x420]))
        (nil)))

The problem is in the handling of the destination of insn 73.  The
constraints for the addsi3 pattern only accept register operands.
The pseudo in the lreg pass has been replaced by a temp which must
be reloaded.

I looked at pa_secondary_reload.  It simply returns NO_REGS for
(mem/c:SI (plus:SI (reg/f:SI 3 %r3) (const_int 17888 [0x45e0]))).
The frame offset in the temp exceeds that which can be handled
in a simple move.  So, an intermediate registers is needed.


-- 

danglin at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|target                      |middle-end


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


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

* [Bug middle-end/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (10 preceding siblings ...)
  2007-11-11 16:50 ` [Bug middle-end/32889] " danglin at gcc dot gnu dot org
@ 2007-11-11 23:28 ` danglin at gcc dot gnu dot org
  2007-11-24 21:58 ` dave at hiauly1 dot hia dot nrc dot ca
                   ` (6 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: danglin at gcc dot gnu dot org @ 2007-11-11 23:28 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #11 from danglin at gcc dot gnu dot org  2007-11-11 23:28 -------
When delete_output_reload is called, we have:

(gdb) p debug_rtx (insn)
(insn 86 91 89 7 (set (mem/c:SI (plus:SI (reg/f:SI 3 %r3)
                (const_int 17900 [0x45ec])) [20 S4 A32])
        (plus:SI (reg/f:SI 3 %r3)
            (const_int 1068 [0x42c]))) 114 {addsi3} (nil)
    (expr_list:REG_EQUIV (plus:SI (reg/f:SI 3 %r3)
            (const_int 1068 [0x42c]))
        (nil)))

(gdb) p debug_rtx (reg_equiv_memory_loc[209])
(mem/c:SI (plus:SI (reg/f:SI 3 %r3)
        (const_int 17900 [0x45ec])) [20 S4 A32])
$20 = void
(gdb) p debug_rtx (reg_equiv_alt_mem_list[209])
(expr_list:REG_EQUIV (mem/c:SI (plus:SI (reg/f:SI 3 %r3)
            (const_int 17900 [0x45ec])) [20 S4 A32])
    (nil))

reg_equiv_memory_loc[209] is assigned to substed.  So, either the
substitution is wrong or reg_equiv_alt_mem_list[209] incorrectly
contains the substituted value.


-- 


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


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

* [Bug middle-end/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (11 preceding siblings ...)
  2007-11-11 23:28 ` danglin at gcc dot gnu dot org
@ 2007-11-24 21:58 ` dave at hiauly1 dot hia dot nrc dot ca
  2007-12-09 18:02 ` danglin at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: dave at hiauly1 dot hia dot nrc dot ca @ 2007-11-24 21:58 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #12 from dave at hiauly1 dot hia dot nrc dot ca  2007-11-24 21:58 -------
Subject: Re:  [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926

This seems to help:

Index: reload1.c
===================================================================
--- reload1.c   (revision 130392)
+++ reload1.c   (working copy)
@@ -7929,8 +7929,8 @@
                                                        NULL_RTX), 0);
   for (i1 = reg_equiv_alt_mem_list [REGNO (reg)]; i1; i1 = XEXP (i1, 1))
     {
-      gcc_assert (!rtx_equal_p (XEXP (i1, 0), substed));
-      n_occurrences += count_occurrences (PATTERN (insn), XEXP (i1, 0), 0);
+      if (!rtx_equal_p (XEXP (i1, 0), substed))
+       n_occurrences += count_occurrences (PATTERN (insn), XEXP (i1, 0), 0);
     }
   if (n_occurrences > n_inherited)
     return;

Dave


-- 


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


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

* [Bug middle-end/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (12 preceding siblings ...)
  2007-11-24 21:58 ` dave at hiauly1 dot hia dot nrc dot ca
@ 2007-12-09 18:02 ` danglin at gcc dot gnu dot org
  2007-12-10  3:17 ` danglin at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: danglin at gcc dot gnu dot org @ 2007-12-09 18:02 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #13 from danglin at gcc dot gnu dot org  2007-12-09 18:02 -------
Subject: Bug 32889

Author: danglin
Date: Sun Dec  9 18:02:08 2007
New Revision: 130725

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=130725
Log:
        PR middle-end/32889
        PR target/34091
        * pa.md: Consolidate HImode and QImode move patterns into one pattern
        each, eliminating floating-point alternatives.
        * pa-protos.h (pa_cannot_change_mode_class, pa_modes_tieable_p):
        Declare functions.
        * pa-64.h (SECONDARY_MEMORY_NEEDED): Define here.
        * pa.c (pa_secondary_reload): Use an intermediate general register
        for copies to/from floating-point register classes.  Simplify code
        SHIFT_REGS class.  Provide additional comments.
        (pa_cannot_change_mode_class, pa_modes_tieable_p): New functions.
        * pa.h (MODES_TIEABLE_P): Use pa_modes_tieable_p.
        (SECONDARY_MEMORY_NEEDED): Delete define.
        (INT14_OK_STRICT): Define.
        (MODE_OK_FOR_SCALED_INDEXING_P): Allow SFmode and DFmode when using
        soft float.
        (MODE_OK_FOR_UNSCALED_INDEXING_P): Likewise.
        (GO_IF_LEGITIMATE_ADDRESS): Use INT14_OK_STRICT in REG+D case for
        SFmode and DFmode.
        (LEGITIMIZE_RELOAD_ADDRESS): Use INT14_OK_STRICT in mask selection.
        Align DImode offsets when generating 64-bit code.
        * pa32-regs.h (VALID_FP_MODE_P): Remove QImode and HImode.
        (CANNOT_CHANGE_MODE_CLASS): Define.
        * pa64-regs.h (VALID_FP_MODE_P): Remove QImode and HImode.
        (CANNOT_CHANGE_MODE_CLASS): Define using pa_cannot_change_mode_class.


Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/config/pa/pa-64.h
    trunk/gcc/config/pa/pa-protos.h
    trunk/gcc/config/pa/pa.c
    trunk/gcc/config/pa/pa.h
    trunk/gcc/config/pa/pa.md
    trunk/gcc/config/pa/pa32-regs.h
    trunk/gcc/config/pa/pa64-regs.h


-- 


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


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

* [Bug middle-end/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (13 preceding siblings ...)
  2007-12-09 18:02 ` danglin at gcc dot gnu dot org
@ 2007-12-10  3:17 ` danglin at gcc dot gnu dot org
  2007-12-10  3:27 ` [Bug target/32889] " danglin at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: danglin at gcc dot gnu dot org @ 2007-12-10  3:17 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #14 from danglin at gcc dot gnu dot org  2007-12-10 03:17 -------
Subject: Bug 32889

Author: danglin
Date: Mon Dec 10 03:17:24 2007
New Revision: 130735

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=130735
Log:
        PR middle-end/32889
        PR target/34091
        * pa.md: Consolidate HImode and QImode move patterns into one pattern
        each, eliminating floating-point alternatives.
        * pa-protos.h (pa_cannot_change_mode_class, pa_modes_tieable_p):
        Declare functions.
        * pa-64.h (SECONDARY_MEMORY_NEEDED): Define here.
        * pa.c (pa_secondary_reload): Use an intermediate general register
        for copies to/from floating-point register classes.  Simplify code
        SHIFT_REGS class.  Provide additional comments.
        (pa_cannot_change_mode_class, pa_modes_tieable_p): New functions.
        * pa.h (MODES_TIEABLE_P): Use pa_modes_tieable_p.
        (SECONDARY_MEMORY_NEEDED): Delete define.
        (INT14_OK_STRICT): Define.
        (MODE_OK_FOR_SCALED_INDEXING_P): Allow SFmode and DFmode when using
        soft float.
        (MODE_OK_FOR_UNSCALED_INDEXING_P): Likewise.
        (GO_IF_LEGITIMATE_ADDRESS): Use INT14_OK_STRICT in REG+D case for
        SFmode and DFmode.
        (LEGITIMIZE_RELOAD_ADDRESS): Use INT14_OK_STRICT in mask selection.
        Align DImode offsets when generating 64-bit code.
        * pa32-regs.h (VALID_FP_MODE_P): Remove QImode and HImode.
        (CANNOT_CHANGE_MODE_CLASS): Define.
        * pa64-regs.h (VALID_FP_MODE_P): Remove QImode and HImode.
        (CANNOT_CHANGE_MODE_CLASS): Define using pa_cannot_change_mode_class.


Modified:
    branches/gcc-4_2-branch/gcc/ChangeLog
    branches/gcc-4_2-branch/gcc/config/pa/pa-64.h
    branches/gcc-4_2-branch/gcc/config/pa/pa-protos.h
    branches/gcc-4_2-branch/gcc/config/pa/pa.c
    branches/gcc-4_2-branch/gcc/config/pa/pa.h
    branches/gcc-4_2-branch/gcc/config/pa/pa.md
    branches/gcc-4_2-branch/gcc/config/pa/pa32-regs.h
    branches/gcc-4_2-branch/gcc/config/pa/pa64-regs.h


-- 


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (14 preceding siblings ...)
  2007-12-10  3:17 ` danglin at gcc dot gnu dot org
@ 2007-12-10  3:27 ` danglin at gcc dot gnu dot org
  2008-02-23 21:19 ` eager at eagercon dot com
                   ` (2 subsequent siblings)
  18 siblings, 0 replies; 20+ messages in thread
From: danglin at gcc dot gnu dot org @ 2007-12-10  3:27 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #15 from danglin at gcc dot gnu dot org  2007-12-10 03:27 -------
Fixed by change.


-- 

danglin at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
          Component|middle-end                  |target
         Resolution|                            |FIXED


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (15 preceding siblings ...)
  2007-12-10  3:27 ` [Bug target/32889] " danglin at gcc dot gnu dot org
@ 2008-02-23 21:19 ` eager at eagercon dot com
  2008-02-23 21:22 ` eager at eagercon dot com
  2008-02-24  1:41 ` dave at hiauly1 dot hia dot nrc dot ca
  18 siblings, 0 replies; 20+ messages in thread
From: eager at eagercon dot com @ 2008-02-23 21:19 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #16 from eager at eagercon dot com  2008-02-23 21:18 -------
Attached is a patch to reload.c which addresses the root cause.


-- 

eager at eagercon dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |eager at eagercon dot com


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (16 preceding siblings ...)
  2008-02-23 21:19 ` eager at eagercon dot com
@ 2008-02-23 21:22 ` eager at eagercon dot com
  2008-02-24  1:41 ` dave at hiauly1 dot hia dot nrc dot ca
  18 siblings, 0 replies; 20+ messages in thread
From: eager at eagercon dot com @ 2008-02-23 21:22 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #17 from eager at eagercon dot com  2008-02-23 21:21 -------
Created an attachment (id=15215)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15215&action=view)
Fix to reload.c


-- 


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


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

* [Bug target/32889] [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926
  2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
                   ` (17 preceding siblings ...)
  2008-02-23 21:22 ` eager at eagercon dot com
@ 2008-02-24  1:41 ` dave at hiauly1 dot hia dot nrc dot ca
  18 siblings, 0 replies; 20+ messages in thread
From: dave at hiauly1 dot hia dot nrc dot ca @ 2008-02-24  1:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #18 from dave at hiauly1 dot hia dot nrc dot ca  2008-02-24 01:41 -------
Subject: Re:  [4.2 Regression] ICE in delete_output_reload, at reload1.c:7926

> ------- Comment #16 from eager at eagercon dot com  2008-02-23 21:18 -------
> Attached is a patch to reload.c which addresses the root cause.

The first hunk was applied previously.  Suggest you submit the rest
to gcc-patches.  Looks close to obvious.

Dave


-- 


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


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

end of thread, other threads:[~2008-02-24  1:41 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-07-25  8:19 [Bug c/32889] New: ICE in delete_output_reload, at reload1.c:7926 b dot gunreben at web dot de
2007-07-25  8:20 ` [Bug c/32889] " b dot gunreben at web dot de
2007-07-25  8:26 ` b dot gunreben at web dot de
2007-10-09  7:27 ` [Bug target/32889] " debian-gcc at lists dot debian dot org
2007-10-19 21:30 ` tbm at cyrius dot com
2007-10-19 21:31 ` [Bug target/32889] [4.2 Regression] " tbm at gcc dot gnu dot org
2007-10-19 21:33 ` tbm at cyrius dot com
2007-10-19 21:37 ` tbm at cyrius dot com
2007-10-19 22:16 ` dave at hiauly1 dot hia dot nrc dot ca
2007-10-20  6:10 ` tbm at cyrius dot com
2007-10-22  8:45 ` pinskia at gcc dot gnu dot org
2007-11-11 16:50 ` [Bug middle-end/32889] " danglin at gcc dot gnu dot org
2007-11-11 23:28 ` danglin at gcc dot gnu dot org
2007-11-24 21:58 ` dave at hiauly1 dot hia dot nrc dot ca
2007-12-09 18:02 ` danglin at gcc dot gnu dot org
2007-12-10  3:17 ` danglin at gcc dot gnu dot org
2007-12-10  3:27 ` [Bug target/32889] " danglin at gcc dot gnu dot org
2008-02-23 21:19 ` eager at eagercon dot com
2008-02-23 21:22 ` eager at eagercon dot com
2008-02-24  1:41 ` dave at hiauly1 dot hia dot nrc dot ca

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).