]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/c/ChangeLog
[AArch64] Fix register clobber in, aarch64_ashr_sisd_or_int_<mode>3 split.
[thirdparty/gcc.git] / gcc / c / ChangeLog
CommitLineData
9698b078
SH
12014-06-27 Sebastian Huber <sebastian.huber@embedded-brains.de>
2
3 * c-parser.c (c_parser_declaration_or_fndef): Discard all type
4 qualifiers in __auto_type for atomic types.
5 (c_parser_typeof_specifier): Discard all type qualifiers in
6 __typeof__ for atomic types.
7
6e07c515
MP
82014-06-25 Marek Polacek <polacek@redhat.com>
9
10 PR c/61162
11 * c-parser.c (c_parser_statement_after_labels): Pass the location of
12 the return expression to c_finish_return.
13
da6f124d
JJ
142014-06-25 Jakub Jelinek <jakub@redhat.com>
15
16 * c-typeck.c (c_finish_omp_clauses): Make sure
17 OMP_CLAUSE_LINEAR_STEP has correct type.
18
c203e8a7
TS
192014-06-24 Trevor Saunders <tsaunders@mozilla.com>
20
21 * c-decl.c: Adjust.
22
56ad0e38
JJ
232014-06-24 Jakub Jelinek <jakub@redhat.com>
24
25 * c-parser.c (c_parser_omp_for_loop): For
26 #pragma omp parallel for simd move lastprivate clause from parallel
27 to for rather than simd.
28
47c2554f
MP
292014-06-23 Marek Polacek <polacek@redhat.com>
30
31 * c-typeck.c (parser_build_binary_op): Don't call
32 warn_logical_not_parentheses if the RHS is TRUTH_NOT_EXPR.
33
56363ffd
JH
342014-06-15 Jan Hubicka <hubicka@ucw.cz>
35
36 * c-parser.c (c_parser_omp_threadprivate): Likewise.
37 * c-decl.c (merge_decls): Likewise.
38
d7ff7ae5
MP
392014-06-09 Marek Polacek <polacek@redhat.com>
40
41 PR c/36446
42 * c-typeck.c (error_init): Call inform instead of error_at.
43 (pedwarn_init): Call inform instead of pedwarn.
44 (warning_init): Call inform instead of warning_at.
45
24d047a3
JH
462014-06-07 Jan Hubicka <hubicka@ucw.cz>
47
48 * c-decl.c (merge_decls): Use set_decl_section_name.
49 (duplicate_decls): Remove node if it exists.
50
9bac5cbb
G
512014-06-05 S. Gilles <sgilles@terpmail.umd.edu>
52
53 PR c/53119
54 * c-typeck.c (push_init_level, process_init_element,
55 pop_init_level): Correct check for zero initialization, move
56 missing brace warning to respect zero initialization.
57
8ffcdea8
MP
582014-06-05 Marek Polacek <polacek@redhat.com>
59
60 PR c/56724
61 * c-typeck.c (convert_for_assignment): Use expr_loc for ic_argpass.
62
742938c9
MP
632014-06-05 Marek Polacek <polacek@redhat.com>
64
65 PR c/49706
66 * c-typeck.c (parser_build_binary_op): Warn when logical not is used
67 on the left hand side operand of a comparison.
68
6447c55d
MP
692014-06-05 Marek Polacek <polacek@redhat.com>
70
71 PR c/48062
72 * c-decl.c (warn_if_shadowing): Call inform instead of warning_at.
73 Print note only if the warning was printed.
74
9dc7743c
IZ
752014-06-04 Igor Zamyatin <igor.zamyatin@intel.com>
76
77 PR c/58942
78 * c-array-notation.c (fix_builtin_array_notation_fn): Handle the case
79 with a pointer.
80
fedfecef
MP
812014-06-03 Marek Polacek <polacek@redhat.com>
82
83 PR c/60439
84 * c-parser.c (c_parser_switch_statement): Pass explicit_cast_p to
85 c_start_case.
86 * c-tree.h (c_start_case): Update.
87 * c-typeck.c (c_start_case): Add new boolean parameter. Warn if
88 switch condition has boolean value.
89
9b2b7279
AM
902014-06-02 Andrew MacLeod <amacleod@redhat.com>
91
92 * c-decl.c: Include builtins.h.
93 * c-parser.c: Likewise.
94
5c1bc275
MP
952014-05-27 Marek Polacek <polacek@redhat.com>
96
97 PR c/56724
98 * c-typeck.c (convert_arguments): Get location of a parameter. Change
99 error and warning calls to error_at and warning_at. Pass location of
100 a parameter to it. Call warning_at with OPT_Wtraditional_conversion.
101 (convert_for_assignment): Add parameter to WARN_FOR_ASSIGNMENT and
102 WARN_FOR_QUALIFIERS. Pass expr_loc to those.
103
97563bc8
IZ
1042014-05-26 Igor Zamyatin <igor.zamyatin@intel.com>
105
106 PR c/61191
107 * c-array-notation.c (fix_builtin_array_notation_fn): Check invalid
108 function parameters.
109
aede2c10
JH
1102014-05-23 Jan Hubicka <hubicka@ucw.cz>
111
112 * c-decl.c (merge_decls): Preserve symtab node pointers.
113 (duplicate_decls): Free new decl.
114
edbba2ce
TS
1152014-05-23 Thomas Schwinge <thomas@codesourcery.com>
116
f3316c6d
TS
117 * c-typeck.c (c_finish_omp_clauses): Remove duplicated variable
118 initialization.
119
edbba2ce
TS
120 * c-parser.c (c_parser_omp_target): Return bool values.
121
68c81f24
TS
1222014-05-22 Thomas Schwinge <thomas@codesourcery.com>
123
124 * c-parser.c (c_parser_omp_clause_thread_limit): Rename
125 num_teams_loc variable to num_thread_limit_loc.
126
632f2871
RS
1272014-05-21 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
128
129 * c-array-notation.c (expand_array_notations): Use void_node
130 instead of void_zero_node.
131
766090c2
TS
1322014-05-17 Trevor Saunders <tsaunders@mozilla.com>
133
134 * c-decl.c (finish_struct): Adjust.
135 (finish_enum): Likewise.
136 (bind): Adjust.
137 (record_inline_static): Likewise.
138 (push_scope): Likewise.
139 (make_label): Likewise.
140 (lookup_label_for_goto): Likewise.
141 (finish_struct): Likewise.
142 (finish_enum): Likewise.
143 (store_parm_decls): Likewise.
144 (c_push_function_context): Likewise.
145 * c-lang.h: Remove usage of variable_size gty attribute.
146 * c-parser.c (c_parse_init): Adjust.
147 (c_parse_file): Likewise.
148
2b107f6b
MP
1492014-05-13 Marek Polacek <polacek@redhat.com>
150
151 PR c/61162
152 * c-typeck.c (convert_for_assignment): Pass location to
153 WARN_FOR_ASSIGNMENT instead of input_location.
154
d033409e
MP
1552014-05-10 Marek Polacek <polacek@redhat.com>
156
157 * c-parser.c (c_parser_declaration_or_fndef): Pass init_loc to
158 maybe_warn_string_init.
159 (c_parser_postfix_expression_after_paren_type): Pass type_loc to
160 maybe_warn_string_init.
161 * c-tree.h (maybe_warn_string_init): Update declaration.
162 * c-typeck.c (maybe_warn_string_init): Add location parameter.
163 Call pedwarn_init with loc instead of with input_location.
164 (digest_init): Pass init_loc to maybe_warn_string_init.
165 (pop_init_level): Call pedwarn_init with loc instead of with
166 input_location.
167 (set_init_index): Likewise.
168 (process_init_element): Likewise.
169
ea58ef42
MP
1702014-05-09 Marek Polacek <polacek@redhat.com>
171
172 PR c/61096
173 * c-parser.c (c_parser_braced_init): Pass brace_loc to push_init_level.
174 (c_parser_initelt): Pass location to set_init_label. Pass array index
175 location to set_init_index.
176 * c-tree.h (push_init_level): Update declaration.
177 (pop_init_level): Likewise.
178 (set_init_index): Likewise.
179 (set_init_label): Likewise.
180 * c-typeck.c (error_init): Add location parameter. Call error_at
181 instead of error.
182 (digest_init): Pass init_loc to error_init.
183 (really_start_incremental_init):
184 (push_init_level): Add location parameter. Pass loc to pop_init_level
185 and error_init.
186 (pop_init_level): Likewise.
187 (set_designator): Add location parameter. Pass loc to pop_init_level,
188 push_init_level, and error_init.
189 (set_init_index): Add location parameter. Pass loc to error_init and
190 set_designator.
191 (set_init_label): Likewise.
192 (output_init_element): Pass loc to error_init.
193 (process_init_element): Pass loc to error_init, pop_init_level,
194 pedwarn_init, and push_init_level.
195
661a0813
MP
1962014-05-09 Marek Polacek <polacek@redhat.com>
197
198 PR c/50459
199 * c-parser.c (c_parser_attributes): Parse the arguments as an
200 expression-list if the attribute takes identifier.
201
2793eeab
MP
2022014-05-08 Marek Polacek <polacek@redhat.com>
203
204 PR c/61053
205 * c-decl.c (grokdeclarator): Use min_align_of_type instead of
206 TYPE_ALIGN_UNIT.
207
f827930a
MP
2082014-05-08 Marek Polacek <polacek@redhat.com>
209
210 PR c/61077
211 * c-decl.c (start_function): Warn for _Atomic-qualified return type
212 of main.
213
1d60af08
KZ
2142014-05-06 Kenneth Zadeck <zadeck@naturalbridge.com>
215 Mike Stump <mikestump@comcast.net>
216 Richard Sandiford <rdsandiford@googlemail.com>
217
218 * c-decl.c (check_bitfield_type_and_width): Use TYPE_SIGN.
219 (finish_enum): Use wide-int interfaces.
220 * c-parser.c (c_parser_cilk_clause_vectorlength): Likewise.
221 * c-typeck.c (build_c_cast): Likewise.
222 (set_nonincremental_init_from_string): Likewise.
223 (c_tree_equal): Likewise.
224
a0e24419
MP
2252014-05-02 Marek Polacek <polacek@redhat.com>
226
227 PR c/25801
228 * c-typeck.c (c_size_in_bytes): Update comment. Don't call error.
229 Return size_one_node when the type is not complete.
230 (pointer_diff): Remove comment.
231 (build_unary_op): Improve error messages.
232
19fc9faa
MP
2332014-05-02 Marek Polacek <polacek@redhat.com>
234
235 * c-typeck.c (c_finish_return): Separate warning_at calls.
236
63bc4e87
MP
2372014-05-02 Marek Polacek <polacek@redhat.com>
238
239 * c-tree.h (error_init): Remove declaration.
240 (pedwarn_init): Likewise.
241 * c-typeck.c (error_init): Make static and move above.
242 (pedwarn_init): Likewise.
243 (warning_init): Move above.
244 (maybe_warn_string_init): Likewise.
245
4bd2511b
JL
2462014-05-01 Jeff Law <law@redhat.com>
247
248 Revert:
249
250 2014-04-24 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
251 * c-parser.c (c_parser_sizeof_expression): Reorganize slightly to
252 avoid goto.
253
6a358dcb
MP
2542014-05-02 Marek Polacek <polacek@redhat.com>
255
256 PR c/60784
257 * c-typeck.c (push_init_level): Set constructor_designated to
258 p->designated for structures.
259
ae5ebda4
MP
2602014-05-01 Marek Polacek <polacek@redhat.com>
261
262 PR c/60915
263 * c-parser.c (c_parser_declaration_or_fndef): Give better error if
264 function-definition has an attribute after the declarator.
265
96b40f8d
MP
2662014-05-01 Marek Polacek <polacek@redhat.com>
267
268 PR c/60257
269 * c-typeck.c (warning_init): Add location_t parameter. Call
270 warning_at instead of warning.
271 (push_init_level): Pass input_location to warning_init.
272 (add_pending_init): Add location_t parameter. Pass loc to
273 warning_init.
274 (set_nonincremental_init): Pass input_location to add_pending_init.
275 (set_nonincremental_init_from_string): Likewise.
276 (output_init_element): Pass loc to warning_init and to
277 add_pending_init.
278
32e00768
MP
2792014-05-01 Marek Polacek <polacek@redhat.com>
280
281 PR c/43395
282 * c-typeck.c (c_finish_return): Distinguish between label and variable
283 when warning about returning local address.
284
c9379ce2
MP
2852014-05-01 Marek Polacek <polacek@redhat.com>
286
287 PR c/29467
288 * c-decl.c (declspecs_add_type): Pedwarn if boolean types are used
289 in C89 mode.
290
d00887e8
MP
2912014-05-01 Marek Polacek <polacek@redhat.com>
292
293 PR c/43245
294 * c-typeck.c (convert_for_assignment): Pass OPT_Wdiscarded_qualifiers
295 instead of 0 to WARN_FOR_QUALIFIERS.
296
5436fa2e
MP
2972014-05-01 Marek Polacek <polacek@redhat.com>
298
299 PR c/56989
300 * c-typeck.c (default_conversion): Use better location for
301 error call.
302
f8ed5150
MP
3032014-04-30 Marek Polacek <polacek@redhat.com>
304
305 * c-typeck.c (build_binary_op): Call ubsan_instrument_division
306 also when SANITIZE_FLOAT_DIVIDE is on.
307
8337d1db
MP
3082014-04-30 Marek Polacek <polacek@redhat.com>
309
310 PR c/60139
311 * c-typeck.c (output_init_element): Pass OPT_Wpedantic to pedwarn
312 and pedwarn_init. Use loc insted of input_location.
313
c4bdc42f
MP
3142014-04-30 Marek Polacek <polacek@redhat.com>
315
316 PR c/60351
317 * c-typeck.c (build_binary_op): Use location when warning about
318 shift count.
319
45484dcf
MP
3202014-04-25 Marek Polacek <polacek@redhat.com>
321
322 PR c/18079
323 * c-decl.c (diagnose_mismatched_decls): Warn for mismatched
324 always_inline/noinline and hot/cold attributes.
325
34cf811f
MP
3262014-04-25 Marek Polacek <polacek@redhat.com>
327
328 PR c/60114
329 * c-parser.c (c_parser_initelt): Pass input_location to
330 process_init_element.
331 (c_parser_initval): Pass loc to process_init_element.
332 * c-tree.h (process_init_element): Adjust declaration.
333 * c-typeck.c (push_init_level): Pass input_location to
334 process_init_element.
335 (pop_init_level): Likewise.
336 (set_designator): Likewise.
337 (output_init_element): Add location_t parameter. Pass loc to
338 digest_init.
339 (output_pending_init_elements): Pass input_location to
340 output_init_element.
341 (process_init_element): Add location_t parameter. Pass loc to
342 output_init_element.
343
42056eac
JJ
3442014-04-24 Jakub Jelinek <jakub@redhat.com>
345
346 * c-parser.c (c_parser_omp_atomic): Allow seq_cst before
347 atomic-clause, allow comma in between atomic-clause and
348 seq_cst.
349
e162a134
JJ
3502014-04-22 Jakub Jelinek <jakub@redhat.com>
351
352 PR c/59073
353 * c-parser.c (c_parser_omp_parallel): If c_parser_omp_for
354 fails, don't set OM_PARALLEL_COMBINED and return NULL.
355
2f6babac
IZ
3562014-04-12 Igor Zamyatin <igor.zamyatin@intel.com>
357
358 PR middle-end/60469
359 * c-array-notation.c (fix_builtin_array_notation_fn): Use
360 create_tmp_var instead build_decl for creating temps.
361 (build_array_notation_expr): Likewise.
362 (fix_conditional_array_notations_1): Likewise.
363 (fix_array_notation_expr): Likewise.
364 (fix_array_notation_call_expr): Likewise.
365
8edbfaa6
JJ
3662014-03-28 Jakub Jelinek <jakub@redhat.com>
367
368 PR c++/60689
369 * c-tree.h (c_build_function_call_vec): New prototype.
370 * c-typeck.c (build_function_call_vec): Don't call
371 resolve_overloaded_builtin here.
372 (c_build_function_call_vec): New wrapper function around
373 build_function_call_vec. Call resolve_overloaded_builtin here.
374 (convert_lvalue_to_rvalue, build_function_call, build_atomic_assign):
375 Call c_build_function_call_vec instead of build_function_call_vec.
376 * c-parser.c (c_parser_postfix_expression_after_primary): Likewise.
377 * c-decl.c (finish_decl): Likewise.
378
7485aeea
MLI
3792014-03-18 Manuel López-Ibáñez <manu@gcc.gnu.org>
380
381 PR c/55383
382 * c-typeck.c: Use correct format string in cast-qual warning
383
b17a8b07
TS
3842014-03-07 Thomas Schwinge <thomas@codesourcery.com>
385
386 * c-decl.c (c_decl_attributes): Use
387 lang_hooks.types.omp_mappable_type.
388 * c-typeck.c (c_finish_omp_clauses): Likewise.
389
3af9c5e9
MP
3902014-03-06 Marek Polacek <polacek@redhat.com>
391
392 PR c/60197
393 * c-typeck.c (c_finish_return): Call contains_cilk_spawn_stmt instead
394 of checking tree code.
395
1c9f5f33
PK
3962014-02-19 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
397
398 * c-parser.c (c_parser_declspecs): Replace call to error by error_at.
399 (c_parser_parameter_declaration): Likewise.
400
cc28fc7f
MP
4012014-02-19 Marek Polacek <polacek@redhat.com>
402
403 PR c/60195
404 * c-typeck.c (convert_lvalue_to_rvalue): Set TREE_NO_WARNING on tmp.
405 Call mark_exp_read on exp.value.
406 (build_atomic_assign): Set TREE_NO_WARNING on val and old. Set
407 TREE_ADDRESSABLE on old instead of val.
408 (emit_side_effect_warnings): Warn only if RHS has !TREE_NO_WARNING.
409
b581c05c
PK
4102014-02-07 Prathamesh Kulkarni <bilbotheelffriend@gmail.com>
411
412 * c-parser.c (c_parser_get_builtin_args): Replace calls to
413 C_EXPR_APPEND by vec_safe_push.
414 * c-tree.h (C_EXPR_APPEND): Remove.
415
81e5eca8
MP
4162014-01-31 Marek Polacek <polacek@redhat.com>
417
418 PR c/59963
419 * c-typeck.c (convert_lvalue_to_rvalue): Pass vNULL to
420 build_function_call_vec.
421 (build_function_call): Likewise.
422 (build_atomic_assign): Likewise.
423 (build_function_call_vec): Add arg_loc parameter. Use it.
424 (convert_arguments): Likewise.
425 (convert_for_assignment): Rename rhs_loc to expr_loc.
426 * c-parser.c (c_parser_attributes): Pass NULL to c_parser_expr_list.
427 (c_parser_objc_keywordexpr): Likewise.
428 (c_parser_postfix_expression_after_primary): Call
429 build_function_call_vec with expr_loc rather than op_loc.
430 Call c_parser_expr_list to fill arg_loc. Pass arg_loc to
431 build_function_call_vec.
432 (c_parser_expr_list): Add locations parameter. Fill it with locations
433 of function arguments.
434 * c-decl.c (finish_decl): Pass vNULL to build_function_call_vec.
435
68fca595
MP
4362014-01-30 Marek Polacek <polacek@redhat.com>
437
438 PR c/59940
439 * c-typeck.c (build_function_call_vec): Use loc parameter.
440 (convert_arguments): Add location parameter. Use it.
441 (ep_convert_and_check): Likewise.
442 (build_atomic_assign): Adjust convert_for_assignment call.
443 (build_modify_expr): Likewise.
444 (digest_init): Likewise.
445 (c_finish_return): Likewise.
446 (build_conditional_expr): Adjust ep_convert_and_check calls.
447 (convert_for_assignment): Add rhs_loc parameter. Use it.
448 (build_binary_op): Adjust convert_and_check and ep_convert_and_check
449 calls.
450
fa337f3a
RB
4512014-01-30 Richard Biener <rguenther@suse.de>
452
453 PR c/59905
454 * c-typeck.c (build_function_call_vec): Do not replace calls
455 to a function via an incompatible type with a runtime abort.
456
b72271b9
BI
4572014-01-24 Balaji V. Iyer <balaji.v.iyer@intel.com>
458
459 * c-parser.c (c_parser_declaration_or_fndef): Replaced
460 flag_enable_cilkplus with flag_cilkplus.
461 (c_parser_direct_declarator_inner): Likewise.
462 (c_parser_attribute_any_word): Likewise.
463 (c_parser_attributes): Likewise.
464 (c_parser_compound_statement): Likewise.
465 (c_parser_statement_after_labels): Likewise.
466 (c_parser_if_statement): Likewise.
467 (c_parser_switch_statement): Likewise.
468 (c_parser_do_statement): Likewise.
469 (c_parser_for_statement): Likewise.
470 (c_parser_unary_expression): Likewise.
471 (c_parser_postfix_expression): Likewise.
472 (c_parser_postfix_expression_after_primary): Likewise.
473 (c_parser_postfix_expression_after_primary): Likewise.
474 (c_parser_omp_clause_name): Likewise.
475 (c_finish_omp_declare_simd): Likewise.
476 (c_parser_cilk_verify_simd): Likewise.
477 * c-typeck.c (build_array_ref): Likewise.
478 (build_function_call_vec): Likewise.
479 (convert_arguments): Likewise.
480 (build_compound_expr): Likewise.
481 (c_finish_return): Likewise.
482 (c_finish_if_stmt): Likewise.
483 (c_finish_loop): Likewise.
484 (build_binary_op): Likewise.
485
393e8e8b
MP
4862014-01-23 Marek Polacek <polacek@redhat.com>
487
488 PR c/59846
489 * c-typeck.c (parser_build_binary_op): Use location instead of
490 input_location.
491 (build_binary_op): Pass location to shorten_compare.
492
f04dda30
MP
4932014-01-23 Marek Polacek <polacek@redhat.com>
494
495 PR c/58346
496 * c-typeck.c (pointer_diff): Give an error on arithmetic on pointer to
497 an empty aggregate.
498
789eadcd
MP
4992014-01-23 Marek Polacek <polacek@redhat.com>
500
501 PR c/59871
502 * c-typeck.c (build_compound_expr): Warn even for right-hand operand
503 of a comma expression.
504 (emit_side_effect_warnings): Likewise.
505
40f14e9f
BI
5062014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com>
507
508 PR c/59825
509 * c-array-notation.c (expand_array_notation_exprs): Rewrote this
510 function to use walk_tree and moved a lot of its functionality to
511 expand_array_notations.
512 (expand_array_notations): New function.
513
74558dd9
BI
5142014-01-23 Balaji V. Iyer <balaji.v.iyer@intel.com>
515
516 * c-parser.c (c_finish_omp_declare_simd): Made "cilk simd function"
517 attribute an attribute without value.
518
652fea39
JJ
5192014-01-23 Jakub Jelinek <jakub@redhat.com>
520
521 PR middle-end/58809
522 * c-typeck.c (c_finish_omp_clause): Reject MIN_EXPR, MAX_EXPR,
523 BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR on COMPLEX_TYPEs.
524
f34f1c87
MP
5252014-01-22 Marek Polacek <polacek@redhat.com>
526
527 PR c/59891
528 * c-typeck.c (build_conditional_expr): Call c_fully_fold instead
529 of remove_c_maybe_const_expr on op1 and op2.
530
241f845a
JJ
5312014-01-15 Jakub Jelinek <jakub@redhat.com>
532
533 PR c/58943
534 * c-typeck.c (build_modify_expr): For lhs op= rhs, if rhs has side
535 effects, preevaluate rhs using SAVE_EXPR first.
536
9a74f20c
BI
5372014-01-09 Balaji V. Iyer <balaji.v.iyer@intel.com>
538
539 PR c++/59631
540 * c-parser.c (c_parser_postfix_expression): Replaced consecutive if
541 statements with if-elseif statements.
542
96066ce1
MP
5432014-01-06 Marek Polacek <polacek@redhat.com>
544
545 PR c/57773
546 * c-decl.c (check_bitfield_type_and_width): Warn for implementation
547 defined bit-field types only in ISO C.
548
23a5b65a
RS
5492014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
550
551 Update copyright years
552
f9030485
RS
5532014-01-02 Richard Sandiford <rdsandiford@googlemail.com>
554
555 * c-array-notation.c: Use the standard form for the copyright notice.
556
41958c28
BI
5572013-12-18 Balaji V. Iyer <balaji.v.iyer@intel.com>
558
559 * c-parser.c (struct c_parser::cilk_simd_fn_tokens): Added new field.
560 (c_parser_declaration_or_fndef): Added a check if cilk_simd_fn_tokens
561 field in parser is not empty. If not-empty, call the function
562 c_parser_finish_omp_declare_simd.
563 (c_parser_cilk_clause_vectorlength): Modified function to be shared
564 between SIMD-enabled functions and #pragma simd. Added new parameter.
565 (c_parser_cilk_all_clauses): Modified the usage of the function
566 c_parser_cilk_clause_vectorlength as mentioned above.
567 (c_parser_cilk_simd_fn_vector_attrs): New function.
568 (c_finish_cilk_simd_fn_tokens): Likewise.
569 (is_cilkplus_vector_p): Likewise.
570 (c_parser_omp_clause_name): Added checking for "vectorlength,"
571 "nomask," and "mask" strings in clause name.
572 (c_parser_omp_all_clauses): Added 3 new case statements:
573 PRAGMA_CILK_CLAUSE_VECTORLENGTH, PRAGMA_CILK_CLAUSE_MASK and
574 PRAGMA_CILK_CLAUSE_NOMASK.
575 (c_parser_attributes): Added a cilk_simd_fn_tokens parameter. Added a
576 check for vector attribute and if so call the function
577 c_parser_cilk_simd_fn_vector_attrs. Also, when Cilk plus is enabled,
578 called the function c_finish_cilk_simd_fn_tokens.
579 (c_finish_omp_declare_simd): Added a check if cilk_simd_fn_tokens in
580 parser field is non-empty. If so, parse them as you would parse
581 the omp declare simd pragma.
582 (c_parser_omp_clause_linear): Added a new bool parm. is_cilk_simd_fn.
583 Added a check when step is a parameter and flag it as error.
584 (CILK_SIMD_FN_CLAUSE_MASK): New #define.
585 (c_parser_cilk_clause_name): Changed pragma_cilk_clause to
586 pragma_omp_clause.
587
cef0fd0e
TS
5882013-12-17 Thomas Schwinge <thomas@codesourcery.com>
589
590 * c-parser.c (c_parser_omp_parallel): Fix description.
591
12893402
BI
5922013-12-11 Balaji V. Iyer <balaji.v.iyer@intel.com>
593
594 * c-objc-common.h (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Remove.
595 (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise.
596 (LANG_HOOKS_CILKPLUS_CILKPLUS_GIMPLIFY_SPAWN): Likewise.
597 * c-typeck.c (cilk_install_body_with_frame_cleanup): New function.
598
296674db
JM
5992013-12-04 Joseph Myers <joseph@codesourcery.com>
600
601 PR c/52023
602 * c-parser.c (c_parser_alignas_specifier): Use
603 c_sizeof_or_alignof_type instead of c_alignof.
604 (c_parser_alignof_expression): Likewise, with min_alignof
605 parameter depending on alignof spelling used.
606
edd28054
MP
6072013-12-04 Marek Polacek <polacek@redhat.com>
608
609 PR c/54113
610 * c-decl.c (start_function): Don't warn for missing prototype for
611 inline functions.
612
da0fc454
MP
6132013-12-03 Marek Polacek <polacek@redhat.com>
614
615 PR c/59351
616 * c-decl.c (build_compound_literal): Allow compound literals with
617 empty initial value.
618
4c2ecab0
JM
6192013-12-02 Joseph Myers <joseph@codesourcery.com>
620
621 PR c/58235
622 * c-typeck.c (build_modify_expr): Diagnose assignment to
623 expression with array type.
624
340baef7
JM
6252013-11-29 Joseph Myers <joseph@codesourcery.com>
626
627 PR c/42262
628 * c-typeck.c (process_init_element): Do not treat a string as
629 initializing a whole array when used with a designator for an
630 individual element.
631
6763b9f7
JM
6322013-11-29 Joseph Myers <joseph@codesourcery.com>
633
634 PR c/57574
635 * c-decl.c (merge_decls): Clear DECL_EXTERNAL for a definition of
636 an inline function following a static declaration.
637
e7bd1de1
JJ
6382013-11-28 Jakub Jelinek <jakub@redhat.com>
639
640 PR c/59310
641 * c-parser.c (c_parser_omp_target): Copy "#pragma omp target"
642 to p_name before calling c_parser_omp_teams instead of after.
643 (c_parser_cilk_simd): Remove wrong ATTRIBUTE_UNUSED from parser
644 argument. Remove unused p_name variable.
645
0136f8f0
AH
6462013-11-27 Aldy Hernandez <aldyh@redhat.com>
647 Jakub Jelinek <jakub@redhat.com>
648
649 * c-decl.c (c_builtin_function_ext_scope): Avoid binding if
650 external_scope is NULL.
651
241b71bb
TV
6522013-11-27 Tom de Vries <tom@codesourcery.com>
653 Marc Glisse <marc.glisse@inria.fr>
654
655 PR c++/59032
656 * c-typeck.c (build_unary_op): Allow vector increment and decrement.
657
2fb9a547
AM
6582013-11-22 Andrew MacLeod <amacleod@redhat.com>
659
660 * c-typeck.c: Add required include files from gimple.h.
661
8400e75e
DM
6622013-11-22 David Malcolm <dmalcolm@redhat.com>
663
664 * c-decl.c (define_label, shadow_tag_warned)
665 (check_bitfield_type_and_width, grokdeclarator, grokparms,
666 store_parm_decls_newstyle, store_parm_decls_oldstyle)
667 (declspecs_add_type): Remove use of in_system_header macro.
668 * c-parser.c (c_parser_unary_expression): Likewise.
669 * c-typeck.c (store_init_value, process_init_element)
670 (c_start_case): Likewise.
671
672 * c-decl.c (build_enumerator): Remove use of EXPR_LOC_OR_HERE
673 macro.
674
675 * c-parser.c (c_parser_set_source_position_from_token): Remove
676 reference to in_system_header from comment.
677
386b1f1f
RS
6782013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
679
680 * c-decl.c (grokdeclarator): Update comment to refer to
681 tree_to_[su]hwi rather than tree_low_cst.
682
ae7e9ddd
RS
6832013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
684
685 * c-decl.c, c-typeck.c: Replace tree_low_cst (..., 1) with
686 tree_to_uhwi throughout.
687
9439e9a1
RS
6882013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
689
690 * c-parser.c: Replace tree_low_cst (..., 0) with tree_to_shwi
691 throughout.
692
9541ffee
RS
6932013-11-18 Richard Sandiford <rdsandiford@googlemail.com>
694
695 * c-parser.c: Replace host_integerp (..., 0) with tree_fits_shwi_p
696 throughout.
697
c02065fc
AH
6982013-11-15 Aldy Hernandez <aldyh@redhat.com>
699
700 * c-parser.c (c_parser_cilk_simd): New.
701 (c_parser_cilk_verify_simd): New.
702 (c_parser_pragma): Add case for PRAGMA_CILK_SIMD.
703 (c_parser_omp_for_loop): Add case for NE_EXPR.
704 Set c_break_label for CILK_SIMD.
705 (c_parser_cilk_clause_vectorlength): New.
706 (c_parser_cilk_clause_linear): New.
707 (c_parser_cilk_clause_name): New.
708 (c_parser_cilk_all_clauses): New.
709 * c-typeck.c (build_unary_op): Pass location argument to
710 readonly_error.
711 (build_modify_expr): Same.
712 (build_asm_expr): Same.
713 (c_finish_bc_stmt): Error on break/continue in loops.
714
18f429e2
AM
7152013-11-14 Andrew MacLeod <amacleod@redhat.com>
716
717 * c-typeck.c: Include only gimplify.h and gimple.h as needed.
718
d8a2d370
DN
7192013-11-14 Diego Novillo <dnovillo@google.com>
720
721 * c-decl.c: Include print-tree.h.
722 Include stor-layout.h.
723 Include varasm.h.
724 Include attribs.h.
725 Include stringpool.h.
726 * c-lang.c: Include fold-const.h.
727 * c-parser.c: Include stringpool.h.
728 Include attribs.h.
729 Include stor-layout.h.
730 Include varasm.h.
731 Include trans-mem.h.
732 * c-typeck.c: Include stor-layout.h.
733 Include trans-mem.h.
734 Include varasm.h.
735 Include stmt.h.
736
38b7bc7f
JM
7372013-11-13 Joseph Myers <joseph@codesourcery.com>
738
739 * c-tree.h (c_typespec_keyword): Add cts_auto_type.
740 * c-decl.c (declspecs_add_type, finish_declspecs): Handle
741 __auto_type.
742 * c-parser.c (c_token_starts_typename, c_token_starts_declspecs)
743 (c_parser_attribute_any_word, c_parser_objc_selector): Handle
744 RID_AUTO_TYPE.
745 (c_parser_declspecs): Take argument AUTO_TYPE_OK.
746 (c_parser_declaration_or_fndef, c_parser_struct_declaration)
747 (c_parser_declarator, c_parser_direct_declarator_inner)
748 (c_parser_parameter_declaration, c_parser_type_name): All callers
749 changed.
750 (c_parser_declaration_or_fndef): Handle declarations with type
751 determined from the initializer.
752
45b0be94
AM
7532013-11-12 Andrew MacLeod <amacleod@redhat.com>
754
18f429e2 755 * c-typeck.c: Include gimplify.h.
45b0be94 756
582d9b50
JM
7572013-11-12 Joseph Myers <joseph@codesourcery.com>
758
759 * c-tree.h (struct c_declspecs): Add thread_gnu_p field.
760 * c-parser.c (c_parser_declspecs): Mention _Thread_local in
761 comment.
762 * c-decl.c (shadow_tag_warned, grokdeclarator): Mention __thread
763 or _Thread_local as appropriate in diagnostics.
764 (build_null_declspecs): Initialize ret->thread_gnu_p.
765 (declspecs_add_scspec): Handle either __thread or _Thread_local
766 for RID_THREAD. Diagnose _Thread_local for pre-C11 standards if
767 pedantic. Do not disallow _Thread_local extern and _Thread_local
768 static.
769
267bac10
JM
7702013-11-07 Joseph Myers <joseph@codesourcery.com>
771 Andrew MacLeod <amacleod@redhat.com>
772
773 * c-aux-info.c (gen_type): Handle atomic qualifier.
774 * c-decl.c (validate_proto_after_old_defn): Do not remove atomic
775 qualifiers when compating types.
776 (shadow_tag_warned): Handle atomic_p in declspecs.
777 (quals_from_declspecs): Likewise.
778 (start_decl): Use c_type_promotes_to when promoting argument
779 types.
780 (grokdeclarator): Handle _Atomic.
781 (get_parm_info): Diagnose any qualifier on "void" as only
782 parameter.
783 (store_parm_decls_oldstyle): Do not remove atomic qualifiers when
784 comparing types. Use c_type_promotes_to when promoting argument
785 types.
786 (finish_function): Use c_type_promotes_to when promoting argument
787 types.
788 (build_null_declspecs): Handle atomic_p in declspecs.
789 (declspecs_add_qual): Handle RID_ATOMIC.
790 * c-parser.c (c_token_starts_typename, c_token_is_qualifier)
791 (c_token_starts_declspecs): Handle RID_ATOMIC.
792 (c_parser_declspecs): Handle atomic type specifiers and
793 qualifiers.
794 (c_parser_typeof_specifier): Remove const and _Atomic qualifiers
795 from types of expressions with atomic type.
796 (c_parser_direct_declarator_inner): Use convert_lvalue_to_rvalue.
797 (c_parser_attribute_any_word): Handle RID_ATOMIC.
798 (c_parser_initializer, c_parser_initelt, c_parser_initval)
799 (c_parser_statement_after_labels, c_parser_switch_statement)
800 (c_parser_for_statement, c_parser_expr_no_commas)
801 (c_parser_conditional_expression, c_parser_binary_expression)
802 (c_parser_cast_expression, c_parser_unary_expression)
803 (c_parser_postfix_expression)
804 (c_parser_postfix_expression_after_primary, c_parser_expression):
805 Use convert_lvalue_to_rvalue.
806 (c_parser_expression_conv, c_parser_expr_list): Document
807 conversion of lvalues to rvalues. Use convert_lvalue_to_rvalue.
808 (c_parser_objc_synchronized_statement): Use
809 convert_lvalue_to_rvalue.
810 (c_parser_objc_selector): Handle RID_ATOMIC.
811 (c_parser_objc_receiver, c_parser_array_notation): Use
812 convert_lvalue_to_rvalue.
813 * c-tree.h (ctsk_typeof): Adjust comment to mention use for
814 _Atomic (type-name).
815 (struct c_declspecs): Add atomic_p field.
816 (convert_lvalue_to_rvalue): Declare.
817 * c-typeck.c (c_type_promotes_to): Promote atomic types to
818 corresponding atomic types.
819 (qualify_type): Don't add _Atomic qualifiers from second argument.
820 (comp_target_types): Do not allow _Atomic mismatches.
821 (type_lists_compatible_p): Do not remove atomic qualifiers when
822 comparing types.
823 (really_atomic_lvalue, convert_lvalue_to_rvalue)
824 (build_atomic_assign): New functions.
825 (build_unary_op): Use build_atomic_assign for atomic increment and
826 decrement.
827 (build_conditional_expr): Do not treat _Atomic void as a qualified
828 version of void.
829 (build_modify_expr): Use build_atomic_assign for atomic LHS.
830 (find_anonymous_field_with_type, convert_to_anonymous_field)
831 (convert_for_assignment): Do not remove atomic qualifiers when
832 comparing types.
833 (digest_init): Do not accept initialization of arrays of atomic
834 elements by string constants.
835 (build_asm_expr): Use convert_lvalue_to_rvalue.
836 (build_binary_op): Do not treat _Atomic void as a qualified
837 version of void.
838
0c249d4b
DD
8392013-11-06 DJ Delorie <dj@redhat.com>
840
841 * c-decl.c (locate_old_decl): If a previous conflicting decl is
842 both explicit and builtin, print the location of the explicit one.
843
6d7f7e0a
TB
8442013-11-05 Tobias Burnus <burnus@net-b.de>
845
846 * c-parser.c (c_parser_omp_for, c_parser_omp_parallel,
847 c_parser_omp_distribute, c_parser_omp_teams,
848 c_parser_omp_target, c_parser_omp_declare): Handle
849 -fopenmp-simd.
850
b906f4ca
MP
8512013-11-03 Marek Polacek <polacek@redhat.com>
852
853 * c-decl.c (grokdeclarator): Add VLA instrumentation.
854
ee1d5a02
JJ
8552013-11-01 Jakub Jelinek <jakub@redhat.com>
856
857 * c-typeck.c (c_finish_omp_clauses) <case OMP_CLAUSE_UNIFORM>: Go to
858 check_dup_generic at the end, unless remove is true.
859 (c_finish_omp_clauses) <case OMP_CLAUSE_REDUCTION>: Add break; after
860 remove = true;.
861 (c_finish_omp_clauses) <case OMP_CLAUSE_COPYIN>: Likewise.
862
5a9785fb
JJ
8632013-10-31 Jakub Jelinek <jakub@redhat.com>
864
865 * c-typeck.c (c_finish_omp_clauses): Diagnose aligned clause
866 with decl that is not pointer nor array.
867
939b37da
BI
8682013-10-29 Balaji V. Iyer <balaji.v.iyer@intel.com>
869
870 * c-decl.c (finish_function): Added a call for insert_cilk_frame when
871 a spawning function is found.
872 * c-objc-common.h (LANG_HOOKS_CILKPLUS_GIMPLIFY_SPAWN): New #define.
873 (LANG_HOOKS_CILKPLUS_FRAME_CLEANUP): Likewise.
874 (LANG_HOOKS_CILKPLUS_DETECT_SPAWN_AND_UNWRAP): Likewise.
875 * c-parser.c (c_parser_statement_after_labels): Added RID_CILK_SYNC
876 case.
877 (c_parser_postfix_expression): Added RID_CILK_SPAWN case.
878 * c-typeck.c (build_compound_expr): Reject _Cilk_spawn in a comma
879 expr.
880 (c_finish_return): Added a check to reject _Cilk_spawn in return
881 expression.
882 (build_cilk_spawn): New function.
883 (build_cilk_sync): Likewise.
884 * Makefile.in (c-decl.o): Added cilk.h in dependency list.
885
d4af74d4
TB
8862013-10-27 Tobias Burnus <burnus@net-b.de>
887
888 PR other/33426
889 * c-parser.c (c_parser_while_statement, c_parser_while_statement,
890 c_parser_pragma): Add GCC ivdep support to 'do' and 'while'.
891 (c_parser_statement_after_labels): Update calls.
892
d73749df 8932013-10-24 Tobias Burnus <burnus@net-b.de>
8170608b
TB
894
895 PR other/33426
896 * c-parser.c (c_parser_pragma, c_parser_for_statement):
897 Handle PRAGMA_IVDEP.
898 (c_parser_statement_after_labels): Update call.
899
f28aa681
MP
9002013-10-24 Marek Polacek <polacek@redhat.com>
901
902 * c-parser.c (c_parser_struct_declaration): Add a comment.
903 (c_parser_declarator): Don't allow _Alignas here.
904
0645c1a2
AM
9052013-10-17 Andrew MacLeod <amacleod@redhat.com>
906
907 * c-parser.c: Include omp-low.h.
908 * c-typeck.c: Likewise.
909
568a31f2
MP
9102013-10-17 Marek Polacek <polacek@redhat.com>
911
912 PR c/58267
913 * c-parser.c (c_parser_declspecs): Add alignspec_ok parameter.
914 Document syntax of the array-declarator.
915 (c_parser_declspecs) <RID_ALIGNAS>: Bail out if alignment specs
916 are not permitted.
917 (c_parser_declaration_or_fndef): Adjust c_parser_declspecs call.
918 (c_parser_struct_declaration): Likewise.
919 (c_parser_declarator): Likewise.
920 (c_parser_direct_declarator_inner): Likewise.
921 (c_parser_parameter_declaration): Likewise.
922 (c_parser_type_name): Likewise.
923
acf0174b
JJ
9242013-10-11 Jakub Jelinek <jakub@redhat.com>
925
926 * c-lang.h (current_omp_declare_target_attribute): New extern
927 decl.
928 * c-parser.c: Include c-lang.h.
929 (struct c_parser): Change tokens to c_token *.
930 Add tokens_buf field. Change tokens_avail type to unsigned int.
931 (c_parser_consume_token): If parser->tokens isn't
932 &parser->tokens_buf[0], increment parser->tokens.
933 (c_parser_consume_pragma): Likewise.
934 (enum pragma_context): Add pragma_struct and pragma_param.
935 (c_parser_external_declaration): Adjust
936 c_parser_declaration_or_fndef caller.
937 (c_parser_declaration_or_fndef): Add omp_declare_simd_clauses
938 argument, if it is non-vNULL vector, call c_finish_omp_declare_simd.
939 Adjust recursive call.
940 (c_parser_struct_or_union_specifier): Use pragma_struct instead
941 of pragma_external.
942 (c_parser_parameter_declaration): Use pragma_param instead of
943 pragma_external.
944 (c_parser_compound_statement_nostart, c_parser_label,
945 c_parser_for_statement): Adjust
946 c_parser_declaration_or_fndef callers.
947 (c_parser_expr_no_commas): Add omp_atomic_lhs argument, pass
948 it through to c_parser_conditional_expression.
949 (c_parser_conditional_expression): Add omp_atomic_lhs argument,
950 pass it through to c_parser_binary_expression. Adjust recursive
951 call.
952 (c_parser_binary_expression): Remove prec argument, add
953 omp_atomic_lhs argument instead. Always start from PREC_NONE, if
954 omp_atomic_lhs is non-NULL and one of the arguments of toplevel
955 binop matches it, use build2 instead of parser_build_binary_op.
956 (c_parser_pragma): Handle PRAGMA_OMP_CANCEL,
957 PRAGMA_OMP_CANCELLATION_POINT, PRAGMA_OMP_TARGET,
958 PRAGMA_OMP_END_DECLARE_TARGET, PRAGMA_OMP_DECLARE_REDUCTION.
959 Handle pragma_struct and pragma_param the same as pragma_external.
960 (c_parser_omp_clause_name): Parse new OpenMP 4.0 clause names.
961 (c_parser_omp_variable_list): Parse array sections for
962 OMP_CLAUSE_{DEPEND,MAP,TO,FROM} clauses.
963 (c_parser_omp_clause_collapse): Fully fold collapse expression.
964 (c_parser_omp_clause_reduction): Handle user defined reductions.
965 (c_parser_omp_clause_branch, c_parser_omp_clause_cancelkind,
966 c_parser_omp_clause_num_teams, c_parser_omp_clause_thread_limit,
967 c_parser_omp_clause_aligned, c_parser_omp_clause_linear,
968 c_parser_omp_clause_safelen, c_parser_omp_clause_simdlen,
969 c_parser_omp_clause_depend, c_parser_omp_clause_map,
970 c_parser_omp_clause_device, c_parser_omp_clause_dist_schedule,
971 c_parser_omp_clause_proc_bind, c_parser_omp_clause_to,
972 c_parser_omp_clause_from, c_parser_omp_clause_uniform): New functions.
973 (c_parser_omp_all_clauses): Add finish_p argument. Don't call
974 c_finish_omp_clauses if it is false. Handle new OpenMP 4.0 clauses.
975 (c_parser_omp_atomic): Parse seq_cst clause, pass true if it is
976 present to c_finish_omp_atomic. Handle OpenMP 4.0 atomic forms.
977 (c_parser_omp_for_loop): Add CODE argument, pass it through
978 to c_finish_omp_for. Change last argument to cclauses,
979 and adjust uses to grab parallel clauses from the array of all
980 the split clauses. Adjust c_parser_binary_expression,
981 c_parser_declaration_or_fndef and c_finish_omp_for callers.
982 (omp_split_clauses): New function.
983 (c_parser_omp_simd): New function.
984 (c_parser_omp_for): Add p_name, mask and cclauses arguments.
985 Allow the function to be called also when parsing combined constructs,
986 and call c_parser_omp_simd when parsing for simd.
987 (c_parser_omp_sections_scope): If section-sequence doesn't start with
988 #pragma omp section, require exactly one structured-block instead of
989 sequence of statements.
990 (c_parser_omp_sections): Add p_name, mask and cclauses arguments.
991 Allow the function to be called also when parsing combined constructs.
992 (c_parser_omp_parallel): Add p_name, mask and cclauses arguments.
993 Allow the function to be called also when parsing combined
994 constructs.
995 (c_parser_omp_taskgroup, c_parser_omp_cancel,
996 c_parser_omp_cancellation_point, c_parser_omp_distribute,
997 c_parser_omp_teams, c_parser_omp_target_data,
998 c_parser_omp_target_update, c_parser_omp_target,
999 c_parser_omp_declare_simd, c_finish_omp_declare_simd,
1000 c_parser_omp_declare_target, c_parser_omp_end_declare_target,
1001 c_parser_omp_declare_reduction, c_parser_omp_declare): New functions.
1002 (c_parser_omp_construct): Add p_name and mask vars. Handle
1003 PRAGMA_OMP_DISTRIBUTE, PRAGMA_OMP_SIMD, PRAGMA_OMP_TASKGROUP,
1004 PRAGMA_OMP_TEAMS. Adjust c_parser_omp_for, c_parser_omp_parallel
1005 and c_parser_omp_sections callers.
1006 (c_parse_file): Initialize tparser.tokens and the_parser->tokens here.
1007 (OMP_FOR_CLAUSE_MASK, OMP_SECTIONS_CLAUSE_MASK,
1008 OMP_SINGLE_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1.
1009 (OMP_PARALLEL_CLAUSE_MASK): Likewise. Add OMP_CLAUSE_PROC_BIND.
1010 (OMP_TASK_CLAUSE_MASK): Use OMP_CLAUSE_MASK_1 instead of 1. Add
1011 OMP_CLAUSE_DEPEND.
1012 (OMP_SIMD_CLAUSE_MASK, OMP_CANCEL_CLAUSE_MASK,
1013 OMP_CANCELLATION_POINT_CLAUSE_MASK, OMP_DISTRIBUTE_CLAUSE_MASK,
1014 OMP_TEAMS_CLAUSE_MASK, OMP_TARGET_DATA_CLAUSE_MASK,
1015 OMP_TARGET_UPDATE_CLAUSE_MASK, OMP_TARGET_CLAUSE_MASK,
1016 OMP_DECLARE_SIMD_CLAUSE_MASK): Define.
1017 * c-typeck.c: Include tree-inline.h.
1018 (c_finish_omp_cancel, c_finish_omp_cancellation_point,
1019 handle_omp_array_sections_1, handle_omp_array_sections,
1020 c_clone_omp_udr, c_find_omp_placeholder_r): New functions.
1021 (c_finish_omp_clauses): Handle new OpenMP 4.0 clauses and
1022 user defined reductions.
1023 (c_tree_equal): New function.
1024 * c-tree.h (temp_store_parm_decls, temp_pop_parm_decls,
1025 c_finish_omp_cancel, c_finish_omp_cancellation_point, c_tree_equal,
1026 c_omp_reduction_id, c_omp_reduction_decl, c_omp_reduction_lookup,
1027 c_check_omp_declare_reduction_r): New prototypes.
1028 * c-decl.c (current_omp_declare_target_attribute): New variable.
1029 (c_decl_attributes): New function.
1030 (start_decl, start_function): Use it instead of decl_attributes.
1031 (temp_store_parm_decls, temp_pop_parm_decls, c_omp_reduction_id,
1032 c_omp_reduction_decl, c_omp_reduction_lookup,
1033 c_check_omp_declare_reduction_r): New functions.
1034
0a6c2227
TT
10352013-09-25 Tom Tromey <tromey@redhat.com>
1036
1037 * Make-lang.in (c/gccspec.o): Remove.
1038 (CFLAGS-c/gccspec.o): New variable.
1039 (cc1-checksum.o, C_TREE_H, c/c-aux-info.o, c/c-convert.o)
1040 (c/c-decl.o, c/c-errors.o, c/c-lang.o, c/c-objc-common.o)
1041 (c/c-parser.o, c/c-typeck.o, c/c-array-notation.o): Remove.
1042
f3bc55f0
TT
10432013-09-25 Tom Tromey <tromey@redhat.com>
1044
1045 * Make-lang.in (c/gccspec.o): Don't use subshell.
1046
a24d975c
MP
10472013-09-18 Marek Polacek <polacek@redhat.com>
1048
1049 PR sanitize/58443
1050 * c-typeck.c (build_binary_op): Properly honor -fsanitize options.
1051 Remove unnecessary check.
1052
ce6923c5
MP
10532013-09-18 Marek Polacek <polacek@redhat.com>
1054
1055 PR sanitizer/58411
1056 * c-typeck.c (build_binary_op): Don't sanitize function if it has the
1057 no_sanitize_undefined attribute.
1058
a1e51df9
KT
10592013-09-13 Kai Tietz <ktietz@redhat.com>
1060
1061 PR target/57848
1062 * c-decl.c (c_builtin_function_ext_scope): Remove
1063 wrong assumption that it is never called on prexisting
1064 symbol.
1065
0af94e6f
JR
10662013-09-08 Joern Rennecke <joern.rennecke@embecosm.com>
1067
1068 * c-typeck.c (build_binary_op): Use vector_types_compatible_elements_p.
1069
20059c8b
GDR
10702013-09-03 Gabriel Dos Reis <gdr@integrable-solutions.net>
1071
1072 * c-objc-common.c (c_tree_printer): Tidy.
1073
de5a5fa1
MP
10742013-08-30 Marek Polacek <polacek@redhat.com>
1075
1076 * c-typeck.c (build_binary_op): Add division by zero and shift
1077 instrumentation.
1078
2531a1d9 10792013-08-26 Joern Rennecke <joern.rennecke@embecosm.com>
0fdd4508 1080 Joseph Myers <joseph@codesourcery.com>
2531a1d9 1081
6e2bcc98 1082 PR c/35649
2531a1d9
JR
1083 * c-typeck.c (c_common_type): Prefer double_type_node over
1084 other REAL_TYPE types with the same precision.
1085 (convert_arguments): Likewise.
1086
025311c4
GDR
10872013-08-23 Gabriel Dos Reis <gdr@integrable-solutions.net>
1088
1089 * c-objc-common.c (c_tree_printer): Document the nature of the cast.
1090 (c_initialize_diagnostics): Call a destructor for the early printer.
1091
da6ca2b5
GDR
10922013-08-22 Gabriel Dos Reis <gdr@integrable-solutions.net>
1093
1094 * c-objc-common.c (c_initialize_diagnostics): Simplify C pretty
1095 printer initialization.
1096
318cda85 10972013-08-19 Balaji V. Iyer <balaji.v.iyer@intel.com>
da6ca2b5 1098
318cda85
BI
1099 PR c/57490
1100 * c-array-notation.c (fix_conditional_array_notations_1): Added a
1101 check for truth values.
1102 (expand_array_notation_exprs): Added truth values case. Removed an
1103 unwanted else. Added for-loop to walk through subtrees in default
1104 case.
1105
b066401f
GDR
11062013-08-04 Gabriel Dos Reis <gdr@integrable-solutions.net>
1107
1108 * c-objc-common.c (c_initialize_diagnostics): Don't call pp_base.
1109
fb48aadc
JM
11102013-07-23 Joseph Myers <joseph@codesourcery.com>
1111
1112 * c-parser.c (struct c_generic_association): Fix typo.
1113
433cc7b0
TT
11142013-07-23 Tom Tromey <tromey@redhat.com>
1115 Joseph Myers <joseph@codesourcery.com>
1116
1117 * c-parser.c (struct c_generic_association): New.
1118 (c_generic_association_d): New typedef.
1119 (c_parser_generic_selection): New function.
1120 (c_parser_postfix_expression): Handle RID_GENERIC.
1121
26d40c3d
JM
11222013-07-13 Jason Merrill <jason@redhat.com>
1123
1124 PR c++/57793
1125 * c-decl.c (finish_struct): Check for too-large class.
1126
ecdbd01a 11272013-07-04 Joern Rennecke <joern.rennecke@embecosm.com>
40d3d530
JR
1128
1129 PR c/57821
1130 * c-typeck.c (set_init_index): When folding, check for index overflow.
1131
1141ed3f
BI
11322013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
1133
1134 * c-parser.c (c_parser_array_notation): Removed rejection of array
1135 notations in an array of function pointers.
1136
713b46fa
BI
11372013-06-21 Balaji V. Iyer <balaji.v.iyer@intel.com>
1138
1139 * c-array-notation.c (make_triplet_val_inv): New function.
1140 (create_cmp_incr): Likewise.
1141 (create_array_refs): Likewise.
1142 (fix_builtin_array_notation_fn): Replaced all mallocs with tree vec.
1143 Also modularized common parts between functions and called the function.
1144 (build_array_notation_expr): Likewise.
1145 (fix_conditional_array_notations_1): Likewise.
1146 (fix_array_notation_expr): Likewise.
1147 (fix_array_notation_call_expr): Likewise.
1148
92f20202
MP
11492013-06-18 Marek Polacek <polacek@redhat.com>
1150
1151 PR c/57630
1152 * c-decl.c (check_for_loop_decls): Improve diagnostics messages.
1153
73a23b06
BI
11542013-06-12 Balaji V. Iyer <balaji.v.iyer@intel.com>
1155
1156 * c-array-notation.c (build_array_notation_expr): Reject array notation
1157 mismatch between LHS and RHS even inside a call_expr. Also, removed
1158 a couple while statements that were dead code.
1159
00b8517d
BI
11602013-06-10 Balaji V. Iyer <balaji.v.iyer@intel.com>
1161
1162 * c-array-notation.c (fix_builtin_array_notation_fn): Fully folded
1163 excessive precision expressions in function parameters. Also removed
1164 couple unwanted while statements.
1165
1509bdda
BI
11662013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
1167
1168 * c-array-notation.c (expand_array_notation_exprs): Added
1169 ARRAY_NOTATION_REF case.
1170
d60f1706
BI
11712013-06-07 Balaji V. Iyer <balaji.v.iyer@intel.com>
1172
1173 * c-array-notation.c (length_mismatch_in_expr_p): Moved this
1174 function to c-family/array-notation-common.c.
1175 (is_cilkplus_reduce_builtin): Likewise.
1176 (find_rank): Likewise.
1177 (extract_array_notation_exprs): Likewise.
1178 (replace_array_notations): Likewise.
1179 (find_inv_trees): Likewise.
1180 (replace_inv_trees): Likewise.
1181 (contains_array_notation_expr): Likewise.
1182 (find_correct_array_notation_type): Likewise.
1183 (replace_invariant_exprs): Initialized additional_tcodes to NULL.
1184 (struct inv_list): Moved this to c-family/array-notation-common.c.
1185 * c-tree.h (is_cilkplus_builtin_reduce): Remove prototype.
1186
6d6efbb3
BI
11872013-06-05 Balaji V. Iyer <balaji.v.iyer@intel.com>
1188
1189 * c-typeck.c (convert_arguments): Moved checking of builtin cilkplus
1190 reduction functions outside the for-loop. Added a check if the fundecl
1191 is non-NULL. Finally, removed an unwanted if-statement, and made the
1192 body unconditional.
1193
25c22937
BI
11942013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com>
1195
1196 * c-typeck.c (c_finish_if_stmt): Added a check to see if the rank of the
1197 condition of the if-statement matches the rank of else-block and then-
1198 block when array notations are used.
1199 * c-parser.c (c_parser_declaration_or_fndef): Expanded array notation
1200 expression after the entire function body is parsed.
1201 (c_parser_expr_no_commas): Delayed creating array notation expressions
1202 to the end of function parsing.
1203 * c-array-notation.c (fix_conditional_array_notations_1): Expanded the
1204 whole if-statement instead of just the condition.
1205 (expand_array_notation_exprs): Added MODIFY_EXPR case.
1206
edd25645
BI
12072013-06-03 Balaji V. Iyer <balaji.v.iyer@intel.com>
1208
1209 PR c/57474
1210 * c-array-notation.c (build_array_notation_expr): Initialized rhs_length
1211 array to NULL_TREE if they are unused. Also added a check for the
1212 field to be NULL before its fields are used in future.
1213
065ce7f1
RO
12142013-05-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1215
1216 PR bootstrap/57450
1217 * c-array-notation.c (length_mismatch_in_expr_p): Use absu_hwi.
1218 (build_array_notation_expr): Likewise.
1219
36536d79
BI
12202013-05-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
1221
1222 * c-typeck.c (build_array_ref): Added a check to see if array's
1223 index is greater than one. If true, then emit an error.
1224 (build_function_call_vec): Exclude error reporting and checking
1225 for builtin array-notation functions.
1226 (convert_arguments): Likewise.
1227 (c_finish_return): Added a check for array notations as a return
1228 expression. If true, then emit an error.
1229 (c_finish_loop): Added a check for array notations in a loop
1230 condition. If true then emit an error.
1231 (lvalue_p): Added a ARRAY_NOTATION_REF case.
1232 (build_binary_op): Added a check for array notation expr inside
1233 op1 and op0. If present, we call another function to find correct
1234 type.
1235 * Make-lang.in (C_AND_OBJC_OBJS): Added c-array-notation.o.
1236 * c-parser.c (c_parser_compound_statement): Check if array
1237 notation code is used in tree, if so, then transform them into
1238 appropriate C code.
1239 (c_parser_expr_no_commas): Check if array notation is used in LHS
1240 or RHS, if so, then build array notation expression instead of
1241 regular modify.
1242 (c_parser_postfix_expression_after_primary): Added a check for
1243 colon(s) after square braces, if so then handle it like an array
1244 notation. Also, break up array notations in unary op if found.
1245 (c_parser_direct_declarator_inner): Added a check for array
1246 notation.
1247 (c_parser_compound_statement): Added a check for array notation in
1248 a stmt. If one is present, then expand array notation expr.
1249 (c_parser_if_statement): Likewise.
1250 (c_parser_switch_statement): Added a check for array notations in
1251 a switch statement's condition. If true, then output an error.
1252 (c_parser_while_statement): Similarly, but for a while.
1253 (c_parser_do_statement): Similarly, but for a do-while.
1254 (c_parser_for_statement): Similarly, but for a for-loop.
1255 (c_parser_unary_expression): Check if array notation is used in a
1256 pre-increment or pre-decrement expression. If true, then expand
1257 them.
1258 (c_parser_array_notation): New function.
1259 * c-array-notation.c: New file.
1260 * c-tree.h (is_cilkplus_reduce_builtin): Protoize.
1261
cd192ccc
MS
12622013-05-23 Mike Stump <mikestump@comcast.net>
1263
1264 * c-typeck.c (convert_for_assignment): Handle references to memory
1265 spaces better.
1266
427b248d
JM
12672013-05-16 Jason Merrill <jason@redhat.com>
1268
1269 * Make-lang.in (cc1$(exeext)): Use link mutex.
1270
44d90fe1
PC
12712013-04-24 Paolo Carlini <paolo.carlini@oracle.com>
1272
1273 * c-typeck.c (pointer_diff): Change -Wpointer-arith pedwarns
1274 to simply use OPT_Wpointer_arith.
1275 (build_unary_op): Likewise.
1276
4e7d7b3d
JJ
12772013-04-03 Jakub Jelinek <jakub@redhat.com>
1278
1279 PR c/19449
1280 * c-parser.c (c_parser_get_builtin_args): Add choose_expr_p
1281 argument. If set, or it temporarily for parsing of the first
1282 argument into force_folding_builtin_constant_p.
1283 (c_parser_postfix_expression): Adjust callers.
1284
839b422f
RB
12852013-03-21 Richard Biener <rguenther@suse.de>
1286
1287 * c-objc-common.c (c_tree_printer): Use DECL_HAS_DEBUG_EXPR_P
1288 instead of DECL_DEBUG_EXPR_IS_FROM. Guard properly.
1289
2ee028f1
MP
12902013-02-12 Marek Polacek <polacek@redhat.com>
1291
1292 PR c/44938
1293 * c-parser.c (c_parser_postfix_expression_after_primary): Initialize
1294 origtypes to NULL.
1295
8824edff
JJ
12962013-01-24 Jakub Jelinek <jakub@redhat.com>
1297
1298 PR c/56078
1299 * c-typeck.c (set_nonincremental_init_from_string): If
1300 constructor_max_index is NULL, treat it as if tree_int_cst_lt
1301 returned false.
1302 (process_init_element): Likewise.
1303
eadd3d0d
JJ
13042012-12-20 Jakub Jelinek <jakub@redhat.com>
1305
1306 PR c++/55619
1307 * c-parser.c (c_parser_asm_operands): Remove CONVERT_P
1308 argument, don't call default_function_array_conversion
1309 nor c_fully_fold here.
1310 (c_parser_asm_statement): Adjust callers.
1311 * c-typeck.c (build_asm_expr): Call c_fully_fold on inputs
1312 and outputs here, and call default_function_array_conversion
1313 on inputs that don't need to be addressable.
1314
f8a93a2e
JJ
13152012-12-18 Jakub Jelinek <jakub@redhat.com>
1316
1317 PR c/39464
1318 * c-typeck.c (convert_for_assignment): For -Wpointer-sign
1319 warning require that both c_common_unsigned_type as well as
1320 c_common_signed_type is the same for both mvl and mvr types.
1321
9771b263
DN
13222012-11-16 Diego Novillo <dnovillo@google.com>
1323
1324 Adjust for new vec API (http://gcc.gnu.org/wiki/cxx-conversion/cxx-vec)
1325
1326 * c-common.c: Use new vec API in vec.h.
1327 * c-common.h: Likewise.
1328 * c-gimplify.c: Likewise.
1329 * c-pragma.c: Likewise.
1330 * c-pretty-print.c: Likewise.
1331 * c-pretty-print.h: Likewise.
1332 * c-semantics.c: Likewise.
1333 * c-decl.c: Likewise.
1334 * c-parser.c: Likewise.
1335 * c-tree.h: Likewise.
1336 * c-typeck.c: Likewise.
1337
880661a4
JW
13382012-10-29 Jonathan Wakely <jwakely.gcc@gmail.com>
1339
1340 PR c++/54930
1341 * c-typeck.c (c_finish_return): Use OPT_Wreturn_local_addr.
1342
077d1abe
MLI
13432012-10-29 Manuel López-Ibáñez <manu@gcc.gnu.org>
1344
1345 PR c/53066
1346 * c-decl.c (warn_if_shadowing): Do not warn if a variable
1347 shadows a function, unless the variable is a function or a
1348 pointer-to-function.
1349
3a785c97
JJ
13502012-10-12 Jakub Jelinek <jakub@redhat.com>
1351
1352 PR c/54381
1353 * c-parser.c (struct c_tree_loc_pair): Removed.
1354 (c_parser_expr_list): Remove struct c_tree_loc_pair * argument,
1355 add location_t * and tree * arguments, fill in array of 3
1356 sizeof_arg trees and corresponding locs.
1357 (c_parser_attributes, c_parser_objc_keywordexpr): Adjust
1358 c_parser_expr_list callers.
1359 (c_parser_postfix_expression_after_primary): Likewise. Pass
1360 array of 3 sizeof_arg trees and locs (corresponding to first
1361 3 arguments) to sizeof_pointer_memaccess_warning.
1362
703c8606
LC
13632012-10-09 Lawrence Crowl <crowl@google.com>
1364
1365 * Make-lang.in (c-decl.o): Add dependence on hash-table.h.
1366 * c-decl.c (detect_field_duplicates_hash): Change to new type-safe
1367 hash table.
1368
5d9de0d0
PC
13692012-10-09 Paolo Carlini <paolo.carlini@oracle.com>
1370
1371 PR c++/54194
1372 * c-typeck.c (parser_build_binary_op): Update warn_about_parentheses
1373 call.
1374
a212e43f
MG
13752012-10-09 Marc Glisse <marc.glisse@inria.fr>
1376
1377 PR c++/54427
1378 * c-typeck.c: Include c-common.h.
1379 (enum stv_conv): Moved to c-common.h.
1380 (scalar_to_vector): Moved to c-common.c.
1381 (build_binary_op): Adapt to scalar_to_vector's new prototype.
1382 * Make-lang.in: c-typeck.c depends on c-common.h.
1383
3b78de56
AC
13842012-10-04 Arnaud Charlet <charlet@adacore.com>
1385
1386 * c-decl.c (c_write_global_declarations): Fix handling of
1387 -fdump-ada-spec*.
1388
78c60e3d
SS
13892012-09-30 Sharad Singhai <singhai@google.com>
1390
1391 * c-decl.c (c_write_global_declarations): Use a different method
1392 to determine if the dump has ben initialized.
1393
9f33203d
JM
13942012-09-14 Joseph Myers <joseph@codesourcery.com>
1395
1396 PR c/54552
1397 * c-typeck.c (c_cast_expr): When casting to a type requiring
1398 C_MAYBE_CONST_EXPR to be created, pass the inner expression to
1399 c_fully_fold first.
1400
a27d595d
JM
14012012-09-14 Joseph Myers <joseph@codesourcery.com>
1402
1403 PR c/54103
1404 * c-typeck.c (build_unary_op): Pass original argument of
1405 TRUTH_NOT_EXPR to c_objc_common_truthvalue_conversion, then remove
1406 any C_MAYBE_CONST_EXPR, if it has integer operands.
1407 (build_binary_op): Pass original arguments of TRUTH_ANDIF_EXPR,
1408 TRUTH_ORIF_EXPR, TRUTH_AND_EXPR, TRUTH_OR_EXPR and TRUTH_XOR_EXPR
1409 to c_objc_common_truthvalue_conversion, then remove any
1410 C_MAYBE_CONST_EXPR, if they have integer operands. Use
1411 c_objc_common_truthvalue_conversion not
1412 c_common_truthvalue_conversion.
1413 (c_objc_common_truthvalue_conversion): Build NE_EXPR directly and
1414 call note_integer_operands for arguments with integer operands
1415 that are not integer constants.
1416
9feb29df
JJ
14172012-09-13 Jakub Jelinek <jakub@redhat.com>
1418
1419 PR c/54559
1420 * c-typeck.c (c_finish_return): Do convert to BOOLEAN_TYPE or
1421 COMPLEX_TYPE with in_late_binary_op set temporarily to true.
1422
d409320c
JJ
14232012-08-31 Jakub Jelinek <jakub@redhat.com>
1424
1425 PR c/54428
1426 * c-convert.c (convert): Don't call fold_convert_loc if
1427 TYPE_MAIN_VARIANT of a COMPLEX_TYPE is the same, unless e
1428 is a COMPLEX_EXPR. Remove TYPE_MAIN_VARIANT check from
1429 COMPLEX_TYPE -> COMPLEX_TYPE conversion.
1430
6265d07c
JJ
14312012-08-24 Jakub Jelinek <jakub@redhat.com>
1432
1433 PR c/54355
1434 * c-decl.c (c_parser_label): Pass true as nested and fix up comments
1435 for nested and empty_ok arguments in the call to
1436 c_parser_declaration_or_fndef.
1437
1a4049e7
JJ
14382012-08-17 Jakub Jelinek <jakub@redhat.com>
1439
1440 * c-tree.h (c_last_sizeof_arg): Declare.
1441 * c-parser.c (struct c_tree_loc_pair): New type.
1442 (c_parser_expr_list): Add sizeof_arg argument. Fill it in if
1443 non-NULL.
1444 (c_parser_attributes, c_parser_objc_keywordexpr): Adjust callers.
1445 (c_parser_postfix_expression_after_primary): Likewise. Call
1446 sizeof_pointer_memaccess_warning if needed.
1447 (sizeof_ptr_memacc_comptypes): New function.
1448 * c-typeck.c (c_last_sizeof_arg): New global variable.
1449 (c_expr_sizeof_expr, c_expr_sizeof_type): Initialize it.
1450
0229aee9
UB
14512012-07-24 Uros Bizjak <ubizjak@gmail.com>
1452
1453 * c-lang.h (lang_decl): Add variable_size GTY option.
1454
7ee2468b
SB
14552012-07-16 Steven Bosscher <steven@gcc.gnu.org>
1456
1457 * c-decl.c: Include dumpfile.h instead of tree-dump.h.
1458 * Make-lang.in: Fix dependencies.
1459
d4a10d0a
SB
14602012-06-29 Steven Bosscher <steven@gcc.gnu.org>
1461
1462 * Make-lang.in: New file, rules migrated from gcc/Makefile.in
1463 and add language Makefile hooks.
1464 * config-lang.in: New file.
1465 * c-config-lang.in: Moved from gcc/config-lang.in to here, and
1466 add the required "normal" config-lang.in rules.
1467 * c-lang.h: Moved from gcc/ to here.
1468 * c-tree.h: Likewise.
1469 * c-objc-common.c: Likewise.
1470 * c-objc-common.h: Likewise.
1471 * c-typeck.c: Likewise.
1472 * c-convert.c: Likewise.
1473 * c-lang.c: Likewise.
1474 * c-aux-info.c: Likewise.
1475 * c-errors.c: Likewise.
1476 * gccspec.c: Likewise.
1477 * c-decl.c: Likewise. Include gt-c-c-decl.h, not gt-c-decl.h.
1478 * c-parser.c: Likewise. Include gt-c-c-parser.h, not gt-c-parser.h.
1479\f
23a5b65a 1480Copyright (C) 2012-2014 Free Software Foundation, Inc.
d4a10d0a
SB
1481
1482Copying and distribution of this file, with or without modification,
1483are permitted in any medium without royalty provided the copyright
1484notice and this notice are preserved.