1 2021-12-07 Harald Anlauf <anlauf@gmx.de>
4 * frontend-passes.c (do_subscript): Ensure that array bounds are
5 of type INTEGER before performing checks on array subscripts.
7 2021-12-07 Harald Anlauf <anlauf@gmx.de>
10 * array.c (gfc_ref_dimen_size): Do not generate internal error on
11 failed simplification of stride expression; just return failure.
13 2021-12-07 Harald Anlauf <anlauf@gmx.de>
16 * match.c (match_case_selector): Check type of upper bound in case
19 2021-12-04 Tobias Burnus <tobias@codesourcery.com>
21 * dump-parse-tree.c (show_omp_clauses): Handle
22 weak/compare/fail clause.
23 * gfortran.h (gfc_omp_clauses): Add weak, compare, fail.
24 * openmp.c (enum omp_mask1, gfc_match_omp_clauses,
25 OMP_ATOMIC_CLAUSES): Update for new clauses.
26 (gfc_match_omp_atomic): Update for 5.1 atomic changes.
27 (is_conversion): Support widening in one go.
28 (is_scalar_intrinsic_expr): New.
29 (resolve_omp_atomic): Update for 5.1 atomic changes.
30 * parse.c (parse_omp_oacc_atomic): Update for compare.
31 * resolve.c (gfc_resolve_blocks): Update asserts.
32 * trans-openmp.c (gfc_trans_omp_atomic): Handle new clauses.
34 2021-12-03 Harald Anlauf <anlauf@gmx.de>
35 Steven G. Kargl <kargl@gcc.gnu.org>
38 * array.c (match_array_element_spec): Try to simplify array
39 element specifications to improve early checking.
40 * expr.c (gfc_try_simplify_expr): New. Try simplification of an
41 expression via gfc_simplify_expr. When an error occurs, roll
43 * gfortran.h (gfc_try_simplify_expr): Declare it.
45 2021-12-03 Tobias Burnus <tobias@codesourcery.com>
47 * trans-stmt.c (gfc_trans_allocate): Set e3_has_nodescriptor to true
48 only for non-named arrays.
50 2021-12-02 Chung-Lin Tang <cltang@codesourcery.com>
53 * trans-openmp.c (gfc_omp_finish_clause): Remove fold_convert to pointer
54 to char_type_node, add gcc_assert of POINTER_TYPE_P.
55 (gfc_trans_omp_array_section): Likewise.
56 (gfc_trans_omp_clauses): Likewise.
58 2021-11-30 Harald Anlauf <anlauf@gmx.de>
61 * array.c (expand_constructor): When encountering a constant array
62 expression or array section within a constructor, simplify it to
63 enable better expansion.
65 2021-11-30 Harald Anlauf <anlauf@gmx.de>
68 * simplify.c (simplify_minmaxloc_nodim): Avoid NULL pointer
69 dereference when shape is not set.
71 2021-11-30 Harald Anlauf <anlauf@gmx.de>
72 Steven G. Kargl <kargl@gcc.gnu.org>
75 * check.c (gfc_check_image_index): Verify that SUB argument to
76 IMAGE_INDEX is of type integer.
78 2021-11-30 Richard Biener <rguenther@suse.de>
80 * frontend-passes.c (gfc_expr_walker): Add comment to
81 indicate tail recursion.
83 2021-11-30 Richard Biener <rguenther@suse.de>
85 * target-memory.c (gfc_element_size): Remove unreachable return.
87 2021-11-30 Thomas Schwinge <thomas@codesourcery.com>
89 * openmp.c (resolve_oacc_loop_blocks): Remove "gang reduction on
90 an orphan loop" checking.
91 (oacc_is_parallel, oacc_is_kernels, oacc_is_serial)
92 (oacc_is_compute_construct): Remove.
94 2021-11-30 Frederik Harwath <frederik@codesourcery.com>
95 Thomas Schwinge <thomas@codesourcery.com>
97 * openmp.c (oacc_is_parallel_or_serial): Evolve into...
98 (oacc_is_compute_construct): ... this function.
99 (resolve_oacc_loop_blocks): Use "oacc_is_compute_construct"
100 instead of "oacc_is_parallel_or_serial" for checking that a
101 loop is not orphaned.
103 2021-11-30 Kwok Cheung Yeung <kcy@codesourcery.com>
104 Thomas Schwinge <thomas@codesourcery.com>
106 * openmp.c (oacc_is_serial, oacc_is_parallel_or_serial): New.
107 (resolve_oacc_loop_blocks): Use oacc_is_parallel_or_serial instead of
110 2021-11-30 Cesar Philippidis <cesar@codesourcery.com>
111 Thomas Schwinge <thomas@codesourcery.com>
113 * openmp.c (oacc_is_parallel, oacc_is_kernels): New 'static'
115 (resolve_oacc_loop_blocks): Emit an error on orphan OpenACC gang
118 2021-11-30 Richard Biener <rguenther@suse.de>
120 * decl.c (gfc_insert_parameter_exprs): Only return after
121 resetting type_param_spec_list.
123 2021-11-30 Richard Biener <rguenther@suse.de>
125 * frontend-passes.c (gfc_expr_walker): Remove unreachable
127 * scanner.c (skip_fixed_comments): Remove unreachable
129 * trans-expr.c (gfc_expr_is_variable): Refactor to make
130 control flow more obvious.
132 2021-11-29 Eric Gallager <egallager@gcc.gnu.org>
135 * Make-lang.in: Use ETAGS variable in TAGS target.
137 2021-11-26 Harald Anlauf <anlauf@gmx.de>
140 * check.c (gfc_check_reshape): Improve check of size of source
141 array for the RESHAPE intrinsic against the given shape when pad
142 is not given, and shape is a parameter. Try other simplifications
145 2021-11-23 Harald Anlauf <anlauf@gmx.de>
148 * simplify.c (simplify_bound): Do not try to simplify
149 LBOUND/UBOUND for arrays with POINTER or ALLOCATABLE attribute.
151 2021-11-23 Harald Anlauf <anlauf@gmx.de>
155 * trans-array.c (arg_evaluated_for_scalarization): Add LEN_TRIM to
156 list of intrinsics for which an optional KIND argument needs to be
157 removed before scalarization.
159 2021-11-21 Jakub Jelinek <jakub@redhat.com>
162 * trans-types.c (gfc_get_array_descr_info): Use DW_OP_deref_size 1
163 instead of DW_OP_deref for DW_AT_rank.
165 2021-11-21 Harald Anlauf <anlauf@gmx.de>
166 Steven G. Kargl <kargl@gcc.gnu.org>
169 * trans-intrinsic.c (gfc_lookup_intrinsic): Helper function for
170 looking up gfortran builtin intrinsics.
171 (gfc_conv_intrinsic_atrigd): Use it.
172 (gfc_conv_intrinsic_cotan): Likewise.
173 (gfc_conv_intrinsic_cotand): Likewise.
174 (gfc_conv_intrinsic_atan2d): Likewise.
176 2021-11-18 Harald Anlauf <anlauf@gmx.de>
177 Steven G. Kargl <kargl@gcc.gnu.org>
180 * check.c (is_c_interoperable): Reject NULL() as it is not
183 2021-11-16 Harald Anlauf <anlauf@gmx.de>
186 * resolve.c (resolve_select): Choose appropriate range limit to
187 avoid NULL pointer dereference when generating error message.
189 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
191 * interface.c (gfc_dummy_arg_get_name): New function.
192 * gfortran.h (gfc_dummy_arg_get_name): Declare it.
193 * trans-array.c (arg_evaluated_for_scalarization): Pass a dummy
194 argument wrapper as argument instead of an actual argument
195 and an index number. Check it’s non-NULL. Use its name
197 (gfc_walk_elemental_function_args): Update call to
198 arg_evaluated for scalarization. Remove argument counting.
200 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
202 * gfortran.h (gfc_actual_arglist::missing_arg_type): Remove.
203 * interface.c (gfc_compare_actual_formal): Remove
204 missing_arg_type initialization.
205 * intrinsic.c (sort_actual): Ditto.
206 * trans-expr.c (gfc_conv_procedure_call): Use associated_dummy
207 and gfc_dummy_arg_get_typespec to get the dummy argument type.
209 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
211 * interface.c (gfc_dummy_arg_get_typespec,
212 gfc_dummy_arg_is_optional): New functions.
213 * gfortran.h (gfc_dummy_arg_get_typespec,
214 gfc_dummy_arg_is_optional): Declare them.
215 * trans.h (gfc_ss_info::dummy_arg): Use the wrapper type
217 * trans-array.c (gfc_scalar_elemental_arg_saved_as_reference):
218 use gfc_dummy_arg_get_typespec function to get the type.
219 (gfc_walk_elemental_function_args): Remove proc_ifc argument.
220 Get info about the dummy arg using the associated_dummy field.
221 * trans-array.h (gfc_walk_elemental_function_args): Update declaration.
222 * trans-intrinsic.c (gfc_walk_intrinsic_function):
223 Update call to gfc_walk_elemental_function_args.
224 * trans-stmt.c (gfc_trans_call): Ditto.
225 (get_proc_ifc_for_call): Remove.
227 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
229 * gfortran.h (gfc_dummy_arg_kind, gfc_dummy_arg): New.
230 (gfc_actual_arglist): New field associated_dummy.
231 (gfc_intrinsic_arg): Remove field actual.
232 * interface.c (get_nonintrinsic_dummy_arg): New.
233 (gfc_compare_actual): Initialize associated_dummy.
234 * intrinsic.c (get_intrinsic_dummy_arg): New.
235 (sort_actual): Add argument vectors.
236 Use loops with indices on argument vectors.
237 Initialize associated_dummy.
239 2021-11-16 Mikael Morin <mikael@gcc.gnu.org>
241 * intrinsic.c (sort_actual): initialise variable and use it earlier.
243 2021-11-15 Tobias Burnus <tobias@codesourcery.com>
245 * openmp.c (OMP_TARGET_CLAUSES): Add thread_limit.
246 * trans-openmp.c (gfc_split_omp_clauses): Add thread_limit also to
249 2021-11-12 Tobias Burnus <tobias@codesourcery.com>
251 * parse.c (decode_omp_directive): Fix permitting 'nowait' for some
252 combined directives, add missing 'omp end ... loop'.
253 (gfc_ascii_statement): Fix ST_OMP_END_TEAMS_LOOP result.
254 * openmp.c (resolve_omp_clauses): Add missing combined loop constructs
255 case values to the 'if(directive-name: ...)' check.
256 * trans-openmp.c (gfc_split_omp_clauses): Put nowait on target if
257 first leaf construct accepting it.
259 2021-11-12 Martin Jambor <mjambor@suse.cz>
261 * trans-types.c (gfc_get_array_descr_info): Use build_debug_expr_decl
262 instead of building DEBUG_EXPR_DECL manually.
264 2021-11-12 Mikael Morin <mikael@gcc.gnu.org>
267 * intrinsic.c (add_sym_4ind): Remove.
268 (add_functions): Use add_sym4 instead of add_sym4ind.
269 Don’t special case the index intrinsic.
270 * iresolve.c (gfc_resolve_index_func): Use the individual arguments
271 directly instead of the full argument list.
272 * intrinsic.h (gfc_resolve_index_func): Update the declaration
274 * trans-decl.c (gfc_get_extern_function_decl): Don’t modify the
275 list of arguments in the case of the index intrinsic.
276 * trans-array.h (gfc_get_intrinsic_for_expr,
277 gfc_get_proc_ifc_for_expr): New.
278 * trans-array.c (gfc_get_intrinsic_for_expr,
279 arg_evaluated_for_scalarization): New.
280 (gfc_walk_elemental_function_args): Add intrinsic procedure
281 as argument. Count arguments. Check arg_evaluated_for_scalarization.
282 * trans-intrinsic.c (gfc_walk_intrinsic_function): Update call.
283 * trans-stmt.c (get_intrinsic_for_code): New.
284 (gfc_trans_call): Update call.
286 2021-11-12 Jakub Jelinek <jakub@redhat.com>
288 * types.def (BT_FN_VOID_UINT_UINT): Remove.
289 (BT_FN_BOOL_UINT_UINT_UINT_BOOL): New.
291 2021-11-11 Tobias Burnus <tobias@codesourcery.com>
293 * gfortran.h (struct gfc_omp_clauses): Rename num_teams to
294 num_teams_upper, add num_teams_upper.
295 * dump-parse-tree.c (show_omp_clauses): Update to handle
296 lower-bound num_teams clause.
297 * frontend-passes.c (gfc_code_walker): Likewise
298 * openmp.c (gfc_free_omp_clauses, gfc_match_omp_clauses,
299 resolve_omp_clauses): Likewise.
300 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses,
301 gfc_trans_omp_target): Likewise.
303 2021-11-11 Jakub Jelinek <jakub@redhat.com>
305 * trans-openmp.c (gfc_trans_omp_clauses): Use
306 OMP_CLAUSE_NUM_TEAMS_UPPER_EXPR instead of OMP_CLAUSE_NUM_TEAMS_EXPR.
308 2021-11-10 Harald Anlauf <anlauf@gmx.de>
312 * check.c (gfc_check_shape): Avoid NULL pointer dereference on
314 * simplify.c (gfc_simplify_cshift): Avoid NULL pointer dereference
316 (gfc_simplify_transpose): Likewise.
318 2021-11-09 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
321 * class.c (generate_finalization_wrapper): Do not leak
322 finalization wrappers if they will not be used.
323 * expr.c (gfc_free_actual_arglist): Formatting fix.
324 * gfortran.h (gfc_free_symbol): Pass argument by reference.
325 (gfc_release_symbol): Likewise.
326 (gfc_free_namespace): Likewise.
327 * symbol.c (gfc_release_symbol): Adjust acordingly.
328 (free_components): Set procedure pointer components
329 of derived types to NULL after freeing.
330 (free_tb_tree): Likewise.
331 (gfc_free_symbol): Set sym to NULL after freeing.
332 (gfc_free_namespace): Set namespace to NULL after freeing.
334 2021-11-09 Martin Liska <mliska@suse.cz>
336 * symbol.c (gfc_get_ultimate_derived_super_type): Remove.
338 2021-11-09 Aldy Hernandez <aldyh@redhat.com>
340 * misc.c (gfc_dummy_typename): Make sure ts->kind is
343 2021-11-07 Thomas Koenig <tkoenig@gcc.gnu.org>
345 * intrinsic.c (add_subroutines): Change keyword "operator"
346 to the correct one, "operation".
347 * check.c (gfc_check_co_reduce): Change OPERATOR to
348 OPERATION in error messages.
349 * intrinsic.texi: Change OPERATOR to OPERATION in
352 2021-11-07 Sandra Loosemore <sandra@codesourcery.com>
354 * interface.c (gfc_compare_actual_formal): Continue checking
355 all arguments after encountering an error.
356 * intrinsic.c (do_ts29113_check): Likewise.
357 * resolve.c (resolve_operator): Continue resolving on op2 error.
359 2021-11-06 Harald Anlauf <anlauf@gmx.de>
362 * decl.c (add_init_expr_to_sym): Reject rank mismatch between
363 array and its initializer.
365 2021-11-05 Harald Anlauf <anlauf@gmx.de>
368 * expr.c (simplify_parameter_variable): Copy shape of referenced
369 subobject when simplifying.
371 2021-11-05 Harald Anlauf <anlauf@gmx.de>
374 * match.c (gfc_match_common): Check array spec of a symbol in a
375 COMMON object list and reject it if it is a coarray.
377 2021-11-05 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
380 * decl.c (gfc_match_implicit_none): Fix typo in warning.
381 * resolve.c (resolve_unknown_f): Reject external procedures
382 without explicit EXTERNAL attribute whe IMPLICIT none (external)
385 2021-11-05 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
387 * decl.c (gfc_insert_kind_parameter_exprs): Make static.
388 * expr.c (gfc_build_init_expr): Make static
389 (gfc_build_default_init_expr): Move below its static helper.
390 * gfortran.h (gfc_insert_kind_parameter_exprs, gfc_add_saved_common,
391 gfc_add_common, gfc_use_derived_tree, gfc_free_charlen,
392 gfc_get_ultimate_derived_super_type,
393 gfc_resolve_oacc_parallel_loop_blocks, gfc_build_init_expr,
394 gfc_iso_c_sub_interface): Delete.
395 * symbol.c (gfc_new_charlen, gfc_get_derived_super_type): Make
398 2021-11-05 Sandra Loosemore <sandra@codesourcery.com>
401 * gfortran.texi (Mixed-Language Programming): Talk about C++,
404 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
406 * gfortran.texi (Projects): Add bullet for helping with
407 incomplete standards compliance.
408 (Proposed Extensions): Delete section.
410 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
412 * intrinsic.texi (Introduction to Intrinsics): Genericize
413 references to standard versions.
414 * invoke.texi (-fall-intrinsics): Likewise.
415 (-fmax-identifier-length=): Likewise.
417 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
419 * gfortran.texi (Interoperability with C): Copy-editing. Add
421 (Intrinsic Types): Likewise.
422 (Derived Types and struct): Likewise.
423 (Interoperable Global Variables): Likewise.
424 (Interoperable Subroutines and Functions): Likewise.
425 (Working with C Pointers): Likewise.
426 (Further Interoperability of Fortran with C): Likewise. Rewrite
427 to reflect that this is now fully supported by gfortran.
429 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
431 * gfortran.texi (About GNU Fortran): Consolidate material
432 formerly in other sections. Copy-editing.
433 (Preprocessing and conditional compilation): Delete, moving
434 most material to invoke.texi.
435 (GNU Fortran and G77): Delete.
436 (Project Status): Delete.
438 (Fortran 95 status): Mention conditional compilation here.
439 (Fortran 2003 status): Rewrite to mention the 1 missing feature
440 instead of all the ones implemented.
441 (Fortran 2008 status): Similarly for the 2 missing features.
442 (Fortran 2018 status): Rewrite to reflect completion of TS29113
444 * invoke.texi (Preprocessing Options): Move material formerly
445 in introductory chapter here.
447 2021-11-04 Sandra Loosemore <sandra@codesourcery.com>
449 * gfortran.texi (Standards): Move discussion of specific
450 standard versions here....
451 (Fortran standards status): ...from here, and delete this node.
453 2021-10-31 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
455 * symbol.c (gfc_get_typebound_proc): Revert memcpy.
457 2021-10-31 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
459 * resolve.c (resolve_fl_procedure): Initialize
460 allocatable_or_pointer.
462 2021-10-30 Manfred Schwarb <manfred99@gmx.ch>
464 * intrinsic.texi: Remove entries for SHORT and LONG intrinsics.
466 2021-10-30 Manfred Schwarb <manfred99@gmx.ch>
468 * check.c (gfc_check_intconv): Change error message.
470 2021-10-30 Manfred Schwarb <manfred99@gmx.ch>
472 * intrinsic.texi (REAL): Fix entries in Specific names table.
474 2021-10-30 Manfred Schwarb <manfred99@gmx.ch>
476 * intrinsic.texi: Adjust @columnfractions commands to improve
477 appearance for narrow 80 character terminals.
479 2021-10-30 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
481 * parse.c (clean_up_modules): Free gsym.
483 2021-10-30 Harald Anlauf <anlauf@gmx.de>
485 * gfortran.texi (bug reports): credit Gerhard Steinmetz for
486 numerous bug reports.
488 2021-10-30 Steve Kargl <kargl@gcc.gnu.org>
491 * resolve.c (resolve_select): Generate regular gfc_error on
492 invalid conversions instead of an gfc_internal_error.
494 2021-10-29 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
496 * symbol.c (free_tb_tree): Free type-bound procedure struct.
497 (gfc_get_typebound_proc): Use explicit memcpy for clarity.
499 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
501 * intrinsic.h (gfc_check_sum, gfc_resolve_atan2d, gfc_resolve_kill,
502 gfc_resolve_kill_sub): Delete declaration.
504 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
506 * trans-types.h (gfc_convert_function_code): Delete.
508 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
510 * trans-stmt.h (gfc_trans_deallocate_array): Delete.
512 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
514 * trans-array.c (gfc_trans_scalarized_loop_end): Make static.
515 * trans-array.h (gfc_trans_scalarized_loop_end,
516 gfc_conv_tmp_ref, gfc_conv_array_transpose): Delete declaration.
518 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
520 * constructor.c (gfc_constructor_get_base): Make static.
521 (gfc_constructor_expr_foreach, gfc_constructor_swap): Delete.
522 * constructor.h (gfc_constructor_get_base): Remove declaration.
523 (gfc_constructor_expr_foreach, gfc_constructor_swap): Delete.
525 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
527 * decl.c (gfc_match_old_kind_spec, set_com_block_bind_c,
528 set_verify_bind_c_sym, set_verify_bind_c_com_block,
529 get_bind_c_idents, gfc_match_suffix, gfc_get_type_attr_spec,
530 check_extended_derived_type): Make static.
531 (gfc_match_gcc_unroll): Add comment.
532 * match.c (gfc_match_small_int_expr): Delete definition.
533 * match.h (gfc_match_small_int_expr): Delete declaration.
534 (gfc_match_name_C, gfc_match_old_kind_spec, set_com_block_bind_c,
535 set_verify_bind_c_sym, set_verify_bind_c_com_block,
536 get_bind_c_idents, gfc_match_suffix,
537 gfc_get_type_attr_spec): Delete declaration.
539 2021-10-27 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
541 * expr.c (is_non_empty_structure_constructor): Make static.
542 * gfortran.h (gfc_check_any_c_kind): Delete.
543 * match.c (gfc_match_label): Make static.
544 * match.h (gfc_match_label): Delete declaration.
545 * scanner.c (file_changes_cur, file_changes_count,
546 file_changes_allocated): Make static.
547 * trans-expr.c (gfc_get_character_len): Make static.
548 (gfc_class_len_or_zero_get): Make static.
549 (VTAB_GET_FIELD_GEN): Undefine.
550 (gfc_get_class_array_ref): Make static.
551 (gfc_finish_interface_mapping): Make static.
552 * trans-types.c (gfc_check_any_c_kind): Delete.
553 (pfunc_type_node, dtype_type_node, gfc_get_ppc_type): Make static.
554 * trans-types.h (gfc_get_ppc_type): Delete declaration.
555 * trans.c (gfc_msg_wrong_return): Delete.
556 * trans.h (gfc_class_len_or_zero_get, gfc_class_vtab_extends_get,
557 gfc_vptr_extends_get, gfc_get_class_array_ref, gfc_get_character_len,
558 gfc_finish_interface_mapping, gfc_msg_wrong_return,
559 gfc_get_function_decl): Delete declaration.
561 2021-10-27 Tobias Burnus <tobias@codesourcery.com>
563 * trans-stmt.c (gfc_trans_select_rank_cases): Fix condition
564 for allocatables/pointers.
566 2021-10-26 Harald Anlauf <anlauf@gmx.de>
569 * symbol.c (gfc_check_conflict): Add conflict check for PDT KIND
570 and LEN type parameters.
572 2021-10-26 Harald Anlauf <anlauf@gmx.de>
575 * decl.c (match_attr_spec): Remove invalid integer kind checks on
576 KIND and LEN attributes of PDTs.
578 2021-10-26 Harald Anlauf <anlauf@gmx.de>
581 * resolve.c (resolve_structure_cons): Reject invalid array spec of
582 a DT component referenced in a structure constructor.
584 2021-10-26 Tobias Burnus <tobias@codesourcery.com>
587 * trans-decl.c (gfc_conv_cfi_to_gfc): Properly handle nonconstant
590 2021-10-25 Andrew MacLeod <amacleod@redhat.com>
592 * trans-decl.c (gfc_conv_cfi_to_gfc): Initialize rank to NULL_TREE.
594 2021-10-22 Eric Gallager <egallager@gcc.gnu.org>
597 * Make-lang.in: Allow dvi-formatted documentation
600 2021-10-22 Tobias Burnus <tobias@codesourcery.com>
603 * trans-expr.c (gfc_trans_assignment_1): Add STRIP_NOPS.
605 2021-10-21 Chung-Lin Tang <cltang@codesourcery.com>
607 * decl.c (gfc_match_end): Add COMP_OMP_STRICTLY_STRUCTURED_BLOCK case
608 together with COMP_BLOCK.
609 * parse.c (parse_omp_structured_block): Change return type to
610 'gfc_statement', add handling for strictly-structured block case, adjust
611 recursive calls to parse_omp_structured_block.
612 (parse_executable): Adjust calls to parse_omp_structured_block.
613 * parse.h (enum gfc_compile_state): Add
614 COMP_OMP_STRICTLY_STRUCTURED_BLOCK.
615 * trans-openmp.c (gfc_trans_omp_workshare): Add EXEC_BLOCK case
618 2021-10-21 Sandra Loosemore <sandra@codesourcery.com>
621 * expr.c (gfc_simplify_expr): Handle GFC_ISYM_SHAPE along with
622 GFC_ISYM_LBOUND and GFC_ISYM_UBOUND.
623 * trans-array.c (gfc_conv_ss_startstride): Likewise.
624 (set_loop_bounds): Likewise.
625 * trans-intrinsic.c (gfc_trans_intrinsic_bound): Extend to
626 handle SHAPE. Correct logic for zero-size special cases and
627 detecting assumed-rank arrays associated with an assumed-size
629 (gfc_conv_intrinsic_shape): Deleted.
630 (gfc_conv_intrinsic_function): Handle GFC_ISYM_SHAPE like
631 GFC_ISYM_LBOUND and GFC_ISYM_UBOUND.
632 (gfc_add_intrinsic_ss_code): Likewise.
633 (gfc_walk_intrinsic_bound): Likewise.
635 2021-10-20 Chung-Lin Tang <cltang@codesourcery.com>
637 * openmp.c (gfc_match_omp_clause_reduction): Add 'openmp_target' default
638 false parameter. Add 'always,tofrom' map for OMP_LIST_IN_REDUCTION case.
639 (gfc_match_omp_clauses): Add 'openmp_target' default false parameter,
640 adjust call to gfc_match_omp_clause_reduction.
641 (match_omp): Adjust call to gfc_match_omp_clauses
642 * trans-openmp.c (gfc_trans_omp_taskgroup): Add call to
643 gfc_match_omp_clause, create and return block.
645 2021-10-19 Tobias Burnus <tobias@codesourcery.com>
647 * trans-types.c (create_fn_spec): For allocatable/pointer
648 character(len=:), use 'w' not 'R' as fn spec for the length dummy
651 2021-10-19 Tobias Burnus <tobias@codesourcery.com>
654 * trans-expr.c (gfc_conv_procedure_call): Use TREE_OPERAND not
655 build_fold_indirect_ref_loc to undo an ADDR_EXPR.
657 2021-10-18 Tobias Burnus <tobias@codesourcery.com>
666 * decl.c (gfc_verify_c_interop_param): Remove 'sorry' for
667 scalar allocatable/pointer and len=*.
668 * expr.c (is_CFI_desc): Return true for for those.
669 * gfortran.h (CFI_type_kind_shift, CFI_type_mask,
670 CFI_type_from_type_kind, CFI_VERSION, CFI_MAX_RANK,
671 CFI_attribute_pointer, CFI_attribute_allocatable,
672 CFI_attribute_other, CFI_type_Integer, CFI_type_Logical,
673 CFI_type_Real, CFI_type_Complex, CFI_type_Character,
674 CFI_type_ucs4_char, CFI_type_struct, CFI_type_cptr,
675 CFI_type_cfunptr, CFI_type_other): New #define.
676 * trans-array.c (CFI_FIELD_BASE_ADDR, CFI_FIELD_ELEM_LEN,
677 CFI_FIELD_VERSION, CFI_FIELD_RANK, CFI_FIELD_ATTRIBUTE,
678 CFI_FIELD_TYPE, CFI_FIELD_DIM, CFI_DIM_FIELD_LOWER_BOUND,
679 CFI_DIM_FIELD_EXTENT, CFI_DIM_FIELD_SM,
680 gfc_get_cfi_descriptor_field, gfc_get_cfi_desc_base_addr,
681 gfc_get_cfi_desc_elem_len, gfc_get_cfi_desc_version,
682 gfc_get_cfi_desc_rank, gfc_get_cfi_desc_type,
683 gfc_get_cfi_desc_attribute, gfc_get_cfi_dim_item,
684 gfc_get_cfi_dim_lbound, gfc_get_cfi_dim_extent, gfc_get_cfi_dim_sm):
685 New define/functions to access the CFI array descriptor.
686 (gfc_conv_descriptor_type): New function for the GFC descriptor.
687 (gfc_get_array_span): Handle expr of CFI descriptors and
688 assumed-type descriptors.
689 (gfc_trans_array_bounds): Remove 'static'.
690 (gfc_conv_expr_descriptor): For assumed type, use the dtype of
692 (structure_alloc_comps): Remove ' ' inside tabs.
693 * trans-array.h (gfc_trans_array_bounds, gfc_conv_descriptor_type,
694 gfc_get_cfi_desc_base_addr, gfc_get_cfi_desc_elem_len,
695 gfc_get_cfi_desc_version, gfc_get_cfi_desc_rank,
696 gfc_get_cfi_desc_type, gfc_get_cfi_desc_attribute,
697 gfc_get_cfi_dim_lbound, gfc_get_cfi_dim_extent, gfc_get_cfi_dim_sm):
699 * trans-decl.c (gfor_fndecl_cfi_to_gfc, gfor_fndecl_gfc_to_cfi):
701 (gfc_build_builtin_function_decls): Remove their initialization.
702 (gfc_get_symbol_decl, create_function_arglist,
703 gfc_trans_deferred_vars): Update for CFI.
704 (convert_CFI_desc): Remove and replace by ...
705 (gfc_conv_cfi_to_gfc): ... this function
706 (gfc_generate_function_code): Call it; create local GFC var for CFI.
707 * trans-expr.c (gfc_maybe_dereference_var): Handle CFI.
708 (gfc_conv_subref_array_arg): Handle the if-noncontigous-only copy in
709 when the result should be a descriptor.
710 (gfc_conv_gfc_desc_to_cfi_desc): Completely rewritten.
711 (gfc_conv_procedure_call): CFI fixes.
712 * trans-openmp.c (gfc_omp_is_optional_argument,
713 gfc_omp_check_optional_argument): Handle optional
715 * trans-stmt.c (gfc_trans_select_rank_cases): Cleanup, avoid invalid
716 code for allocatable/pointer dummies, which cannot be assumed size.
717 * trans-types.c (gfc_cfi_descriptor_base): New global var.
718 (gfc_get_dtype_rank_type): Skip rank init for rank < 0.
719 (gfc_sym_type): Handle CFI dummies.
720 (gfc_get_function_type): Update call.
721 (gfc_get_cfi_dim_type, gfc_get_cfi_type): New.
722 * trans-types.h (gfc_sym_type): Update prototype.
723 (gfc_get_cfi_type): New prototype.
724 * trans.c (gfc_trans_runtime_check): Make conditions more consistent
725 to avoid '<logical> AND_THEN <long int>' in conditions.
726 * trans.h (gfor_fndecl_cfi_to_gfc, gfor_fndecl_gfc_to_cfi): Remove
727 global-var declaration.
729 2021-10-18 Tobias Burnus <tobias@codesourcery.com>
732 * intrinsic.c (gfc_convert_type_warn): Fix checks by checking CLASS
733 and do typcheck in correct order for type extension.
734 * misc.c (gfc_typename): Print proper not internal CLASS type name.
736 2021-10-15 Harald Anlauf <anlauf@gmx.de>
737 Tobias Burnus <tobias@codesourcery.com>
740 * decl.c (match_clist_expr): Set rank/shape of clist initializer
742 * resolve.c (resolve_structure_cons): In a structure constructor,
743 compare shapes of array components against declared shape.
745 2021-10-14 Harald Anlauf <anlauf@gmx.de>
748 * simplify.c (gfc_simplify_reshape): Replace assert by error
749 message for negative elements in SHAPE array.
751 2021-10-14 Harald Anlauf <anlauf@gmx.de>
754 * check.c (gfc_check_shape): Reorder checks so that invalid KIND
755 arguments can be detected.
757 2021-10-14 Kwok Cheung Yeung <kcy@codesourcery.com>
759 * gfortran.h (enum gfc_statement): Add ST_OMP_DECLARE_VARIANT.
760 (enum gfc_omp_trait_property_kind): New.
761 (struct gfc_omp_trait_property): New.
762 (gfc_get_omp_trait_property): New macro.
763 (struct gfc_omp_selector): New.
764 (gfc_get_omp_selector): New macro.
765 (struct gfc_omp_set_selector): New.
766 (gfc_get_omp_set_selector): New macro.
767 (struct gfc_omp_declare_variant): New.
768 (gfc_get_omp_declare_variant): New macro.
769 (struct gfc_namespace): Add omp_declare_variant field.
770 (gfc_free_omp_declare_variant_list): New prototype.
771 * match.h (gfc_match_omp_declare_variant): New prototype.
772 * openmp.c (gfc_free_omp_trait_property_list): New.
773 (gfc_free_omp_selector_list): New.
774 (gfc_free_omp_set_selector_list): New.
775 (gfc_free_omp_declare_variant_list): New.
776 (gfc_match_omp_clauses): Add extra optional argument. Handle end of
777 clauses for context selectors.
778 (omp_construct_selectors, omp_device_selectors,
779 omp_implementation_selectors, omp_user_selectors): New.
780 (gfc_match_omp_context_selector): New.
781 (gfc_match_omp_context_selector_specification): New.
782 (gfc_match_omp_declare_variant): New.
783 * parse.c: Include tree-core.h and omp-general.h.
784 (decode_omp_directive): Handle 'declare variant'.
785 (case_omp_decl): Include ST_OMP_DECLARE_VARIANT.
786 (gfc_ascii_statement): Handle ST_OMP_DECLARE_VARIANT.
787 (gfc_parse_file): Initialize omp_requires_mask.
788 * symbol.c (gfc_free_namespace): Call
789 gfc_free_omp_declare_variant_list.
790 * trans-decl.c (gfc_get_extern_function_decl): Call
791 gfc_trans_omp_declare_variant.
792 (gfc_create_function_decl): Call gfc_trans_omp_declare_variant.
793 * trans-openmp.c (gfc_trans_omp_declare_variant): New.
794 * trans-stmt.h (gfc_trans_omp_declare_variant): New prototype.
796 2021-10-13 Tobias Burnus <tobias@codesourcery.com>
798 * dump-parse-tree.c (show_omp_clauses): Handle ancestor modifier,
799 avoid ICE for GFC_OMP_ATOMIC_SWAP.
800 * gfortran.h (gfc_omp_clauses): Change 'anecestor' into a bitfield.
802 2021-10-12 Tobias Burnus <tobias@codesourcery.com>
805 * check.c (gfc_check_present): Handle optional CLASS.
806 * interface.c (gfc_compare_actual_formal): Likewise.
807 * trans-array.c (gfc_trans_g77_array): Likewise.
808 * trans-decl.c (gfc_build_dummy_array_decl): Likewise.
809 * trans-types.c (gfc_sym_type): Likewise.
810 * primary.c (gfc_variable_attr): Fixes for dummy and
811 pointer when 'class%_data' is passed.
812 * trans-expr.c (set_dtype_for_unallocated, gfc_conv_procedure_call):
813 For assumed-rank dummy, fix setting rank for dealloc/notassoc actual
814 and setting ubound to -1 for assumed-size actuals.
816 2021-10-10 Harald Anlauf <anlauf@gmx.de>
820 * decl.c (add_init_expr_to_sym): Extend initialization of
821 parameter arrays from scalars to handle derived types.
823 2021-10-09 Harald Anlauf <anlauf@gmx.de>
826 * module.c (read_module): Handle old and new-style relational
827 operators when used in USE module, ONLY: OPERATOR(op).
829 2021-10-08 Sandra Loosemore <sandra@codesourcery.com>
832 * interface.c (gfc_compare_actual_formal): Add diagnostic
833 for F2018:C839. Refactor shared code and fix bugs with class
834 array info lookup, and extend similar diagnostic from PR94110
835 to also cover class types.
837 2021-10-08 Martin Liska <mliska@suse.cz>
839 * options.c (gfc_post_options): Use new macro
842 2021-10-06 Tobias Burnus <tobias@codesourcery.com>
844 * resolve.c (resolve_values): Only show
845 deprecated warning if attr.referenced.
847 2021-10-04 Tobias Burnus <tobias@codesourcery.com>
850 * resolve.c (can_generate_init, resolve_fl_variable_derived,
851 resolve_symbol): Only do initialization with intent(out) if not
852 inside of an interface block.
854 2021-10-01 Martin Sebor <msebor@redhat.com>
857 * array.c: Remove an unnecessary test.
858 * trans-array.c: Same.
860 2021-10-01 Jakub Jelinek <jakub@redhat.com>
862 * gfortran.h (gfc_omp_clauses): Add order_reproducible bitfield.
863 * dump-parse-tree.c (show_omp_clauses): Print REPRODUCIBLE: for it.
864 * openmp.c (gfc_match_omp_clauses): Set order_reproducible for
865 explicit reproducible: modifier.
866 * trans-openmp.c (gfc_trans_omp_clauses): Set
867 OMP_CLAUSE_ORDER_REPRODUCIBLE for order_reproducible.
868 (gfc_split_omp_clauses): Also copy order_reproducible.
870 2021-09-30 Harald Anlauf <anlauf@gmx.de>
873 * simplify.c (simplify_size): Resolve expressions used in array
874 specifications so that SIZE can be simplified.
876 2021-09-30 Harald Anlauf <anlauf@gmx.de>
878 * expr.c: The correct reference to Fortran standard is: F2018:10.1.12.
880 2021-09-30 Tobias Burnus <tobias@codesourcery.com>
884 * trans-intrinsic.c (gfc_conv_same_type_as): Fix handling
886 * trans.h (gfc_vtpr_hash_get): Renamed prototype to ...
887 (gfc_vptr_hash_get): ... this to match function name.
889 2021-09-29 Harald Anlauf <anlauf@gmx.de>
892 * array.c (expand_constructor): Do not dereference NULL pointer.
894 2021-09-27 Tobias Burnus <tobias@codesourcery.com>
897 * trans-array.c (gfc_tree_array_size): New function to
898 find size inline (whole array or one dimension).
899 (array_parameter_size): Use it, take stmt_block as arg.
900 (gfc_conv_array_parameter): Update call.
901 * trans-array.h (gfc_tree_array_size): Add prototype.
902 * trans-decl.c (gfor_fndecl_size0, gfor_fndecl_size1): Remove
904 (gfc_build_intrinsic_function_decls): Remove their initialization.
905 * trans-expr.c (gfc_conv_procedure_call): Update
906 bounds of pointer/allocatable actual args to nonallocatable/nonpointer
907 dummies to be one based.
908 * trans-intrinsic.c (gfc_conv_intrinsic_shape): Fix case for
909 assumed rank with allocatable/pointer dummy.
910 (gfc_conv_intrinsic_size): Update to use inline function.
911 * trans.h (gfor_fndecl_size0, gfor_fndecl_size1): Remove var decl.
913 2021-09-26 Tobias Burnus <tobias@codesourcery.com>
916 * trans-intrinsic.c (gfc_conv_associated): Support assumed-rank
917 'pointer' with scalar/array 'target' argument.
919 2021-09-24 Harald Anlauf <anlauf@gmx.de>
922 * expr.c (is_non_constant_intrinsic): Check for intrinsics
923 excluded in constant expressions (F2018:10.1.2).
924 (gfc_is_constant_expr): Use that check.
926 2021-09-24 Sandra Loosemore <sandra@codesourcery.com>
929 * interface.c (compare_parameter): Enforce F2018 C711.
931 2021-09-24 Tobias Burnus <tobias@codesourcery.com>
934 * scanner.c (load_file): Return void, call (gfc_)fatal_error for
936 (include_line, include_stmt, gfc_new_file): Remove exit call
937 for failed load_file run.
939 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
942 * decl.c (gfc_verify_c_interop_param): Handle F2018 C1557,
945 2021-09-23 Harald Anlauf <anlauf@gmx.de>
946 Tobias Burnus <tobias@codesourcery.com>
949 * trans-intrinsic.c (gfc_conv_allocated): Cleanup. Handle
950 coindexed scalar coarrays.
952 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
955 * interface.c (gfc_compare_actual_formal): Extend existing
956 assumed-type diagnostic to also check for argument with type
959 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
962 * check.c (gfc_check_associated): Allow an assumed-rank
963 array for the pointer argument.
964 * interface.c (compare_parameter): Also give rank mismatch
965 error on assumed-rank array.
967 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
969 * trans-stmt.c (trans_associate_var): Check that result of
970 GFC_DECL_SAVED_DESCRIPTOR is not null before using it.
972 2021-09-22 Tobias Burnus <tobias@codesourcery.com>
975 * cpp.c (gfc_cpp_register_include_paths, gfc_cpp_post_options):
976 Add new bool verbose_missing_dir_warn argument.
977 * cpp.h (gfc_cpp_post_options): Update prototype.
978 * f95-lang.c (gfc_init): Remove duplicated file-not found diag.
979 * gfortran.h (gfc_check_include_dirs): Takes bool
980 verbose_missing_dir_warn arg.
981 (gfc_new_file): Returns now void.
982 * options.c (gfc_post_options): Update to warn for -I and -J,
983 only, by default but for all when user requested.
984 * scanner.c (gfc_do_check_include_dir):
985 (gfc_do_check_include_dirs, gfc_check_include_dirs): Take bool
986 verbose warn arg and update to avoid printing the same message
988 (load_file): Fix indent.
989 (gfc_new_file): Return void and exit when load_file failed
990 as all other load_file users do.
992 2021-09-22 Tobias Burnus <tobias@codesourcery.com>
994 * trans-expr.c (gfc_simple_for_loop): New.
995 * trans.h (gfc_simple_for_loop): New prototype.
997 2021-09-21 Tobias Burnus <tobias@codesourcery.com>
1000 * cpp.c: Define GCC_C_COMMON_C for #include "options.h" to make
1001 cpp_reason_option_codes available.
1002 (gfc_cpp_register_include_paths): Make static, set pfile's
1003 warn_missing_include_dirs and move before caller.
1004 (gfc_cpp_init_cb): New, cb code moved from ...
1005 (gfc_cpp_init_0): ... here.
1006 (gfc_cpp_post_options): Call gfc_cpp_init_cb.
1007 (cb_cpp_diagnostic_cpp_option): New. As implemented in c-family
1008 to match CppReason flags to -W... names.
1009 (cb_cpp_diagnostic): Use it to replace single special case.
1010 * cpp.h (gfc_cpp_register_include_paths): Remove as now static.
1011 * gfortran.h (gfc_check_include_dirs): New prototype.
1012 (gfc_add_include_path): Add new bool arg.
1013 * options.c (gfc_init_options): Don't set -Wmissing-include-dirs.
1014 (gfc_post_options): Set it here after commandline processing. Call
1015 gfc_add_include_path with defer_warn=false.
1016 (gfc_handle_option): Call it with defer_warn=true.
1017 * scanner.c (gfc_do_check_include_dir, gfc_do_check_include_dirs,
1018 gfc_check_include_dirs): New. Diagnostic moved from ...
1019 (add_path_to_list): ... here, which came before cmdline processing.
1020 Take additional bool defer_warn argument.
1021 (gfc_add_include_path): Take additional defer_warn arg.
1022 * scanner.h (struct gfc_directorylist): Reorder for alignment issues,
1023 add new 'bool warn'.
1025 2021-09-20 Tobias Burnus <tobias@codesourcery.com>
1027 * gfortran.h (gfc_omp_clauses): Add order_unconstrained.
1028 * dump-parse-tree.c (show_omp_clauses): Dump it.
1029 * openmp.c (gfc_match_omp_clauses): Match unconstrained/reproducible
1030 modifiers to ordered(concurrent).
1031 (OMP_DISTRIBUTE_CLAUSES): Accept ordered clause.
1032 (resolve_omp_clauses): Reject ordered + order on same directive.
1033 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses): Pass
1034 on unconstrained modifier of ordered(concurrent).
1036 2021-09-17 Harald Anlauf <anlauf@gmx.de>
1039 * trans-decl.c (gfc_finish_var_decl): Disable the warning message
1040 for variables moved from stack to static storange if they are
1041 declared in the main, but allow the move to happen.
1043 2021-09-17 Sandra Loosemore <sandra@codesourcery.com>
1045 * intrinsic.texi (ISO_C_BINDING): Change C_FLOAT128 to correspond
1046 to _Float128 rather than __float128.
1047 * iso-c-binding.def (c_float128): Update comments.
1048 * trans-intrinsic.c (gfc_builtin_decl_for_float_kind): Likewise.
1049 (build_round_expr): Likewise.
1050 (gfc_build_intrinsic_lib_fndcecls): Likewise.
1051 * trans-types.h (gfc_real16_is_float128): Likewise.
1053 2021-09-16 Harald Anlauf <anlauf@gmx.de>
1056 * trans-expr.c (gfc_conv_procedure_call): Wrap deallocation of
1057 allocatable components of optional allocatable derived type
1058 procedure arguments with INTENT(OUT) into a presence check.
1060 2021-09-14 Harald Anlauf <anlauf@gmx.de>
1063 * resolve.c (resolve_entries): Attempt to recover cleanly after
1064 rejecting mismatched function entries.
1066 2021-09-14 Tobias Burnus <tobias@codesourcery.com>
1069 * parse.c (gfc_ascii_statement): Add missing ST_OMP_END_SCOPE.
1071 2021-09-13 Harald Anlauf <anlauf@gmx.de>
1074 * decl.c (add_init_expr_to_sym): For proper initialization of
1075 array-valued named constants the array bounds need to be
1076 simplified before adding the initializer.
1078 2021-09-13 Harald Anlauf <anlauf@gmx.de>
1081 * expr.c (find_substring_ref): Handle given substring start and
1082 end indices as signed integers, not unsigned.
1084 2021-09-09 Harald Anlauf <anlauf@gmx.de>
1087 * trans-expr.c (gfc_conv_substring): Do not generate substring
1088 bounds check for implied do loop index variable before it actually
1091 2021-09-08 liuhongt <hongtao.liu@intel.com>
1093 * options.c (gfc_post_options): Issue an error for
1094 -fexcess-precision=16.
1096 2021-09-07 Harald Anlauf <anlauf@gmx.de>
1099 * expr.c (find_array_element): When bounds cannot be determined as
1100 constant, return error instead of aborting.
1102 2021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
1104 * openmp.c (gfc_match_omp_flush): Parse 'seq_cst' clause on 'flush'
1106 * trans-openmp.c (gfc_trans_omp_flush): Handle OMP_MEMORDER_SEQ_CST.
1108 2021-09-03 Tobias Burnus <tobias@codesourcery.com>
1110 * decl.c (gfc_verify_c_interop_param): Reject pointer with
1111 CONTIGUOUS attributes as dummy arg. Reject character len > 1
1112 when passed as byte stream.
1114 2021-09-01 Harald Anlauf <anlauf@gmx.de>
1117 * resolve.c (resolve_common_vars): Fix grammar and improve wording
1118 of error message rejecting an unlimited polymorphic in COMMON.
1120 2021-08-31 Harald Anlauf <anlauf@gmx.de>
1123 * simplify.c (substring_has_constant_len): Minimize checks for
1124 substring expressions being allowed.
1126 2021-08-31 Marcel Vollweiler <marcel@codesourcery.com>
1128 * gfortran.h: Add variable for 'ancestor' in struct gfc_omp_clauses.
1129 * openmp.c (gfc_match_omp_clauses): Parse device-modifiers 'device_num'
1130 and 'ancestor' in 'target device' clauses.
1131 * trans-openmp.c (gfc_trans_omp_clauses): Set OMP_CLAUSE_DEVICE_ANCESTOR.
1133 2021-08-30 Harald Anlauf <anlauf@gmx.de>
1136 * match.c (gfc_match_goto): Allow for whitespace in parsing list
1139 2021-08-30 Harald Anlauf <anlauf@gmx.de>
1142 * resolve.c (resolve_allocate_expr): An unlimited polymorphic
1143 argument to ALLOCATE must be ALLOCATABLE or a POINTER. Fix the
1144 corresponding check.
1146 2021-08-28 Harald Anlauf <anlauf@gmx.de>
1149 * resolve.c (resolve_entries): For functions of type CHARACTER
1150 tighten the checks for matching characteristics.
1152 2021-08-25 Lewis Hyatt <lhyatt@gmail.com>
1155 * cpp.c (gfc_cpp_post_options): Call new function
1156 diagnostic_initialize_input_context().
1158 2021-08-24 Harald Anlauf <anlauf@gmx.de>
1161 * trans-decl.c (gfc_finish_var_decl): Adjust check to handle
1162 implicit SAVE as well as variables in the main program. Improve
1163 warning message text.
1165 2021-08-23 Tobias Burnus <tobias@codesourcery.com>
1167 * openmp.c (gfc_match_dupl_check, gfc_match_dupl_memorder,
1168 gfc_match_dupl_atomic): New.
1169 (gfc_match_omp_clauses): Use them; remove duplicate
1170 'release'/'relaxed' clause matching; improve error dignostic
1173 2021-08-23 Tobias Burnus <tobias@codesourcery.com>
1175 * dump-parse-tree.c (show_omp_clauses): Handle 'strict' modifier
1176 on grainsize/num_tasks
1177 * gfortran.h (gfc_omp_clauses): Add grainsize_strict
1178 and num_tasks_strict.
1179 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses):
1180 Handle 'strict' modifier on grainsize/num_tasks.
1181 * openmp.c (gfc_match_omp_clauses): Likewise.
1183 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
1186 (error_uinteger): Take 'long long unsigned' instead
1187 of 'long unsigned' as argumpent.
1188 (error_integer): Take 'long long' instead of 'long'.
1189 (error_hwuint, error_hwint): New.
1190 (error_print): Update to handle 'll' and 'w'
1192 * simplify.c (substring_has_constant_len): Use '%wd'
1195 2021-08-20 Harald Anlauf <anlauf@gmx.de>
1198 * simplify.c (substring_has_constant_len): Fix format string of
1199 gfc_error, pass HOST_WIDE_INT bounds values via char buffer.
1201 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
1203 * dump-parse-tree.c (show_omp_clauses): Handle 'at', 'severity'
1204 and 'message' clauses.
1205 (show_omp_node, show_code_node): Handle EXEC_OMP_ERROR.
1206 * gfortran.h (gfc_statement): Add ST_OMP_ERROR.
1207 (gfc_omp_severity_type, gfc_omp_at_type): New.
1208 (gfc_omp_clauses): Add 'at', 'severity' and 'message' clause;
1209 use more bitfields + ENUM_BITFIELD.
1210 (gfc_exec_op): Add EXEC_OMP_ERROR.
1211 * match.h (gfc_match_omp_error): New.
1212 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_(AT,SEVERITY,MESSAGE).
1213 (gfc_match_omp_clauses): Handle new clauses.
1214 (OMP_ERROR_CLAUSES, gfc_match_omp_error): New.
1215 (resolve_omp_clauses): Resolve new clauses.
1216 (omp_code_to_statement, gfc_resolve_omp_directive): Handle
1218 * parse.c (decode_omp_directive, next_statement,
1219 gfc_ascii_statement): Handle 'omp error'.
1220 * resolve.c (gfc_resolve_blocks): Likewise.
1221 * st.c (gfc_free_statement): Likewise.
1222 * trans-openmp.c (gfc_trans_omp_error): Likewise.
1223 (gfc_trans_omp_directive): Likewise.
1224 * trans.c (trans_code): Likewise.
1226 2021-08-20 Jakub Jelinek <jakub@redhat.com>
1228 * types.def (BT_FN_VOID_CONST_PTR_SIZE): New DEF_FUNCTION_TYPE_2.
1229 * f95-lang.c (ATTR_COLD_NORETURN_NOTHROW_LEAF_LIST): Define.
1231 2021-08-19 Harald Anlauf <anlauf@gmx.de>
1234 * simplify.c (substring_has_constant_len): New.
1235 (gfc_simplify_len): Handle case of substrings with constant
1238 2021-08-18 Tobias Burnus <tobias@codesourcery.com>
1240 * match.h (gfc_match_omp_nothing): New.
1241 * openmp.c (gfc_match_omp_nothing): New.
1242 * parse.c (decode_omp_directive): Match 'nothing' directive.
1244 2021-08-17 Tobias Burnus <tobias@codesourcery.com>
1246 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
1248 * gfortran.h (enum gfc_statement): Add ST_OMP_(END_)SCOPE.
1249 (enum gfc_exec_op): Add EXEC_OMP_SCOPE.
1250 * match.h (gfc_match_omp_scope): New.
1251 * openmp.c (OMP_SCOPE_CLAUSES): Define
1252 (gfc_match_omp_scope): New.
1253 (gfc_match_omp_cancellation_point, gfc_match_omp_end_nowait):
1254 Improve error diagnostic.
1255 (omp_code_to_statement): Handle ST_OMP_SCOPE.
1256 (gfc_resolve_omp_directive): Handle EXEC_OMP_SCOPE.
1257 * parse.c (decode_omp_directive, next_statement,
1258 gfc_ascii_statement, parse_omp_structured_block,
1259 parse_executable): Handle OpenMP's scope construct.
1260 * resolve.c (gfc_resolve_blocks): Likewise
1261 * st.c (gfc_free_statement): Likewise
1262 * trans-openmp.c (gfc_trans_omp_scope): New.
1263 (gfc_trans_omp_directive): Call it.
1264 * trans.c (trans_code): handle EXEC_OMP_SCOPE.
1266 2021-08-16 Tobias Burnus <tobias@codesourcery.com>
1268 * dump-parse-tree.c (show_omp_clauses): Handle 'filter' clause.
1269 (show_omp_node, show_code_node): Handle (combined) omp masked construct.
1270 * frontend-passes.c (gfc_code_walker): Likewise.
1271 * gfortran.h (enum gfc_statement): Add ST_OMP_*_MASKED*.
1272 (enum gfc_exec_op): Add EXEC_OMP_*_MASKED*.
1273 * match.h (gfc_match_omp_masked, gfc_match_omp_masked_taskloop,
1274 gfc_match_omp_masked_taskloop_simd, gfc_match_omp_parallel_masked,
1275 gfc_match_omp_parallel_masked_taskloop,
1276 gfc_match_omp_parallel_masked_taskloop_simd): New prototypes.
1277 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_FILTER.
1278 (gfc_match_omp_clauses): Match it.
1279 (OMP_MASKED_CLAUSES, gfc_match_omp_parallel_masked,
1280 gfc_match_omp_parallel_masked_taskloop,
1281 gfc_match_omp_parallel_masked_taskloop_simd,
1282 gfc_match_omp_masked, gfc_match_omp_masked_taskloop,
1283 gfc_match_omp_masked_taskloop_simd): New.
1284 (resolve_omp_clauses): Resolve filter clause.
1285 (gfc_resolve_omp_parallel_blocks, resolve_omp_do,
1286 omp_code_to_statement, gfc_resolve_omp_directive): Handle
1287 omp masked constructs.
1288 * parse.c (decode_omp_directive, case_exec_markers,
1289 gfc_ascii_statement, parse_omp_do, parse_omp_structured_block,
1290 parse_executable): Likewise.
1291 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
1292 * st.c (gfc_free_statement): Likewise.
1293 * trans-openmp.c (gfc_trans_omp_clauses): Handle filter clause.
1294 (GFC_OMP_SPLIT_MASKED, GFC_OMP_MASK_MASKED): New enum values.
1295 (gfc_trans_omp_masked): New.
1296 (gfc_split_omp_clauses): Handle combined masked directives.
1297 (gfc_trans_omp_master_taskloop): Rename to ...
1298 (gfc_trans_omp_master_masked_taskloop): ... this; handle also
1299 combined masked directives.
1300 (gfc_trans_omp_parallel_master): Rename to ...
1301 (gfc_trans_omp_parallel_master_masked): ... this; handle
1302 combined masked directives.
1303 (gfc_trans_omp_directive): Handle EXEC_OMP_*_MASKED*.
1304 * trans.c (trans_code): Likewise.
1306 2021-08-15 Harald Anlauf <anlauf@gmx.de>
1309 * match.c (sync_statement): Replace %v code by %e in gfc_match to
1310 allow for function references as STAT and ERRMSG arguments.
1311 * resolve.c (resolve_sync): Adjust checks of STAT= and ERRMSG= to
1312 being definable arguments. Function references with a data
1313 pointer result are accepted.
1314 * trans-stmt.c (gfc_trans_sync): Adjust assertion.
1316 2021-08-12 Tobias Burnus <tobias@codesourcery.com>
1318 * gfortran.h (gfc_omp_proc_bind_kind): Add OMP_PROC_BIND_PRIMARY.
1319 * dump-parse-tree.c (show_omp_clauses): Add TODO comment to
1320 change 'master' to 'primary' in proc_bind for OpenMP 5.1.
1321 * intrinsic.texi (OMP_LIB): Mention OpenMP 5.1; add
1322 omp_proc_bind_primary.
1323 * openmp.c (gfc_match_omp_clauses): Accept
1324 'primary' as alias for 'master'.
1325 * trans-openmp.c (gfc_trans_omp_clauses): Handle
1326 OMP_PROC_BIND_PRIMARY.
1328 2021-08-11 Sandra Loosemore <sandra@codesourcery.com>
1330 * iso-c-binding.def (c_float128, c_float128_complex): Check
1331 float128_type_node instead of gfc_float128_type_node.
1332 * trans-types.c (gfc_init_kinds, gfc_build_real_type):
1333 Update comments re supported 128-bit floating-point types.
1335 2021-08-11 Richard Biener <rguenther@suse.de>
1337 * trans-common.c (create_common): Set TREE_THIS_VOLATILE on the
1338 COMPONENT_REF if the field is volatile.
1340 2021-08-07 Harald Anlauf <anlauf@gmx.de>
1343 * primary.c (gfc_expr_attr): Variable attribute can only be
1344 inquired when symtree is non-NULL.
1346 2021-07-28 Harald Anlauf <anlauf@gmx.de>
1349 * expr.c (gfc_check_vardef_context): Add check for KIND and LEN
1350 parameter inquiries.
1351 * match.c (gfc_match): Fix comment for %v code.
1352 (gfc_match_allocate, gfc_match_deallocate): Replace use of %v code
1353 by %e in gfc_match to allow for function references as STAT and
1355 * resolve.c (resolve_allocate_deallocate): Avoid NULL pointer
1356 dereferences and shortcut for bad STAT and ERRMSG argument to
1357 (DE)ALLOCATE. Remove bogus parts of checks for STAT and ERRMSG.
1359 2021-07-26 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1360 Tobias Burnus <tobias@codesourcery.com>
1367 * trans-decl.c (convert_CFI_desc): Only copy out the descriptor
1369 * trans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): Updated attribute
1370 handling which reflect a previous intermediate version of the
1371 standard. Only copy out the descriptor if necessary.
1373 2021-07-23 Harald Anlauf <anlauf@gmx.de>
1376 * check.c (array_check): Adjust check for the case of CLASS
1379 2021-07-21 Thomas Schwinge <thomas@codesourcery.com>
1380 Joseph Myers <joseph@codesourcery.com>
1381 Cesar Philippidis <cesar@codesourcery.com>
1383 * dump-parse-tree.c (show_attr): Update.
1384 * gfortran.h (symbol_attribute): Add 'oacc_routine_nohost' member.
1385 (gfc_omp_clauses): Add 'nohost' member.
1386 * module.c (ab_attribute): Add 'AB_OACC_ROUTINE_NOHOST'.
1387 (attr_bits, mio_symbol_attribute): Update.
1388 * openmp.c (omp_mask2): Add 'OMP_CLAUSE_NOHOST'.
1389 (gfc_match_omp_clauses): Handle 'OMP_CLAUSE_NOHOST'.
1390 (OACC_ROUTINE_CLAUSES): Add 'OMP_CLAUSE_NOHOST'.
1391 (gfc_match_oacc_routine): Update.
1392 * trans-decl.c (add_attributes_to_decl): Update.
1393 * trans-openmp.c (gfc_trans_omp_clauses): Likewise.
1395 2021-07-21 Harald Anlauf <anlauf@gmx.de>
1398 * target-memory.c (gfc_interpret_derived): Size of array component
1399 of derived type can only be computed here for explicit shape.
1400 * trans-types.c (gfc_get_nodesc_array_type): Do not dereference
1403 2021-07-21 Tobias Burnus <tobias@codesourcery.com>
1405 * decl.c (gfc_verify_c_interop_param): Update for F2008 + F2018
1406 changes; reject unsupported bits with 'Error: Sorry,'.
1407 * trans-expr.c (gfc_conv_procedure_call): Fix condition to
1408 For using CFI descriptor with characters.
1410 2021-07-18 Harald Anlauf <anlauf@gmx.de>
1413 * io.c (resolve_tag_format): Extend FORMAT check to unknown type.
1415 2021-07-14 Harald Anlauf <anlauf@gmx.de>
1418 * trans-expr.c (gfc_trans_class_init_assign): Call
1419 gfc_conv_expr_present only for dummy variables.
1421 2021-07-06 Thomas Koenig <tkoenig@gcc.gnu.org>
1424 * frontend-passes.c (traverse_io_block): Adjust test for
1425 when a variable is eligible for the transformation to
1428 2021-06-28 Martin Sebor <msebor@redhat.com>
1430 * trans-array.c (trans_array_constructor): Replace direct uses
1431 of TREE_NO_WARNING with warning_suppressed_p, and suppress_warning.
1432 * trans-decl.c (gfc_build_qualified_array): Same.
1433 (gfc_build_dummy_array_decl): Same.
1434 (generate_local_decl): Same.
1435 (gfc_generate_function_code): Same.
1436 * trans-openmp.c (gfc_omp_clause_default_ctor): Same.
1437 (gfc_omp_clause_copy_ctor): Same.
1438 * trans-types.c (get_dtype_type_node): Same.
1439 (gfc_get_desc_dim_type): Same.
1440 (gfc_get_array_descriptor_base): Same.
1441 (gfc_get_caf_vector_type): Same.
1442 (gfc_get_caf_reference_type): Same.
1443 * trans.c (gfc_create_var_np): Same.
1445 2021-06-23 Tobias Burnus <tobias@codesourcery.com>
1447 * dump-parse-tree.c (show_omp_clauses): Fix enum type used
1448 for dumping gfc_omp_defaultmap_category.
1450 2021-06-23 Andre Vehreschild <vehre@gcc.gnu.org>
1453 * trans-intrinsic.c (conv_co_collective): Check stat for null ptr
1454 before dereferrencing.
1456 2021-06-18 Harald Anlauf <anlauf@gmx.de>
1460 * trans-intrinsic.c (gfc_conv_intrinsic_minmax): Unconditionally
1461 convert result of min/max to result type.
1463 2021-06-16 Harald Anlauf <anlauf@gmx.de>
1467 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
1469 * match.c (gfc_match_pointer_assignment): Likewise.
1470 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
1473 2021-06-16 Harald Anlauf <anlauf@gmx.de>
1476 2021-06-16 Harald Anlauf <anlauf@gmx.de>
1480 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
1482 * match.c (gfc_match_pointer_assignment): Likewise.
1483 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
1486 2021-06-16 Harald Anlauf <anlauf@gmx.de>
1490 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
1492 * match.c (gfc_match_pointer_assignment): Likewise.
1493 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
1496 2021-06-15 Tobias Burnus <tobias@codesourcery.com>
1499 * dump-parse-tree.c (show_omp_clauses): Update for defaultmap.
1500 * f95-lang.c (LANG_HOOKS_OMP_ALLOCATABLE_P,
1501 LANG_HOOKS_OMP_SCALAR_TARGET_P): New.
1502 * gfortran.h (enum gfc_omp_defaultmap,
1503 enum gfc_omp_defaultmap_category): New.
1504 * openmp.c (gfc_match_omp_clauses): Update defaultmap matching.
1505 * trans-decl.c (gfc_finish_decl_attrs): Set GFC_DECL_SCALAR_TARGET.
1506 * trans-openmp.c (gfc_omp_allocatable_p, gfc_omp_scalar_target_p): New.
1507 (gfc_omp_scalar_p): Take 'ptr_alloc_ok' argument.
1508 (gfc_trans_omp_clauses, gfc_split_omp_clauses): Update for
1510 * trans.h (gfc_omp_scalar_p): Update prototype.
1511 (gfc_omp_allocatable_p, gfc_omp_scalar_target_p): New.
1512 (struct lang_decl): Add scalar_target.
1513 (GFC_DECL_SCALAR_TARGET, GFC_DECL_GET_SCALAR_TARGET): New.
1515 2021-06-14 Tobias Burnus <tobias@codesourcery.com>
1517 * resolve.c (resolve_variable): Remove *XCNEW used to
1518 nullify nullified memory.
1520 2021-06-09 Martin Liska <mliska@suse.cz>
1522 * intrinsic.texi: Add missing @headitem to tables with a header.
1524 2021-06-09 Jakub Jelinek <jakub@redhat.com>
1527 * trans-openmp.c (gfc_omp_finish_clause): Gimplify OMP_CLAUSE_SIZE.
1529 2021-06-08 Tobias Burnus <tobias@codesourcery.com>
1532 * trans-openmp.c (gfc_add_clause_implicitly): New.
1533 (gfc_split_omp_clauses): Use it.
1534 (gfc_free_split_omp_clauses): New.
1535 (gfc_trans_omp_do_simd, gfc_trans_omp_parallel_do,
1536 gfc_trans_omp_parallel_do_simd, gfc_trans_omp_distribute,
1537 gfc_trans_omp_teams, gfc_trans_omp_target, gfc_trans_omp_taskloop,
1538 gfc_trans_omp_master_taskloop, gfc_trans_omp_parallel_master): Use it.
1540 2021-06-08 Martin Liska <mliska@suse.cz>
1542 * intrinsic.texi: Fix typo.
1543 * trans-expr.c (gfc_trans_pointer_assignment): Likewise.
1545 2021-06-05 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1552 * trans-array.c (gfc_get_array_span): rework the way character
1553 array "span" was calculated.
1554 (gfc_conv_expr_descriptor): improve handling of character sections
1555 and unlimited polymorphic objects.
1556 * trans-expr.c (gfc_get_character_len): new function to calculate
1557 character string length.
1558 (gfc_get_character_len_in_bytes): new function to calculate
1559 character string length in bytes.
1560 (gfc_conv_scalar_to_descriptor): add call to set the "span".
1561 (gfc_trans_pointer_assignment): set "_len" and antecipate the
1562 initialization of the deferred character length hidden argument.
1563 * trans-intrinsic.c (gfc_conv_associated): set "force_no_tmp" to
1564 avoid the creation of a temporary.
1565 * trans-types.c (gfc_get_dtype_rank_type): rework type detection
1566 so that unlimited polymorphic objects get proper type infomation,
1567 also important for bind(c).
1568 (gfc_get_dtype): add argument to pass the rank if necessary.
1569 (gfc_get_array_type_bounds): cosmetic change to have character
1570 arrays called character instead of unknown.
1571 * trans-types.h (gfc_get_dtype): modify prototype.
1572 * trans.c (get_array_span): rework the way character array "span"
1574 * trans.h (gfc_get_character_len): new prototype.
1575 (gfc_get_character_len_in_bytes): new prototype.
1576 Add "unlimited_polymorphic" flag to "gfc_se" type to signal when
1577 expression carries an unlimited polymorphic object.
1579 2021-06-04 Harald Anlauf <anlauf@gmx.de>
1582 * frontend-passes.c (inline_matmul_assign): Do not inline matmul
1583 if the assignment to the resulting array if it is not of canonical
1584 type (real/integer/complex/logical).
1586 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1588 * dump-parse-tree.c (show_code_node): Handle
1589 EXEC_OMP_(TARGET_)(,PARALLEL_,TEAMS_)LOOP.
1591 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1593 * scanner.c (skip_fixed_omp_sentinel): Set openacc_flag if
1594 this is not an (OpenMP) continuation line.
1595 (skip_fixed_oacc_sentinel): Likewise for openmp_flag and OpenACC.
1596 (gfc_next_char_literal): gfc_error_now to force error for mixed OMP/ACC
1597 continuation once per location and return '\n'.
1599 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1602 * openmp.c (gfc_match_omp_clauses): Fix typo in error message.
1604 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1607 * dump-parse-tree.c (show_omp_clauses): Handle bind clause.
1608 (show_omp_node): Handle loop directive.
1609 * frontend-passes.c (gfc_code_walker): Likewise.
1610 * gfortran.h (enum gfc_statement): Add
1611 ST_OMP_(END_)(TARGET_)(|PARALLEL_|TEAMS_)LOOP.
1612 (enum gfc_omp_bind_type): New.
1613 (gfc_omp_clauses): Use it.
1614 (enum gfc_exec_op): Add EXEC_OMP_(TARGET_)(|PARALLEL_|TEAMS_)LOOP.
1615 * match.h (gfc_match_omp_loop, gfc_match_omp_parallel_loop,
1616 gfc_match_omp_target_parallel_loop, gfc_match_omp_target_teams_loop,
1617 gfc_match_omp_teams_loop): New.
1618 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_BIND.
1619 (gfc_match_omp_clauses): Handle it.
1620 (OMP_LOOP_CLAUSES, gfc_match_omp_loop, gfc_match_omp_teams_loop,
1621 gfc_match_omp_target_teams_loop, gfc_match_omp_parallel_loop,
1622 gfc_match_omp_target_parallel_loop): New.
1623 (resolve_omp_clauses, resolve_omp_do, omp_code_to_statement,
1624 gfc_resolve_omp_directive): Handle omp loop.
1625 * parse.c (decode_omp_directive case_exec_markers, gfc_ascii_statement,
1626 parse_omp_do, parse_executable): Likewise.
1627 (parse_omp_structured_block): Remove ST_ which use parse_omp_do.
1628 * resolve.c (gfc_resolve_blocks): Add omp loop.
1629 * st.c (gfc_free_statement): Likewise.
1630 * trans-openmp.c (gfc_trans_omp_clauses): Handle bind clause.
1631 (gfc_trans_omp_do, gfc_trans_omp_parallel_do, gfc_trans_omp_distribute,
1632 gfc_trans_omp_teams, gfc_trans_omp_target, gfc_trans_omp_directive):
1633 Handle loop directive.
1634 (gfc_split_omp_clauses): Likewise; fix firstprivate/lastprivate
1635 and (in_)reduction for taskloop.
1636 * trans.c (trans_code): Handle omp loop directive.
1638 2021-06-01 Tobias Burnus <tobias@codesourcery.com>
1641 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
1642 (parallel) master taskloop (simd).
1643 * frontend-passes.c (gfc_code_walker): Set in_omp_workshare
1644 to false for parallel master taskloop (simd).
1645 * gfortran.h (enum gfc_statement):
1646 Add ST_OMP_(END_)(PARALLEL_)MASTER_TASKLOOP(_SIMD).
1647 (enum gfc_exec_op): EXEC_OMP_(PARALLEL_)MASTER_TASKLOOP(_SIMD).
1648 * match.h (gfc_match_omp_master_taskloop,
1649 gfc_match_omp_master_taskloop_simd,
1650 gfc_match_omp_parallel_master_taskloop,
1651 gfc_match_omp_parallel_master_taskloop_simd): New prototype.
1652 * openmp.c (gfc_match_omp_parallel_master_taskloop,
1653 gfc_match_omp_parallel_master_taskloop_simd,
1654 gfc_match_omp_master_taskloop,
1655 gfc_match_omp_master_taskloop_simd): New.
1656 (gfc_match_omp_taskloop_simd): Permit 'reduction' clause.
1657 (resolve_omp_clauses): Handle new combined directives; remove
1658 inscan-reduction check to reduce multiple errors; add
1659 task-reduction error for 'taskloop simd'.
1660 (gfc_resolve_omp_parallel_blocks,
1661 resolve_omp_do, omp_code_to_statement,
1662 gfc_resolve_omp_directive): Handle new combined constructs.
1663 * parse.c (decode_omp_directive, next_statement,
1664 gfc_ascii_statement, parse_omp_do, parse_omp_structured_block,
1665 parse_executable): Likewise.
1666 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
1667 * st.c (gfc_free_statement): Likewise.
1668 * trans.c (trans_code): Likewise.
1669 * trans-openmp.c (gfc_split_omp_clauses,
1670 gfc_trans_omp_directive): Likewise.
1671 (gfc_trans_omp_parallel_master): Move after gfc_trans_omp_master_taskloop;
1672 handle parallel master taskloop (simd) as well.
1673 (gfc_trans_omp_taskloop): Take gfc_exec_op as arg.
1674 (gfc_trans_omp_master_taskloop): New.
1676 2021-05-30 Gerald Pfeifer <gerald@pfeifer.com>
1678 * gfortran.texi (BOZ literal constants): Fix typo.
1680 2021-05-28 Tobias Burnus <tobias@codesourcery.com>
1682 * dump-parse-tree.c (show_iterator): New.
1683 (show_omp_namelist): Handle iterators.
1684 (show_omp_clauses): Handle affinity.
1685 * gfortran.h (gfc_free_omp_namelist): New union with 'udr' and new 'ns'.
1686 * match.c (gfc_free_omp_namelist): Add are to choose union element.
1687 * openmp.c (gfc_free_omp_clauses, gfc_match_omp_detach,
1688 gfc_match_omp_clause_reduction, gfc_match_omp_flush): Update
1689 call to gfc_free_omp_namelist.
1690 (gfc_match_omp_variable_list): Likewise; permit preceeding whitespace.
1691 (enum omp_mask1): Add OMP_CLAUSE_AFFINITY.
1692 (gfc_match_iterator): New.
1693 (gfc_match_omp_clauses): Use it; update call to gfc_free_omp_namelist.
1694 (OMP_TASK_CLAUSES): Add OMP_CLAUSE_AFFINITY.
1695 (gfc_match_omp_taskwait): Match depend clause.
1696 (resolve_omp_clauses): Handle affinity; update for udr/union change.
1697 (gfc_resolve_omp_directive): Resolve clauses of taskwait.
1698 * st.c (gfc_free_statement): Update gfc_free_omp_namelist call.
1699 * trans-openmp.c (gfc_trans_omp_array_reduction_or_udr): Likewise
1700 (handle_iterator): New.
1701 (gfc_trans_omp_clauses): Handle iterators for depend/affinity clause.
1702 (gfc_trans_omp_taskwait): Handle depend clause.
1703 (gfc_trans_omp_directive): Update call.
1705 2021-05-27 Harald Anlauf <anlauf@gmx.de>
1708 * trans-intrinsic.c (gfc_conv_intrinsic_size): Use CLASS data
1709 attributes for CLASS arrays for generation of runtime error.
1711 2021-05-27 Harald Anlauf <anlauf@gmx.de>
1714 * trans-array.c (gfc_conv_ss_startstride): Do not call check for
1715 presence of a dummy argument when a symbol actually refers to a
1718 2021-05-25 Tobias Burnus <tobias@codesourcery.com>
1719 Johannes Nendwich <a08727063@unet.univie.ac.at>
1721 * intrinsic.texi (GERROR, GETARGS, GETLOG, NORM2, PARITY, RANDOM_INIT,
1722 RANDOM_NUMBER): Fix typos and copy'n'paste errors.
1724 2021-05-24 Tobias Burnus <tobias@codesourcery.com>
1727 * trans-expr.c (gfc_copy_class_to_class): Add unshare_expr.
1728 * trans-openmp.c (gfc_is_polymorphic_nonptr,
1729 gfc_is_unlimited_polymorphic_nonptr): New.
1730 (gfc_omp_clause_copy_ctor, gfc_omp_clause_dtor): Handle
1731 polymorphic scalars.
1733 2021-05-23 Harald Anlauf <anlauf@gmx.de>
1736 * trans-expr.c (gfc_conv_procedure_call): Adjust check for
1737 implicit conversion of actual argument to an unlimited polymorphic
1740 2021-05-23 Tobias Burnus <tobias@codesourcery.com>
1742 * intrinsic.texi (ATOMIC_ADD, ATOMIC_FETCH_ADD): Use the
1743 proper variable name in the description.
1745 2021-05-22 Andre Vehreschild <vehre@gcc.gnu.org>
1746 Steve Kargl <kargl@gcc.gnu.org>
1749 * trans-decl.c (gfc_build_builtin_function_decls): Move decl.
1750 * trans-intrinsic.c (conv_intrinsic_random_init): Use bool for
1751 lib-call of caf_random_init instead of logical (4-byte).
1752 * trans.h: Add tree var for random_init.
1754 2021-05-20 Marcel Vollweiler <marcel@codesourcery.com>
1756 * openmp.c (gfc_match_omp_clauses): Support map-type-modifier 'close'.
1758 2021-05-18 Tobias Burnus <tobias@codesourcery.com>
1761 * openmp.c (omp_code_to_statement): Add missing EXEC_OMP_DEPOBJ.
1763 2021-05-17 Harald Anlauf <anlauf@gmx.de>
1766 * trans-decl.c (gfc_finish_var_decl): Add check for explicit SAVE
1769 2021-05-17 Tobias Burnus <tobias@codesourcery.com>
1772 * resolve.c (gfc_resolve_code): Reject nonintrinsic assignments in
1775 2021-05-14 Tobias Burnus <tobias@codesourcery.com>
1777 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
1778 EXEC_OMP_PARALLEL_MASTER.
1779 * frontend-passes.c (gfc_code_walker): Likewise.
1780 * gfortran.h (enum gfc_statement): Add ST_OMP_PARALLEL_MASTER and
1781 ST_OMP_END_PARALLEL_MASTER.
1782 (enum gfc_exec_op): Add EXEC_OMP_PARALLEL_MASTER..
1783 * match.h (gfc_match_omp_parallel_master): Handle it.
1784 * openmp.c (gfc_match_omp_parallel_master, resolve_omp_clauses,
1785 omp_code_to_statement, gfc_resolve_omp_directive): Likewise.
1786 * parse.c (decode_omp_directive, case_exec_markers,
1787 gfc_ascii_statement, parse_omp_structured_block,
1788 parse_executable): Likewise.
1789 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
1790 * st.c (gfc_free_statement): Likewise.
1791 * trans-openmp.c (gfc_trans_omp_parallel_master,
1792 gfc_trans_omp_workshare, gfc_trans_omp_directive): Likewise.
1793 * trans.c (trans_code): Likewise.
1795 2021-05-14 Tobias Burnus <tobias@codesourcery.com>
1797 * resolve.c (resolve_symbol): Handle implicit SAVE of main-program
1798 for vars in 'omp threadprivate' and 'omp declare target'.
1800 2021-05-10 Martin Liska <mliska@suse.cz>
1802 * decl.c (variable_decl): Use startswith
1803 function instead of strncmp.
1804 (gfc_match_end): Likewise.
1805 * gfortran.h (gfc_str_startswith): Likewise.
1806 * module.c (load_omp_udrs): Likewise.
1807 (read_module): Likewise.
1808 * options.c (gfc_handle_runtime_check_option): Likewise.
1809 * primary.c (match_arg_list_function): Likewise.
1810 * trans-decl.c (gfc_get_symbol_decl): Likewise.
1811 * trans-expr.c (gfc_conv_procedure_call): Likewise.
1812 * trans-intrinsic.c (gfc_conv_ieee_arithmetic_function): Likewise.
1814 2021-05-06 Paul Thomas <pault@gcc.gnu.org>
1818 * class.c (gfc_build_class_symbol): Remove the error that
1819 disables assumed size class arrays. Class array types that are
1820 not deferred shape or assumed rank are given a unique name and
1821 placed in the procedure namespace.
1822 * trans-array.c (gfc_trans_g77_array): Obtain the data pointer
1824 (gfc_trans_dummy_array_bias): Suppress the runtime error for
1825 extent violations in explicit shape class arrays because it
1827 * trans-expr.c (gfc_conv_procedure_call): Handle assumed size
1828 class actual arguments passed to non-descriptor formal args by
1829 using the data pointer, stored as the symbol's backend decl.
1831 2021-05-05 Harald Anlauf <anlauf@gmx.de>
1834 * interface.c (gfc_compare_actual_formal): Continue checks after
1835 emitting warning for argument length mismatch.
1836 * trans-expr.c (gfc_conv_procedure_call): Check for NULL pointer
1839 2021-05-04 Tobias Burnus <tobias@codesourcery.com>
1842 * trans-openmp.c (gfc_trans_omp_depobj): Fix pasto in enum values.
1844 2021-04-28 Tobias Burnus <tobias@codesourcery.com>
1846 * openmp.c (gfc_match_omp_variable_list): Gobble whitespace before
1847 checking whether a '%' or parenthesis-open follows as next character.
1849 2021-04-28 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1852 * trans-expr.c (gfc_conv_procedure_call): Evaluate function result
1853 and then pass a pointer.
1855 2021-04-26 Thomas Schwinge <thomas@codesourcery.com>
1856 Nathan Sidwell <nathan@codesourcery.com>
1857 Tom de Vries <vries@codesourcery.com>
1858 Julian Brown <julian@codesourcery.com>
1859 Kwok Cheung Yeung <kcy@codesourcery.com>
1861 * lang.opt (Wopenacc-parallelism): New.
1863 2021-04-24 Harald Anlauf <anlauf@gmx.de>
1866 * check.c (variable_check): Allow function reference having a data
1868 (arg_strlen_is_zero): New function.
1869 (gfc_check_fgetputc_sub): Add static check of character and status
1871 (gfc_check_fgetput_sub): Likewise.
1872 * intrinsic.c (add_subroutines): Fix argument name for the
1873 character argument to intrinsic subroutines fget[c], fput[c].
1875 2021-04-24 Harald Anlauf <anlauf@gmx.de>
1878 * expr.c (gfc_check_vardef_context): Extend check to allow pointer
1879 from a function reference.
1881 2021-04-22 Martin Liska <mliska@suse.cz>
1885 * frontend-passes.c (optimize_expr): Fix typos and missing comments.
1887 2021-04-22 Michael Meissner <meissner@linux.ibm.com>
1890 * trans-intrinsic.c (build_round_expr): If int type is larger than
1891 long long, do the round and convert to the integer type. Do not
1892 try to find a floating point type the exact size of the integer
1895 2021-04-21 Tobias Burnus <tobias@codesourcery.com>
1897 * dump-parse-tree.c (show_omp_namelist): Handle depobj + mutexinoutset
1898 in the depend clause.
1899 (show_omp_clauses, show_omp_node, show_code_node): Handle depobj.
1900 * gfortran.h (enum gfc_statement): Add ST_OMP_DEPOBJ.
1901 (enum gfc_omp_depend_op): Add OMP_DEPEND_UNSET,
1902 OMP_DEPEND_MUTEXINOUTSET and OMP_DEPEND_DEPOBJ.
1903 (gfc_omp_clauses): Add destroy, depobj_update and depobj.
1904 (enum gfc_exec_op): Add EXEC_OMP_DEPOBJ
1905 * match.h (gfc_match_omp_depobj): Match 'omp depobj'.
1906 * openmp.c (gfc_match_omp_clauses): Add depobj + mutexinoutset
1908 (gfc_match_omp_depobj, resolve_omp_clauses, gfc_resolve_omp_directive):
1909 Handle 'omp depobj'.
1910 * parse.c (decode_omp_directive, next_statement, gfc_ascii_statement):
1912 * resolve.c (gfc_resolve_code): Likewise.
1913 * st.c (gfc_free_statement): Likewise.
1914 * trans-openmp.c (gfc_trans_omp_clauses): Handle depobj + mutexinoutset
1915 in the depend clause.
1916 (gfc_trans_omp_depobj, gfc_trans_omp_directive): Handle EXEC_OMP_DEPOBJ.
1917 * trans.c (trans_code): Likewise.
1919 2021-04-20 Paul Thomas <pault@gcc.gnu.org>
1922 * trans-decl.c (gfc_get_symbol_decl): Replace test for host
1923 association with a check that the current and symbol namespaces
1926 2021-04-19 Thomas Schwinge <thomas@codesourcery.com>
1928 * lang.opt (fopenacc-kernels=): Remove.
1930 2021-04-16 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1933 * trans-array.c (gfc_trans_deferred_array): Add code to initialize
1934 pointers and allocatables with correct TKR parameters.
1936 2021-04-16 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1939 * resolve.c: Add association check before de-referencing pointer.
1941 2021-04-16 Harald Anlauf <anlauf@gmx.de>
1942 Paul Thomas <pault@gcc.gnu.org>
1945 * module.c (write_symtree): Do not write interface of intrinsic
1946 procedure to module file for F2003 and newer.
1948 2021-04-15 Paul Thomas <pault@gcc.gnu.org>
1951 * symbol.c: Remove trailing white space.
1952 * trans-array.c (gfc_trans_create_temp_array): Create a class
1953 temporary for class expressions and assign the new descriptor
1955 (build_class_array_ref): If the class expr can be extracted,
1956 then use that for 'decl'. Class function results are reliably
1957 handled this way. Call gfc_find_and_cut_at_last_class_ref to
1958 eliminate largely redundant code. Remove dead code and recast
1959 the rest of the code to extract 'decl' for remaining cases.
1960 Call gfc_build_spanned_array_ref.
1961 (gfc_alloc_allocatable_for_assignment): Use class descriptor
1962 element length for 'elemsize1'. Eliminate repeat set of dtype
1963 for class expressions.
1964 * trans-expr.c (gfc_find_and_cut_at_last_class_ref): Include
1965 additional code from build_class_array_ref, and use optional
1966 gfc_typespec pointer argument.
1967 (gfc_trans_scalar_assign): Make use of pre and post blocks for
1968 all class expressions.
1969 * trans.c (get_array_span): For unlimited polymorphic exprs
1970 multiply the span by the value of the _len field.
1971 (gfc_build_spanned_array_ref): New function.
1972 (gfc_build_array_ref): Call gfc_build_spanned_array_ref and
1973 eliminate repeated code.
1974 * trans.h: Add arg to gfc_find_and_cut_at_last_class_ref and
1975 add prototype for gfc_build_spanned_array_ref.
1977 2021-04-14 Martin Liska <mliska@suse.cz>
1979 * intrinsic.texi: The table has first column empty and it makes
1980 trouble when processing makeinfo --xml output.
1982 2021-04-09 Tobias Burnus <tobias@codesourcery.com>
1985 * trans-types.c (gfc_get_function_type): Also generate hidden
1986 coarray argument for character arguments.
1988 2021-04-03 Paul Thomas <pault@gcc.gnu.org>
1991 * interface.c (compare_parameter): The codimension attribute is
1992 applied to the _data field of class formal arguments.
1994 2021-04-01 Harald Anlauf <anlauf@gmx.de>
1997 * simplify.c (gfc_simplify_transpose): Properly initialize
2000 2021-03-28 Paul Thomas <pault@gcc.gnu.org>
2003 * trans-expr.c (gfc_conv_procedure_call): Use the _data attrs
2004 for class expressions and detect proc pointer evaluations by
2005 the non-null actual argument list.
2007 2021-03-27 Steve Kargl <kargl@gcc.gnu.org>
2009 * misc.c (gfc_typename): Fix off-by-one in buffer sizes.
2011 2021-03-26 Tobias Burnus <tobias@codesourcery.com>
2014 * intrinsic.c (gfc_intrinsic_func_interface): Set
2015 attr.proc = PROC_INTRINSIC if FL_PROCEDURE.
2017 2021-03-24 Tobias Burnus <tobias@codesourcery.com>
2020 * resolve.c (resolve_operator): Make 'msg' buffer larger
2023 2021-03-23 Tobias Burnus <tobias@codesourcery.com>
2026 * trans-decl.c (build_function_decl): Add comment;
2027 increment hidden_typelist for caf_token/caf_offset.
2028 * trans-types.c (gfc_get_function_type): Add comment;
2029 add missing caf_token/caf_offset args.
2031 2021-03-22 Tobias Burnus <tobias@codesourcery.com>
2034 * match.c (select_type_set_tmp, gfc_match_select_type,
2035 gfc_match_select_rank): Fix 'name' buffersize to avoid out of bounds.
2036 * resolve.c (resolve_select_type): Likewise.
2038 2021-03-19 Thomas Koenig <tkoenig@gcc.gnu.org>
2040 * frontend-passes.c (inline_limit_check): Add rank_a
2041 argument. If a is rank 1, set the second dimension to 1.
2042 (inline_matmul_assign): Pass rank_a argument to inline_limit_check.
2043 (call_external_blas): Likewise.
2045 2021-03-15 Thomas Koenig <tkoenig@gcc.gnu.org>
2048 * frontend-passes.c (doloop_contained_procedure_code):
2049 Properly handle EXEC_IOLENGTH.
2051 2021-03-15 Paul Thomas <pault@gcc.gnu.org>
2054 * trans-stmt.c (gfc_trans_allocate): Mark the initialization
2055 assignment by setting init_flag.
2057 2021-03-14 Harald Anlauf <anlauf@gmx.de>
2058 Paul Thomas <pault@gcc.gnu.org>
2060 * trans-expr.c (gfc_conv_procedure_call): Fix runtime checks for
2062 * trans-intrinsic.c (gfc_conv_intrinsic_size): Likewise.
2064 2021-03-13 Paul Thomas <pault@gcc.gnu.org>
2067 * trans-array.c (gfc_conv_expr_descriptor): For deferred length
2068 length components use the ss_info string length instead of
2069 gfc_get_expr_charlen. Make sure that the deferred string length
2070 is a variable before assigning to it. Otherwise use the expr.
2071 * trans-expr.c (gfc_conv_string_length): Make sure that the
2072 deferred string length is a variable before assigning to it.
2074 2021-03-12 Tobias Burnus <tobias@codesourcery.com>
2077 * resolve.c (resolve_symbol): Accept vars which are in DATA
2078 and hence (either) implicit SAVE (or in common).
2080 2021-03-10 Harald Anlauf <anlauf@gmx.de>
2083 * data.c (gfc_assign_data_value): Reject non-constant character
2085 * trans-array.c (gfc_conv_array_initializer): Restrict loop to
2086 elements which are defined to avoid NULL pointer dereference.
2088 2021-03-10 Tobias Burnus <tobias@codesourcery.com>
2090 * intrinsic.texi (MIN): Correct 'maximum' to 'minimum'.
2092 2021-03-10 Eric Botcazou <ebotcazou@adacore.com>
2095 * trans-intrinsic.c (build_round_expr): Do not implicitly assume
2096 that __float128 is the 128-bit floating-point type.
2098 2021-03-08 Harald Anlauf <anlauf@gmx.de>
2101 * data.c (gfc_assign_data_value): Reject variable with PARAMETER
2102 attribute in DATA statement.
2104 2021-03-05 Tobias Burnus <tobias@codesourcery.com>
2108 * invoke.texi (-freal{4,8}-real-*): Extend description.
2109 * primary.c (match_real_constant): Also promote real literals
2110 with '_kind' number.
2112 2021-03-04 Tobias Burnus <tobias@codesourcery.com>
2115 * decl.c (gfc_match_old_kind_spec, gfc_match_kind_spec): Avoid
2116 redoing kind conversions.
2117 * primary.c (match_real_constant): Likewise.
2119 2021-02-28 Jakub Jelinek <jakub@redhat.com>
2122 * openmp.c (gfc_omp_requires_add_clause): Fix up diagnostic message
2124 (resolve_omp_clauses): Likewise.
2126 2021-02-28 Jakub Jelinek <jakub@redhat.com>
2129 * frontend-passes.c (doloop_code): Replace double space in diagnostics
2130 with a single space.
2132 2021-02-24 Paul Thomas <pault@gcc.gnu.org>
2135 * trans-expr.c (gfc_conv_derived_to_class): Add optional arg.
2136 'derived_array' to hold the fixed, parmse expr in the case of
2137 assumed rank formal arguments. Deal with optional arguments.
2138 (gfc_conv_procedure_call): Null 'derived' array for each actual
2139 argument. Add its address to the call to gfc_conv_derived_to_
2140 class. Access the 'data' field of scalar descriptors before
2141 deallocating allocatable components. Also strip NOPs before the
2142 calls to gfc_deallocate_alloc_comp. Use 'derived' array as the
2143 input to gfc_deallocate_alloc_comp if it is available.
2144 * trans.h : Include the optional argument 'derived_array' to
2145 the prototype of gfc_conv_derived_to_class. The default value
2148 2021-02-23 Paul Thomas <pault@gcc.gnu.org>
2151 * resolve.c (resolve_fl_procedure): Include class results in
2152 the test for F2018, C15100.
2153 * trans-array.c (get_class_info_from_ss): Do not use the saved
2154 descriptor to obtain the class expression for variables. Use
2155 gfc_get_class_from_expr instead.
2157 2021-02-23 Harald Anlauf <anlauf@gmx.de>
2160 * simplify.c (gfc_simplify_reshape): Set string length for
2161 character arguments.
2163 2021-02-22 Tobias Burnus <tobias@codesourcery.com>
2166 * trans-openmp.c (gfc_omp_is_optional_argument): Regard optional
2167 dummy procs as nonoptional as no special treatment is needed.
2169 2021-02-21 Harald Anlauf <anlauf@gmx.de>
2171 * trans-expr.c (gfc_conv_procedure_call): Do not add clobber to
2172 allocatable intent(out) argument.
2174 2021-02-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
2177 * match.c (gfc_match_namelist): If BT_UNKNOWN, check for
2178 IMPLICIT NONE and and issue an error, otherwise set the type
2179 to its IMPLICIT type so that any subsequent use of objects will
2180 will confirm their types.
2182 2021-02-19 Harald Anlauf <anlauf@gmx.de>
2184 * symbol.c (gfc_add_flavor): Reverse order of conditions.
2186 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
2189 * dependency.c (gfc_dep_resolver): Fix coarray handling.
2191 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
2196 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
2199 * simplify.c (simplify_bound_dim): Honor DIMEN_ELEMENT
2202 2021-02-17 Julian Brown <julian@codesourcery.com>
2204 * openmp.c (resolve_omp_clauses): Disallow selecting components
2205 of arrays of derived type.
2207 2021-02-17 Julian Brown <julian@codesourcery.com>
2209 * trans-openmp.c (gfc_trans_omp_clauses): Handle element selection
2210 for arrays of derived types.
2212 2021-02-16 Tobias Burnus <tobias@codesourcery.com>
2214 * expr.c (gfc_is_simplify_contiguous): Handle REF_INQUIRY, i.e.
2215 %im and %re which are EXPR_VARIABLE.
2216 * openmp.c (resolve_omp_clauses): Diagnose %re/%im explicitly.
2218 2021-02-16 Tobias Burnus <tobias@codesourcery.com>
2221 * io.c (resolve_tag_format): Reject BT_DERIVED/CLASS/VOID
2222 as (array-valued) FORMAT tag.
2224 2021-02-12 Tobias Burnus <tobias@codesourcery.com>
2227 * trans-expr.c (gfc_conv_procedure_call): Don't reset
2228 rank of assumed-rank array.
2230 2021-02-11 Paul Thomas <pault@gcc.gnu.org>
2233 * match.c (gfc_match_call): Include associate names as possible
2234 entities with typebound subroutines. The target needs to be
2235 resolved for the type.
2237 2021-02-11 Paul Thomas <pault@gcc.gnu.org>
2240 * primary.c (gfc_match_varspec): Test for non-null 'previous'
2241 before using its name in the error message.
2243 2021-02-11 Tobias Burnus <tobias@codesourcery.com>
2245 * intrinsic.texi (FINDLOC): Add 'MASK' to argument table.
2246 (MAXLOC, MAXVAL, MINLOC, MINVAL): For 'MASK', remove 'an
2247 array' as scalars are also permitted.
2249 2021-02-10 Julian Brown <julian@codesourcery.com>
2252 * openmp.c (resolve_omp_clauses): Omit OpenACC update in
2253 contiguity check and stride-specified error.
2255 2021-02-04 Julian Brown <julian@codesourcery.com>
2257 * openmp.c (resolve_omp_clauses): Omit OpenACC update in
2258 contiguity check and stride-specified error.
2260 2021-02-04 Julian Brown <julian@codesourcery.com>
2262 * trans-openmp.c (gfc_trans_omp_clauses): Use class_pointer attribute
2265 2021-02-04 Julian Brown <julian@codesourcery.com>
2267 * trans-openmp.c (gfc_trans_omp_clauses): Fix dereferencing for
2270 2021-02-04 Tobias Burnus <tobias@codesourcery.com>
2272 * openmp.c (resolve_omp_clauses): Explicitly diagnose
2273 substrings as not permitted.
2275 2021-02-03 Jeff Law <law@redhat.com>
2277 * intrinsic.texi (ANINT): Fix typo.
2279 2021-02-03 Tobias Burnus <tobias@codesourcery.com>
2282 * dependency.c (gfc_dep_resolver): Treat local access
2283 to coarrays like any array access in dependency analysis.
2285 2021-01-28 Harald Anlauf <anlauf@gmx.de>
2288 * trans.c (gfc_call_malloc): Allocate area of size 1 if passed
2289 size is NULL (as documented).
2291 2021-01-27 Paul Thomas <pault@gcc.gnu.org>
2295 * trans-expr.c (gfc_conv_procedure_call): Suppress the call to
2296 gfc_conv_intrinsic_to_class for unlimited polymorphic procedure
2298 (gfc_trans_assignment_1): Similarly suppress class assignment
2299 for class valued procedure pointers.
2301 2021-01-27 Paul Thomas <pault@gcc.gnu.org>
2304 * trans-array.c (gfc_conv_expr_descriptor): Include elemental
2305 procedure pointers in the assert under the comment 'elemental
2306 function' and eliminate the second, spurious assert.
2308 2021-01-25 Harald Anlauf <anlauf@gmx.de>
2311 * data.c (create_character_initializer): Check substring indices
2313 (gfc_assign_data_value): Catch error returned from
2314 create_character_initializer.
2316 2021-01-25 Tobias Burnus <tobias@codesourcery.com>
2318 * intrinsic.texi (CO_BROADCAST, CO_MIN, CO_REDUCE, CO_SUM): Fix typos.
2320 2021-01-25 Steve Kargl <kargl@gcc.gnu.org>
2323 * resolve.c (resolve_charlen): Check that length expression is
2324 present before testing for scalar/integer..
2326 2021-01-22 Paul Thomas <pault@gcc.gnu.org>
2329 * trans-intrinsic.c (gfc_conv_associated): Do not add a _data
2330 component for scalar class function targets. Instead, fix the
2331 function result and access the _data from that.
2333 2021-01-21 Jorge D'Elia <jdelia@cimec.unl.edu.ar>
2335 * intrinsic.texi (CO_MAX): Fix typo.
2337 2021-01-21 Paul Thomas <pault@gcc.gnu.org>
2340 * decl.c (gfc_match_modproc): It is not an error to find a
2341 module procedure declaration within a contains block.
2342 * expr.c (gfc_check_vardef_context): Pure procedure result is
2343 assignable. Change 'own_scope' accordingly.
2344 * resolve.c (resolve_typebound_procedure): A procedure that
2345 has the module procedure attribute is almost certainly a
2346 module procedure, whatever its interface.
2348 2021-01-19 Tobias Burnus <tobias@codesourcery.com>
2351 * openmp.c (resolve_omp_clauses): Change use_device_ptr
2352 to use_device_addr for unless type(c_ptr); check all
2353 list item for is_device_ptr.
2355 2021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
2357 * dump-parse-tree.c (show_omp_clauses): Handle detach clause.
2358 * frontend-passes.c (gfc_code_walker): Walk detach expression.
2359 * gfortran.h (struct gfc_omp_clauses): Add detach field.
2360 (gfc_c_intptr_kind): New.
2361 * openmp.c (gfc_free_omp_clauses): Free detach clause.
2362 (gfc_match_omp_detach): New.
2363 (enum omp_mask1): Add OMP_CLAUSE_DETACH.
2364 (enum omp_mask2): Remove OMP_CLAUSE_DETACH.
2365 (gfc_match_omp_clauses): Handle OMP_CLAUSE_DETACH for OpenMP.
2366 (OMP_TASK_CLAUSES): Add OMP_CLAUSE_DETACH.
2367 (resolve_omp_clauses): Prevent use of detach with mergeable and
2368 overriding the data sharing mode of the event handle.
2369 * trans-openmp.c (gfc_trans_omp_clauses): Handle detach clause.
2370 * trans-types.c (gfc_c_intptr_kind): New.
2371 (gfc_init_kinds): Initialize gfc_c_intptr_kind.
2373 (BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT): Rename
2375 (BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT_PTR):
2376 ...this. Add extra argument.
2378 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2380 * gfortran.h (gfc_resolve_substring): Add prototype.
2381 * primary.c (match_string_constant): Simplify substrings with
2382 constant starting and ending points.
2383 * resolve.c: Rename resolve_substring to gfc_resolve_substring.
2384 (gfc_resolve_ref): Use renamed function gfc_resolve_substring.
2386 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2389 * resolve.c (resolve_component): Derived type components with
2390 ALLOCATABLE or POINTER attribute shall have a deferred shape.
2392 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2395 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2398 * resolve.c (resolve_component): Derived type components with
2399 ALLOCATABLE or POINTER attribute shall have a deferred shape.
2401 2021-01-14 Harald Anlauf <anlauf@gmx.de>
2404 * resolve.c (resolve_component): Derived type components with
2405 ALLOCATABLE or POINTER attribute shall have a deferred shape.
2407 2021-01-08 Paul Thomas <pault@gcc.gnu.org>
2410 * trans-expr.c (gfc_conv_component_ref): Remove the condition
2411 that deferred character length components only be allocatable.
2413 2021-01-08 Paul Thomas <pault@gcc.gnu.org>
2416 * simplify.c (is_constant_array_expr): If an array constructor
2417 expression has elements other than constants or structures, try
2418 fixing the expression with gfc_reduce_init_expr. Also, if shape
2419 is NULL, obtain the array size and set it.
2421 2021-01-07 Paul Thomas <pault@gcc.gnu.org>
2424 * resolve.c (find_array_spec): Put static prototype for
2425 resolve_assoc_var before this function and call for associate
2428 2021-01-06 Harald Anlauf <anlauf@gmx.de>
2430 * resolve.c (resolve_component): Add check for valid CLASS
2431 reference before trying to access CLASS data.
2433 2021-01-04 Martin Liska <mliska@suse.cz>
2435 * ChangeLog-2018: Remove duplicate ChangeLog entries.
2437 2021-01-01 Harald Anlauf <anlauf@gmx.de>
2439 * class.c (gfc_find_vtab): Add check on attribute is_class.
2441 2021-01-01 Jakub Jelinek <jakub@redhat.com>
2443 * gfortranspec.c (lang_specific_driver): Update copyright notice
2445 * gfc-internals.texi: Bump @copying's copyright year.
2446 * gfortran.texi: Ditto.
2447 * intrinsic.texi: Ditto.
2448 * invoke.texi: Ditto.
2450 2021-01-01 Jakub Jelinek <jakub@redhat.com>
2452 * ChangeLog-2020: Rotate ChangeLog. New file.
2455 Copyright (C) 2021 Free Software Foundation, Inc.
2457 Copying and distribution of this file, with or without modification,
2458 are permitted in any medium without royalty provided the copyright
2459 notice and this notice are preserved.