]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/fortran/ChangeLog
re PR fortran/79602 (translation: globally replace '%s' with %qs)
[thirdparty/gcc.git] / gcc / fortran / ChangeLog
1 2017-03-22 Dominique d'Humieres <dominiq@lps.ens.fr>
2
3 PR fortran/79602
4 * decl.c: Replace '%s' with %qs.
5 * expr.c: Likewise.
6 * interface.c: Likewise.
7 * match.c: Likewise.
8 * primary.c: Likewise.
9 * resolve.c: Likewise.
10
11 PR fortran/79844
12 PR fortran/80011
13 * io.c: Remove trailing spaces.
14 * match.c: Likewise.
15 * openmp.c: Likewise.
16 * resolve.c: Likewise.
17 * trans-intrinsic.c: Likewise.
18
19 PR fortran/79853
20 * expr.c: Remove a double spaces.
21
22 PR fortran/79859
23 * primary.c: Remove spurious quotes around %qs.
24
25 2017-03-22 Thomas Koenig <tkoenig@gcc.gnu.org>
26
27 PR fortran/80142
28 * frontend-passes.c (combine_array_constructor): Take
29 location of new expression from constructor expression instead
30 of constructor.
31
32 2017-03-18 Paul Thomas <pault@gcc.gnu.org>
33
34 PR fortran/79676
35 * module.c (mio_symbol_attribute): Remove reset of the flag
36 'no_module_procedures'.
37 (check_for_module_procedures): New function. Move declaration
38 of 'no_module_procedures' to above it.
39 (gfc_dump_module): Traverse namespace calling new function.
40
41 2017-03-18 Paul Thomas <pault@gcc.gnu.org>
42
43 PR fortran/71838
44 * symbol.c (check_conflict): A dummy procedure in a submodule,
45 module procedure is not an error.
46 (gfc_add_flavor): Ditto.
47
48 2017-03-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
49
50 PR fortran/79841
51 * openmp.c (check_symbol_not_pointer): Adjust diagnostics.
52
53 2017-03-16 Jakub Jelinek <jakub@redhat.com>
54
55 PR fortran/80010
56 * parse.c (gfc_ascii_statement): Use !$ACC for ST_OACC_ATOMIC
57 and ST_OACC_END_ATOMIC, instead of !ACC.
58 * trans-decl.c (finish_oacc_declare): Use !$ACC instead of $!ACC.
59 * openmp.c (gfc_match_oacc_declare, gfc_match_oacc_wait,
60 gfc_resolve_oacc_declare): Likewise.
61
62 PR fortran/79886
63 * error.c (gfc_format_decoder): Rename plus argument to set_locus,
64 remove ATTRIBUTE_UNUSED from all arguments, call default_tree_printer
65 if not a Fortran specific spec.
66 * trans-io.c: Include options.h.
67 (gfc_build_st_parameter): Temporarily disable -Wpadded around layout
68 of artificial IO data structures.
69
70 2017-03-15 David Malcolm <dmalcolm@redhat.com>
71
72 PR fortran/79860
73 * resolve.c (resolve_contained_fntype): Make error messages more
74 amenable to translation.
75
76 2017-03-06 Richard Biener <rguenther@suse.de>
77
78 PR fortran/79894
79 * trans.c (gfc_add_modify_loc): Weaken assert.
80
81 2017-03-05 Andre Vehreschild <vehre@gcc.gnu.org>,
82 Alessandro Fanfarillo <fanfarillo.gcc@gmail.com>
83
84 * check.c (positive_check): Add new function checking constant for
85 being greater then zero.
86 (gfc_check_image_status): Add checking of image_status arguments.
87 (gfc_check_failed_or_stopped_images): Same but for failed_- and
88 stopped_images function.
89 * dump-parse-tree.c (show_code_node): Added output of FAIL IMAGE.
90 * gfortran.h (enum gfc_statement): Added FAIL_IMAGE_ST.
91 (enum gfc_isym_id): Added new intrinsic symbols.
92 (enum gfc_exec_op): Added EXEC_FAIL_IMAGE.
93 * gfortran.texi: Added description for the new API functions. Updated
94 coverage of gfortran of TS18508.
95 * intrinsic.c (add_functions): Added symbols to resolve new intrinsic
96 functions.
97 * intrinsic.h: Added prototypes.
98 * iresolve.c (gfc_resolve_failed_images): Resolve the failed_images
99 intrinsic.
100 (gfc_resolve_image_status): Same for image_status.
101 (gfc_resolve_stopped_images): Same for stopped_images.
102 * libgfortran.h: Added prototypes.
103 * match.c (gfc_match_if): Added matching of FAIL IMAGE statement.
104 (gfc_match_fail_image): Match a FAIL IMAGE statement.
105 * match.h: Added prototype.
106 * parse.c (decode_statement): Added matching for FAIL IMAGE.
107 (next_statement): Same.
108 (gfc_ascii_statement): Same.
109 * resolve.c: Same.
110 * simplify.c (gfc_simplify_failed_or_stopped_images): For COARRAY=
111 single a constant result can be returne.d
112 (gfc_simplify_image_status): For COARRAY=single the result is constant.
113 * st.c (gfc_free_statement): Added FAIL_IMAGE handling.
114 * trans-decl.c (gfc_build_builtin_function_decls): Added decls of the
115 new intrinsics.
116 * trans-expr.c (gfc_conv_procedure_call): This is first time all
117 arguments of a function are optional, which is now handled here
118 correctly.
119 * trans-intrinsic.c (conv_intrinsic_image_status): Translate
120 image_status.
121 (gfc_conv_intrinsic_function): Add support for image_status.
122 (gfc_is_intrinsic_libcall): Add support for the remaining new
123 intrinsics.
124 * trans-stmt.c (gfc_trans_fail_image): Trans a fail image.
125 * trans-stmt.h: Add the prototype for the above.
126 * trans.c (trans_code): Dispatch for fail_image.
127 * trans.h: Add the trees for the new intrinsics.
128
129 2017-03-03 Jerry DeLisle <jvdelisle@gcc.gnu.org>
130
131 PR fortran/79841
132 * openmp.c (check_symbol_not_pointer): Adjust diagnostic.
133
134 2017-02-28 Paul Thomas <pault@gcc.gnu.org>
135
136 PR fortran/79739
137 * resolve.c (resolve_fl_procedure): Deal with the case where
138 'submodule_name' is NULL so that gfc_error does not ICE.
139 Reformat the error message to make it more consistent.
140
141 2017-02-28 Jakub Jelinek <jakub@redhat.com>
142
143 * parse.c (parse_critical_block): Use cond ? G_("...") : G_("...")
144 instead of just cond ? "..." : "...".
145 * scanner.c (gfc_next_char_literal): Likewise.
146 * match.c (match_exit_cycle): Likewise.
147
148 2017-02-26 Thomas Koenig <tkoenig@gcc.gnu.org>
149
150 PR fortran/51119
151 * options.c (gfc_post_options): Set default limit for matmul
152 inlining to 30.
153 * invoke.texi: Document change.
154
155 2017-02-25 Dominique d'Humieres <dominiq@lps.ens.fr>
156
157 PR fortran/79601
158 * interface.c (check_dtio_arg_TKR_intent): Change 'intent'
159 to 'INTENT'.
160
161 2017-02-25 Dominique d'Humieres <dominiq@lps.ens.fr>
162
163 PR fortran/79597
164 * interface.c (gfc_match_end_interface): Remove spurious comma
165 and space, replace 'got %s' with 'got %qs'.
166
167 2017-02-20 Paul Thomas <pault@gcc.gnu.org>
168
169 PR fortran/79599
170 * interface.c (check_dtio_arg_TKR_intent): Supply 'must'
171 missing from error message.
172
173 2017-02-20 Paul Thomas <pault@gcc.gnu.org>
174
175 PR fortran/79523
176 * interface.c (gfc_find_typebound_dtio_proc): Guard test for
177 flavor attribute by checking that symbol is resolved.
178
179 2017-02-16 Paul Thomas <pault@gcc.gnu.org>
180
181 PR fortran/79382
182 * decl.c (access_attr_decl): Test for presence of generic DTIO
183 interface and emit error if not present.
184
185 2017-02-20 Paul Thomas <pault@gcc.gnu.org>
186
187 PR fortran/79434
188 * parse.c (check_component, parse_union): Whitespace.
189 (set_syms_host_assoc): For a derived type, check if the module
190 in which it was declared is one of the submodule ancestors. If
191 it is, make the components public. Otherwise, reset attribute
192 'host_assoc' and set 'use-assoc' so that encapsulation is
193 preserved.
194
195 2017-02-19 Paul Thomas <pault@gcc.gnu.org>
196
197 PR fortran/79447
198 * decl.c (gfc_set_constant_character_len): Whitespace.
199 (gfc_match_end): Catch case where a procedure is contained in
200 a module procedure and ensure that 'end procedure' is the
201 correct termination.
202
203 2017-02-19 Paul Thomas <pault@gcc.gnu.org>
204
205 PR fortran/79402
206 * resolve.c (fixup_unique_dummy): New function.
207 (gfc_resolve_expr): Call it for dummy variables with a unique
208 symtree name.
209
210 2017-02-19 Andre Vehreschild <vehre@gcc.gnu.org>
211
212 PR fortran/79229
213 * trans-expr.c (gfc_trans_assignment_1): Deref indirect refs when
214 compiling with -fcheck=mem to check the pointer and not the data.
215
216 2017-02-19 Andre Vehreschild <vehre@gcc.gnu.org>
217
218 PR fortran/79335
219 * trans-array.c (duplicate_allocatable_coarray): Ensure attributes
220 passed are properly initialized.
221 (structure_alloc_comps): Same.
222 * trans-expr.c (gfc_trans_structure_assign): Same.
223
224 2017-02-13 Jakub Jelinek <jakub@redhat.com>
225
226 * trans-expr.c (gfc_conv_substring): Add missing space in diagnostics.
227
228 2017-02-12 Thomas Koenig <tkoenig@gcc.gnu.org>
229
230 PR fortran/65542
231 * intrinsic.c (gfc_intrinsic_func_interface): Return an error
232 for -std=f95 for disallowed transformational functions in
233 initialization expressions.
234
235 2017-02-09 Cesar Philippidis <cesar@codesourcery.com>
236 Joseph Myers <joseph@codesourcery.com>
237
238 * openmp.c (resolve_omp_clauses): Error on directives
239 containing both tile and collapse clauses.
240 (resolve_oacc_loop_blocks): Represent '*' tile arguments as zero.
241 * trans-openmp.c (gfc_trans_omp_do): Lower tiled loops like
242 collapsed loops.
243
244 2017-02-07 Steven G. Kargl <kargl@gcc.gnu.org>
245
246 * trans-types.c (gfc_get_int_kind_from_width_isofortranen): Choose
247 REAL type with the widest precision if two (or more) have the same
248 storage size.
249
250 2017-02-05 Andre Vehreschild <vehre@gcc.gnu.org>
251
252 PR fortran/79344
253 * trans-stmt.c (gfc_trans_allocate): Only deallocate the components of
254 the temporary, when a new object was created for the temporary. Not
255 when it is just an alias to an existing object.
256
257 2017-02-05 Andre Vehreschild <vehre@gcc.gnu.org>
258
259 PR fortran/79335
260 * trans-decl.c (generate_coarray_sym_init): Retrieve the symbol's
261 attributes before using them.
262
263 2017-02-05 Andre Vehreschild <vehre@gcc.gnu.org>
264
265 PR fortran/78958
266 * trans-stmt.c (gfc_trans_allocate): Add the multiplying the _len
267 component of unlimited polymorphic objects when source-allocating.
268
269 2017-02-05 Andre Vehreschild <vehre@gcc.gnu.org>
270
271 PR fortran/79230
272 * trans-array.c (structure_alloc_comps): Ignore pointer components when
273 freeing structures.
274
275 2017-01-25 Maxim Ostapenko <m.ostapenko@samsung.com>
276
277 PR lto/79061
278 * f95-lang.c (gfc_create_decls): Include stringpool.h.
279 Pass main_input_filename to build_translation_unit_decl.
280
281 2017-01-23 Thomas Koenig <tkoenig@netcologne.de>
282
283 * arith.c (arith_power): If simplifying integer power expression
284 to zero, warn if -Winteger-division is given.
285
286 2017-01-22 Jakub Jelinek <jakub@redhat.com>
287
288 PR fortran/79154
289 * parse.c (matchs, matcho, matchds, matchdo): Replace return st;
290 with { ret = st; goto finish; }.
291 (decode_omp_directive): Allow declare simd, declare target and
292 simd directives in PURE/ELEMENTAL procedures. Only call
293 gfc_unset_implicit_pure on successful match of other procedures.
294
295 2017-01-21 Gerald Pfeifer <gerald@pfeifer.com>
296
297 * gfc-internals.texi (Symbol Versioning): Change references
298 to www.akkadia.org to https.
299
300 2017-01-21 Jakub Jelinek <jakub@redhat.com>
301
302 * gfortran.h (gfc_extract_int): Change return type to bool. Add
303 int argument with = 0.
304 * decl.c (gfc_match_kind_spec): Adjust gfc_extract_int caller, pass
305 1 as new last argument to it, don't emit gfc_error.
306 (match_char_kind): Likewise.
307 (gfc_match_decl_type_spec): Use gfc_get_string ("%s", x) instead of
308 gfc_get_string (x).
309 (gfc_match_derived_decl, match_binding_attributes): Likewise.
310 (gfc_match_structure_decl): Don't sprintf back to name, call
311 get_struct_decl directly with gfc_dt_upper_string (name) result.
312 * trans-stmt.c (gfc_trans_allocate): Use gfc_get_string ("%s", x)
313 instead of gfc_get_string (x).
314 * module.c (gfc_dt_lower_string, gfc_dt_upper_string,
315 gfc_match_use, gfc_match_submodule, find_true_name, mio_pool_string,
316 mio_symtree_ref, mio_expr, mio_omp_udr_expr, load_generic_interfaces,
317 load_omp_udrs, load_needed, read_module, dump_module,
318 create_intrinsic_function, import_iso_c_binding_module,
319 create_int_parameter, create_int_parameter_array, create_derived_type,
320 use_iso_fortran_env_module): Likewise.
321 * error.c (gfc_diagnostic_starter, gfc_diagnostic_start_span): Use
322 pp_verbatim (context->printer, "%s", x) instead of
323 pp_verbatim (context->printer, x).
324 * match.c (gfc_match_small_int): Adjust gfc_extract_int caller, pass
325 1 as new last argument to it, don't emit gfc_error.
326 (gfc_match_small_int_expr): Likewise.
327 * iresolve.c (gfc_get_string): Optimize format "%s" case.
328 (resolve_bound): Use gfc_get_string ("%s", x) instead of
329 gfc_get_string (x).
330 (resolve_transformational): Formatting fix.
331 (gfc_resolve_char_achar): Change name argument to bool is_achar,
332 use a single format string and if is_achar add "a" before "char".
333 (gfc_resolve_achar, gfc_resolve_char): Adjust callers.
334 * expr.c (gfc_extract_int): Change return type to bool, return true
335 if some error occurred. Add REPORT_ERROR argument, if non-zero
336 call either gfc_error or gfc_error_now depending on its sign.
337 * arith.c (arith_power): Adjust gfc_extract_int caller.
338 * symbol.c (gfc_add_component): Use gfc_get_string ("%s", x) instead
339 of gfc_get_string (x).
340 (gfc_new_symtree, gfc_delete_symtree, gfc_get_uop, gfc_new_symbol,
341 gfc_get_gsymbol, generate_isocbinding_symbol): Likewise.
342 * openmp.c (gfc_match_omp_clauses): Adjust gfc_extract_int caller, pass
343 -1 as new last argument to it, don't emit gfc_error_now.
344 (gfc_match_omp_declare_reduction): Use gfc_get_string ("%s", x)
345 instead of gfc_get_string (x).
346 * check.c (kind_check): Adjust gfc_extract_int caller.
347 * intrinsic.c (add_sym, find_sym, make_alias): Use
348 gfc_get_string ("%s", x) instead of gfc_get_string (x).
349 * simplify.c (get_kind, gfc_simplify_btest, gfc_simplify_maskr,
350 gfc_simplify_maskl, gfc_simplify_poppar, gfc_simplify_repeat,
351 gfc_simplify_selected_int_kind, gfc_simplify_selected_real_kind):
352 Adjust gfc_extract_int callers.
353 * trans-decl.c (gfc_find_module): Use gfc_get_string ("%s", x)
354 instead of gfc_get_string (x).
355 * matchexp.c (expression_syntax): Add const.
356 * primary.c (match_kind_param, match_hollerith_constant,
357 match_string_constant): Adjust gfc_extract_int callers.
358 (match_keyword_arg): Use gfc_get_string ("%s", x) instead of
359 gfc_get_string (x).
360 * frontend-passes.c (optimize_minmaxloc): Likewise.
361
362 2017-01-19 Andre Vehreschild <vehre@gcc.gnu.org>
363
364 PR fortran/70696
365 * trans-decl.c (gfc_build_qualified_array): Add static decl to parent
366 function only, when the decl-context is not the translation unit.
367
368 2017-01-18 Louis Krupp <louis.krupp@zoho.com>
369
370 PR fortran/50069
371 PR fortran/55086
372 * trans-expr.c (gfc_conv_variable): Don't treat temporary variables
373 as function arguments.
374 * trans-stmt.c (forall_make_variable_temp,
375 generate_loop_for_temp_to_lhs, gfc_trans_assign_need_temp,
376 gfc_trans_forall_1): Don't adjust offset of forall temporary
377 for array sections, make forall temporaries work for substring
378 expressions, improve test coverage by adding -ftest-forall-temp
379 option to request usage of temporary array in forall code.
380 * lang.opt: Add -ftest-forall-temp option.
381 * invoke.texi: Add -ftest-forall-temp option.
382
383 2017-01-18 Andre Vehreschild <vehre@gcc.gnu.org>
384
385 * primary.c (caf_variable_attr): Improve figuring whether the current
386 component is the last one refed.
387 * trans-stmt.c (gfc_trans_allocate): Do not generate sync_all calls
388 when allocating pointer or allocatable components.
389
390 2017-01-18 Andre Vehreschild <vehre@gcc.gnu.org>
391
392 * gfortran.texi: Add missing parameters to caf-API functions. Correct
393 typos and clarify some descriptions.
394
395 2017-01-18 Andre Vehreschild <vehre@gcc.gnu.org>
396
397 PR fortran/70696
398 Missed some cases, here they are:
399 * trans-decl.c (gfc_build_qualified_array): Add static tokens to the
400 parent function's scope.
401 * trans-expr.c (gfc_get_tree_for_caf_expr): Shorten code. Remove
402 unnecessary assert.
403
404 2017-01-13 Andre Vehreschild <vehre@gcc.gnu.org>
405
406 PR fortran/70697
407 * resolve.c (resolve_lock_unlock_event): Resolve the expression for
408 event's until_count.
409
410 2017-01-13 Andre Vehreschild <vehre@gcc.gnu.org>
411
412 PR fortran/70696
413 * trans-expr.c (gfc_get_tree_for_caf_expr): Ensure the backend_decl
414 is valid before accessing it.
415
416 2017-01-09 Jakub Jelinek <jakub@redhat.com>
417
418 PR translation/79019
419 PR translation/79020
420 * decl.c (attr_decl1): Fix spelling in translatable string.
421 * intrinsic.texi: Fix spelling - invokation -> invocation.
422 * lang.opt (faggressive-function-elimination, gfc_convert): Fix
423 typos in descriptions.
424 * openmp.c (resolve_omp_clauses): Add missing whitespace to
425 translatable strings.
426
427 2017-01-08 Martin Sebor <msebor@redhat.com>
428
429 PR tree-optimization/78913
430 PR middle-end/77708
431 * trans-common.c (build_equiv_decl): Increase buffer size to avoid
432 truncation for any argument.
433 * trans-types.c (gfc_build_logical_type): Same.
434
435 2017-01-07 Andre Vehreschild <vehre@gcc.gnu.org>
436
437 PR fortran/78781
438 PR fortran/78935
439 * expr.c (gfc_check_pointer_assign): Return the same error message for
440 rewritten coarray pointer assignments like for plain ones.
441 * gfortran.h: Change prototype.
442 * primary.c (caf_variable_attr): Set attributes used ones only only
443 ones. Add setting of pointer_comp attribute.
444 (gfc_caf_attr): Add setting of pointer_comp attribute.
445 * trans-array.c (gfc_array_allocate): Add flag that the component to
446 allocate is not an ultimate coarray component. Add allocation of
447 pointer arrays.
448 (structure_alloc_comps): Extend nullify to treat pointer components in
449 coarrays correctly. Restructure nullify to remove redundant code.
450 (gfc_nullify_alloc_comp): Allow setting caf_mode flags.
451 * trans-array.h: Change prototype of gfc_nullify_alloc_comp ().
452 * trans-decl.c (generate_coarray_sym_init): Call nullify_alloc_comp for
453 derived type coarrays with pointer components.
454 * trans-expr.c (gfc_trans_structure_assign): Also treat pointer
455 components.
456 (trans_caf_token_assign): Handle assignment of token of scalar pointer
457 components.
458 (gfc_trans_pointer_assignment): Call above routine.
459 * trans-intrinsic.c (conv_expr_ref_to_caf_ref): Add treating pointer
460 components.
461 (gfc_conv_intrinsic_caf_get): Likewise.
462 (conv_caf_send): Likewise.
463 * trans-stmt.c (gfc_trans_allocate): After allocating a derived type in
464 a coarray pre-register the tokens.
465 (gfc_trans_deallocate): Simply determining the coarray type (scalar or
466 array) and deregistering it correctly.
467 * trans-types.c (gfc_typenode_for_spec): Replace in_coarray flag by the
468 actual codim to allow lookup of array types in the cache.
469 (gfc_build_array_type): Likewise.
470 (gfc_get_array_descriptor_base): Likewise.
471 (gfc_get_array_type_bounds): Likewise.
472 (gfc_get_derived_type): Likewise.
473 * trans-types.h: Likewise.
474 * trans.c (gfc_deallocate_with_status): Enable deregistering of all kind
475 of coarray components.
476 (gfc_deallocate_scalar_with_status): Use free() in fcoarray_single mode
477 instead of caf_deregister.
478
479 2017-01-06 Jakub Jelinek <jakub@redhat.com>
480
481 * simplify.c (simplify_transformation_to_array): Use
482 GCC_DIAGNOSTIC_PUSH_IGNORED and GCC_DIAGNOSTIC_POP instead of
483 #pragma GCC diagnostic {push,ignored,pop}.
484
485 2017-01-06 Alexandre Oliva <aoliva@redhat.com>
486
487 * simplify.c (simplify_transformation_to_array): Silence
488 array bounds warning. Fix whitespace.
489
490 2017-01-04 Alexandre Oliva <aoliva@redhat.com>
491
492 * module.c (load_omp_udrs): Initialize name.
493
494 2017-01-02 Janne Blomqvist <jb@gcc.gnu.org>
495
496 PR fortran/78534
497 * trans-expr.c (gfc_trans_string_copy): Rework string copy
498 algorithm to avoid -Wstringop-overflow warning.
499
500 2017-01-01 Jakub Jelinek <jakub@redhat.com>
501
502 Update copyright years.
503
504 * gfortranspec.c (lang_specific_driver): Update copyright notice
505 dates.
506 * gfc-internals.texi: Bump @copying's copyright year.
507 * gfortran.texi: Ditto.
508 * intrinsic.texi: Ditto.
509 * invoke.texi: Ditto.
510 \f
511 Copyright (C) 2017 Free Software Foundation, Inc.
512
513 Copying and distribution of this file, with or without modification,
514 are permitted in any medium without royalty provided the copyright
515 notice and this notice are preserved.