public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug debug/55193] New: ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659
@ 2012-11-03 16:30 martin.kronbichler at it dot uu.se
  2012-11-03 16:58 ` [Bug debug/55193] " mpolacek at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: martin.kronbichler at it dot uu.se @ 2012-11-03 16:30 UTC (permalink / raw)
  To: gcc-bugs


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

             Bug #: 55193
           Summary: ICE in in simplify_const_unary_operation, at
                    simplify-rtx.c:1659
    Classification: Unclassified
           Product: gcc
           Version: 4.8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: debug
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: martin.kronbichler@it.uu.se


Created attachment 28603
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28603
Delta-reduced test case

With gcc trunk (rev 193123) on x86-64 linux:

$ g++-4.8 -v
Using built-in specs.
COLLECT_GCC=g++-4.8
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-linux-gnu/4.8.0/lto-wrapper
Target: x86_64-linux-gnu
Configured with: ../gcc_trunk/configure --enable-languages=c,c++,fortran
--prefix=/usr/local --program-suffix=-4.8 --enable-shared
--enable-linker-build-id --with-system-zlib --without-included-gettext
--enable-threads=posix --enable-nls --enable-libstdcxx-time=yes
--disable-multilib --enable-plugin --disable-werror --with-tune=corei7-avx
--enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu
--target=x86_64-linux-gnu --with-isl=/usr/local --with-cloog=/usr/local
Thread model: posix
gcc version 4.8.0 20121103 (experimental) (GCC)

I compile the attached test case with command line:

$ g++-4.8 -g -Og testcase2.i -c

which leads to the ICE below. The error only appears with both -Og and -g
specified.


testcase2.i: In function ‘void foo(FEValues&, Tensor&, vector<double>&)’:
testcase2.i:49:7: internal compiler error: in simplify_const_unary_operation,
at simplify-rtx.c:1659
       }
       ^
0x8a7063 simplify_const_unary_operation(rtx_code, machine_mode, rtx_def*,
machine_mode)
    ../../gcc_trunk/gcc/simplify-rtx.c:1659
0x89ddda simplify_unary_operation(rtx_code, machine_mode, rtx_def*,
machine_mode)
    ../../gcc_trunk/gcc/simplify-rtx.c:783
0x698a50 cselib_expand_value_rtx_1
    ../../gcc_trunk/gcc/cselib.c:1826
0x699d6e cselib_expand_value_rtx_cb(rtx_def*, bitmap_head_def*, int, rtx_def*
(*)(rtx_def*, bitmap_head_def*, int, void*), void*)
    ../../gcc_trunk/gcc/cselib.c:1534
0xa27488 vt_expand_var_loc_chain
    ../../gcc_trunk/gcc/var-tracking.c:8063
0xa27488 vt_expand_loc_callback
    ../../gcc_trunk/gcc/var-tracking.c:8225
0x69891f cselib_expand_value_rtx_1
    ../../gcc_trunk/gcc/cselib.c:1687
0x699d6e cselib_expand_value_rtx_cb(rtx_def*, bitmap_head_def*, int, rtx_def*
(*)(rtx_def*, bitmap_head_def*, int, void*), void*)
    ../../gcc_trunk/gcc/cselib.c:1534
0xa27cb7 vt_expand_var_loc_chain
    ../../gcc_trunk/gcc/var-tracking.c:8063
0xa27cb7 vt_expand_1pvar
    ../../gcc_trunk/gcc/var-tracking.c:8340
0xa2832f emit_note_insn_var_location
    ../../gcc_trunk/gcc/var-tracking.c:8394
0xd1da97 htab_traverse_noresize
    ../../gcc_trunk/libiberty/hashtab.c:784
0xa28cd7 emit_notes_for_changes
    ../../gcc_trunk/gcc/var-tracking.c:8757
0xa290c1 emit_notes_in_bb
    ../../gcc_trunk/gcc/var-tracking.c:9187
0xa290c1 vt_emit_notes
    ../../gcc_trunk/gcc/var-tracking.c:9249
0xa29839 variable_tracking_main_1
    ../../gcc_trunk/gcc/var-tracking.c:10068
0xa29839 variable_tracking_main()
    ../../gcc_trunk/gcc/var-tracking.c:10082


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

* [Bug debug/55193] ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659
  2012-11-03 16:30 [Bug debug/55193] New: ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659 martin.kronbichler at it dot uu.se
@ 2012-11-03 16:58 ` mpolacek at gcc dot gnu.org
  2012-12-10 17:45 ` [Bug rtl-optimization/55193] [4.8 Regression] " jakub at gcc dot gnu.org
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: mpolacek at gcc dot gnu.org @ 2012-11-03 16:58 UTC (permalink / raw)
  To: gcc-bugs


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

Marek Polacek <mpolacek at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2012-11-03
                 CC|                            |mpolacek at gcc dot
                   |                            |gnu.org, vmakarov at gcc
                   |                            |dot gnu.org
   Target Milestone|---                         |4.8.0
     Ever Confirmed|0                           |1

--- Comment #1 from Marek Polacek <mpolacek at gcc dot gnu.org> 2012-11-03 16:58:10 UTC ---
Started http://gcc.gnu.org/viewcvs?view=revision&revision=192719


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

* [Bug rtl-optimization/55193] [4.8 Regression] ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659
  2012-11-03 16:30 [Bug debug/55193] New: ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659 martin.kronbichler at it dot uu.se
  2012-11-03 16:58 ` [Bug debug/55193] " mpolacek at gcc dot gnu.org
