public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/34633]  New: Compiler crash on FORALL loop
@ 2008-01-01  0:11 holst at matmech dot com
  2008-01-01  1:23 ` [Bug fortran/34633] " pinskia at gcc dot gnu dot org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: holst at matmech dot com @ 2008-01-01  0:11 UTC (permalink / raw)
  To: gcc-bugs

Hi GCC Fortran developers!

I was playing with some CaSe changing routines and I ran into a crash when I
tried to use a FORALL statement instead of a DO loop. 

The routine that is failing (from my perspective) is SUBROUTINE TO_UPPER(STR).

--
MODULE CASECONV
CONTAINS
   SUBROUTINE TO_UPPER(STR)
      CHARACTER(*) STR
      INTEGER      I
      FORALL (I = 1:LEN(STR))
      !DO I = 1, LEN(STR)
         STR(I:I) = UC(STR(I:I))
      !END DO
      END FORALL
   CONTAINS
      ELEMENTAL FUNCTION UC(C)
         CHARACTER, INTENT(IN) :: C
         CHARACTER             :: UC
         INTEGER, PARAMETER    :: DELTA = ICHAR('A') - ICHAR('a')
         IF (LLE(C, 'z') .AND. LGE(C, 'a')) THEN
            UC = ACHAR(ICHAR(C) + DELTA)
         ELSE
            UC = C
         END IF
      END FUNCTION UC
   END SUBROUTINE TO_UPPER
END MODULE CASECONV

PROGRAM UCBUG
   USE CASECONV
   IMPLICIT NONE
   CHARACTER(132) :: TESTSTR
   TESTSTR = 'Hello, World!'
   PRINT *, TRIM(TESTSTR)
   CALL TO_UPPER(TESTSTR)
   PRINT *, TRIM(TESTSTR)
END PROGRAM UCBUG


-- 
           Summary: Compiler crash on FORALL loop
           Product: gcc
           Version: 4.2.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: holst at matmech dot com
  GCC host triplet: x86_64-unknown-linux


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


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

* [Bug fortran/34633] Compiler crash on FORALL loop
  2008-01-01  0:11 [Bug fortran/34633] New: Compiler crash on FORALL loop holst at matmech dot com
@ 2008-01-01  1:23 ` pinskia at gcc dot gnu dot org
  2008-01-01  1:26 ` pinskia at gcc dot gnu dot org
  2010-09-08 18:05 ` gcc-bugzilla at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-01-01  1:23 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gcc dot gnu dot org  2008-01-01 01:22 -------
This works on the trunk for 4.3.0.


-- 


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


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

* [Bug fortran/34633] Compiler crash on FORALL loop
  2008-01-01  0:11 [Bug fortran/34633] New: Compiler crash on FORALL loop holst at matmech dot com
  2008-01-01  1:23 ` [Bug fortran/34633] " pinskia at gcc dot gnu dot org
@ 2008-01-01  1:26 ` pinskia at gcc dot gnu dot org
  2010-09-08 18:05 ` gcc-bugzilla at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-01-01  1:26 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pinskia at gcc dot gnu dot org  2008-01-01 01:25 -------
That is because it is the same as PR 31217.

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


-- 

pinskia at gcc dot gnu dot org changed:

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


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


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

* [Bug fortran/34633] Compiler crash on FORALL loop
  2008-01-01  0:11 [Bug fortran/34633] New: Compiler crash on FORALL loop holst at matmech dot com
  2008-01-01  1:23 ` [Bug fortran/34633] " pinskia at gcc dot gnu dot org
  2008-01-01  1:26 ` pinskia at gcc dot gnu dot org
@ 2010-09-08 18:05 ` gcc-bugzilla at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: gcc-bugzilla at gcc dot gnu dot org @ 2010-09-08 18:05 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pinskia at gcc dot gnu dot org  2008-01-01 01:25 -------
That is because it is the same as PR 31217.

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


-- 

pinskia at gcc dot gnu dot org changed:

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


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


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

end of thread, other threads:[~2010-09-08 18:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-01-01  0:11 [Bug fortran/34633] New: Compiler crash on FORALL loop holst at matmech dot com
2008-01-01  1:23 ` [Bug fortran/34633] " pinskia at gcc dot gnu dot org
2008-01-01  1:26 ` pinskia at gcc dot gnu dot org
2010-09-08 18:05 ` gcc-bugzilla 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).