Bug 42050 - [4.5 Regression] ice in graphite-clast-to-gimple.c:165
Summary: [4.5 Regression] ice in graphite-clast-to-gimple.c:165
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: middle-end (show other bugs)
Version: 4.5.0
: P3 normal
Target Milestone: 4.5.0
Assignee: Not yet assigned to anyone
URL:
Keywords: ice-on-valid-code
Depends on:
Blocks:
 
Reported: 2009-11-15 12:39 UTC by Joost VandeVondele
Modified: 2009-11-19 21:12 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Known to work: 4.4.2
Known to fail: 4.5.0
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joost VandeVondele 2009-11-15 12:39:02 UTC
Program received signal SIGSEGV, Segmentation fault.
clast_to_gcc_expression (type=0x7f419f5c4580, e=0x0, region=0x139a9e0, newivs=0x13a47a0, newivs_index=0x13a9b70)
    at /data03/vondele/gcc_trunk/gcc/gcc/graphite-clast-to-gimple.c:165
165       switch (e->type)
(gdb) bt
#0  clast_to_gcc_expression (type=0x7f419f5c4580, e=0x0, region=0x139a9e0, newivs=0x13a47a0, newivs_index=0x13a9b70)
    at /data03/vondele/gcc_trunk/gcc/gcc/graphite-clast-to-gimple.c:165
#1  0x0000000000c43cc5 in translate_clast (region=0x139a9e0, context_loop=0x7f419f4c06c0, stmt=0x13c51d0, next_e=0x7f419f4c4740, rename_map=0x13879f0,
    newivs=0x7fffa9408ef8, newivs_index=0x13a9b70, bb_pbb_mapping=0x139a8c0) at /data03/vondele/gcc_trunk/gcc/gcc/graphite-clast-to-gimple.c:467
#2  0x0000000000c44238 in translate_clast (region=0x139a9e0, context_loop=0x7f419f4c06c0, stmt=0x13c60a0, next_e=0x7f419f4c4280, rename_map=0x13879f0,
    newivs=0x7fffa9408ef8, newivs_index=0x13a9b70, bb_pbb_mapping=0x139a8c0) at /data03/vondele/gcc_trunk/gcc/gcc/graphite-clast-to-gimple.c:679
#3  0x0000000000c4429e in translate_clast (region=0x139a9e0, context_loop=0x7f419f4c06c0, stmt=0x13c6a90, next_e=0x7f419f4c4040, rename_map=0x13879f0,
    newivs=0x7fffa9408ef8, newivs_index=0x13a9b70, bb_pbb_mapping=0x139a8c0) at /data03/vondele/gcc_trunk/gcc/gcc/graphite-clast-to-gimple.c:690
#4  0x0000000000c43c27 in translate_clast (region=0x139a9e0, context_loop=0x7f419f4c06c0, stmt=0x13b0e90, next_e=0x7f419f4c4040, rename_map=0x13879f0,
    newivs=0x7fffa9408ef8, newivs_index=0x13a9b70, bb_pbb_mapping=0x139a8c0) at /data03/vondele/gcc_trunk/gcc/gcc/graphite-clast-to-gimple.c:602
#5  0x0000000000c44c70 in gloog (scop=<value optimized out>, bb_pbb_mapping=0x139a8c0) at /data03/vondele/gcc_trunk/gcc/gcc/graphite-clast-to-gimple.c:1195
#6  0x0000000000c418b5 in graphite_transform_loops () at /data03/vondele/gcc_trunk/gcc/gcc/graphite.c:275
#7  0x00000000008e3c57 in graphite_transforms () at /data03/vondele/gcc_trunk/gcc/gcc/tree-ssa-loop.c:300

compiling :

> cat bug.f90
MODULE qs_ks_methods
  INTEGER, PARAMETER :: sic_list_all=1
  TYPE dft_control_type
     INTEGER :: sic_list_id
  END TYPE
