This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/35633] New: [Regression] stream io broken on FreeBSD due to ftruncate changes.
- From: "kargl at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 19 Mar 2008 03:42:19 -0000
- Subject: [Bug fortran/35633] New: [Regression] stream io broken on FreeBSD due to ftruncate changes.
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
This commit:
2008-03-05 Hans-Peter Nilsson <hp@axis.com>
PR libfortran/35293
* io/unix.c (fd_truncate): Fold s->special_file case into
success case of ftruncate/chsize call instead of the failure case.
Make failure case actually return failure. Properly update stream
pointers on failure. Call runtime_error for targets without
neither ftruncate nor chsize where such a call would be needed.
leads to
WARNING: program timed out.
FAIL: gfortran.dg/streamio_4.f90 -O0 execution test
WARNING: program timed out.
FAIL: gfortran.dg/streamio_4.f90 -O1 execution test
WARNING: program timed out.
FAIL: gfortran.dg/streamio_4.f90 -O2 execution test
WARNING: program timed out.
FAIL: gfortran.dg/streamio_4.f90 -O3 -fomit-frame-pointer execution test
A ktrace on one of the failing cases shows
19649 streamio_4.exe RET ftruncate 0
19649 streamio_4.exe CALL sigprocmask(SIG_BLOCK,0,0xbfbfd7a8)
19649 streamio_4.exe RET sigprocmask 0
19649 streamio_4.exe CALL lseek(0x3,0x188b2,SEEK_SET,0)
19649 streamio_4.exe RET lseek 100530/0x188b2
19649 streamio_4.exe CALL ftruncate(0x3,0x188b2,0)
19649 streamio_4.exe RET ftruncate 0
19649 streamio_4.exe CALL sigprocmask(SIG_BLOCK,0,0xbfbfd7a8)
19649 streamio_4.exe RET sigprocmask 0
19649 streamio_4.exe CALL lseek(0x3,0x188b8,SEEK_SET,0)
19649 streamio_4.exe RET lseek 100536/0x188b8
19649 streamio_4.exe CALL ftruncate(0x3,0x188b8,0)
19649 streamio_4.exe RET ftruncate 0
19649 streamio_4.exe CALL sigprocmask(SIG_BLOCK,0,0xbfbfd7a8)
19649 streamio_4.exe RET sigprocmask 0
19649 streamio_4.exe CALL lseek(0x3,0x188be,SEEK_SET,0)
19649 streamio_4.exe RET lseek 100542/0x188be
19649 streamio_4.exe CALL ftruncate(0x3,0x188be,0)
19649 streamio_4.exe RET ftruncate 0
19649 streamio_4.exe CALL sigprocmask(SIG_BLOCK,0,0xbfbfd7a8)
19649 streamio_4.exe RET sigprocmask 0
19649 streamio_4.exe CALL lseek(0x3,0x188c4,SEEK_SET,0)
19649 streamio_4.exe RET lseek 100548/0x188c4
19649 streamio_4.exe CALL ftruncate(0x3,0x188c4,0)
19649 streamio_4.exe RET ftruncate 0
19649 streamio_4.exe CALL sigprocmask(SIG_BLOCK,0,0xbfbfd7a8)
19649 streamio_4.exe RET sigprocmask 0
19649 streamio_4.exe CALL lseek(0x3,0x188ca,SEEK_SET,0)
19649 streamio_4.exe RET lseek 100554/0x188ca
19649 streamio_4.exe CALL ftruncate(0x3,0x188ca,0)
19649 streamio_4.exe RET ftruncate 0
ad nausem.
Please revert your patch.
--
Summary: [Regression] stream io broken on FreeBSD due to
ftruncate changes.
Product: gcc
Version: 4.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: kargl at gcc dot gnu dot org
GCC target triplet: i386-unknown-freebsd8.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35633