This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/54923] New: Internal unit I/O error when using -malign-double
- From: "gnu.0kn at gishpuppy dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 13 Oct 2012 23:35:22 +0000
- Subject: [Bug fortran/54923] New: Internal unit I/O error when using -malign-double
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54923
Bug #: 54923
Summary: Internal unit I/O error when using -malign-double
Classification: Unclassified
Product: gcc
Version: 4.6.3
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: gnu.0kn@gishpuppy.com
Reading from of integer from character string fails with
Fortran runtime error: Internal unit I/O error
when compiling with -malign-double.
Background: This occurred when using the usual getarg(1,arg) construct and
linking against FFTW3, which requires data alignment.
Minimal example:
___
PROGRAM readtest
IMPLICIT NONE
CHARACTER*8 arg
INTEGER inputarg
arg=" 1 "
READ(arg,*) inputarg
PRINT *,"Argument supplied was: ", inputarg
RETURN
END
___
Compiling with gfortran without data alignment yields the expected result.
Compiling with -malign-double in the compiler options yields runtime error.
Thank you.