[Bug fortran/39667] I/O possibly unneccesary truncations

2009-08-28 Thread jb at gcc dot gnu dot org


--- Comment #6 from jb at gcc dot gnu dot org  2009-08-28 14:48 ---
Closing as fixed


-- 

jb at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED


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



[Bug fortran/39667] I/O possibly unneccesary truncations

2009-08-27 Thread jb at gcc dot gnu dot org


--- Comment #5 from jb at gcc dot gnu dot org  2009-08-27 17:41 ---
Subject: Bug 39667

Author: jb
Date: Thu Aug 27 17:40:55 2009
New Revision: 151144

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=151144
Log:
PR libfortran/39667 Fix testcases to not need fd_truncate.

Modified:
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/gfortran.dg/f2003_io_4.f03
trunk/gcc/testsuite/gfortran.dg/fmt_cache_1.f
trunk/gcc/testsuite/gfortran.dg/fmt_exhaust.f90
trunk/gcc/testsuite/gfortran.dg/fmt_t_4.f90
trunk/gcc/testsuite/gfortran.dg/fseek.f90
trunk/gcc/testsuite/gfortran.dg/list_read_5.f90
trunk/gcc/testsuite/gfortran.dg/namelist_39.f90
trunk/gcc/testsuite/gfortran.dg/namelist_56.f90
trunk/gcc/testsuite/gfortran.dg/read_bad_advance.f90
trunk/gcc/testsuite/gfortran.dg/read_repeat.f90
trunk/gcc/testsuite/gfortran.dg/read_size_noadvance.f90
trunk/gcc/testsuite/gfortran.dg/read_x_past.f


-- 


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



[Bug fortran/39667] I/O possibly unneccesary truncations

2009-08-25 Thread jb at gcc dot gnu dot org


--- Comment #4 from jb at gcc dot gnu dot org  2009-08-25 22:17 ---
Updated patch fixing remaining fd_truncate issues with testsuite.


-- 

jb at gcc dot gnu dot org changed:

   What|Removed |Added

URL|http://gcc.gnu.org/ml/fortra|http://gcc.gnu.org/ml/gcc-
   |n/2009-04/msg00199.html |patches/2009-
   ||08/msg01388.html


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



[Bug fortran/39667] I/O possibly unneccesary truncations

2009-05-26 Thread jvdelisle at gcc dot gnu dot org


--- Comment #3 from jvdelisle at gcc dot gnu dot org  2009-05-27 01:22 
---
Subject: Bug 39667

Author: jvdelisle
Date: Wed May 27 01:21:22 2009
New Revision: 147887

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=147887
Log:
2009-05-23  Jerry DeLisle  

Backport from mainline:
PR libfortran/37754
* io/write_float.def: Simplify format calculation.

2009-05-23  Francois-Xavier Coudert  

Backport from mainline:
PR fortran/22423
* io/transfer.c (read_block_direct): Avoid warning.

2009-05-23  Janne Blomqvist  

Backport from mainline:
PR libfortran/39667
* io/file_pos.c (st_rewind): Don't truncate or flush.
* io/intrinsics.c (fgetc): Flush if switching mode.
(fputc): Likewise.

2009-05-23  Janne Blomqvist  

Backport from mainline:
PR libfortran/39782
* io/transfer.c (data_transfer_init): Don't flush before seek.

2009-05-23  Janne Blomqvist  

Backport from mainline:
* io/io.h (is_preconnected): Remove prototype.
* io/unix.c (is_preconnected): Remove function.

2009-05-23  Janne Blomqvist  

Backport from mainline:
PR libfortran/38668
* io/transfer.c (finalize_transfer): Don't flush for advance='no'.

2009-05-23 Danny Smith  

Backport from mainline:
* io/write.c (itoa) : Rename back to gfc_itoa.
(write_i): Adjust call to write_decimal.
(write_integer):  Use gfc_itoa.

2009-05-23  Janne Blomqvist  

Backport from mainline:
* io/io.h (move_pos_offset): Remove prototype.
* io/transfer.c (formatted_transfer_scalar_read): Use sseek
instead of move_pos_offset.
* io/unix.c (move_pos_offset): Remove.

2009-05-23  Janne Blomqvist  

Backport from mainline:
PR libfortran/39665 libfortran/39702 libfortran/39709
* io/io.h (st_parameter_dt): Revert aligned attribute from u.p.value.
* io/list_read.c (read_complex): Read directly into user pointer.
(read_real): Likewise.
(list_formatted_read_scalar): Update read_complex and read_real calls.
(nml_read_obj): Read directly into user pointer.

2009-05-23  Janne Blomqvist  

Backport from mainline:
PR libfortran/39665
* io/io.h (st_parameter_dt): Add aligned attribute to u.p.value.
* io/read.c (convert_real): Add note about alignment requirements.

2009-05-23  Janne Blomqvist  

Backport from mainline:
* io/open.c (already_open): Test for POSIX close return value.
* io/unit.c (close_unit_1): Likewise.
* io/unix.c (raw_close): Return 0 for success for preconnected units.

2009-05-23  Janne Blomqvist  

