1 2021-12-29 Harald Anlauf <anlauf@gmx.de>
4 * expr.c (gfc_get_variable_expr): Avoid NULL pointer dereferences
5 during handling of errors with invalid uses of CLASS variables.
6 * match.c (select_type_set_tmp): Likewise.
7 * primary.c (gfc_match_varspec): Likewise.
8 * resolve.c (resolve_variable): Likewise.
9 (resolve_select_type): Likewise.
11 2021-12-28 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
14 * trans-decl.c (generate_local_decl): Do not call
15 gfc_conv_scalar_char_value(), but check the type tree.
16 * trans-expr.c (gfc_conv_scalar_char_value): Rename to
17 conv_scalar_char_value, do not alter type tree.
18 (gfc_conv_procedure_call): Adjust call to renamed
19 conv_scalar_char_value() function.
20 * trans-types.c (gfc_sym_type): Take care of
21 CHARACTER(C_CHAR), VALUE arguments.
22 * trans.h (gfc_conv_scalar_char_value): Remove prototype.
24 2021-12-28 Martin Liska <mliska@suse.cz>
26 * gfortran.texi: Replace http:// with https.
27 * intrinsic.texi: Likewise.
29 2021-12-22 Harald Anlauf <anlauf@gmx.de>
32 * check.c (is_c_interoperable): A BOZ literal constant is not
35 2021-12-22 Harald Anlauf <anlauf@gmx.de>
38 * match.c (match_case_selector): Reject expressions in CASE
39 selector which are not scalar.
41 2021-12-18 Harald Anlauf <anlauf@gmx.de>
44 * check.c (gfc_check_sizeof): Reject BOZ type argument.
46 2021-12-14 Harald Anlauf <anlauf@gmx.de>
49 * frontend-passes.c (doloop_code): Prevent NULL pointer
50 dereference when checking for passing a do-loop variable to a
51 contained procedure with an interface mismatch.
53 2021-12-14 Harald Anlauf <anlauf@gmx.de>
57 * frontend-passes.c (doloop_contained_procedure_code): Add several
58 checks to prevent NULL pointer dereferences on valid and invalid
59 code called within do-loops.
61 2021-12-14 Manfred Schwarb <manfred99@gmx.ch>
64 * simplify.c (simplify_min_max): Disable conversion warnings for
67 2021-12-13 Tobias Burnus <tobias@codesourcery.com>
70 * openmp.c (is_scalar_intrinsic_expr): Fix condition.
71 (resolve_omp_atomic): Fix/update checks, accept compare.
72 * trans-openmp.c (gfc_trans_omp_atomic): Handle compare.
74 2021-12-11 Harald Anlauf <anlauf@gmx.de>
77 * resolve.c (resolve_fl_procedure): Do not access CLASS components
78 before class container has been built.
80 2021-12-10 Harald Anlauf <anlauf@gmx.de>
83 * check.c (variable_check): Replace previous check of procedure
84 dummy arguments with INTENT(IN) attribute when passed to intrinsic
85 procedures by gfc_check_vardef_context.
86 * expr.c (gfc_check_vardef_context): Correct check of INTENT(IN)
87 dummy arguments for the case of sub-components of a CLASS pointer.
89 2021-12-08 Harald Anlauf <anlauf@gmx.de>
92 * symbol.c (gfc_sym_get_dummy_args): Catch NULL pointer
95 2021-12-08 Harald Anlauf <anlauf@gmx.de>
98 * array.c (spec_dimen_size): Fix simplification of SHAPE:
99 dimensions must be non-negative.
101 2021-12-08 Chung-Lin Tang <cltang@codesourcery.com>
103 * trans-openmp.c (gfc_trans_omp_array_section): Do not generate
104 GOMP_MAP_ALWAYS_POINTER map for main array maps of ARRAY_TYPE type.
106 2021-12-07 Harald Anlauf <anlauf@gmx.de>
109 * frontend-passes.c (do_subscript): Ensure that array bounds are
110 of type INTEGER before performing checks on array subscripts.
112 2021-12-07 Harald Anlauf <anlauf@gmx.de>
115 * array.c (gfc_ref_dimen_size): Do not generate internal error on
116 failed simplification of stride expression; just return failure.
118 2021-12-07 Harald Anlauf <anlauf@gmx.de>
121 * match.c (match_case_selector): Check type of upper bound in case
124 2021-12-04 Tobias Burnus <tobias@codesourcery.com>
126 * dump-parse-tree.c (show_omp_clauses): Handle
127 weak/compare/fail clause.
128 * gfortran.h (gfc_omp_clauses): Add weak, compare, fail.
129 * openmp.c (enum omp_mask1, gfc_match_omp_clauses,
130 OMP_ATOMIC_CLAUSES): Update for new clauses.
131 (gfc_match_omp_atomic): Update for 5.1 atomic changes.
132 (is_conversion): Support widening in one go.
133 (is_scalar_intrinsic_expr): New.
134 (resolve_omp_atomic): Update for 5.1 atomic changes.
135 * parse.c (parse_omp_oacc_atomic): Update for compare.
136 * resolve.c (gfc_resolve_blocks): Update asserts.
137 * trans-openmp.c (gfc_trans_omp_atomic): Handle new clauses.
139 2021-12-03 Harald Anlauf <anlauf@gmx.de>
140 Steven G. Kargl <kargl@gcc.gnu.org>
143 * array.c (match_array_element_spec): Try to simplify array
144 element specifications to improve early checking.
145 * expr.c (gfc_try_simplify_expr): New. Try simplification of an
146 expression via gfc_simplify_expr. When an error occurs, roll
148 * gfortran.h (gfc_try_simplify_expr): Declare it.
150 2021-12-03 Tobias Burnus <tobias@codesourcery.com>
152 * trans-stmt.c (gfc_trans_allocate): Set e3_has_nodescriptor to true
153 only for non-named arrays.
155 2021-12-02 Chung-Lin Tang <cltang@codesourcery.com>
158 * trans-openmp.c (gfc_omp_finish_clause): Remove fold_convert to pointer
159 to char_type_node, add gcc_assert of POINTER_TYPE_P.
160 (gfc_trans_omp_array_section): Likewise.
161 (gfc_trans_omp_clauses): Likewise.
163 2021-11-30 Harald Anlauf <anlauf@gmx.de>
166 * array.c (expand_constructor): When encountering a constant array
167 expression or array section within a constructor, simplify it to
168 enable better expansion.
170 2021-11-30 Harald Anlauf <anlauf@gmx.de>
173 * simplify.c (simplify_minmaxloc_nodim): Avoid NULL pointer
174 dereference when shape is not set.
176 2021-11-30 Harald Anlauf <anlauf@gmx.de>
177 Steven G. Kargl <kargl@gcc.gnu.org>
180 * check.c (gfc_check_image_index): Verify that SUB argument to
181 IMAGE_INDEX is of type integer.
183 2021-11-30 Richard Biener <rguenther@suse.de>
185 * frontend-passes.c (gfc_expr_walker): Add comment to
186 indicate tail recursion.
188 2021-11-30 Richard Biener <rguenther@suse.de>
190 * target-memory.c (gfc_element_size): Remove unreachable return.
192 2021-11-30 Thomas Schwinge <thomas@codesourcery.com>
194 * openmp.c (resolve_oacc_loop_blocks): Remove "gang reduction on
195 an orphan loop" checking.
196 (oacc_is_parallel, oacc_is_kernels, oacc_is_serial)
197 (oacc_is_compute_construct): Remove.
199 2021-11-30 Frederik Harwath <frederik@codesourcery.com>
200 Thomas Schwinge <thomas@codesourcery.com>
202 * openmp.c (oacc_is_parallel_or_serial): Evolve into...
203 (oacc_is_compute_construct): ... this function.
204 (resolve_oacc_loop_blocks): Use "oacc_is_compute_construct"
205 instead of "oacc_is_parallel_or_serial" for checking that a
206 loop is not orphaned.
208 2021-11-30 Kwok Cheung Yeung <kcy@codesourcery.com>
209 Thomas Schwinge <thomas@codesourcery.com>
211 * openmp.c (oacc_is_serial, oacc_is_parallel_or_serial): New.
212 (resolve_oacc_loop_blocks): Use oacc_is_parallel_or_serial instead of
215 2021-11-30 Cesar Philippidis <cesar@codesourcery.com>
216 Thomas Schwinge <thomas@codesourcery.com>
218 * openmp.c (oacc_is_parallel, oacc_is_kernels): New 'static'
220 (resolve_oacc_loop_blocks): Emit an error on orphan OpenACC gang
223 2021-11-30 Richard Biener <rguenther@suse.de>
225 * decl.c (gfc_insert_parameter_exprs): Only return after
226 resetting type_param_spec_list.
228 2021-11-30 Richard Biener <rguenther@suse.de>
230 * frontend-passes.c (gfc_expr_walker): Remove unreachable
232 * scanner.c (skip_fixed_comments): Remove unreachable
234 * trans-expr.c (gfc_expr_is_variable): Refactor to make
235 control flow more obvious.
237 2021-11-29 Eric Gallager <egallager@gcc.gnu.org>
240 * Make-lang.in: Use ETAGS variable in TAGS target.
242 2021-11-26 Harald Anlauf <anlauf@gmx.de>
245 * check.c (gfc_check_reshape): Improve check of size of source
246 array for the RESHAPE intrinsic against the given shape when pad
247 is not given, and shape is a parameter. Try other simplifications
250 2021-11-23 Harald Anlauf <anlauf@gmx.de>
253 * simplify.c (simplify_bound): Do not try to simplify
254 LBOUND/UBOUND for arrays with POINTER or ALLOCATABLE attribute.
256 2021-11-23 Harald Anlauf <anlauf@gmx.de>
260 * trans-array.c (arg_evaluated_for_scalarization): Add LEN_TRIM to
261 list of intrinsics for which an optional KIND argument needs to be
262 removed before scalarization.
264 2021-11-21 Jakub Jelinek <jakub@redhat.com>
267 * trans-types.c (gfc_get_array_descr_info): Use DW_OP_deref_size 1
268 instead of DW_OP_deref for DW_AT_rank.
270 2021-11-21 Harald Anlauf <anlauf@gmx.de>
271 Steven G. Kargl <kargl@gcc.gnu.org>
274 * trans-intrinsic.c (gfc_lookup_intrinsic): Helper function for
275 looking up gfortran builtin intrinsics.
276 (gfc_conv_intrinsic_atrigd): Use it.
277 (gfc_conv_intrinsic_cotan): Likewise.
278 (gfc_conv_intrinsic_cotand): Likewise.
279 (gfc_conv_intrinsic_atan2d): Likewise.
281 2021-11-18 Harald Anlauf <anlauf@gmx.de>
282 Steven G. Kargl <kargl@gcc.gnu.org>
285 * check.c (is_c_interoperable): Reject NULL() as it is not
288 2021-11-16 Harald Anlauf <anlauf@gmx.de>
291 * resolve.c (resolve_select): Choose appropriate range limit to
292 avoid NULL pointer dereference when generating error message.
294 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
296 * interface.c (gfc_dummy_arg_get_name): New function.
297 * gfortran.h (gfc_dummy_arg_get_name): Declare it.
298 * trans-array.c (arg_evaluated_for_scalarization): Pass a dummy
299 argument wrapper as argument instead of an actual argument
300 and an index number. Check it’s non-NULL. Use its name
302 (gfc_walk_elemental_function_args): Update call to
303 arg_evaluated for scalarization. Remove argument counting.
305 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
307 * gfortran.h (gfc_actual_arglist::missing_arg_type): Remove.
308 * interface.c (gfc_compare_actual_formal): Remove
309 missing_arg_type initialization.
310 * intrinsic.c (sort_actual): Ditto.
311 * trans-expr.c (gfc_conv_procedure_call): Use associated_dummy
312 and gfc_dummy_arg_get_typespec to get the dummy argument type.
314 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
316 * interface.c (gfc_dummy_arg_get_typespec,
317 gfc_dummy_arg_is_optional): New functions.
318 * gfortran.h (gfc_dummy_arg_get_typespec,
319 gfc_dummy_arg_is_optional): Declare them.
320 * trans.h (gfc_ss_info::dummy_arg): Use the wrapper type
322 * trans-array.c (gfc_scalar_elemental_arg_saved_as_reference):
323 use gfc_dummy_arg_get_typespec function to get the type.
324 (gfc_walk_elemental_function_args): Remove proc_ifc argument.
325 Get info about the dummy arg using the associated_dummy field.
326 * trans-array.h (gfc_walk_elemental_function_args): Update declaration.
327 * trans-intrinsic.c (gfc_walk_intrinsic_function):
328 Update call to gfc_walk_elemental_function_args.
329 * trans-stmt.c (gfc_trans_call): Ditto.
330 (get_proc_ifc_for_call): Remove.
332 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
334 * gfortran.h (gfc_dummy_arg_kind, gfc_dummy_arg): New.
335 (gfc_actual_arglist): New field associated_dummy.
336 (gfc_intrinsic_arg): Remove field actual.
337 * interface.c (get_nonintrinsic_dummy_arg): New.
338 (gfc_compare_actual): Initialize associated_dummy.
339 * intrinsic.c (get_intrinsic_dummy_arg): New.
340 (sort_actual):Â Add argument vectors.
341 Use loops with indices on argument vectors.
342 Initialize associated_dummy.
344 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
346 * intrinsic.c (sort_actual): initialise variable and use it earlier.
348 2021-11-15 Tobias Burnus <tobias@codesourcery.com>
350 * openmp.c (OMP_TARGET_CLAUSES): Add thread_limit.
351 * trans-openmp.c (gfc_split_omp_clauses): Add thread_limit also to
354 2021-11-12 Tobias Burnus <tobias@codesourcery.com>
356 * parse.c (decode_omp_directive): Fix permitting 'nowait' for some
357 combined directives, add missing 'omp end ... loop'.
358 (gfc_ascii_statement): Fix ST_OMP_END_TEAMS_LOOP result.
359 * openmp.c (resolve_omp_clauses): Add missing combined loop constructs
360 case values to the 'if(directive-name: ...)' check.
361 * trans-openmp.c (gfc_split_omp_clauses): Put nowait on target if
362 first leaf construct accepting it.
364 2021-11-12 Martin Jambor <mjambor@suse.cz>
366 * trans-types.c (gfc_get_array_descr_info): Use build_debug_expr_decl
367 instead of building DEBUG_EXPR_DECL manually.
369 2021-11-12 Mikael Morin <mikael@gcc.gnu.org>
372 * intrinsic.c (add_sym_4ind): Remove.
373 (add_functions): Use add_sym4 instead of add_sym4ind.
374 Don’t special case the index intrinsic.
375 * iresolve.c (gfc_resolve_index_func): Use the individual arguments
376 directly instead of the full argument list.
377 * intrinsic.h (gfc_resolve_index_func): Update the declaration
379 * trans-decl.c (gfc_get_extern_function_decl): Don’t modify the
380 list of arguments in the case of the index intrinsic.
381 * trans-array.h (gfc_get_intrinsic_for_expr,
382 gfc_get_proc_ifc_for_expr): New.
383 * trans-array.c (gfc_get_intrinsic_for_expr,
384 arg_evaluated_for_scalarization): New.
385 (gfc_walk_elemental_function_args): Add intrinsic procedure
386 as argument. Count arguments. Check arg_evaluated_for_scalarization.
387 * trans-intrinsic.c (gfc_walk_intrinsic_function): Update call.
388 * trans-stmt.c (get_intrinsic_for_code): New.
389 (gfc_trans_call): Update call.
391 2021-11-12 Jakub Jelinek <jakub@redhat.com>
393 * types.def (BT_FN_VOID_UINT_UINT): Remove.
394 (BT_FN_BOOL_UINT_UINT_UINT_BOOL): New.
396 2021-11-11 Tobias Burnus <tobias@codesourcery.com>
398 * gfortran.h (struct gfc_omp_clauses): Rename num_teams to
399 num_teams_upper, add num_teams_upper.
400 * dump-parse-tree.c (show_omp_clauses): Update to handle
401 lower-bound num_teams clause.
402 * frontend-passes.c (gfc_code_walker): Likewise
403 * openmp.c (gfc_free_omp_clauses, gfc_match_omp_clauses,
404 resolve_omp_clauses): Likewise.
405 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses,
406 gfc_trans_omp_target): Likewise.
408 2021-11-11 Jakub Jelinek <jakub@redhat.com>
410 * trans-openmp.c (gfc_trans_omp_clauses): Use
411 OMP_CLAUSE_NUM_TEAMS_UPPER_EXPR instead of OMP_CLAUSE_NUM_TEAMS_EXPR.
413 2021-11-10 Harald Anlauf <anlauf@gmx.de>
417 * check.c (gfc_check_shape): Avoid NULL pointer dereference on
419 * simplify.c (gfc_simplify_cshift): Avoid NULL pointer dereference
421 (gfc_simplify_transpose): Likewise.
423 2021-11-09 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
426 * class.c (generate_finalization_wrapper): Do not leak
427 finalization wrappers if they will not be used.
428 * expr.c (gfc_free_actual_arglist): Formatting fix.
429 * gfortran.h (gfc_free_symbol): Pass argument by reference.
430 (gfc_release_symbol): Likewise.
431 (gfc_free_namespace): Likewise.
432 * symbol.c (gfc_release_symbol): Adjust acordingly.
433 (free_components): Set procedure pointer components
434 of derived types to NULL after freeing.
435 (free_tb_tree): Likewise.
436 (gfc_free_symbol): Set sym to NULL after freeing.
437 (gfc_free_namespace): Set namespace to NULL after freeing.
439 2021-11-09 Martin Liska <mliska@suse.cz>
441 * symbol.c (gfc_get_ultimate_derived_super_type): Remove.
443 2021-11-09 Aldy Hernandez <aldyh@redhat.com>
445 * misc.c (gfc_dummy_typename): Make sure ts->kind is
448 2021-11-07 Thomas Koenig <tkoenig@gcc.gnu.org>
450 * intrinsic.c (add_subroutines): Change keyword "operator"
451 to the correct one, "operation".
452 * check.c (gfc_check_co_reduce): Change OPERATOR to
453 OPERATION in error messages.
454 * intrinsic.texi: Change OPERATOR to OPERATION in
457 2021-11-07 Sandra Loosemore <sandra@codesourcery.com>
459 * interface.c (gfc_compare_actual_formal): Continue checking
460 all arguments after encountering an error.
461 * intrinsic.c (do_ts29113_check): Likewise.
462 * resolve.c (resolve_operator): Continue resolving on op2 error.
464 2021-11-06 Harald Anlauf <anlauf@gmx.de>
467 * decl.c (add_init_expr_to_sym): Reject rank mismatch between
468 array and its initializer.
470 2021-11-05 Harald Anlauf <anlauf@gmx.de>
473 * expr.c (simplify_parameter_variable): Copy shape of referenced
474 subobject when simplifying.
476 2021-11-05 Harald Anlauf <anlauf@gmx.de>
479 * match.c (gfc_match_common): Check array spec of a symbol in a
480 COMMON object list and reject it if it is a coarray.
482 2021-11-05 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
485 * decl.c (gfc_match_implicit_none): Fix typo in warning.
486 * resolve.c (resolve_unknown_f): Reject external procedures
487 without explicit EXTERNAL attribute whe IMPLICIT none (external)
490 2021-11-05 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
492 * decl.c (gfc_insert_kind_parameter_exprs): Make static.
493 * expr.c (gfc_build_init_expr): Make static
494 (gfc_build_default_init_expr): Move below its static helper.
495 * gfortran.h (gfc_insert_kind_parameter_exprs, gfc_add_saved_common,
496 gfc_add_common, gfc_use_derived_tree, gfc_free_charlen,
497 gfc_get_ultimate_derived_super_type,
498 gfc_resolve_oacc_parallel_loop_blocks, gfc_build_init_expr,
499 gfc_iso_c_sub_interface): Delete.
500 * symbol.c (gfc_new_charlen, gfc_get_derived_super_type): Make
503 2021-11-05 Sandra Loosemore <sandra@codesourcery.com>
506 * gfortran.texi (Mixed-Language Programming): Talk about C++,
509 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
511 * gfortran.texi (Projects): Add bullet for helping with
512 incomplete standards compliance.
513 (Proposed Extensions): Delete section.
515 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
517 * intrinsic.texi (Introduction to Intrinsics): Genericize
518 references to standard versions.
519 * invoke.texi (-fall-intrinsics): Likewise.
520 (-fmax-identifier-length=): Likewise.
522 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
524 * gfortran.texi (Interoperability with C): Copy-editing. Add
526 (Intrinsic Types): Likewise.
527 (Derived Types and struct): Likewise.
528 (Interoperable Global Variables): Likewise.
529 (Interoperable Subroutines and Functions): Likewise.
530 (Working with C Pointers): Likewise.
531 (Further Interoperability of Fortran with C): Likewise. Rewrite
532 to reflect that this is now fully supported by gfortran.
534 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
536 * gfortran.texi (About GNU Fortran): Consolidate material
537 formerly in other sections. Copy-editing.
538 (Preprocessing and conditional compilation): Delete, moving
539 most material to invoke.texi.
540 (GNU Fortran and G77): Delete.
541 (Project Status): Delete.
543 (Fortran 95 status): Mention conditional compilation here.
544 (Fortran 2003 status): Rewrite to mention the 1 missing feature
545 instead of all the ones implemented.
546 (Fortran 2008 status): Similarly for the 2 missing features.
547 (Fortran 2018 status): Rewrite to reflect completion of TS29113
549 * invoke.texi (Preprocessing Options): Move material formerly
550 in introductory chapter here.
552 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
554 * gfortran.texi (Standards): Move discussion of specific
555 standard versions here....
556 (Fortran standards status): ...from here, and delete this node.
558 2021-10-31 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
560 * symbol.c (gfc_get_typebound_proc): Revert memcpy.
562 2021-10-31 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
564 * resolve.c (resolve_fl_procedure): Initialize
565 allocatable_or_pointer.
567 2021-10-30 Manfred Schwarb <manfred99@gmx.ch>
569 * intrinsic.texi: Remove entries for SHORT and LONG intrinsics.
571 2021-10-30 Manfred Schwarb <manfred99@gmx.ch>
573 * check.c (gfc_check_intconv): Change error message.
575 2021-10-30 Manfred Schwarb <manfred99@gmx.ch>
577 * intrinsic.texi (REAL): Fix entries in Specific names table.
579 2021-10-30 Manfred Schwarb <manfred99@gmx.ch>
581 * intrinsic.texi: Adjust @columnfractions commands to improve
582 appearance for narrow 80 character terminals.
584 2021-10-30 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
586 * parse.c (clean_up_modules): Free gsym.
588 2021-10-30 Harald Anlauf <anlauf@gmx.de>
590 * gfortran.texi (bug reports): credit Gerhard Steinmetz for
591 numerous bug reports.
593 2021-10-30 Steve Kargl <kargl@gcc.gnu.org>
596 * resolve.c (resolve_select): Generate regular gfc_error on
597 invalid conversions instead of an gfc_internal_error.
599 2021-10-29 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
601 * symbol.c (free_tb_tree): Free type-bound procedure struct.
602 (gfc_get_typebound_proc): Use explicit memcpy for clarity.
604 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
606 * intrinsic.h (gfc_check_sum, gfc_resolve_atan2d, gfc_resolve_kill,
607 gfc_resolve_kill_sub): Delete declaration.
609 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
611 * trans-types.h (gfc_convert_function_code): Delete.
613 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
615 * trans-stmt.h (gfc_trans_deallocate_array): Delete.
617 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
619 * trans-array.c (gfc_trans_scalarized_loop_end): Make static.
620 * trans-array.h (gfc_trans_scalarized_loop_end,
621 gfc_conv_tmp_ref, gfc_conv_array_transpose): Delete declaration.
623 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
625 * constructor.c (gfc_constructor_get_base): Make static.
626 (gfc_constructor_expr_foreach, gfc_constructor_swap): Delete.
627 * constructor.h (gfc_constructor_get_base): Remove declaration.
628 (gfc_constructor_expr_foreach, gfc_constructor_swap): Delete.
630 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
632 * decl.c (gfc_match_old_kind_spec, set_com_block_bind_c,
633 set_verify_bind_c_sym, set_verify_bind_c_com_block,
634 get_bind_c_idents, gfc_match_suffix, gfc_get_type_attr_spec,
635 check_extended_derived_type): Make static.
636 (gfc_match_gcc_unroll): Add comment.
637 * match.c (gfc_match_small_int_expr): Delete definition.
638 * match.h (gfc_match_small_int_expr): Delete declaration.
639 (gfc_match_name_C, gfc_match_old_kind_spec, set_com_block_bind_c,
640 set_verify_bind_c_sym, set_verify_bind_c_com_block,
641 get_bind_c_idents, gfc_match_suffix,
642 gfc_get_type_attr_spec): Delete declaration.
644 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
646 * expr.c (is_non_empty_structure_constructor): Make static.
647 * gfortran.h (gfc_check_any_c_kind): Delete.
648 * match.c (gfc_match_label): Make static.
649 * match.h (gfc_match_label): Delete declaration.
650 * scanner.c (file_changes_cur, file_changes_count,
651 file_changes_allocated): Make static.
652 * trans-expr.c (gfc_get_character_len): Make static.
653 (gfc_class_len_or_zero_get): Make static.
654 (VTAB_GET_FIELD_GEN): Undefine.
655 (gfc_get_class_array_ref): Make static.
656 (gfc_finish_interface_mapping): Make static.
657 * trans-types.c (gfc_check_any_c_kind): Delete.
658 (pfunc_type_node, dtype_type_node, gfc_get_ppc_type): Make static.
659 * trans-types.h (gfc_get_ppc_type): Delete declaration.
660 * trans.c (gfc_msg_wrong_return): Delete.
661 * trans.h (gfc_class_len_or_zero_get, gfc_class_vtab_extends_get,
662 gfc_vptr_extends_get, gfc_get_class_array_ref, gfc_get_character_len,
663 gfc_finish_interface_mapping, gfc_msg_wrong_return,
664 gfc_get_function_decl): Delete declaration.
666 2021-10-27 Tobias Burnus <tobias@codesourcery.com>
668 * trans-stmt.c (gfc_trans_select_rank_cases): Fix condition
669 for allocatables/pointers.
671 2021-10-26 Harald Anlauf <anlauf@gmx.de>
674 * symbol.c (gfc_check_conflict): Add conflict check for PDT KIND
675 and LEN type parameters.
677 2021-10-26 Harald Anlauf <anlauf@gmx.de>
680 * decl.c (match_attr_spec): Remove invalid integer kind checks on
681 KIND and LEN attributes of PDTs.
683 2021-10-26 Harald Anlauf <anlauf@gmx.de>
686 * resolve.c (resolve_structure_cons): Reject invalid array spec of
687 a DT component referenced in a structure constructor.
689 2021-10-26 Tobias Burnus <tobias@codesourcery.com>
692 * trans-decl.c (gfc_conv_cfi_to_gfc): Properly handle nonconstant
695 2021-10-25 Andrew MacLeod <amacleod@redhat.com>
697 * trans-decl.c (gfc_conv_cfi_to_gfc): Initialize rank to NULL_TREE.
699 2021-10-22 Eric Gallager <egallager@gcc.gnu.org>
702 * Make-lang.in: Allow dvi-formatted documentation
705 2021-10-22 Tobias Burnus <tobias@codesourcery.com>
708 * trans-expr.c (gfc_trans_assignment_1): Add STRIP_NOPS.
710 2021-10-21 Chung-Lin Tang <cltang@codesourcery.com>
712 * decl.c (gfc_match_end): Add COMP_OMP_STRICTLY_STRUCTURED_BLOCK case
713 together with COMP_BLOCK.
714 * parse.c (parse_omp_structured_block): Change return type to
715 'gfc_statement', add handling for strictly-structured block case, adjust
716 recursive calls to parse_omp_structured_block.
717 (parse_executable): Adjust calls to parse_omp_structured_block.
718 * parse.h (enum gfc_compile_state): Add
719 COMP_OMP_STRICTLY_STRUCTURED_BLOCK.
720 * trans-openmp.c (gfc_trans_omp_workshare): Add EXEC_BLOCK case
723 2021-10-21 Sandra Loosemore <sandra@codesourcery.com>
726 * expr.c (gfc_simplify_expr): Handle GFC_ISYM_SHAPE along with
727 GFC_ISYM_LBOUND and GFC_ISYM_UBOUND.
728 * trans-array.c (gfc_conv_ss_startstride): Likewise.
729 (set_loop_bounds): Likewise.
730 * trans-intrinsic.c (gfc_trans_intrinsic_bound): Extend to
731 handle SHAPE. Correct logic for zero-size special cases and
732 detecting assumed-rank arrays associated with an assumed-size
734 (gfc_conv_intrinsic_shape): Deleted.
735 (gfc_conv_intrinsic_function): Handle GFC_ISYM_SHAPE like
736 GFC_ISYM_LBOUND and GFC_ISYM_UBOUND.
737 (gfc_add_intrinsic_ss_code): Likewise.
738 (gfc_walk_intrinsic_bound): Likewise.
740 2021-10-20 Chung-Lin Tang <cltang@codesourcery.com>
742 * openmp.c (gfc_match_omp_clause_reduction): Add 'openmp_target' default
743 false parameter. Add 'always,tofrom' map for OMP_LIST_IN_REDUCTION case.
744 (gfc_match_omp_clauses): Add 'openmp_target' default false parameter,
745 adjust call to gfc_match_omp_clause_reduction.
746 (match_omp): Adjust call to gfc_match_omp_clauses
747 * trans-openmp.c (gfc_trans_omp_taskgroup): Add call to
748 gfc_match_omp_clause, create and return block.
750 2021-10-19 Tobias Burnus <tobias@codesourcery.com>
752 * trans-types.c (create_fn_spec): For allocatable/pointer
753 character(len=:), use 'w' not 'R' as fn spec for the length dummy
756 2021-10-19 Tobias Burnus <tobias@codesourcery.com>
759 * trans-expr.c (gfc_conv_procedure_call): Use TREE_OPERAND not
760 build_fold_indirect_ref_loc to undo an ADDR_EXPR.
762 2021-10-18 Tobias Burnus <tobias@codesourcery.com>
771 * decl.c (gfc_verify_c_interop_param): Remove 'sorry' for
772 scalar allocatable/pointer and len=*.
773 * expr.c (is_CFI_desc): Return true for for those.
774 * gfortran.h (CFI_type_kind_shift, CFI_type_mask,
775 CFI_type_from_type_kind, CFI_VERSION, CFI_MAX_RANK,
776 CFI_attribute_pointer, CFI_attribute_allocatable,
777 CFI_attribute_other, CFI_type_Integer, CFI_type_Logical,
778 CFI_type_Real, CFI_type_Complex, CFI_type_Character,
779 CFI_type_ucs4_char, CFI_type_struct, CFI_type_cptr,
780 CFI_type_cfunptr, CFI_type_other): New #define.
781 * trans-array.c (CFI_FIELD_BASE_ADDR, CFI_FIELD_ELEM_LEN,
782 CFI_FIELD_VERSION, CFI_FIELD_RANK, CFI_FIELD_ATTRIBUTE,
783 CFI_FIELD_TYPE, CFI_FIELD_DIM, CFI_DIM_FIELD_LOWER_BOUND,
784 CFI_DIM_FIELD_EXTENT, CFI_DIM_FIELD_SM,
785 gfc_get_cfi_descriptor_field, gfc_get_cfi_desc_base_addr,
786 gfc_get_cfi_desc_elem_len, gfc_get_cfi_desc_version,
787 gfc_get_cfi_desc_rank, gfc_get_cfi_desc_type,
788 gfc_get_cfi_desc_attribute, gfc_get_cfi_dim_item,
789 gfc_get_cfi_dim_lbound, gfc_get_cfi_dim_extent, gfc_get_cfi_dim_sm):
790 New define/functions to access the CFI array descriptor.
791 (gfc_conv_descriptor_type): New function for the GFC descriptor.
792 (gfc_get_array_span): Handle expr of CFI descriptors and
793 assumed-type descriptors.
794 (gfc_trans_array_bounds): Remove 'static'.
795 (gfc_conv_expr_descriptor): For assumed type, use the dtype of
797 (structure_alloc_comps): Remove ' ' inside tabs.
798 * trans-array.h (gfc_trans_array_bounds, gfc_conv_descriptor_type,
799 gfc_get_cfi_desc_base_addr, gfc_get_cfi_desc_elem_len,
800 gfc_get_cfi_desc_version, gfc_get_cfi_desc_rank,
801 gfc_get_cfi_desc_type, gfc_get_cfi_desc_attribute,
802 gfc_get_cfi_dim_lbound, gfc_get_cfi_dim_extent, gfc_get_cfi_dim_sm):
804 * trans-decl.c (gfor_fndecl_cfi_to_gfc, gfor_fndecl_gfc_to_cfi):
806 (gfc_build_builtin_function_decls): Remove their initialization.
807 (gfc_get_symbol_decl, create_function_arglist,
808 gfc_trans_deferred_vars): Update for CFI.
809 (convert_CFI_desc): Remove and replace by ...
810 (gfc_conv_cfi_to_gfc): ... this function
811 (gfc_generate_function_code): Call it; create local GFC var for CFI.
812 * trans-expr.c (gfc_maybe_dereference_var): Handle CFI.
813 (gfc_conv_subref_array_arg): Handle the if-noncontigous-only copy in
814 when the result should be a descriptor.
815 (gfc_conv_gfc_desc_to_cfi_desc): Completely rewritten.
816 (gfc_conv_procedure_call): CFI fixes.
817 * trans-openmp.c (gfc_omp_is_optional_argument,
818 gfc_omp_check_optional_argument): Handle optional
820 * trans-stmt.c (gfc_trans_select_rank_cases): Cleanup, avoid invalid
821 code for allocatable/pointer dummies, which cannot be assumed size.
822 * trans-types.c (gfc_cfi_descriptor_base): New global var.
823 (gfc_get_dtype_rank_type): Skip rank init for rank < 0.
824 (gfc_sym_type): Handle CFI dummies.
825 (gfc_get_function_type): Update call.
826 (gfc_get_cfi_dim_type, gfc_get_cfi_type): New.
827 * trans-types.h (gfc_sym_type): Update prototype.
828 (gfc_get_cfi_type): New prototype.
829 * trans.c (gfc_trans_runtime_check): Make conditions more consistent
830 to avoid '<logical> AND_THEN <long int>' in conditions.
831 * trans.h (gfor_fndecl_cfi_to_gfc, gfor_fndecl_gfc_to_cfi): Remove
832 global-var declaration.
834 2021-10-18 Tobias Burnus <tobias@codesourcery.com>
837 * intrinsic.c (gfc_convert_type_warn): Fix checks by checking CLASS
838 and do typcheck in correct order for type extension.
839 * misc.c (gfc_typename): Print proper not internal CLASS type name.
841 2021-10-15 Harald Anlauf <anlauf@gmx.de>
842 Tobias Burnus <tobias@codesourcery.com>
845 * decl.c (match_clist_expr): Set rank/shape of clist initializer
847 * resolve.c (resolve_structure_cons): In a structure constructor,
848 compare shapes of array components against declared shape.
850 2021-10-14 Harald Anlauf <anlauf@gmx.de>
853 * simplify.c (gfc_simplify_reshape): Replace assert by error
854 message for negative elements in SHAPE array.
856 2021-10-14 Harald Anlauf <anlauf@gmx.de>
859 * check.c (gfc_check_shape): Reorder checks so that invalid KIND
860 arguments can be detected.
862 2021-10-14 Kwok Cheung Yeung <kcy@codesourcery.com>
864 * gfortran.h (enum gfc_statement): Add ST_OMP_DECLARE_VARIANT.
865 (enum gfc_omp_trait_property_kind): New.
866 (struct gfc_omp_trait_property): New.
867 (gfc_get_omp_trait_property): New macro.
868 (struct gfc_omp_selector): New.
869 (gfc_get_omp_selector): New macro.
870 (struct gfc_omp_set_selector): New.
871 (gfc_get_omp_set_selector): New macro.
872 (struct gfc_omp_declare_variant): New.
873 (gfc_get_omp_declare_variant): New macro.
874 (struct gfc_namespace): Add omp_declare_variant field.
875 (gfc_free_omp_declare_variant_list): New prototype.
876 * match.h (gfc_match_omp_declare_variant): New prototype.
877 * openmp.c (gfc_free_omp_trait_property_list): New.
878 (gfc_free_omp_selector_list): New.
879 (gfc_free_omp_set_selector_list): New.
880 (gfc_free_omp_declare_variant_list): New.
881 (gfc_match_omp_clauses): Add extra optional argument. Handle end of
882 clauses for context selectors.
883 (omp_construct_selectors, omp_device_selectors,
884 omp_implementation_selectors, omp_user_selectors): New.
885 (gfc_match_omp_context_selector): New.
886 (gfc_match_omp_context_selector_specification): New.
887 (gfc_match_omp_declare_variant): New.
888 * parse.c: Include tree-core.h and omp-general.h.
889 (decode_omp_directive): Handle 'declare variant'.
890 (case_omp_decl): Include ST_OMP_DECLARE_VARIANT.
891 (gfc_ascii_statement): Handle ST_OMP_DECLARE_VARIANT.
892 (gfc_parse_file): Initialize omp_requires_mask.
893 * symbol.c (gfc_free_namespace): Call
894 gfc_free_omp_declare_variant_list.
895 * trans-decl.c (gfc_get_extern_function_decl): Call
896 gfc_trans_omp_declare_variant.
897 (gfc_create_function_decl): Call gfc_trans_omp_declare_variant.
898 * trans-openmp.c (gfc_trans_omp_declare_variant): New.
899 * trans-stmt.h (gfc_trans_omp_declare_variant): New prototype.
901 2021-10-13 Tobias Burnus <tobias@codesourcery.com>
903 * dump-parse-tree.c (show_omp_clauses): Handle ancestor modifier,
904 avoid ICE for GFC_OMP_ATOMIC_SWAP.
905 * gfortran.h (gfc_omp_clauses): Change 'anecestor' into a bitfield.
907 2021-10-12 Tobias Burnus <tobias@codesourcery.com>
910 * check.c (gfc_check_present): Handle optional CLASS.
911 * interface.c (gfc_compare_actual_formal): Likewise.
912 * trans-array.c (gfc_trans_g77_array): Likewise.
913 * trans-decl.c (gfc_build_dummy_array_decl): Likewise.
914 * trans-types.c (gfc_sym_type): Likewise.
915 * primary.c (gfc_variable_attr): Fixes for dummy and
916 pointer when 'class%_data' is passed.
917 * trans-expr.c (set_dtype_for_unallocated, gfc_conv_procedure_call):
918 For assumed-rank dummy, fix setting rank for dealloc/notassoc actual
919 and setting ubound to -1 for assumed-size actuals.
921 2021-10-10 Harald Anlauf <anlauf@gmx.de>
925 * decl.c (add_init_expr_to_sym): Extend initialization of
926 parameter arrays from scalars to handle derived types.
928 2021-10-09 Harald Anlauf <anlauf@gmx.de>
931 * module.c (read_module): Handle old and new-style relational
932 operators when used in USE module, ONLY: OPERATOR(op).
934 2021-10-08 Sandra Loosemore <sandra@codesourcery.com>
937 * interface.c (gfc_compare_actual_formal): Add diagnostic
938 for F2018:C839. Refactor shared code and fix bugs with class
939 array info lookup, and extend similar diagnostic from PR94110
940 to also cover class types.
942 2021-10-08 Martin Liska <mliska@suse.cz>
944 * options.c (gfc_post_options): Use new macro
947 2021-10-06 Tobias Burnus <tobias@codesourcery.com>
949 * resolve.c (resolve_values): Only show
950 deprecated warning if attr.referenced.
952 2021-10-04 Tobias Burnus <tobias@codesourcery.com>
955 * resolve.c (can_generate_init, resolve_fl_variable_derived,
956 resolve_symbol): Only do initialization with intent(out) if not
957 inside of an interface block.
959 2021-10-01 Martin Sebor <msebor@redhat.com>
962 * array.c: Remove an unnecessary test.
963 * trans-array.c: Same.
965 2021-10-01 Jakub Jelinek <jakub@redhat.com>
967 * gfortran.h (gfc_omp_clauses): Add order_reproducible bitfield.
968 * dump-parse-tree.c (show_omp_clauses): Print REPRODUCIBLE: for it.
969 * openmp.c (gfc_match_omp_clauses): Set order_reproducible for
970 explicit reproducible: modifier.
971 * trans-openmp.c (gfc_trans_omp_clauses): Set
972 OMP_CLAUSE_ORDER_REPRODUCIBLE for order_reproducible.
973 (gfc_split_omp_clauses): Also copy order_reproducible.
975 2021-09-30 Harald Anlauf <anlauf@gmx.de>
978 * simplify.c (simplify_size): Resolve expressions used in array
979 specifications so that SIZE can be simplified.
981 2021-09-30 Harald Anlauf <anlauf@gmx.de>
983 * expr.c: The correct reference to Fortran standard is: F2018:10.1.12.
985 2021-09-30 Tobias Burnus <tobias@codesourcery.com>
989 * trans-intrinsic.c (gfc_conv_same_type_as): Fix handling
991 * trans.h (gfc_vtpr_hash_get): Renamed prototype to ...
992 (gfc_vptr_hash_get): ... this to match function name.
994 2021-09-29 Harald Anlauf <anlauf@gmx.de>
997 * array.c (expand_constructor): Do not dereference NULL pointer.
999 2021-09-27 Tobias Burnus <tobias@codesourcery.com>
1002 * trans-array.c (gfc_tree_array_size): New function to
1003 find size inline (whole array or one dimension).
1004 (array_parameter_size): Use it, take stmt_block as arg.
1005 (gfc_conv_array_parameter): Update call.
1006 * trans-array.h (gfc_tree_array_size): Add prototype.
1007 * trans-decl.c (gfor_fndecl_size0, gfor_fndecl_size1): Remove
1009 (gfc_build_intrinsic_function_decls): Remove their initialization.
1010 * trans-expr.c (gfc_conv_procedure_call): Update
1011 bounds of pointer/allocatable actual args to nonallocatable/nonpointer
1012 dummies to be one based.
1013 * trans-intrinsic.c (gfc_conv_intrinsic_shape): Fix case for
1014 assumed rank with allocatable/pointer dummy.
1015 (gfc_conv_intrinsic_size): Update to use inline function.
1016 * trans.h (gfor_fndecl_size0, gfor_fndecl_size1): Remove var decl.
1018 2021-09-26 Tobias Burnus <tobias@codesourcery.com>
1021 * trans-intrinsic.c (gfc_conv_associated): Support assumed-rank
1022 'pointer' with scalar/array 'target' argument.
1024 2021-09-24 Harald Anlauf <anlauf@gmx.de>
1027 * expr.c (is_non_constant_intrinsic): Check for intrinsics
1028 excluded in constant expressions (F2018:10.1.2).
1029 (gfc_is_constant_expr): Use that check.
1031 2021-09-24 Sandra Loosemore <sandra@codesourcery.com>
1034 * interface.c (compare_parameter): Enforce F2018 C711.
1036 2021-09-24 Tobias Burnus <tobias@codesourcery.com>
1039 * scanner.c (load_file): Return void, call (gfc_)fatal_error for
1041 (include_line, include_stmt, gfc_new_file): Remove exit call
1042 for failed load_file run.
1044 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
1047 * decl.c (gfc_verify_c_interop_param): Handle F2018 C1557,
1050 2021-09-23 Harald Anlauf <anlauf@gmx.de>
1051 Tobias Burnus <tobias@codesourcery.com>
1054 * trans-intrinsic.c (gfc_conv_allocated): Cleanup. Handle
1055 coindexed scalar coarrays.
1057 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
1060 * interface.c (gfc_compare_actual_formal): Extend existing
1061 assumed-type diagnostic to also check for argument with type
1064 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
1067 * check.c (gfc_check_associated): Allow an assumed-rank
1068 array for the pointer argument.
1069 * interface.c (compare_parameter): Also give rank mismatch
1070 error on assumed-rank array.
1072 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
1074 * trans-stmt.c (trans_associate_var): Check that result of
1075 GFC_DECL_SAVED_DESCRIPTOR is not null before using it.
1077 2021-09-22 Tobias Burnus <tobias@codesourcery.com>
1080 * cpp.c (gfc_cpp_register_include_paths, gfc_cpp_post_options):
1081 Add new bool verbose_missing_dir_warn argument.
1082 * cpp.h (gfc_cpp_post_options): Update prototype.
1083 * f95-lang.c (gfc_init): Remove duplicated file-not found diag.
1084 * gfortran.h (gfc_check_include_dirs): Takes bool
1085 verbose_missing_dir_warn arg.
1086 (gfc_new_file): Returns now void.
1087 * options.c (gfc_post_options): Update to warn for -I and -J,
1088 only, by default but for all when user requested.
1089 * scanner.c (gfc_do_check_include_dir):
1090 (gfc_do_check_include_dirs, gfc_check_include_dirs): Take bool
1091 verbose warn arg and update to avoid printing the same message
1093 (load_file): Fix indent.
1094 (gfc_new_file): Return void and exit when load_file failed
1095 as all other load_file users do.
1097 2021-09-22 Tobias Burnus <tobias@codesourcery.com>
1099 * trans-expr.c (gfc_simple_for_loop): New.
1100 * trans.h (gfc_simple_for_loop): New prototype.
1102 2021-09-21 Tobias Burnus <tobias@codesourcery.com>
1105 * cpp.c: Define GCC_C_COMMON_C for #include "options.h" to make
1106 cpp_reason_option_codes available.
1107 (gfc_cpp_register_include_paths): Make static, set pfile's
1108 warn_missing_include_dirs and move before caller.
1109 (gfc_cpp_init_cb): New, cb code moved from ...
1110 (gfc_cpp_init_0): ... here.
1111 (gfc_cpp_post_options): Call gfc_cpp_init_cb.
1112 (cb_cpp_diagnostic_cpp_option): New. As implemented in c-family
1113 to match CppReason flags to -W... names.
1114 (cb_cpp_diagnostic): Use it to replace single special case.
1115 * cpp.h (gfc_cpp_register_include_paths): Remove as now static.
1116 * gfortran.h (gfc_check_include_dirs): New prototype.
1117 (gfc_add_include_path): Add new bool arg.
1118 * options.c (gfc_init_options): Don't set -Wmissing-include-dirs.
1119 (gfc_post_options): Set it here after commandline processing. Call
1120 gfc_add_include_path with defer_warn=false.
1121 (gfc_handle_option): Call it with defer_warn=true.
1122 * scanner.c (gfc_do_check_include_dir, gfc_do_check_include_dirs,
1123 gfc_check_include_dirs): New. Diagnostic moved from ...
1124 (add_path_to_list): ... here, which came before cmdline processing.
1125 Take additional bool defer_warn argument.
1126 (gfc_add_include_path): Take additional defer_warn arg.
1127 * scanner.h (struct gfc_directorylist): Reorder for alignment issues,
1128 add new 'bool warn'.
1130 2021-09-20 Tobias Burnus <tobias@codesourcery.com>
1132 * gfortran.h (gfc_omp_clauses): Add order_unconstrained.
1133 * dump-parse-tree.c (show_omp_clauses): Dump it.
1134 * openmp.c (gfc_match_omp_clauses): Match unconstrained/reproducible
1135 modifiers to ordered(concurrent).
1136 (OMP_DISTRIBUTE_CLAUSES): Accept ordered clause.
1137 (resolve_omp_clauses): Reject ordered + order on same directive.
1138 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses): Pass
1139 on unconstrained modifier of ordered(concurrent).
1141 2021-09-17 Harald Anlauf <anlauf@gmx.de>
1144 * trans-decl.c (gfc_finish_var_decl): Disable the warning message
1145 for variables moved from stack to static storange if they are
1146 declared in the main, but allow the move to happen.
1148 2021-09-17 Sandra Loosemore <sandra@codesourcery.com>
1150 * intrinsic.texi (ISO_C_BINDING): Change C_FLOAT128 to correspond
1151 to _Float128 rather than __float128.
1152 * iso-c-binding.def (c_float128): Update comments.
1153 * trans-intrinsic.c (gfc_builtin_decl_for_float_kind): Likewise.
1154 (build_round_expr): Likewise.
1155 (gfc_build_intrinsic_lib_fndcecls): Likewise.
1156 * trans-types.h (gfc_real16_is_float128): Likewise.
1158 2021-09-16 Harald Anlauf <anlauf@gmx.de>
1161 * trans-expr.c (gfc_conv_procedure_call): Wrap deallocation of
1162 allocatable components of optional allocatable derived type
1163 procedure arguments with INTENT(OUT) into a presence check.
1165 2021-09-14 Harald Anlauf <anlauf@gmx.de>
1168 * resolve.c (resolve_entries): Attempt to recover cleanly after
1169 rejecting mismatched function entries.
1171 2021-09-14 Tobias Burnus <tobias@codesourcery.com>
1174 * parse.c (gfc_ascii_statement): Add missing ST_OMP_END_SCOPE.
1176 2021-09-13 Harald Anlauf <anlauf@gmx.de>
1179 * decl.c (add_init_expr_to_sym): For proper initialization of
1180 array-valued named constants the array bounds need to be
1181 simplified before adding the initializer.
1183 2021-09-13 Harald Anlauf <anlauf@gmx.de>
1186 * expr.c (find_substring_ref): Handle given substring start and
1187 end indices as signed integers, not unsigned.
1189 2021-09-09 Harald Anlauf <anlauf@gmx.de>
1192 * trans-expr.c (gfc_conv_substring): Do not generate substring
1193 bounds check for implied do loop index variable before it actually
1196 2021-09-08 liuhongt <hongtao.liu@intel.com>
1198 * options.c (gfc_post_options): Issue an error for
1199 -fexcess-precision=16.
1201 2021-09-07 Harald Anlauf <anlauf@gmx.de>
1204 * expr.c (find_array_element): When bounds cannot be determined as
1205 constant, return error instead of aborting.
1207 2021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
1209 * openmp.c (gfc_match_omp_flush): Parse 'seq_cst' clause on 'flush'
1211 * trans-openmp.c (gfc_trans_omp_flush): Handle OMP_MEMORDER_SEQ_CST.
1213 2021-09-03 Tobias Burnus <tobias@codesourcery.com>
1215 * decl.c (gfc_verify_c_interop_param): Reject pointer with
1216 CONTIGUOUS attributes as dummy arg. Reject character len > 1
1217 when passed as byte stream.
1219 2021-09-01 Harald Anlauf <anlauf@gmx.de>
1222 * resolve.c (resolve_common_vars): Fix grammar and improve wording
1223 of error message rejecting an unlimited polymorphic in COMMON.
1225 2021-08-31 Harald Anlauf <anlauf@gmx.de>
1228 * simplify.c (substring_has_constant_len): Minimize checks for
1229 substring expressions being allowed.
1231 2021-08-31 Marcel Vollweiler <marcel@codesourcery.com>
1233 * gfortran.h: Add variable for 'ancestor' in struct gfc_omp_clauses.
1234 * openmp.c (gfc_match_omp_clauses): Parse device-modifiers 'device_num'
1235 and 'ancestor' in 'target device' clauses.
1236 * trans-openmp.c (gfc_trans_omp_clauses): Set OMP_CLAUSE_DEVICE_ANCESTOR.
1238 2021-08-30 Harald Anlauf <anlauf@gmx.de>
1241 * match.c (gfc_match_goto): Allow for whitespace in parsing list
1244 2021-08-30 Harald Anlauf <anlauf@gmx.de>
1247 * resolve.c (resolve_allocate_expr): An unlimited polymorphic
1248 argument to ALLOCATE must be ALLOCATABLE or a POINTER. Fix the
1249 corresponding check.
1251 2021-08-28 Harald Anlauf <anlauf@gmx.de>
1254 * resolve.c (resolve_entries): For functions of type CHARACTER
1255 tighten the checks for matching characteristics.
1257 2021-08-25 Lewis Hyatt <lhyatt@gmail.com>
1260 * cpp.c (gfc_cpp_post_options): Call new function
1261 diagnostic_initialize_input_context().
1263 2021-08-24 Harald Anlauf <anlauf@gmx.de>
1266 * trans-decl.c (gfc_finish_var_decl): Adjust check to handle
1267 implicit SAVE as well as variables in the main program. Improve
1268 warning message text.
1270 2021-08-23 Tobias Burnus <tobias@codesourcery.com>
1272 * openmp.c (gfc_match_dupl_check, gfc_match_dupl_memorder,
1273 gfc_match_dupl_atomic): New.
1274 (gfc_match_omp_clauses): Use them; remove duplicate
1275 'release'/'relaxed' clause matching; improve error dignostic
1278 2021-08-23 Tobias Burnus <tobias@codesourcery.com>
1280 * dump-parse-tree.c (show_omp_clauses): Handle 'strict' modifier
1281 on grainsize/num_tasks
1282 * gfortran.h (gfc_omp_clauses): Add grainsize_strict
1283 and num_tasks_strict.
1284 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses):
1285 Handle 'strict' modifier on grainsize/num_tasks.
1286 * openmp.c (gfc_match_omp_clauses): Likewise.
1288 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
1291 (error_uinteger): Take 'long long unsigned' instead
1292 of 'long unsigned' as argumpent.
1293 (error_integer): Take 'long long' instead of 'long'.
1294 (error_hwuint, error_hwint): New.
1295 (error_print): Update to handle 'll' and 'w'
1297 * simplify.c (substring_has_constant_len): Use '%wd'
1300 2021-08-20 Harald Anlauf <anlauf@gmx.de>
1303 * simplify.c (substring_has_constant_len): Fix format string of
1304 gfc_error, pass HOST_WIDE_INT bounds values via char buffer.
1306 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
1308 * dump-parse-tree.c (show_omp_clauses): Handle 'at', 'severity'
1309 and 'message' clauses.
1310 (show_omp_node, show_code_node): Handle EXEC_OMP_ERROR.
1311 * gfortran.h (gfc_statement): Add ST_OMP_ERROR.
1312 (gfc_omp_severity_type, gfc_omp_at_type): New.
1313 (gfc_omp_clauses): Add 'at', 'severity' and 'message' clause;
1314 use more bitfields + ENUM_BITFIELD.
1315 (gfc_exec_op): Add EXEC_OMP_ERROR.
1316 * match.h (gfc_match_omp_error): New.
1317 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_(AT,SEVERITY,MESSAGE).
1318 (gfc_match_omp_clauses): Handle new clauses.
1319 (OMP_ERROR_CLAUSES, gfc_match_omp_error): New.
1320 (resolve_omp_clauses): Resolve new clauses.
1321 (omp_code_to_statement, gfc_resolve_omp_directive): Handle
1323 * parse.c (decode_omp_directive, next_statement,
1324 gfc_ascii_statement): Handle 'omp error'.
1325 * resolve.c (gfc_resolve_blocks): Likewise.
1326 * st.c (gfc_free_statement): Likewise.
1327 * trans-openmp.c (gfc_trans_omp_error): Likewise.
1328 (gfc_trans_omp_directive): Likewise.
1329 * trans.c (trans_code): Likewise.
1331 2021-08-20 Jakub Jelinek <jakub@redhat.com>
1333 * types.def (BT_FN_VOID_CONST_PTR_SIZE): New DEF_FUNCTION_TYPE_2.
1334 * f95-lang.c (ATTR_COLD_NORETURN_NOTHROW_LEAF_LIST): Define.
1336 2021-08-19 Harald Anlauf <anlauf@gmx.de>
1339 * simplify.c (substring_has_constant_len): New.
1340 (gfc_simplify_len): Handle case of substrings with constant
1343 2021-08-18 Tobias Burnus <tobias@codesourcery.com>
1345 * match.h (gfc_match_omp_nothing): New.
1346 * openmp.c (gfc_match_omp_nothing): New.
1347 * parse.c (decode_omp_directive): Match 'nothing' directive.
1349 2021-08-17 Tobias Burnus <tobias@codesourcery.com>
1351 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
1353 * gfortran.h (enum gfc_statement): Add ST_OMP_(END_)SCOPE.
1354 (enum gfc_exec_op): Add EXEC_OMP_SCOPE.
1355 * match.h (gfc_match_omp_scope): New.
1356 * openmp.c (OMP_SCOPE_CLAUSES): Define
1357 (gfc_match_omp_scope): New.
1358 (gfc_match_omp_cancellation_point, gfc_match_omp_end_nowait):
1359 Improve error diagnostic.
1360 (omp_code_to_statement): Handle ST_OMP_SCOPE.
1361 (gfc_resolve_omp_directive): Handle EXEC_OMP_SCOPE.
1362 * parse.c (decode_omp_directive, next_statement,
1363 gfc_ascii_statement, parse_omp_structured_block,
1364 parse_executable): Handle OpenMP's scope construct.
1365 * resolve.c (gfc_resolve_blocks): Likewise
1366 * st.c (gfc_free_statement): Likewise
1367 * trans-openmp.c (gfc_trans_omp_scope): New.
1368 (gfc_trans_omp_directive): Call it.
1369 * trans.c (trans_code): handle EXEC_OMP_SCOPE.
1371 2021-08-16 Tobias Burnus <tobias@codesourcery.com>
1373 * dump-parse-tree.c (show_omp_clauses): Handle 'filter' clause.
1374 (show_omp_node, show_code_node): Handle (combined) omp masked construct.
1375 * frontend-passes.c (gfc_code_walker): Likewise.
1376 * gfortran.h (enum gfc_statement): Add ST_OMP_*_MASKED*.
1377 (enum gfc_exec_op): Add EXEC_OMP_*_MASKED*.
1378 * match.h (gfc_match_omp_masked, gfc_match_omp_masked_taskloop,
1379 gfc_match_omp_masked_taskloop_simd, gfc_match_omp_parallel_masked,
1380 gfc_match_omp_parallel_masked_taskloop,
1381 gfc_match_omp_parallel_masked_taskloop_simd): New prototypes.
1382 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_FILTER.
1383 (gfc_match_omp_clauses): Match it.
1384 (OMP_MASKED_CLAUSES, gfc_match_omp_parallel_masked,
1385 gfc_match_omp_parallel_masked_taskloop,
1386 gfc_match_omp_parallel_masked_taskloop_simd,
1387 gfc_match_omp_masked, gfc_match_omp_masked_taskloop,
1388 gfc_match_omp_masked_taskloop_simd): New.
1389 (resolve_omp_clauses): Resolve filter clause.
1390 (gfc_resolve_omp_parallel_blocks, resolve_omp_do,
1391 omp_code_to_statement, gfc_resolve_omp_directive): Handle
1392 omp masked constructs.
1393 * parse.c (decode_omp_directive, case_exec_markers,
1394 gfc_ascii_statement, parse_omp_do, parse_omp_structured_block,
1395 parse_executable): Likewise.
1396 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
1397 * st.c (gfc_free_statement): Likewise.
1398 * trans-openmp.c (gfc_trans_omp_clauses): Handle filter clause.
1399 (GFC_OMP_SPLIT_MASKED, GFC_OMP_MASK_MASKED): New enum values.
1400 (gfc_trans_omp_masked): New.
1401 (gfc_split_omp_clauses): Handle combined masked directives.
1402 (gfc_trans_omp_master_taskloop): Rename to ...
1403 (gfc_trans_omp_master_masked_taskloop): ... this; handle also
1404 combined masked directives.
1405 (gfc_trans_omp_parallel_master): Rename to ...
1406 (gfc_trans_omp_parallel_master_masked): ... this; handle
1407 combined masked directives.
1408 (gfc_trans_omp_directive): Handle EXEC_OMP_*_MASKED*.
1409 * trans.c (trans_code): Likewise.
1411 2021-08-15 Harald Anlauf <anlauf@gmx.de>
1414 * match.c (sync_statement): Replace %v code by %e in gfc_match to
1415 allow for function references as STAT and ERRMSG arguments.
1416 * resolve.c (resolve_sync): Adjust checks of STAT= and ERRMSG= to
1417 being definable arguments. Function references with a data
1418 pointer result are accepted.
1419 * trans-stmt.c (gfc_trans_sync): Adjust assertion.
1421 2021-08-12 Tobias Burnus <tobias@codesourcery.com>
1423 * gfortran.h (gfc_omp_proc_bind_kind): Add OMP_PROC_BIND_PRIMARY.
1424 * dump-parse-tree.c (show_omp_clauses): Add TODO comment to
1425 change 'master' to 'primary' in proc_bind for OpenMP 5.1.
1426 * intrinsic.texi (OMP_LIB): Mention OpenMP 5.1; add
1427 omp_proc_bind_primary.
1428 * openmp.c (gfc_match_omp_clauses): Accept
1429 'primary' as alias for 'master'.
1430 * trans-openmp.c (gfc_trans_omp_clauses): Handle
1431 OMP_PROC_BIND_PRIMARY.
1433 2021-08-11 Sandra Loosemore <sandra@codesourcery.com>
1435 * iso-c-binding.def (c_float128, c_float128_complex): Check
1436 float128_type_node instead of gfc_float128_type_node.
1437 * trans-types.c (gfc_init_kinds, gfc_build_real_type):
1438 Update comments re supported 128-bit floating-point types.
1440 2021-08-11 Richard Biener <rguenther@suse.de>
1442 * trans-common.c (create_common): Set TREE_THIS_VOLATILE on the
1443 COMPONENT_REF if the field is volatile.
1445 2021-08-07 Harald Anlauf <anlauf@gmx.de>
1448 * primary.c (gfc_expr_attr): Variable attribute can only be
1449 inquired when symtree is non-NULL.
1451 2021-07-28 Harald Anlauf <anlauf@gmx.de>
1454 * expr.c (gfc_check_vardef_context): Add check for KIND and LEN
1455 parameter inquiries.
1456 * match.c (gfc_match): Fix comment for %v code.
1457 (gfc_match_allocate, gfc_match_deallocate): Replace use of %v code
1458 by %e in gfc_match to allow for function references as STAT and
1460 * resolve.c (resolve_allocate_deallocate): Avoid NULL pointer
1461 dereferences and shortcut for bad STAT and ERRMSG argument to
1462 (DE)ALLOCATE. Remove bogus parts of checks for STAT and ERRMSG.
1464 2021-07-26 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1465 Tobias Burnus <tobias@codesourcery.com>
1472 * trans-decl.c (convert_CFI_desc): Only copy out the descriptor
1474 * trans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): Updated attribute
1475 handling which reflect a previous intermediate version of the
1476 standard. Only copy out the descriptor if necessary.
1478 2021-07-23 Harald Anlauf <anlauf@gmx.de>
1481 * check.c (array_check): Adjust check for the case of CLASS
1484 2021-07-21 Thomas Schwinge <thomas@codesourcery.com>
1485 Joseph Myers <joseph@codesourcery.com>
1486 Cesar Philippidis <cesar@codesourcery.com>
1488 * dump-parse-tree.c (show_attr): Update.
1489 * gfortran.h (symbol_attribute): Add 'oacc_routine_nohost' member.
1490 (gfc_omp_clauses): Add 'nohost' member.
1491 * module.c (ab_attribute): Add 'AB_OACC_ROUTINE_NOHOST'.
1492 (attr_bits, mio_symbol_attribute): Update.
1493 * openmp.c (omp_mask2): Add 'OMP_CLAUSE_NOHOST'.
1494 (gfc_match_omp_clauses): Handle 'OMP_CLAUSE_NOHOST'.
1495 (OACC_ROUTINE_CLAUSES): Add 'OMP_CLAUSE_NOHOST'.
1496 (gfc_match_oacc_routine): Update.
1497 * trans-decl.c (add_attributes_to_decl): Update.
1498 * trans-openmp.c (gfc_trans_omp_clauses): Likewise.
1500 2021-07-21 Harald Anlauf <anlauf@gmx.de>
1503 * target-memory.c (gfc_interpret_derived): Size of array component
1504 of derived type can only be computed here for explicit shape.
1505 * trans-types.c (gfc_get_nodesc_array_type): Do not dereference
1508 2021-07-21 Tobias Burnus <tobias@codesourcery.com>
1510 * decl.c (gfc_verify_c_interop_param): Update for F2008 + F2018
1511 changes; reject unsupported bits with 'Error: Sorry,'.
1512 * trans-expr.c (gfc_conv_procedure_call): Fix condition to
1513 For using CFI descriptor with characters.
1515 2021-07-18 Harald Anlauf <anlauf@gmx.de>
1518 * io.c (resolve_tag_format): Extend FORMAT check to unknown type.
1520 2021-07-14 Harald Anlauf <anlauf@gmx.de>
1523 * trans-expr.c (gfc_trans_class_init_assign): Call
1524 gfc_conv_expr_present only for dummy variables.
1526 2021-07-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1529 * frontend-passes.c (traverse_io_block): Adjust test for
1530 when a variable is eligible for the transformation to
1533 2021-06-28 Martin Sebor <msebor@redhat.com>
1535 * trans-array.c (trans_array_constructor): Replace direct uses
1536 of TREE_NO_WARNING with warning_suppressed_p, and suppress_warning.
1537 * trans-decl.c (gfc_build_qualified_array): Same.
1538 (gfc_build_dummy_array_decl): Same.
1539 (generate_local_decl): Same.
1540 (gfc_generate_function_code): Same.
1541 * trans-openmp.c (gfc_omp_clause_default_ctor): Same.
1542 (gfc_omp_clause_copy_ctor): Same.
1543 * trans-types.c (get_dtype_type_node): Same.
1544 (gfc_get_desc_dim_type): Same.
1545 (gfc_get_array_descriptor_base): Same.
1546 (gfc_get_caf_vector_type): Same.
1547 (gfc_get_caf_reference_type): Same.
1548 * trans.c (gfc_create_var_np): Same.
1550 2021-06-23 Tobias Burnus <tobias@codesourcery.com>
1552 * dump-parse-tree.c (show_omp_clauses): Fix enum type used
1553 for dumping gfc_omp_defaultmap_category.
1555 2021-06-23 Andre Vehreschild <vehre@gcc.gnu.org>
1558 * trans-intrinsic.c (conv_co_collective): Check stat for null ptr
1559 before dereferrencing.
1561 2021-06-18 Harald Anlauf <anlauf@gmx.de>
1565 * trans-intrinsic.c (gfc_conv_intrinsic_minmax): Unconditionally
1566 convert result of min/max to result type.
1568 2021-06-16 Harald Anlauf <anlauf@gmx.de>
1572 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
1574 * match.c (gfc_match_pointer_assignment): Likewise.
1575 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
1578 2021-06-16 Harald Anlauf <anlauf@gmx.de>
1581 2021-06-16 Harald Anlauf <anlauf@gmx.de>
1585 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
1587 * match.c (gfc_match_pointer_assignment): Likewise.
1588 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
1591 2021-06-16 Harald Anlauf <anlauf@gmx.de>
1595 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
1597 * match.c (gfc_match_pointer_assignment): Likewise.
1598 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
1601 2021-06-15 Tobias Burnus <tobias@codesourcery.com>
1604 * dump-parse-tree.c (show_omp_clauses): Update for defaultmap.
1605 * f95-lang.c (LANG_HOOKS_OMP_ALLOCATABLE_P,
1606 LANG_HOOKS_OMP_SCALAR_TARGET_P): New.
1607 * gfortran.h (enum gfc_omp_defaultmap,
1608 enum gfc_omp_defaultmap_category): New.
1609 * openmp.c (gfc_match_omp_clauses): Update defaultmap matching.
1610 * trans-decl.c (gfc_finish_decl_attrs): Set GFC_DECL_SCALAR_TARGET.
1611 * trans-openmp.c (gfc_omp_allocatable_p, gfc_omp_scalar_target_p): New.
1612 (gfc_omp_scalar_p): Take 'ptr_alloc_ok' argument.
1613 (gfc_trans_omp_clauses, gfc_split_omp_clauses): Update for
1615 * trans.h (gfc_omp_scalar_p): Update prototype.
1616 (gfc_omp_allocatable_p, gfc_omp_scalar_target_p): New.
1617 (struct lang_decl): Add scalar_target.
1618 (GFC_DECL_SCALAR_TARGET, GFC_DECL_GET_SCALAR_TARGET): New.
1620 2021-06-14 Tobias Burnus <tobias@codesourcery.com>
1622 * resolve.c (resolve_variable): Remove *XCNEW used to
1623 nullify nullified memory.
1625 2021-06-09 Martin Liska <mliska@suse.cz>
1627 * intrinsic.texi: Add missing @headitem to tables with a header.
1629 2021-06-09 Jakub Jelinek <jakub@redhat.com>
1632 * trans-openmp.c (gfc_omp_finish_clause): Gimplify OMP_CLAUSE_SIZE.
1634 2021-06-08 Tobias Burnus <tobias@codesourcery.com>
1637 * trans-openmp.c (gfc_add_clause_implicitly): New.
1638 (gfc_split_omp_clauses): Use it.
1639 (gfc_free_split_omp_clauses): New.
1640 (gfc_trans_omp_do_simd, gfc_trans_omp_parallel_do,
1641 gfc_trans_omp_parallel_do_simd, gfc_trans_omp_distribute,
1642 gfc_trans_omp_teams, gfc_trans_omp_target, gfc_trans_omp_taskloop,
1643 gfc_trans_omp_master_taskloop, gfc_trans_omp_parallel_master): Use it.
1645 2021-06-08 Martin Liska <mliska@suse.cz>
1647 * intrinsic.texi: Fix typo.
1648 * trans-expr.c (gfc_trans_pointer_assignment): Likewise.
1650 2021-06-05 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1657 * trans-array.c (gfc_get_array_span): rework the way character
1658 array "span" was calculated.
1659 (gfc_conv_expr_descriptor): improve handling of character sections
1660 and unlimited polymorphic objects.
1661 * trans-expr.c (gfc_get_character_len): new function to calculate
1662 character string length.
1663 (gfc_get_character_len_in_bytes): new function to calculate
1664 character string length in bytes.
1665 (gfc_conv_scalar_to_descriptor): add call to set the "span".
1666 (gfc_trans_pointer_assignment): set "_len" and antecipate the
1667 initialization of the deferred character length hidden argument.
1668 * trans-intrinsic.c (gfc_conv_associated): set "force_no_tmp" to
1669 avoid the creation of a temporary.
1670 * trans-types.c (gfc_get_dtype_rank_type): rework type detection
1671 so that unlimited polymorphic objects get proper type infomation,
1672 also important for bind(c).
1673 (gfc_get_dtype): add argument to pass the rank if necessary.
1674 (gfc_get_array_type_bounds): cosmetic change to have character
1675 arrays called character instead of unknown.
1676 * trans-types.h (gfc_get_dtype): modify prototype.
1677 * trans.c (get_array_span): rework the way character array "span"
1679 * trans.h (gfc_get_character_len): new prototype.
1680 (gfc_get_character_len_in_bytes): new prototype.
1681 Add "unlimited_polymorphic" flag to "gfc_se" type to signal when
1682 expression carries an unlimited polymorphic object.
1684 2021-06-04 Harald Anlauf <anlauf@gmx.de>
1687 * frontend-passes.c (inline_matmul_assign): Do not inline matmul
1688 if the assignment to the resulting array if it is not of canonical
1689 type (real/integer/complex/logical).
1691 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1693 * dump-parse-tree.c (show_code_node): Handle
1694 EXEC_OMP_(TARGET_)(,PARALLEL_,TEAMS_)LOOP.
1696 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1698 * scanner.c (skip_fixed_omp_sentinel): Set openacc_flag if
1699 this is not an (OpenMP) continuation line.
1700 (skip_fixed_oacc_sentinel): Likewise for openmp_flag and OpenACC.
1701 (gfc_next_char_literal): gfc_error_now to force error for mixed OMP/ACC
1702 continuation once per location and return '\n'.
1704 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1707 * openmp.c (gfc_match_omp_clauses): Fix typo in error message.
1709 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1712 * dump-parse-tree.c (show_omp_clauses): Handle bind clause.
1713 (show_omp_node): Handle loop directive.
1714 * frontend-passes.c (gfc_code_walker): Likewise.
1715 * gfortran.h (enum gfc_statement): Add
1716 ST_OMP_(END_)(TARGET_)(|PARALLEL_|TEAMS_)LOOP.
1717 (enum gfc_omp_bind_type): New.
1718 (gfc_omp_clauses): Use it.
1719 (enum gfc_exec_op): Add EXEC_OMP_(TARGET_)(|PARALLEL_|TEAMS_)LOOP.
1720 * match.h (gfc_match_omp_loop, gfc_match_omp_parallel_loop,
1721 gfc_match_omp_target_parallel_loop, gfc_match_omp_target_teams_loop,
1722 gfc_match_omp_teams_loop): New.
1723 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_BIND.
1724 (gfc_match_omp_clauses): Handle it.
1725 (OMP_LOOP_CLAUSES, gfc_match_omp_loop, gfc_match_omp_teams_loop,
1726 gfc_match_omp_target_teams_loop, gfc_match_omp_parallel_loop,
1727 gfc_match_omp_target_parallel_loop): New.
1728 (resolve_omp_clauses, resolve_omp_do, omp_code_to_statement,
1729 gfc_resolve_omp_directive): Handle omp loop.
1730 * parse.c (decode_omp_directive case_exec_markers, gfc_ascii_statement,
1731 parse_omp_do, parse_executable): Likewise.
1732 (parse_omp_structured_block): Remove ST_ which use parse_omp_do.
1733 * resolve.c (gfc_resolve_blocks): Add omp loop.
1734 * st.c (gfc_free_statement): Likewise.
1735 * trans-openmp.c (gfc_trans_omp_clauses): Handle bind clause.
1736 (gfc_trans_omp_do, gfc_trans_omp_parallel_do, gfc_trans_omp_distribute,
1737 gfc_trans_omp_teams, gfc_trans_omp_target, gfc_trans_omp_directive):
1738 Handle loop directive.
1739 (gfc_split_omp_clauses): Likewise; fix firstprivate/lastprivate
1740 and (in_)reduction for taskloop.
1741 * trans.c (trans_code): Handle omp loop directive.
1743 2021-06-01 Tobias Burnus <tobias@codesourcery.com>
1746 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
1747 (parallel) master taskloop (simd).
1748 * frontend-passes.c (gfc_code_walker): Set in_omp_workshare
1749 to false for parallel master taskloop (simd).
1750 * gfortran.h (enum gfc_statement):
1751 Add ST_OMP_(END_)(PARALLEL_)MASTER_TASKLOOP(_SIMD).
1752 (enum gfc_exec_op): EXEC_OMP_(PARALLEL_)MASTER_TASKLOOP(_SIMD).
1753 * match.h (gfc_match_omp_master_taskloop,
1754 gfc_match_omp_master_taskloop_simd,
1755 gfc_match_omp_parallel_master_taskloop,
1756 gfc_match_omp_parallel_master_taskloop_simd): New prototype.
1757 * openmp.c (gfc_match_omp_parallel_master_taskloop,
1758 gfc_match_omp_parallel_master_taskloop_simd,
1759 gfc_match_omp_master_taskloop,
1760 gfc_match_omp_master_taskloop_simd): New.
1761 (gfc_match_omp_taskloop_simd): Permit 'reduction' clause.
1762 (resolve_omp_clauses): Handle new combined directives; remove
1763 inscan-reduction check to reduce multiple errors; add
1764 task-reduction error for 'taskloop simd'.
1765 (gfc_resolve_omp_parallel_blocks,
1766 resolve_omp_do, omp_code_to_statement,
1767 gfc_resolve_omp_directive): Handle new combined constructs.
1768 * parse.c (decode_omp_directive, next_statement,
1769 gfc_ascii_statement, parse_omp_do, parse_omp_structured_block,
1770 parse_executable): Likewise.
1771 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
1772 * st.c (gfc_free_statement): Likewise.
1773 * trans.c (trans_code): Likewise.
1774 * trans-openmp.c (gfc_split_omp_clauses,
1775 gfc_trans_omp_directive): Likewise.
1776 (gfc_trans_omp_parallel_master): Move after gfc_trans_omp_master_taskloop;
1777 handle parallel master taskloop (simd) as well.
1778 (gfc_trans_omp_taskloop): Take gfc_exec_op as arg.
1779 (gfc_trans_omp_master_taskloop): New.
1781 2021-05-30 Gerald Pfeifer <gerald@pfeifer.com>
1783 * gfortran.texi (BOZ literal constants): Fix typo.
1785 2021-05-28 Tobias Burnus <tobias@codesourcery.com>
1787 * dump-parse-tree.c (show_iterator): New.
1788 (show_omp_namelist): Handle iterators.
1789 (show_omp_clauses): Handle affinity.
1790 * gfortran.h (gfc_free_omp_namelist): New union with 'udr' and new 'ns'.
1791 * match.c (gfc_free_omp_namelist): Add are to choose union element.
1792 * openmp.c (gfc_free_omp_clauses, gfc_match_omp_detach,
1793 gfc_match_omp_clause_reduction, gfc_match_omp_flush): Update
1794 call to gfc_free_omp_namelist.
1795 (gfc_match_omp_variable_list): Likewise; permit preceeding whitespace.
1796 (enum omp_mask1): Add OMP_CLAUSE_AFFINITY.
1797 (gfc_match_iterator): New.
1798 (gfc_match_omp_clauses): Use it; update call to gfc_free_omp_namelist.
1799 (OMP_TASK_CLAUSES): Add OMP_CLAUSE_AFFINITY.
1800 (gfc_match_omp_taskwait): Match depend clause.
1801 (resolve_omp_clauses): Handle affinity; update for udr/union change.
1802 (gfc_resolve_omp_directive): Resolve clauses of taskwait.
1803 * st.c (gfc_free_statement): Update gfc_free_omp_namelist call.
1804 * trans-openmp.c (gfc_trans_omp_array_reduction_or_udr): Likewise
1805 (handle_iterator): New.
1806 (gfc_trans_omp_clauses): Handle iterators for depend/affinity clause.
1807 (gfc_trans_omp_taskwait): Handle depend clause.
1808 (gfc_trans_omp_directive): Update call.
1810 2021-05-27 Harald Anlauf <anlauf@gmx.de>
1813 * trans-intrinsic.c (gfc_conv_intrinsic_size): Use CLASS data
1814 attributes for CLASS arrays for generation of runtime error.
1816 2021-05-27 Harald Anlauf <anlauf@gmx.de>
1819 * trans-array.c (gfc_conv_ss_startstride): Do not call check for
1820 presence of a dummy argument when a symbol actually refers to a
1823 2021-05-25 Tobias Burnus <tobias@codesourcery.com>
1824 Johannes Nendwich <a08727063@unet.univie.ac.at>
1826 * intrinsic.texi (GERROR, GETARGS, GETLOG, NORM2, PARITY, RANDOM_INIT,
1827 RANDOM_NUMBER): Fix typos and copy'n'paste errors.
1829 2021-05-24 Tobias Burnus <tobias@codesourcery.com>
1832 * trans-expr.c (gfc_copy_class_to_class): Add unshare_expr.
1833 * trans-openmp.c (gfc_is_polymorphic_nonptr,
1834 gfc_is_unlimited_polymorphic_nonptr): New.
1835 (gfc_omp_clause_copy_ctor, gfc_omp_clause_dtor): Handle
1836 polymorphic scalars.
1838 2021-05-23 Harald Anlauf <anlauf@gmx.de>
1841 * trans-expr.c (gfc_conv_procedure_call): Adjust check for
1842 implicit conversion of actual argument to an unlimited polymorphic
1845 2021-05-23 Tobias Burnus <tobias@codesourcery.com>
1847 * intrinsic.texi (ATOMIC_ADD, ATOMIC_FETCH_ADD): Use the
1848 proper variable name in the description.
1850 2021-05-22 Andre Vehreschild <vehre@gcc.gnu.org>
1851 Steve Kargl <kargl@gcc.gnu.org>
1854 * trans-decl.c (gfc_build_builtin_function_decls): Move decl.
1855 * trans-intrinsic.c (conv_intrinsic_random_init): Use bool for
1856 lib-call of caf_random_init instead of logical (4-byte).
1857 * trans.h: Add tree var for random_init.
1859 2021-05-20 Marcel Vollweiler <marcel@codesourcery.com>
1861 * openmp.c (gfc_match_omp_clauses): Support map-type-modifier 'close'.
1863 2021-05-18 Tobias Burnus <tobias@codesourcery.com>
1866 * openmp.c (omp_code_to_statement): Add missing EXEC_OMP_DEPOBJ.
1868 2021-05-17 Harald Anlauf <anlauf@gmx.de>
1871 * trans-decl.c (gfc_finish_var_decl): Add check for explicit SAVE
1874 2021-05-17 Tobias Burnus <tobias@codesourcery.com>
1877 * resolve.c (gfc_resolve_code): Reject nonintrinsic assignments in
1880 2021-05-14 Tobias Burnus <tobias@codesourcery.com>
1882 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
1883 EXEC_OMP_PARALLEL_MASTER.
1884 * frontend-passes.c (gfc_code_walker): Likewise.
1885 * gfortran.h (enum gfc_statement): Add ST_OMP_PARALLEL_MASTER and
1886 ST_OMP_END_PARALLEL_MASTER.
1887 (enum gfc_exec_op): Add EXEC_OMP_PARALLEL_MASTER..
1888 * match.h (gfc_match_omp_parallel_master): Handle it.
1889 * openmp.c (gfc_match_omp_parallel_master, resolve_omp_clauses,
1890 omp_code_to_statement, gfc_resolve_omp_directive): Likewise.
1891 * parse.c (decode_omp_directive, case_exec_markers,
1892 gfc_ascii_statement, parse_omp_structured_block,
1893 parse_executable): Likewise.
1894 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
1895 * st.c (gfc_free_statement): Likewise.
1896 * trans-openmp.c (gfc_trans_omp_parallel_master,
1897 gfc_trans_omp_workshare, gfc_trans_omp_directive): Likewise.
1898 * trans.c (trans_code): Likewise.
1900 2021-05-14 Tobias Burnus <tobias@codesourcery.com>
1902 * resolve.c (resolve_symbol): Handle implicit SAVE of main-program
1903 for vars in 'omp threadprivate' and 'omp declare target'.
1905 2021-05-10 Martin Liska <mliska@suse.cz>
1907 * decl.c (variable_decl): Use startswith
1908 function instead of strncmp.
1909 (gfc_match_end): Likewise.
1910 * gfortran.h (gfc_str_startswith): Likewise.
1911 * module.c (load_omp_udrs): Likewise.
1912 (read_module): Likewise.
1913 * options.c (gfc_handle_runtime_check_option): Likewise.
1914 * primary.c (match_arg_list_function): Likewise.
1915 * trans-decl.c (gfc_get_symbol_decl): Likewise.
1916 * trans-expr.c (gfc_conv_procedure_call): Likewise.
1917 * trans-intrinsic.c (gfc_conv_ieee_arithmetic_function): Likewise.
1919 2021-05-06 Paul Thomas <pault@gcc.gnu.org>
1923 * class.c (gfc_build_class_symbol): Remove the error that
1924 disables assumed size class arrays. Class array types that are
1925 not deferred shape or assumed rank are given a unique name and
1926 placed in the procedure namespace.
1927 * trans-array.c (gfc_trans_g77_array): Obtain the data pointer
1929 (gfc_trans_dummy_array_bias): Suppress the runtime error for
1930 extent violations in explicit shape class arrays because it
1932 * trans-expr.c (gfc_conv_procedure_call): Handle assumed size
1933 class actual arguments passed to non-descriptor formal args by
1934 using the data pointer, stored as the symbol's backend decl.
1936 2021-05-05 Harald Anlauf <anlauf@gmx.de>
1939 * interface.c (gfc_compare_actual_formal): Continue checks after
1940 emitting warning for argument length mismatch.
1941 * trans-expr.c (gfc_conv_procedure_call): Check for NULL pointer
1944 2021-05-04 Tobias Burnus <tobias@codesourcery.com>
1947 * trans-openmp.c (gfc_trans_omp_depobj): Fix pasto in enum values.
1949 2021-04-28 Tobias Burnus <tobias@codesourcery.com>
1951 * openmp.c (gfc_match_omp_variable_list): Gobble whitespace before
1952 checking whether a '%' or parenthesis-open follows as next character.
1954 2021-04-28 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1957 * trans-expr.c (gfc_conv_procedure_call): Evaluate function result
1958 and then pass a pointer.
1960 2021-04-26 Thomas Schwinge <thomas@codesourcery.com>
1961 Nathan Sidwell <nathan@codesourcery.com>
1962 Tom de Vries <vries@codesourcery.com>
1963 Julian Brown <julian@codesourcery.com>
1964 Kwok Cheung Yeung <kcy@codesourcery.com>
1966 * lang.opt (Wopenacc-parallelism): New.
1968 2021-04-24 Harald Anlauf <anlauf@gmx.de>
1971 * check.c (variable_check): Allow function reference having a data
1973 (arg_strlen_is_zero): New function.
1974 (gfc_check_fgetputc_sub): Add static check of character and status
1976 (gfc_check_fgetput_sub): Likewise.
1977 * intrinsic.c (add_subroutines): Fix argument name for the
1978 character argument to intrinsic subroutines fget[c], fput[c].
1980 2021-04-24 Harald Anlauf <anlauf@gmx.de>
1983 * expr.c (gfc_check_vardef_context): Extend check to allow pointer
1984 from a function reference.
1986 2021-04-22 Martin Liska <mliska@suse.cz>
1990 * frontend-passes.c (optimize_expr): Fix typos and missing comments.
1992 2021-04-22 Michael Meissner <meissner@linux.ibm.com>
1995 * trans-intrinsic.c (build_round_expr): If int type is larger than
1996 long long, do the round and convert to the integer type. Do not
1997 try to find a floating point type the exact size of the integer
2000 2021-04-21 Tobias Burnus <tobias@codesourcery.com>
2002 * dump-parse-tree.c (show_omp_namelist): Handle depobj + mutexinoutset
2003 in the depend clause.
2004 (show_omp_clauses, show_omp_node, show_code_node): Handle depobj.
2005 * gfortran.h (enum gfc_statement): Add ST_OMP_DEPOBJ.
2006 (enum gfc_omp_depend_op): Add OMP_DEPEND_UNSET,
2007 OMP_DEPEND_MUTEXINOUTSET and OMP_DEPEND_DEPOBJ.
2008 (gfc_omp_clauses): Add destroy, depobj_update and depobj.
2009 (enum gfc_exec_op): Add EXEC_OMP_DEPOBJ
2010 * match.h (gfc_match_omp_depobj): Match 'omp depobj'.
2011 * openmp.c (gfc_match_omp_clauses): Add depobj + mutexinoutset
2013 (gfc_match_omp_depobj, resolve_omp_clauses, gfc_resolve_omp_directive):
2014 Handle 'omp depobj'.
2015 * parse.c (decode_omp_directive, next_statement, gfc_ascii_statement):
2017 * resolve.c (gfc_resolve_code): Likewise.
2018 * st.c (gfc_free_statement): Likewise.
2019 * trans-openmp.c (gfc_trans_omp_clauses): Handle depobj + mutexinoutset
2020 in the depend clause.
2021 (gfc_trans_omp_depobj, gfc_trans_omp_directive): Handle EXEC_OMP_DEPOBJ.
2022 * trans.c (trans_code): Likewise.
2024 2021-04-20 Paul Thomas <pault@gcc.gnu.org>
2027 * trans-decl.c (gfc_get_symbol_decl): Replace test for host
2028 association with a check that the current and symbol namespaces
2031 2021-04-19 Thomas Schwinge <thomas@codesourcery.com>
2033 * lang.opt (fopenacc-kernels=): Remove.
2035 2021-04-16 José Rui Faustino de Sousa <jrfsousa@gmail.com>
2038 * trans-array.c (gfc_trans_deferred_array): Add code to initialize
2039 pointers and allocatables with correct TKR parameters.
2041 2021-04-16 José Rui Faustino de Sousa <jrfsousa@gmail.com>
2044 * resolve.c: Add association check before de-referencing pointer.
2046 2021-04-16 Harald Anlauf <anlauf@gmx.de>
2047 Paul Thomas <pault@gcc.gnu.org>
2050 * module.c (write_symtree): Do not write interface of intrinsic
2051 procedure to module file for F2003 and newer.
2053 2021-04-15 Paul Thomas <pault@gcc.gnu.org>
2056 * symbol.c: Remove trailing white space.
2057 * trans-array.c (gfc_trans_create_temp_array): Create a class
2058 temporary for class expressions and assign the new descriptor
2060 (build_class_array_ref): If the class expr can be extracted,
2061 then use that for 'decl'. Class function results are reliably
2062 handled this way. Call gfc_find_and_cut_at_last_class_ref to
2063 eliminate largely redundant code. Remove dead code and recast
2064 the rest of the code to extract 'decl' for remaining cases.
2065 Call gfc_build_spanned_array_ref.
2066 (gfc_alloc_allocatable_for_assignment): Use class descriptor
2067 element length for 'elemsize1'. Eliminate repeat set of dtype
2068 for class expressions.
2069 * trans-expr.c (gfc_find_and_cut_at_last_class_ref): Include
2070 additional code from build_class_array_ref, and use optional
2071 gfc_typespec pointer argument.
2072 (gfc_trans_scalar_assign): Make use of pre and post blocks for
2073 all class expressions.
2074 * trans.c (get_array_span): For unlimited polymorphic exprs
2075 multiply the span by the value of the _len field.
2076 (gfc_build_spanned_array_ref): New function.
2077 (gfc_build_array_ref): Call gfc_build_spanned_array_ref and
2078 eliminate repeated code.
2079 * trans.h: Add arg to gfc_find_and_cut_at_last_class_ref and
2080 add prototype for gfc_build_spanned_array_ref.
2082 2021-04-14 Martin Liska <mliska@suse.cz>
2084 * intrinsic.texi: The table has first column empty and it makes
2085 trouble when processing makeinfo --xml output.
2087 2021-04-09 Tobias Burnus <tobias@codesourcery.com>
2090 * trans-types.c (gfc_get_function_type): Also generate hidden
2091 coarray argument for character arguments.
2093 2021-04-03 Paul Thomas <pault@gcc.gnu.org>
2096 * interface.c (compare_parameter): The codimension attribute is
2097 applied to the _data field of class formal arguments.
2099 2021-04-01 Harald Anlauf <anlauf@gmx.de>
2102 * simplify.c (gfc_simplify_transpose): Properly initialize
2105 2021-03-28 Paul Thomas <pault@gcc.gnu.org>
2108 * trans-expr.c (gfc_conv_procedure_call): Use the _data attrs
2109 for class expressions and detect proc pointer evaluations by
2110 the non-null actual argument list.
2112 2021-03-27 Steve Kargl <kargl@gcc.gnu.org>
2114 * misc.c (gfc_typename): Fix off-by-one in buffer sizes.
2116 2021-03-26 Tobias Burnus <tobias@codesourcery.com>
2119 * intrinsic.c (gfc_intrinsic_func_interface): Set
2120 attr.proc = PROC_INTRINSIC if FL_PROCEDURE.
2122 2021-03-24 Tobias Burnus <tobias@codesourcery.com>
2125 * resolve.c (resolve_operator): Make 'msg' buffer larger
2128 2021-03-23 Tobias Burnus <tobias@codesourcery.com>
2131 * trans-decl.c (build_function_decl): Add comment;
2132 increment hidden_typelist for caf_token/caf_offset.
2133 * trans-types.c (gfc_get_function_type): Add comment;
2134 add missing caf_token/caf_offset args.
2136 2021-03-22 Tobias Burnus <tobias@codesourcery.com>
2139 * match.c (select_type_set_tmp, gfc_match_select_type,
2140 gfc_match_select_rank): Fix 'name' buffersize to avoid out of bounds.
2141 * resolve.c (resolve_select_type): Likewise.
2143 2021-03-19 Thomas Koenig <tkoenig@gcc.gnu.org>
2145 * frontend-passes.c (inline_limit_check): Add rank_a
2146 argument. If a is rank 1, set the second dimension to 1.
2147 (inline_matmul_assign): Pass rank_a argument to inline_limit_check.
2148 (call_external_blas): Likewise.
2150 2021-03-15 Thomas Koenig <tkoenig@gcc.gnu.org>
2153 * frontend-passes.c (doloop_contained_procedure_code):
2154 Properly handle EXEC_IOLENGTH.
2156 2021-03-15 Paul Thomas <pault@gcc.gnu.org>
2159 * trans-stmt.c (gfc_trans_allocate): Mark the initialization
2160 assignment by setting init_flag.
2162 2021-03-14 Harald Anlauf <anlauf@gmx.de>
2163 Paul Thomas <pault@gcc.gnu.org>
2165 * trans-expr.c (gfc_conv_procedure_call): Fix runtime checks for
2167 * trans-intrinsic.c (gfc_conv_intrinsic_size): Likewise.
2169 2021-03-13 Paul Thomas <pault@gcc.gnu.org>
2172 * trans-array.c (gfc_conv_expr_descriptor): For deferred length
2173 length components use the ss_info string length instead of
2174 gfc_get_expr_charlen. Make sure that the deferred string length
2175 is a variable before assigning to it. Otherwise use the expr.
2176 * trans-expr.c (gfc_conv_string_length): Make sure that the
2177 deferred string length is a variable before assigning to it.
2179 2021-03-12 Tobias Burnus <tobias@codesourcery.com>
2182 * resolve.c (resolve_symbol): Accept vars which are in DATA
2183 and hence (either) implicit SAVE (or in common).
2185 2021-03-10 Harald Anlauf <anlauf@gmx.de>
2188 * data.c (gfc_assign_data_value): Reject non-constant character
2190 * trans-array.c (gfc_conv_array_initializer): Restrict loop to
2191 elements which are defined to avoid NULL pointer dereference.
2193 2021-03-10 Tobias Burnus <tobias@codesourcery.com>
2195 * intrinsic.texi (MIN): Correct 'maximum' to 'minimum'.
2197 2021-03-10 Eric Botcazou <ebotcazou@adacore.com>
2200 * trans-intrinsic.c (build_round_expr): Do not implicitly assume
2201 that __float128 is the 128-bit floating-point type.
2203 2021-03-08 Harald Anlauf <anlauf@gmx.de>
2206 * data.c (gfc_assign_data_value): Reject variable with PARAMETER
2207 attribute in DATA statement.
2209 2021-03-05 Tobias Burnus <tobias@codesourcery.com>
2213 * invoke.texi (-freal{4,8}-real-*): Extend description.
2214 * primary.c (match_real_constant): Also promote real literals
2215 with '_kind' number.
2217 2021-03-04 Tobias Burnus <tobias@codesourcery.com>
2220 * decl.c (gfc_match_old_kind_spec, gfc_match_kind_spec): Avoid
2221 redoing kind conversions.
2222 * primary.c (match_real_constant): Likewise.
2224 2021-02-28 Jakub Jelinek <jakub@redhat.com>
2227 * openmp.c (gfc_omp_requires_add_clause): Fix up diagnostic message
2229 (resolve_omp_clauses): Likewise.
2231 2021-02-28 Jakub Jelinek <jakub@redhat.com>
2234 * frontend-passes.c (doloop_code): Replace double space in diagnostics
2235 with a single space.
2237 2021-02-24 Paul Thomas <pault@gcc.gnu.org>
2240 * trans-expr.c (gfc_conv_derived_to_class): Add optional arg.
2241 'derived_array' to hold the fixed, parmse expr in the case of
2242 assumed rank formal arguments. Deal with optional arguments.
2243 (gfc_conv_procedure_call): Null 'derived' array for each actual
2244 argument. Add its address to the call to gfc_conv_derived_to_
2245 class. Access the 'data' field of scalar descriptors before
2246 deallocating allocatable components. Also strip NOPs before the
2247 calls to gfc_deallocate_alloc_comp. Use 'derived' array as the
2248 input to gfc_deallocate_alloc_comp if it is available.
2249 * trans.h : Include the optional argument 'derived_array' to
2250 the prototype of gfc_conv_derived_to_class. The default value
2253 2021-02-23 Paul Thomas <pault@gcc.gnu.org>
2256 * resolve.c (resolve_fl_procedure): Include class results in
2257 the test for F2018, C15100.
2258 * trans-array.c (get_class_info_from_ss): Do not use the saved
2259 descriptor to obtain the class expression for variables. Use
2260 gfc_get_class_from_expr instead.
2262 2021-02-23 Harald Anlauf <anlauf@gmx.de>
2265 * simplify.c (gfc_simplify_reshape): Set string length for
2266 character arguments.
2268 2021-02-22 Tobias Burnus <tobias@codesourcery.com>
2271 * trans-openmp.c (gfc_omp_is_optional_argument): Regard optional
2272 dummy procs as nonoptional as no special treatment is needed.
2274 2021-02-21 Harald Anlauf <anlauf@gmx.de>
2276 * trans-expr.c (gfc_conv_procedure_call): Do not add clobber to
2277 allocatable intent(out) argument.
2279 2021-02-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2282 * match.c (gfc_match_namelist): If BT_UNKNOWN, check for
2283 IMPLICIT NONE and and issue an error, otherwise set the type
2284 to its IMPLICIT type so that any subsequent use of objects will
2285 will confirm their types.
2287 2021-02-19 Harald Anlauf <anlauf@gmx.de>
2289 * symbol.c (gfc_add_flavor): Reverse order of conditions.
2291 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
2294 * dependency.c (gfc_dep_resolver): Fix coarray handling.
2296 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
2301 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
2304 * simplify.c (simplify_bound_dim): Honor DIMEN_ELEMENT
2307 2021-02-17 Julian Brown <julian@codesourcery.com>
2309 * openmp.c (resolve_omp_clauses): Disallow selecting components
2310 of arrays of derived type.
2312 2021-02-17 Julian Brown <julian@codesourcery.com>
2314 * trans-openmp.c (gfc_trans_omp_clauses): Handle element selection
2315 for arrays of derived types.
2317 2021-02-16 Tobias Burnus <tobias@codesourcery.com>
2319 * expr.c (gfc_is_simplify_contiguous): Handle REF_INQUIRY, i.e.
2320 %im and %re which are EXPR_VARIABLE.
2321 * openmp.c (resolve_omp_clauses): Diagnose %re/%im explicitly.
2323 2021-02-16 Tobias Burnus <tobias@codesourcery.com>
2326 * io.c (resolve_tag_format): Reject BT_DERIVED/CLASS/VOID
2327 as (array-valued) FORMAT tag.
2329 2021-02-12 Tobias Burnus <tobias@codesourcery.com>
2332 * trans-expr.c (gfc_conv_procedure_call): Don't reset
2333 rank of assumed-rank array.
2335 2021-02-11 Paul Thomas <pault@gcc.gnu.org>
2338 * match.c (gfc_match_call): Include associate names as possible
2339 entities with typebound subroutines. The target needs to be
2340 resolved for the type.
2342 2021-02-11 Paul Thomas <pault@gcc.gnu.org>
2345 * primary.c (gfc_match_varspec): Test for non-null 'previous'
2346 before using its name in the error message.
2348 2021-02-11 Tobias Burnus <tobias@codesourcery.com>
2350 * intrinsic.texi (FINDLOC): Add 'MASK' to argument table.
2351 (MAXLOC, MAXVAL, MINLOC, MINVAL): For 'MASK', remove 'an
2352 array' as scalars are also permitted.
2354 2021-02-10 Julian Brown <julian@codesourcery.com>
2357 * openmp.c (resolve_omp_clauses): Omit OpenACC update in
2358 contiguity check and stride-specified error.
2360 2021-02-04 Julian Brown <julian@codesourcery.com>
2362 * openmp.c (resolve_omp_clauses): Omit OpenACC update in
2363 contiguity check and stride-specified error.
2365 2021-02-04 Julian Brown <julian@codesourcery.com>
2367 * trans-openmp.c (gfc_trans_omp_clauses): Use class_pointer attribute
2370 2021-02-04 Julian Brown <julian@codesourcery.com>
2372 * trans-openmp.c (gfc_trans_omp_clauses): Fix dereferencing for
2375 2021-02-04 Tobias Burnus <tobias@codesourcery.com>
2377 * openmp.c (resolve_omp_clauses): Explicitly diagnose
2378 substrings as not permitted.
2380 2021-02-03 Jeff Law <law@redhat.com>
2382 * intrinsic.texi (ANINT): Fix typo.
2384 2021-02-03 Tobias Burnus <tobias@codesourcery.com>
2387 * dependency.c (gfc_dep_resolver): Treat local access
2388 to coarrays like any array access in dependency analysis.
2390 2021-01-28 Harald Anlauf <anlauf@gmx.de>
2393 * trans.c (gfc_call_malloc): Allocate area of size 1 if passed
2394 size is NULL (as documented).
2396 2021-01-27 Paul Thomas <pault@gcc.gnu.org>
2400 * trans-expr.c (gfc_conv_procedure_call): Suppress the call to
2401 gfc_conv_intrinsic_to_class for unlimited polymorphic procedure
2403 (gfc_trans_assignment_1): Similarly suppress class assignment
2404 for class valued procedure pointers.
2406 2021-01-27 Paul Thomas <pault@gcc.gnu.org>
2409 * trans-array.c (gfc_conv_expr_descriptor): Include elemental
2410 procedure pointers in the assert under the comment 'elemental
2411 function' and eliminate the second, spurious assert.
2413 2021-01-25 Harald Anlauf <anlauf@gmx.de>
2416 * data.c (create_character_initializer): Check substring indices
2418 (gfc_assign_data_value): Catch error returned from
2419 create_character_initializer.
2421 2021-01-25 Tobias Burnus <tobias@codesourcery.com>
2423 * intrinsic.texi (CO_BROADCAST, CO_MIN, CO_REDUCE, CO_SUM): Fix typos.
2425 2021-01-25 Steve Kargl <kargl@gcc.gnu.org>
2428 * resolve.c (resolve_charlen): Check that length expression is
2429 present before testing for scalar/integer..
2431 2021-01-22 Paul Thomas <pault@gcc.gnu.org>
2434 * trans-intrinsic.c (gfc_conv_associated): Do not add a _data
2435 component for scalar class function targets. Instead, fix the
2436 function result and access the _data from that.
2438 2021-01-21 Jorge D'Elia <jdelia@cimec.unl.edu.ar>
2440 * intrinsic.texi (CO_MAX): Fix typo.
2442 2021-01-21 Paul Thomas <pault@gcc.gnu.org>
2445 * decl.c (gfc_match_modproc): It is not an error to find a
2446 module procedure declaration within a contains block.
2447 * expr.c (gfc_check_vardef_context): Pure procedure result is
2448 assignable. Change 'own_scope' accordingly.
2449 * resolve.c (resolve_typebound_procedure): A procedure that
2450 has the module procedure attribute is almost certainly a
2451 module procedure, whatever its interface.
2453 2021-01-19 Tobias Burnus <tobias@codesourcery.com>
2456 * openmp.c (resolve_omp_clauses): Change use_device_ptr
2457 to use_device_addr for unless type(c_ptr); check all
2458 list item for is_device_ptr.
2460 2021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
2462 * dump-parse-tree.c (show_omp_clauses): Handle detach clause.
2463 * frontend-passes.c (gfc_code_walker): Walk detach expression.
2464 * gfortran.h (struct gfc_omp_clauses): Add detach field.
2465 (gfc_c_intptr_kind): New.
2466 * openmp.c (gfc_free_omp_clauses): Free detach clause.
2467 (gfc_match_omp_detach): New.
2468 (enum omp_mask1): Add OMP_CLAUSE_DETACH.
2469 (enum omp_mask2): Remove OMP_CLAUSE_DETACH.
2470 (gfc_match_omp_clauses): Handle OMP_CLAUSE_DETACH for OpenMP.
2471 (OMP_TASK_CLAUSES): Add OMP_CLAUSE_DETACH.
2472 (resolve_omp_clauses): Prevent use of detach with mergeable and
2473 overriding the data sharing mode of the event handle.
2474 * trans-openmp.c (gfc_trans_omp_clauses): Handle detach clause.
2475 * trans-types.c (gfc_c_intptr_kind): New.
2476 (gfc_init_kinds): Initialize gfc_c_intptr_kind.
2478 (BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT): Rename
2480 (BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT_PTR):
2481 ...this. Add extra argument.
2483 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2485 * gfortran.h (gfc_resolve_substring): Add prototype.
2486 * primary.c (match_string_constant): Simplify substrings with
2487 constant starting and ending points.
2488 * resolve.c: Rename resolve_substring to gfc_resolve_substring.
2489 (gfc_resolve_ref): Use renamed function gfc_resolve_substring.
2491 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2494 * resolve.c (resolve_component): Derived type components with
2495 ALLOCATABLE or POINTER attribute shall have a deferred shape.
2497 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2500 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2503 * resolve.c (resolve_component): Derived type components with
2504 ALLOCATABLE or POINTER attribute shall have a deferred shape.
2506 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2509 * resolve.c (resolve_component): Derived type components with
2510 ALLOCATABLE or POINTER attribute shall have a deferred shape.
2512 2021-01-08 Paul Thomas <pault@gcc.gnu.org>
2515 * trans-expr.c (gfc_conv_component_ref): Remove the condition
2516 that deferred character length components only be allocatable.
2518 2021-01-08 Paul Thomas <pault@gcc.gnu.org>
2521 * simplify.c (is_constant_array_expr): If an array constructor
2522 expression has elements other than constants or structures, try
2523 fixing the expression with gfc_reduce_init_expr. Also, if shape
2524 is NULL, obtain the array size and set it.
2526 2021-01-07 Paul Thomas <pault@gcc.gnu.org>
2529 * resolve.c (find_array_spec): Put static prototype for
2530 resolve_assoc_var before this function and call for associate
2533 2021-01-06 Harald Anlauf <anlauf@gmx.de>
2535 * resolve.c (resolve_component): Add check for valid CLASS
2536 reference before trying to access CLASS data.
2538 2021-01-04 Martin Liska <mliska@suse.cz>
2540 * ChangeLog-2018: Remove duplicate ChangeLog entries.
2542 2021-01-01 Harald Anlauf <anlauf@gmx.de>
2544 * class.c (gfc_find_vtab): Add check on attribute is_class.
2546 2021-01-01 Jakub Jelinek <jakub@redhat.com>
2548 * gfortranspec.c (lang_specific_driver): Update copyright notice
2550 * gfc-internals.texi: Bump @copying's copyright year.
2551 * gfortran.texi: Ditto.
2552 * intrinsic.texi: Ditto.
2553 * invoke.texi: Ditto.
2555 2021-01-01 Jakub Jelinek <jakub@redhat.com>
2557 * ChangeLog-2020: Rotate ChangeLog. New file.
2559 Copyright (C) 2021 Free Software Foundation, Inc.
2561 Copying and distribution of this file, with or without modification,
2562 are permitted in any medium without royalty provided the copyright
2563 notice and this notice are preserved.