Add _FloatN, _FloatNx tests for __builtin_fpclassify.
[official-gcc.git] / libgfortran / ChangeLog
blob3edd9eda2d5a446cc88f65392fb5f2473f79ee64
1 2016-09-21  Janne Blomqvist  <jb@gcc.gnu.org>
3         * intrinsics/random.c (getosrandom): Use rand_s() on
4         MinGW-w64. Fix bounds overflow in fallback code.
6 2016-09-19  Andre Vehreschild  <vehre@gcc.gnu.org>
8         * caf/libcaf.h: Add caf_reference_type.
9         * caf/mpi.c: Adapted signature of caf_register().
10         * caf/single.c (struct caf_single_token): Added to keep the pointer
11         to the memory registered and array descriptor.
12         (caf_internal_error): Added convenience interface.
13         (_gfortran_caf_register): Adapted to work with caf_single_token and
14         return memory in the array descriptor.
15         (_gfortran_caf_deregister): Same.
16         (assign_char1_from_char4): Fixed style.
17         (convert_type): Fixed incorrect conversion.
18         (_gfortran_caf_get): Adapted to work with caf_single_token.
19         (_gfortran_caf_send): Same.
20         (_gfortran_caf_sendget): Same.
21         (copy_data): Added to stop repeating it in all _by_ref functions.
22         (get_for_ref): Recursive getting of coarray data using a chain of
23         references.
24         (_gfortran_caf_get_by_ref): Driver for computing the memory needed for
25         the get and checking properties of the operation.
26         (send_by_ref): Same as get_for_ref but for sending data.
27         (_gfortran_caf_send_by_ref): Same like caf_get_by_ref but for sending.
28         (_gfortran_caf_sendget_by_ref): Uses get_by_ref and send_by_ref to
29         implement sendget for reference chains.
30         (_gfortran_caf_atomic_define): Adapted to work with caf_single_token.
31         (_gfortran_caf_atomic_ref): Likewise.
32         (_gfortran_caf_atomic_cas): Likewise.
33         (_gfortran_caf_atomic_op): Likewise.
34         (_gfortran_caf_event_post): Likewise.
35         (_gfortran_caf_event_wait): Likewise.
36         (_gfortran_caf_event_query): Likewise.
37         (_gfortran_caf_lock): Likewise.
38         (_gfortran_caf_unlock): Likewise.
40 2016-09-09  Steven G. Kargl  <kargl@gcc.gnu.org>
42         PR fortran/77507
43         * ieee/ieee_arithmetic.F90 (IEEE_VALUE_4,IEEE_VALUE_8,IEEE_VALULE_10,
44         IEEE_VALUE_16):  Use correct keyword.
46 2016-09-06  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
48         PR libgfortran/77393
49         * io/write_float.def (build_float_string): Recognize when the
50         result will not fit in the user provided, star fill, and exit
51         early.
53 2016-08-31  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
55         PR libgfortran/77393
56         * io/write.c (kind_from_size): New function to calculate required buffer
57         size based on kind type. (select_buffer, select_string): Use new
58         function. (write_float_0, write_real, write_real_g0, write_complex):
59         Adjust calls to pass parameters needed by new function.
61 2016-08-31  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
62         Paul Thomas  <pault@gcc.gnu.org>
64         PR libgfortran/48298
65         * gfortran.map : Flag _st_set_nml_dtio_var and
66         _gfortran_transfer_derived.
67         * io/format.c (format_lex): Detect DTIO formatting.
68         (parse_format_list): Parse the DTIO format.
69         (next_format): Include FMT_DT.
70         * io/format.h : Likewise. Add structure 'udf' to structure
71         'fnode' to carry the IOTYPE string and the 'vlist'.
72         * io/io.h : Add prototypes for the two types of DTIO subroutine
73         and a typedef for gfc_class. Also, add to 'namelist_type'
74         fields for the pointer to the DTIO procedure and the vtable.
75         Add fields to struct st_parameter_dt for pointers to the two
76         types of DTIO subroutine. Add to gfc_unit DTIO specific fields.
77         (internal_proto): Add prototype for 'read_user_defined' and
78         'write_user_defined'.
79         * io/list_read.c (check_buffers): Use the 'current_unit' field.
80         (unget_char): Likewise.
81         (eat_spaces): Likewise.
82         (list_formatted_read_scalar): For case BT_CLASS, call the DTIO
83         procedure.
84         (nml_get_obj_data): Likewise when DTIO procedure is present,.
85         * io/transfer.c : Export prototypes for 'transfer_derived' and
86         'transfer_derived_write'.
87         (unformatted_read): For case BT_CLASS, call the DTIO procedure.
88         (unformatted_write): Likewise.
89         (formatted_transfer_scalar_read): Likewise.
90         (formatted_transfer_scalar_write: Likewise.
91         (transfer_derived): New function.
92         (data_transfer_init): Set last_char if no child_dtio.
93         (finalize_transfer): Return if child_dtio set.
94         (st_write_done): Add condition for child_dtio not set.
95         Add extra arguments for st_set_nml_var prototype.
96         (set_nml_var): New function that contains the contents of the
97         old version of st_set_nml_var. Also sets the 'dtio_sub' and
98         'vtable' fields of the 'nml' structure.
99         (st_set_nml_var): Now just calls set_nml_var with 'dtio_sub'
100         and 'vtable' NULL.
101         (st_set_nml_dtio_var): New function that calls set_nml_var.
102         * io/unit.c (get_external_unit): If the found unit child_dtio
103         is non zero, don't do any mutex locking/unlocking.  Just
104         return the unit.
105         * io/unix.c (tempfile_open): Revert to C style comment.
106         * io/write.c (list_formatted_write_scalar): Do the DTIO call.
107         (nml_write_obj): Add BT_CLASS and do the DTIO call.
109 2016-08-29  Nathan Sidwell  <nathan@acm.org>
111         * configure.ac (nvptx-*): Hardwire newlib.
112         * configure: Rebuilt.
114 2016-08-19  Janne Blomqvist  <jb@gcc.gnu.org>
116         * intrinsics/random.c (xor_keys): New array with "secret" keys.
117         (scramble_seed): XOR given seed with xor_keys array rather than
118         shuffling bytes.
119         (unscramble_seed): Remove function.
120         (random_seed_i4): Use new scramble_seed.
121         (random_seed_i8): Likewise.
123 2016-08-19  Janne Blomqvist  <jb@gcc.gnu.org>
125         * intrinsics/random.c (master_init): New variable.
126         (init_rand_state): Move below getosrandom (), maybe initialize
127         master_state.
128         (random_seed_i4): If called with no arguments, set master_init to
129         false, and reinitialize. If called with PUT=, set master_init to
130         true.
131         (random_seed_i8): Likewise.
133 2016-08-11  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
135         * intrinsics/random.c: Include <stdlib.h>.
137 2016-08-11  Janne Blomqvist  <jb@gcc.gnu.org>
139         * intrinsics/random.c: Replace KISS with xorshift1024* using
140         per-thread state.
141         * runtime/main.c (init): Don't call random_seed_i4.
143 2016-07-22  Andre Vehreschild  <vehre@gcc.gnu.org>
145         * caf/libcaf.h: Add parameter stat to caf_get() and
146         caf_send()'s function prototypes.
147         * caf/single.c (_gfortran_caf_get): Implement reporting
148         error using stat instead of abort().
149         (_gfortran_caf_send): Same.
150         (_gfortran_caf_sendget): Use NULL for stat when calling
151         caf_send().
153 2016-06-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
155         PR libgfortran/48852
156         * io/write.c: Cleaned up whitespace.
157         (write_d, write_e, write_f, write_es, write_en): Use new helper
158         function write_float_0.
159         (write_float_0): New helper function.
160         (get_precision, select_buffer, select_string, write_float_string): New
161         helper functions used in remaining float writing functions.
162         Helper function write_float_string now contains code for writing
163         to kind=4 character internal units.
164         (write_real): Modified to establish working buffers at this level
165         and to  use new helper functions.
166         (write_real_g0): Likewise modified.
167         (write_complex): Likewise modified. Gets both float strings before
168         output so that final lengths can be determined which allows right
169         justifying the complex number with no intervening spaces.
170         * io/write_float.def (build_float_string): Renamed from previosly
171         output_float, modified to use buffers passed in from higher functions,
172         builds a null terminated string of the floating point value. Character
173         kind=4 code eliminated.
174         (write_infnan): Likewise modified to use incoming buffers and eliminate
175         kind=4 related code.
176         (OUTPUT_FLOAT_FMT_G): Deleted, functionality moved into FORMAT_FLOAT.
177         (FORMAT_FLOAT): Renamed macro from WRITE_FLOAT. Use build_float_string.
178         (get_float_string): Renamed from write_float, uses FORMAT_FLOAT macro.
179         Buffer allocation removed, now at higher level.
181 2016-05-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
183         PR libgfortran/71123
184         * io/list_read (eat_spaces): Eat '\r' as part of spaces.
186 2016-04-19  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
188         PR libgfortran/70684
189         * io/list_read (check_buffers): Add '\r' to check for end of line.
191 2016-03-30  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
192             Dominique d'Humieres  <dominiq@lps.ens.fr>
194         PR libgfortran/70235
195         * io/write_float.def: Fix PF format for negative values of the scale
196         factor.
198 2016-03-28  Alessandro Fanfarillo  <fanfarillo.gcc@gmail.com>
200         * caf/libcaf.h: caf_stop_numeric and caf_stop_str prototype.
201         * caf/single.c: _gfortran_caf_stop_numeric and
202         _gfortran_caf_stop_str implementation.
204 2016-02-23  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
206         PR libgfortran/69456
207         * io/list_read.c (read_real): If digit is missing from exponent issue
208         an error. (parse_real): Likewise and adjusted error message to clarify
209         it is part of a complex number.
210         (nml_read_obj): Bump item count and add comment that this is used to
211         identify which item in a namelist read has a problem.
213 2016-02-17  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
215         PR libgfortran/69651
216         * io/list_read.c (push_char4): Fix the pointer usage for xrealloc.
218 2016-02-15  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
220         PR libgfortran/69651
221         * io/list_read.c: Entire file trailing spaces removed.
222         (CASE_SEPARATORS): Remove '!'.
223         (is_separator): Add namelist mode as condition with '!'.
224         (push_char): Remove un-needed memset. (push_char4): Likewise and remove
225         'new' pointer. (eat_separator): Remove un-needed use of notify_std.
226         (read_logical): If '!' bang encountered when not in namelist mode got
227         bad_logical to give an error. (read_integer): Likewise reject '!'.
228         (read_character): Remove condition testing c = '!' which is now inside
229         the is_separator macro. (parse_real): Reject '!' unless in namelist mode.
230         (read_complex): Reject '!' unless in namelist mode. (read_real): Likewise
231         reject '!'.
233 2016-02-12  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
235         PR libgfortran/69668
236         * io/list_read.c (read_character): Remove code related to DELIM_NONE.
238 2016-01-23  John David Anglin  <danglin@gcc.gnu.org>
240         PR libfortran/68744
241         * runtime/backtrace.c: Include gthr.h.
242         (show_backtrace): Use __gthread_active_p() to determine whether threads
243         are active.  Return if lbstate is NULL.
245 2016-01-15  Jakub Jelinek  <jakub@redhat.com>
247         * intrinsics/execute_command_line.c (set_cmdstat): Use "%s", msg
248         instead of msg to avoid -Wformat-security warning.
250 2016-01-04  Jakub Jelinek  <jakub@redhat.com>
252         Update copyright years.
254 Copyright (C) 2016 Free Software Foundation, Inc.
256 Copying and distribution of this file, with or without modification,
257 are permitted in any medium without royalty provided the copyright
258 notice and this notice are preserved.