Backport from mainline:
* runtime/error.c (gfc_itoa): Move to io/write.c
(xtoa): Rename to gfc_xtoa.
* runtime/backtrace.c (show_backtrace): Call gfc_xtoa.
* libgfortran.h (gfc_itoa): Remove prototype.
(xtoa): Rename prototype to gfc_xtoa.
* io/list_read.c (nml_read_obj): Use size_t for string length.
* io/transfer.c (read_block_direct): Change nbytes arg from
pointer to value.
(unformatted_read): Minor cleanup, call read_block_directly properly.
(skip_record): Use ssize_t.
(next_record_w_unf): Avoid stell() call by calling sseek with SEEK_CUR.
(iolength_transfer): Make sure to multiply before cast.
* io/intrinsics.c (fgetc): Remove unnecessary variable.
* io/format.c (format_hash): Use gfc_charlen_type.
* io/write.c (itoa): Move from runtime/error.c:gfc_itoa, rename,
make static.
(write_i): Call with pointer to itoa.
(write_z): Call with pointer to gfc_xtoa.
(write_integer): Pointer to itoa.
(nml_write_obj): Type cleanup, don't call strlen in loop.

2009-05-23  H.J. Lu  

Backport from mainline:
PR libgfortran/39664
* io/unix.c (raw_close): Don't close STDOUT_FILENO,
STDERR_FILENO nor STDIN_FILENO.

2009-05-23  David Edelsohn  

Backport from mainline:
* io/io.h (struct stream): Rename truncate to trunc.
(struncate): Same.
* io/unix.c (raw_init): Rename truncate to trunc.
(buf_init): Same.
(open_internal): Same.

2009-05-23  Daniel Kraft  

Backport from mainline:
PR fortran/38654
* io/read.c (read_f): Reworked to speed up floating point parsing.
(convert_real): Use pointer-casting instead of memcpy and temporaries.

2009-05-23  Jerry DeLisle  

Backport from mainline:
PR libfortran/37754
* io/io.h (format_hash_entry): New structure for hash table.
(format_hash_table): The hash table itself.
(free_format_data): Revise function prototype.
(free_format_hash_table, init_format_hash,
free_format_hash): New function prototypes.
* io/unit.c (close_unit_1): Use free_format_hash_table.

[Bug fortran/39667] I/O possibly unneccesary truncations

2009-04-30 Thread jb at gcc dot gnu dot org


--- Comment #2 from jb at gcc dot gnu dot org  2009-04-30 15:12 ---
Subject: Bug 39667

Author: jb
Date: Thu Apr 30 15:12:37 2009
New Revision: 147004

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=147004
Log:
Fix PR libfortran/39667

