public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/23515] New: ICE on correct code
@ 2005-08-22 16:20 pault at gcc dot gnu dot org
  2005-08-22 18:00 ` [Bug fortran/23515] " pinskia at gcc dot gnu dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-08-22 16:20 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1558 bytes --]

[prt@localhost mytests]# cat foo.f90 program foo
  common /x/ a
  a = 1
  call bar ()
contains
  subroutine bar ()
    equivalence (a,b)
    print *, b
  end subroutine bar
end program foo
[prt@localhost mytests]# /gcc-4.0/bin/gfortran foo.f90
foo.f90: In function ‘MAIN__’:
foo.f90:8: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
[prt@localhost mytests]# cat foo*al
{
  union
  {
    real4 a;
  } equiv.0;
  real4 b;

  _gfortran_filename = "foo.f90";
  _gfortran_line = 8;
  _gfortran_ioparm.unit = 6;
  _gfortran_ioparm.list_format = 1;
  _gfortran_st_write ();
  _gfortran_transfer_real (&b, 4);
  _gfortran_st_write_done ();
}

Note, no MAIN. My mainline gets further but the equivalences are similarly
stuffed.  Declaring a and b before the equivalence, gives correct code.  I would
surmise, therefore, that match_equivalence needs to check that symbols exist for
each member of the equivalence group and that they are from the current scoping
unit.  If they are not, local symbols must be created.

Paul T

-- 
           Summary: ICE on correct code
           Product: gcc
           Version: 4.0.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: pault at gcc dot gnu dot org
                CC: gcc-bugs at gcc dot gnu dot org


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


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

* [Bug fortran/23515] ICE on correct code
  2005-08-22 16:20 [Bug fortran/23515] New: ICE on correct code pault at gcc dot gnu dot org
@ 2005-08-22 18:00 ` pinskia at gcc dot gnu dot org
  2005-08-22 18:26 ` paulthomas2 at wanadoo dot fr
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-08-22 18:00 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-08-22 17:40 -------
Confirmed.
Back trace:
#0  translate_common (common=0x9037228, var_list=Variable "var_list" is not available.
) at /home/peshtigo/pinskia/src/gnu/gcc/src/gcc/fortran/trans-common.c:823
#1  0x0808ebf5 in gfc_traverse_symtree (st=0x9036df0, func=0x80a24f0 <named_common>) at /
home/peshtigo/pinskia/src/gnu/gcc/src/gcc/fortran/symbol.c:2295
#2  0x080a2454 in gfc_trans_common (ns=0x9036e58) at /home/peshtigo/pinskia/src/gnu/gcc/src/
gcc/fortran/trans-common.c:956
#3  0x080a7518 in gfc_generate_function_code (ns=0x9036e58) at /home/peshtigo/pinskia/src/gnu/
gcc/src/gcc/fortran/trans-decl.c:2351
#4  0x08097964 in gfc_generate_code (ns=0x9036e58) at /home/peshtigo/pinskia/src/gnu/gcc/src/
gcc/fortran/trans.c:683
#5  0x0807daa1 in gfc_parse_file () at /home/peshtigo/pinskia/src/gnu/gcc/src/gcc/fortran/parse.c:
2642
#6  0x08097325 in gfc_be_parse_file (set_yydebug=0) at /home/peshtigo/pinskia/src/gnu/gcc/src/
gcc/fortran/f95-lang.c:256


-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2005-08-22 17:40:54
               date|                            |


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


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

* Re: [Bug fortran/23515] ICE on correct code
  2005-08-22 18:26 ` paulthomas2 at wanadoo dot fr
@ 2005-08-22 18:26   ` Andrew Pinski
  0 siblings, 0 replies; 6+ messages in thread
From: Andrew Pinski @ 2005-08-22 18:26 UTC (permalink / raw)
  To: gcc-bugzilla; +Cc: gcc-bugs


On Aug 22, 2005, at 2:18 PM, paulthomas2 at wanadoo dot fr wrote:

>
> PS peshtigo?

I don't know where it comes from for this machine, as I did not name 
them.
It looks like where the deadest fire in American history happened.

http://www.peshtigofire.info/

-- Pinski


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

* [Bug fortran/23515] ICE on correct code
  2005-08-22 16:20 [Bug fortran/23515] New: ICE on correct code pault at gcc dot gnu dot org
  2005-08-22 18:00 ` [Bug fortran/23515] " pinskia at gcc dot gnu dot org
