1 2017-11-13 Fritz Reese <fritzoreese@gmail.com>
4 * decl.c (match_clist_expr): Replace gcc_assert with proper
5 handling of bad result from spec_size().
6 * resolve.c (check_data_variable): Avoid NULL dereference when passing
9 2017-11-11 Janus Weil <janus@gcc.gnu.org>
12 * resolve.c (update_compcall_arglist): Improve error recovery,
15 2017-11-10 Fritz Reese <fritzoreese@gmail.com>
18 * gfortran.h (gfc_build_init_expr): New prototype.
19 * invoke.texi (finit-derived): Update documentation.
20 * expr.c (gfc_build_init_expr): New, from gfc_build_default_init_expr.
21 (gfc_build_default_init_expr): Redirect to gfc_build_init_expr(,,false)
22 (component_initializer): Force building initializers using
23 gfc_build_init_expr(,,true).
25 2017-11-10 Martin Sebor <msebor@redhat.com>
28 * gcc/fortran/decl.c (build_sym): Use strcpy instead of strncpy.
30 2017-11-10 Paul Thomas <pault@gcc.gnu.org>
33 * trans-stmt.c (gfc_trans_allocate): Remove the gcc_assert on
34 null string length for assumed length typespec and set
35 expr3_esize to NULL_TREE;
37 2017-11-09 Paul Thomas <pault@gcc.gnu.org>
40 * check.c (same_type_check): Introduce a new argument 'assoc'
41 with default value false. If this is true, use the symbol type
42 spec of BT_PROCEDURE expressions.
43 (gfc_check_associated): Set 'assoc' true in the call to
46 2017-11-09 Steven G. Kargl <kargl@gcc.gnu.org>
49 * interface.c (symbol_rank): Check for NULL pointer.
51 2017-11-08 Steven G. Kargl <kargl@kgcc.gnu.org>
54 * simplify.c(gfc_simplify_transfer): Do not dereference a NULL pointer.
57 2017-11-08 Steven G. Kargl <kargl@gcc.gnu.org>
60 * arith.c (gfc_hollerith2character): Clear pad.
62 2017-11-08 Janne Blomqvist <jb@gcc.gnu.org>
65 * convert.c (truthvalue_conversion): Use logical_type_node.
66 * trans-array.c (gfc_trans_allocate_array_storage): Likewise.
67 (gfc_trans_create_temp_array): Likewise.
68 (gfc_trans_array_ctor_element): Likewise.
69 (gfc_trans_array_constructor_value): Likewise.
70 (trans_array_constructor): Likewise.
71 (trans_array_bound_check): Likewise.
72 (gfc_conv_array_ref): Likewise.
73 (gfc_trans_scalarized_loop_end): Likewise.
74 (gfc_conv_array_extent_dim): Likewise.
75 (gfc_array_init_size): Likewise.
76 (gfc_array_allocate): Likewise.
77 (gfc_trans_array_bounds): Likewise.
78 (gfc_trans_dummy_array_bias): Likewise.
79 (gfc_conv_array_parameter): Likewise.
80 (duplicate_allocatable): Likewise.
81 (duplicate_allocatable_coarray): Likewise.
82 (structure_alloc_comps): Likewise
83 (get_std_lbound): Likewise
84 (gfc_alloc_allocatable_for_assignment): Likewise
85 * trans-decl.c (add_argument_checking): Likewise
86 (gfc_generate_function_code): Likewise
87 * trans-expr.c (gfc_copy_class_to_class): Likewise
88 (gfc_trans_class_array_init_assign): Likewise
89 (gfc_trans_class_init_assign): Likewise
90 (gfc_conv_expr_present): Likewise
91 (gfc_conv_substring): Likewise
92 (gfc_conv_cst_int_power): Likewise
93 (gfc_conv_expr_op): Likewise
94 (gfc_conv_procedure_call): Likewise
95 (fill_with_spaces): Likewise
96 (gfc_trans_string_copy): Likewise
97 (gfc_trans_alloc_subarray_assign): Likewise
98 (gfc_trans_pointer_assignment): Likewise
99 (gfc_trans_scalar_assign): Likewise
100 (fcncall_realloc_result): Likewise
101 (alloc_scalar_allocatable_for_assignment): Likewise
102 (trans_class_assignment): Likewise
103 (gfc_trans_assignment_1): Likewise
104 * trans-intrinsic.c (build_fixbound_expr): Likewise
105 (gfc_conv_intrinsic_aint): Likewise
106 (gfc_trans_same_strlen_check): Likewise
107 (conv_caf_send): Likewise
108 (trans_this_image): Likewise
109 (conv_intrinsic_image_status): Likewise
110 (trans_image_index): Likewise
111 (gfc_conv_intrinsic_bound): Likewise
112 (conv_intrinsic_cobound): Likewise
113 (gfc_conv_intrinsic_mod): Likewise
114 (gfc_conv_intrinsic_dshift): Likewise
115 (gfc_conv_intrinsic_dim): Likewise
116 (gfc_conv_intrinsic_sign): Likewise
117 (gfc_conv_intrinsic_ctime): Likewise
118 (gfc_conv_intrinsic_fdate): Likewise
119 (gfc_conv_intrinsic_ttynam): Likewise
120 (gfc_conv_intrinsic_minmax): Likewise
121 (gfc_conv_intrinsic_minmax_char): Likewise
122 (gfc_conv_intrinsic_anyall): Likewise
123 (gfc_conv_intrinsic_arith): Likewise
124 (gfc_conv_intrinsic_minmaxloc): Likewise
125 (gfc_conv_intrinsic_minmaxval): Likewise
126 (gfc_conv_intrinsic_btest): Likewise
127 (gfc_conv_intrinsic_bitcomp): Likewise
128 (gfc_conv_intrinsic_shift): Likewise
129 (gfc_conv_intrinsic_ishft): Likewise
130 (gfc_conv_intrinsic_ishftc): Likewise
131 (gfc_conv_intrinsic_leadz): Likewise
132 (gfc_conv_intrinsic_trailz): Likewise
133 (gfc_conv_intrinsic_mask): Likewise
134 (gfc_conv_intrinsic_spacing): Likewise
135 (gfc_conv_intrinsic_rrspacing): Likewise
136 (gfc_conv_intrinsic_size): Likewise
137 (gfc_conv_intrinsic_sizeof): Likewise
138 (gfc_conv_intrinsic_transfer): Likewise
139 (gfc_conv_allocated): Likewise
140 (gfc_conv_associated): Likewise
141 (gfc_conv_same_type_as): Likewise
142 (gfc_conv_intrinsic_trim): Likewise
143 (gfc_conv_intrinsic_repeat): Likewise
144 (conv_isocbinding_function): Likewise
145 (conv_intrinsic_ieee_is_normal): Likewise
146 (conv_intrinsic_ieee_is_negative): Likewise
147 (conv_intrinsic_ieee_copy_sign): Likewise
148 (conv_intrinsic_move_alloc): Likewise
149 * trans-io.c (set_parameter_value_chk): Likewise
150 (set_parameter_value_inquire): Likewise
151 (set_string): Likewise
152 * trans-openmp.c (gfc_walk_alloc_comps): Likewise
153 (gfc_omp_clause_default_ctor): Likewise
154 (gfc_omp_clause_copy_ctor): Likewise
155 (gfc_omp_clause_assign_op): Likewise
156 (gfc_omp_clause_dtor): Likewise
157 (gfc_omp_finish_clause): Likewise
158 (gfc_trans_omp_clauses): Likewise
159 (gfc_trans_omp_do): Likewise
160 * trans-stmt.c (gfc_trans_goto): Likewise
161 (gfc_trans_sync): Likewise
162 (gfc_trans_arithmetic_if): Likewise
163 (gfc_trans_simple_do): Likewise
164 (gfc_trans_do): Likewise
165 (gfc_trans_forall_loop): Likewise
166 (gfc_trans_where_2): Likewise
167 (gfc_trans_allocate): Likewise
168 (gfc_trans_deallocate): Likewise
169 * trans-types.c (gfc_init_types): Initialize logical_type_node and
170 their true/false trees.
171 (gfc_get_array_descr_info): Use logical_type_node.
172 * trans-types.h (logical_type_node): New tree.
173 (logical_true_node): Likewise.
174 (logical_false_node): Likewise.
175 * trans.c (gfc_trans_runtime_check): Use logical_type_node.
176 (gfc_call_malloc): Likewise
177 (gfc_allocate_using_malloc): Likewise
178 (gfc_allocate_allocatable): Likewise
179 (gfc_add_comp_finalizer_call): Likewise
180 (gfc_add_finalizer_call): Likewise
181 (gfc_deallocate_with_status): Likewise
182 (gfc_deallocate_scalar_with_status): Likewise
183 (gfc_call_realloc): Likewise
185 2017-11-06 Paul Thomas <pault@gcc.gnu.org>
188 * trans-expr.c (gfc_map_intrinsic_function): Return false for
189 bounds without the DIM argument instead of ICEing.
191 2017-11-06 Martin Liska <mliska@suse.cz>
194 * options.c (gfc_post_options): Set default value of
195 -Wreturn-type to false.
197 2017-11-05 Thomas Koenig <tkoenig@gcc.gnu.org>
200 * lang.opt (ffrontend-loop-interchange): New option.
201 (Wfrontend-loop-interchange): New option.
202 * options.c (gfc_post_options): Handle ffrontend-loop-interchange.
203 * frontend-passes.c (gfc_run_passes): Run
204 optimize_namespace if flag_frontend_optimize or
205 flag_frontend_loop_interchange are set.
206 (optimize_namespace): Run functions according to flags set;
207 also call index_interchange.
208 (ind_type): New function.
209 (has_var): New function.
210 (index_cost): New function.
211 (loop_comp): New function.
213 2017-11-05 Paul Thomas <pault@gcc.gnu.org>
216 * resolve.c (resolve_ordinary_assign): Do not add the _data
217 component for class valued array constructors being assigned
218 to derived type arrays.
219 * trans-array.c (gfc_trans_array_ctor_element): Take the _data
220 of class valued elements for assignment to derived type arrays.
222 2017-11-05 Paul Thomas <pault@gcc.gnu.org>
226 * resolve.c (resolve_component): There is no need to resolve
227 the components of a use associated vtype.
228 (resolve_fl_derived): Unconditionally generate a vtable for any
229 module derived type, as long as the standard is F2003 or later
230 and it is not a vtype or a PDT template.
232 2017-11-05 Tom de Vries <tom@codesourcery.com>
235 * parse.c (match, matcha, matchs, matcho, matchds, matchdo): Remove
236 semicolon after "do {} while (0)".
238 2017-11-04 Andre Vehreschild <vehre@gcc.gnu.org>
240 * trans-expr.c (gfc_trans_assignment_1): Character kind conversion may
241 create a loop variant temporary, too.
242 * trans-intrinsic.c (conv_caf_send): Treat char arrays as arrays and
244 * trans.c (get_array_span): Take the character kind into account when
245 doing pointer arithmetic.
247 2017-11-04 Thomas Koenig <tkoenig@gcc.gnu.org>
250 * gfortran.h (gfc_check_f): Replace fm3l with fm4l.
251 * intrinsic.h (gfc_resolve_maxloc): Add gfc_expr * to argument
253 (gfc_resolve_minloc): Likewise.
254 * check.c (gfc_check_minloc_maxloc): Handle kind argument.
255 * intrinsic.c (add_sym_3_ml): Rename to
256 (add_sym_4_ml): and handle kind argument.
257 (add_function): Replace add_sym_3ml with add_sym_4ml and add
258 extra arguments for maxloc and minloc.
259 (check_specific): Change use of check.f3ml with check.f4ml.
260 * iresolve.c (gfc_resolve_maxloc): Handle kind argument. If
261 the kind is smaller than the smallest library version available,
262 use gfc_default_integer_kind and convert afterwards.
263 (gfc_resolve_minloc): Likewise.
265 2017-11-04 Paul Thomas <pault@gcc.gnu.org>
268 * trans-decl.c (gfc_trans_deferred_vars): Do a better job of a
269 case where 'tmp' was used unititialized and remove TODO.
271 2017-11-03 Steven G. Kargl <kargl@gcc.gnu.org>
274 * resolve.c (resolve_equivalence): An entity in a common block within
275 a module cannot appear in an equivalence statement if the entity is
276 with a pure procedure.
278 2017-10-31 Jim Wilson <wilson@tuliptree.org>
280 * parse.c (unexpected_eof): Call gcc_unreachable before return.
282 2017-10-30 Paul Thomas <pault@gcc.gnu.org>
285 * trans_expr.c (gfc_conv_procedure_call): When passing a class
286 argument to an unlimited polymorphic dummy, it is wrong to cast
287 the passed expression as unlimited, unless it is unlimited. The
288 correct way is to assign to each of the fields and set the _len
291 2017-10-30 Steven G. Kargl <kargl@gcc.gnu.org>
293 * resolve.c (resolve_transfer): Set derived to correct symbol for
296 2017-10-29 Jim Wilson <wilson@tuliptree.org>
298 * invoke.texi: Delete adb and sdb references.
300 2017-10-28 Andre Vehreschild <vehre@gcc.gnu.org>
302 * check.c (gfc_check_co_reduce): Clarify error message.
304 2017-10-28 Paul Thomas <pault@gcc.gnu.org>
307 * trans-expr.c (trans_class_vptr_len_assignment): 'vptr_expr'
308 must only be set if the right hand side expression is of type
311 2017-10-27 Steven G. Kargl <kargl@gcc.gnu.org>
314 * match.c (gfc_match_allocate): Exit early on syntax error.
316 2017-10-27 Thomas Koenig <tkoenig@gcc.gnu.org>
319 * simplify.c (is_constant_array_expr): If the expression is
320 a parameter array, call gfc_simplify_expr.
322 2017-10-25 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
324 * match.c (gfc_match_type_is): Fix typo in error message.
326 2017-10-21 Paul Thomas <pault@gcc.gnu.org>
329 * decl.c (gfc_get_pdt_instance): Remove the error message that
330 the parameter does not have a corresponding component since
331 this is now taken care of when the derived type is resolved. Go
332 straight to error return instead.
333 (gfc_match_formal_arglist): Make the PDT relevant errors
334 immediate so that parsing of the derived type can continue.
335 (gfc_match_derived_decl): Do not check the match status on
336 return from gfc_match_formal_arglist for the same reason.
337 * resolve.c (resolve_fl_derived0): Check that each type
338 parameter has a corresponding component.
341 * resolve.c (resolve_generic_f): Check that the derived type
342 can be used before resolving the struture constructor.
345 * symbol.c (check_conflict): Add the conflicts involving PDT
346 KIND and LEN attributes.
348 2017-10-19 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
350 * interface.c (check_sym_interfaces, check_uop_interfaces,
351 gfc_check_interfaces): Base interface_name buffer off
354 2017-10-19 Jakub Jelinek <jakub@redhat.com>
357 * gfortran.h (gfc_resolve_do_iterator): Add a bool arg.
358 (gfc_resolve_omp_local_vars): New declaration.
359 * openmp.c (omp_current_ctx): Make static.
360 (gfc_resolve_omp_parallel_blocks): Handle EXEC_OMP_TASKLOOP
361 and EXEC_OMP_TASKLOOP_SIMD.
362 (gfc_resolve_do_iterator): Add ADD_CLAUSE argument, if false,
363 don't actually add any clause. Move omp_current_ctx test
365 (handle_local_var, gfc_resolve_omp_local_vars): New functions.
366 * resolve.c (gfc_resolve_code): Call gfc_resolve_omp_parallel_blocks
367 instead of just gfc_resolve_omp_do_blocks for EXEC_OMP_TASKLOOP
368 and EXEC_OMP_TASKLOOP_SIMD.
369 (gfc_resolve_code): Adjust gfc_resolve_do_iterator caller.
370 (resolve_codes): Call gfc_resolve_omp_local_vars.
372 2017-10-19 Bernhard Reutner-Fischer <aldot@gcc.gnu.org>
374 * gfortran.h (gfc_lookup_function_fuzzy): New declaration.
375 (gfc_closest_fuzzy_match): New declaration.
376 (vec_push): New definition.
377 * misc.c (gfc_closest_fuzzy_match): New definition.
378 * resolve.c: Include spellcheck.h.
379 (lookup_function_fuzzy_find_candidates): New static function.
380 (lookup_uop_fuzzy_find_candidates): Likewise.
381 (lookup_uop_fuzzy): Likewise.
382 (resolve_operator) <INTRINSIC_USER>: Call lookup_uop_fuzzy.
383 (gfc_lookup_function_fuzzy): New definition.
384 (resolve_unknown_f): Call gfc_lookup_function_fuzzy.
385 * interface.c (check_interface0): Likewise.
386 (lookup_arg_fuzzy_find_candidates): New static function.
387 (lookup_arg_fuzzy ): Likewise.
388 (compare_actual_formal): Call lookup_arg_fuzzy.
389 * symbol.c: Include spellcheck.h.
390 (lookup_symbol_fuzzy_find_candidates): New static function.
391 (lookup_symbol_fuzzy): Likewise.
392 (gfc_set_default_type): Call lookup_symbol_fuzzy.
393 (lookup_component_fuzzy_find_candidates): New static function.
394 (lookup_component_fuzzy): Likewise.
395 (gfc_find_component): Call lookup_component_fuzzy.
397 2017-10-18 Thomas Koenig <tkoenig@gcc.gnu.org>
400 * frontend-passes.c (combine_array_constructor): If an array
401 constructor is all constants and has more elements than a small
402 constant, don't convert a*[b,c] to [a*b,a*c] to reduce compilation
405 2017-10-18 Thomas Koenig <tkoenig@gcc.gnu.org>
408 * resolve.c (resovle_symbol): Change gcc_assert to
409 sensible error message.
411 2017-10-18 Paul Thomas <pault@gcc.gnu.org>
414 * trans_decl.c (gfc_get_symbol_decl): Procedure symbols that
415 have the 'used_in_submodule' attribute should be processed by
416 'gfc_get_extern_function_decl'.
418 2017-10-16 Fritz Reese <fritzoreese@gmail.com>
421 * trans-io.c (transfer_expr): Treat BT_UNION as BT_DERIVED.
423 2017-10-15 Thomas Koenig <tkoenig@gcc.gnu.org>
426 * fortran/scanner.c (last_error_char): New global variable.
427 (gfc_scanner_init_1): Set last_error_char to NULL.
428 (gfc_gobble_whitespace): If a character not printable or
429 not newline, issue an error.
431 2017-10-13 Paul Thomas <pault@gcc.gnu.org>
434 * resolve.c (resolve_symbol): Ensure that derived type array
435 results get default initialization.
437 2017-10-11 Nathan Sidwell <nathan@acm.org>
439 * cpp.c (gfc_cpp_add_include_path): Update incpath_e names.
440 (gfc_cpp_add_include_path_after): Likewise.
442 2017-10-10 Richard Sandiford <richard.sandiford@linaro.org>
444 * target-memory.c (gfc_interpret_logical): Use wi::to_wide when
445 operating on trees as wide_ints.
446 * trans-const.c (gfc_conv_tree_to_mpz): Likewise.
447 * trans-expr.c (gfc_conv_cst_int_power): Likewise.
448 * trans-intrinsic.c (trans_this_image): Likewise.
449 (gfc_conv_intrinsic_bound): Likewise.
450 (conv_intrinsic_cobound): Likewise.
452 2017-10-08 Steven G. Kargl <kargl@gcc.gnu.org>
454 * check.c (gfc_check_x): Remove function.
455 * intrinsic.c (add_functions): Use gfc_check_fn_r.
457 2017-10-08 Paul Thomas <pault@gcc.gnu.org>
460 * module.c : Bump up MOD_VERSION to 15.
461 (mio_component): Edit comment about PDT specification list.
462 (mio_expr, mio_symbol): Include the expression and symbol PDT
463 specification lists in the same way as in mio_component.
465 2017-10-08 Thomas Koenig <tkoenig@gcc.gnu.org>
467 * dump_prase_tree (show_symbol): Output list of variables in
469 (show_code_node): Add new line for ELSE and END DO for DO
471 * invoke.texi: Document that the output of
472 -fdump-fortran-original, -fdump-fortran-optimized and
473 -fdump-parse-tree is unsable and may lead to ICEs.
475 2017-10-07 Paul Thomas <pault@gcc.gnu.org>
478 * class.c (gfc_find_derived_vtab): Return NULL for a passed
479 pdt template to prevent bad procedures from being written.
480 * decl.c (gfc_get_pdt_instance): Do not use the default
481 initializer for pointer and allocatable pdt type components. If
482 the component is allocatbale, set the 'alloc_comp' attribute of
484 * module.c : Add a prototype for 'mio_actual_arglist'. Add a
485 boolean argument 'pdt'.
486 (mio_component): Call it for the parameter list of pdt type
487 components with 'pdt' set to true.
488 (mio_actual_arg): Add the boolean 'pdt' and, if it is set, call
489 mio_integer for the 'spec_type'.
490 (mio_actual_arglist): Add the boolean 'pdt' and use it in the
491 call to mio_actual_arg.
492 (mio_expr, mio_omp_udr_expr): Call mio_actual_arglist with
494 * resolve.c (get_pdt_spec_expr): Add the parameter name to the
495 KIND parameter error.
496 (get_pdt_constructor): Check that cons->expr is non-null.
497 * trans-array.c (structure_alloc_comps): For deallocation of
498 allocatable components, ensure that parameterized components
499 are deallocated first. Likewise, when parameterized components
500 are allocated, nullify allocatable components first. Do not
501 recurse into pointer or allocatable pdt components while
502 allocating or deallocating parameterized components. Test that
503 parameterized arrays or strings are allocated before freeing
505 (gfc_trans_pointer_assignment): Call the new function. Tidy up
506 a minor whitespace issue.
507 trans-decl.c (gfc_trans_deferred_vars): Set 'tmp' to NULL_TREE
508 to prevent the expression from being used a second time.
510 2017-10-07 Thomas Koenig <tkoenig@gcc.gnu.org>
513 * expr.c (gfc_check_pointer_assign): Error
514 for non-contiguous rhs.
516 2017-10-07 Thomas Koenig <tkoenig@gcc.gnu.org>
518 * gfortran.h (async_io_dt): Add external reference.
519 * io.c (async_io_dt): Add variable.
520 (compare_to_allowed_values): Add prototyte. Add optional argument
521 num. If present, set it to the number of the entry that was
523 (check_io_constraints): If this is for an asynchronous I/O
524 statement, set async_io_dt and set the asynchronous flag for
526 * resolve.c (resolve_transfer): If async_io_dt is set, set
527 the asynchronous flag on the variable.
528 (resolve_fl_namelist): If async_io_dt is set, set the asynchronous
529 flag on all elements of the namelist.
531 2017-10-04 Paul Thomas <pault@gcc.gnu.org>
535 * resolve.c (resolve_assoc_var): Deferred character type
536 associate names must not receive an integer conatant length.
537 * symbol.c (gfc_is_associate_pointer): Deferred character
538 length functions also require an associate pointer.
539 * trans-decl.c (gfc_get_symbol_decl): Deferred character
540 length functions or derived type components require the assoc
541 name to have variable string length.
542 * trans-stmt.c (trans_associate_var): Set the string length of
543 deferred string length associate names. The address expression
544 is not needed for allocatable, pointer or dummy targets. Change
545 the comment about defered string length targets.
547 2017-10-03 Thomas Koenig <tkoenig@gcc.gnu.org>
549 * io.c (match_wait_element): Correctly match END and EOR tags.
550 * dump-parse-tree.c (show_code_node): Handle EXEC_WAIT.
552 2017-10-02 Paul Thomas <pault@gcc.gnu.org>
555 * resolve.c (gfc_resolve_code): Simplify condition for class
556 pointer assignments becoming regular assignments by asserting
557 that only class valued targets are permitted.
558 * trans-expr.c (trans_class_pointer_fcn): New function using a
559 block of code from gfc_trans_pointer_assignment.
560 (gfc_trans_pointer_assignment): Call the new function. Tidy up
561 a minor whitespace issue.
563 2017-10-01 Dominique d'Humieres <dominiq@lps.ens.fr>
566 * parse.c (gfc_global_used): Replace the gfc_internal_error
569 2017-09-29 Dominique d'Humieres <dominiq@lps.ens.fr>
572 * interface.c (compare_actual_formal): Change warnings to errors
573 when "Actual argument contains too few elements for dummy
574 argument", unless -std=legacy is used.
576 2017-09-27 Thomas Schwinge <thomas@codesourcery.com>
578 * lang.opt <Wdo-subscript>: End help text with a period.
580 2017-09-26 Thomas Koenig <tkoenig@gcc.gnu.org>
582 * frontend-passes.c (do_subscript): Don't do anything
583 if inside an associate list.
585 2017-09-25 Thomas Koenig <tkoenig@gcc.gnu.org>
587 * lang.opt: Add -Wdo-subscript.
588 * frontend-passes.c (do_t): New type.
589 (doloop_list): Use variable of do_type.
590 (if_level): Variable to track if levels.
591 (select_level): Variable to track select levels.
592 (gfc_run_passes): Initialize i_level and select_level.
593 (doloop_code): Record current level of if + select
594 level in doloop_list. Add seen_goto if there could
595 be a branch outside the loop. Use different type for
597 (doloop_function): Call do_intent and do_subscript; move
598 functionality of checking INTENT to do_intent.
599 (insert_index_t): New type, for callback_insert_index.
600 (callback_insert_index): New function.
601 (insert_index): New function.
602 (do_subscript): New function.
603 (do_intent): New function.
604 (gfc_code_walker): Keep track of if_level and select_level.
605 * invoke.texi: Document -Wdo-subscript.
607 2017-09-25 Janne Blomqvist <jb@gcc.gnu.org>
609 * trans.c (gfc_unlikely): Remove unnecessary fold_convert.
610 (gfc_likely): Likewise.
612 2017-09-24 Thomas Koenig <tkoenig@gcc.gnu.org>
613 Steven G. Kargl <kargl@gcc.gnu.org>
616 * expr.c (gfc_get_full_arrayspec_from_expr): If there is
617 no symtree, set array spec to NULL.
619 2017-09-23 Janus Weil <janus@gcc.gnu.org>
622 * lang.opt: Add the options -fdefault-real-10 and -fdefault-real-16.
623 Rename flag_default_real to flag_default_real_8.
624 * invoke.texi: Add documentation.
625 * module.c (use_iso_fortran_env_module): flag_default_real is renamed.
626 * trans-types.c (gfc_init_kinds): Implement the flags
627 -fdefault-real-10 and -fdefault-real-16. Make -fdefault-double-8 work
628 without -fdefault-real-8.
630 2017-09-21 Paul Thomas <pault@gcc.gnu.org>
633 * match.c (gfc_match_associate): Before failing the association
634 try again, allowing a proc pointer selector.
639 * primary.c (gfc_match_varspec): Introduce 'tgt_expr', which
640 points to the associate selector, if any. Go through selector
641 references, after resolution for variables, to catch any full
642 or section array references. If a class associate name does
643 not have the same declared type as the selector, resolve the
644 selector and copy the declared type to the associate name.
645 Before throwing a no implicit type error, resolve all allowed
646 selector expressions, and copy the resulting typespec.
649 * resolve.c (resolve_assoc_var): Selector must cannot be the
650 NULL expression and it must have a type.
653 * resolve.c (resolve_symbol): Allow associate names to be
656 2017-09-21 Cesar Philippidis <cesar@codesourcery.com>
658 * openmp.c (gfc_match_oacc_wait): Don't restrict wait directive
659 arguments to constant integers.
661 2017-09-17 Paul Thomas <pault@gcc.gnu.org>
664 * decl.c (gfc_get_pdt_instance): Use the component initializer
665 expression for the default, rather than the parameter value.
666 * resolve.c (resolve_pdt): New function.
667 (resolve_symbol): Call it. Remove false error, prohibiting
668 deferred type parameters for dummy arguments.
671 * primary.c (gfc_match_varspec): If the type of an associate
672 name is unknown and yet there is a match, try resolving the
673 target expression and using its type.
675 2017-09-15 Paul Thomas <pault@gcc.gnu.org>
678 trans-decl.c (gfc_trans_deferred_vars): Do not null the 'span'
679 field if the symbol is either implicitly or explicitly saved.
681 2017-09-13 Paul Thomas <pault@gcc.gnu.org>
684 * decl.c (match_char_kind): If the kind expression is
685 parameterized, save it in saved_kind_expr and set kind = 0.
686 (gfc_get_pdt_instance): Resolve and simplify before emitting
687 error on expression kind. Insert a missing simplification after
688 insertion of kind expressions.
690 2017-09-12 Paul Thomas <pault@gcc.gnu.org>
694 * decl.c (variable_decl): Check pdt template components for
695 appearance of KIND/LEN components in the type parameter name
696 list, that components corresponding to type parameters have
697 either KIND or LEN attributes and that KIND or LEN components
698 are scalar. Copy the initializer to the parameter value.
699 (gfc_get_pdt_instance): Add a label 'error_return' and follow
700 it with repeated code, while replacing this code with a jump.
701 Check if a parameter appears as a component in the template.
702 Make sure that the parameter expressions are integer. Validate
704 (gfc_match_decl_type_spec): Search for pdt_types in the parent
705 namespace since they are instantiated in the template ns.
706 * expr.c (gfc_extract_int): Use a KIND parameter if it
707 appears as a component expression.
708 (gfc_check_init_expr): Allow expressions with the pdt_kind
710 *primary.c (gfc_match_actual_arglist): Make sure that the first
711 keyword argument is recognised when 'pdt' is set.
713 2017-09-10 Paul Thomas <pault@gcc.gnu.org>
721 * expr.c (is_subref_array): Add class pointer array dummies
722 to the list of expressions that return true.
723 * trans-array.c: Add SPAN_FIELD and update indices for
725 (gfc_conv_descriptor_span, gfc_conv_descriptor_span_get,
726 gfc_conv_descriptor_span_set, is_pointer_array,
727 get_array_span): New functions.
728 (gfc_get_descriptor_offsets_for_info): New function to preserve
729 API for access to descriptor fields for trans-types.c.
730 (gfc_conv_scalarized_array_ref): If the expression is a subref
731 array, make sure that info->descriptor is a descriptor type.
732 Otherwise, if info->descriptor is a pointer array, set 'decl'
733 and fix it if it is a component reference.
734 (build_array_ref): Simplify handling of class array refs by
735 passing the vptr to gfc_build_array_ref rather than generating
736 the pointer arithmetic in this function.
737 (gfc_conv_array_ref): As in gfc_conv_scalarized_array_ref, set
739 (gfc_array_allocate): Set the span field if this is a pointer
740 array. Use the expr3 element size if it is available, so that
741 the dynamic type element size is used.
742 (gfc_conv_expr_descriptor): Set the span field for pointer
744 * trans-array.h: Prototypes for gfc_conv_descriptor_span_get
745 gfc_conv_descriptor_span_set and
746 gfc_get_descriptor_offsets_for_info added.
747 trans-decl.c (gfc_get_symbol_decl): If a non-class pointer
748 array, mark the declaration as a GFC_DECL_PTR_ARRAY_P. Remove
749 the setting of GFC_DECL_SPAN.
750 (gfc_trans_deferred_vars): Set the span field to zero in thge
752 * trans-expr.c (gfc_conv_procedure_call): Do not use copy-in/
753 copy-out to pass subref expressions to a pointer dummy.
754 (gfc_trans_pointer_assignment): Remove code for setting of
755 GFC_DECL_SPAN. Set the 'span' field for non-class pointers to
756 class function results. Likewise for rank remap. In the case
757 that the target is not a whole array, use the target array ref
758 for remap and, since the 'start' indices are missing, set the
759 lbounds to one, as required by the standard.
760 * trans-intrinsic.c (conv_expr_ref_to_caf_ref): Pick up the
761 'token' offset from the field decl in the descriptor.
762 (conv_isocbinding_subroutine): Set the 'span' field.
763 * trans-io.c (gfc_trans_transfer): Always scalarize pointer
765 * trans-stmt.c (trans_associate_var): Set the 'span' field.
766 * trans-types.c (gfc_get_array_descriptor_base): Add the 'span'
767 field to the array descriptor.
768 (gfc_get_derived_type): Pointer array components are marked as
769 GFC_DECL_PTR_ARRAY_P.
770 (gfc_get_array_descr_info): Replaced API breaking code for
771 descriptor offset calling gfc_get_descriptor_offsets_for_info.
772 * trans.c (get_array_span): New function.
773 (gfc_build_array_ref): Simplify by calling get_array_span and
774 obtain 'span' if 'decl' or 'vptr' present.
775 * trans.h : Rename DECL_LANG_FLAG_6, GFC_DECL_SUBREF_ARRAY_P,
776 as GFC_DECL_PTR_ARRAY_P.
778 2017-09-09 Paul Thomas <pault@gcc.gnu.org>
780 * decl.c : Add decl_type_param_list, type_param_spec_list as
781 static variables to hold PDT spec lists.
782 (build_sym): Copy 'type_param_spec_list' to symbol spec_list.
783 (build_struct): Copy the 'saved_kind_expr' to the component
784 'kind_expr'. Check that KIND or LEN components appear in the
785 decl_type_param_list. These should appear as symbols in the
786 f2k_derived namespace. If the component is itself a PDT type,
787 copy the decl_type_param_list to the component param_list.
788 (gfc_match_kind_spec): If the KIND expression is parameterized
789 set KIND to zero and store the expression in 'saved_kind_expr'.
790 (insert_parameter_exprs): New function.
791 (gfc_insert_kind_parameter_exprs): New function.
792 (gfc_insert_parameter_exprs): New function.
793 (gfc_get_pdt_instance): New function.
794 (gfc_match_decl_type_spec): Match the decl_type_spec_list if it
795 is present. If it is, call 'gfc_get_pdt_instance' to obtain the
796 specific instance of the PDT.
797 (match_attr_spec): Match KIND and LEN attributes. Check for the
798 standard and for type/kind of the parameter. They are also not
799 allowed outside a derived type definition.
800 (gfc_match_data_decl): Null the decl_type_param_list and the
801 type_param_spec_list on entry and free them on exit.
802 (gfc_match_formal_arglist): If 'typeparam' is true, add the
803 formal symbol to the f2k_derived namespace.
804 (gfc_match_derived_decl): Register the decl_type_param_list
805 if this is a PDT. If this is a type extension, gather up all
806 the type parameters and put them in the right order.
807 *dump-parse-tree.c (show_attr): Signal PDT templates and the
808 parameter attributes.
809 (show_components): Output parameter atrributes and component
811 (show_symbol): Show variable parameter lists.
812 * expr.c (expr.c): Copy the expression parameter list.
813 (gfc_is_constant_expr): Pass on symbols representing PDT
815 (gfc_check_init_expr): Break on PDT KIND parameters and
816 PDT parameter expressions.
817 (gfc_check_assign): Assigning to KIND or LEN components is an
819 (derived_parameter_expr): New function.
820 (gfc_derived_parameter_expr): New function.
821 (gfc_spec_list_type): New function.
822 * gfortran.h : Add enum gfc_param_spec_type. Add the PDT attrs
823 to the structure symbol_attr. Add the 'kind_expr' and
824 'param_list' field to the gfc_component structure. Comment on
825 the reuse of the gfc_actual_arglist structure as storage for
826 type parameter spec lists. Add the new field 'spec_type' to
827 this structure. Add 'param_list' fields to gfc_symbol and
828 gfc_expr. Add prototypes for gfc_insert_kind_parameter_exprs,
829 gfc_insert_parameter_exprs, gfc_add_kind, gfc_add_len,
830 gfc_derived_parameter_expr and gfc_spec_list_type.
831 * interface.c (gfc_compare_derived_types): Treat PDTs in the
832 same way as sequence types.
833 * match.c : Add variable 'type_param_spec_list'.
834 (gfc_op2string, gfc_match_member_sep, gfc_match_label): Remove
836 (match_derived_type_spec): Match PDTs and find specific
838 (gfc_match_type_spec): Remove more trailing whitespace.
839 (gfc_match_allocate): Assumed or deferred parameters cannot
840 appear here. Copy the type parameter spec list to the expr for
841 the allocatable entity. Free 'type_param_spec_list'.
842 (gfc_match_common, gfc_match_namelist, gfc_match_module): Still
843 more trailing whitespace to remove.
844 (gfc_match_type_is): Allow PDT typespecs.
845 * match.h : Modify prototypes for gfc_match_formal_arglist and
846 gfc_match_actual_arglist.
847 * module.c (ab_attribute, mstring attr_bits): PDT attributes
849 (mio_symbol_attribute): PDT attributes handled.
850 (mio_component): Deal with 'kind_expr' field.
851 (mio_full_f2k_derived): For PDT templates, transfer the formal
852 namespace symroot to the f2k_derived namespace.
853 *primary.c (match_keyword_arg, gfc_match_actual_arglist): Add
854 modifications to handle PDT spec lists. These are flagged in
855 both cases by new boolean arguments, whose prototype defaults
857 (gfc_match_structure_constructor, match_variable): Remove yet
858 more trailing whitespace.
859 * resolve.c (get_pdt_spec_expr, get_pdt_constructor): New
861 (resolve_structure_cons): If the constructor is a PDT template,
862 call get_pdt_constructor to build it using the parameter lists
863 and then get the specific instance of the PDT.
864 (resolve_component): PDT strings need a hidden string length
865 component like deferred characters.
866 (resolve_symbol): Dummy PDTs cannot have deferred parameters.
867 * symbol.c (gfc_add_kind, gfc_add_len): New functions.
868 (free_components): Free 'kind_expr' and 'param_list' fields.
869 (gfc_free_symbol): Free the 'param_list' field.
870 (gfc_find_sym_tree): If the current state is a PDT template,
871 look for the symtree in the f2k_derived namspaces.
872 trans-array.c (structure_alloc_comps): Allocate and deallocate
873 PDTs. Check dummy arguments for compliance of LEN parameters.
874 Add the new functions to the preceeding enum.
875 (gfc_allocate_pdt_comp, gfc_deallocate_pdt_comp and
876 gfc_check_pdt_dummy): New functions calling above.
877 * trans-array.h : Add prototypes for these functions.
878 trans-decl.c (gfc_get_symbol_decl): Call gfc_defer_symbol_init
879 as appropriate for PDT symbols.
880 (gfc_trans_deferred_vars): Allocate/deallocate PDT entities as
881 they come into and out of scope. Exclude pdt_types from being
883 (gfc_trans_subcomponent_assign): PDT array components must be
884 handles as if they are allocatable.
885 * trans-stmt.c (gfc_trans_allocate): Handle initialization of
887 (gfc_trans_deallocate): Likewise.
888 * trans-types.c (gfc_get_derived_type): PDT templates must not
889 arrive here. PDT string components are handles as if deferred.
890 Similarly, PDT arrays are treated as if allocatable. PDT
891 strings are pointer types.
892 * trans.c (gfc_deferred_strlen): Handle PDT strings in the same
893 way as deferred characters.
895 2017-09-01 Jakub Jelinek <jakub@redhat.com>
898 * parse.c (decode_omp_directive): Use matchs instead of matcho for
899 end ordered and ordered directives, except for ordered depend. For
900 -fopenmp-simd and ordered depend, reject the stmt.
901 * trans-openmp.c (gfc_trans_omp_ordered): For -fopenmp-simd ignore
902 threads clause and if simd clause isn't present, just translate the
905 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
906 Alan Hayward <alan.hayward@arm.com>
907 David Sherwood <david.sherwood@arm.com>
909 * trans-types.c (gfc_init_kinds): Use opt_scalar_int_mode for
912 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
913 Alan Hayward <alan.hayward@arm.com>
914 David Sherwood <david.sherwood@arm.com>
916 * target-memory.c (size_integer): Use SCALAR_INT_TYPE_MODE.
917 (size_logical): Likewise.
919 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
920 Alan Hayward <alan.hayward@arm.com>
921 David Sherwood <david.sherwood@arm.com>
923 * trans-types.c (gfc_type_for_mode): Use is_a <scalar_int_mode>.
925 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
926 Alan Hayward <alan.hayward@arm.com>
927 David Sherwood <david.sherwood@arm.com>
929 * trans-types.c (gfc_init_kinds): Use opt_scalar_float_mode
930 and FOR_EACH_MODE_IN_CLASS.
932 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
933 Alan Hayward <alan.hayward@arm.com>
934 David Sherwood <david.sherwood@arm.com>
936 * target-memory.c (size_float): Use SCALAR_FLOAT_TYPE_MODE
937 instead of TYPE_MODE.
939 2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
940 Alan Hayward <alan.hayward@arm.com>
941 David Sherwood <david.sherwood@arm.com>
943 * trans-types.c (gfc_init_kinds): Use machine_mode instead of int
946 2017-08-28 Janus Weil <janus@gcc.gnu.org>
949 * expr.c (gfc_check_pointer_assign): Improve the check whether pointer
950 may outlive pointer target.
952 2017-08-27 Thomas Koenig <tkoenig@gcc.gnu.org>
955 * frontend-passes (inline_matumul_assign): Explicity
956 set typespec for call to CONJG.
958 2017-08-21 Jerry DeLisle <jvdelisle@gcc.gnu.org>
961 * trans-io.c (get_dtio_proc): Add check for format label and set
962 formatted flag accordingly. Reorganize the code a little.
964 2017-08-16 Thomas Koenig <tkoenig@gcc.gnu.org>
967 * frontend-passes.c (realloc_string_callback): If expression is a
968 concatenation, also check for dependency.
969 (constant_string_length): Check for presence of symtree.
971 2017-08-13 Thomas Koenig <tkoenig@gcc.gnu.org>
973 * gfortran.texi: Document format of unformatted sequential files.
975 2017-08-11 Thomas Koenig <tkoenig@gcc.gnu.org>
977 * invoke.texi: Actually commit change about -Ofast.
979 2017-08-11 Thomas Koenig <tkoenig@gcc.gnu.org>
982 * resolve.c (resolve_symbol): Adjust (and reformat)
983 comment. Perform check if a BIND(C) is declared
984 at module level regardless of whether it is typed
987 2017-08-10 Fritz Reese <fritzoreese@gmail.com>
989 * options.c (set_dec_flags): Only set legacy standards when value
992 2017-08-10 Fritz Reese <fritzoreese@gmail.com>
994 * options.c (set_dec_flags, gfc_post_options): Only set flag_d_lines
995 with -fdec when not set by user.
997 2017-08-10 Fritz Reese <fritzoreese@gmail.com>
999 * decl.c (attr_seen): New static variable.
1000 * decl.c (variable_decl): Match %FILL in STRUCTURE body.
1001 * gfortran.texi: Update documentation.
1003 2017-08-08 Martin Liska <mliska@suse.cz>
1005 * trans-types.c: Include header files.
1007 2017-08-07 Thomas Koenig <tkoenig@gcc.gnu.org>
1011 * options.c: Make -Ofast honor -fmax-stack-var-size.
1012 * invoke.texi: Document change.
1014 2017-08-01 Thomas König <tkoenig@gcc.gnu.org>
1017 * intrisic.c (gfc_convert_type_warn): Only set typespec for
1018 empty array constructors which don't have it already.
1020 2017-08-01 Thomas Koenig <tkoenig@gcc.gnu.org>
1023 * lang.opt (fc-prototypes): Add option.
1024 * gfortran.h (gfc_typespec): Add interop_kind to struct.
1025 (gfc_dump_c_prototypes): Add prototype.
1026 * decl.c (gfc_match_kind_spec): Copy symbol used for kind to typespec.
1027 * parse.c (gfc_parse_file): Call gfc_dump_prototypes.
1028 * dump-parse-tree.c (gfc_dump_c_prototypes): New function.
1029 (type_return): New enum.
1030 (get_c_type_name): New function.
1031 (write_decl): New function.
1032 (write_type): New function.
1033 (write_variable): New function.
1034 (write_proc): New function.
1035 (write_interop_decl): New function.
1036 * invoke.texi: Document -fc-prototypes.
1038 2017-08-01 Dominique d'Humieres <dominiq@lps.ens.fr>
1041 * expr.c (gfc_check_init_expr): Use the renamed name.
1043 2017-07-31 Jakub Jelinek <jakub@redhat.com>
1045 * check.c (gfc_check_num_images): Fix a pasto.
1047 2017-07-29 Jakub Jelinek <jakub@redhat.com>
1049 * trans-decl.c (gfc_trans_use_stmts): Pass false as new argument to
1050 the imported_module_or_decl debug hook.
1052 2017-07-28 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
1054 * resolve.c (find_reachable_labels): Adjust.
1056 2017-07-25 Jakub Jelinek <jakub@redhat.com>
1058 * ioparm.def: Use 1U << 31 instead of 1 << 31 as flags2 mask.
1060 2017-07-24 Thomas Koenig <tkoenig@gcc.gnu.org>
1062 * dump-parse-tree.c (show_symbol): Show binding label if present.
1064 2017-07-24 Thomas Koenig <tkoenig@gcc.gnu.org>
1065 Mikael Morin <mikael@gcc.gnu.org>
1068 * fortran/trans-array.c (gfc_conv_resolve_dependencies):
1069 Break if dependency has been found.
1071 2017-07-23 Alexander Monakov <amonakov@ispras.ru>
1073 * interface.c (pair_cmp): Fix gfc_symbol comparison. Adjust comment.
1075 2017-07-18 Nathan Sidwell <nathan@acm.org>
1077 * trans.c (gfc_build_array_ref): Use TYPE_MAX_VALUE.
1079 2017-07-09 Dominique d'Humieres <dominiq@lps.ens.fr>
1082 * class.c (class_array_ref_detected): Remove a redundant
1085 2017-07-06 Harald Anlauf <anlauf@gmx.de>
1088 * array.c (gfc_ref_dimen_size): Handle bad subscript triplets.
1090 2017-07-03 Dominique d'Humieres <dominiq@lps.ens.fr>
1093 * resolve.c (resolve_symbol): Fix typo.
1095 2017-07-03 Dominique d'Humieres <dominiq@lps.ens.fr>
1098 * symbol.c (check_conflict): Add missing "conflicts".
1100 2017-06-29 Cesar Philippidis <cesar@codesourcery.com>
1103 * openmp.c (gfc_match_oacc_routine): Check if proc_name exist before
1104 comparing the routine name against it.
1106 2017-06-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1109 * trans-stmt.c (gfc_trans_call): If no code expr, use code->loc
1110 as warning/error locus.
1112 2017-06-24 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1115 * arith.c (wprecision_int_real): Set return value before
1116 mpz_clear and then return after it.
1118 2017-06-15 Janus Weil <janus@gcc.gnu.org>
1121 * trans-expr.c (gfc_conv_procedure_call): Deallocate the result of
1122 scalar allocatable procedure-pointer components.
1124 2017-06-10 Thomas Koenig <tkoenig@gcc.gnu.org>
1127 * frontend-passes.c (traverse_io_block): Also
1128 check for variables occurring as indices multiple
1129 time in a single implied DO loop.
1131 2017-06-05 Janus Weil <janus@gcc.gnu.org>
1134 * trans-expr.c (gfc_conv_procedure_call): Fix detection of allocatable
1137 2017-06-05 Nicolas Koenig <koenigni@student.ethz.ch>
1140 * frontend-passes.c (traverse_io_block): New function.
1141 (simplify_io_impl_do): New function.
1142 (optimize_namespace): Invoke gfc_code_walker with
1143 simplify_io_impl_do.
1145 2017-06-02 Jakub Jelinek <jakub@redhat.com>
1148 * openmp.c (resolve_omp_clauses): Fix a typo.
1150 2017-05-30 David Malcolm <dmalcolm@redhat.com>
1152 * error.c (gfc_format_decoder): Update for new bool and
1153 const char ** params.
1155 2017-05-29 Thomas Koenig <tkoenig@gcc.gnu.org>
1158 * frontend-passes.c (check_conjg_transpose_variable):
1160 (has_dimen_vector_ref): Likewise
1161 (matmul_temp_args): New function. Add prototype.
1162 (optimize_namespace): Call matmul_temp_args.
1164 2017-05-28 Thomas Koenig <tkoenig@gcc.gnu.org>
1166 * frontend-passes.c (matmul_lhs_realloc): Correct
1167 allocation size for case A1B2.
1169 2017-05-25 Thomas Koenig <tkoenig@gcc.gnu.org>
1171 * dump-parse-tree.c (show_expr): Also replace
1172 with dumpfile for showing values for forgotten
1175 2017-05-24 Thomas Koenig <tkoenig@gcc.gnu.org>
1177 * dump-parse-tree.c (show_expr): Replace stdout
1178 with dumpfile for showing values.
1180 2017-05-24 Thomas Koenig <tkoenig@gcc.gnu.org>
1183 * frontend-passes.c (matrix_case): Add A2TB2.
1184 (inline_limit_check): Handle MATMUL(TRANSPOSE(A),B)
1185 (inline_matmul_assign): Likewise.
1187 2017-05-23 Thomas Schwinge <thomas@codesourcery.com>
1189 * openmp.c (OACC_KERNELS_CLAUSES): Add "OMP_CLAUSE_NUM_GANGS",
1190 "OMP_CLAUSE_NUM_WORKERS", "OMP_CLAUSE_VECTOR_LENGTH".
1192 2017-05-22 Janus Weil <janus@gcc.gnu.org>
1195 * resolve.c (resolve_fl_derived): Make sure that vtype symbols are
1198 2017-05-19 Paul Thomas <pault@gcc.gnu.org>
1201 * trans-io.c (nml_get_addr_expr): If we are dealing with class
1202 type data set tmp tree to get that address.
1203 (transfer_namelist_element): Set the array spec to point to the
1206 2017-05-19 David Malcolm <dmalcolm@redhat.com>
1209 * bbt.c (insert): Remove trailing exclamation mark from message.
1210 * decl.c (gfc_match_final_decl): Likewise.
1211 * dump-parse-tree.c (show_expr): Likewise.
1212 * module.c (gfc_use_module): Likewise.
1213 * primary.c (build_actual_constructor): Likewise.
1214 (gfc_convert_to_structure_constructor): Likewise.
1216 2017-05-19 Thomas Schwinge <thomas@codesourcery.com>
1218 * gfortran.h (enum gfc_omp_default_sharing): Add
1219 "OMP_DEFAULT_PRESENT".
1220 * dump-parse-tree.c (show_omp_clauses): Handle it.
1221 * openmp.c (gfc_match_omp_clauses): Likewise.
1222 * trans-openmp.c (gfc_trans_omp_clauses): Likewise.
1224 2017-05-18 Fritz Reese <fritzoreese@gmail.com>
1227 * decl.c (match_attr_spec, gfc_match_automatic,
1228 gfc_match_static, gfc_match_structure_decl): Unify diagnostic
1229 errors regarding -fdec options.
1230 * io.c (match_dec_etag, match_dec_vtag, match_dec_ftag): Ditto.
1232 2017-05-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1235 * trans-io.c (transfer_namelist_element): Change check from
1236 NULL_TREE to null_pointer_node.
1238 2017-05-17 Fritz Reese <fritzoreese@gmail.com>
1241 * expr.c (component_initializer): Don't generate initializers for
1243 * invoke.texi (-finit-derived): Document.
1245 2017-05-16 Paul Thomas <pault@gcc.gnu.org>
1248 * decl.c (build_sym): In a submodule allow overriding of host
1249 associated symbols from the ancestor module with a new
1252 2017-05-15 Steven G. Kargl <kargl@gcc.gnu.org>
1255 * trans-stmt.c (gfc_trans_integer_select): Remove redundant condition.
1257 2017-05-15 Steven G. Kargl <kargl@gcc.gnu.org>
1260 * expr.c (gfc_generate_initializer): If type conversion fails,
1261 check for error and return NULL.
1263 2017-05-14 Nicolas Koenig <koenigni@student.ethz.ch>
1266 * array.c (gfc_ref_dimen_size): Simplify stride
1268 * data.c (gfc_advance_section): Simplify start,
1269 end and stride expressions
1270 (gfc_advance_section): Simplify start and end
1272 (gfc_get_section_index): Simplify start expression
1274 2017-05-13 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1276 * io.c (gfc_resolve_dt): Fix returns to bool type.
1278 2017-05-11 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1281 * io.c (dtio_procs_present): Add new function to check for DTIO
1282 procedures relative to I/O statement READ or WRITE.
1283 (gfc_resolve_dt): Add namelist checks using the new function.
1284 * resolve.c (dtio_procs_present): Remove function and related
1285 namelist checks. (resolve_fl_namelist): Add check specific to
1286 Fortran 95 restriction on namelist objects.
1288 2017-05-11 Nathan Sidwell <nathan@acm.org>
1290 * trans-decl.c: Include dumpfile.h not tree-dump.h,
1292 2017-05-09 Janus Weil <janus@gcc.gnu.org>
1295 * resolve.c (gfc_resolve_finalizers): Ensure that derived-type
1296 components have a their finalizers resolved, also if the superordinate
1297 type itself has a finalizer.
1299 2017-05-08 Thomas Koenig <tkoenig@gcc.gnu.org>
1302 * frontend-passes.c (matmul_to_var_expr): New function,
1304 (matmul_to_var_code): Likewise.
1305 (optimize_namespace): Use them from gfc_code_walker.
1307 2017-05-05 David Malcolm <dmalcolm@redhat.com>
1309 * cpp.c (cb_cpp_error): Replace report_diagnostic
1310 with diagnostic_report_diagnostic.
1311 * error.c (gfc_warning): Likewise.
1312 (gfc_warning_now_at): Likewise.
1313 (gfc_warning_now): Likewise.
1314 (gfc_warning_internal): Likewise.
1315 (gfc_error_now): Likewise.
1316 (gfc_fatal_error): Likewise.
1317 (gfc_error_opt): Likewise.
1318 (gfc_internal_error): Likewise.
1320 2017-05-01 Thomas Koenig <tkoenig@gcc.gnu.org>
1323 * frontend-passes.c (inline_matmul_assign): Also check bounds
1324 for allocatable lhs and matrix-vector-multiplication.
1326 2017-04-23 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1329 * io.c (format_lex): Check for '/' and set token to FMT_SLASH.
1330 (check_format): Move FMT_DT checking code to data_desc section.
1331 * module.c (gfc_match_use): Include the case of INTERFACE_DTIO.
1333 2017-04-22 Janus Weil <janus@gcc.gnu.org>
1336 * trans-types.c (gfc_conv_procedure_call): Deallocate the components
1337 of allocatable intent(out) arguments.
1339 2017-04-21 Janus Weil <janus@gcc.gnu.org>
1342 * trans-types.c (gfc_get_derived_type): Prevent an infinite loop when
1343 building a derived type that includes a procedure pointer component
1344 with a polymorphic result.
1346 2017-04-17 Paul Thomas <pault@gcc.gnu.org>
1349 * module.c (find_symtree_for_symbol): Delete.
1350 (read_module): Remove the call to the above.
1352 2017-04-14 Janus Weil <janus@gcc.gnu.org>
1355 * class.c (generate_finalization_wrapper): Give the finalization wrapper
1356 the recursive attribute.
1358 2017-04-10 Nicolas Koenig <koenigni@student.ethz.ch>
1359 Paul Thomas <pault@gcc.gnu.org>
1362 * module.c (gfc_match_submodule): Add error
1363 if function is called in the wrong state.
1365 2017-04-10 Janus Weil <janus@gcc.gnu.org>
1368 * expr.c (gfc_check_pointer_assign): Check if procedure pointer
1369 components in a pointer assignment need an explicit interface.
1371 2017-03-18 Nicolas Koenig <koenigni@student.ethz.ch>
1374 * symbol.c (gfc_delete_symtree): If there is a period in the name, ignore
1375 everything before it.
1377 2017-03-28 Janus Weil <janus@gcc.gnu.org>
1380 * trans-io.c (transfer_namelist_element): Perform a polymorphic call
1381 to a DTIO procedure if necessary.
1383 2017-03-25 Paul Thomas <pault@gcc.gnu.org>
1387 * decl.c (access_attr_decl): Remove the error for an absent
1388 generic DTIO interface and ensure that symbol has the flavor
1391 2017-03-22 Dominique d'Humieres <dominiq@lps.ens.fr>
1394 * module.c: Remove trailing period.
1396 2017-03-22 Dominique d'Humieres <dominiq@lps.ens.fr>
1399 * decl.c: Replace '%s' with %qs.
1401 * interface.c: Likewise.
1402 * match.c: Likewise.
1403 * primary.c: Likewise.
1404 * resolve.c: Likewise.
1408 * io.c: Remove trailing spaces.
1409 * match.c: Likewise.
1410 * openmp.c: Likewise.
1411 * resolve.c: Likewise.
1412 * trans-intrinsic.c: Likewise.
1415 * expr.c: Remove a double spaces.
1418 * primary.c: Remove spurious quotes around %qs.
1420 2017-03-22 Thomas Koenig <tkoenig@gcc.gnu.org>
1423 * frontend-passes.c (combine_array_constructor): Take
1424 location of new expression from constructor expression instead
1427 2017-03-20 Nicolas Koenig <koenigni@student.ethz.ch>
1430 * symbol.c (check_conflict): Report an error if an EQUIVALENCE
1433 2017-03-18 Nicolas Koenig <koenigni@student.ethz.ch>
1436 * decl.c (add_hidden_procptr_result): Fixed Refs count of the
1437 created "ppr@" symbol.
1439 2017-03-18 Paul Thomas <pault@gcc.gnu.org>
1442 * module.c (mio_symbol_attribute): Remove reset of the flag
1443 'no_module_procedures'.
1444 (check_for_module_procedures): New function. Move declaration
1445 of 'no_module_procedures' to above it.
1446 (gfc_dump_module): Traverse namespace calling new function.
1448 2017-03-18 Paul Thomas <pault@gcc.gnu.org>
1451 * symbol.c (check_conflict): A dummy procedure in a submodule,
1452 module procedure is not an error.
1453 (gfc_add_flavor): Ditto.
1455 2017-03-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1458 * openmp.c (check_symbol_not_pointer): Adjust diagnostics.
1460 2017-03-16 Jakub Jelinek <jakub@redhat.com>
1463 * parse.c (gfc_ascii_statement): Use !$ACC for ST_OACC_ATOMIC
1464 and ST_OACC_END_ATOMIC, instead of !ACC.
1465 * trans-decl.c (finish_oacc_declare): Use !$ACC instead of $!ACC.
1466 * openmp.c (gfc_match_oacc_declare, gfc_match_oacc_wait,
1467 gfc_resolve_oacc_declare): Likewise.
1470 * error.c (gfc_format_decoder): Rename plus argument to set_locus,
1471 remove ATTRIBUTE_UNUSED from all arguments, call default_tree_printer
1472 if not a Fortran specific spec.
1473 * trans-io.c: Include options.h.
1474 (gfc_build_st_parameter): Temporarily disable -Wpadded around layout
1475 of artificial IO data structures.
1477 2017-03-15 David Malcolm <dmalcolm@redhat.com>
1480 * resolve.c (resolve_contained_fntype): Make error messages more
1481 amenable to translation.
1483 2017-03-06 Richard Biener <rguenther@suse.de>
1486 * trans.c (gfc_add_modify_loc): Weaken assert.
1488 2017-03-05 Andre Vehreschild <vehre@gcc.gnu.org>,
1489 Alessandro Fanfarillo <fanfarillo.gcc@gmail.com>
1491 * check.c (positive_check): Add new function checking constant for
1492 being greater then zero.
1493 (gfc_check_image_status): Add checking of image_status arguments.
1494 (gfc_check_failed_or_stopped_images): Same but for failed_- and
1495 stopped_images function.
1496 * dump-parse-tree.c (show_code_node): Added output of FAIL IMAGE.
1497 * gfortran.h (enum gfc_statement): Added FAIL_IMAGE_ST.
1498 (enum gfc_isym_id): Added new intrinsic symbols.
1499 (enum gfc_exec_op): Added EXEC_FAIL_IMAGE.
1500 * gfortran.texi: Added description for the new API functions. Updated
1501 coverage of gfortran of TS18508.
1502 * intrinsic.c (add_functions): Added symbols to resolve new intrinsic
1504 * intrinsic.h: Added prototypes.
1505 * iresolve.c (gfc_resolve_failed_images): Resolve the failed_images
1507 (gfc_resolve_image_status): Same for image_status.
1508 (gfc_resolve_stopped_images): Same for stopped_images.
1509 * libgfortran.h: Added prototypes.
1510 * match.c (gfc_match_if): Added matching of FAIL IMAGE statement.
1511 (gfc_match_fail_image): Match a FAIL IMAGE statement.
1512 * match.h: Added prototype.
1513 * parse.c (decode_statement): Added matching for FAIL IMAGE.
1514 (next_statement): Same.
1515 (gfc_ascii_statement): Same.
1517 * simplify.c (gfc_simplify_failed_or_stopped_images): For COARRAY=
1518 single a constant result can be returne.d
1519 (gfc_simplify_image_status): For COARRAY=single the result is constant.
1520 * st.c (gfc_free_statement): Added FAIL_IMAGE handling.
1521 * trans-decl.c (gfc_build_builtin_function_decls): Added decls of the
1523 * trans-expr.c (gfc_conv_procedure_call): This is first time all
1524 arguments of a function are optional, which is now handled here
1526 * trans-intrinsic.c (conv_intrinsic_image_status): Translate
1528 (gfc_conv_intrinsic_function): Add support for image_status.
1529 (gfc_is_intrinsic_libcall): Add support for the remaining new
1531 * trans-stmt.c (gfc_trans_fail_image): Trans a fail image.
1532 * trans-stmt.h: Add the prototype for the above.
1533 * trans.c (trans_code): Dispatch for fail_image.
1534 * trans.h: Add the trees for the new intrinsics.
1536 2017-03-03 Jerry DeLisle <jvdelisle@gcc.gnu.org>
1539 * openmp.c (check_symbol_not_pointer): Adjust diagnostic.
1541 2017-02-28 Paul Thomas <pault@gcc.gnu.org>
1544 * resolve.c (resolve_fl_procedure): Deal with the case where
1545 'submodule_name' is NULL so that gfc_error does not ICE.
1546 Reformat the error message to make it more consistent.
1548 2017-02-28 Jakub Jelinek <jakub@redhat.com>
1550 * parse.c (parse_critical_block): Use cond ? G_("...") : G_("...")
1551 instead of just cond ? "..." : "...".
1552 * scanner.c (gfc_next_char_literal): Likewise.
1553 * match.c (match_exit_cycle): Likewise.
1555 2017-02-26 Thomas Koenig <tkoenig@gcc.gnu.org>
1558 * options.c (gfc_post_options): Set default limit for matmul
1560 * invoke.texi: Document change.
1562 2017-02-25 Dominique d'Humieres <dominiq@lps.ens.fr>
1565 * interface.c (check_dtio_arg_TKR_intent): Change 'intent'
1568 2017-02-25 Dominique d'Humieres <dominiq@lps.ens.fr>
1571 * interface.c (gfc_match_end_interface): Remove spurious comma
1572 and space, replace 'got %s' with 'got %qs'.
1574 2017-02-20 Paul Thomas <pault@gcc.gnu.org>
1577 * interface.c (check_dtio_arg_TKR_intent): Supply 'must'
1578 missing from error message.
1580 2017-02-20 Paul Thomas <pault@gcc.gnu.org>
1583 * interface.c (gfc_find_typebound_dtio_proc): Guard test for
1584 flavor attribute by checking that symbol is resolved.
1586 2017-02-16 Paul Thomas <pault@gcc.gnu.org>
1589 * decl.c (access_attr_decl): Test for presence of generic DTIO
1590 interface and emit error if not present.
1592 2017-02-20 Paul Thomas <pault@gcc.gnu.org>
1595 * parse.c (check_component, parse_union): Whitespace.
1596 (set_syms_host_assoc): For a derived type, check if the module
1597 in which it was declared is one of the submodule ancestors. If
1598 it is, make the components public. Otherwise, reset attribute
1599 'host_assoc' and set 'use-assoc' so that encapsulation is
1602 2017-02-19 Paul Thomas <pault@gcc.gnu.org>
1605 * decl.c (gfc_set_constant_character_len): Whitespace.
1606 (gfc_match_end): Catch case where a procedure is contained in
1607 a module procedure and ensure that 'end procedure' is the
1608 correct termination.
1610 2017-02-19 Paul Thomas <pault@gcc.gnu.org>
1613 * resolve.c (fixup_unique_dummy): New function.
1614 (gfc_resolve_expr): Call it for dummy variables with a unique
1617 2017-02-19 Andre Vehreschild <vehre@gcc.gnu.org>
1620 * trans-expr.c (gfc_trans_assignment_1): Deref indirect refs when
1621 compiling with -fcheck=mem to check the pointer and not the data.
1623 2017-02-19 Andre Vehreschild <vehre@gcc.gnu.org>
1626 * trans-array.c (duplicate_allocatable_coarray): Ensure attributes
1627 passed are properly initialized.
1628 (structure_alloc_comps): Same.
1629 * trans-expr.c (gfc_trans_structure_assign): Same.
1631 2017-02-13 Jakub Jelinek <jakub@redhat.com>
1633 * trans-expr.c (gfc_conv_substring): Add missing space in diagnostics.
1635 2017-02-12 Thomas Koenig <tkoenig@gcc.gnu.org>
1638 * intrinsic.c (gfc_intrinsic_func_interface): Return an error
1639 for -std=f95 for disallowed transformational functions in
1640 initialization expressions.
1642 2017-02-09 Cesar Philippidis <cesar@codesourcery.com>
1643 Joseph Myers <joseph@codesourcery.com>
1645 * openmp.c (resolve_omp_clauses): Error on directives
1646 containing both tile and collapse clauses.
1647 (resolve_oacc_loop_blocks): Represent '*' tile arguments as zero.
1648 * trans-openmp.c (gfc_trans_omp_do): Lower tiled loops like
1651 2017-02-07 Steven G. Kargl <kargl@gcc.gnu.org>
1653 * trans-types.c (gfc_get_int_kind_from_width_isofortranen): Choose
1654 REAL type with the widest precision if two (or more) have the same
1657 2017-02-05 Andre Vehreschild <vehre@gcc.gnu.org>
1660 * trans-stmt.c (gfc_trans_allocate): Only deallocate the components of
1661 the temporary, when a new object was created for the temporary. Not
1662 when it is just an alias to an existing object.
1664 2017-02-05 Andre Vehreschild <vehre@gcc.gnu.org>
1667 * trans-decl.c (generate_coarray_sym_init): Retrieve the symbol's
1668 attributes before using them.
1670 2017-02-05 Andre Vehreschild <vehre@gcc.gnu.org>
1673 * trans-stmt.c (gfc_trans_allocate): Add the multiplying the _len
1674 component of unlimited polymorphic objects when source-allocating.
1676 2017-02-05 Andre Vehreschild <vehre@gcc.gnu.org>
1679 * trans-array.c (structure_alloc_comps): Ignore pointer components when
1682 2017-01-25 Maxim Ostapenko <m.ostapenko@samsung.com>
1685 * f95-lang.c (gfc_create_decls): Include stringpool.h.
1686 Pass main_input_filename to build_translation_unit_decl.
1688 2017-01-23 Thomas Koenig <tkoenig@netcologne.de>
1690 * arith.c (arith_power): If simplifying integer power expression
1691 to zero, warn if -Winteger-division is given.
1693 2017-01-22 Jakub Jelinek <jakub@redhat.com>
1696 * parse.c (matchs, matcho, matchds, matchdo): Replace return st;
1697 with { ret = st; goto finish; }.
1698 (decode_omp_directive): Allow declare simd, declare target and
1699 simd directives in PURE/ELEMENTAL procedures. Only call
1700 gfc_unset_implicit_pure on successful match of other procedures.
1702 2017-01-21 Gerald Pfeifer <gerald@pfeifer.com>
1704 * gfc-internals.texi (Symbol Versioning): Change references
1705 to www.akkadia.org to https.
1707 2017-01-21 Jakub Jelinek <jakub@redhat.com>
1709 * gfortran.h (gfc_extract_int): Change return type to bool. Add
1710 int argument with = 0.
1711 * decl.c (gfc_match_kind_spec): Adjust gfc_extract_int caller, pass
1712 1 as new last argument to it, don't emit gfc_error.
1713 (match_char_kind): Likewise.
1714 (gfc_match_decl_type_spec): Use gfc_get_string ("%s", x) instead of
1716 (gfc_match_derived_decl, match_binding_attributes): Likewise.
1717 (gfc_match_structure_decl): Don't sprintf back to name, call
1718 get_struct_decl directly with gfc_dt_upper_string (name) result.
1719 * trans-stmt.c (gfc_trans_allocate): Use gfc_get_string ("%s", x)
1720 instead of gfc_get_string (x).
1721 * module.c (gfc_dt_lower_string, gfc_dt_upper_string,
1722 gfc_match_use, gfc_match_submodule, find_true_name, mio_pool_string,
1723 mio_symtree_ref, mio_expr, mio_omp_udr_expr, load_generic_interfaces,
1724 load_omp_udrs, load_needed, read_module, dump_module,
1725 create_intrinsic_function, import_iso_c_binding_module,
1726 create_int_parameter, create_int_parameter_array, create_derived_type,
1727 use_iso_fortran_env_module): Likewise.
1728 * error.c (gfc_diagnostic_starter, gfc_diagnostic_start_span): Use
1729 pp_verbatim (context->printer, "%s", x) instead of
1730 pp_verbatim (context->printer, x).
1731 * match.c (gfc_match_small_int): Adjust gfc_extract_int caller, pass
1732 1 as new last argument to it, don't emit gfc_error.
1733 (gfc_match_small_int_expr): Likewise.
1734 * iresolve.c (gfc_get_string): Optimize format "%s" case.
1735 (resolve_bound): Use gfc_get_string ("%s", x) instead of
1737 (resolve_transformational): Formatting fix.
1738 (gfc_resolve_char_achar): Change name argument to bool is_achar,
1739 use a single format string and if is_achar add "a" before "char".
1740 (gfc_resolve_achar, gfc_resolve_char): Adjust callers.
1741 * expr.c (gfc_extract_int): Change return type to bool, return true
1742 if some error occurred. Add REPORT_ERROR argument, if non-zero
1743 call either gfc_error or gfc_error_now depending on its sign.
1744 * arith.c (arith_power): Adjust gfc_extract_int caller.
1745 * symbol.c (gfc_add_component): Use gfc_get_string ("%s", x) instead
1746 of gfc_get_string (x).
1747 (gfc_new_symtree, gfc_delete_symtree, gfc_get_uop, gfc_new_symbol,
1748 gfc_get_gsymbol, generate_isocbinding_symbol): Likewise.
1749 * openmp.c (gfc_match_omp_clauses): Adjust gfc_extract_int caller, pass
1750 -1 as new last argument to it, don't emit gfc_error_now.
1751 (gfc_match_omp_declare_reduction): Use gfc_get_string ("%s", x)
1752 instead of gfc_get_string (x).
1753 * check.c (kind_check): Adjust gfc_extract_int caller.
1754 * intrinsic.c (add_sym, find_sym, make_alias): Use
1755 gfc_get_string ("%s", x) instead of gfc_get_string (x).
1756 * simplify.c (get_kind, gfc_simplify_btest, gfc_simplify_maskr,
1757 gfc_simplify_maskl, gfc_simplify_poppar, gfc_simplify_repeat,
1758 gfc_simplify_selected_int_kind, gfc_simplify_selected_real_kind):
1759 Adjust gfc_extract_int callers.
1760 * trans-decl.c (gfc_find_module): Use gfc_get_string ("%s", x)
1761 instead of gfc_get_string (x).
1762 * matchexp.c (expression_syntax): Add const.
1763 * primary.c (match_kind_param, match_hollerith_constant,
1764 match_string_constant): Adjust gfc_extract_int callers.
1765 (match_keyword_arg): Use gfc_get_string ("%s", x) instead of
1767 * frontend-passes.c (optimize_minmaxloc): Likewise.
1769 2017-01-19 Andre Vehreschild <vehre@gcc.gnu.org>
1772 * trans-decl.c (gfc_build_qualified_array): Add static decl to parent
1773 function only, when the decl-context is not the translation unit.
1775 2017-01-18 Louis Krupp <louis.krupp@zoho.com>
1779 * trans-expr.c (gfc_conv_variable): Don't treat temporary variables
1780 as function arguments.
1781 * trans-stmt.c (forall_make_variable_temp,
1782 generate_loop_for_temp_to_lhs, gfc_trans_assign_need_temp,
1783 gfc_trans_forall_1): Don't adjust offset of forall temporary
1784 for array sections, make forall temporaries work for substring
1785 expressions, improve test coverage by adding -ftest-forall-temp
1786 option to request usage of temporary array in forall code.
1787 * lang.opt: Add -ftest-forall-temp option.
1788 * invoke.texi: Add -ftest-forall-temp option.
1790 2017-01-18 Andre Vehreschild <vehre@gcc.gnu.org>
1792 * primary.c (caf_variable_attr): Improve figuring whether the current
1793 component is the last one refed.
1794 * trans-stmt.c (gfc_trans_allocate): Do not generate sync_all calls
1795 when allocating pointer or allocatable components.
1797 2017-01-18 Andre Vehreschild <vehre@gcc.gnu.org>
1799 * gfortran.texi: Add missing parameters to caf-API functions. Correct
1800 typos and clarify some descriptions.
1802 2017-01-18 Andre Vehreschild <vehre@gcc.gnu.org>
1805 Missed some cases, here they are:
1806 * trans-decl.c (gfc_build_qualified_array): Add static tokens to the
1807 parent function's scope.
1808 * trans-expr.c (gfc_get_tree_for_caf_expr): Shorten code. Remove
1811 2017-01-13 Andre Vehreschild <vehre@gcc.gnu.org>
1814 * resolve.c (resolve_lock_unlock_event): Resolve the expression for
1815 event's until_count.
1817 2017-01-13 Andre Vehreschild <vehre@gcc.gnu.org>
1820 * trans-expr.c (gfc_get_tree_for_caf_expr): Ensure the backend_decl
1821 is valid before accessing it.
1823 2017-01-09 Jakub Jelinek <jakub@redhat.com>
1825 PR translation/79019
1826 PR translation/79020
1827 * decl.c (attr_decl1): Fix spelling in translatable string.
1828 * intrinsic.texi: Fix spelling - invokation -> invocation.
1829 * lang.opt (faggressive-function-elimination, gfc_convert): Fix
1830 typos in descriptions.
1831 * openmp.c (resolve_omp_clauses): Add missing whitespace to
1832 translatable strings.
1834 2017-01-08 Martin Sebor <msebor@redhat.com>
1836 PR tree-optimization/78913
1838 * trans-common.c (build_equiv_decl): Increase buffer size to avoid
1839 truncation for any argument.
1840 * trans-types.c (gfc_build_logical_type): Same.
1842 2017-01-07 Andre Vehreschild <vehre@gcc.gnu.org>
1846 * expr.c (gfc_check_pointer_assign): Return the same error message for
1847 rewritten coarray pointer assignments like for plain ones.
1848 * gfortran.h: Change prototype.
1849 * primary.c (caf_variable_attr): Set attributes used ones only only
1850 ones. Add setting of pointer_comp attribute.
1851 (gfc_caf_attr): Add setting of pointer_comp attribute.
1852 * trans-array.c (gfc_array_allocate): Add flag that the component to
1853 allocate is not an ultimate coarray component. Add allocation of
1855 (structure_alloc_comps): Extend nullify to treat pointer components in
1856 coarrays correctly. Restructure nullify to remove redundant code.
1857 (gfc_nullify_alloc_comp): Allow setting caf_mode flags.
1858 * trans-array.h: Change prototype of gfc_nullify_alloc_comp ().
1859 * trans-decl.c (generate_coarray_sym_init): Call nullify_alloc_comp for
1860 derived type coarrays with pointer components.
1861 * trans-expr.c (gfc_trans_structure_assign): Also treat pointer
1863 (trans_caf_token_assign): Handle assignment of token of scalar pointer
1865 (gfc_trans_pointer_assignment): Call above routine.
1866 * trans-intrinsic.c (conv_expr_ref_to_caf_ref): Add treating pointer
1868 (gfc_conv_intrinsic_caf_get): Likewise.
1869 (conv_caf_send): Likewise.
1870 * trans-stmt.c (gfc_trans_allocate): After allocating a derived type in
1871 a coarray pre-register the tokens.
1872 (gfc_trans_deallocate): Simply determining the coarray type (scalar or
1873 array) and deregistering it correctly.
1874 * trans-types.c (gfc_typenode_for_spec): Replace in_coarray flag by the
1875 actual codim to allow lookup of array types in the cache.
1876 (gfc_build_array_type): Likewise.
1877 (gfc_get_array_descriptor_base): Likewise.
1878 (gfc_get_array_type_bounds): Likewise.
1879 (gfc_get_derived_type): Likewise.
1880 * trans-types.h: Likewise.
1881 * trans.c (gfc_deallocate_with_status): Enable deregistering of all kind
1882 of coarray components.
1883 (gfc_deallocate_scalar_with_status): Use free() in fcoarray_single mode
1884 instead of caf_deregister.
1886 2017-01-06 Jakub Jelinek <jakub@redhat.com>
1888 * simplify.c (simplify_transformation_to_array): Use
1889 GCC_DIAGNOSTIC_PUSH_IGNORED and GCC_DIAGNOSTIC_POP instead of
1890 #pragma GCC diagnostic {push,ignored,pop}.
1892 2017-01-06 Alexandre Oliva <aoliva@redhat.com>
1894 * simplify.c (simplify_transformation_to_array): Silence
1895 array bounds warning. Fix whitespace.
1897 2017-01-04 Alexandre Oliva <aoliva@redhat.com>
1899 * module.c (load_omp_udrs): Initialize name.
1901 2017-01-02 Janne Blomqvist <jb@gcc.gnu.org>
1904 * trans-expr.c (gfc_trans_string_copy): Rework string copy
1905 algorithm to avoid -Wstringop-overflow warning.
1907 2017-01-01 Jakub Jelinek <jakub@redhat.com>
1909 Update copyright years.
1911 * gfortranspec.c (lang_specific_driver): Update copyright notice
1913 * gfc-internals.texi: Bump @copying's copyright year.
1914 * gfortran.texi: Ditto.
1915 * intrinsic.texi: Ditto.
1916 * invoke.texi: Ditto.
1918 Copyright (C) 2017 Free Software Foundation, Inc.
1920 Copying and distribution of this file, with or without modification,
1921 are permitted in any medium without royalty provided the copyright
1922 notice and this notice are preserved.