[Bug libfortran/28747] Empty write STREAM I/O file positioning problem

jvdelisle at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Fri Aug 18 16:08:00 GMT 2006

------- Comment #1 from jvdelisle at gcc dot gnu dot org  2006-08-18 16:08 -------
Created an attachment (id=12093)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=12093&action=view)
assembly output for reduced case

There is wrong code generated setting up the parameters for the second call to
write.  The pointers are off by 400.  You can see this by comparing the
instructions just before the first call too _gfortran_st_write vs the
instructions leading up to the second _gfortran_st_write.

-fdump-tree-original looks OK.  Inserting a flush right after the first call to
write in the test case and the problem goes away.

Middle-end or backend problem?



More information about the Gcc-bugs mailing list