@ 2005-08-22 18:26 ` paulthomas2 at wanadoo dot fr
  2005-08-22 18:26   ` Andrew Pinski
  2005-08-22 18:48 ` pinskia at physics dot uc dot edu
  2005-09-18 14:04 ` pault at gcc dot gnu dot org
  3 siblings, 1 reply; 6+ messages in thread
From: paulthomas2 at wanadoo dot fr @ 2005-08-22 18:26 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From paulthomas2 at wanadoo dot fr  2005-08-22 18:18 -------
Subject: Re:  ICE on correct code

pinskia at gcc dot gnu dot org wrote:

>------- Additional Comments From pinskia at gcc dot gnu dot org  2005-08-22 17:40 -------
>Confirmed.
>Back trace:
>#0  translate_common (common=0x9037228, var_list=Variable "var_list" is not available.
>) at /home/peshtigo/pinskia/src/gnu/gcc/src/gcc/fortran/trans-common.c:823
>#1  0x0808ebf5 in gfc_traverse_symtree (st=0x9036df0, func=0x80a24f0 <named_common>) at /
>home/peshtigo/pinskia/src/gnu/gcc/src/gcc/fortran/symbol.c:2295
>#2  0x080a2454 in gfc_trans_common (ns=0x9036e58) at /home/peshtigo/pinskia/src/gnu/gcc/src/
>gcc/fortran/trans-common.c:956
>#3  0x080a7518 in gfc_generate_function_code (ns=0x9036e58) at /home/peshtigo/pinskia/src/gnu/
>gcc/src/gcc/fortran/trans-decl.c:2351
>#4  0x08097964 in gfc_generate_code (ns=0x9036e58) at /home/peshtigo/pinskia/src/gnu/gcc/src/
>gcc/fortran/trans.c:683
>#5  0x0807daa1 in gfc_parse_file () at /home/peshtigo/pinskia/src/gnu/gcc/src/gcc/fortran/parse.c:
>2642
>#6  0x08097325 in gfc_be_parse_file (set_yydebug=0) at /home/peshtigo/pinskia/src/gnu/gcc/src/
>gcc/fortran/f95-lang.c:256
>
>
>  
>
Coo! It really is broken - I did not expect it to crash in translate_common.

Paul T

PS peshtigo?



-- 


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


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

* [Bug fortran/23515] ICE on correct code
  2005-08-22 16:20 [Bug fortran/23515] New: ICE on correct code pault at gcc dot gnu dot org
  2005-08-22 18:00 ` [Bug fortran/23515] " pinskia at gcc dot gnu dot org
  2005-08-22 18:26 ` paulthomas2 at wanadoo dot fr
@ 2005-08-22 18:48 ` pinskia at physics dot uc dot edu
  2005-09-18 14:04 ` pault at gcc dot gnu dot org
  3 siblings, 0 replies; 6+ messages in thread
From: pinskia at physics dot uc dot edu @ 2005-08-22 18:48 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at physics dot uc dot edu  2005-08-22 18:26 -------
Subject: Re:  ICE on correct code


On Aug 22, 2005, at 2:18 PM, paulthomas2 at wanadoo dot fr wrote:

>
> PS peshtigo?

I don't know where it comes from for this machine, as I did not name 
them.
It looks like where the deadest fire in American history happened.

http://www.peshtigofire.info/

-- Pinski



-- 


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


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

* [Bug fortran/23515] ICE on correct code
  2005-08-22 16:20 [Bug fortran/23515] New: ICE on correct code pault at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2005-08-22 18:48 ` pinskia at physics dot uc dot edu
@ 2005-09-18 14:04 ` pault at gcc dot gnu dot org
  3 siblings, 0 replies; 6+ messages in thread
From: pault at gcc dot gnu dot org @ 2005-09-18 14:04 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pault at gcc dot gnu dot org  2005-09-18 14:04 -------
Fixed on mainline and 4.02

http://gcc.gnu.org/ml/fortran/2005-09/msg00068.html contains a remark that an
issue raised by Steven Bosscher had been resolved.  I had forgotten that I
raised this PR about it.  The new function gfc_match_equiv_variable is what does
it.  

Paul T

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


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


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

end of thread, other threads:[~2005-09-18 14:04 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-08-22 16:20 [Bug fortran/23515] New: ICE on correct code pault at gcc dot gnu dot org
2005-08-22 18:00 ` [Bug fortran/23515] " pinskia at gcc dot gnu dot org
2005-08-22 18:26 ` paulthomas2 at wanadoo dot fr
2005-08-22 18:26   ` Andrew Pinski
2005-08-22 18:48 ` pinskia at physics dot uc dot edu
2005-09-18 14:04 ` pault 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).