public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/30715]  New: [fortran, 4.3 regression]: ICE in operand_equal_p()
@ 2007-02-06 14:31 martin at mpa-garching dot mpg dot de
  2007-02-06 16:52 ` [Bug fortran/30715] [4.3 regression]: ICE in operand_equal_p() with -O burnus at gcc dot gnu dot org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: martin at mpa-garching dot mpg dot de @ 2007-02-06 14:31 UTC (permalink / raw)
  To: gcc-bugs

Current mainline ICEs on the code below:

module coord_v_convert
  INTEGER, PARAMETER, public :: dp  = SELECTED_REAL_KIND(12,200)

contains

  Subroutine xcc_V_CONVERT(ivector,iepoch,oepoch,isys,osys,ovector)
    real(dp) ::      IVECTOR(1:3)   ! Input coordinate vector
    real(dp) ::      IEPOCH         ! Input epoch
    real(dp) ::      OEPOCH         ! Output epoch        
    real(dp) ::      OVECTOR(1:3)   ! Output coordinate vector
    Character(len=*) ::    ISYS           ! Input system
    Character(len=*) ::    OSYS           ! Output system
    real(dp) ::      XVECTOR(1:3)     ! Temporary coordinate holder
    real(dp) ::      YVECTOR(1:3)     ! Temporary coordinate holder
    Character(len=20) ::    isysu     ! Input system, uppercase
    Character(len=20) ::    osysu     ! Output system, uppercase

    if (trim(isysu) /= 'E') then
       if (trim(isysu) == 'Q' .or. trim(isysu) == 'C') then
          call xcc_dp_q_to_e(ivector,iepoch,xvector)
       elseif (trim(isysu) == 'G') then
          call xcc_dp_g_to_e(ivector,iepoch,xvector)
       endif
    endif

    if (iepoch /= oepoch) then
       call xcc_dp_precess(xvector,iepoch,oepoch,yvector)
    else
       yvector(1:3)=xvector(1:3)
    endif

    if (trim(osysu) /= 'E') then 
       if (trim(osysu) == 'Q' .or. trim(osysu) == 'C') then
          call xcc_dp_e_to_q(yvector,oepoch,ovector)
       elseif (trim(osysu) == 'G') then
          call xcc_dp_e_to_g(yvector,oepoch,ovector)
       endif
    endif
  end subroutine xcc_v_convert
end module coord_v_convert

~/tmp>gfortran -c -O -v coord_v_convert.F90
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with: /scratch/martin/gcc/configure
--prefix=/afs/mpa/data/martin/ugcc --enable-languages=c++,fortran
Thread model: posix
gcc version 4.3.0 20070206 (experimental)
 /afs/mpa/data/martin/ugcc/libexec/gcc/i686-pc-linux-gnu/4.3.0/cc1 -E
-lang-fortran -traditional-cpp -D_LANGUAGE_FORTRAN -quiet -v
coord_v_convert.F90 -mtune=generic -O -o /tmp/ccjN9yGi.f95
ignoring nonexistent directory
"/afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.3.0/../../../../i686-pc-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /afs/mpa/data/martin/ugcc/include
 /afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.3.0/include
 /usr/include
End of search list.
 /afs/mpa/data/martin/ugcc/libexec/gcc/i686-pc-linux-gnu/4.3.0/f951
/tmp/ccjN9yGi.f95 -ffree-form -quiet -dumpbase coord_v_convert.F90
-mtune=generic -auxbase coord_v_convert -O -version -fpreprocessed
-fintrinsic-modules-path
/afs/mpa/data/martin/ugcc/lib/gcc/i686-pc-linux-gnu/4.3.0/finclude -o
/tmp/ccUyuIKr.s
GNU F95 version 4.3.0 20070206 (experimental) (i686-pc-linux-gnu)
        compiled by GNU C version 4.3.0 20070206 (experimental).
GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096
coord_v_convert.F90: In function 'xcc_v_convert':
coord_v_convert.F90:29: internal compiler error: in operand_equal_p, at
fold-const.c:2577

The 4.1 and 4.2 branches compile this properly.


-- 
           Summary: [fortran, 4.3 regression]: ICE in operand_equal_p()
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: martin at mpa-garching dot mpg dot de
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


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

* [Bug fortran/30715] [4.3 regression]: ICE in operand_equal_p()  with -O
  2007-02-06 14:31 [Bug fortran/30715] New: [fortran, 4.3 regression]: ICE in operand_equal_p() martin at mpa-garching dot mpg dot de
@ 2007-02-06 16:52 ` burnus at gcc dot gnu dot org
  2007-02-06 17:45 ` [Bug middle-end/30715] " burnus at gcc dot gnu dot org
  2007-02-06 17:52 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: burnus at gcc dot gnu dot org @ 2007-02-06 16:52 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from burnus at gcc dot gnu dot org  2007-02-06 16:52 -------
Confirmed. It crashes with -O but not without optimization.

Reduced test case:
Subroutine xcc_V_CONVERT(iepoch)
    implicit none
    logical :: IEPOCH
    real    :: XVECTOR(1:3)
    real    :: YVECTOR(1:3)
    xvector = 0.0
    if (iepoch) then
       yvector(1:3)=xvector(1:3)
    endif
end subroutine xcc_v_convert


#1  0x0000000000551e7d in operand_equal_p (arg0=0x2b493e8fecc0,
arg1=0x2b493e81b440, flags=0)    at gcc/fold-const.c:2577
#2  0x000000000057977f in fold_ternary (code=COND_EXPR, type=0x2b493e82b0c0,
op0=0x2b493e81b200, op1=0x2b493e8fecc0, op2=0x2b493e81b440) at
gcc/fold-const.c:11773
#3  0x000000000057a9a1 in fold_build3_stat (code=10473456, type=0xa11,
op0=0x9fcec0, op1=0xa, op2=0x70) at gcc/fold-const.c:12423
#4  0x0000000000497321 in gfc_trans_if_1 (code=0xe60c40) at
gcc/fortran/trans-stmt.c:612
#5  0x0000000000468183 in gfc_trans_code (code=0xe61150) at
gcc/fortran/trans.c:531


-- 

burnus at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |burnus at gcc dot gnu dot
                   |                            |org
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
  GCC build triplet|i686-pc-linux-gnu           |
   GCC host triplet|i686-pc-linux-gnu           |
 GCC target triplet|i686-pc-linux-gnu           |
   Last reconfirmed|0000-00-00 00:00:00         |2007-02-06 16:52:39
               date|                            |
            Summary|[fortran, 4.3 regression]:  |[4.3 regression]: ICE in
                   |ICE in operand_equal_p()    |operand_equal_p()  with -O


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


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

* [Bug middle-end/30715] [4.3 regression]: ICE in operand_equal_p()  with -O
  2007-02-06 14:31 [Bug fortran/30715] New: [fortran, 4.3 regression]: ICE in operand_equal_p() martin at mpa-garching dot mpg dot de
  2007-02-06 16:52 ` [Bug fortran/30715] [4.3 regression]: ICE in operand_equal_p() with -O burnus at gcc dot gnu dot org