@ 2012-12-10 17:45 ` jakub at gcc dot gnu.org
  2012-12-10 17:53 ` jakub at gcc dot gnu.org
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-12-10 17:45 UTC (permalink / raw)
  To: gcc-bugs


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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

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

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-12-10 17:44:57 UTC ---
Can't be reproduced starting with
http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=193157
(made latent on this testcase), but if I revert the patch I can reproduce it
easily.
The bug is in lra-constraints.c, loc_equivalence_change_p really doesn't work
well on DEBUG_INSNs.


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

* [Bug rtl-optimization/55193] [4.8 Regression] ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659
  2012-11-03 16:30 [Bug debug/55193] New: ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659 martin.kronbichler at it dot uu.se
  2012-11-03 16:58 ` [Bug debug/55193] " mpolacek at gcc dot gnu.org
  2012-12-10 17:45 ` [Bug rtl-optimization/55193] [4.8 Regression] " jakub at gcc dot gnu.org
@ 2012-12-10 17:53 ` jakub at gcc dot gnu.org
  2012-12-11 18:01 ` jakub at gcc dot gnu.org
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-12-10 17:53 UTC (permalink / raw)
  To: gcc-bugs


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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
         AssignedTo|unassigned at gcc dot       |jakub at gcc dot gnu.org
                   |gnu.org                     |

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-12-10 17:53:01 UTC ---
Created attachment 28915
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28915
gcc48-pr55193.patch

Untested fix.  For changes to DEBUG_INSNs, generally simplify_replace_fn_rtx
is the best thing, it takes care of simplifying everything that is needed, both
for the cases where something changes from non-VOIDmode into VOIDmode (then
simplification is required; e.g. as on this testcase (zero_extend:DI (reg:SI
eax) 0) where eax is replaced by (const_int 0)), and a nice thing to have
otherwise.


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

* [Bug rtl-optimization/55193] [4.8 Regression] ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659
  2012-11-03 16:30 [Bug debug/55193] New: ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659 martin.kronbichler at it dot uu.se
                   ` (2 preceding siblings ...)
  2012-12-10 17:53 ` jakub at gcc dot gnu.org