CONTAINS
  SUBROUTINE sic_explicit_orbitals( )
    TYPE(dft_control_type), POINTER          :: dft_control
    INTEGER, ALLOCATABLE, DIMENSION(:, :)    :: sic_orbital_list
    INTEGER, DIMENSION(:), &
      POINTER                                :: mo_derivs
    SELECT CASE(dft_control%sic_list_id)
    CASE(sic_list_all)
      DO i=1,k_alpha
         IF (SIZE(mo_derivs,1)==1) THEN
         ELSE
             sic_orbital_list(3,iorb)=2
         ENDIF
      ENDDO
    END SELECT
    CALL test()
  END SUBROUTINE sic_explicit_orbitals
END MODULE qs_ks_methods

> gfortran -c -fgraphite-identity -O1  -v bug.f90
Using built-in specs.
COLLECT_GCC=gfortran
COLLECT_LTO_WRAPPER=/data03/vondele/gcc_trunk/build/libexec/gcc/x86_64-unknown-linux-gnu/4.5.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: /data03/vondele/gcc_trunk/gcc/configure --disable-bootstrap --prefix=/data03/vondele/gcc_trunk/build --enable-languages=c,c++,fortran --disable-multilib --with-ppl=/data03/vondele/gcc_trunk/build/ --with-cloog=/data03/vondele/gcc_trunk/build/ --with-libelf=/data03/vondele/libelf-0.8.12/build/ --enable-gold --enable-lto --enable-plugins
Thread model: posix
gcc version 4.5.0 20091115 (experimental) [trunk revision 154188] (GCC)
COLLECT_GCC_OPTIONS='-c' '-fgraphite-identity' '-O1' '-v' '-mtune=generic'
 /data03/vondele/gcc_trunk/build/libexec/gcc/x86_64-unknown-linux-gnu/4.5.0/f951 bug.f90 -quiet -dumpbase bug.f90 -mtune=generic -auxbase bug -O1 -version -fgraphite-identity -fintrinsic-modules-path /data03/vondele/gcc_trunk/build/lib/gcc/x86_64-unknown-linux-gnu/4.5.0/finclude -o /tmp/cc58n9IM.s
GNU Fortran (GCC) version 4.5.0 20091115 (experimental) [trunk revision 154188] (x86_64-unknown-linux-gnu)
        compiled by GNU C version 4.3.1 20080507 (prerelease) [gcc-4_3-branch revision 135036], GMP version 4.2.4, MPFR version 2.4.1, MPC version 0.8
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
GNU Fortran (GCC) version 4.5.0 20091115 (experimental) [trunk revision 154188] (x86_64-unknown-linux-gnu)
        compiled by GNU C version 4.3.1 20080507 (prerelease) [gcc-4_3-branch revision 135036], GMP version 4.2.4, MPFR version 2.4.1, MPC version 0.8
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
bug.f90: In function ‘__qs_ks_methods_MOD_sic_explicit_orbitals’:
bug.f90:7:0: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
Comment 1 Joost VandeVondele 2009-11-15 12:40:26 UTC
works on 4.4 branch, fails on 4.5 branch
Comment 2 Sebastian Pop 2009-11-19 21:12:28 UTC
Fixed in the Graphite branch.  The changes of the branch will be pushed into trunk soon.
I will commit the reduced testcase to the Graphite testsuite.

Sebastian
Comment 3 Sebastian Pop 2009-11-19 22:33:07 UTC
Subject: Bug 42050

Author: spop
Date: Thu Nov 19 22:32:44 2009
New Revision: 154347

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=154347
Log:
Testcase for PR42050.

2009-11-18  Sebastian Pop  <sebastian.pop@amd.com>

	PR middle-end/42050
	* testsuite/gfortran.dg/graphite/pr42050.f90: New.

Added:
    branches/graphite/gcc/testsuite/gfortran.dg/graphite/pr42050.f90
Modified:
    branches/graphite/gcc/ChangeLog.graphite

Comment 4 Sebastian Pop 2009-11-25 05:32:17 UTC
Subject: Bug 42050

Author: spop
Date: Wed Nov 25 05:32:03 2009
New Revision: 154640

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=154640
Log:
2009-11-18  Sebastian Pop  <sebastian.pop@amd.com>

	PR middle-end/42050
	* testsuite/gfortran.dg/graphite/pr42050.f90: New.

Modified:
    trunk/gcc/ChangeLog.graphite