public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/23677] New: -fno-automatic does not accept legal save statements
@ 2005-09-01 13:08 federico dot carminati at cern dot ch
2005-09-01 13:09 ` [Bug fortran/23677] " federico dot carminati at cern dot ch
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: federico dot carminati at cern dot ch @ 2005-09-01 13:08 UTC (permalink / raw)
To: gcc-bugs
The following code fails
[/Users/fca] more test.f
subroutine test(bbb)
implicit double precision (A-H,O-Z)
double precision blob(100),bbb(100)
data blob /100*-1/
save blob
do j=1,100
blob(j)=bbb(j)
enddo
end
[/Users/fca] /opt/gcc-4_0/bin/gfortran -c -fno-automatic test.f
In file test.f:3
double precision blob(100),bbb(100)
1
Error: Duplicate SAVE attribute specified at (1)
Two remarks.
- Non-contraddictory declarations should not cause compilation to fail (see with double precision)
- A compiler switch should not turn valid code into non-compilable code
--
Summary: -fno-automatic does not accept legal save statements
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: federico dot carminati at cern dot ch
CC: gcc-bugs at gcc dot gnu dot org
GCC host triplet: Darwin 8.2.0 Power Macintosh powerpc
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23677
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/23677] -fno-automatic does not accept legal save statements
2005-09-01 13:08 [Bug fortran/23677] New: -fno-automatic does not accept legal save statements federico dot carminati at cern dot ch
@ 2005-09-01 13:09 ` federico dot carminati at cern dot ch
2005-09-06 19:31 ` dir at lanl dot gov
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: federico dot carminati at cern dot ch @ 2005-09-01 13:09 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |alfredo dot ferrari at cern
| |dot ch
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23677
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/23677] -fno-automatic does not accept legal save statements
2005-09-01 13:08 [Bug fortran/23677] New: -fno-automatic does not accept legal save statements federico dot carminati at cern dot ch
2005-09-01 13:09 ` [Bug fortran/23677] " federico dot carminati at cern dot ch
@ 2005-09-06 19:31 ` dir at lanl dot gov
2005-09-06 19:33 ` dir at lanl dot gov
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: dir at lanl dot gov @ 2005-09-06 19:31 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From dir at lanl dot gov 2005-09-06 19:31 -------
I have the same problem (g77 does not complain) -
[dranta:~/tests/gfortran-D] dir% g77 -c -fno-automatic save.f
[dranta:~/tests/gfortran-D] dir% gfortran -c -fno-automatic save.f
In file save.f:2
save lastcol
1
Error: Duplicate SAVE attribute specified at (1)
[dranta:~/tests/gfortran-D] dir% cat save.f
subroutine gdpstc(ifxn,xa,ya)
save lastcol
return
end
[dranta:~/tests/gfortran-D] dir% gfortran --v
Using built-in specs.
Target: powerpc-apple-darwin7.9.0
Configured with: ./configure --prefix=/Users/dir/gfortran --enable-languages=c,f95
Thread model: posix
gcc version 4.1.0 20050906 (experimental)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23677
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/23677] -fno-automatic does not accept legal save statements
2005-09-01 13:08 [Bug fortran/23677] New: -fno-automatic does not accept legal save statements federico dot carminati at cern dot ch
2005-09-01 13:09 ` [Bug fortran/23677] " federico dot carminati at cern dot ch
2005-09-06 19:31 ` dir at lanl dot gov
@ 2005-09-06 19:33 ` dir at lanl dot gov
2005-09-09 15:10 ` tobi at gcc dot gnu dot org
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: dir at lanl dot gov @ 2005-09-06 19:33 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |dir at lanl dot gov
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23677
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/23677] -fno-automatic does not accept legal save statements
2005-09-01 13:08 [Bug fortran/23677] New: -fno-automatic does not accept legal save statements federico dot carminati at cern dot ch
` (2 preceding siblings ...)
2005-09-06 19:33 ` dir at lanl dot gov
@ 2005-09-09 15:10 ` tobi at gcc dot gnu dot org
2005-09-26 20:07 ` cvs-commit at gcc dot gnu dot org
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: tobi at gcc dot gnu dot org @ 2005-09-09 15:10 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From tobi at gcc dot gnu dot org 2005-09-09 15:09 -------
-fno-automatic should be a synonym for -fmax-stack-var-size=0 instead of what is
implemented now.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2005-09-09 15:09:55
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23677
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/23677] -fno-automatic does not accept legal save statements
2005-09-01 13:08 [Bug fortran/23677] New: -fno-automatic does not accept legal save statements federico dot carminati at cern dot ch
` (3 preceding siblings ...)
2005-09-09 15:10 ` tobi at gcc dot gnu dot org
@ 2005-09-26 20:07 ` cvs-commit at gcc dot gnu dot org
2005-09-29 21:27 ` cvs-commit at gcc dot gnu dot org
2005-09-29 21:32 ` pinskia at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2005-09-26 20:07 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-09-26 20:06 -------
Subject: Bug 23677
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: jakub@gcc.gnu.org 2005-09-26 20:06:37
Modified files:
gcc/fortran : ChangeLog
gcc/testsuite : ChangeLog
gcc/fortran : options.c symbol.c resolve.c
Added files:
gcc/testsuite/gfortran.dg: save_1.f90
gcc/testsuite/gfortran.fortran-torture/execute: save_1.f90
Log message:
PR fortran/23677
* symbol.c (gfc_is_var_automatic): Return true if character length
is non-constant rather than constant.
* resolve.c (gfc_resolve): Don't handle !gfc_option.flag_automatic
here.
* options.c (gfc_post_options): Set gfc_option.flag_max_stack_var_size
to 0 for -fno-automatic.
* gfortran.fortran-torture/execute/save_1.f90: New test.
* gfortran.dg/save_1.f90: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/ChangeLog.diff?cvsroot=gcc&r1=1.568&r2=1.569
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.6105&r2=1.6106
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/options.c.diff?cvsroot=gcc&r1=1.25&r2=1.26
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/symbol.c.diff?cvsroot=gcc&r1=1.34&r2=1.35
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/resolve.c.diff?cvsroot=gcc&r1=1.55&r2=1.56
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gfortran.dg/save_1.f90.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gfortran.fortran-torture/execute/save_1.f90.diff?cvsroot=gcc&r1=NONE&r2=1.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23677
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/23677] -fno-automatic does not accept legal save statements
2005-09-01 13:08 [Bug fortran/23677] New: -fno-automatic does not accept legal save statements federico dot carminati at cern dot ch
` (4 preceding siblings ...)
2005-09-26 20:07 ` cvs-commit at gcc dot gnu dot org
@ 2005-09-29 21:27 ` cvs-commit at gcc dot gnu dot org
2005-09-29 21:32 ` pinskia at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2005-09-29 21:27 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-09-29 21:27 -------
Subject: Bug 23677
CVSROOT: /cvs/gcc
Module name: gcc
Branch: gcc-4_0-branch
Changes by: jakub@gcc.gnu.org 2005-09-29 21:27:35
Modified files:
gcc/fortran : ChangeLog
gcc/testsuite : ChangeLog
gcc/fortran : symbol.c options.c resolve.c
Added files:
gcc/testsuite/gfortran.dg: save_1.f90
gcc/testsuite/gfortran.fortran-torture/execute: save_1.f90
Log message:
PR fortran/23677
* symbol.c (gfc_is_var_automatic): Return true if character length
is non-constant rather than constant.
* resolve.c (gfc_resolve): Don't handle !gfc_option.flag_automatic
here.
* options.c (gfc_post_options): Set gfc_option.flag_max_stack_var_size
to 0 for -fno-automatic.
* gfortran.fortran-torture/execute/save_1.f90: New test.
* gfortran.dg/save_1.f90: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.335.2.121&r2=1.335.2.122
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.5084.2.416&r2=1.5084.2.417
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/symbol.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.26.2.3&r2=1.26.2.4
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/options.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.17.8.5&r2=1.17.8.6
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/fortran/resolve.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.34.2.15&r2=1.34.2.16
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gfortran.dg/save_1.f90.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=NONE&r2=1.1.4.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gfortran.fortran-torture/execute/save_1.f90.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=NONE&r2=1.1.4.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23677
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Bug fortran/23677] -fno-automatic does not accept legal save statements
2005-09-01 13:08 [Bug fortran/23677] New: -fno-automatic does not accept legal save statements federico dot carminati at cern dot ch
` (5 preceding siblings ...)
2005-09-29 21:27 ` cvs-commit at gcc dot gnu dot org
@ 2005-09-29 21:32 ` pinskia at gcc dot gnu dot org
6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-09-29 21:32 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-09-29 21:32 -------
Fixed.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.0.3
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23677
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2005-09-29 21:32 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-09-01 13:08 [Bug fortran/23677] New: -fno-automatic does not accept legal save statements federico dot carminati at cern dot ch
2005-09-01 13:09 ` [Bug fortran/23677] " federico dot carminati at cern dot ch
2005-09-06 19:31 ` dir at lanl dot gov
2005-09-06 19:33 ` dir at lanl dot gov
2005-09-09 15:10 ` tobi at gcc dot gnu dot org
2005-09-26 20:07 ` cvs-commit at gcc dot gnu dot org
2005-09-29 21:27 ` cvs-commit at gcc dot gnu dot org
2005-09-29 21:32 ` 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).