@ 2012-12-11 18:01 ` jakub at gcc dot gnu.org
  2012-12-11 19:15 ` jakub at gcc dot gnu.org
  2013-01-14 19:36 ` steven at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-12-11 18:01 UTC (permalink / raw)
  To: gcc-bugs


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

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-12-11 18:01:19 UTC ---
Author: jakub
Date: Tue Dec 11 18:01:09 2012
New Revision: 194405

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=194405
Log:
    PR rtl-optimization/55193
    * lra-constraints.c (loc_equivalence_callback): New function.
    (lra_constraints): Call simplify_replace_fn_rtx instead of
    loc_equivalence_change_p on DEBUG_INSNs.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/lra-constraints.c


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

* [Bug rtl-optimization/55193] [4.8 Regression] ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659
  2012-11-03 16:30 [Bug debug/55193] New: ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659 martin.kronbichler at it dot uu.se
                   ` (3 preceding siblings ...)
  2012-12-11 18:01 ` jakub at gcc dot gnu.org
@ 2012-12-11 19:15 ` jakub at gcc dot gnu.org
  2013-01-14 19:36 ` steven at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-12-11 19:15 UTC (permalink / raw)
  To: gcc-bugs


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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

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

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-12-11 19:15:21 UTC ---
Fixed.


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

* [Bug rtl-optimization/55193] [4.8 Regression] ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659
  2012-11-03 16:30 [Bug debug/55193] New: ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659 martin.kronbichler at it dot uu.se
                   ` (4 preceding siblings ...)
  2012-12-11 19:15 ` jakub at gcc dot gnu.org
@ 2013-01-14 19:36 ` steven at gcc dot gnu.org
  5 siblings, 0 replies; 7+ messages in thread
From: steven at gcc dot gnu.org @ 2013-01-14 19:36 UTC (permalink / raw)
  To: gcc-bugs


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

--- Comment #6 from Steven Bosscher <steven at gcc dot gnu.org> 2013-01-14 19:35:10 UTC ---
Author: steven
Date: Mon Jan 14 19:35:03 2013
New Revision: 195173

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=195173
Log:

    * ira-build.c (ira_flattening): Comment fix.

    Port the following LRA changes on trunk back to the LRA branch:

    2013-01-10  Vladimir Makarov  <vmakarov at redhat dot com>

    PR rtl-optimization/pr55672
    * lra-eliminations.c (mark_not_elimnable): Permit addition with
    const to be elimnable.

    2012-12-21  Vladimir Makarov  <vmakarov at redhat dot com>

    PR middle-end/55775
    * lra-assigns.c (improve_inheritance): Do nothing after
    LRA_MAX_INHERITANCE_PASSES pass.
    * lra-constraints.c (MAX_CONSTRAINT_ITERATION_NUMBER): Rename to
    LRA_MAX_CONSTRAINT_ITERATION_NUMBER.  Move to lra-int.h.
    (MAX_INHERITANCE_PASSES): Rename to LRA_MAX_INHERITANCE_PASSES.
    Move to lra-int.h.
    * lra-int.h (LRA_MAX_CONSTRAINT_ITERATION_NUMBER): Move from
    lra-constraints.c.
    (LRA_MAX_INHERITANCE_PASSES): Ditto.

    2012-12-21  Steve Ellcey  <sellcey at mips dot com>

    PR bootstrap/54128
    * ira.c (build_insn_chain): Check only NONDEBUG instructions for
    register usage.

    2012-12-11  Jakub Jelinek  <jakub at redhat dot com>

    PR rtl-optimization/55193
    * lra-constraints.c (loc_equivalence_callback): New function.
    (lra_constraints): Call simplify_replace_fn_rtx instead of
    loc_equivalence_change_p on DEBUG_INSNs.


Modified:
    branches/lra/gcc/ChangeLog
    branches/lra/gcc/ira-build.c
    branches/lra/gcc/ira.c
    branches/lra/gcc/lra-assigns.c
    branches/lra/gcc/lra-constraints.c
    branches/lra/gcc/lra-eliminations.c
    branches/lra/gcc/lra-int.h


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

end of thread, other threads:[~2013-01-14 19:36 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-03 16:30 [Bug debug/55193] New: ICE in in simplify_const_unary_operation, at simplify-rtx.c:1659 martin.kronbichler at it dot uu.se
2012-11-03 16:58 ` [Bug debug/55193] " mpolacek at gcc dot gnu.org
2012-12-10 17:45 ` [Bug rtl-optimization/55193] [4.8 Regression] " jakub at gcc dot gnu.org
2012-12-10 17:53 ` jakub at gcc dot gnu.org
2012-12-11 18:01 ` jakub at gcc dot gnu.org
2012-12-11 19:15 ` jakub at gcc dot gnu.org
2013-01-14 19:36 ` steven at gcc dot gnu.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).