@ 2007-02-06 17:45 ` burnus at gcc dot gnu dot org
  2007-02-06 17:52 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: burnus at gcc dot gnu dot org @ 2007-02-06 17:45 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from burnus at gcc dot gnu dot org  2007-02-06 17:45 -------
> Reduced test case:
The line "xvector = 0.0" can also be removed. The dump-tree-original looks then
as follows:

xcc_v_convert (iepoch)
{
  real4 xvector[3];
  real4 yvector[3];

  if (*iepoch)
    {
      (void) __builtin_memcpy ((void *) &yvector, (void *) &xvector, 12);
    }
}


-- 

burnus at gcc dot gnu dot org changed:

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


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


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

* [Bug middle-end/30715] [4.3 regression]: ICE in operand_equal_p()  with -O
  2007-02-06 14:31 [Bug fortran/30715] New: [fortran, 4.3 regression]: ICE in operand_equal_p() martin at mpa-garching dot mpg dot de
  2007-02-06 16:52 ` [Bug fortran/30715] [4.3 regression]: ICE in operand_equal_p() with -O burnus at gcc dot gnu dot org
  2007-02-06 17:45 ` [Bug middle-end/30715] " burnus at gcc dot gnu dot org
@ 2007-02-06 17:52 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-02-06 17:52 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from pinskia at gcc dot gnu dot org  2007-02-06 17:52 -------


*** This bug has been marked as a duplicate of 30391 ***


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |DUPLICATE


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


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

end of thread, other threads:[~2007-02-06 17:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-02-06 14:31 [Bug fortran/30715] New: [fortran, 4.3 regression]: ICE in operand_equal_p() martin at mpa-garching dot mpg dot de
2007-02-06 16:52 ` [Bug fortran/30715] [4.3 regression]: ICE in operand_equal_p() with -O burnus at gcc dot gnu dot org
2007-02-06 17:45 ` [Bug middle-end/30715] " burnus at gcc dot gnu dot org
2007-02-06 17:52 ` pinskia 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).