1 2021-10-22 Eric Gallager <egallager@gcc.gnu.org>
4 * Make-lang.in: Allow dvi-formatted documentation
7 2021-10-22 Tobias Burnus <tobias@codesourcery.com>
10 * trans-expr.c (gfc_trans_assignment_1): Add STRIP_NOPS.
12 2021-10-21 Chung-Lin Tang <cltang@codesourcery.com>
14 * decl.c (gfc_match_end): Add COMP_OMP_STRICTLY_STRUCTURED_BLOCK case
15 together with COMP_BLOCK.
16 * parse.c (parse_omp_structured_block): Change return type to
17 'gfc_statement', add handling for strictly-structured block case, adjust
18 recursive calls to parse_omp_structured_block.
19 (parse_executable): Adjust calls to parse_omp_structured_block.
20 * parse.h (enum gfc_compile_state): Add
21 COMP_OMP_STRICTLY_STRUCTURED_BLOCK.
22 * trans-openmp.c (gfc_trans_omp_workshare): Add EXEC_BLOCK case
25 2021-10-21 Sandra Loosemore <sandra@codesourcery.com>
28 * expr.c (gfc_simplify_expr): Handle GFC_ISYM_SHAPE along with
29 GFC_ISYM_LBOUND and GFC_ISYM_UBOUND.
30 * trans-array.c (gfc_conv_ss_startstride): Likewise.
31 (set_loop_bounds): Likewise.
32 * trans-intrinsic.c (gfc_trans_intrinsic_bound): Extend to
33 handle SHAPE. Correct logic for zero-size special cases and
34 detecting assumed-rank arrays associated with an assumed-size
36 (gfc_conv_intrinsic_shape): Deleted.
37 (gfc_conv_intrinsic_function): Handle GFC_ISYM_SHAPE like
38 GFC_ISYM_LBOUND and GFC_ISYM_UBOUND.
39 (gfc_add_intrinsic_ss_code): Likewise.
40 (gfc_walk_intrinsic_bound): Likewise.
42 2021-10-20 Chung-Lin Tang <cltang@codesourcery.com>
44 * openmp.c (gfc_match_omp_clause_reduction): Add 'openmp_target' default
45 false parameter. Add 'always,tofrom' map for OMP_LIST_IN_REDUCTION case.
46 (gfc_match_omp_clauses): Add 'openmp_target' default false parameter,
47 adjust call to gfc_match_omp_clause_reduction.
48 (match_omp): Adjust call to gfc_match_omp_clauses
49 * trans-openmp.c (gfc_trans_omp_taskgroup): Add call to
50 gfc_match_omp_clause, create and return block.
52 2021-10-19 Tobias Burnus <tobias@codesourcery.com>
54 * trans-types.c (create_fn_spec): For allocatable/pointer
55 character(len=:), use 'w' not 'R' as fn spec for the length dummy
58 2021-10-19 Tobias Burnus <tobias@codesourcery.com>
61 * trans-expr.c (gfc_conv_procedure_call): Use TREE_OPERAND not
62 build_fold_indirect_ref_loc to undo an ADDR_EXPR.
64 2021-10-18 Tobias Burnus <tobias@codesourcery.com>
73 * decl.c (gfc_verify_c_interop_param): Remove 'sorry' for
74 scalar allocatable/pointer and len=*.
75 * expr.c (is_CFI_desc): Return true for for those.
76 * gfortran.h (CFI_type_kind_shift, CFI_type_mask,
77 CFI_type_from_type_kind, CFI_VERSION, CFI_MAX_RANK,
78 CFI_attribute_pointer, CFI_attribute_allocatable,
79 CFI_attribute_other, CFI_type_Integer, CFI_type_Logical,
80 CFI_type_Real, CFI_type_Complex, CFI_type_Character,
81 CFI_type_ucs4_char, CFI_type_struct, CFI_type_cptr,
82 CFI_type_cfunptr, CFI_type_other): New #define.
83 * trans-array.c (CFI_FIELD_BASE_ADDR, CFI_FIELD_ELEM_LEN,
84 CFI_FIELD_VERSION, CFI_FIELD_RANK, CFI_FIELD_ATTRIBUTE,
85 CFI_FIELD_TYPE, CFI_FIELD_DIM, CFI_DIM_FIELD_LOWER_BOUND,
86 CFI_DIM_FIELD_EXTENT, CFI_DIM_FIELD_SM,
87 gfc_get_cfi_descriptor_field, gfc_get_cfi_desc_base_addr,
88 gfc_get_cfi_desc_elem_len, gfc_get_cfi_desc_version,
89 gfc_get_cfi_desc_rank, gfc_get_cfi_desc_type,
90 gfc_get_cfi_desc_attribute, gfc_get_cfi_dim_item,
91 gfc_get_cfi_dim_lbound, gfc_get_cfi_dim_extent, gfc_get_cfi_dim_sm):
92 New define/functions to access the CFI array descriptor.
93 (gfc_conv_descriptor_type): New function for the GFC descriptor.
94 (gfc_get_array_span): Handle expr of CFI descriptors and
95 assumed-type descriptors.
96 (gfc_trans_array_bounds): Remove 'static'.
97 (gfc_conv_expr_descriptor): For assumed type, use the dtype of
99 (structure_alloc_comps): Remove ' ' inside tabs.
100 * trans-array.h (gfc_trans_array_bounds, gfc_conv_descriptor_type,
101 gfc_get_cfi_desc_base_addr, gfc_get_cfi_desc_elem_len,
102 gfc_get_cfi_desc_version, gfc_get_cfi_desc_rank,
103 gfc_get_cfi_desc_type, gfc_get_cfi_desc_attribute,
104 gfc_get_cfi_dim_lbound, gfc_get_cfi_dim_extent, gfc_get_cfi_dim_sm):
106 * trans-decl.c (gfor_fndecl_cfi_to_gfc, gfor_fndecl_gfc_to_cfi):
108 (gfc_build_builtin_function_decls): Remove their initialization.
109 (gfc_get_symbol_decl, create_function_arglist,
110 gfc_trans_deferred_vars): Update for CFI.
111 (convert_CFI_desc): Remove and replace by ...
112 (gfc_conv_cfi_to_gfc): ... this function
113 (gfc_generate_function_code): Call it; create local GFC var for CFI.
114 * trans-expr.c (gfc_maybe_dereference_var): Handle CFI.
115 (gfc_conv_subref_array_arg): Handle the if-noncontigous-only copy in
116 when the result should be a descriptor.
117 (gfc_conv_gfc_desc_to_cfi_desc): Completely rewritten.
118 (gfc_conv_procedure_call): CFI fixes.
119 * trans-openmp.c (gfc_omp_is_optional_argument,
120 gfc_omp_check_optional_argument): Handle optional
122 * trans-stmt.c (gfc_trans_select_rank_cases): Cleanup, avoid invalid
123 code for allocatable/pointer dummies, which cannot be assumed size.
124 * trans-types.c (gfc_cfi_descriptor_base): New global var.
125 (gfc_get_dtype_rank_type): Skip rank init for rank < 0.
126 (gfc_sym_type): Handle CFI dummies.
127 (gfc_get_function_type): Update call.
128 (gfc_get_cfi_dim_type, gfc_get_cfi_type): New.
129 * trans-types.h (gfc_sym_type): Update prototype.
130 (gfc_get_cfi_type): New prototype.
131 * trans.c (gfc_trans_runtime_check): Make conditions more consistent
132 to avoid '<logical> AND_THEN <long int>' in conditions.
133 * trans.h (gfor_fndecl_cfi_to_gfc, gfor_fndecl_gfc_to_cfi): Remove
134 global-var declaration.
136 2021-10-18 Tobias Burnus <tobias@codesourcery.com>
139 * intrinsic.c (gfc_convert_type_warn): Fix checks by checking CLASS
140 and do typcheck in correct order for type extension.
141 * misc.c (gfc_typename): Print proper not internal CLASS type name.
143 2021-10-15 Harald Anlauf <anlauf@gmx.de>
144 Tobias Burnus <tobias@codesourcery.com>
147 * decl.c (match_clist_expr): Set rank/shape of clist initializer
149 * resolve.c (resolve_structure_cons): In a structure constructor,
150 compare shapes of array components against declared shape.
152 2021-10-14 Harald Anlauf <anlauf@gmx.de>
155 * simplify.c (gfc_simplify_reshape): Replace assert by error
156 message for negative elements in SHAPE array.
158 2021-10-14 Harald Anlauf <anlauf@gmx.de>
161 * check.c (gfc_check_shape): Reorder checks so that invalid KIND
162 arguments can be detected.
164 2021-10-14 Kwok Cheung Yeung <kcy@codesourcery.com>
166 * gfortran.h (enum gfc_statement): Add ST_OMP_DECLARE_VARIANT.
167 (enum gfc_omp_trait_property_kind): New.
168 (struct gfc_omp_trait_property): New.
169 (gfc_get_omp_trait_property): New macro.
170 (struct gfc_omp_selector): New.
171 (gfc_get_omp_selector): New macro.
172 (struct gfc_omp_set_selector): New.
173 (gfc_get_omp_set_selector): New macro.
174 (struct gfc_omp_declare_variant): New.
175 (gfc_get_omp_declare_variant): New macro.
176 (struct gfc_namespace): Add omp_declare_variant field.
177 (gfc_free_omp_declare_variant_list): New prototype.
178 * match.h (gfc_match_omp_declare_variant): New prototype.
179 * openmp.c (gfc_free_omp_trait_property_list): New.
180 (gfc_free_omp_selector_list): New.
181 (gfc_free_omp_set_selector_list): New.
182 (gfc_free_omp_declare_variant_list): New.
183 (gfc_match_omp_clauses): Add extra optional argument. Handle end of
184 clauses for context selectors.
185 (omp_construct_selectors, omp_device_selectors,
186 omp_implementation_selectors, omp_user_selectors): New.
187 (gfc_match_omp_context_selector): New.
188 (gfc_match_omp_context_selector_specification): New.
189 (gfc_match_omp_declare_variant): New.
190 * parse.c: Include tree-core.h and omp-general.h.
191 (decode_omp_directive): Handle 'declare variant'.
192 (case_omp_decl): Include ST_OMP_DECLARE_VARIANT.
193 (gfc_ascii_statement): Handle ST_OMP_DECLARE_VARIANT.
194 (gfc_parse_file): Initialize omp_requires_mask.
195 * symbol.c (gfc_free_namespace): Call
196 gfc_free_omp_declare_variant_list.
197 * trans-decl.c (gfc_get_extern_function_decl): Call
198 gfc_trans_omp_declare_variant.
199 (gfc_create_function_decl): Call gfc_trans_omp_declare_variant.
200 * trans-openmp.c (gfc_trans_omp_declare_variant): New.
201 * trans-stmt.h (gfc_trans_omp_declare_variant): New prototype.
203 2021-10-13 Tobias Burnus <tobias@codesourcery.com>
205 * dump-parse-tree.c (show_omp_clauses): Handle ancestor modifier,
206 avoid ICE for GFC_OMP_ATOMIC_SWAP.
207 * gfortran.h (gfc_omp_clauses): Change 'anecestor' into a bitfield.
209 2021-10-12 Tobias Burnus <tobias@codesourcery.com>
212 * check.c (gfc_check_present): Handle optional CLASS.
213 * interface.c (gfc_compare_actual_formal): Likewise.
214 * trans-array.c (gfc_trans_g77_array): Likewise.
215 * trans-decl.c (gfc_build_dummy_array_decl): Likewise.
216 * trans-types.c (gfc_sym_type): Likewise.
217 * primary.c (gfc_variable_attr): Fixes for dummy and
218 pointer when 'class%_data' is passed.
219 * trans-expr.c (set_dtype_for_unallocated, gfc_conv_procedure_call):
220 For assumed-rank dummy, fix setting rank for dealloc/notassoc actual
221 and setting ubound to -1 for assumed-size actuals.
223 2021-10-10 Harald Anlauf <anlauf@gmx.de>
227 * decl.c (add_init_expr_to_sym): Extend initialization of
228 parameter arrays from scalars to handle derived types.
230 2021-10-09 Harald Anlauf <anlauf@gmx.de>
233 * module.c (read_module): Handle old and new-style relational
234 operators when used in USE module, ONLY: OPERATOR(op).
236 2021-10-08 Sandra Loosemore <sandra@codesourcery.com>
239 * interface.c (gfc_compare_actual_formal): Add diagnostic
240 for F2018:C839. Refactor shared code and fix bugs with class
241 array info lookup, and extend similar diagnostic from PR94110
242 to also cover class types.
244 2021-10-08 Martin Liska <mliska@suse.cz>
246 * options.c (gfc_post_options): Use new macro
249 2021-10-06 Tobias Burnus <tobias@codesourcery.com>
251 * resolve.c (resolve_values): Only show
252 deprecated warning if attr.referenced.
254 2021-10-04 Tobias Burnus <tobias@codesourcery.com>
257 * resolve.c (can_generate_init, resolve_fl_variable_derived,
258 resolve_symbol): Only do initialization with intent(out) if not
259 inside of an interface block.
261 2021-10-01 Martin Sebor <msebor@redhat.com>
264 * array.c: Remove an unnecessary test.
265 * trans-array.c: Same.
267 2021-10-01 Jakub Jelinek <jakub@redhat.com>
269 * gfortran.h (gfc_omp_clauses): Add order_reproducible bitfield.
270 * dump-parse-tree.c (show_omp_clauses): Print REPRODUCIBLE: for it.
271 * openmp.c (gfc_match_omp_clauses): Set order_reproducible for
272 explicit reproducible: modifier.
273 * trans-openmp.c (gfc_trans_omp_clauses): Set
274 OMP_CLAUSE_ORDER_REPRODUCIBLE for order_reproducible.
275 (gfc_split_omp_clauses): Also copy order_reproducible.
277 2021-09-30 Harald Anlauf <anlauf@gmx.de>
280 * simplify.c (simplify_size): Resolve expressions used in array
281 specifications so that SIZE can be simplified.
283 2021-09-30 Harald Anlauf <anlauf@gmx.de>
285 * expr.c: The correct reference to Fortran standard is: F2018:10.1.12.
287 2021-09-30 Tobias Burnus <tobias@codesourcery.com>
291 * trans-intrinsic.c (gfc_conv_same_type_as): Fix handling
293 * trans.h (gfc_vtpr_hash_get): Renamed prototype to ...
294 (gfc_vptr_hash_get): ... this to match function name.
296 2021-09-29 Harald Anlauf <anlauf@gmx.de>
299 * array.c (expand_constructor): Do not dereference NULL pointer.
301 2021-09-27 Tobias Burnus <tobias@codesourcery.com>
304 * trans-array.c (gfc_tree_array_size): New function to
305 find size inline (whole array or one dimension).
306 (array_parameter_size): Use it, take stmt_block as arg.
307 (gfc_conv_array_parameter): Update call.
308 * trans-array.h (gfc_tree_array_size): Add prototype.
309 * trans-decl.c (gfor_fndecl_size0, gfor_fndecl_size1): Remove
311 (gfc_build_intrinsic_function_decls): Remove their initialization.
312 * trans-expr.c (gfc_conv_procedure_call): Update
313 bounds of pointer/allocatable actual args to nonallocatable/nonpointer
314 dummies to be one based.
315 * trans-intrinsic.c (gfc_conv_intrinsic_shape): Fix case for
316 assumed rank with allocatable/pointer dummy.
317 (gfc_conv_intrinsic_size): Update to use inline function.
318 * trans.h (gfor_fndecl_size0, gfor_fndecl_size1): Remove var decl.
320 2021-09-26 Tobias Burnus <tobias@codesourcery.com>
323 * trans-intrinsic.c (gfc_conv_associated): Support assumed-rank
324 'pointer' with scalar/array 'target' argument.
326 2021-09-24 Harald Anlauf <anlauf@gmx.de>
329 * expr.c (is_non_constant_intrinsic): Check for intrinsics
330 excluded in constant expressions (F2018:10.1.2).
331 (gfc_is_constant_expr): Use that check.
333 2021-09-24 Sandra Loosemore <sandra@codesourcery.com>
336 * interface.c (compare_parameter): Enforce F2018 C711.
338 2021-09-24 Tobias Burnus <tobias@codesourcery.com>
341 * scanner.c (load_file): Return void, call (gfc_)fatal_error for
343 (include_line, include_stmt, gfc_new_file): Remove exit call
344 for failed load_file run.
346 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
349 * decl.c (gfc_verify_c_interop_param): Handle F2018 C1557,
352 2021-09-23 Harald Anlauf <anlauf@gmx.de>
353 Tobias Burnus <tobias@codesourcery.com>
356 * trans-intrinsic.c (gfc_conv_allocated): Cleanup. Handle
357 coindexed scalar coarrays.
359 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
362 * interface.c (gfc_compare_actual_formal): Extend existing
363 assumed-type diagnostic to also check for argument with type
366 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
369 * check.c (gfc_check_associated): Allow an assumed-rank
370 array for the pointer argument.
371 * interface.c (compare_parameter): Also give rank mismatch
372 error on assumed-rank array.
374 2021-09-23 Sandra Loosemore <sandra@codesourcery.com>
376 * trans-stmt.c (trans_associate_var): Check that result of
377 GFC_DECL_SAVED_DESCRIPTOR is not null before using it.
379 2021-09-22 Tobias Burnus <tobias@codesourcery.com>
382 * cpp.c (gfc_cpp_register_include_paths, gfc_cpp_post_options):
383 Add new bool verbose_missing_dir_warn argument.
384 * cpp.h (gfc_cpp_post_options): Update prototype.
385 * f95-lang.c (gfc_init): Remove duplicated file-not found diag.
386 * gfortran.h (gfc_check_include_dirs): Takes bool
387 verbose_missing_dir_warn arg.
388 (gfc_new_file): Returns now void.
389 * options.c (gfc_post_options): Update to warn for -I and -J,
390 only, by default but for all when user requested.
391 * scanner.c (gfc_do_check_include_dir):
392 (gfc_do_check_include_dirs, gfc_check_include_dirs): Take bool
393 verbose warn arg and update to avoid printing the same message
395 (load_file): Fix indent.
396 (gfc_new_file): Return void and exit when load_file failed
397 as all other load_file users do.
399 2021-09-22 Tobias Burnus <tobias@codesourcery.com>
401 * trans-expr.c (gfc_simple_for_loop): New.
402 * trans.h (gfc_simple_for_loop): New prototype.
404 2021-09-21 Tobias Burnus <tobias@codesourcery.com>
407 * cpp.c: Define GCC_C_COMMON_C for #include "options.h" to make
408 cpp_reason_option_codes available.
409 (gfc_cpp_register_include_paths): Make static, set pfile's
410 warn_missing_include_dirs and move before caller.
411 (gfc_cpp_init_cb): New, cb code moved from ...
412 (gfc_cpp_init_0): ... here.
413 (gfc_cpp_post_options): Call gfc_cpp_init_cb.
414 (cb_cpp_diagnostic_cpp_option): New. As implemented in c-family
415 to match CppReason flags to -W... names.
416 (cb_cpp_diagnostic): Use it to replace single special case.
417 * cpp.h (gfc_cpp_register_include_paths): Remove as now static.
418 * gfortran.h (gfc_check_include_dirs): New prototype.
419 (gfc_add_include_path): Add new bool arg.
420 * options.c (gfc_init_options): Don't set -Wmissing-include-dirs.
421 (gfc_post_options): Set it here after commandline processing. Call
422 gfc_add_include_path with defer_warn=false.
423 (gfc_handle_option): Call it with defer_warn=true.
424 * scanner.c (gfc_do_check_include_dir, gfc_do_check_include_dirs,
425 gfc_check_include_dirs): New. Diagnostic moved from ...
426 (add_path_to_list): ... here, which came before cmdline processing.
427 Take additional bool defer_warn argument.
428 (gfc_add_include_path): Take additional defer_warn arg.
429 * scanner.h (struct gfc_directorylist): Reorder for alignment issues,
432 2021-09-20 Tobias Burnus <tobias@codesourcery.com>
434 * gfortran.h (gfc_omp_clauses): Add order_unconstrained.
435 * dump-parse-tree.c (show_omp_clauses): Dump it.
436 * openmp.c (gfc_match_omp_clauses): Match unconstrained/reproducible
437 modifiers to ordered(concurrent).
438 (OMP_DISTRIBUTE_CLAUSES): Accept ordered clause.
439 (resolve_omp_clauses): Reject ordered + order on same directive.
440 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses): Pass
441 on unconstrained modifier of ordered(concurrent).
443 2021-09-17 Harald Anlauf <anlauf@gmx.de>
446 * trans-decl.c (gfc_finish_var_decl): Disable the warning message
447 for variables moved from stack to static storange if they are
448 declared in the main, but allow the move to happen.
450 2021-09-17 Sandra Loosemore <sandra@codesourcery.com>
452 * intrinsic.texi (ISO_C_BINDING): Change C_FLOAT128 to correspond
453 to _Float128 rather than __float128.
454 * iso-c-binding.def (c_float128): Update comments.
455 * trans-intrinsic.c (gfc_builtin_decl_for_float_kind): Likewise.
456 (build_round_expr): Likewise.
457 (gfc_build_intrinsic_lib_fndcecls): Likewise.
458 * trans-types.h (gfc_real16_is_float128): Likewise.
460 2021-09-16 Harald Anlauf <anlauf@gmx.de>
463 * trans-expr.c (gfc_conv_procedure_call): Wrap deallocation of
464 allocatable components of optional allocatable derived type
465 procedure arguments with INTENT(OUT) into a presence check.
467 2021-09-14 Harald Anlauf <anlauf@gmx.de>
470 * resolve.c (resolve_entries): Attempt to recover cleanly after
471 rejecting mismatched function entries.
473 2021-09-14 Tobias Burnus <tobias@codesourcery.com>
476 * parse.c (gfc_ascii_statement): Add missing ST_OMP_END_SCOPE.
478 2021-09-13 Harald Anlauf <anlauf@gmx.de>
481 * decl.c (add_init_expr_to_sym): For proper initialization of
482 array-valued named constants the array bounds need to be
483 simplified before adding the initializer.
485 2021-09-13 Harald Anlauf <anlauf@gmx.de>
488 * expr.c (find_substring_ref): Handle given substring start and
489 end indices as signed integers, not unsigned.
491 2021-09-09 Harald Anlauf <anlauf@gmx.de>
494 * trans-expr.c (gfc_conv_substring): Do not generate substring
495 bounds check for implied do loop index variable before it actually
498 2021-09-08 liuhongt <hongtao.liu@intel.com>
500 * options.c (gfc_post_options): Issue an error for
501 -fexcess-precision=16.
503 2021-09-07 Harald Anlauf <anlauf@gmx.de>
506 * expr.c (find_array_element): When bounds cannot be determined as
507 constant, return error instead of aborting.
509 2021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
511 * openmp.c (gfc_match_omp_flush): Parse 'seq_cst' clause on 'flush'
513 * trans-openmp.c (gfc_trans_omp_flush): Handle OMP_MEMORDER_SEQ_CST.
515 2021-09-03 Tobias Burnus <tobias@codesourcery.com>
517 * decl.c (gfc_verify_c_interop_param): Reject pointer with
518 CONTIGUOUS attributes as dummy arg. Reject character len > 1
519 when passed as byte stream.
521 2021-09-01 Harald Anlauf <anlauf@gmx.de>
524 * resolve.c (resolve_common_vars): Fix grammar and improve wording
525 of error message rejecting an unlimited polymorphic in COMMON.
527 2021-08-31 Harald Anlauf <anlauf@gmx.de>
530 * simplify.c (substring_has_constant_len): Minimize checks for
531 substring expressions being allowed.
533 2021-08-31 Marcel Vollweiler <marcel@codesourcery.com>
535 * gfortran.h: Add variable for 'ancestor' in struct gfc_omp_clauses.
536 * openmp.c (gfc_match_omp_clauses): Parse device-modifiers 'device_num'
537 and 'ancestor' in 'target device' clauses.
538 * trans-openmp.c (gfc_trans_omp_clauses): Set OMP_CLAUSE_DEVICE_ANCESTOR.
540 2021-08-30 Harald Anlauf <anlauf@gmx.de>
543 * match.c (gfc_match_goto): Allow for whitespace in parsing list
546 2021-08-30 Harald Anlauf <anlauf@gmx.de>
549 * resolve.c (resolve_allocate_expr): An unlimited polymorphic
550 argument to ALLOCATE must be ALLOCATABLE or a POINTER. Fix the
553 2021-08-28 Harald Anlauf <anlauf@gmx.de>
556 * resolve.c (resolve_entries): For functions of type CHARACTER
557 tighten the checks for matching characteristics.
559 2021-08-25 Lewis Hyatt <lhyatt@gmail.com>
562 * cpp.c (gfc_cpp_post_options): Call new function
563 diagnostic_initialize_input_context().
565 2021-08-24 Harald Anlauf <anlauf@gmx.de>
568 * trans-decl.c (gfc_finish_var_decl): Adjust check to handle
569 implicit SAVE as well as variables in the main program. Improve
570 warning message text.
572 2021-08-23 Tobias Burnus <tobias@codesourcery.com>
574 * openmp.c (gfc_match_dupl_check, gfc_match_dupl_memorder,
575 gfc_match_dupl_atomic): New.
576 (gfc_match_omp_clauses): Use them; remove duplicate
577 'release'/'relaxed' clause matching; improve error dignostic
580 2021-08-23 Tobias Burnus <tobias@codesourcery.com>
582 * dump-parse-tree.c (show_omp_clauses): Handle 'strict' modifier
583 on grainsize/num_tasks
584 * gfortran.h (gfc_omp_clauses): Add grainsize_strict
585 and num_tasks_strict.
586 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses):
587 Handle 'strict' modifier on grainsize/num_tasks.
588 * openmp.c (gfc_match_omp_clauses): Likewise.
590 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
593 (error_uinteger): Take 'long long unsigned' instead
594 of 'long unsigned' as argumpent.
595 (error_integer): Take 'long long' instead of 'long'.
596 (error_hwuint, error_hwint): New.
597 (error_print): Update to handle 'll' and 'w'
599 * simplify.c (substring_has_constant_len): Use '%wd'
602 2021-08-20 Harald Anlauf <anlauf@gmx.de>
605 * simplify.c (substring_has_constant_len): Fix format string of
606 gfc_error, pass HOST_WIDE_INT bounds values via char buffer.
608 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
610 * dump-parse-tree.c (show_omp_clauses): Handle 'at', 'severity'
611 and 'message' clauses.
612 (show_omp_node, show_code_node): Handle EXEC_OMP_ERROR.
613 * gfortran.h (gfc_statement): Add ST_OMP_ERROR.
614 (gfc_omp_severity_type, gfc_omp_at_type): New.
615 (gfc_omp_clauses): Add 'at', 'severity' and 'message' clause;
616 use more bitfields + ENUM_BITFIELD.
617 (gfc_exec_op): Add EXEC_OMP_ERROR.
618 * match.h (gfc_match_omp_error): New.
619 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_(AT,SEVERITY,MESSAGE).
620 (gfc_match_omp_clauses): Handle new clauses.
621 (OMP_ERROR_CLAUSES, gfc_match_omp_error): New.
622 (resolve_omp_clauses): Resolve new clauses.
623 (omp_code_to_statement, gfc_resolve_omp_directive): Handle
625 * parse.c (decode_omp_directive, next_statement,
626 gfc_ascii_statement): Handle 'omp error'.
627 * resolve.c (gfc_resolve_blocks): Likewise.
628 * st.c (gfc_free_statement): Likewise.
629 * trans-openmp.c (gfc_trans_omp_error): Likewise.
630 (gfc_trans_omp_directive): Likewise.
631 * trans.c (trans_code): Likewise.
633 2021-08-20 Jakub Jelinek <jakub@redhat.com>
635 * types.def (BT_FN_VOID_CONST_PTR_SIZE): New DEF_FUNCTION_TYPE_2.
636 * f95-lang.c (ATTR_COLD_NORETURN_NOTHROW_LEAF_LIST): Define.
638 2021-08-19 Harald Anlauf <anlauf@gmx.de>
641 * simplify.c (substring_has_constant_len): New.
642 (gfc_simplify_len): Handle case of substrings with constant
645 2021-08-18 Tobias Burnus <tobias@codesourcery.com>
647 * match.h (gfc_match_omp_nothing): New.
648 * openmp.c (gfc_match_omp_nothing): New.
649 * parse.c (decode_omp_directive): Match 'nothing' directive.
651 2021-08-17 Tobias Burnus <tobias@codesourcery.com>
653 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
655 * gfortran.h (enum gfc_statement): Add ST_OMP_(END_)SCOPE.
656 (enum gfc_exec_op): Add EXEC_OMP_SCOPE.
657 * match.h (gfc_match_omp_scope): New.
658 * openmp.c (OMP_SCOPE_CLAUSES): Define
659 (gfc_match_omp_scope): New.
660 (gfc_match_omp_cancellation_point, gfc_match_omp_end_nowait):
661 Improve error diagnostic.
662 (omp_code_to_statement): Handle ST_OMP_SCOPE.
663 (gfc_resolve_omp_directive): Handle EXEC_OMP_SCOPE.
664 * parse.c (decode_omp_directive, next_statement,
665 gfc_ascii_statement, parse_omp_structured_block,
666 parse_executable): Handle OpenMP's scope construct.
667 * resolve.c (gfc_resolve_blocks): Likewise
668 * st.c (gfc_free_statement): Likewise
669 * trans-openmp.c (gfc_trans_omp_scope): New.
670 (gfc_trans_omp_directive): Call it.
671 * trans.c (trans_code): handle EXEC_OMP_SCOPE.
673 2021-08-16 Tobias Burnus <tobias@codesourcery.com>
675 * dump-parse-tree.c (show_omp_clauses): Handle 'filter' clause.
676 (show_omp_node, show_code_node): Handle (combined) omp masked construct.
677 * frontend-passes.c (gfc_code_walker): Likewise.
678 * gfortran.h (enum gfc_statement): Add ST_OMP_*_MASKED*.
679 (enum gfc_exec_op): Add EXEC_OMP_*_MASKED*.
680 * match.h (gfc_match_omp_masked, gfc_match_omp_masked_taskloop,
681 gfc_match_omp_masked_taskloop_simd, gfc_match_omp_parallel_masked,
682 gfc_match_omp_parallel_masked_taskloop,
683 gfc_match_omp_parallel_masked_taskloop_simd): New prototypes.
684 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_FILTER.
685 (gfc_match_omp_clauses): Match it.
686 (OMP_MASKED_CLAUSES, gfc_match_omp_parallel_masked,
687 gfc_match_omp_parallel_masked_taskloop,
688 gfc_match_omp_parallel_masked_taskloop_simd,
689 gfc_match_omp_masked, gfc_match_omp_masked_taskloop,
690 gfc_match_omp_masked_taskloop_simd): New.
691 (resolve_omp_clauses): Resolve filter clause.
692 (gfc_resolve_omp_parallel_blocks, resolve_omp_do,
693 omp_code_to_statement, gfc_resolve_omp_directive): Handle
694 omp masked constructs.
695 * parse.c (decode_omp_directive, case_exec_markers,
696 gfc_ascii_statement, parse_omp_do, parse_omp_structured_block,
697 parse_executable): Likewise.
698 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
699 * st.c (gfc_free_statement): Likewise.
700 * trans-openmp.c (gfc_trans_omp_clauses): Handle filter clause.
701 (GFC_OMP_SPLIT_MASKED, GFC_OMP_MASK_MASKED): New enum values.
702 (gfc_trans_omp_masked): New.
703 (gfc_split_omp_clauses): Handle combined masked directives.
704 (gfc_trans_omp_master_taskloop): Rename to ...
705 (gfc_trans_omp_master_masked_taskloop): ... this; handle also
706 combined masked directives.
707 (gfc_trans_omp_parallel_master): Rename to ...
708 (gfc_trans_omp_parallel_master_masked): ... this; handle
709 combined masked directives.
710 (gfc_trans_omp_directive): Handle EXEC_OMP_*_MASKED*.
711 * trans.c (trans_code): Likewise.
713 2021-08-15 Harald Anlauf <anlauf@gmx.de>
716 * match.c (sync_statement): Replace %v code by %e in gfc_match to
717 allow for function references as STAT and ERRMSG arguments.
718 * resolve.c (resolve_sync): Adjust checks of STAT= and ERRMSG= to
719 being definable arguments. Function references with a data
720 pointer result are accepted.
721 * trans-stmt.c (gfc_trans_sync): Adjust assertion.
723 2021-08-12 Tobias Burnus <tobias@codesourcery.com>
725 * gfortran.h (gfc_omp_proc_bind_kind): Add OMP_PROC_BIND_PRIMARY.
726 * dump-parse-tree.c (show_omp_clauses): Add TODO comment to
727 change 'master' to 'primary' in proc_bind for OpenMP 5.1.
728 * intrinsic.texi (OMP_LIB): Mention OpenMP 5.1; add
729 omp_proc_bind_primary.
730 * openmp.c (gfc_match_omp_clauses): Accept
731 'primary' as alias for 'master'.
732 * trans-openmp.c (gfc_trans_omp_clauses): Handle
733 OMP_PROC_BIND_PRIMARY.
735 2021-08-11 Sandra Loosemore <sandra@codesourcery.com>
737 * iso-c-binding.def (c_float128, c_float128_complex): Check
738 float128_type_node instead of gfc_float128_type_node.
739 * trans-types.c (gfc_init_kinds, gfc_build_real_type):
740 Update comments re supported 128-bit floating-point types.
742 2021-08-11 Richard Biener <rguenther@suse.de>
744 * trans-common.c (create_common): Set TREE_THIS_VOLATILE on the
745 COMPONENT_REF if the field is volatile.
747 2021-08-07 Harald Anlauf <anlauf@gmx.de>
750 * primary.c (gfc_expr_attr): Variable attribute can only be
751 inquired when symtree is non-NULL.
753 2021-07-28 Harald Anlauf <anlauf@gmx.de>
756 * expr.c (gfc_check_vardef_context): Add check for KIND and LEN
758 * match.c (gfc_match): Fix comment for %v code.
759 (gfc_match_allocate, gfc_match_deallocate): Replace use of %v code
760 by %e in gfc_match to allow for function references as STAT and
762 * resolve.c (resolve_allocate_deallocate): Avoid NULL pointer
763 dereferences and shortcut for bad STAT and ERRMSG argument to
764 (DE)ALLOCATE. Remove bogus parts of checks for STAT and ERRMSG.
766 2021-07-26 José Rui Faustino de Sousa <jrfsousa@gmail.com>
767 Tobias Burnus <tobias@codesourcery.com>
774 * trans-decl.c (convert_CFI_desc): Only copy out the descriptor
776 * trans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): Updated attribute
777 handling which reflect a previous intermediate version of the
778 standard. Only copy out the descriptor if necessary.
780 2021-07-23 Harald Anlauf <anlauf@gmx.de>
783 * check.c (array_check): Adjust check for the case of CLASS
786 2021-07-21 Thomas Schwinge <thomas@codesourcery.com>
787 Joseph Myers <joseph@codesourcery.com>
788 Cesar Philippidis <cesar@codesourcery.com>
790 * dump-parse-tree.c (show_attr): Update.
791 * gfortran.h (symbol_attribute): Add 'oacc_routine_nohost' member.
792 (gfc_omp_clauses): Add 'nohost' member.
793 * module.c (ab_attribute): Add 'AB_OACC_ROUTINE_NOHOST'.
794 (attr_bits, mio_symbol_attribute): Update.
795 * openmp.c (omp_mask2): Add 'OMP_CLAUSE_NOHOST'.
796 (gfc_match_omp_clauses): Handle 'OMP_CLAUSE_NOHOST'.
797 (OACC_ROUTINE_CLAUSES): Add 'OMP_CLAUSE_NOHOST'.
798 (gfc_match_oacc_routine): Update.
799 * trans-decl.c (add_attributes_to_decl): Update.
800 * trans-openmp.c (gfc_trans_omp_clauses): Likewise.
802 2021-07-21 Harald Anlauf <anlauf@gmx.de>
805 * target-memory.c (gfc_interpret_derived): Size of array component
806 of derived type can only be computed here for explicit shape.
807 * trans-types.c (gfc_get_nodesc_array_type): Do not dereference
810 2021-07-21 Tobias Burnus <tobias@codesourcery.com>
812 * decl.c (gfc_verify_c_interop_param): Update for F2008 + F2018
813 changes; reject unsupported bits with 'Error: Sorry,'.
814 * trans-expr.c (gfc_conv_procedure_call): Fix condition to
815 For using CFI descriptor with characters.
817 2021-07-18 Harald Anlauf <anlauf@gmx.de>
820 * io.c (resolve_tag_format): Extend FORMAT check to unknown type.
822 2021-07-14 Harald Anlauf <anlauf@gmx.de>
825 * trans-expr.c (gfc_trans_class_init_assign): Call
826 gfc_conv_expr_present only for dummy variables.
828 2021-07-06 Thomas Koenig <tkoenig@gcc.gnu.org>
831 * frontend-passes.c (traverse_io_block): Adjust test for
832 when a variable is eligible for the transformation to
835 2021-06-28 Martin Sebor <msebor@redhat.com>
837 * trans-array.c (trans_array_constructor): Replace direct uses
838 of TREE_NO_WARNING with warning_suppressed_p, and suppress_warning.
839 * trans-decl.c (gfc_build_qualified_array): Same.
840 (gfc_build_dummy_array_decl): Same.
841 (generate_local_decl): Same.
842 (gfc_generate_function_code): Same.
843 * trans-openmp.c (gfc_omp_clause_default_ctor): Same.
844 (gfc_omp_clause_copy_ctor): Same.
845 * trans-types.c (get_dtype_type_node): Same.
846 (gfc_get_desc_dim_type): Same.
847 (gfc_get_array_descriptor_base): Same.
848 (gfc_get_caf_vector_type): Same.
849 (gfc_get_caf_reference_type): Same.
850 * trans.c (gfc_create_var_np): Same.
852 2021-06-23 Tobias Burnus <tobias@codesourcery.com>
854 * dump-parse-tree.c (show_omp_clauses): Fix enum type used
855 for dumping gfc_omp_defaultmap_category.
857 2021-06-23 Andre Vehreschild <vehre@gcc.gnu.org>
860 * trans-intrinsic.c (conv_co_collective): Check stat for null ptr
861 before dereferrencing.
863 2021-06-18 Harald Anlauf <anlauf@gmx.de>
867 * trans-intrinsic.c (gfc_conv_intrinsic_minmax): Unconditionally
868 convert result of min/max to result type.
870 2021-06-16 Harald Anlauf <anlauf@gmx.de>
874 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
876 * match.c (gfc_match_pointer_assignment): Likewise.
877 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
880 2021-06-16 Harald Anlauf <anlauf@gmx.de>
883 2021-06-16 Harald Anlauf <anlauf@gmx.de>
887 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
889 * match.c (gfc_match_pointer_assignment): Likewise.
890 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
893 2021-06-16 Harald Anlauf <anlauf@gmx.de>
897 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
899 * match.c (gfc_match_pointer_assignment): Likewise.
900 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
903 2021-06-15 Tobias Burnus <tobias@codesourcery.com>
906 * dump-parse-tree.c (show_omp_clauses): Update for defaultmap.
907 * f95-lang.c (LANG_HOOKS_OMP_ALLOCATABLE_P,
908 LANG_HOOKS_OMP_SCALAR_TARGET_P): New.
909 * gfortran.h (enum gfc_omp_defaultmap,
910 enum gfc_omp_defaultmap_category): New.
911 * openmp.c (gfc_match_omp_clauses): Update defaultmap matching.
912 * trans-decl.c (gfc_finish_decl_attrs): Set GFC_DECL_SCALAR_TARGET.
913 * trans-openmp.c (gfc_omp_allocatable_p, gfc_omp_scalar_target_p): New.
914 (gfc_omp_scalar_p): Take 'ptr_alloc_ok' argument.
915 (gfc_trans_omp_clauses, gfc_split_omp_clauses): Update for
917 * trans.h (gfc_omp_scalar_p): Update prototype.
918 (gfc_omp_allocatable_p, gfc_omp_scalar_target_p): New.
919 (struct lang_decl): Add scalar_target.
920 (GFC_DECL_SCALAR_TARGET, GFC_DECL_GET_SCALAR_TARGET): New.
922 2021-06-14 Tobias Burnus <tobias@codesourcery.com>
924 * resolve.c (resolve_variable): Remove *XCNEW used to
925 nullify nullified memory.
927 2021-06-09 Martin Liska <mliska@suse.cz>
929 * intrinsic.texi: Add missing @headitem to tables with a header.
931 2021-06-09 Jakub Jelinek <jakub@redhat.com>
934 * trans-openmp.c (gfc_omp_finish_clause): Gimplify OMP_CLAUSE_SIZE.
936 2021-06-08 Tobias Burnus <tobias@codesourcery.com>
939 * trans-openmp.c (gfc_add_clause_implicitly): New.
940 (gfc_split_omp_clauses): Use it.
941 (gfc_free_split_omp_clauses): New.
942 (gfc_trans_omp_do_simd, gfc_trans_omp_parallel_do,
943 gfc_trans_omp_parallel_do_simd, gfc_trans_omp_distribute,
944 gfc_trans_omp_teams, gfc_trans_omp_target, gfc_trans_omp_taskloop,
945 gfc_trans_omp_master_taskloop, gfc_trans_omp_parallel_master): Use it.
947 2021-06-08 Martin Liska <mliska@suse.cz>
949 * intrinsic.texi: Fix typo.
950 * trans-expr.c (gfc_trans_pointer_assignment): Likewise.
952 2021-06-05 José Rui Faustino de Sousa <jrfsousa@gmail.com>
959 * trans-array.c (gfc_get_array_span): rework the way character
960 array "span" was calculated.
961 (gfc_conv_expr_descriptor): improve handling of character sections
962 and unlimited polymorphic objects.
963 * trans-expr.c (gfc_get_character_len): new function to calculate
964 character string length.
965 (gfc_get_character_len_in_bytes): new function to calculate
966 character string length in bytes.
967 (gfc_conv_scalar_to_descriptor): add call to set the "span".
968 (gfc_trans_pointer_assignment): set "_len" and antecipate the
969 initialization of the deferred character length hidden argument.
970 * trans-intrinsic.c (gfc_conv_associated): set "force_no_tmp" to
971 avoid the creation of a temporary.
972 * trans-types.c (gfc_get_dtype_rank_type): rework type detection
973 so that unlimited polymorphic objects get proper type infomation,
974 also important for bind(c).
975 (gfc_get_dtype): add argument to pass the rank if necessary.
976 (gfc_get_array_type_bounds): cosmetic change to have character
977 arrays called character instead of unknown.
978 * trans-types.h (gfc_get_dtype): modify prototype.
979 * trans.c (get_array_span): rework the way character array "span"
981 * trans.h (gfc_get_character_len): new prototype.
982 (gfc_get_character_len_in_bytes): new prototype.
983 Add "unlimited_polymorphic" flag to "gfc_se" type to signal when
984 expression carries an unlimited polymorphic object.
986 2021-06-04 Harald Anlauf <anlauf@gmx.de>
989 * frontend-passes.c (inline_matmul_assign): Do not inline matmul
990 if the assignment to the resulting array if it is not of canonical
991 type (real/integer/complex/logical).
993 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
995 * dump-parse-tree.c (show_code_node): Handle
996 EXEC_OMP_(TARGET_)(,PARALLEL_,TEAMS_)LOOP.
998 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1000 * scanner.c (skip_fixed_omp_sentinel): Set openacc_flag if
1001 this is not an (OpenMP) continuation line.
1002 (skip_fixed_oacc_sentinel): Likewise for openmp_flag and OpenACC.
1003 (gfc_next_char_literal): gfc_error_now to force error for mixed OMP/ACC
1004 continuation once per location and return '\n'.
1006 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1009 * openmp.c (gfc_match_omp_clauses): Fix typo in error message.
1011 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
1014 * dump-parse-tree.c (show_omp_clauses): Handle bind clause.
1015 (show_omp_node): Handle loop directive.
1016 * frontend-passes.c (gfc_code_walker): Likewise.
1017 * gfortran.h (enum gfc_statement): Add
1018 ST_OMP_(END_)(TARGET_)(|PARALLEL_|TEAMS_)LOOP.
1019 (enum gfc_omp_bind_type): New.
1020 (gfc_omp_clauses): Use it.
1021 (enum gfc_exec_op): Add EXEC_OMP_(TARGET_)(|PARALLEL_|TEAMS_)LOOP.
1022 * match.h (gfc_match_omp_loop, gfc_match_omp_parallel_loop,
1023 gfc_match_omp_target_parallel_loop, gfc_match_omp_target_teams_loop,
1024 gfc_match_omp_teams_loop): New.
1025 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_BIND.
1026 (gfc_match_omp_clauses): Handle it.
1027 (OMP_LOOP_CLAUSES, gfc_match_omp_loop, gfc_match_omp_teams_loop,
1028 gfc_match_omp_target_teams_loop, gfc_match_omp_parallel_loop,
1029 gfc_match_omp_target_parallel_loop): New.
1030 (resolve_omp_clauses, resolve_omp_do, omp_code_to_statement,
1031 gfc_resolve_omp_directive): Handle omp loop.
1032 * parse.c (decode_omp_directive case_exec_markers, gfc_ascii_statement,
1033 parse_omp_do, parse_executable): Likewise.
1034 (parse_omp_structured_block): Remove ST_ which use parse_omp_do.
1035 * resolve.c (gfc_resolve_blocks): Add omp loop.
1036 * st.c (gfc_free_statement): Likewise.
1037 * trans-openmp.c (gfc_trans_omp_clauses): Handle bind clause.
1038 (gfc_trans_omp_do, gfc_trans_omp_parallel_do, gfc_trans_omp_distribute,
1039 gfc_trans_omp_teams, gfc_trans_omp_target, gfc_trans_omp_directive):
1040 Handle loop directive.
1041 (gfc_split_omp_clauses): Likewise; fix firstprivate/lastprivate
1042 and (in_)reduction for taskloop.
1043 * trans.c (trans_code): Handle omp loop directive.
1045 2021-06-01 Tobias Burnus <tobias@codesourcery.com>
1048 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
1049 (parallel) master taskloop (simd).
1050 * frontend-passes.c (gfc_code_walker): Set in_omp_workshare
1051 to false for parallel master taskloop (simd).
1052 * gfortran.h (enum gfc_statement):
1053 Add ST_OMP_(END_)(PARALLEL_)MASTER_TASKLOOP(_SIMD).
1054 (enum gfc_exec_op): EXEC_OMP_(PARALLEL_)MASTER_TASKLOOP(_SIMD).
1055 * match.h (gfc_match_omp_master_taskloop,
1056 gfc_match_omp_master_taskloop_simd,
1057 gfc_match_omp_parallel_master_taskloop,
1058 gfc_match_omp_parallel_master_taskloop_simd): New prototype.
1059 * openmp.c (gfc_match_omp_parallel_master_taskloop,
1060 gfc_match_omp_parallel_master_taskloop_simd,
1061 gfc_match_omp_master_taskloop,
1062 gfc_match_omp_master_taskloop_simd): New.
1063 (gfc_match_omp_taskloop_simd): Permit 'reduction' clause.
1064 (resolve_omp_clauses): Handle new combined directives; remove
1065 inscan-reduction check to reduce multiple errors; add
1066 task-reduction error for 'taskloop simd'.
1067 (gfc_resolve_omp_parallel_blocks,
1068 resolve_omp_do, omp_code_to_statement,
1069 gfc_resolve_omp_directive): Handle new combined constructs.
1070 * parse.c (decode_omp_directive, next_statement,
1071 gfc_ascii_statement, parse_omp_do, parse_omp_structured_block,
1072 parse_executable): Likewise.
1073 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
1074 * st.c (gfc_free_statement): Likewise.
1075 * trans.c (trans_code): Likewise.
1076 * trans-openmp.c (gfc_split_omp_clauses,
1077 gfc_trans_omp_directive): Likewise.
1078 (gfc_trans_omp_parallel_master): Move after gfc_trans_omp_master_taskloop;
1079 handle parallel master taskloop (simd) as well.
1080 (gfc_trans_omp_taskloop): Take gfc_exec_op as arg.
1081 (gfc_trans_omp_master_taskloop): New.
1083 2021-05-30 Gerald Pfeifer <gerald@pfeifer.com>
1085 * gfortran.texi (BOZ literal constants): Fix typo.
1087 2021-05-28 Tobias Burnus <tobias@codesourcery.com>
1089 * dump-parse-tree.c (show_iterator): New.
1090 (show_omp_namelist): Handle iterators.
1091 (show_omp_clauses): Handle affinity.
1092 * gfortran.h (gfc_free_omp_namelist): New union with 'udr' and new 'ns'.
1093 * match.c (gfc_free_omp_namelist): Add are to choose union element.
1094 * openmp.c (gfc_free_omp_clauses, gfc_match_omp_detach,
1095 gfc_match_omp_clause_reduction, gfc_match_omp_flush): Update
1096 call to gfc_free_omp_namelist.
1097 (gfc_match_omp_variable_list): Likewise; permit preceeding whitespace.
1098 (enum omp_mask1): Add OMP_CLAUSE_AFFINITY.
1099 (gfc_match_iterator): New.
1100 (gfc_match_omp_clauses): Use it; update call to gfc_free_omp_namelist.
1101 (OMP_TASK_CLAUSES): Add OMP_CLAUSE_AFFINITY.
1102 (gfc_match_omp_taskwait): Match depend clause.
1103 (resolve_omp_clauses): Handle affinity; update for udr/union change.
1104 (gfc_resolve_omp_directive): Resolve clauses of taskwait.
1105 * st.c (gfc_free_statement): Update gfc_free_omp_namelist call.
1106 * trans-openmp.c (gfc_trans_omp_array_reduction_or_udr): Likewise
1107 (handle_iterator): New.
1108 (gfc_trans_omp_clauses): Handle iterators for depend/affinity clause.
1109 (gfc_trans_omp_taskwait): Handle depend clause.
1110 (gfc_trans_omp_directive): Update call.
1112 2021-05-27 Harald Anlauf <anlauf@gmx.de>
1115 * trans-intrinsic.c (gfc_conv_intrinsic_size): Use CLASS data
1116 attributes for CLASS arrays for generation of runtime error.
1118 2021-05-27 Harald Anlauf <anlauf@gmx.de>
1121 * trans-array.c (gfc_conv_ss_startstride): Do not call check for
1122 presence of a dummy argument when a symbol actually refers to a
1125 2021-05-25 Tobias Burnus <tobias@codesourcery.com>
1126 Johannes Nendwich <a08727063@unet.univie.ac.at>
1128 * intrinsic.texi (GERROR, GETARGS, GETLOG, NORM2, PARITY, RANDOM_INIT,
1129 RANDOM_NUMBER): Fix typos and copy'n'paste errors.
1131 2021-05-24 Tobias Burnus <tobias@codesourcery.com>
1134 * trans-expr.c (gfc_copy_class_to_class): Add unshare_expr.
1135 * trans-openmp.c (gfc_is_polymorphic_nonptr,
1136 gfc_is_unlimited_polymorphic_nonptr): New.
1137 (gfc_omp_clause_copy_ctor, gfc_omp_clause_dtor): Handle
1138 polymorphic scalars.
1140 2021-05-23 Harald Anlauf <anlauf@gmx.de>
1143 * trans-expr.c (gfc_conv_procedure_call): Adjust check for
1144 implicit conversion of actual argument to an unlimited polymorphic
1147 2021-05-23 Tobias Burnus <tobias@codesourcery.com>
1149 * intrinsic.texi (ATOMIC_ADD, ATOMIC_FETCH_ADD): Use the
1150 proper variable name in the description.
1152 2021-05-22 Andre Vehreschild <vehre@gcc.gnu.org>
1153 Steve Kargl <kargl@gcc.gnu.org>
1156 * trans-decl.c (gfc_build_builtin_function_decls): Move decl.
1157 * trans-intrinsic.c (conv_intrinsic_random_init): Use bool for
1158 lib-call of caf_random_init instead of logical (4-byte).
1159 * trans.h: Add tree var for random_init.
1161 2021-05-20 Marcel Vollweiler <marcel@codesourcery.com>
1163 * openmp.c (gfc_match_omp_clauses): Support map-type-modifier 'close'.
1165 2021-05-18 Tobias Burnus <tobias@codesourcery.com>
1168 * openmp.c (omp_code_to_statement): Add missing EXEC_OMP_DEPOBJ.
1170 2021-05-17 Harald Anlauf <anlauf@gmx.de>
1173 * trans-decl.c (gfc_finish_var_decl): Add check for explicit SAVE
1176 2021-05-17 Tobias Burnus <tobias@codesourcery.com>
1179 * resolve.c (gfc_resolve_code): Reject nonintrinsic assignments in
1182 2021-05-14 Tobias Burnus <tobias@codesourcery.com>
1184 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
1185 EXEC_OMP_PARALLEL_MASTER.
1186 * frontend-passes.c (gfc_code_walker): Likewise.
1187 * gfortran.h (enum gfc_statement): Add ST_OMP_PARALLEL_MASTER and
1188 ST_OMP_END_PARALLEL_MASTER.
1189 (enum gfc_exec_op): Add EXEC_OMP_PARALLEL_MASTER..
1190 * match.h (gfc_match_omp_parallel_master): Handle it.
1191 * openmp.c (gfc_match_omp_parallel_master, resolve_omp_clauses,
1192 omp_code_to_statement, gfc_resolve_omp_directive): Likewise.
1193 * parse.c (decode_omp_directive, case_exec_markers,
1194 gfc_ascii_statement, parse_omp_structured_block,
1195 parse_executable): Likewise.
1196 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
1197 * st.c (gfc_free_statement): Likewise.
1198 * trans-openmp.c (gfc_trans_omp_parallel_master,
1199 gfc_trans_omp_workshare, gfc_trans_omp_directive): Likewise.
1200 * trans.c (trans_code): Likewise.
1202 2021-05-14 Tobias Burnus <tobias@codesourcery.com>
1204 * resolve.c (resolve_symbol): Handle implicit SAVE of main-program
1205 for vars in 'omp threadprivate' and 'omp declare target'.
1207 2021-05-10 Martin Liska <mliska@suse.cz>
1209 * decl.c (variable_decl): Use startswith
1210 function instead of strncmp.
1211 (gfc_match_end): Likewise.
1212 * gfortran.h (gfc_str_startswith): Likewise.
1213 * module.c (load_omp_udrs): Likewise.
1214 (read_module): Likewise.
1215 * options.c (gfc_handle_runtime_check_option): Likewise.
1216 * primary.c (match_arg_list_function): Likewise.
1217 * trans-decl.c (gfc_get_symbol_decl): Likewise.
1218 * trans-expr.c (gfc_conv_procedure_call): Likewise.
1219 * trans-intrinsic.c (gfc_conv_ieee_arithmetic_function): Likewise.
1221 2021-05-06 Paul Thomas <pault@gcc.gnu.org>
1225 * class.c (gfc_build_class_symbol): Remove the error that
1226 disables assumed size class arrays. Class array types that are
1227 not deferred shape or assumed rank are given a unique name and
1228 placed in the procedure namespace.
1229 * trans-array.c (gfc_trans_g77_array): Obtain the data pointer
1231 (gfc_trans_dummy_array_bias): Suppress the runtime error for
1232 extent violations in explicit shape class arrays because it
1234 * trans-expr.c (gfc_conv_procedure_call): Handle assumed size
1235 class actual arguments passed to non-descriptor formal args by
1236 using the data pointer, stored as the symbol's backend decl.
1238 2021-05-05 Harald Anlauf <anlauf@gmx.de>
1241 * interface.c (gfc_compare_actual_formal): Continue checks after
1242 emitting warning for argument length mismatch.
1243 * trans-expr.c (gfc_conv_procedure_call): Check for NULL pointer
1246 2021-05-04 Tobias Burnus <tobias@codesourcery.com>
1249 * trans-openmp.c (gfc_trans_omp_depobj): Fix pasto in enum values.
1251 2021-04-28 Tobias Burnus <tobias@codesourcery.com>
1253 * openmp.c (gfc_match_omp_variable_list): Gobble whitespace before
1254 checking whether a '%' or parenthesis-open follows as next character.
1256 2021-04-28 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1259 * trans-expr.c (gfc_conv_procedure_call): Evaluate function result
1260 and then pass a pointer.
1262 2021-04-26 Thomas Schwinge <thomas@codesourcery.com>
1263 Nathan Sidwell <nathan@codesourcery.com>
1264 Tom de Vries <vries@codesourcery.com>
1265 Julian Brown <julian@codesourcery.com>
1266 Kwok Cheung Yeung <kcy@codesourcery.com>
1268 * lang.opt (Wopenacc-parallelism): New.
1270 2021-04-24 Harald Anlauf <anlauf@gmx.de>
1273 * check.c (variable_check): Allow function reference having a data
1275 (arg_strlen_is_zero): New function.
1276 (gfc_check_fgetputc_sub): Add static check of character and status
1278 (gfc_check_fgetput_sub): Likewise.
1279 * intrinsic.c (add_subroutines): Fix argument name for the
1280 character argument to intrinsic subroutines fget[c], fput[c].
1282 2021-04-24 Harald Anlauf <anlauf@gmx.de>
1285 * expr.c (gfc_check_vardef_context): Extend check to allow pointer
1286 from a function reference.
1288 2021-04-22 Martin Liska <mliska@suse.cz>
1292 * frontend-passes.c (optimize_expr): Fix typos and missing comments.
1294 2021-04-22 Michael Meissner <meissner@linux.ibm.com>
1297 * trans-intrinsic.c (build_round_expr): If int type is larger than
1298 long long, do the round and convert to the integer type. Do not
1299 try to find a floating point type the exact size of the integer
1302 2021-04-21 Tobias Burnus <tobias@codesourcery.com>
1304 * dump-parse-tree.c (show_omp_namelist): Handle depobj + mutexinoutset
1305 in the depend clause.
1306 (show_omp_clauses, show_omp_node, show_code_node): Handle depobj.
1307 * gfortran.h (enum gfc_statement): Add ST_OMP_DEPOBJ.
1308 (enum gfc_omp_depend_op): Add OMP_DEPEND_UNSET,
1309 OMP_DEPEND_MUTEXINOUTSET and OMP_DEPEND_DEPOBJ.
1310 (gfc_omp_clauses): Add destroy, depobj_update and depobj.
1311 (enum gfc_exec_op): Add EXEC_OMP_DEPOBJ
1312 * match.h (gfc_match_omp_depobj): Match 'omp depobj'.
1313 * openmp.c (gfc_match_omp_clauses): Add depobj + mutexinoutset
1315 (gfc_match_omp_depobj, resolve_omp_clauses, gfc_resolve_omp_directive):
1316 Handle 'omp depobj'.
1317 * parse.c (decode_omp_directive, next_statement, gfc_ascii_statement):
1319 * resolve.c (gfc_resolve_code): Likewise.
1320 * st.c (gfc_free_statement): Likewise.
1321 * trans-openmp.c (gfc_trans_omp_clauses): Handle depobj + mutexinoutset
1322 in the depend clause.
1323 (gfc_trans_omp_depobj, gfc_trans_omp_directive): Handle EXEC_OMP_DEPOBJ.
1324 * trans.c (trans_code): Likewise.
1326 2021-04-20 Paul Thomas <pault@gcc.gnu.org>
1329 * trans-decl.c (gfc_get_symbol_decl): Replace test for host
1330 association with a check that the current and symbol namespaces
1333 2021-04-19 Thomas Schwinge <thomas@codesourcery.com>
1335 * lang.opt (fopenacc-kernels=): Remove.
1337 2021-04-16 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1340 * trans-array.c (gfc_trans_deferred_array): Add code to initialize
1341 pointers and allocatables with correct TKR parameters.
1343 2021-04-16 José Rui Faustino de Sousa <jrfsousa@gmail.com>
1346 * resolve.c: Add association check before de-referencing pointer.
1348 2021-04-16 Harald Anlauf <anlauf@gmx.de>
1349 Paul Thomas <pault@gcc.gnu.org>
1352 * module.c (write_symtree): Do not write interface of intrinsic
1353 procedure to module file for F2003 and newer.
1355 2021-04-15 Paul Thomas <pault@gcc.gnu.org>
1358 * symbol.c: Remove trailing white space.
1359 * trans-array.c (gfc_trans_create_temp_array): Create a class
1360 temporary for class expressions and assign the new descriptor
1362 (build_class_array_ref): If the class expr can be extracted,
1363 then use that for 'decl'. Class function results are reliably
1364 handled this way. Call gfc_find_and_cut_at_last_class_ref to
1365 eliminate largely redundant code. Remove dead code and recast
1366 the rest of the code to extract 'decl' for remaining cases.
1367 Call gfc_build_spanned_array_ref.
1368 (gfc_alloc_allocatable_for_assignment): Use class descriptor
1369 element length for 'elemsize1'. Eliminate repeat set of dtype
1370 for class expressions.
1371 * trans-expr.c (gfc_find_and_cut_at_last_class_ref): Include
1372 additional code from build_class_array_ref, and use optional
1373 gfc_typespec pointer argument.
1374 (gfc_trans_scalar_assign): Make use of pre and post blocks for
1375 all class expressions.
1376 * trans.c (get_array_span): For unlimited polymorphic exprs
1377 multiply the span by the value of the _len field.
1378 (gfc_build_spanned_array_ref): New function.
1379 (gfc_build_array_ref): Call gfc_build_spanned_array_ref and
1380 eliminate repeated code.
1381 * trans.h: Add arg to gfc_find_and_cut_at_last_class_ref and
1382 add prototype for gfc_build_spanned_array_ref.
1384 2021-04-14 Martin Liska <mliska@suse.cz>
1386 * intrinsic.texi: The table has first column empty and it makes
1387 trouble when processing makeinfo --xml output.
1389 2021-04-09 Tobias Burnus <tobias@codesourcery.com>
1392 * trans-types.c (gfc_get_function_type): Also generate hidden
1393 coarray argument for character arguments.
1395 2021-04-03 Paul Thomas <pault@gcc.gnu.org>
1398 * interface.c (compare_parameter): The codimension attribute is
1399 applied to the _data field of class formal arguments.
1401 2021-04-01 Harald Anlauf <anlauf@gmx.de>
1404 * simplify.c (gfc_simplify_transpose): Properly initialize
1407 2021-03-28 Paul Thomas <pault@gcc.gnu.org>
1410 * trans-expr.c (gfc_conv_procedure_call): Use the _data attrs
1411 for class expressions and detect proc pointer evaluations by
1412 the non-null actual argument list.
1414 2021-03-27 Steve Kargl <kargl@gcc.gnu.org>
1416 * misc.c (gfc_typename): Fix off-by-one in buffer sizes.
1418 2021-03-26 Tobias Burnus <tobias@codesourcery.com>
1421 * intrinsic.c (gfc_intrinsic_func_interface): Set
1422 attr.proc = PROC_INTRINSIC if FL_PROCEDURE.
1424 2021-03-24 Tobias Burnus <tobias@codesourcery.com>
1427 * resolve.c (resolve_operator): Make 'msg' buffer larger
1430 2021-03-23 Tobias Burnus <tobias@codesourcery.com>
1433 * trans-decl.c (build_function_decl): Add comment;
1434 increment hidden_typelist for caf_token/caf_offset.
1435 * trans-types.c (gfc_get_function_type): Add comment;
1436 add missing caf_token/caf_offset args.
1438 2021-03-22 Tobias Burnus <tobias@codesourcery.com>
1441 * match.c (select_type_set_tmp, gfc_match_select_type,
1442 gfc_match_select_rank): Fix 'name' buffersize to avoid out of bounds.
1443 * resolve.c (resolve_select_type): Likewise.
1445 2021-03-19 Thomas Koenig <tkoenig@gcc.gnu.org>
1447 * frontend-passes.c (inline_limit_check): Add rank_a
1448 argument. If a is rank 1, set the second dimension to 1.
1449 (inline_matmul_assign): Pass rank_a argument to inline_limit_check.
1450 (call_external_blas): Likewise.
1452 2021-03-15 Thomas Koenig <tkoenig@gcc.gnu.org>
1455 * frontend-passes.c (doloop_contained_procedure_code):
1456 Properly handle EXEC_IOLENGTH.
1458 2021-03-15 Paul Thomas <pault@gcc.gnu.org>
1461 * trans-stmt.c (gfc_trans_allocate): Mark the initialization
1462 assignment by setting init_flag.
1464 2021-03-14 Harald Anlauf <anlauf@gmx.de>
1465 Paul Thomas <pault@gcc.gnu.org>
1467 * trans-expr.c (gfc_conv_procedure_call): Fix runtime checks for
1469 * trans-intrinsic.c (gfc_conv_intrinsic_size): Likewise.
1471 2021-03-13 Paul Thomas <pault@gcc.gnu.org>
1474 * trans-array.c (gfc_conv_expr_descriptor): For deferred length
1475 length components use the ss_info string length instead of
1476 gfc_get_expr_charlen. Make sure that the deferred string length
1477 is a variable before assigning to it. Otherwise use the expr.
1478 * trans-expr.c (gfc_conv_string_length): Make sure that the
1479 deferred string length is a variable before assigning to it.
1481 2021-03-12 Tobias Burnus <tobias@codesourcery.com>
1484 * resolve.c (resolve_symbol): Accept vars which are in DATA
1485 and hence (either) implicit SAVE (or in common).
1487 2021-03-10 Harald Anlauf <anlauf@gmx.de>
1490 * data.c (gfc_assign_data_value): Reject non-constant character
1492 * trans-array.c (gfc_conv_array_initializer): Restrict loop to
1493 elements which are defined to avoid NULL pointer dereference.
1495 2021-03-10 Tobias Burnus <tobias@codesourcery.com>
1497 * intrinsic.texi (MIN): Correct 'maximum' to 'minimum'.
1499 2021-03-10 Eric Botcazou <ebotcazou@adacore.com>
1502 * trans-intrinsic.c (build_round_expr): Do not implicitly assume
1503 that __float128 is the 128-bit floating-point type.
1505 2021-03-08 Harald Anlauf <anlauf@gmx.de>
1508 * data.c (gfc_assign_data_value): Reject variable with PARAMETER
1509 attribute in DATA statement.
1511 2021-03-05 Tobias Burnus <tobias@codesourcery.com>
1515 * invoke.texi (-freal{4,8}-real-*): Extend description.
1516 * primary.c (match_real_constant): Also promote real literals
1517 with '_kind' number.
1519 2021-03-04 Tobias Burnus <tobias@codesourcery.com>
1522 * decl.c (gfc_match_old_kind_spec, gfc_match_kind_spec): Avoid
1523 redoing kind conversions.
1524 * primary.c (match_real_constant): Likewise.
1526 2021-02-28 Jakub Jelinek <jakub@redhat.com>
1529 * openmp.c (gfc_omp_requires_add_clause): Fix up diagnostic message
1531 (resolve_omp_clauses): Likewise.
1533 2021-02-28 Jakub Jelinek <jakub@redhat.com>
1536 * frontend-passes.c (doloop_code): Replace double space in diagnostics
1537 with a single space.
1539 2021-02-24 Paul Thomas <pault@gcc.gnu.org>
1542 * trans-expr.c (gfc_conv_derived_to_class): Add optional arg.
1543 'derived_array' to hold the fixed, parmse expr in the case of
1544 assumed rank formal arguments. Deal with optional arguments.
1545 (gfc_conv_procedure_call): Null 'derived' array for each actual
1546 argument. Add its address to the call to gfc_conv_derived_to_
1547 class. Access the 'data' field of scalar descriptors before
1548 deallocating allocatable components. Also strip NOPs before the
1549 calls to gfc_deallocate_alloc_comp. Use 'derived' array as the
1550 input to gfc_deallocate_alloc_comp if it is available.
1551 * trans.h : Include the optional argument 'derived_array' to
1552 the prototype of gfc_conv_derived_to_class. The default value
1555 2021-02-23 Paul Thomas <pault@gcc.gnu.org>
1558 * resolve.c (resolve_fl_procedure): Include class results in
1559 the test for F2018, C15100.
1560 * trans-array.c (get_class_info_from_ss): Do not use the saved
1561 descriptor to obtain the class expression for variables. Use
1562 gfc_get_class_from_expr instead.
1564 2021-02-23 Harald Anlauf <anlauf@gmx.de>
1567 * simplify.c (gfc_simplify_reshape): Set string length for
1568 character arguments.
1570 2021-02-22 Tobias Burnus <tobias@codesourcery.com>
1573 * trans-openmp.c (gfc_omp_is_optional_argument): Regard optional
1574 dummy procs as nonoptional as no special treatment is needed.
1576 2021-02-21 Harald Anlauf <anlauf@gmx.de>
1578 * trans-expr.c (gfc_conv_procedure_call): Do not add clobber to
1579 allocatable intent(out) argument.
1581 2021-02-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1584 * match.c (gfc_match_namelist): If BT_UNKNOWN, check for
1585 IMPLICIT NONE and and issue an error, otherwise set the type
1586 to its IMPLICIT type so that any subsequent use of objects will
1587 will confirm their types.
1589 2021-02-19 Harald Anlauf <anlauf@gmx.de>
1591 * symbol.c (gfc_add_flavor): Reverse order of conditions.
1593 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
1596 * dependency.c (gfc_dep_resolver): Fix coarray handling.
1598 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
1603 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
1606 * simplify.c (simplify_bound_dim): Honor DIMEN_ELEMENT
1609 2021-02-17 Julian Brown <julian@codesourcery.com>
1611 * openmp.c (resolve_omp_clauses): Disallow selecting components
1612 of arrays of derived type.
1614 2021-02-17 Julian Brown <julian@codesourcery.com>
1616 * trans-openmp.c (gfc_trans_omp_clauses): Handle element selection
1617 for arrays of derived types.
1619 2021-02-16 Tobias Burnus <tobias@codesourcery.com>
1621 * expr.c (gfc_is_simplify_contiguous): Handle REF_INQUIRY, i.e.
1622 %im and %re which are EXPR_VARIABLE.
1623 * openmp.c (resolve_omp_clauses): Diagnose %re/%im explicitly.
1625 2021-02-16 Tobias Burnus <tobias@codesourcery.com>
1628 * io.c (resolve_tag_format): Reject BT_DERIVED/CLASS/VOID
1629 as (array-valued) FORMAT tag.
1631 2021-02-12 Tobias Burnus <tobias@codesourcery.com>
1634 * trans-expr.c (gfc_conv_procedure_call): Don't reset
1635 rank of assumed-rank array.
1637 2021-02-11 Paul Thomas <pault@gcc.gnu.org>
1640 * match.c (gfc_match_call): Include associate names as possible
1641 entities with typebound subroutines. The target needs to be
1642 resolved for the type.
1644 2021-02-11 Paul Thomas <pault@gcc.gnu.org>
1647 * primary.c (gfc_match_varspec): Test for non-null 'previous'
1648 before using its name in the error message.
1650 2021-02-11 Tobias Burnus <tobias@codesourcery.com>
1652 * intrinsic.texi (FINDLOC): Add 'MASK' to argument table.
1653 (MAXLOC, MAXVAL, MINLOC, MINVAL): For 'MASK', remove 'an
1654 array' as scalars are also permitted.
1656 2021-02-10 Julian Brown <julian@codesourcery.com>
1659 * openmp.c (resolve_omp_clauses): Omit OpenACC update in
1660 contiguity check and stride-specified error.
1662 2021-02-04 Julian Brown <julian@codesourcery.com>
1664 * openmp.c (resolve_omp_clauses): Omit OpenACC update in
1665 contiguity check and stride-specified error.
1667 2021-02-04 Julian Brown <julian@codesourcery.com>
1669 * trans-openmp.c (gfc_trans_omp_clauses): Use class_pointer attribute
1672 2021-02-04 Julian Brown <julian@codesourcery.com>
1674 * trans-openmp.c (gfc_trans_omp_clauses): Fix dereferencing for
1677 2021-02-04 Tobias Burnus <tobias@codesourcery.com>
1679 * openmp.c (resolve_omp_clauses): Explicitly diagnose
1680 substrings as not permitted.
1682 2021-02-03 Jeff Law <law@redhat.com>
1684 * intrinsic.texi (ANINT): Fix typo.
1686 2021-02-03 Tobias Burnus <tobias@codesourcery.com>
1689 * dependency.c (gfc_dep_resolver): Treat local access
1690 to coarrays like any array access in dependency analysis.
1692 2021-01-28 Harald Anlauf <anlauf@gmx.de>
1695 * trans.c (gfc_call_malloc): Allocate area of size 1 if passed
1696 size is NULL (as documented).
1698 2021-01-27 Paul Thomas <pault@gcc.gnu.org>
1702 * trans-expr.c (gfc_conv_procedure_call): Suppress the call to
1703 gfc_conv_intrinsic_to_class for unlimited polymorphic procedure
1705 (gfc_trans_assignment_1): Similarly suppress class assignment
1706 for class valued procedure pointers.
1708 2021-01-27 Paul Thomas <pault@gcc.gnu.org>
1711 * trans-array.c (gfc_conv_expr_descriptor): Include elemental
1712 procedure pointers in the assert under the comment 'elemental
1713 function' and eliminate the second, spurious assert.
1715 2021-01-25 Harald Anlauf <anlauf@gmx.de>
1718 * data.c (create_character_initializer): Check substring indices
1720 (gfc_assign_data_value): Catch error returned from
1721 create_character_initializer.
1723 2021-01-25 Tobias Burnus <tobias@codesourcery.com>
1725 * intrinsic.texi (CO_BROADCAST, CO_MIN, CO_REDUCE, CO_SUM): Fix typos.
1727 2021-01-25 Steve Kargl <kargl@gcc.gnu.org>
1730 * resolve.c (resolve_charlen): Check that length expression is
1731 present before testing for scalar/integer..
1733 2021-01-22 Paul Thomas <pault@gcc.gnu.org>
1736 * trans-intrinsic.c (gfc_conv_associated): Do not add a _data
1737 component for scalar class function targets. Instead, fix the
1738 function result and access the _data from that.
1740 2021-01-21 Jorge D'Elia <jdelia@cimec.unl.edu.ar>
1742 * intrinsic.texi (CO_MAX): Fix typo.
1744 2021-01-21 Paul Thomas <pault@gcc.gnu.org>
1747 * decl.c (gfc_match_modproc): It is not an error to find a
1748 module procedure declaration within a contains block.
1749 * expr.c (gfc_check_vardef_context): Pure procedure result is
1750 assignable. Change 'own_scope' accordingly.
1751 * resolve.c (resolve_typebound_procedure): A procedure that
1752 has the module procedure attribute is almost certainly a
1753 module procedure, whatever its interface.
1755 2021-01-19 Tobias Burnus <tobias@codesourcery.com>
1758 * openmp.c (resolve_omp_clauses): Change use_device_ptr
1759 to use_device_addr for unless type(c_ptr); check all
1760 list item for is_device_ptr.
1762 2021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
1764 * dump-parse-tree.c (show_omp_clauses): Handle detach clause.
1765 * frontend-passes.c (gfc_code_walker): Walk detach expression.
1766 * gfortran.h (struct gfc_omp_clauses): Add detach field.
1767 (gfc_c_intptr_kind): New.
1768 * openmp.c (gfc_free_omp_clauses): Free detach clause.
1769 (gfc_match_omp_detach): New.
1770 (enum omp_mask1): Add OMP_CLAUSE_DETACH.
1771 (enum omp_mask2): Remove OMP_CLAUSE_DETACH.
1772 (gfc_match_omp_clauses): Handle OMP_CLAUSE_DETACH for OpenMP.
1773 (OMP_TASK_CLAUSES): Add OMP_CLAUSE_DETACH.
1774 (resolve_omp_clauses): Prevent use of detach with mergeable and
1775 overriding the data sharing mode of the event handle.
1776 * trans-openmp.c (gfc_trans_omp_clauses): Handle detach clause.
1777 * trans-types.c (gfc_c_intptr_kind): New.
1778 (gfc_init_kinds): Initialize gfc_c_intptr_kind.
1780 (BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT): Rename
1782 (BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT_PTR):
1783 ...this. Add extra argument.
1785 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1787 * gfortran.h (gfc_resolve_substring): Add prototype.
1788 * primary.c (match_string_constant): Simplify substrings with
1789 constant starting and ending points.
1790 * resolve.c: Rename resolve_substring to gfc_resolve_substring.
1791 (gfc_resolve_ref): Use renamed function gfc_resolve_substring.
1793 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1796 * resolve.c (resolve_component): Derived type components with
1797 ALLOCATABLE or POINTER attribute shall have a deferred shape.
1799 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1802 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1805 * resolve.c (resolve_component): Derived type components with
1806 ALLOCATABLE or POINTER attribute shall have a deferred shape.
1808 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1811 * resolve.c (resolve_component): Derived type components with
1812 ALLOCATABLE or POINTER attribute shall have a deferred shape.
1814 2021-01-08 Paul Thomas <pault@gcc.gnu.org>
1817 * trans-expr.c (gfc_conv_component_ref): Remove the condition
1818 that deferred character length components only be allocatable.
1820 2021-01-08 Paul Thomas <pault@gcc.gnu.org>
1823 * simplify.c (is_constant_array_expr): If an array constructor
1824 expression has elements other than constants or structures, try
1825 fixing the expression with gfc_reduce_init_expr. Also, if shape
1826 is NULL, obtain the array size and set it.
1828 2021-01-07 Paul Thomas <pault@gcc.gnu.org>
1831 * resolve.c (find_array_spec): Put static prototype for
1832 resolve_assoc_var before this function and call for associate
1835 2021-01-06 Harald Anlauf <anlauf@gmx.de>
1837 * resolve.c (resolve_component): Add check for valid CLASS
1838 reference before trying to access CLASS data.
1840 2021-01-04 Martin Liska <mliska@suse.cz>
1842 * ChangeLog-2018: Remove duplicate ChangeLog entries.
1844 2021-01-01 Harald Anlauf <anlauf@gmx.de>
1846 * class.c (gfc_find_vtab): Add check on attribute is_class.
1848 2021-01-01 Jakub Jelinek <jakub@redhat.com>
1850 * gfortranspec.c (lang_specific_driver): Update copyright notice
1852 * gfc-internals.texi: Bump @copying's copyright year.
1853 * gfortran.texi: Ditto.
1854 * intrinsic.texi: Ditto.
1855 * invoke.texi: Ditto.
1857 2021-01-01 Jakub Jelinek <jakub@redhat.com>
1859 * ChangeLog-2020: Rotate ChangeLog. New file.
1862 Copyright (C) 2021 Free Software Foundation, Inc.
1864 Copying and distribution of this file, with or without modification,
1865 are permitted in any medium without royalty provided the copyright
1866 notice and this notice are preserved.