]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/fortran/ChangeLog
Daily bump.
[thirdparty/gcc.git] / gcc / fortran / ChangeLog
1 2021-09-08 liuhongt <hongtao.liu@intel.com>
2
3 * options.c (gfc_post_options): Issue an error for
4 -fexcess-precision=16.
5
6 2021-09-07 Harald Anlauf <anlauf@gmx.de>
7
8 PR fortran/101327
9 * expr.c (find_array_element): When bounds cannot be determined as
10 constant, return error instead of aborting.
11
12 2021-09-07 Marcel Vollweiler <marcel@codesourcery.com>
13
14 * openmp.c (gfc_match_omp_flush): Parse 'seq_cst' clause on 'flush'
15 directive.
16 * trans-openmp.c (gfc_trans_omp_flush): Handle OMP_MEMORDER_SEQ_CST.
17
18 2021-09-03 Tobias Burnus <tobias@codesourcery.com>
19
20 * decl.c (gfc_verify_c_interop_param): Reject pointer with
21 CONTIGUOUS attributes as dummy arg. Reject character len > 1
22 when passed as byte stream.
23
24 2021-09-01 Harald Anlauf <anlauf@gmx.de>
25
26 PR fortran/56985
27 * resolve.c (resolve_common_vars): Fix grammar and improve wording
28 of error message rejecting an unlimited polymorphic in COMMON.
29
30 2021-08-31 Harald Anlauf <anlauf@gmx.de>
31
32 PR fortran/100950
33 * simplify.c (substring_has_constant_len): Minimize checks for
34 substring expressions being allowed.
35
36 2021-08-31 Marcel Vollweiler <marcel@codesourcery.com>
37
38 * gfortran.h: Add variable for 'ancestor' in struct gfc_omp_clauses.
39 * openmp.c (gfc_match_omp_clauses): Parse device-modifiers 'device_num'
40 and 'ancestor' in 'target device' clauses.
41 * trans-openmp.c (gfc_trans_omp_clauses): Set OMP_CLAUSE_DEVICE_ANCESTOR.
42
43 2021-08-30 Harald Anlauf <anlauf@gmx.de>
44
45 PR fortran/102113
46 * match.c (gfc_match_goto): Allow for whitespace in parsing list
47 of labels.
48
49 2021-08-30 Harald Anlauf <anlauf@gmx.de>
50
51 PR fortran/101349
52 * resolve.c (resolve_allocate_expr): An unlimited polymorphic
53 argument to ALLOCATE must be ALLOCATABLE or a POINTER. Fix the
54 corresponding check.
55
56 2021-08-28 Harald Anlauf <anlauf@gmx.de>
57
58 PR fortran/87737
59 * resolve.c (resolve_entries): For functions of type CHARACTER
60 tighten the checks for matching characteristics.
61
62 2021-08-25 Lewis Hyatt <lhyatt@gmail.com>
63
64 PR other/93067
65 * cpp.c (gfc_cpp_post_options): Call new function
66 diagnostic_initialize_input_context().
67
68 2021-08-24 Harald Anlauf <anlauf@gmx.de>
69
70 PR fortran/98411
71 * trans-decl.c (gfc_finish_var_decl): Adjust check to handle
72 implicit SAVE as well as variables in the main program. Improve
73 warning message text.
74
75 2021-08-23 Tobias Burnus <tobias@codesourcery.com>
76
77 * openmp.c (gfc_match_dupl_check, gfc_match_dupl_memorder,
78 gfc_match_dupl_atomic): New.
79 (gfc_match_omp_clauses): Use them; remove duplicate
80 'release'/'relaxed' clause matching; improve error dignostic
81 for 'default'.
82
83 2021-08-23 Tobias Burnus <tobias@codesourcery.com>
84
85 * dump-parse-tree.c (show_omp_clauses): Handle 'strict' modifier
86 on grainsize/num_tasks
87 * gfortran.h (gfc_omp_clauses): Add grainsize_strict
88 and num_tasks_strict.
89 * trans-openmp.c (gfc_trans_omp_clauses, gfc_split_omp_clauses):
90 Handle 'strict' modifier on grainsize/num_tasks.
91 * openmp.c (gfc_match_omp_clauses): Likewise.
92
93 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
94
95 * error.c
96 (error_uinteger): Take 'long long unsigned' instead
97 of 'long unsigned' as argumpent.
98 (error_integer): Take 'long long' instead of 'long'.
99 (error_hwuint, error_hwint): New.
100 (error_print): Update to handle 'll' and 'w'
101 length modifiers.
102 * simplify.c (substring_has_constant_len): Use '%wd'
103 in gfc_error.
104
105 2021-08-20 Harald Anlauf <anlauf@gmx.de>
106
107 PR fortran/100950
108 * simplify.c (substring_has_constant_len): Fix format string of
109 gfc_error, pass HOST_WIDE_INT bounds values via char buffer.
110
111 2021-08-20 Tobias Burnus <tobias@codesourcery.com>
112
113 * dump-parse-tree.c (show_omp_clauses): Handle 'at', 'severity'
114 and 'message' clauses.
115 (show_omp_node, show_code_node): Handle EXEC_OMP_ERROR.
116 * gfortran.h (gfc_statement): Add ST_OMP_ERROR.
117 (gfc_omp_severity_type, gfc_omp_at_type): New.
118 (gfc_omp_clauses): Add 'at', 'severity' and 'message' clause;
119 use more bitfields + ENUM_BITFIELD.
120 (gfc_exec_op): Add EXEC_OMP_ERROR.
121 * match.h (gfc_match_omp_error): New.
122 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_(AT,SEVERITY,MESSAGE).
123 (gfc_match_omp_clauses): Handle new clauses.
124 (OMP_ERROR_CLAUSES, gfc_match_omp_error): New.
125 (resolve_omp_clauses): Resolve new clauses.
126 (omp_code_to_statement, gfc_resolve_omp_directive): Handle
127 EXEC_OMP_ERROR.
128 * parse.c (decode_omp_directive, next_statement,
129 gfc_ascii_statement): Handle 'omp error'.
130 * resolve.c (gfc_resolve_blocks): Likewise.
131 * st.c (gfc_free_statement): Likewise.
132 * trans-openmp.c (gfc_trans_omp_error): Likewise.
133 (gfc_trans_omp_directive): Likewise.
134 * trans.c (trans_code): Likewise.
135
136 2021-08-20 Jakub Jelinek <jakub@redhat.com>
137
138 * types.def (BT_FN_VOID_CONST_PTR_SIZE): New DEF_FUNCTION_TYPE_2.
139 * f95-lang.c (ATTR_COLD_NORETURN_NOTHROW_LEAF_LIST): Define.
140
141 2021-08-19 Harald Anlauf <anlauf@gmx.de>
142
143 PR fortran/100950
144 * simplify.c (substring_has_constant_len): New.
145 (gfc_simplify_len): Handle case of substrings with constant
146 bounds.
147
148 2021-08-18 Tobias Burnus <tobias@codesourcery.com>
149
150 * match.h (gfc_match_omp_nothing): New.
151 * openmp.c (gfc_match_omp_nothing): New.
152 * parse.c (decode_omp_directive): Match 'nothing' directive.
153
154 2021-08-17 Tobias Burnus <tobias@codesourcery.com>
155
156 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
157 EXEC_OMP_SCOPE.
158 * gfortran.h (enum gfc_statement): Add ST_OMP_(END_)SCOPE.
159 (enum gfc_exec_op): Add EXEC_OMP_SCOPE.
160 * match.h (gfc_match_omp_scope): New.
161 * openmp.c (OMP_SCOPE_CLAUSES): Define
162 (gfc_match_omp_scope): New.
163 (gfc_match_omp_cancellation_point, gfc_match_omp_end_nowait):
164 Improve error diagnostic.
165 (omp_code_to_statement): Handle ST_OMP_SCOPE.
166 (gfc_resolve_omp_directive): Handle EXEC_OMP_SCOPE.
167 * parse.c (decode_omp_directive, next_statement,
168 gfc_ascii_statement, parse_omp_structured_block,
169 parse_executable): Handle OpenMP's scope construct.
170 * resolve.c (gfc_resolve_blocks): Likewise
171 * st.c (gfc_free_statement): Likewise
172 * trans-openmp.c (gfc_trans_omp_scope): New.
173 (gfc_trans_omp_directive): Call it.
174 * trans.c (trans_code): handle EXEC_OMP_SCOPE.
175
176 2021-08-16 Tobias Burnus <tobias@codesourcery.com>
177
178 * dump-parse-tree.c (show_omp_clauses): Handle 'filter' clause.
179 (show_omp_node, show_code_node): Handle (combined) omp masked construct.
180 * frontend-passes.c (gfc_code_walker): Likewise.
181 * gfortran.h (enum gfc_statement): Add ST_OMP_*_MASKED*.
182 (enum gfc_exec_op): Add EXEC_OMP_*_MASKED*.
183 * match.h (gfc_match_omp_masked, gfc_match_omp_masked_taskloop,
184 gfc_match_omp_masked_taskloop_simd, gfc_match_omp_parallel_masked,
185 gfc_match_omp_parallel_masked_taskloop,
186 gfc_match_omp_parallel_masked_taskloop_simd): New prototypes.
187 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_FILTER.
188 (gfc_match_omp_clauses): Match it.
189 (OMP_MASKED_CLAUSES, gfc_match_omp_parallel_masked,
190 gfc_match_omp_parallel_masked_taskloop,
191 gfc_match_omp_parallel_masked_taskloop_simd,
192 gfc_match_omp_masked, gfc_match_omp_masked_taskloop,
193 gfc_match_omp_masked_taskloop_simd): New.
194 (resolve_omp_clauses): Resolve filter clause.
195 (gfc_resolve_omp_parallel_blocks, resolve_omp_do,
196 omp_code_to_statement, gfc_resolve_omp_directive): Handle
197 omp masked constructs.
198 * parse.c (decode_omp_directive, case_exec_markers,
199 gfc_ascii_statement, parse_omp_do, parse_omp_structured_block,
200 parse_executable): Likewise.
201 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
202 * st.c (gfc_free_statement): Likewise.
203 * trans-openmp.c (gfc_trans_omp_clauses): Handle filter clause.
204 (GFC_OMP_SPLIT_MASKED, GFC_OMP_MASK_MASKED): New enum values.
205 (gfc_trans_omp_masked): New.
206 (gfc_split_omp_clauses): Handle combined masked directives.
207 (gfc_trans_omp_master_taskloop): Rename to ...
208 (gfc_trans_omp_master_masked_taskloop): ... this; handle also
209 combined masked directives.
210 (gfc_trans_omp_parallel_master): Rename to ...
211 (gfc_trans_omp_parallel_master_masked): ... this; handle
212 combined masked directives.
213 (gfc_trans_omp_directive): Handle EXEC_OMP_*_MASKED*.
214 * trans.c (trans_code): Likewise.
215
216 2021-08-15 Harald Anlauf <anlauf@gmx.de>
217
218 PR fortran/99351
219 * match.c (sync_statement): Replace %v code by %e in gfc_match to
220 allow for function references as STAT and ERRMSG arguments.
221 * resolve.c (resolve_sync): Adjust checks of STAT= and ERRMSG= to
222 being definable arguments. Function references with a data
223 pointer result are accepted.
224 * trans-stmt.c (gfc_trans_sync): Adjust assertion.
225
226 2021-08-12 Tobias Burnus <tobias@codesourcery.com>
227
228 * gfortran.h (gfc_omp_proc_bind_kind): Add OMP_PROC_BIND_PRIMARY.
229 * dump-parse-tree.c (show_omp_clauses): Add TODO comment to
230 change 'master' to 'primary' in proc_bind for OpenMP 5.1.
231 * intrinsic.texi (OMP_LIB): Mention OpenMP 5.1; add
232 omp_proc_bind_primary.
233 * openmp.c (gfc_match_omp_clauses): Accept
234 'primary' as alias for 'master'.
235 * trans-openmp.c (gfc_trans_omp_clauses): Handle
236 OMP_PROC_BIND_PRIMARY.
237
238 2021-08-11 Sandra Loosemore <sandra@codesourcery.com>
239
240 * iso-c-binding.def (c_float128, c_float128_complex): Check
241 float128_type_node instead of gfc_float128_type_node.
242 * trans-types.c (gfc_init_kinds, gfc_build_real_type):
243 Update comments re supported 128-bit floating-point types.
244
245 2021-08-11 Richard Biener <rguenther@suse.de>
246
247 * trans-common.c (create_common): Set TREE_THIS_VOLATILE on the
248 COMPONENT_REF if the field is volatile.
249
250 2021-08-07 Harald Anlauf <anlauf@gmx.de>
251
252 PR fortran/68568
253 * primary.c (gfc_expr_attr): Variable attribute can only be
254 inquired when symtree is non-NULL.
255
256 2021-07-28 Harald Anlauf <anlauf@gmx.de>
257
258 PR fortran/101564
259 * expr.c (gfc_check_vardef_context): Add check for KIND and LEN
260 parameter inquiries.
261 * match.c (gfc_match): Fix comment for %v code.
262 (gfc_match_allocate, gfc_match_deallocate): Replace use of %v code
263 by %e in gfc_match to allow for function references as STAT and
264 ERRMSG arguments.
265 * resolve.c (resolve_allocate_deallocate): Avoid NULL pointer
266 dereferences and shortcut for bad STAT and ERRMSG argument to
267 (DE)ALLOCATE. Remove bogus parts of checks for STAT and ERRMSG.
268
269 2021-07-26 José Rui Faustino de Sousa <jrfsousa@gmail.com>
270 Tobias Burnus <tobias@codesourcery.com>
271
272 PR fortran/93308
273 PR fortran/93963
274 PR fortran/94327
275 PR fortran/94331
276 PR fortran/97046
277 * trans-decl.c (convert_CFI_desc): Only copy out the descriptor
278 if necessary.
279 * trans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): Updated attribute
280 handling which reflect a previous intermediate version of the
281 standard. Only copy out the descriptor if necessary.
282
283 2021-07-23 Harald Anlauf <anlauf@gmx.de>
284
285 PR fortran/101536
286 * check.c (array_check): Adjust check for the case of CLASS
287 arrays.
288
289 2021-07-21 Thomas Schwinge <thomas@codesourcery.com>
290 Joseph Myers <joseph@codesourcery.com>
291 Cesar Philippidis <cesar@codesourcery.com>
292
293 * dump-parse-tree.c (show_attr): Update.
294 * gfortran.h (symbol_attribute): Add 'oacc_routine_nohost' member.
295 (gfc_omp_clauses): Add 'nohost' member.
296 * module.c (ab_attribute): Add 'AB_OACC_ROUTINE_NOHOST'.
297 (attr_bits, mio_symbol_attribute): Update.
298 * openmp.c (omp_mask2): Add 'OMP_CLAUSE_NOHOST'.
299 (gfc_match_omp_clauses): Handle 'OMP_CLAUSE_NOHOST'.
300 (OACC_ROUTINE_CLAUSES): Add 'OMP_CLAUSE_NOHOST'.
301 (gfc_match_oacc_routine): Update.
302 * trans-decl.c (add_attributes_to_decl): Update.
303 * trans-openmp.c (gfc_trans_omp_clauses): Likewise.
304
305 2021-07-21 Harald Anlauf <anlauf@gmx.de>
306
307 PR fortran/101514
308 * target-memory.c (gfc_interpret_derived): Size of array component
309 of derived type can only be computed here for explicit shape.
310 * trans-types.c (gfc_get_nodesc_array_type): Do not dereference
311 NULL pointers.
312
313 2021-07-21 Tobias Burnus <tobias@codesourcery.com>
314
315 * decl.c (gfc_verify_c_interop_param): Update for F2008 + F2018
316 changes; reject unsupported bits with 'Error: Sorry,'.
317 * trans-expr.c (gfc_conv_procedure_call): Fix condition to
318 For using CFI descriptor with characters.
319
320 2021-07-18 Harald Anlauf <anlauf@gmx.de>
321
322 PR fortran/101084
323 * io.c (resolve_tag_format): Extend FORMAT check to unknown type.
324
325 2021-07-14 Harald Anlauf <anlauf@gmx.de>
326
327 PR fortran/100949
328 * trans-expr.c (gfc_trans_class_init_assign): Call
329 gfc_conv_expr_present only for dummy variables.
330
331 2021-07-06 Thomas Koenig <tkoenig@gcc.gnu.org>
332
333 PR fortran/100227
334 * frontend-passes.c (traverse_io_block): Adjust test for
335 when a variable is eligible for the transformation to
336 array slice.
337
338 2021-06-28 Martin Sebor <msebor@redhat.com>
339
340 * trans-array.c (trans_array_constructor): Replace direct uses
341 of TREE_NO_WARNING with warning_suppressed_p, and suppress_warning.
342 * trans-decl.c (gfc_build_qualified_array): Same.
343 (gfc_build_dummy_array_decl): Same.
344 (generate_local_decl): Same.
345 (gfc_generate_function_code): Same.
346 * trans-openmp.c (gfc_omp_clause_default_ctor): Same.
347 (gfc_omp_clause_copy_ctor): Same.
348 * trans-types.c (get_dtype_type_node): Same.
349 (gfc_get_desc_dim_type): Same.
350 (gfc_get_array_descriptor_base): Same.
351 (gfc_get_caf_vector_type): Same.
352 (gfc_get_caf_reference_type): Same.
353 * trans.c (gfc_create_var_np): Same.
354
355 2021-06-23 Tobias Burnus <tobias@codesourcery.com>
356
357 * dump-parse-tree.c (show_omp_clauses): Fix enum type used
358 for dumping gfc_omp_defaultmap_category.
359
360 2021-06-23 Andre Vehreschild <vehre@gcc.gnu.org>
361
362 PR fortran/100337
363 * trans-intrinsic.c (conv_co_collective): Check stat for null ptr
364 before dereferrencing.
365
366 2021-06-18 Harald Anlauf <anlauf@gmx.de>
367
368 PR fortran/100283
369 PR fortran/101123
370 * trans-intrinsic.c (gfc_conv_intrinsic_minmax): Unconditionally
371 convert result of min/max to result type.
372
373 2021-06-16 Harald Anlauf <anlauf@gmx.de>
374
375 PR fortran/95501
376 PR fortran/95502
377 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
378 dereference.
379 * match.c (gfc_match_pointer_assignment): Likewise.
380 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
381 symtree.
382
383 2021-06-16 Harald Anlauf <anlauf@gmx.de>
384
385 Revert:
386 2021-06-16 Harald Anlauf <anlauf@gmx.de>
387
388 PR fortran/95501
389 PR fortran/95502
390 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
391 dereference.
392 * match.c (gfc_match_pointer_assignment): Likewise.
393 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
394 symtree.
395
396 2021-06-16 Harald Anlauf <anlauf@gmx.de>
397
398 PR fortran/95501
399 PR fortran/95502
400 * expr.c (gfc_check_pointer_assign): Avoid NULL pointer
401 dereference.
402 * match.c (gfc_match_pointer_assignment): Likewise.
403 * parse.c (gfc_check_do_variable): Avoid comparison with NULL
404 symtree.
405
406 2021-06-15 Tobias Burnus <tobias@codesourcery.com>
407
408 PR fortran/92568
409 * dump-parse-tree.c (show_omp_clauses): Update for defaultmap.
410 * f95-lang.c (LANG_HOOKS_OMP_ALLOCATABLE_P,
411 LANG_HOOKS_OMP_SCALAR_TARGET_P): New.
412 * gfortran.h (enum gfc_omp_defaultmap,
413 enum gfc_omp_defaultmap_category): New.
414 * openmp.c (gfc_match_omp_clauses): Update defaultmap matching.
415 * trans-decl.c (gfc_finish_decl_attrs): Set GFC_DECL_SCALAR_TARGET.
416 * trans-openmp.c (gfc_omp_allocatable_p, gfc_omp_scalar_target_p): New.
417 (gfc_omp_scalar_p): Take 'ptr_alloc_ok' argument.
418 (gfc_trans_omp_clauses, gfc_split_omp_clauses): Update for
419 defaultmap changes.
420 * trans.h (gfc_omp_scalar_p): Update prototype.
421 (gfc_omp_allocatable_p, gfc_omp_scalar_target_p): New.
422 (struct lang_decl): Add scalar_target.
423 (GFC_DECL_SCALAR_TARGET, GFC_DECL_GET_SCALAR_TARGET): New.
424
425 2021-06-14 Tobias Burnus <tobias@codesourcery.com>
426
427 * resolve.c (resolve_variable): Remove *XCNEW used to
428 nullify nullified memory.
429
430 2021-06-09 Martin Liska <mliska@suse.cz>
431
432 * intrinsic.texi: Add missing @headitem to tables with a header.
433
434 2021-06-09 Jakub Jelinek <jakub@redhat.com>
435
436 PR fortran/100965
437 * trans-openmp.c (gfc_omp_finish_clause): Gimplify OMP_CLAUSE_SIZE.
438
439 2021-06-08 Tobias Burnus <tobias@codesourcery.com>
440
441 PR middle-end/99928
442 * trans-openmp.c (gfc_add_clause_implicitly): New.
443 (gfc_split_omp_clauses): Use it.
444 (gfc_free_split_omp_clauses): New.
445 (gfc_trans_omp_do_simd, gfc_trans_omp_parallel_do,
446 gfc_trans_omp_parallel_do_simd, gfc_trans_omp_distribute,
447 gfc_trans_omp_teams, gfc_trans_omp_target, gfc_trans_omp_taskloop,
448 gfc_trans_omp_master_taskloop, gfc_trans_omp_parallel_master): Use it.
449
450 2021-06-08 Martin Liska <mliska@suse.cz>
451
452 * intrinsic.texi: Fix typo.
453 * trans-expr.c (gfc_trans_pointer_assignment): Likewise.
454
455 2021-06-05 José Rui Faustino de Sousa <jrfsousa@gmail.com>
456
457 PR fortran/100120
458 PR fortran/100816
459 PR fortran/100818
460 PR fortran/100819
461 PR fortran/100821
462 * trans-array.c (gfc_get_array_span): rework the way character
463 array "span" was calculated.
464 (gfc_conv_expr_descriptor): improve handling of character sections
465 and unlimited polymorphic objects.
466 * trans-expr.c (gfc_get_character_len): new function to calculate
467 character string length.
468 (gfc_get_character_len_in_bytes): new function to calculate
469 character string length in bytes.
470 (gfc_conv_scalar_to_descriptor): add call to set the "span".
471 (gfc_trans_pointer_assignment): set "_len" and antecipate the
472 initialization of the deferred character length hidden argument.
473 * trans-intrinsic.c (gfc_conv_associated): set "force_no_tmp" to
474 avoid the creation of a temporary.
475 * trans-types.c (gfc_get_dtype_rank_type): rework type detection
476 so that unlimited polymorphic objects get proper type infomation,
477 also important for bind(c).
478 (gfc_get_dtype): add argument to pass the rank if necessary.
479 (gfc_get_array_type_bounds): cosmetic change to have character
480 arrays called character instead of unknown.
481 * trans-types.h (gfc_get_dtype): modify prototype.
482 * trans.c (get_array_span): rework the way character array "span"
483 was calculated.
484 * trans.h (gfc_get_character_len): new prototype.
485 (gfc_get_character_len_in_bytes): new prototype.
486 Add "unlimited_polymorphic" flag to "gfc_se" type to signal when
487 expression carries an unlimited polymorphic object.
488
489 2021-06-04 Harald Anlauf <anlauf@gmx.de>
490
491 PR fortran/99839
492 * frontend-passes.c (inline_matmul_assign): Do not inline matmul
493 if the assignment to the resulting array if it is not of canonical
494 type (real/integer/complex/logical).
495
496 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
497
498 * dump-parse-tree.c (show_code_node): Handle
499 EXEC_OMP_(TARGET_)(,PARALLEL_,TEAMS_)LOOP.
500
501 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
502
503 * scanner.c (skip_fixed_omp_sentinel): Set openacc_flag if
504 this is not an (OpenMP) continuation line.
505 (skip_fixed_oacc_sentinel): Likewise for openmp_flag and OpenACC.
506 (gfc_next_char_literal): gfc_error_now to force error for mixed OMP/ACC
507 continuation once per location and return '\n'.
508
509 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
510
511 PR middle-end/99928
512 * openmp.c (gfc_match_omp_clauses): Fix typo in error message.
513
514 2021-06-04 Tobias Burnus <tobias@codesourcery.com>
515
516 PR middle-end/99928
517 * dump-parse-tree.c (show_omp_clauses): Handle bind clause.
518 (show_omp_node): Handle loop directive.
519 * frontend-passes.c (gfc_code_walker): Likewise.
520 * gfortran.h (enum gfc_statement): Add
521 ST_OMP_(END_)(TARGET_)(|PARALLEL_|TEAMS_)LOOP.
522 (enum gfc_omp_bind_type): New.
523 (gfc_omp_clauses): Use it.
524 (enum gfc_exec_op): Add EXEC_OMP_(TARGET_)(|PARALLEL_|TEAMS_)LOOP.
525 * match.h (gfc_match_omp_loop, gfc_match_omp_parallel_loop,
526 gfc_match_omp_target_parallel_loop, gfc_match_omp_target_teams_loop,
527 gfc_match_omp_teams_loop): New.
528 * openmp.c (enum omp_mask1): Add OMP_CLAUSE_BIND.
529 (gfc_match_omp_clauses): Handle it.
530 (OMP_LOOP_CLAUSES, gfc_match_omp_loop, gfc_match_omp_teams_loop,
531 gfc_match_omp_target_teams_loop, gfc_match_omp_parallel_loop,
532 gfc_match_omp_target_parallel_loop): New.
533 (resolve_omp_clauses, resolve_omp_do, omp_code_to_statement,
534 gfc_resolve_omp_directive): Handle omp loop.
535 * parse.c (decode_omp_directive case_exec_markers, gfc_ascii_statement,
536 parse_omp_do, parse_executable): Likewise.
537 (parse_omp_structured_block): Remove ST_ which use parse_omp_do.
538 * resolve.c (gfc_resolve_blocks): Add omp loop.
539 * st.c (gfc_free_statement): Likewise.
540 * trans-openmp.c (gfc_trans_omp_clauses): Handle bind clause.
541 (gfc_trans_omp_do, gfc_trans_omp_parallel_do, gfc_trans_omp_distribute,
542 gfc_trans_omp_teams, gfc_trans_omp_target, gfc_trans_omp_directive):
543 Handle loop directive.
544 (gfc_split_omp_clauses): Likewise; fix firstprivate/lastprivate
545 and (in_)reduction for taskloop.
546 * trans.c (trans_code): Handle omp loop directive.
547
548 2021-06-01 Tobias Burnus <tobias@codesourcery.com>
549
550 PR middle-end/99928
551 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
552 (parallel) master taskloop (simd).
553 * frontend-passes.c (gfc_code_walker): Set in_omp_workshare
554 to false for parallel master taskloop (simd).
555 * gfortran.h (enum gfc_statement):
556 Add ST_OMP_(END_)(PARALLEL_)MASTER_TASKLOOP(_SIMD).
557 (enum gfc_exec_op): EXEC_OMP_(PARALLEL_)MASTER_TASKLOOP(_SIMD).
558 * match.h (gfc_match_omp_master_taskloop,
559 gfc_match_omp_master_taskloop_simd,
560 gfc_match_omp_parallel_master_taskloop,
561 gfc_match_omp_parallel_master_taskloop_simd): New prototype.
562 * openmp.c (gfc_match_omp_parallel_master_taskloop,
563 gfc_match_omp_parallel_master_taskloop_simd,
564 gfc_match_omp_master_taskloop,
565 gfc_match_omp_master_taskloop_simd): New.
566 (gfc_match_omp_taskloop_simd): Permit 'reduction' clause.
567 (resolve_omp_clauses): Handle new combined directives; remove
568 inscan-reduction check to reduce multiple errors; add
569 task-reduction error for 'taskloop simd'.
570 (gfc_resolve_omp_parallel_blocks,
571 resolve_omp_do, omp_code_to_statement,
572 gfc_resolve_omp_directive): Handle new combined constructs.
573 * parse.c (decode_omp_directive, next_statement,
574 gfc_ascii_statement, parse_omp_do, parse_omp_structured_block,
575 parse_executable): Likewise.
576 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
577 * st.c (gfc_free_statement): Likewise.
578 * trans.c (trans_code): Likewise.
579 * trans-openmp.c (gfc_split_omp_clauses,
580 gfc_trans_omp_directive): Likewise.
581 (gfc_trans_omp_parallel_master): Move after gfc_trans_omp_master_taskloop;
582 handle parallel master taskloop (simd) as well.
583 (gfc_trans_omp_taskloop): Take gfc_exec_op as arg.
584 (gfc_trans_omp_master_taskloop): New.
585
586 2021-05-30 Gerald Pfeifer <gerald@pfeifer.com>
587
588 * gfortran.texi (BOZ literal constants): Fix typo.
589
590 2021-05-28 Tobias Burnus <tobias@codesourcery.com>
591
592 * dump-parse-tree.c (show_iterator): New.
593 (show_omp_namelist): Handle iterators.
594 (show_omp_clauses): Handle affinity.
595 * gfortran.h (gfc_free_omp_namelist): New union with 'udr' and new 'ns'.
596 * match.c (gfc_free_omp_namelist): Add are to choose union element.
597 * openmp.c (gfc_free_omp_clauses, gfc_match_omp_detach,
598 gfc_match_omp_clause_reduction, gfc_match_omp_flush): Update
599 call to gfc_free_omp_namelist.
600 (gfc_match_omp_variable_list): Likewise; permit preceeding whitespace.
601 (enum omp_mask1): Add OMP_CLAUSE_AFFINITY.
602 (gfc_match_iterator): New.
603 (gfc_match_omp_clauses): Use it; update call to gfc_free_omp_namelist.
604 (OMP_TASK_CLAUSES): Add OMP_CLAUSE_AFFINITY.
605 (gfc_match_omp_taskwait): Match depend clause.
606 (resolve_omp_clauses): Handle affinity; update for udr/union change.
607 (gfc_resolve_omp_directive): Resolve clauses of taskwait.
608 * st.c (gfc_free_statement): Update gfc_free_omp_namelist call.
609 * trans-openmp.c (gfc_trans_omp_array_reduction_or_udr): Likewise
610 (handle_iterator): New.
611 (gfc_trans_omp_clauses): Handle iterators for depend/affinity clause.
612 (gfc_trans_omp_taskwait): Handle depend clause.
613 (gfc_trans_omp_directive): Update call.
614
615 2021-05-27 Harald Anlauf <anlauf@gmx.de>
616
617 PR fortran/100602
618 * trans-intrinsic.c (gfc_conv_intrinsic_size): Use CLASS data
619 attributes for CLASS arrays for generation of runtime error.
620
621 2021-05-27 Harald Anlauf <anlauf@gmx.de>
622
623 PR fortran/100656
624 * trans-array.c (gfc_conv_ss_startstride): Do not call check for
625 presence of a dummy argument when a symbol actually refers to a
626 non-dummy.
627
628 2021-05-25 Tobias Burnus <tobias@codesourcery.com>
629 Johannes Nendwich <a08727063@unet.univie.ac.at>
630
631 * intrinsic.texi (GERROR, GETARGS, GETLOG, NORM2, PARITY, RANDOM_INIT,
632 RANDOM_NUMBER): Fix typos and copy'n'paste errors.
633
634 2021-05-24 Tobias Burnus <tobias@codesourcery.com>
635
636 PR fortran/86470
637 * trans-expr.c (gfc_copy_class_to_class): Add unshare_expr.
638 * trans-openmp.c (gfc_is_polymorphic_nonptr,
639 gfc_is_unlimited_polymorphic_nonptr): New.
640 (gfc_omp_clause_copy_ctor, gfc_omp_clause_dtor): Handle
641 polymorphic scalars.
642
643 2021-05-23 Harald Anlauf <anlauf@gmx.de>
644
645 PR fortran/100551
646 * trans-expr.c (gfc_conv_procedure_call): Adjust check for
647 implicit conversion of actual argument to an unlimited polymorphic
648 procedure argument.
649
650 2021-05-23 Tobias Burnus <tobias@codesourcery.com>
651
652 * intrinsic.texi (ATOMIC_ADD, ATOMIC_FETCH_ADD): Use the
653 proper variable name in the description.
654
655 2021-05-22 Andre Vehreschild <vehre@gcc.gnu.org>
656 Steve Kargl <kargl@gcc.gnu.org>
657
658 PR fortran/98301
659 * trans-decl.c (gfc_build_builtin_function_decls): Move decl.
660 * trans-intrinsic.c (conv_intrinsic_random_init): Use bool for
661 lib-call of caf_random_init instead of logical (4-byte).
662 * trans.h: Add tree var for random_init.
663
664 2021-05-20 Marcel Vollweiler <marcel@codesourcery.com>
665
666 * openmp.c (gfc_match_omp_clauses): Support map-type-modifier 'close'.
667
668 2021-05-18 Tobias Burnus <tobias@codesourcery.com>
669
670 PR fortran/100642
671 * openmp.c (omp_code_to_statement): Add missing EXEC_OMP_DEPOBJ.
672
673 2021-05-17 Harald Anlauf <anlauf@gmx.de>
674
675 PR fortran/98411
676 * trans-decl.c (gfc_finish_var_decl): Add check for explicit SAVE
677 attribute.
678
679 2021-05-17 Tobias Burnus <tobias@codesourcery.com>
680
681 PR fortran/100633
682 * resolve.c (gfc_resolve_code): Reject nonintrinsic assignments in
683 OMP WORKSHARE.
684
685 2021-05-14 Tobias Burnus <tobias@codesourcery.com>
686
687 * dump-parse-tree.c (show_omp_node, show_code_node): Handle
688 EXEC_OMP_PARALLEL_MASTER.
689 * frontend-passes.c (gfc_code_walker): Likewise.
690 * gfortran.h (enum gfc_statement): Add ST_OMP_PARALLEL_MASTER and
691 ST_OMP_END_PARALLEL_MASTER.
692 (enum gfc_exec_op): Add EXEC_OMP_PARALLEL_MASTER..
693 * match.h (gfc_match_omp_parallel_master): Handle it.
694 * openmp.c (gfc_match_omp_parallel_master, resolve_omp_clauses,
695 omp_code_to_statement, gfc_resolve_omp_directive): Likewise.
696 * parse.c (decode_omp_directive, case_exec_markers,
697 gfc_ascii_statement, parse_omp_structured_block,
698 parse_executable): Likewise.
699 * resolve.c (gfc_resolve_blocks, gfc_resolve_code): Likewise.
700 * st.c (gfc_free_statement): Likewise.
701 * trans-openmp.c (gfc_trans_omp_parallel_master,
702 gfc_trans_omp_workshare, gfc_trans_omp_directive): Likewise.
703 * trans.c (trans_code): Likewise.
704
705 2021-05-14 Tobias Burnus <tobias@codesourcery.com>
706
707 * resolve.c (resolve_symbol): Handle implicit SAVE of main-program
708 for vars in 'omp threadprivate' and 'omp declare target'.
709
710 2021-05-10 Martin Liska <mliska@suse.cz>
711
712 * decl.c (variable_decl): Use startswith
713 function instead of strncmp.
714 (gfc_match_end): Likewise.
715 * gfortran.h (gfc_str_startswith): Likewise.
716 * module.c (load_omp_udrs): Likewise.
717 (read_module): Likewise.
718 * options.c (gfc_handle_runtime_check_option): Likewise.
719 * primary.c (match_arg_list_function): Likewise.
720 * trans-decl.c (gfc_get_symbol_decl): Likewise.
721 * trans-expr.c (gfc_conv_procedure_call): Likewise.
722 * trans-intrinsic.c (gfc_conv_ieee_arithmetic_function): Likewise.
723
724 2021-05-06 Paul Thomas <pault@gcc.gnu.org>
725
726 PR fortran/46991
727 PR fortran/99819
728 * class.c (gfc_build_class_symbol): Remove the error that
729 disables assumed size class arrays. Class array types that are
730 not deferred shape or assumed rank are given a unique name and
731 placed in the procedure namespace.
732 * trans-array.c (gfc_trans_g77_array): Obtain the data pointer
733 for class arrays.
734 (gfc_trans_dummy_array_bias): Suppress the runtime error for
735 extent violations in explicit shape class arrays because it
736 always fails.
737 * trans-expr.c (gfc_conv_procedure_call): Handle assumed size
738 class actual arguments passed to non-descriptor formal args by
739 using the data pointer, stored as the symbol's backend decl.
740
741 2021-05-05 Harald Anlauf <anlauf@gmx.de>
742
743 PR fortran/100274
744 * interface.c (gfc_compare_actual_formal): Continue checks after
745 emitting warning for argument length mismatch.
746 * trans-expr.c (gfc_conv_procedure_call): Check for NULL pointer
747 dereference.
748
749 2021-05-04 Tobias Burnus <tobias@codesourcery.com>
750
751 PR testsuite/100397
752 * trans-openmp.c (gfc_trans_omp_depobj): Fix pasto in enum values.
753
754 2021-04-28 Tobias Burnus <tobias@codesourcery.com>
755
756 * openmp.c (gfc_match_omp_variable_list): Gobble whitespace before
757 checking whether a '%' or parenthesis-open follows as next character.
758
759 2021-04-28 José Rui Faustino de Sousa <jrfsousa@gmail.com>
760
761 PR fortran/82376
762 * trans-expr.c (gfc_conv_procedure_call): Evaluate function result
763 and then pass a pointer.
764
765 2021-04-26 Thomas Schwinge <thomas@codesourcery.com>
766 Nathan Sidwell <nathan@codesourcery.com>
767 Tom de Vries <vries@codesourcery.com>
768 Julian Brown <julian@codesourcery.com>
769 Kwok Cheung Yeung <kcy@codesourcery.com>
770
771 * lang.opt (Wopenacc-parallelism): New.
772
773 2021-04-24 Harald Anlauf <anlauf@gmx.de>
774
775 PR fortran/100154
776 * check.c (variable_check): Allow function reference having a data
777 pointer result.
778 (arg_strlen_is_zero): New function.
779 (gfc_check_fgetputc_sub): Add static check of character and status
780 arguments.
781 (gfc_check_fgetput_sub): Likewise.
782 * intrinsic.c (add_subroutines): Fix argument name for the
783 character argument to intrinsic subroutines fget[c], fput[c].
784
785 2021-04-24 Harald Anlauf <anlauf@gmx.de>
786
787 PR fortran/100218
788 * expr.c (gfc_check_vardef_context): Extend check to allow pointer
789 from a function reference.
790
791 2021-04-22 Martin Liska <mliska@suse.cz>
792
793 PR testsuite/100159
794 PR testsuite/100192
795 * frontend-passes.c (optimize_expr): Fix typos and missing comments.
796
797 2021-04-22 Michael Meissner <meissner@linux.ibm.com>
798
799 PR fortran/96983
800 * trans-intrinsic.c (build_round_expr): If int type is larger than
801 long long, do the round and convert to the integer type. Do not
802 try to find a floating point type the exact size of the integer
803 type.
804
805 2021-04-21 Tobias Burnus <tobias@codesourcery.com>
806
807 * dump-parse-tree.c (show_omp_namelist): Handle depobj + mutexinoutset
808 in the depend clause.
809 (show_omp_clauses, show_omp_node, show_code_node): Handle depobj.
810 * gfortran.h (enum gfc_statement): Add ST_OMP_DEPOBJ.
811 (enum gfc_omp_depend_op): Add OMP_DEPEND_UNSET,
812 OMP_DEPEND_MUTEXINOUTSET and OMP_DEPEND_DEPOBJ.
813 (gfc_omp_clauses): Add destroy, depobj_update and depobj.
814 (enum gfc_exec_op): Add EXEC_OMP_DEPOBJ
815 * match.h (gfc_match_omp_depobj): Match 'omp depobj'.
816 * openmp.c (gfc_match_omp_clauses): Add depobj + mutexinoutset
817 to depend clause.
818 (gfc_match_omp_depobj, resolve_omp_clauses, gfc_resolve_omp_directive):
819 Handle 'omp depobj'.
820 * parse.c (decode_omp_directive, next_statement, gfc_ascii_statement):
821 Likewise.
822 * resolve.c (gfc_resolve_code): Likewise.
823 * st.c (gfc_free_statement): Likewise.
824 * trans-openmp.c (gfc_trans_omp_clauses): Handle depobj + mutexinoutset
825 in the depend clause.
826 (gfc_trans_omp_depobj, gfc_trans_omp_directive): Handle EXEC_OMP_DEPOBJ.
827 * trans.c (trans_code): Likewise.
828
829 2021-04-20 Paul Thomas <pault@gcc.gnu.org>
830
831 PR fortran/100110
832 * trans-decl.c (gfc_get_symbol_decl): Replace test for host
833 association with a check that the current and symbol namespaces
834 are the same.
835
836 2021-04-19 Thomas Schwinge <thomas@codesourcery.com>
837
838 * lang.opt (fopenacc-kernels=): Remove.
839
840 2021-04-16 José Rui Faustino de Sousa <jrfsousa@gmail.com>
841
842 PR fortran/100094
843 * trans-array.c (gfc_trans_deferred_array): Add code to initialize
844 pointers and allocatables with correct TKR parameters.
845
846 2021-04-16 José Rui Faustino de Sousa <jrfsousa@gmail.com>
847
848 PR fortran/100018
849 * resolve.c: Add association check before de-referencing pointer.
850
851 2021-04-16 Harald Anlauf <anlauf@gmx.de>
852 Paul Thomas <pault@gcc.gnu.org>
853
854 PR fortran/63797
855 * module.c (write_symtree): Do not write interface of intrinsic
856 procedure to module file for F2003 and newer.
857
858 2021-04-15 Paul Thomas <pault@gcc.gnu.org>
859
860 PR fortran/99307
861 * symbol.c: Remove trailing white space.
862 * trans-array.c (gfc_trans_create_temp_array): Create a class
863 temporary for class expressions and assign the new descriptor
864 to the data field.
865 (build_class_array_ref): If the class expr can be extracted,
866 then use that for 'decl'. Class function results are reliably
867 handled this way. Call gfc_find_and_cut_at_last_class_ref to
868 eliminate largely redundant code. Remove dead code and recast
869 the rest of the code to extract 'decl' for remaining cases.
870 Call gfc_build_spanned_array_ref.
871 (gfc_alloc_allocatable_for_assignment): Use class descriptor
872 element length for 'elemsize1'. Eliminate repeat set of dtype
873 for class expressions.
874 * trans-expr.c (gfc_find_and_cut_at_last_class_ref): Include
875 additional code from build_class_array_ref, and use optional
876 gfc_typespec pointer argument.
877 (gfc_trans_scalar_assign): Make use of pre and post blocks for
878 all class expressions.
879 * trans.c (get_array_span): For unlimited polymorphic exprs
880 multiply the span by the value of the _len field.
881 (gfc_build_spanned_array_ref): New function.
882 (gfc_build_array_ref): Call gfc_build_spanned_array_ref and
883 eliminate repeated code.
884 * trans.h: Add arg to gfc_find_and_cut_at_last_class_ref and
885 add prototype for gfc_build_spanned_array_ref.
886
887 2021-04-14 Martin Liska <mliska@suse.cz>
888
889 * intrinsic.texi: The table has first column empty and it makes
890 trouble when processing makeinfo --xml output.
891
892 2021-04-09 Tobias Burnus <tobias@codesourcery.com>
893
894 PR fortran/99817
895 * trans-types.c (gfc_get_function_type): Also generate hidden
896 coarray argument for character arguments.
897
898 2021-04-03 Paul Thomas <pault@gcc.gnu.org>
899
900 PR fortran/99818
901 * interface.c (compare_parameter): The codimension attribute is
902 applied to the _data field of class formal arguments.
903
904 2021-04-01 Harald Anlauf <anlauf@gmx.de>
905
906 PR fortran/99840
907 * simplify.c (gfc_simplify_transpose): Properly initialize
908 resulting shape.
909
910 2021-03-28 Paul Thomas <pault@gcc.gnu.org>
911
912 PR fortran/99602
913 * trans-expr.c (gfc_conv_procedure_call): Use the _data attrs
914 for class expressions and detect proc pointer evaluations by
915 the non-null actual argument list.
916
917 2021-03-27 Steve Kargl <kargl@gcc.gnu.org>
918
919 * misc.c (gfc_typename): Fix off-by-one in buffer sizes.
920
921 2021-03-26 Tobias Burnus <tobias@codesourcery.com>
922
923 PR fortran/99651
924 * intrinsic.c (gfc_intrinsic_func_interface): Set
925 attr.proc = PROC_INTRINSIC if FL_PROCEDURE.
926
927 2021-03-24 Tobias Burnus <tobias@codesourcery.com>
928
929 PR fortran/99369
930 * resolve.c (resolve_operator): Make 'msg' buffer larger
931 and use snprintf.
932
933 2021-03-23 Tobias Burnus <tobias@codesourcery.com>
934
935 PR fortran/93660
936 * trans-decl.c (build_function_decl): Add comment;
937 increment hidden_typelist for caf_token/caf_offset.
938 * trans-types.c (gfc_get_function_type): Add comment;
939 add missing caf_token/caf_offset args.
940
941 2021-03-22 Tobias Burnus <tobias@codesourcery.com>
942
943 PR fortran/99688
944 * match.c (select_type_set_tmp, gfc_match_select_type,
945 gfc_match_select_rank): Fix 'name' buffersize to avoid out of bounds.
946 * resolve.c (resolve_select_type): Likewise.
947
948 2021-03-19 Thomas Koenig <tkoenig@gcc.gnu.org>
949
950 * frontend-passes.c (inline_limit_check): Add rank_a
951 argument. If a is rank 1, set the second dimension to 1.
952 (inline_matmul_assign): Pass rank_a argument to inline_limit_check.
953 (call_external_blas): Likewise.
954
955 2021-03-15 Thomas Koenig <tkoenig@gcc.gnu.org>
956
957 PR fortran/99345
958 * frontend-passes.c (doloop_contained_procedure_code):
959 Properly handle EXEC_IOLENGTH.
960
961 2021-03-15 Paul Thomas <pault@gcc.gnu.org>
962
963 PR fortran/99545
964 * trans-stmt.c (gfc_trans_allocate): Mark the initialization
965 assignment by setting init_flag.
966
967 2021-03-14 Harald Anlauf <anlauf@gmx.de>
968 Paul Thomas <pault@gcc.gnu.org>
969
970 * trans-expr.c (gfc_conv_procedure_call): Fix runtime checks for
971 CLASS arguments.
972 * trans-intrinsic.c (gfc_conv_intrinsic_size): Likewise.
973
974 2021-03-13 Paul Thomas <pault@gcc.gnu.org>
975
976 PR fortran/99125
977 * trans-array.c (gfc_conv_expr_descriptor): For deferred length
978 length components use the ss_info string length instead of
979 gfc_get_expr_charlen. Make sure that the deferred string length
980 is a variable before assigning to it. Otherwise use the expr.
981 * trans-expr.c (gfc_conv_string_length): Make sure that the
982 deferred string length is a variable before assigning to it.
983
984 2021-03-12 Tobias Burnus <tobias@codesourcery.com>
985
986 PR fortran/99514
987 * resolve.c (resolve_symbol): Accept vars which are in DATA
988 and hence (either) implicit SAVE (or in common).
989
990 2021-03-10 Harald Anlauf <anlauf@gmx.de>
991
992 PR fortran/99205
993 * data.c (gfc_assign_data_value): Reject non-constant character
994 length for lvalue.
995 * trans-array.c (gfc_conv_array_initializer): Restrict loop to
996 elements which are defined to avoid NULL pointer dereference.
997
998 2021-03-10 Tobias Burnus <tobias@codesourcery.com>
999
1000 * intrinsic.texi (MIN): Correct 'maximum' to 'minimum'.
1001
1002 2021-03-10 Eric Botcazou <ebotcazou@adacore.com>
1003
1004 PR fortran/96983
1005 * trans-intrinsic.c (build_round_expr): Do not implicitly assume
1006 that __float128 is the 128-bit floating-point type.
1007
1008 2021-03-08 Harald Anlauf <anlauf@gmx.de>
1009
1010 PR fortran/49278
1011 * data.c (gfc_assign_data_value): Reject variable with PARAMETER
1012 attribute in DATA statement.
1013
1014 2021-03-05 Tobias Burnus <tobias@codesourcery.com>
1015
1016 PR fortran/99355
1017 PR fortran/57871
1018 * invoke.texi (-freal{4,8}-real-*): Extend description.
1019 * primary.c (match_real_constant): Also promote real literals
1020 with '_kind' number.
1021
1022 2021-03-04 Tobias Burnus <tobias@codesourcery.com>
1023
1024 PR fortran/99355
1025 * decl.c (gfc_match_old_kind_spec, gfc_match_kind_spec): Avoid
1026 redoing kind conversions.
1027 * primary.c (match_real_constant): Likewise.
1028
1029 2021-02-28 Jakub Jelinek <jakub@redhat.com>
1030
1031 PR fortran/99303
1032 * openmp.c (gfc_omp_requires_add_clause): Fix up diagnostic message
1033 wordings.
1034 (resolve_omp_clauses): Likewise.
1035
1036 2021-02-28 Jakub Jelinek <jakub@redhat.com>
1037
1038 PR fortran/99300
1039 * frontend-passes.c (doloop_code): Replace double space in diagnostics
1040 with a single space.
1041
1042 2021-02-24 Paul Thomas <pault@gcc.gnu.org>
1043
1044 PR fortran/98342
1045 * trans-expr.c (gfc_conv_derived_to_class): Add optional arg.
1046 'derived_array' to hold the fixed, parmse expr in the case of
1047 assumed rank formal arguments. Deal with optional arguments.
1048 (gfc_conv_procedure_call): Null 'derived' array for each actual
1049 argument. Add its address to the call to gfc_conv_derived_to_
1050 class. Access the 'data' field of scalar descriptors before
1051 deallocating allocatable components. Also strip NOPs before the
1052 calls to gfc_deallocate_alloc_comp. Use 'derived' array as the
1053 input to gfc_deallocate_alloc_comp if it is available.
1054 * trans.h : Include the optional argument 'derived_array' to
1055 the prototype of gfc_conv_derived_to_class. The default value
1056 is NULL_TREE.
1057
1058 2021-02-23 Paul Thomas <pault@gcc.gnu.org>
1059
1060 PR fortran/99124
1061 * resolve.c (resolve_fl_procedure): Include class results in
1062 the test for F2018, C15100.
1063 * trans-array.c (get_class_info_from_ss): Do not use the saved
1064 descriptor to obtain the class expression for variables. Use
1065 gfc_get_class_from_expr instead.
1066
1067 2021-02-23 Harald Anlauf <anlauf@gmx.de>
1068
1069 PR fortran/99206
1070 * simplify.c (gfc_simplify_reshape): Set string length for
1071 character arguments.
1072
1073 2021-02-22 Tobias Burnus <tobias@codesourcery.com>
1074
1075 PR fortran/99171
1076 * trans-openmp.c (gfc_omp_is_optional_argument): Regard optional
1077 dummy procs as nonoptional as no special treatment is needed.
1078
1079 2021-02-21 Harald Anlauf <anlauf@gmx.de>
1080
1081 * trans-expr.c (gfc_conv_procedure_call): Do not add clobber to
1082 allocatable intent(out) argument.
1083
1084 2021-02-19 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1085
1086 PR fortran/98686
1087 * match.c (gfc_match_namelist): If BT_UNKNOWN, check for
1088 IMPLICIT NONE and and issue an error, otherwise set the type
1089 to its IMPLICIT type so that any subsequent use of objects will
1090 will confirm their types.
1091
1092 2021-02-19 Harald Anlauf <anlauf@gmx.de>
1093
1094 * symbol.c (gfc_add_flavor): Reverse order of conditions.
1095
1096 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
1097
1098 PR fortran/99010
1099 * dependency.c (gfc_dep_resolver): Fix coarray handling.
1100
1101 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
1102
1103 PR fortran/99146
1104 * interface.c:
1105
1106 2021-02-19 Tobias Burnus <tobias@codesourcery.com>
1107
1108 PR fortran/99027
1109 * simplify.c (simplify_bound_dim): Honor DIMEN_ELEMENT
1110 when using dim=.
1111
1112 2021-02-17 Julian Brown <julian@codesourcery.com>
1113
1114 * openmp.c (resolve_omp_clauses): Disallow selecting components
1115 of arrays of derived type.
1116
1117 2021-02-17 Julian Brown <julian@codesourcery.com>
1118
1119 * trans-openmp.c (gfc_trans_omp_clauses): Handle element selection
1120 for arrays of derived types.
1121
1122 2021-02-16 Tobias Burnus <tobias@codesourcery.com>
1123
1124 * expr.c (gfc_is_simplify_contiguous): Handle REF_INQUIRY, i.e.
1125 %im and %re which are EXPR_VARIABLE.
1126 * openmp.c (resolve_omp_clauses): Diagnose %re/%im explicitly.
1127
1128 2021-02-16 Tobias Burnus <tobias@codesourcery.com>
1129
1130 PR fortran/99111
1131 * io.c (resolve_tag_format): Reject BT_DERIVED/CLASS/VOID
1132 as (array-valued) FORMAT tag.
1133
1134 2021-02-12 Tobias Burnus <tobias@codesourcery.com>
1135
1136 PR fortran/99043
1137 * trans-expr.c (gfc_conv_procedure_call): Don't reset
1138 rank of assumed-rank array.
1139
1140 2021-02-11 Paul Thomas <pault@gcc.gnu.org>
1141
1142 PR fortran/98897
1143 * match.c (gfc_match_call): Include associate names as possible
1144 entities with typebound subroutines. The target needs to be
1145 resolved for the type.
1146
1147 2021-02-11 Paul Thomas <pault@gcc.gnu.org>
1148
1149 PR fortran/99060
1150 * primary.c (gfc_match_varspec): Test for non-null 'previous'
1151 before using its name in the error message.
1152
1153 2021-02-11 Tobias Burnus <tobias@codesourcery.com>
1154
1155 * intrinsic.texi (FINDLOC): Add 'MASK' to argument table.
1156 (MAXLOC, MAXVAL, MINLOC, MINVAL): For 'MASK', remove 'an
1157 array' as scalars are also permitted.
1158
1159 2021-02-10 Julian Brown <julian@codesourcery.com>
1160
1161 PR fortran/98979
1162 * openmp.c (resolve_omp_clauses): Omit OpenACC update in
1163 contiguity check and stride-specified error.
1164
1165 2021-02-04 Julian Brown <julian@codesourcery.com>
1166
1167 * openmp.c (resolve_omp_clauses): Omit OpenACC update in
1168 contiguity check and stride-specified error.
1169
1170 2021-02-04 Julian Brown <julian@codesourcery.com>
1171
1172 * trans-openmp.c (gfc_trans_omp_clauses): Use class_pointer attribute
1173 for BT_CLASS.
1174
1175 2021-02-04 Julian Brown <julian@codesourcery.com>
1176
1177 * trans-openmp.c (gfc_trans_omp_clauses): Fix dereferencing for
1178 BT_DERIVED members.
1179
1180 2021-02-04 Tobias Burnus <tobias@codesourcery.com>
1181
1182 * openmp.c (resolve_omp_clauses): Explicitly diagnose
1183 substrings as not permitted.
1184
1185 2021-02-03 Jeff Law <law@redhat.com>
1186
1187 * intrinsic.texi (ANINT): Fix typo.
1188
1189 2021-02-03 Tobias Burnus <tobias@codesourcery.com>
1190
1191 PR fortran/98913
1192 * dependency.c (gfc_dep_resolver): Treat local access
1193 to coarrays like any array access in dependency analysis.
1194
1195 2021-01-28 Harald Anlauf <anlauf@gmx.de>
1196
1197 PR fortran/86470
1198 * trans.c (gfc_call_malloc): Allocate area of size 1 if passed
1199 size is NULL (as documented).
1200
1201 2021-01-27 Paul Thomas <pault@gcc.gnu.org>
1202
1203 PR fortran/93924
1204 PR fortran/93925
1205 * trans-expr.c (gfc_conv_procedure_call): Suppress the call to
1206 gfc_conv_intrinsic_to_class for unlimited polymorphic procedure
1207 pointers.
1208 (gfc_trans_assignment_1): Similarly suppress class assignment
1209 for class valued procedure pointers.
1210
1211 2021-01-27 Paul Thomas <pault@gcc.gnu.org>
1212
1213 PR fortran/98472
1214 * trans-array.c (gfc_conv_expr_descriptor): Include elemental
1215 procedure pointers in the assert under the comment 'elemental
1216 function' and eliminate the second, spurious assert.
1217
1218 2021-01-25 Harald Anlauf <anlauf@gmx.de>
1219
1220 PR fortran/70070
1221 * data.c (create_character_initializer): Check substring indices
1222 against bounds.
1223 (gfc_assign_data_value): Catch error returned from
1224 create_character_initializer.
1225
1226 2021-01-25 Tobias Burnus <tobias@codesourcery.com>
1227
1228 * intrinsic.texi (CO_BROADCAST, CO_MIN, CO_REDUCE, CO_SUM): Fix typos.
1229
1230 2021-01-25 Steve Kargl <kargl@gcc.gnu.org>
1231
1232 PR fortran/98517
1233 * resolve.c (resolve_charlen): Check that length expression is
1234 present before testing for scalar/integer..
1235
1236 2021-01-22 Paul Thomas <pault@gcc.gnu.org>
1237
1238 PR fortran/98565
1239 * trans-intrinsic.c (gfc_conv_associated): Do not add a _data
1240 component for scalar class function targets. Instead, fix the
1241 function result and access the _data from that.
1242
1243 2021-01-21 Jorge D'Elia <jdelia@cimec.unl.edu.ar>
1244
1245 * intrinsic.texi (CO_MAX): Fix typo.
1246
1247 2021-01-21 Paul Thomas <pault@gcc.gnu.org>
1248
1249 PR fortran/96320
1250 * decl.c (gfc_match_modproc): It is not an error to find a
1251 module procedure declaration within a contains block.
1252 * expr.c (gfc_check_vardef_context): Pure procedure result is
1253 assignable. Change 'own_scope' accordingly.
1254 * resolve.c (resolve_typebound_procedure): A procedure that
1255 has the module procedure attribute is almost certainly a
1256 module procedure, whatever its interface.
1257
1258 2021-01-19 Tobias Burnus <tobias@codesourcery.com>
1259
1260 PR fortran/98476
1261 * openmp.c (resolve_omp_clauses): Change use_device_ptr
1262 to use_device_addr for unless type(c_ptr); check all
1263 list item for is_device_ptr.
1264
1265 2021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com>
1266
1267 * dump-parse-tree.c (show_omp_clauses): Handle detach clause.
1268 * frontend-passes.c (gfc_code_walker): Walk detach expression.
1269 * gfortran.h (struct gfc_omp_clauses): Add detach field.
1270 (gfc_c_intptr_kind): New.
1271 * openmp.c (gfc_free_omp_clauses): Free detach clause.
1272 (gfc_match_omp_detach): New.
1273 (enum omp_mask1): Add OMP_CLAUSE_DETACH.
1274 (enum omp_mask2): Remove OMP_CLAUSE_DETACH.
1275 (gfc_match_omp_clauses): Handle OMP_CLAUSE_DETACH for OpenMP.
1276 (OMP_TASK_CLAUSES): Add OMP_CLAUSE_DETACH.
1277 (resolve_omp_clauses): Prevent use of detach with mergeable and
1278 overriding the data sharing mode of the event handle.
1279 * trans-openmp.c (gfc_trans_omp_clauses): Handle detach clause.
1280 * trans-types.c (gfc_c_intptr_kind): New.
1281 (gfc_init_kinds): Initialize gfc_c_intptr_kind.
1282 * types.def
1283 (BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT): Rename
1284 to...
1285 (BT_FN_VOID_OMPFN_PTR_OMPCPYFN_LONG_LONG_BOOL_UINT_PTR_INT_PTR):
1286 ...this. Add extra argument.
1287
1288 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1289
1290 * gfortran.h (gfc_resolve_substring): Add prototype.
1291 * primary.c (match_string_constant): Simplify substrings with
1292 constant starting and ending points.
1293 * resolve.c: Rename resolve_substring to gfc_resolve_substring.
1294 (gfc_resolve_ref): Use renamed function gfc_resolve_substring.
1295
1296 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1297
1298 PR fortran/98661
1299 * resolve.c (resolve_component): Derived type components with
1300 ALLOCATABLE or POINTER attribute shall have a deferred shape.
1301
1302 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1303
1304 Revert:
1305 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1306
1307 PR fortran/98661
1308 * resolve.c (resolve_component): Derived type components with
1309 ALLOCATABLE or POINTER attribute shall have a deferred shape.
1310
1311 2021-01-14 Harald Anlauf <anlauf@gmx.de>
1312
1313 PR fortran/98661
1314 * resolve.c (resolve_component): Derived type components with
1315 ALLOCATABLE or POINTER attribute shall have a deferred shape.
1316
1317 2021-01-08 Paul Thomas <pault@gcc.gnu.org>
1318
1319 PR fortran/93794
1320 * trans-expr.c (gfc_conv_component_ref): Remove the condition
1321 that deferred character length components only be allocatable.
1322
1323 2021-01-08 Paul Thomas <pault@gcc.gnu.org>
1324
1325 PR fortran/98458
1326 * simplify.c (is_constant_array_expr): If an array constructor
1327 expression has elements other than constants or structures, try
1328 fixing the expression with gfc_reduce_init_expr. Also, if shape
1329 is NULL, obtain the array size and set it.
1330
1331 2021-01-07 Paul Thomas <pault@gcc.gnu.org>
1332
1333 PR fortran/93701
1334 * resolve.c (find_array_spec): Put static prototype for
1335 resolve_assoc_var before this function and call for associate
1336 variables.
1337
1338 2021-01-06 Harald Anlauf <anlauf@gmx.de>
1339
1340 * resolve.c (resolve_component): Add check for valid CLASS
1341 reference before trying to access CLASS data.
1342
1343 2021-01-04 Martin Liska <mliska@suse.cz>
1344
1345 * ChangeLog-2018: Remove duplicate ChangeLog entries.
1346
1347 2021-01-01 Harald Anlauf <anlauf@gmx.de>
1348
1349 * class.c (gfc_find_vtab): Add check on attribute is_class.
1350
1351 2021-01-01 Jakub Jelinek <jakub@redhat.com>
1352
1353 * gfortranspec.c (lang_specific_driver): Update copyright notice
1354 dates.
1355 * gfc-internals.texi: Bump @copying's copyright year.
1356 * gfortran.texi: Ditto.
1357 * intrinsic.texi: Ditto.
1358 * invoke.texi: Ditto.
1359
1360 2021-01-01 Jakub Jelinek <jakub@redhat.com>
1361
1362 * ChangeLog-2020: Rotate ChangeLog. New file.
1363
1364 \f
1365 Copyright (C) 2021 Free Software Foundation, Inc.
1366
1367 Copying and distribution of this file, with or without modification,
1368 are permitted in any medium without royalty provided the copyright
1369 notice and this notice are preserved.