svn merge -r 216846:217483 svn+ssh://gcc.gnu.org/svn/gcc/trunk
[official-gcc.git] / libgfortran / ChangeLog
blob119e1aef402a1924f5df37d134b5e6d723c66d03
1 2014-11-13  Janne Blomqvist  <jb@gcc.gnu.org>
3         PR libfortran/60324
4         * configure: Regenerated.
5         * configure.ac (AM_CFLAGS): Add Werror=vla.
6         * libgfortran.h (gfc_alloca): Remove macro.
7         (fc_strdup_notrim): New prototype.
8         * intrinsics/access.c (access_func): Use fc_strdup rather than
9         stack allocation.
10         * intrinsics/chdir.c (chdir_i4_sub): Likewise.
11         (chdir_i8_sub): Likewise.
12         * intrinsics/chmod.c (chmod_internal): New function, move logic
13         here.
14         (chmod_func): Call chmod_internal.
15         * intrinsics/env.c (getenv): Use fc_strdup rather than stack
16         allocation.
17         (get_environment_variable_i4): Likewise.
18         * intrinsics/execute_command_line.c (execute_command_line):
19         Likewise.
20         * intrinsics/hostnm.c (hostnm_0): New function, use static buffer
21         rather than VLA.
22         (hostnm_i4_sub): Call hostnm_0.
23         (hostnm_i8_sub): Likewise.
24         (hostnm): Likewise.
25         * intrinsics/link.c (link_internal): New function, use fc_strdup
26         rather than stack allocation.
27         (link_i4_sub): Call link_internal.
28         (link_i8_sub): Likewise.
29         (link_i4): Likewise.
30         (link_i8): Likewise.
31         * intrinsics/perror.c (perror_sub): Use fc_strdup rather than
32         stack allocation.
33         * intrinsics/random.c (random_seed_i4): Use static buffer rather
34         than VLA, use _Static_assert to make sure it's big enough.
35         * intrinsics/rename.c (rename_internal): New function, use
36         fc_strdup rather than stack allocation.
37         (rename_i4_sub): Call rename_internal.
38         (rename_i8_sub): Likewise.
39         (rename_i4): Likewise.
40         (rename_i8): Likewise.
41         * intrinsics/stat.c (stat_i4_sub_0): Use fc_strdup rather than
42         stack allocation.
43         (stat_i8_sub_0): Likewise.
44         * intrinsics/symlink.c (symlnk_internal): New function, use
45         fc_strdup rather than stack allocation.
46         (symlnk_i4_sub): Call symlnk_internal.
47         (symlnk_i8_sub): Likewise.
48         (symlnk_i4): Likewise.
49         (symlnk_i8): Likewise.
50         * intrinsics/system.c (system_sub): Use fc_strdup rather than
51         stack allocation.
52         * intrinsics/unlink.c (unlink_i4_sub): Likewise.
53         * io/file_pos.c (READ_CHUNK): Make it a macro rather than variable.
54         * io/list_read.c (nml_get_obj_data): Use fixed stack buffer, fall
55         back to xmalloc/free for large sizes.
56         * io/read.c (read_f): Likewise.
57         * io/transfer.c (MAX_READ): Make it a macro rather than variable.
58         (WRITE_CHUNK): Likewise.
59         * io/write_float.def (write_float): Use fixed stack buffer, fall
60         back to xmalloc/free for large sizes.
61         * runtime/string.c (fc_strdup_notrim): New function.
63 2014-11-11  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
65         PR target/63610
66         * configure: Regenerate.
68 2014-11-10  Janne Blomqvist  <jb@gcc.gnu.org>
70         PR libfortran/47007
71         PR libfortran/61847
72         * config.h.in: Regenerated.
73         * configure: Regenerated.
74         * configure.ac (AC_CHECK_HEADERS_ONCE): Check for xlocale.h.
75         (AC_CHECK_FUNCS_ONCE): Check for newlocale, freelocale, uselocale,
76         strerror_l.
77         * io/io.h (locale.h): Include.
78         (xlocale.h): Include if present.
79         (c_locale): New variable.
80         (old_locale): New variable.
81         (old_locale_ctr): New variable.
82         (old_locale_lock): New variable.
83         (st_parameter_dt): Add old_locale member.
84         * io/transfer.c (data_transfer_init): Set locale to "C" if doing
85         formatted transfer.
86         (finalize_transfer): Reset locale to previous.
87         * io/unit.c (c_locale): New variable.
88         (old_locale): New variable.
89         (old_locale_ctr): New variable.
90         (old_locale_lock): New variable.
91         (init_units): Init c_locale, init old_locale_lock.
92         (close_units): Free c_locale.
93         * runtime/error.c (locale.h): Include.
94         (xlocale.h): Include if present.
95         (gf_strerror): Use strerror_l if available. Reset locale to
96         LC_GLOBAL_LOCALE for strerror_r branch.
98 2014-10-20  Janne Blomqvist  <jb@gcc.gnu.org>
100         PR libfortran/63589
101         * configure.ac: Check for strtok_r.
102         * runtime/main.c (gfstrtok_r): Fallback implementation of
103         strtok_r.
104         (find_addr2line): Use strtok_r to split PATH.
105         * config.h.in: Regenerated.
106         * configure: Regenerated.
108 2014-10-09  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
110         * ieee/ieee_helper.c (ieee_is_finite_*, ieee_is_nan_*,
111         ieee_is_negative_*, ieee_is_normal_*, ieee_copy_sign_*,
112         ieee_unordered_*, ieee_logb_*, ieee_rint_*, ieee_scalb_*,
113         ieee_rem_*, ieee_next_after_*): Remove functions.
114         * gfortran.map (GFORTRAN_1.5): Remove corresponding symbols.
116 2014-10-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
118         PR libgfortran/63460
119         * io/unit.c (init_units): Initialize the DELIM flag to
120         UNSPECIFIED for the STDIN unit so that the flag is
121         correctly set later.
123 2014-10-01  Janne Blomqvist  <jb@gcc.gnu.org>
125         * intrinsics/pack_generic.c (pack_s_internal): Fix
126         -Wmaybe-uninitialized warning.
127         * m4/unpack.m4 (unpack0_'rtype_code`): Likewise.
128         (unpack1_'rtype_code`): Likewise.
129         * generated/unpack_*.m4: Regenerated.
131 2014-09-30  Janne Blomqvist  <jb@gcc.gnu.org>
133         * configure.ac (AM_CFLAGS): Add
134         -Werror=implicit-function-declaration.
135         * Makefile.in: Regenerated.
136         * aclocal.m4: Regenerated.
137         * configure: Regenerated.
139 2014-09-25  Tobias Burnus  <burnus@net-b.de>
141         * caf/libcaf.h (_gfortran_caf_co_broadcast): New prototype.
142         * caf/single.c (_gfortran_caf_co_broadcast): New.
144 2014-09-18  Janne Blomqvist  <jb@gcc.gnu.org>
146         PR libfortran/62768
147         * io/inquire.c (inquire_via_unit): Use gfc_unit.filename also when
148         HAVE_TTYNAME{_R} is not defined.
150 2014-09-17  Janne Blomqvist  <jb@gcc.gnu.org>
152         PR libfortran/62768
153         * io/io.h (gfc_unit): Store C string for the filename.
154         * io/close.c (st_close): Use gfc_unit.filename.
155         * io/inquire.c (inquire_via_unit): Likewise.
156         * io/open.c (new_unit): Likewise.
157         (already_open): Likewise, unlink file before freeing filename.
158         * io/unit.c (init_units): Likewise.
159         (close_unit_1): Likewise.
160         (filename_from_unit): Likewise.
161         * io/unix.c (compare_file_filename): Likewise.
162         (find_file0): Likewise.
163         (delete_file): Likewise.
165 2014-09-10  Janne Blomqvist  <jb@gcc.gnu.org>
167         * io/transfer.c (read_block_form): Fix pad status check (found by
168         Thomas Schwinge with -Wlogical-not-parentheses).
170 2014-08-31  Tobias Burnus  <burnus@net-b.de>
172         * caf/libcaf.h (_gfortran_caf_send, _gfortran_caf_get,
173         _gfortran_caf_sendget): Update prototype.
174         * caf/single.c (_gfortran_caf_send, _gfortran_caf_get,
175         _gfortran_caf_sendget): Handle may_require_tmp.
177 2014-08-20  Steven G. Kargl  <kargl@gcc.gnu.org>
179         PR libgfortran/62188
180         * m4/bessel.m4: Avoid indexing off the end of an array.
181         * generated/bessel_r10.c: Regenerated.
182         * generated/bessel_r16.c: Ditto.
183         * generated/bessel_r4.c: Ditto.
184         * generated/bessel_r8.c: Ditto.
186 2014-08-14  Tobias Burnus  <burnus@net-b.de>
188         * caf/libcaf.h (caf_register_t): Update for critical.
189         (_gfortran_caf_critical, _gfortran_caf_end_critical): Remove.
190         (_gfortran_caf_lock, _gfortran_caf_unlock): Add.
191         * caf/single.c (_gfortran_caf_register): Handle locking
192         variables.
193         (_gfortran_caf_sendget): Re-name args for consistency.
194         (_gfortran_caf_lock, _gfortran_caf_unlock): Add.
196 2014-08-04  Jakub Jelinek  <jakub@redhat.com>
198         * runtime/memory.c (xmallocarray): Avoid division for the common case.
200 2014-07-20  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
202         PR libgfortran/61632
203         * io/format.c (format_error): Avoid invalid string pointer by
204         using the fortran string length values to generate error string.
205         (parse_format): Allocate the null terminator for the format
206         string.
208 2014-07-12  Tobias Burnus  <burnus@net-b.de>
210         * caf/libcaf.h (_gfortran_caf_atomic_define,
211         _gfortran_caf_atomic_ref, _gfortran_caf_atomic_op,
212         _gfortran_caf_atomic_cas): New prototypes.
213         * caf/single.c (_gfortran_caf_atomic_define,
214         _gfortran_caf_atomic_ref, _gfortran_caf_atomic_op,
215         _gfortran_caf_atomic_cas): New functions.
217 2014-07-10  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
219         * config/fpu-*.h (get_fpu_rounding_mode, set_fpu_rounding_mode,
220         support_fpu_rounding_mode): Clean up, mark unreachable code as such.
222 2014-07-09  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
224         * libgfortran.h (support_fpu_underflow_control,
225         get_fpu_underflow_mode, set_fpu_underflow_mode): New prototypes.
226         * config/fpu-*.h (support_fpu_underflow_control,
227         get_fpu_underflow_mode, set_fpu_underflow_mode):
228         New functions.
229         * ieee/ieee_arithmetic.F90: Support underflow control.
231 2014-07-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
233         * config/fpu-sysv.h (get_fpu_rounding_mode): Use FP_RN, FP_RP,
234         FP_RM, FP_RZ unconditionally.
235         (set_fpu_rounding_mode): Likewise.
237 2014-07-07  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
239         * libgfortran.h: Assume __GNUC__.
241 2014-07-07  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
243         * runtime/stop.c: Use C11 _Noreturn.
244         * libgfortran.h: Use C11 _Noreturn in prototypes.
245         Move REALPART, IMAGPART and COMPLEX_ASSIGN macros...
246         * intrinsics/c99_functions.c: ... here.
248 2014-07-07  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
250         * config/fpu-387.h, config/fpu-aix.h, config/fpu-sysv.h,
251         config/fpu-glibc.h: Use static assertions.
253 2014-07-05  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
255         * configure, config.h.in: Regenerate.
256         * config/fpu-sysv.h: Include <assert.h>.
258 2014-07-02  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
260         * config/fpu-glibc.h: Fix comment about FE_DENORMAL.
262 2014-07-02  Uros Bizjak  <ubizjak@gmail.com>
264         * configure.host (ieee_flags): Add -mieee for alpha*.
266         * config/fpu-glibc.h (support_fpu_rounding_mode): Correctly handle
267         GFC_FPE_UPWARD, GFC_FPE_DOWNWARD and GFC_FPE_TOWARDZERO.
268         * config/fpu-aix.h (support_fpu_rounding_mode): Ditto.
270 2014-06-29  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
272         * config/fpu-387.h (my_fenv_t): Amend structure so it also works
273         on mingw32.
275 2014-06-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
277         PR libgfortran/61640
278         * io/list_read.c (next_char_internal): Adjust the read length to
279         a single wide character. (eat_spaces): Add missing paren.
280         * io/unix.c (mem_read4): Use the correct mem_alloc function for
281         wide character internal reads.
283 2014-06-28  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
285         PR fortran/29383
286         * configure.host: Add checks for IEEE support, rework priorities.
287         * configure.ac: Define IEEE_SUPPORT, check for fpsetsticky and
288         fpresetsticky.
289         * configure: Regenerate.
290         * Makefile.am: Build new ieee files, install IEEE_* modules.
291         * Makefile.in: Regenerate.
292         * gfortran.map (GFORTRAN_1.6): Add new symbols.
293         * libgfortran.h (get_fpu_trap_exceptions, set_fpu_trap_exceptions,
294         support_fpu_trap, set_fpu_except_flags, support_fpu_flag,
295         support_fpu_rounding_mode, get_fpu_state, set_fpu_state): New
296         prototypes.
297         * config/fpu-*.h (get_fpu_trap_exceptions,
298         set_fpu_trap_exceptions, support_fpu_trap, set_fpu_except_flags,
299         support_fpu_flag, support_fpu_rounding_mode, get_fpu_state,
300         set_fpu_state): New functions.
301         * ieee/ieee_features.F90: New file.
302         * ieee/ieee_exceptions.F90: New file.
303         * ieee/ieee_arithmetic.F90: New file.
304         * ieee/ieee_helper.c: New file.
306 2014-06-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
308         PR libgfortran/61499
309         * io/list_read.c (eat_spaces): Use a 'for' loop instead of
310         'while' loop to skip the loop if there are no bytes left in the
311         string. Only seek if actual spaces can be skipped.
313 2014-06-25  Tobias Burnus  <burnus@net-b.de>
315         * caf/single.c (assign_char4_from_char1, assign_char1_from_char4,
316         convert_type): New static functions.
317         (_gfortran_caf_get, _gfortran_caf_send): Use them.
319 2014-06-19  Tobias Burnus  <burnus@net-b.de>
321         * caf/single.c (_gfortran_caf_co_sum, _gfortran_caf_co_max,
322         _gfortran_caf_co_min): Fix stat setting.
324 2014-06-17  Tobias Burnus  <burnus@net-b.de>
326         * caf/libcaf.h (gfc_descriptor_t): New typedef.
327         (caf_vector_t): Update.
328         (_gfortran_caf_co_sum, _gfortran_caf_co_max, _gfortran_caf_co_min):
329         Remove vector-subscript argument.
330         (_gfortran_caf_co_send, _gfortran_caf_co_get,
331         _gfortran_caf_co_sendget): New.
332         * caf/single.c (_gfortran_caf_co_sum, _gfortran_caf_co_max,
333         _gfortran_caf_co_min): Remove vector-subscript argument.
334         (_gfortran_caf_co_send, _gfortran_caf_co_get,
335         _gfortran_caf_co_sendget): New.
337 2014-06-17  Janne Blomqvist  <jb@gcc.gnu.org>
339         * libgfortran.h (xmallocarray): New prototype.
340         * runtime/memory.c (xmallocarray): New function.
341         (xcalloc): Check for nonzero separately instead of multiplying.
342         * generated/*.c: Regenerated.
343         * intrinsics/cshift0.c (cshift0): Call xmallocarray instead of
344         xmalloc.
345         * intrinsics/eoshift0.c (eoshift0): Likewise.
346         * intrinsics/eoshift2.c (eoshift2): Likewise.
347         * intrinsics/pack_generic.c (pack_internal): Likewise.
348         (pack_s_internal): Likewise.
349         * intrinsics/reshape_generic.c (reshape_internal): Likewise.
350         * intrinsics/spread_generic.c (spread_internal): Likewise.
351         (spread_internal_scalar): Likewise.
352         * intrinsics/string_intrinsics_inc.c (string_trim): Likewise.
353         (string_minmax): Likewise.
354         * intrinsics/transpose_generic.c (transpose_internal): Likewise.
355         * intrinsics/unpack_generic.c (unpack_internal): Likewise.
356         * io/list_read.c (nml_touch_nodes): Don't cast xmalloc return value.
357         * io/transfer.c (st_set_nml_var): Call xmallocarray instead of
358         xmalloc.
359         * io/unit.c (get_internal_unit): Likewise.
360         (filename_from_unit): Don't cast xmalloc return value.
361         * io/write.c (nml_write_obj): Likewise, formatting.
362         * m4/bessel.m4 (bessel_jn_r'rtype_kind`): Call xmallocarray
363         instead of xmalloc.
364         (besse_yn_r'rtype_kind`): Likewise.
365         * m4/cshift1.m4 (cshift1): Likewise.
366         * m4/eoshift1.m4 (eoshift1): Likewise.
367         * m4/eoshift3.m4 (eoshift3): Likewise.
368         * m4/iforeach.m4: Likewise.
369         * m4/ifunction.m4: Likewise.
370         * m4/ifunction_logical.m4 (name`'rtype_qual`_'atype_code):
371         Likewise.
372         * m4/in_pack.m4 (internal_pack_'rtype_ccode`): Likewise.
373         * m4/matmul.m4 (matmul_'rtype_code`): Likewise.
374         * m4/matmull.m4 (matmul_'rtype_code`): Likewise.
375         * m4/pack.m4 (pack_'rtype_code`): Likewise.
376         * m4/reshape.m4 (reshape_'rtype_ccode`): Likewise.
377         * m4/shape.m4 (shape_'rtype_kind`): Likewise.
378         * m4/spread.m4 (spread_'rtype_code`): Likewise.
379         (spread_scalar_'rtype_code`): Likewise.
380         * m4/transpose.m4 (transpose_'rtype_code`): Likewise.
381         * m4/unpack.m4 (unpack0_'rtype_code`): Likewise.
382         (unpack1_'rtype_code`): Likewise.
383         * runtime/convert_char.c (convert_char1_to_char4): Likewise.
384         (convert_char4_to_char1): Simplify.
385         * runtime/environ.c (init_unformatted): Call xmallocarray instead
386         of xmalloc.
387         * runtime/in_pack_generic.c (internal_pack): Likewise.
389 2014-06-15  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
391         PR libfortran/60468
392         * configure.ac: Include <math.h> when checking for fp_except_t
393         and fp_rnd_t types.
394         * configure: Regenerate.
396 2014-06-08  Janne Blomqvist  <jb@gcc.gnu.org>
398         PR libfortran/56981
399         * io/unix.h (struct stream_vtable): Add new member function,
400         markeor.
401         (smarkeor): New inline function.
402         (flush_if_unbuffered): Remove prototype.
403         * io/unix.c (raw_markeor): New function.
404         (raw_vtable): Initialize markeor member.
405         (buf_markeor): New function.
406         (buf_vtable): Initialize markeor member.
407         (mem_vtable): Likewise.
408         (mem4_vtable): Likewise.
409         (flush_if_unbuffered): Remove function.
410         * io/transfer.c (next_record): Call smarkeor instead of
411         flush_if_unbuffered.
413 2014-05-27  Uros Bizjak  <ubizjak@gmail.com>
415         * intrinsics/getcwd.c: Include stdlib.h.
417 2014-05-26  Janne Blomqvist  <jb@gcc.gnu.org>
419         * libgfortran.h (xrealloc): New prototype.
420         * runtime/memory.c (xrealloc): New function.
421         * io/fbuf.c (fbuf_alloc): Use xrealloc.
422         * io/list_read.c (push_char_default): Likewise.
423         (push_char4): Likewise.
425 2014-05-26  Janne Blomqvist  <jb@gcc.gnu.org>
427         PR libfortran/61310
428         * intrinsics/ctime.c (strctime): Rename to gf_ctime, use snprintf
429         instead of strftime.
430         (fdate): Use gf_ctime.
431         (fdate_sub): Likewise.
432         (ctime): Likewise.
433         (ctime_sub): Likewise.
435 2014-05-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
437         PR libgfortran/55117
438         * io/list_read.c (extended_look_ahead): New helper function to
439         scan the namelist name and look for matches with the new '+'
440         extended type parent indicator.  (str_comp_extended): New
441         helper function to compare the namelist name with the varname
442         namelist. (find_nml_name): Use the new helper functions to match
443         the extended type varnames.
445 2014-05-23  Jerry DeLisle  <jvdelisle@gcc.gnu>
447         PR libfortran/61173
448         * io/list_read.c (eat_spaces): If the next character pointed to
449         is a space, don't seek, must be at the end.
451 2014-05-23  Hans-Peter Nilsson  <hp@axis.com>
453         * configure.ac [with_newlib] (HAVE_STRNLEN, HAVE_STRNDUP): Define.
454         * configure: Regenerate.
456 2014-05-23  Janne Blomqvist  <jb@gcc.gnu.org>
458         PR libfortran/60324
459         * runtime/string.c: Include stdlib.h.
461 2014-05-22  Janne Blomqvist  <jb@gcc.gnu.org>
463         PR libfortran/60324
464         * config.h.in: Regenerated.
465         * configure: Regenerated.
466         * configure.ac (AC_CHECK_FUNCS_ONCE): Check for strnlen and
467         strndup.
468         * libgfortran.h (fc_strdup): New prototype.
469         * runtime/string.c (strnlen): New fallback function.
470         (strndup): New fallback function.
471         (fc_strdup): New function.
472         * io/close.c (st_close): Use fc_strdup.
473         * io/open.c (new_unit): Likewise.
474         (already_open): Likewise.
475         * io/unit.c (filename_from_unit): Likewise.
476         * io/unix.c (unpack_filename): Remove function.
477         (regular_file): Rename to regular_file2, add path argument.
478         (regular_file): New function calling regular_file2.
479         (compare_file_filename): Use fc_strdup.
480         (find_file): Likewise.
481         (delete_file): Likewise.
482         (file_exists): Likewise.
483         (file_size): Likewise.
484         (inquire_sequential): Likewise.
485         (inquire_direct): Likewise.
486         (inquire_formatted): Likewise.
487         (inquire_access): Likewise.
488         * io/unix.h (unpack_filename): Remove prototype.
489         * runtime/main.c (please_free_exe_path_when_done): Change type to
490         bool.
491         (store_exe_path): Use malloced buffer, grow as needed.
493 2014-05-17  Jerry DeLisle  <jvdelisle@gcc.gnu>
495         PR libfortran/52539
496         * io/io.h (gfc_unit): New function pointers *next_char_fn_ptr
497         and *push_char_fn_ptr.
498         *io/list_read.c (next_char): Create macro with this name to call
499         the new function pointer. Split the original next_char function
500         into three new functions. (next_char_default, next_char_internal,
501         next_char_utf8): New functions. (push_char): Create macro with
502         this name to call new function pointer. Split the original
503         push_char into three new functions. (push_char_default,
504         push_char_internal, push_char4): New functions. (set_workers):
505         New function to initilize the function pointers depending on the
506         type of IO to be performed. (list_formatted_read_scalar): Use
507         set_workers function. (finish_list_read): Likewise.
508         (namelist_read): Likewise.
509         (nml_get_obj_data): Use push_char_default.
511 2014-05-16  Janne Blomqvist  <jb@gcc.gnu.org>
513         PR libfortran/61187
514         * io/unix.c (raw_close): Check if s->fd is -1.
515         (fd_to_stream): Check return value of fstat(), handle error.
517 2014-05-12  Janne Blomqvist  <jb@gcc.gnu.org>
519         PR libfortran/61035
520         * intrinsics/getcwd.c (getcwd_i4_sub): Avoid potentially large
521         stack allocation, avoid extra copying in the common case.
523 2014-05-12  Janne Blomqvist  <jb@gcc.gnu.org>
525         * configure.ac (AM_CFLAGS): Use -std=gnu11.
526         (CFLAGS): Likewise.
527         * configure: Regenerated.
529 2014-05-11  Tobias Burnus  <burnus@net-b.de>
531         * caf/libcaf.h (_gfortran_caf_num_images): Change type of
532         second argument to int.
533         * caf/mpi.c (_gfortran_caf_num_images): Ditto.
534         * caf/single.c (_gfortran_caf_num_images): Ditto.
536 2014-05-08  Tobias Burnus  <burnus@net-b.de>
538         * caf/libcaf.h (caf_vector_t, _gfortran_caf_co_sum,
539         _gfortran_caf_co_min, _gfortran_caf_co_max): Declare
540         * caf/single.c
542 2014-05-06  Jerry DeLisle  <jvdelisle@gcc.gnu>
544         PR libfortran/61049
545         * io/list_read.c (list_formatted_read_scalar): Use eat_separator
546         and delete extraneous code.
548 2014-04-30  Tobias Burnus  <burnus@net-b.de>
550         * caf/libcaf.h (_gfortran_caf_this_image, _gfortran_caf_num_images):
551         New prototypes.
552         (_gfortran_caf_init): Change prototype.
553         (mpi_token_t): New typedef.
554         (TOKEN): New define.
555         * caf/mpi.c (_gfortran_caf_this_image, _gfortran_caf_num_images):
556         New functions.
557         (_gfortran_caf_init): Update.
558         (_gfortran_caf_finalize, _gfortran_caf_register,
559         _gfortran_caf_deregister): Use mpi_token_t.
560         * caf/single.c (_gfortran_caf_this_image, _gfortran_caf_num_images):
561         New functions.
562         (_gfortran_caf_init): Update.
563         (_gfortran_caf_finalize, _gfortran_caf_register,
564         _gfortran_caf_deregister): Use mpi_token_t, simplify.
566 2014-04-26  Jerry DeLisle  <jvdelisle@gcc.gnu>
568         PR libfortran/52539
569         * io/list_read.c: Add uchar typedef. (push_char4): New function
570         to save kind=4 character. (next_char_utf8): New function to read
571         a single UTF-8 encoded character value. (read_chracter): Update
572         to use the new functions for reading UTF-8 strings.
573         (list_formatted_read_scalar): Update to handle list directed
574         reads of UTF-8 strings. (nml_read_obj): Likewise update for
575         UTF-8 strings in namelists.
576         * io/write.c (nml_write_obj): Add kind=4 character support for
577         namelist writes.
579 2014-04-24  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
581         * configure.ac: Quote usage of ac_cv_func_clock_gettime in if test.
582         * configure: Regenerate.
584 2014-04-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
586         * config/fpu-387.h [__sun__ && __svr4__]: Remove SSE execution
587         check.
589 2014-04-11  Jerry DeLisle  <jvdelisle@gcc.gnu>
591         PR libfortran/60810
592         io/unit.c (is_trim_ok): If internal unit is array, do not trim.
594 2014-03-21  Jerry DeLisle  <jvdelisle@gcc.gnu>
596         PR libfortran/60148
597         * io/transfer.c (data_transfer_init): If std= was specified, set
598         delim status to DELIM_NONE of no other was specified.
600 2014-03-18  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
602         * configure.ac: Check for presence of fcntl.
603         * configure: Regenerate.
604         * config.h.in: Regenerate.
605         * io/unix.c (set_close_on_exec): Check for HAVE_FCNTL.
607 2014-03-17  Jerry DeLisle  <jvdelisle@gcc.gnu>
609         PR libfortran/48600
610         * io/list_read.c (list_formatted_read_scalar): Do not use
611         eat_separator. Explicitly set the comma and end-of-line flags.
612         Check for END condition from finish_separator.
614 2014-03-15  Jerry DeLisle  <jvdelisle@gcc.gnu>
616         PR libfortran/58324
617         * io/list_read.c (finish_list_read): Read one character to check
618         for the end of the file.  If it is the end, then issue the file
619         end error message.  If not, use eat_line to reach the end
620         without giving error.  The next attempt to read will then
621         issue the error as described above.
623 2014-03-12  Jerry DeLisle  <jvdelisle@gcc.gnu>
625         PR libfortran/38199
626         * io/read.c (read_decimal): Quickly skip spaces to avoid calls
627         to next_char.
628         * io/unit.c (is_trim_ok): New helper function to check various
629         conditions to see if its OK to trim the internal unit string.
630         (get_internal_unit): Use LEN_TRIM to shorten selected internal
631         unit strings for optimizing READ. Enable this optimization for
632         formatted READ.
633         * io/list_read.c (finish_list_read): Don't call eat_line for
634         internal units.
636 2014-03-08  Jerry DeLisle  <jvdelisle@gcc.gnu>
638         PR libfortran/38199
639         * io/list_read.c (next_char): Mark unlikely error checks.
640         (eat_spaces): For character array reading, skip ahead over
641         spaces rather than call next_char multiple times.
643 2014-03-08  Tobias Burnus  <burnus@net-b.de>
645         * libgfortran.h (unlikely, likely): Add usage comment.
647 2014-03-08  Dominique d'Humieres  <dominiq@lps.ens.fr>
649         PR libgfortran/60128
650         * io/write_float.def (output_float): Remove unused variable
651         nzero_real. Replace a double space with a single one.
652         (determine_en_precision): Fix wrong handling of the EN format.
654 2014-03-03  Jerry DeLisle  <jvdelisle@gcc.gnu>
656         PR libfortran/60148
657         * io/inquire.c (inquire_via_unit): In the case of
658         DELIM_UNSPECIFIED set inquire return string to "NONE".
659         * io/list_read.c (read_character): In the case of DELIM_NONE and
660         namelists, complete the character read using the namelist
661         variable length.
662         * io/open.c (new_unit): Don't set delim status to none if not
663         specified so that DELIM_UNSPECIFIED can be used later.
664         * io/transfer.c (data_transfer_init): For namelist I/O, if the
665         unit delim status is unspecified set the current status to quote.
666         Otherwise, set current status to the unit status.
667         * io/unit.c (get_internel_unit, init_unit): Remember to set
668         flags_delim initially to DELIM_UNSPECIFIED so defaults come out
669         correctly.
670         * io/write.c (write_character): Add a new function argument
671         "mode" to signify that raw output is to be used vs output with
672         delimiters. If the mode is set to DELIM (1) proceed with
673         delimiters. (list_formatted_write_scalar): Write the separator
674         only if a delimiter was previously specified. Update the call to
675         write_character with the mode argument given.
676         (namelist_write_newline): Use the mode argument. (nml_write_obj):
677         Use the mode argument. Remove use of tmp_delim. Write the
678         semi-colon or comma correctly only when needed with using
679         delimiters. Cleanup whitespace.
680         (namelist_write): If delim is not specified in namelist I/O,
681         default to using quotes. Get rid of the tmp_delim variable and
682         use the new mode argument in write_character.
684 2014-02-21  Tobias Burnus  <burnus@net-b.de>
686         PR fortran/60286
687         * libgfortran/io/inquire.c (yes, no): New static const char vars.
688         (inquire_via_unit): Use them. Use OPEN mode instead of using
689         POSIX's access to query about write=, read= and readwrite=.
691 2014-01-20  Jerry DeLisle  <jvdelisle@gcc.gnu>
692             Dominique d'Humieres  <dominiq@lps.ens.fr>
694         * io/write_float.def (output_float): Remove inadvertent test
695         code from previous patch.
697 2014-01-19  Jerry DeLisle  <jvdelisle@gcc.gnu>
698             Dominique d'Humieres  <dominiq@lps.ens.fr>
700         PR libfortran/59771
701         PR libfortran/59774
702         PR libfortran/59836
703         * io/write_float.def (output_float): Fix wrong handling of the
704         Fw.0 format.
705         (output_float_FMT_G_): Fixes rounding issues with -m32.
707 2014-01-11  Jerry DeLisle  <jvdelisle@gcc.gnu>
708             Dominique d'Humieres  <dominiq@lps.ens.fr>
709             Steven G. Kargl  <kargl@gcc.gnu.org>
711         PR libfortran/59700
712         PR libfortran/59764
713         * io/io.h (struct st_parameter_dt): Assign expanded_read flag to
714         unused bit. Define new variable line_buffer_pos.
715         * io/list_read.c (free_saved, next_char, l_push_char,
716         read_logical, read_real): Replace use of item_count with
717         line_buffer_pos for line_buffer look ahead.
718         (read_logical, read_integer, parse_real, read_real, check_type):
719         Adjust location of free_line to after generating error messages
720         to retain the correct item count for the message.
722 2014-01-02  Richard Sandiford  <rdsandiford@googlemail.com>
724         Update copyright years
726 Copyright (C) 2013-2014 Free Software Foundation, Inc.
728 Copying and distribution of this file, with or without modification,
729 are permitted in any medium without royalty provided the copyright
730 notice and this notice are preserved.