another ICE derived from CP2K (PR 29975)

gfortran testcase.cell_types.f90
testcase.cell_types.f90: In function ‘pbc3’:
testcase.cell_types.f90:22: internal compiler error: in gfc_trans_assignment_1,
at fortran/trans-expr.c:3877
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
[EMAIL PROTECTED]:/scratch/vondele/tmp> cat testcase.cell_types.f90
MODULE cell_types
  INTEGER, PARAMETER :: dp=KIND(0.0D0)
  TYPE cell_type
     !FM to rm
     REAL(KIND = dp)            :: unit_of_length

     REAL(KIND = dp)            :: subcells
     !FM should stay
     LOGICAL                    :: orthorhombic
     REAL(KIND = dp), DIMENSION(3,3)   :: hmat,h_inv
   END TYPE cell_type
CONTAINS
  FUNCTION pbc3(ra,rb,cell) RESULT(rab_pbc)
    REAL(KIND=dp), DIMENSION(3), INTENT(IN)  :: ra, rb
    REAL(KIND=dp), DIMENSION(3)              :: rab_pbc
    INTEGER                                  :: icell, jcell, kcell
    REAL(KIND=dp)                            :: rab2, rab2_pbc
    REAL(KIND=dp), DIMENSION(3)              :: r, ra_pbc, rab, rb_image, &
                                                rb_pbc, s2r

    rb_pbc(:) = pbc(rb(:),cell)
    rab2_pbc = HUGE(1.0_dp)
    DO icell=-periodic(1),periodic(1)
      DO jcell=-periodic(2),periodic(2)
        DO kcell=-periodic(3),periodic(3)
          r = REAL((/icell,jcell,kcell/),dp)
        END DO
      END DO
    END DO
  END FUNCTION pbc3
END MODULE


-- 
           Summary: internal compiler error: in gfc_trans_assignment_1, at
                    fortran/trans-expr.c:3877
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: jv244 at cam dot ac dot uk


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

Reply via email to