Modified:
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/gfortran.dg/advance_1.f90
trunk/gcc/testsuite/gfortran.dg/advance_4.f90
trunk/gcc/testsuite/gfortran.dg/advance_5.f90
trunk/gcc/testsuite/gfortran.dg/append_1.f90
trunk/gcc/testsuite/gfortran.dg/backslash_1.f90
trunk/gcc/testsuite/gfortran.dg/backslash_2.f90
trunk/gcc/testsuite/gfortran.dg/backslash_3.f
trunk/gcc/testsuite/gfortran.dg/backspace_10.f90
trunk/gcc/testsuite/gfortran.dg/backspace_3.f
trunk/gcc/testsuite/gfortran.dg/backspace_4.f
trunk/gcc/testsuite/gfortran.dg/backspace_5.f
trunk/gcc/testsuite/gfortran.dg/backspace_8.f
trunk/gcc/testsuite/gfortran.dg/backspace_9.f
trunk/gcc/testsuite/gfortran.dg/complex_write.f90
trunk/gcc/testsuite/gfortran.dg/convert_implied_open.f90
trunk/gcc/testsuite/gfortran.dg/dollar_edit_descriptor_1.f
trunk/gcc/testsuite/gfortran.dg/dos_eol.f
trunk/gcc/testsuite/gfortran.dg/empty_format_1.f90
trunk/gcc/testsuite/gfortran.dg/endfile.f
trunk/gcc/testsuite/gfortran.dg/eof_1.f90
trunk/gcc/testsuite/gfortran.dg/eor_1.f90
trunk/gcc/testsuite/gfortran.dg/eor_handling_1.f90
trunk/gcc/testsuite/gfortran.dg/eor_handling_2.f90
trunk/gcc/testsuite/gfortran.dg/eor_handling_3.f90
trunk/gcc/testsuite/gfortran.dg/eor_handling_4.f90
trunk/gcc/testsuite/gfortran.dg/eor_handling_5.f90
trunk/gcc/testsuite/gfortran.dg/error_recovery_5.f90
trunk/gcc/testsuite/gfortran.dg/f2003_inquire_1.f03
trunk/gcc/testsuite/gfortran.dg/f2003_io_4.f03
trunk/gcc/testsuite/gfortran.dg/f2003_io_5.f03
trunk/gcc/testsuite/gfortran.dg/f2003_io_7.f03
trunk/gcc/testsuite/gfortran.dg/fgetc_1.f90
trunk/gcc/testsuite/gfortran.dg/fgetc_2.f90
trunk/gcc/testsuite/gfortran.dg/flush_1.f90
trunk/gcc/testsuite/gfortran.dg/fmt_exhaust.f90
trunk/gcc/testsuite/gfortran.dg/fmt_huge.f90
trunk/gcc/testsuite/gfortran.dg/fmt_read.f90
trunk/gcc/testsuite/gfortran.dg/fmt_t_1.f90
trunk/gcc/testsuite/gfortran.dg/fmt_t_2.f90
trunk/gcc/testsuite/gfortran.dg/fmt_t_3.f90
trunk/gcc/testsuite/gfortran.dg/fmt_t_4.f90
trunk/gcc/testsuite/gfortran.dg/fmt_t_5.f90
trunk/gcc/testsuite/gfortran.dg/fmt_t_7.f
trunk/gcc/testsuite/gfortran.dg/fseek.f90
trunk/gcc/testsuite/gfortran.dg/ftell_1.f90
trunk/gcc/testsuite/gfortran.dg/ftell_2.f90
trunk/gcc/testsuite/gfortran.dg/func_derived_3.f90
trunk/gcc/testsuite/gfortran.dg/inquire_9.f90
trunk/gcc/testsuite/gfortran.dg/iostat_1.f90
trunk/gcc/testsuite/gfortran.dg/iostat_2.f90
trunk/gcc/testsuite/gfortran.dg/list_read_1.f90
trunk/gcc/testsuite/gfortran.dg/list_read_4.f90
trunk/gcc/testsuite/gfortran.dg/list_read_5.f90
trunk/gcc/testsuite/gfortran.dg/list_read_7.f90
trunk/gcc/testsuite/gfortran.dg/list_read_8.f90
trunk/gcc/testsuite/gfortran.dg/list_read_9.f90
trunk/gcc/testsuite/gfortran.dg/namelist_13.f90
trunk/gcc/testsuite/gfortran.dg/namelist_14.f90
trunk/gcc/testsuite/gfortran.dg/namelist_15.f90
trunk/gcc/testsuite/gfortran.dg/namelist_16.f90
trunk/gcc/testsuite/gfortran.dg/namelist_17.f90
trunk/gcc/testsuite/gfortran.dg/namelist_18.f90
trunk/gcc/testsuite/gfortran.dg/namelist_19.f90
trunk/gcc/testsuite/gfortran.dg/namelist_20.f90
trunk/gcc/testsuite/gfortran.dg/namelist_24.f90
trunk/gcc/testsuite/gfortran.dg/namelist_26.f90
trunk/gcc/testsuite/gfortran.dg/namelist_27.f90
trunk/gcc/testsuite/gfortran.dg/namelist_28.f90
trunk/gcc/testsuite/gfortran.dg/namelist_37.f90
trunk/gcc/testsuite/gfortran.dg/namelist_38.f90
trunk/gcc/testsuite/gfortran.dg/namelist_39.f90
trunk/gcc/testsuite/gfortran.dg/namelist_40.f90
trunk/gcc/testsuite/gfortran.dg/namelist_43.f90
trunk/gcc/testsuite/gfortran.dg/namelist_44.f90
trunk/gcc/testsuite/gfortran.dg/namelist_45.f90
trunk/gcc/testsuite/gfortran.dg/namelist_46.f90
trunk/gcc/testsuite/gfortran.dg/namelist_47.f90
trunk/gcc/testsuite/gfortran.dg/namelist_48.f90
trunk/gcc/testsuite/gfortran.dg/namelist_49.f90
trunk/gcc/testsuite/gfortran.dg/namelist_50.f90
trunk/gcc/testsuite/gfortran.dg/namelist_51.f90
trunk/gcc/testsuite/gfortran.dg/namelist_52.f90
trunk/gcc/testsuite/gfortran.dg/namelist_56.f90
trunk/gcc/testsuite/gfortran.dg/namelist_char_only.f90
trunk/gcc/testsuite/gfortran.dg/namelist_use.f90
trunk/gcc/testsuite/gfortran.dg/namelist_use_only.f90
trunk/gcc/testsuite/gfortran.dg/noadv_size.f90
trunk/gcc/testsuite/gfortran.dg/open_access_append_1.f90
trunk/gcc/testsuite/gfortran.dg/pad_no.f90
trunk/gcc/testsuite/gfortran.dg/pr12884.f
trunk/gcc/testsuite/gfortran.dg/pr17090.f90
trunk/gcc/testsuite/

[Bug fortran/39667] I/O possibly unneccesary truncations

2009-04-17 Thread jb at gcc dot gnu dot org


--- Comment #1 from jb at gcc dot gnu dot org  2009-04-17 22:18 ---
Confirmed, assigning to myself.


-- 

jb at gcc dot gnu dot org changed:

   What|Removed |Added

 AssignedTo|unassigned at gcc dot gnu   |jb at gcc dot gnu dot org
   |dot org |
 Status|UNCONFIRMED |ASSIGNED
 Ever Confirmed|0   |1
   Last reconfirmed|-00-00 00:00:00 |2009-04-17 22:18:55
   date||


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