ChangeLog-2014 27 KB

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