]> gcc.gnu.org Git - gcc.git/blob - gcc/ChangeLog
backport: re PR rtl-optimization/90026 (ICE: verify_flow_info failed (error: missing...
[gcc.git] / gcc / ChangeLog
1 2019-04-30 Jakub Jelinek <jakub@redhat.com>
2
3 Backported from mainline
4 2019-04-12 Jakub Jelinek <jakub@redhat.com>
5
6 PR rtl-optimization/90026
7 * cfgcleanup.c (try_optimize_cfg): When removing empty bb with no
8 successors, look for BARRIERs inside of the whole BB_FOOTER chain
9 rather than just at the start of it. If e->src BB_FOOTER is not NULL
10 in cfglayout mode, use emit_barrier_after_bb.
11
12 2019-04-11 Jakub Jelinek <jakub@redhat.com>
13
14 PR rtl-optimization/89965
15 * dce.c (sp_based_mem_offset): New function.
16 (find_call_stack_args): Use sp_based_mem_offset.
17
18 2019-04-10 Jakub Jelinek <jakub@redhat.com>
19
20 PR c++/90010
21 * gimple-ssa-sprintf.c (target_to_host): Fix handling of targstr
22 with strlen in between hostsz-3 and hostsz-1 inclusive when no
23 translation is needed, and when translation is needed, only append
24 ... if the string length is hostsz or more bytes long. Avoid using
25 strncpy or strcat.
26
27 2019-04-09 Jakub Jelinek <jakub@redhat.com>
28
29 PR tree-optimization/89998
30 * gimple-ssa-sprintf.c (try_substitute_return_value): Use lhs type
31 instead of integer_type_node if possible, don't add ranges if return
32 type is not compatible with int.
33 * gimple-fold.c (gimple_fold_builtin_sprintf,
34 gimple_fold_builtin_snprintf): Use lhs type instead of hardcoded
35 integer_type_node.
36
37 2019-03-29 Jakub Jelinek <jakub@redhat.com>
38
39 PR c/89872
40 * gimplify.c (gimplify_compound_literal_expr): Don't optimize a
41 non-addressable complit into its initializer if it is volatile.
42
43 2019-03-28 Jakub Jelinek <jakub@redhat.com>
44
45 PR middle-end/89621
46 * tree-inline.h (struct copy_body_data): Add
47 dont_remap_vla_if_no_change flag.
48 * tree-inline.c (remap_type_3, remap_type_2): New functions.
49 (remap_type): Don't remap vla types if id->dont_remap_vla_if_no_change
50 and remap_type_2 returns false.
51 * omp-low.c (new_omp_context): Set ctx->cb.dont_remap_vla_if_no_change.
52
53 2019-03-20 Jakub Jelinek <jakub@redhat.com>
54
55 PR target/89752
56 * lra-constraints.c (process_alt_operands) <reg>: For BLKmode, don't
57 update this_alternative nor this_alternative_set.
58
59 2019-03-19 Jakub Jelinek <jakub@redhat.com>
60
61 PR rtl-optimization/89768
62 * loop-unroll.c (unroll_loop_constant_iterations): Use gen_int_mode
63 instead of GEN_INT.
64 (unroll_loop_runtime_iterations): Likewise.
65
66 PR target/89752
67 * gimplify.c (gimplify_asm_expr): For output argument with
68 TREE_ADDRESSABLE type, clear allows_reg if it allows memory, otherwise
69 diagnose error.
70
71 PR target/89726
72 * config/i386/i386.c (ix86_expand_floorceildf_32): In ceil
73 compensation use x2 += 1 instead of x2 -= -1 and when honoring
74 signed zeros, do another copysign after the compensation.
75
76 2019-03-15 Jakub Jelinek <jakub@redhat.com>
77
78 PR debug/89704
79 * dwarf2out.c (add_const_value_attribute): Return false for MINUS,
80 SIGN_EXTEND and ZERO_EXTEND.
81
82 2019-03-14 Jakub Jelinek <jakub@redhat.com>
83
84 PR ipa/89684
85 * multiple_target.c (create_dispatcher_calls): Change
86 references_to_redirect from vector of ipa_ref * to vector of ipa_ref.
87 In the node->iterate_referring loop, push *ref rather than ref, call
88 ref->remove_reference () and always pass 0 to iterate_referring.
89
90 PR rtl-optimization/89679
91 * expmed.c (expand_mult_const): Don't add a REG_EQUAL note if it
92 would contain a paradoxical SUBREG.
93
94 PR tree-optimization/89703
95 * tree-ssa-strlen.c (valid_builtin_call): Punt if stmt call types
96 aren't compatible also with builtin_decl_explicit. Check pure
97 or non-pure status of BUILT_IN_STR{{,N}CMP,N{LEN,{CAT,CPY}{,_CHK}}}
98 and BUILT_IN_STPNCPY{,_CHK}.
99
100 2019-03-13 Jakub Jelinek <jakub@redhat.com>
101
102 PR debug/89498
103 * dwarf2out.c (size_of_die): For dw_val_class_view_list always use
104 DWARF_OFFSET_SIZE.
105 (value_format): For dw_val_class_view_list never use DW_FORM_loclistx.
106
107 PR middle-end/88588
108 * omp-simd-clone.c (ipa_simd_modify_stmt_ops): Handle PHI args.
109 (ipa_simd_modify_function_body): Handle PHIs.
110
111 2019-03-12 Jakub Jelinek <jakub@redhat.com>
112
113 PR middle-end/89663
114 * builtins.c (expand_builtin_int_roundingfn,
115 expand_builtin_int_roundingfn_2): Return NULL_RTX instead of
116 gcc_unreachable if validate_arglist fails.
117
118 2019-03-09 Jakub Jelinek <jakub@redhat.com>
119
120 PR c/88568
121 * attribs.c (handle_dll_attribute): Don't clear TREE_STATIC for
122 dllimport on VAR_DECLs with RECORD_TYPE or UNION_TYPE DECL_CONTEXT.
123
124 2019-03-05 Jakub Jelinek <jakub@redhat.com>
125
126 PR target/89587
127 * config/rs6000/t-linux (MULTIARCH_DIRNAME): Set to non-empty only
128 if_multiarch.
129
130 PR middle-end/89590
131 * builtins.c (maybe_emit_free_warning): Punt if free doesn't have
132 exactly one argument.
133
134 2019-02-28 Jakub Jelinek <jakub@redhat.com>
135
136 PR c/89520
137 * convert.c (convert_to_real_1, convert_to_integer_1): Punt for
138 builtins if they don't have a single scalar floating point argument.
139 Formatting fixes.
140
141 2019-02-20 Jakub Jelinek <jakub@redhat.com>
142
143 PR middle-end/89412
144 * expr.c (expand_assignment): If result is a MEM, use change_address
145 instead of simplify_gen_subreg.
146
147 2019-02-20 Jakub Jelinek <jakub@redhat.com>
148 David Malcolm <dmalcolm@redhat.com>
149
150 PR middle-end/89091
151 * fold-const.c (decode_field_reference): Return NULL_TREE if
152 lang_hooks.types.type_for_size returns NULL. Check it before
153 overwriting *exp_. Use return NULL_TREE instead of return 0.
154
155 2019-02-20 Jakub Jelinek <jakub@redhat.com>
156
157 PR middle-end/88074
158 PR middle-end/89415
159 * toplev.c (do_compile): Double the emin/emax exponents to workaround
160 buggy mpc_norm.
161
162 2019-02-19 Richard Biener <rguenther@suse.de>
163
164 PR middle-end/88074
165 * toplev.c (do_compile): Initialize mpfr's exponent range
166 based on available float modes.
167
168 2019-04-30 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
169
170 Backport from mainline.
171 2019-04-30 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
172 PR target/86538
173 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
174 Define __ARM_FEATURE_ATOMICS.
175
176 2019-04-30 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
177
178 Backport from mainline
179 2018-12-11 Richard Earnshaw <Richard.Earnshaw@arm.com>
180
181 PR target/37369
182 * config/aarch64/iterators.md (sizem1): Add sizes for
183 SFmode and DFmode.
184 (Vbtype): Add SFmode mapping.
185 * config/aarch64/aarch64.md (copysigndf3, copysignsf3): Delete.
186 (copysign<GPF:mode>3): New expand pattern.
187 (copysign<GPF:mode>3_insn): New insn pattern.
188
189 2019-04-29 Richard Sandiford <richard.sandiford@arm.com>
190
191 Backport from mainline:
192 2019-01-25 Richard Sandiford <richard.sandiford@arm.com>
193
194 PR middle-end/89037
195 * varasm.c (output_constructor_bitfield): Use wi::extract_uhwi
196 instead of accessing TREE_INT_CST_ELT directly.
197
198 2019-04-29 Richard Sandiford <richard.sandiford@arm.com>
199
200 Backport from mainline:
201 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
202
203 PR target/85910
204 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
205 aarch64_evpc_tbl guard.
206
207 2019-04-29 Richard Sandiford <richard.sandiford@arm.com>
208
209 Backport from mainline:
210 2019-03-08 Richard Sandiford <richard.sandiford@arm.com>
211
212 PR debug/89631
213 * dwarf2cfi.c (dwarf2out_frame_debug_expr): Use CONST_POLY_INT
214 instead of POLY_INT_CST.
215
216 2019-04-26 Roman Zhuykov <zhroma@ispras.ru>
217
218 Backport from mainline
219 2019-04-23 Roman Zhuykov <zhroma@ispras.ru>
220
221 PR rtl-optimization/87979
222 * modulo-sched.c (sms_schedule): Start ii value "mii" should
223 not equal zero.
224
225 PR rtl-optimization/84032
226 * modulo-sched.c (ps_insn_find_column): Change condition so that
227 branch will always be the last insn in a row inside partial
228 schedule.
229
230 2019-04-19 Pat Haugen <pthaugen@us.ibm.com>
231
232 Backport from mainline:
233 2019-04-16 Pat Haugen <pthaugen@us.ibm.com>
234
235 PR target/84369
236 * config/rs6000/power9.md: Add store forwarding bypass.
237
238 2019-04-17 Martin Jambor <mjambor@suse.cz>
239
240 Backport from mainline
241 2019-03-10 Martin Jambor <mjambor@suse.cz>
242
243 PR tree-optimization/85762
244 PR tree-optimization/87008
245 PR tree-optimization/85459
246 * tree-sra.c (contains_vce_or_bfcref_p): New parameter, set the bool
247 it points to if there is a type changing MEM_REF. Adjust all callers.
248 (build_accesses_from_assign): Disable total scalarization if
249 contains_vce_or_bfcref_p returns true through the new parameter, for
250 both rhs and lhs.
251
252 2019-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
253
254 Backport from mainline
255 2019-03-15 Kelvin Nilsen <kelvin@gcc.gnu.org>
256
257 PR target/87532
258 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
259 When handling vec_extract, use modular arithmetic to allow
260 constant selectors greater than vector length.
261 * config/rs6000/rs6000.c (rs6000_expand_vector_extract): Allow
262 V1TImode vectors to have constant selector values greater than 0.
263 Use modular arithmetic to compute vector index.
264 (rs6000_split_vec_extract_var): Use modular arithmetic to compute
265 index for in-memory vectors. Correct code generation for
266 in-register vectors. Use inner mode of vector rather than mode of
267 destination for move instruction.
268 (altivec_expand_vec_ext_builtin): Use modular arithmetic to
269 compute index.
270
271 2019-04-12 Kelvin Nilsen <kelvin@gcc.gnu.org>
272
273 PR target/87532
274 * config/rs6000/vsx.md (*vsx_extract_<mode>_<VS_scalar>mode_var):
275 Use QI inner mode with V16QI vector mode.
276
277 2019-04-15 Martin Jambor <mjambor@suse.cz>
278
279 Backport from mainline
280 2019-04-15 Martin Jambor <mjambor@suse.cz>
281
282 PR ipa/89693
283 * cgraph.c (clone_of_p): Loop over clone chain for each step in
284 the thunk chain.
285
286 2019-04-15 Martin Liska <mliska@suse.cz>
287
288 Backport from mainline
289 2019-01-18 Martin Liska <mliska@suse.cz>
290 Richard Biener <rguenther@suse.de>
291
292 PR middle-end/88587
293 * cgraph.h (create_version_clone_with_body): Add new argument
294 with attributes.
295 * cgraphclones.c (cgraph_node::create_version_clone): Add
296 DECL_ATTRIBUTES to a newly created decl. And call
297 valid_attribute_p so that proper cl_target_optimization_node
298 is set for the newly created declaration.
299 * multiple_target.c (create_target_clone): Set DECL_ATTRIBUTES
300 for declaration.
301 (expand_target_clones): Do not call valid_attribute_p, it must
302 be already done.
303 * tree-inline.c (copy_decl_for_dup_finish): Reset mode for
304 vector types.
305
306 2019-04-11 Richard Biener <rguenther@suse.de>
307
308 PR tree-optimization/90018
309 * tree-vect-data-refs.c (vect_preserves_scalar_order_p):
310 Test both SLP and interleaving variants.
311
312 2019-04-10 Matthew Malcomson <matthew.malcomson@arm.com>
313
314 PR target/90024
315 * config/arm/arm.c (neon_valid_immediate): Disallow VOIDmode parameter.
316 * config/arm/constraints.md (Dm, DN, Dn): Split previous Dn constraint
317 into three.
318 * config/arm/neon.md (*neon_mov<mode>): Account for TImode and DImode
319 differences directly.
320 (*smax<mode>3_neon, vashl<mode>3, vashr<mode>3_imm): Use Dm constraint.
321
322 2019-04-07 Uroš Bizjak <ubizjak@gmail.com>
323
324 PR target/89945
325 * config/i386/i386.md (anddi_1 to andsi_1_zext splitter):
326 Avoid calling gen_lowpart with SYMBOL_REF and LABEL_REF operand.
327
328 2019-04-04 Martin Sebor <msebor@redhat.com>
329
330 PR middle-end/89934
331 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Bail
332 out if the number of arguments is less than expected.
333
334 2019-04-03 Richard Biener <rguenther@suse.de>
335
336 PR lto/89896
337 * lto-wrapper.c (run_gcc): Avoid implicit rules making
338 the all target phony.
339
340 2019-04-02 Uroš Bizjak <ubizjak@gmail.com>
341
342 PR target/89902
343 PR target/89903
344 * config/i386/i386.c (dimode_scalar_to_vector_candidate_p):
345 Return false for variable DImode shifts.
346 (dimode_scalar_chain::compute_convert_gain): Do not handle
347 register count operand in variable DImode shifts.
348 (dimode_scalar_chain::make_vector_copies): Remove support to copy
349 count argument of a variable shift instruction to a vector register.
350 (dimode_scalar_chain::convert_reg): Remove support to convert
351 count argument of a variable shift instruction.
352
353 2019-03-29 Kugan Vivekanandarajah <kuganv@linaro.org>
354
355 Backport from mainline
356 2019-03-29 Kugan Vivekanandarajah <kuganv@linaro.org>
357 Eric Botcazou <ebotcazou@adacore.com>
358
359 PR rtl-optimization/89862
360 * rtl.h (word_register_operation_p): Exclude CONST_INT from operations
361 that operates on the full registers for WORD_REGISTER_OPERATIONS
362 architectures.
363
364 2019-03-28 Uroš Bizjak <ubizjak@gmail.com>
365
366 PR target/89848
367 * config/i386/i386.c (dimode_scalar_chain::make_vector_copies):
368 Also process XEXP (src, 0) of a shift insn.
369
370 2019-03-28 Martin Liska <mliska@suse.cz>
371
372 Backport from mainline
373 2018-11-05 Martin Liska <mliska@suse.cz>
374
375 PR web/87829
376 * doc/invoke.texi: Remove options that are
377 not disabled with -Os.
378
379 2019-03-26 Uroš Bizjak <ubizjak@gmail.com>
380
381 PR target/89827
382 * config/i386/i386.c (dimode_scalar_chain::convert_reg):
383 Also process XEXP (src, 0) of a shift insn.
384
385 2019-03-25 Andreas Krebbel <krebbel@linux.ibm.com>
386
387 Backport from mainline
388 2019-03-20 Andreas Krebbel <krebbel@linux.ibm.com>
389
390 PR target/89775
391 * config/s390/s390.c (global_not_special_regno_p): Move to make it
392 available to ...
393 (s390_optimize_register_info): Use global_not_special_regno_p to
394 check for global regs.
395
396 2019-03-22 Bill Schmidt <wschmidt@linux.ibm.com>
397
398 Backport from mainline
399 2019-03-22 Bill Schmidt <wschmidt@linux.ibm.com>
400
401 * config/rs6000/mmintrin.h (_mm_sub_pi32): Fix typo.
402
403 2019-03-21 Bill Schmidt <wschmidt@linux.ibm.com>
404
405 Backport from mainline
406 2019-03-08 Bill Schmidt <wschmidt@linux.ibm.com>
407
408 * config/rs6000/rs6000-p8swap.c (rs6000_analyze_swaps): Rebuild
409 ud- and du-chains between phases.
410
411 2019-03-19 Richard Biener <rguenther@suse.de>
412
413 PR debug/88389
414 * opts.c (finish_options): Disable -gsplit-dwarf when doing LTO.
415
416 2019-03-19 Eric Botcazou <ebotcazou@adacore.com>
417
418 PR rtl-optimization/89753
419 * loop-unroll.c (decide_unroll_constant_iterations): Make guard for
420 explicit unrolling factor even more robust.
421
422 2019-03-18 Martin Sebor <msebor@redhat.com>
423
424 PR middle-end/88273
425 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range):
426 Handle anti-ranges the same as no range at all.
427
428 2019-03-18 Martin Jambor <mjambor@suse.cz>
429
430 Backport from mainline
431 2019-03-18 Martin Jambor <mjambor@suse.cz>
432
433 PR tree-optimization/89546
434 * tree-sra.c (propagate_subaccesses_across_link): Requeue new_acc if
435 any propagation to its children took place.
436
437 2019-03-17 H.J. Lu <hongjiu.lu@intel.com>
438
439 Backport from mainline
440 2019-03-14 H.J. Lu <hongjiu.lu@intel.com>
441
442 PR target/89523
443 * config/i386/i386.c (ix86_print_operand): Handle 'M' to add
444 addr32 prefix to VSIB address for X32.
445 * config/i386/sse.md (*avx512pf_gatherpf<mode>sf_mask): Prepend
446 "%M2" to opcode.
447 (*avx512pf_gatherpf<mode>df_mask): Likewise.
448 (*avx512pf_scatterpf<mode>sf_mask): Likewise.
449 (*avx512pf_scatterpf<mode>df_mask): Likewise.
450 (*avx2_gathersi<mode>): Prepend "%M3" to opcode.
451 (*avx2_gathersi<mode>_2): Prepend "%M2" to opcode.
452 (*avx2_gatherdi<mode>): Prepend "%M3" to opcode.
453 (*avx2_gatherdi<mode>_2): Prepend "%M2" to opcode.
454 (*avx2_gatherdi<mode>_3): Prepend "%M3" to opcode.
455 (*avx2_gatherdi<mode>_4): Prepend "%M2" to opcode.`
456 (*avx512f_gathersi<mode>): Prepend "%M4" to opcode.
457 (*avx512f_gathersi<mode>_2): Prepend "%M3" to opcode.
458 (*avx512f_gatherdi<mode>): Prepend "%M4" to opcode.
459 (*avx512f_gatherdi<mode>_2): Prepend "%M3" to opcode.
460 (*avx512f_scattersi<mode>): Prepend "%M0" to opcode.
461 (*avx512f_scatterdi<mode>): Likewise.
462
463 2019-03-15 Richard Biener <rguenther@suse.de>
464
465 Backport from mainline
466 2018-11-30 Jakub Jelinek <jakub@redhat.com>
467
468 PR testsuite/85368
469 * params.def (PARAM_LOGICAL_OP_NON_SHORT_CIRCUIT): New param.
470 * tree-ssa-ifcombine.c (ifcombine_ifandif): If
471 --param logical-op-non-short-circuit is present, override
472 LOGICAL_OP_NON_SHORT_CIRCUIT value from the param.
473 * fold-const.c (fold_range_test, fold_truth_andor): Likewise.
474
475 2019-03-15 Martin Liska <mliska@suse.cz>
476
477 PR other/89712
478 * doc/invoke.texi: Remove -fdump-class-hierarchy option.
479
480 2019-03-14 Martin Jambor <mjambor@suse.cz>
481
482 Backport from mainline
483 2019-03-07 Martin Jambor <mjambor@suse.cz>
484
485 PR lto/87525
486 * ipa-cp.c (perform_estimation_of_a_value): Account zero time benefit
487 for extern inline functions.
488
489 2019-03-14 Richard Biener <rguenther@suse.de>
490
491 PR middle-end/89572
492 * tree-scalar-evolution.c (get_loop_exit_condition): Use
493 safe_dyn_cast.
494 * tree-ssa-loop-ivcanon.c (canonicalize_loop_induction_variables):
495 Use gimple_location_safe.
496
497 2019-03-13 Vladimir Makarov <vmakarov@redhat.com>
498
499 PR target/85860
500 * lra-constraints.c (inherit_in_ebb): Update
501 potential_reload_hard_regs along with live_hard_regs.
502
503 2019-03-14 Richard Biener <rguenther@suse.de>
504
505 Backport from mainline
506 2019-03-13 Richard Biener <rguenther@suse.de>
507
508 PR middle-end/89677
509 * tree-scalar-evolution.c (simplify_peeled_chrec): Do not
510 throw FP expressions at tree-affine.
511
512 2019-03-01 Richard Biener <rguenther@suse.de>
513
514 PR middle-end/89497
515 * tree-cfgcleanup.h (cleanup_tree_cfg): Add SSA update flags
516 argument, defaulted to zero.
517 * passes.c (execute_function_todo): Pass down SSA update flags
518 to cleanup_tree_cfg.
519 * tree-cfgcleanup.c: Include tree-into-ssa.h and tree-cfgcleanup.h.
520 (cleanup_tree_cfg_1): After cleanup_control_flow_pre update SSA
521 form if requested.
522 (cleanup_tree_cfg_noloop): Pass down SSA update flags.
523 (cleanup_tree_cfg): Get and pass down SSA update flags.
524
525 2019-02-18 Richard Biener <rguenther@suse.de>
526
527 PR tree-optimization/89296
528 * tree-ssa-loop-ch.c (ch_base::copy_headers): Restrict setting
529 of no-warning flag to cases that might emit the bogus warning.
530
531 2019-03-13 Andreas Krebbel <krebbel@linux.ibm.com>
532
533 Backport from mainline
534 2019-03-11 Andreas Krebbel <krebbel@linux.ibm.com>
535
536 * config/s390/s390.c (s390_expand_builtin): Do the copy_to_reg not
537 only on the else branch.
538
539 2019-03-13 Andreas Krebbel <krebbel@linux.ibm.com>
540
541 Backport from mainline
542 2019-02-07 Andreas Krebbel <krebbel@linux.ibm.com>
543
544 * config/s390/s390-builtin-types.def: Add new types.
545 * config/s390/s390-builtins.def: (s390_vec_xl, s390_vec_xld2)
546 (s390_vec_xlw4): Make the memory operand into a const pointer.
547 (s390_vec_xld2, s390_vec_xlw4): Add a variant for single precision
548 float.
549 * config/s390/s390-c.c (s390_expand_overloaded_builtin): Generate
550 a new vector type with the alignment of the scalar memory operand.
551
552 2019-03-12 Richard Biener <rguenther@suse.de>
553
554 PR tree-optimization/89664
555 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Properly
556 free the occurance tree after the early out.
557
558 2019-03-12 Andre Vieira <andre.simoesdiasvieira@arm.com>
559
560 Backport from mainline
561 2019-03-08 Andre Vieira <andre.simoesdiasvieira@arm.com>
562
563 * config/arm/arm.h (TARGET_FP16_TO_DOUBLE): Add TARGET_VFP_DOUBLE
564 requirement.
565
566 2019-03-11 Eric Botcazou <ebotcazou@adacore.com>
567
568 PR rtl-optimization/89588
569 * loop-unroll.c (decide_unroll_constant_iterations): Make guard for
570 explicit unrolling factor more robust.
571
572 2019-03-11 Martin Liska <mliska@suse.cz>
573
574 Backport from mainline
575 2019-03-08 Martin Liska <mliska@suse.cz>
576
577 PR target/86952
578 * config/i386/i386.c (ix86_option_override_internal): Disable
579 jump tables when retpolines are used.
580
581 2019-03-11 Martin Liska <mliska@suse.cz>
582
583 Backport from mainline
584 2019-02-11 David Malcolm <dmalcolm@redhat.com>
585
586 PR lto/88147
587 * input.c (selftest::test_line_offset_overflow): New selftest.
588 (selftest::input_c_tests): Call it.
589
590 2019-03-08 Martin Jambor <mjambor@suse.cz>
591
592 Backport from mainline
593 2019-03-07 Martin Jambor <mjambor@suse.cz>
594
595 PR ipa/88235
596 * cgraph.h (cgraph_node): New inline method former_thunk_p.
597 * cgraph.c (cgraph_node::dump): Dump a note if node is a former thunk.
598 (clone_of_p): Treat expanded thunks like thunks, be optimistic if they
599 have multiple callees. At the end check if declarations match as
600 opposed to cgraph_nodes.
601
602 2019-03-06 Tamar Christina <tamar.christina@arm.com>
603
604 Backport from trunk.
605 2019-02-25 Tamar Christina <tamar.christina@arm.com>
606
607 PR target/88530
608 * common/config/aarch64/aarch64-common.c
609 (struct aarch64_option_extension): Add is_synthetic.
610 (all_extensions): Use it.
611 (TARGET_OPTION_INIT_STRUCT): Define hook.
612 (struct gcc_targetm_common): Moved to end.
613 (all_extensions_by_on): New.
614 (opt_ext_cmp, typedef opt_ext): New.
615 (aarch64_option_init_struct): New.
616 (aarch64_contains_opt): New.
617 (aarch64_get_extension_string_for_isa_flags): Output smallest set.
618 * config/aarch64/aarch64-option-extensions.def
619 (AARCH64_OPT_EXTENSION): Explicitly include AES and SHA2 in crypto.
620 (fp, simd, crc, lse, fp16, rcpc, rdma, dotprod, aes, sha2, sha3,
621 sm4, fp16fml, sve):
622 Set is_synthetic to false.
623 (crypto): Set is_synthetic to true.
624 * config/aarch64/driver-aarch64.c (AARCH64_OPT_EXTENSION): Add
625 SYNTHETIC.
626
627 2019-03-06 Tamar Christina <tamar.christina@arm.com>
628
629 Backport from trunk.
630 2019-02-28 Tamar Christina <tamar.christina@arm.com>
631
632 PR target/88530
633 * config/aarch64/aarch64-option-extensions.def: Document it.
634 * config/aarch64/driver-aarch64.c (host_detect_local_cpu): Skip feature
635 if empty hwcaps.
636
637 2019-03-06 Xiong Hu Luo <luoxhu@linux.ibm.com>
638
639 Backport of r268834 from mainline to gcc-8-branch.
640 2019-02-13 Xiong Hu Luo <luoxhu@linux.vnet.ibm.com>
641
642 * config/rs6000/altivec.h (vec_sbox_be, vec_cipher_be,
643 vec_cipherlast_be, vec_ncipher_be, vec_ncipherlast_be): New #defines.
644 * config/rs6000/crypto.md (CR_vqdi): New define_mode_iterator.
645 (crypto_vsbox_<mode>, crypto_<CR_insn>_<mode>): New define_insns.
646 * config/rs6000/rs6000-builtin.def (VSBOX_BE): New BU_CRYPTO_1.
647 (VCIPHER_BE, VCIPHERLAST_BE, VNCIPHER_BE, VNCIPHERLAST_BE):
648 New BU_CRYPTO_2.
649 * config/rs6000/rs6000.c (builtin_function_type)
650 <CRYPTO_BUILTIN_VSBOX_BE, CRYPTO_BUILTIN_VCIPHER_BE,
651 CRYPTO_BUILTIN_VCIPHERLAST_BE, CRYPTO_BUILTIN_VNCIPHER_BE,
652 CRYPTO_BUILTIN_VNCIPHERLAST_BE>: New switch options.
653 * doc/extend.texi (vec_sbox_be, vec_cipher_be, vec_cipherlast_be,
654 vec_ncipher_be, vec_ncipherlast_be): New builtin functions.
655
656 2019-03-05 Richard Biener <rguenther@suse.de>
657
658 Backport from mainline
659 2019-02-26 Richard Biener <rguenther@suse.de>
660
661 PR tree-optimization/89505
662 * tree-ssa-structalias.c (compute_dependence_clique): Make sure
663 to handle restrict pointed-to vars with multiple subvars
664 correctly.
665
666 2019-03-01 Tamar Christina <tamar.christina@arm.com>
667
668 PR target/89517
669 * config/aarch64/aarch64-option-extensions.def (fp, simd, crypto,
670 fp16): Collapse line.
671
672 2019-03-01 Richard Biener <rguenther@suse.de>
673
674 Backport from mainline
675 2019-03-01 Jakub Jelinek <jakub@redhat.com>
676
677 PR bootstrap/89539
678 * dwarf2out.c (output_comdat_type_unit): Add ATTRIBUTE_UNUSED to
679 early_lto_debug argument.
680
681 2019-02-27 Richard Biener <rguenther@suse.de>
682
683 PR debug/88878
684 * dwarf2out.c (use_debug_types): Disable when in_lto_p.
685
686 2019-02-27 Richard Biener <rguenther@suse.de>
687
688 PR debug/88878
689 * dwarf2out.c (output_comdat_type_unit): Add early_lto_debug
690 parameter, prefix section name with .gnu.debuglto_ if true.
691 (dwarf2out_finish): Pass false to output_comdat_type_unit.
692 (dwarf2out_early_finish): Pass true to output_comdat_type_unit.
693
694 2019-02-27 Richard Biener <rguenther@suse.de>
695
696 PR debug/89514
697 * dwarf2out.c (size_of_die): Key on AT_ref (a)->comdat_type_p
698 rather than on use_debug_types, doing what output_die does.
699 (value_format): Likewise.
700
701 2019-02-28 Eric Botcazou <ebotcazou@adacore.com>
702
703 PR tree-optimization/89536
704 * tree-ssa-dom.c (edge_info::derive_equivalences) <BIT_NOT_EXPR>: Test
705 only whether bit #0 of the value is 0 instead of the entire value.
706
707 2019-02-28 Li Jia He <helijia@linux.ibm.com>
708
709 Backport from trunk
710 2019-02-20 Li Jia He <helijia@linux.ibm.com>
711
712 PR target/88100
713 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin)
714 <case ALTIVEC_BUILTIN_VSPLTISB, ALTIVEC_BUILTIN_VSPLTISH,
715 ALTIVEC_BUILTIN_VSPLTISW>: Don't convert the operand before
716 range checking it.
717
718 2019-02-27 Uroš Bizjak <ubizjak@gmail.com>
719
720 PR target/89397
721 * config/i386/i386.c (ix86_atomic_assign_expand_fenv): Check
722 TARGET_SSE in addition to TARGET_SSE_MATH.
723
724 (ix86_excess_precision): Ditto.
725 (ix86_float_exceptions_rounding_supported_p): Ditto.
726 (use_rsqrt_p): Ditto.
727 * config/i386/sse.md (rsqrt<mode>2): Ditto.
728
729 2019-02-27 Jakub Jelinek <jakub@redhat.com>
730
731 Backported from mainline
732 2019-02-18 Jakub Jelinek <jakub@redhat.com>
733
734 PR target/89361
735 * config/s390/s390.c (s390_indirect_branch_attrvalue,
736 s390_indirect_branch_settings): Define unconditionally.
737 (s390_set_current_function): Likewise, but guard the whole body except
738 the s390_indirect_branch_settings call with
739 #if S390_USE_TARGET_ATTRIBUTE.
740 (TARGET_SET_CURRENT_FUNCTION): Redefine unconditionally.
741
742 2019-02-26 Eric Botcazou <ebotcazou@adacore.com>
743
744 Backport from mainline
745 2019-02-19 Eric Botcazou <ebotcazou@adacore.com>
746
747 * rtlanal.c (get_initial_register_offset): Fall back to the estimate
748 as long as the epilogue isn't completed.
749
750 2019-02-26 Eric Botcazou <ebotcazou@adacore.com>
751
752 * tree-ssa-dom.c (edge_info::derive_equivalences) <BIT_IOR_EXPR>: Fix
753 and move around comment.
754 <BIT_AND_EXPR>: Likewise.
755 <BIT_NOT_EXPR>: Add specific handling for boolean types.
756
757 2019-02-24 Alan Modra <amodra@gmail.com>
758
759 PR target/89271
760 * config/rs6000/rs6000.md (<bd>_<mode> split): Check for an int
761 output reg on add insn.
762 (<bd>tf_<mode> split): Likewise. Match predicates with insn.
763
764 2019-02-22 Jakub Jelinek <jakub@redhat.com>
765
766 * BASE-VER: Set to 8.3.1.
767
768 2019-02-22 Release Manager
769
770 * GCC 8.3.0 released.
771
772 2019-02-15 Richard Biener <rguenther@suse.de>
773 Jakub Jelinek <jakub@redhat.com>
774
775 PR tree-optimization/89278
776 * tree-loop-distribution.c: Include tree-eh.h.
777 (generate_memset_builtin, generate_memcpy_builtin): Call
778 rewrite_to_non_trapping_overflow on builtin->size before passing it
779 to force_gimple_operand_gsi.
780
781 2019-02-15 Jakub Jelinek <jakub@redhat.com>
782
783 PR other/89342
784 * optc-save-gen.awk: Handle optimize_fast like optimize_size or
785 optimize_debug.
786 * opth-gen.awk: Likewise.
787
788 2019-02-14 David Malcolm <dmalcolm@redhat.com>
789
790 Backport of r267957 from trunk.
791 2019-01-15 David Malcolm <dmalcolm@redhat.com>
792
793 PR c++/88795
794 * tree.c (build_function_type): Assert that arg_types is not
795 error_mark_node.
796
797 2019-02-14 Jakub Jelinek <jakub@redhat.com>
798
799 PR rtl-optimization/89354
800 * combine.c (make_extraction): Punt if extraction_mode is narrower
801 than len bits.
802
803 2019-02-14 David Malcolm <dmalcolm@redhat.com>
804
805 Backport of r263339 from trunk.
806 2018-08-06 David Malcolm <dmalcolm@redhat.com>
807
808 * function-tests.c (selftest::test_expansion_to_rtl): Call
809 free_after_compilation.
810
811 2019-02-14 David Malcolm <dmalcolm@redhat.com>
812
813 Backport of r263295 from trunk.
814 2018-08-03 David Malcolm <dmalcolm@redhat.com>
815
816 * doc/gcov.texi (-x): Remove duplicate "to".
817 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
818 (-Wif-not-aligned): Remove duplicate "is".
819 (-flto): Remove duplicate "the".
820 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
821 duplicate "v5.00.b".
822 (MSP430 Options): Remove duplicate "and" from the description
823 of "-mgprel-sec=regexp".
824 (x86 Options): Remove duplicate copies of "vmldLog102" and
825 vmlsLog104 from description of "-mveclibabi=type".
826
827 2019-02-14 David Malcolm <dmalcolm@redhat.com>
828
829 Backport of r263275 from trunk.
830 2018-08-02 David Malcolm <dmalcolm@redhat.com>
831
832 * diagnostic-show-locus.c (diagnostic_show_locus): Use
833 pp_take_prefix when saving the existing prefix.
834 * diagnostic.c (diagnostic_append_note): Likewise.
835 * langhooks.c (lhd_print_error_function): Likewise.
836 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
837 param's type. Free the existing prefix.
838 (pp_take_prefix): New function.
839 (pretty_printer::pretty_printer): Drop the prefix parameter.
840 Rename the length parameter to match the comment.
841 (pretty_printer::~pretty_printer): Free the prefix.
842 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
843 parameter.
844 (struct pretty_printer): Drop the "const" from "prefix" field's
845 type and clarify memory management.
846 (pp_set_prefix): Drop the "const" from the 2nd param.
847 (pp_take_prefix): New decl.
848
849 2019-02-14 Segher Boessenkool <segher@kernel.crashing.org>
850
851 Backport from trunk
852 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
853
854 PR target/86684
855 PR target/87149
856 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
857
858 2019-02-14 Segher Boessenkool <segher@kernel.crashing.org>
859
860 Backport from trunk
861 2019-01-18 Segher Boessenkool <segher@kernel.crashing.org>
862
863 PR target/88892
864 * config/rs6000/rs6000.md (*movsi_from_df): Allow only register
865 operands.
866
867 2019-02-14 Segher Boessenkool <segher@kernel.crashing.org>
868
869 Backport from trunk
870 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
871
872 PR rtl-optimization/85805
873 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
874 value for hard registers if that was written in the same mode.
875
876 2019-02-14 Martin Liska <mliska@suse.cz>
877
878 Backport from mainline
879 2019-02-14 Martin Liska <mliska@suse.cz>
880
881 PR rtl-optimization/89242
882 * dce.c (delete_unmarked_insns): Call free_dominance_info we
883 process a transformation.
884
885 2019-02-14 Martin Liska <mliska@suse.cz>
886
887 Backport from mainline
888 2019-02-13 Martin Liska <mliska@suse.cz>
889
890 PR lto/88858
891 * cfgrtl.c (remove_barriers_from_footer): New function.
892 (try_redirect_by_replacing_jump): Use it.
893 (cfg_layout_redirect_edge_and_branch): Likewise.
894
895 2019-02-14 Martin Liska <mliska@suse.cz>
896
897 Backport from mainline
898 2019-02-11 Martin Liska <mliska@suse.cz>
899
900 PR ipa/89009
901 * ipa-cp.c (build_toporder_info): Remove usage of a param.
902 * ipa-inline.c (inline_small_functions): Likewise.
903 * ipa-pure-const.c (propagate_pure_const): Likewise.
904 (propagate_nothrow): Likewise.
905 * ipa-reference.c (propagate): Likewise.
906 * ipa-utils.c (struct searchc_env): Remove unused field.
907 (searchc): Always search across AVAIL_INTERPOSABLE.
908 (ipa_reduced_postorder): Always allow AVAIL_INTERPOSABLE as
909 the only called IPA pure const can properly not propagate
910 across interposable boundary.
911 * ipa-utils.h (ipa_reduced_postorder): Remove param.
912
913 2019-02-14 Jakub Jelinek <jakub@redhat.com>
914
915 PR tree-optimization/89314
916 * fold-const.c (fold_binary_loc): Cast strlen argument to
917 const char * before dereferencing it. Formatting fixes.
918
919 Backported from mainline
920 2019-02-13 Jakub Jelinek <jakub@redhat.com>
921
922 PR middle-end/89303
923 * tree-ssa-structalias.c (set_uids_in_ptset): Or in vi->is_heap_var
924 into pt->vars_contains_escaped_heap instead of setting
925 pt->vars_contains_escaped_heap to it.
926
927 PR middle-end/89281
928 * optabs.c (prepare_cmp_insn): Use UINTVAL (size) instead of
929 INTVAL (size), compare it to GET_MODE_MASK instead of
930 1 << GET_MODE_BITSIZE.
931
932 PR target/89290
933 * config/i386/predicates.md (x86_64_immediate_operand): Allow
934 TLS UNSPECs offsetted by signed 32-bit CONST_INT even with
935 -mcmodel=large.
936
937 2019-02-09 Jakub Jelinek <jakub@redhat.com>
938
939 PR middle-end/89246
940 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
941 If !node->definition and TYPE_ARG_TYPES is non-NULL, use
942 TYPE_ARG_TYPES instead of DECL_ARGUMENTS.
943
944 2019-02-13 Bill Schmidt <wschmidt@linux.ibm.com>
945
946 Backport from mainline
947 2019-02-11 Bill Schmidt <wschmidt@linux.ibm.com>
948
949 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Shift-right
950 and shift-left vector built-ins need to include a TRUNC_MOD_EXPR
951 for correct semantics.
952
953 2019-02-13 Richard Biener <rguenther@suse.de>
954
955 Backport from mainline
956 2019-01-08 Richard Biener <rguenther@suse.de>
957
958 PR tree-optimization/86554
959 * tree-ssa-sccvn.c (visit_nary_op): When value-numbering to
960 expressions with different overflow behavior make sure there's an
961 available expression on the path.
962
963 2019-02-13 Martin Liska <mliska@suse.cz>
964
965 PR lto/89260
966 * lto-streamer.h (LTO_minor_version): Bump version due
967 to r268698.
968
969 2019-02-13 Richard Biener <rguenther@suse.de>
970
971 Backport from mainline
972 2019-02-12 Richard Biener <rguenther@suse.de>
973
974 PR tree-optimization/89253
975 * tree-ssa-loop-split.c (tree_ssa_split_loops): Check we can
976 duplicate the loop.
977
978 2019-02-08 Richard Biener <rguenther@suse.de>
979
980 PR middle-end/89223
981 * tree-data-ref.c (initialize_matrix_A): Fail if constant
982 doesn't fit in HWI.
983 (analyze_subscript_affine_affine): Handle failure from
984 initialize_matrix_A.
985
986 2019-01-28 Richard Biener <rguenther@suse.de>
987
988 PR tree-optimization/88739
989 * tree-ssa-sccvn.c (vn_reference_lookup_3): Avoid generating
990 BIT_FIELD_REFs of non-mode-precision integral operands.
991
992 2019-02-12 Jan Hubicka <hubicka@ucw.cz>
993
994 Backport from mainline:
995 2019-02-09 Jan Hubicka <hubicka@ucw.cz>
996
997 * ipa-visibility.c (localize_node): Also do not localize
998 LDPR_PREVAILING_DEF_IRONLY_EXP.
999
1000 2019-02-11 Stefan Agner <stefan@agner.ch>
1001
1002 Backport from mainline.
1003 2019-01-10 Stefan Agner <stefan@agner.ch>
1004
1005 PR target/88648
1006 * config/arm/arm.c (arm_option_override_internal): Force
1007 opts->x_inline_asm_unified to true only if TARGET_THUMB2_P.
1008
1009 2019-02-09 Jan Hubicka <hubicka@ucw.cz>
1010
1011 Backport from mainline:
1012 2019-01-05 Jan Hubicka <hubicka@ucw.cz>
1013
1014 PR tree-opt/86020
1015 Revert:
1016 2017-05-22 Jan Hubicka <hubicka@ucw.cz>
1017
1018 * ipa-inline.c (edge_badness): Use inlined_time instead of
1019 inline_summaries->get.
1020
1021 2019-02-09 Aaron Sawdey <acsawdey@linux.ibm.com>
1022
1023 Backported from mainline
1024 2019-02-05 Aaron Sawdey <acsawdey@linux.ibm.com>
1025
1026 PR target/89112
1027 * config/rs6000/rs6000.md (<bd>tf_<mode>): Generate a local label
1028 for the long branch case.
1029
1030 2019-02-05 Aaron Sawdey <acsawdey@linux.ibm.com>
1031
1032 PR target/89112
1033 * config/rs6000/rs6000-string.c (do_ifelse, expand_cmp_vec_sequence,
1034 expand_compare_loop, expand_block_compare_gpr,
1035 expand_strncmp_align_check, expand_strncmp_gpr_sequence): Insert
1036 REG_BR_PROB notes in inline expansion of memcmp/strncmp. Add
1037 #include "profile-count.h" and "predict.h" for types and functions
1038 needed to work with REG_BR_PROB notes.
1039
1040 2019-02-09 Aaron Sawdey <acsawdey@linux.ibm.com>
1041
1042 * config/rs6000/rs6000-string.c (expand_compare_loop,
1043 expand_block_compare): Insert REG_BR_PROB notes in inline expansion of
1044 memcmp/strncmp.
1045
1046 2019-02-09 Jakub Jelinek <jakub@redhat.com>
1047
1048 Backported from mainline
1049 2019-01-16 David Malcolm <dmalcolm@redhat.com>
1050
1051 PR target/88861
1052 * combine.c (delete_noop_moves): Convert to "bool" return,
1053 returning true if any edges are eliminated.
1054 (combine_instructions): Also return true if delete_noop_moves
1055 returns true.
1056
1057 2019-02-08 Jakub Jelinek <jakub@redhat.com>
1058
1059 PR rtl-optimization/89234
1060 * except.c (copy_reg_eh_region_note_forward): Return if note_or_insn
1061 is a NOTE, CODE_LABEL etc. - rtx_insn * other than INSN_P.
1062 (copy_reg_eh_region_note_backward): Likewise.
1063
1064 2019-02-09 Alan Modra <amodra@gmail.com>
1065
1066 PR target/88343
1067 * config/rs6000/rs6000.c (save_reg_p): Match logic in
1068 rs6000_emit_prologue emitting pic_offset_table setup.
1069
1070 2019-02-08 Richard Biener <rguenther@suse.de>
1071
1072 Backport from mainline
1073 2018-11-13 Richard Biener <rguenther@suse.de>
1074
1075 PR tree-optimization/86991
1076 * tree-vect-loop.c (vect_is_slp_reduction): Delay reduction
1077 group building until we have successfully detected the SLP
1078 reduction.
1079 (vect_is_simple_reduction): Remove fixup code here.
1080
1081 2019-02-08 Richard Biener <rguenther@suse.de>
1082
1083 Backport from mainline
1084 2019-02-03 Richard Biener <rguenther@suse.de>
1085
1086 PR debug/87295
1087 * dwarf2out.c (copy_ancestor_tree): Register non-stubs as
1088 orig.
1089
1090 2019-01-29 Richard Biener <rguenther@suse.de>
1091
1092 PR debug/87295
1093 * dwarf2out.c (collect_skeleton_dies): New helper.
1094 (copy_decls_for_unworthy_types): Call it.
1095 (build_abbrev_table): Do not try to replace
1096 DW_AT_signature refs with local refs.
1097
1098 2019-01-17 Richard Biener <rguenther@suse.de>
1099
1100 PR lto/86736
1101 * dwarf2out.c (want_pubnames): Never generate pubnames sections
1102 and friends for the LTO part of debug info.
1103
1104 2019-01-24 Richard Biener <rguenther@suse.de>
1105
1106 PR lto/87187
1107 * tree-streamer-out.c (write_ts_decl_common_tree_pointers):
1108 When in "legacy" debug mode make sure to reset self-origins.
1109
1110 2019-01-15 Richard Biener <rguenther@suse.de>
1111
1112 PR debug/88046
1113 * dwarf2out.c (gen_member_die): Do not generate inheritance
1114 DIEs late.
1115
1116 2018-11-22 Richard Biener <rguenther@suse.de>
1117
1118 PR lto/87229
1119 PR lto/88112
1120 * lto-streamer-out.c (lto_is_streamable): Allow CALL_EXPRs
1121 which can appear in size expressions.
1122 * tree-streamer-in.c (unpack_ts_base_value_fields): Stream
1123 CALL_EXPR_BY_DESCRIPTOR.
1124 (streamer_read_tree_bitfields): Stream CALL_EXPR_IFN.
1125 * tree-streamer-out.c (pack_ts_base_value_fields): Stream
1126 CALL_EXPR_BY_DESCRIPTOR.
1127 (streamer_write_tree_bitfields): Stream CALL_EXPR_IFN.
1128
1129 2019-02-08 Christophe Lyon <christophe.lyon@linaro.org>
1130
1131 Backport from mainline
1132 2019-01-07 Christophe Lyon <christophe.lyon@linaro.org>
1133
1134 PR target/85596
1135 * doc/install.texi (with-multilib-list): Document for aarch64.
1136
1137 2019-02-08 Richard Biener <rguenther@suse.de>
1138
1139 Backport from mainline
1140 2018-12-10 Richard Biener <rguenther@suse.de>
1141
1142 PR tree-optimization/88427
1143 * vr-values.c (vr_values::extract_range_from_phi_node):
1144 Handle symbolic ranges conservatively when trying to drop
1145 to Inf +- 1.
1146
1147 2018-11-28 Richard Biener <rguenther@suse.de>
1148
1149 PR tree-optimization/88217
1150 * vr-values.c (vr_values::extract_range_from_phi_node): Make
1151 sure to handle results > +INF and < -INF correctly when
1152 trying to drop down to +INF - 1 or -INF + 1.
1153
1154 2018-11-23 Richard Biener <rguenther@suse.de>
1155
1156 PR tree-optimization/88149
1157 * tree-vect-slp.c (vect_slp_analyze_node_operations): Detect
1158 the case where there are two different def types for the
1159 same operand at different operand position in the same stmt.
1160
1161 2019-02-07 Jakub Jelinek <jakub@redhat.com>
1162
1163 Backported from mainline
1164 2019-02-05 Jakub Jelinek <jakub@redhat.com>
1165
1166 PR target/89188
1167 * dce.c (delete_unmarked_insns): Don't remove no-op moves if they
1168 can throw, non-call exceptions are enabled and we can't delete
1169 dead exceptions or alter cfg. Set must_clean if
1170 delete_insn_and_edges returns true, don't set it blindly for calls.
1171
1172 PR rtl-optimization/89195
1173 * combine.c (make_extraction): For MEMs, don't extract bytes outside
1174 of the original MEM.
1175
1176 PR target/89186
1177 * optabs.c (prepare_cmp_insn): Pass x and y to
1178 emit_block_comp_via_libcall rather than XEXP (x, 0) and XEXP (y, 0).
1179
1180 2019-02-02 Jakub Jelinek <jakub@redhat.com>
1181
1182 PR middle-end/87887
1183 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
1184 Punt with warning on aggregate return or argument types. Ignore
1185 type/mode checking for uniform arguments.
1186
1187 2019-02-01 Jakub Jelinek <jakub@redhat.com>
1188
1189 PR tree-optimization/88107
1190 * tree-cfg.c (find_outermost_region_in_block): Add ALL argument,
1191 instead of assertion that eh_region_outermost is non-NULL, if it
1192 is NULL, set *ALL to true and return NULL.
1193 (move_sese_region_to_fn): Adjust caller, if all is set, call
1194 duplicate_eh_regions with NULL region.
1195
1196 2019-01-31 Jakub Jelinek <jakub@redhat.com>
1197
1198 PR sanitizer/89124
1199 * ipa-inline.c (sanitize_attrs_match_for_inline_p): Allow inlining
1200 always_inline callees into no_sanitize_address callers.
1201
1202 2019-01-30 Jakub Jelinek <jakub@redhat.com>
1203
1204 PR c++/89105
1205 * config/i386/i386.c (ix86_warn_parameter_passing_abi): Don't warn
1206 for arguments to functions that are TU-local and shouldn't be
1207 referenced by assembly.
1208
1209 2019-01-29 Jakub Jelinek <jakub@redhat.com>
1210
1211 PR c++/66676
1212 PR ipa/89104
1213 * omp-simd-clone.c (simd_clone_clauses_extract)
1214 <case OMP_CLAUSE_ALIGNED>: Ignore clauses with NULL
1215 OMP_CLAUSE_ALIGNED_ALIGNMENT.
1216
1217 2019-01-28 Jakub Jelinek <jakub@redhat.com>
1218
1219 PR middle-end/89002
1220 * gimplify.c (gimplify_omp_for): When adding OMP_CLAUSE_*_GIMPLE_SEQ
1221 for lastprivate/linear IV, push gimplify context around gimplify_assign
1222 and, if it needed any temporaries, pop it into a gimple bind around the
1223 sequence.
1224
1225 PR target/89073
1226 * doc/invoke.texi (-mclwb, -mprfchw, -mrdpid, -mrdseed, -msgx,
1227 -madx, -mhle, -mavx5124fmaps, -mavx512vnni, -mavx5124vnniw): Document
1228 x86 ISA options.
1229 (bmi2): Add missing @opindex.
1230 * doc/extend.texi (x86 target attribute): Move fma4, lwp, ssse3
1231 options alphabetically. Add missing 3dnow, 3dnowa, adx, avx, avx2,
1232 avx5124fmaps, avx5124vnniw, avx512bitalg, avx512bw, avx512cd,
1233 avx512dq, avx512er, avx512f, avx512ifma, avx512pf, avx512vbmi,
1234 avx512vbmi2, avx512vl, avx512vnni, avx512vpopcntdq, bmi, bmi2,
1235 clflushopt, clwb, clzero, crc32, cx16, f16c, fma, fsgsbase,
1236 fxsr, gfni, hle, lzcnt, movbe, movdir64b, movdiri, mwaitx, pconfig,
1237 pku, prefetchwt1, prfchw, rdpid, rdrnd, rdseed, rtm, sahf,
1238 sgx, sha, shstk, tbm, vaes, vpclmulqdq, wbnoinvd, xsave,
1239 xsavec, xsaveopt and xsaves options.
1240
1241 2019-01-27 Jakub Jelinek <jakub@redhat.com>
1242
1243 PR target/87214
1244 * config/i386/sse.md
1245 (<mask_codefor>avx512dq_shuf_<shuffletype>64x2_1<mask_name>,
1246 avx512f_shuf_<shuffletype>64x2_1<mask_name>): Ensure the
1247 first constants in pairs are multiples of 2. Formatting fixes.
1248 (avx512vl_shuf_<shuffletype>32x4_1<mask_name>,
1249 avx512vl_shuf_<shuffletype>32x4_1<mask_name>): Ensure the
1250 first constants in each quadruple are multiples of 4. Formatting fixes.
1251
1252 2019-01-24 Jakub Jelinek <jakub@redhat.com>
1253
1254 PR tree-optimization/88964
1255 * gimple-loop-interchange.cc (loop_cand::analyze_induction_var): Also
1256 punt if HONOR_SNANS (chrec).
1257
1258 2019-01-23 Jakub Jelinek <jakub@redhat.com>
1259
1260 PR tree-optimization/88964
1261 * gimple-loop-interchange.cc (loop_cand::analyze_induction_var): Use
1262 build_zero_cst instead of build_int_cst. Return false for loop
1263 invariants which honor signed zeros.
1264
1265 2019-01-22 Jakub Jelinek <jakub@redhat.com>
1266
1267 PR target/88965
1268 * config/rs6000/rs6000.c: Include tree-vrp.h and tree-ssanames.h.
1269 (rs6000_gimple_fold_builtin): If MEM_REF address doesn't satisfy
1270 is_gimple_mem_ref_addr predicate, force it into a SSA_NAME first.
1271
1272 PR middle-end/88968
1273 * gimplify.c (gimplify_omp_atomic): Handle bitfield atomics with
1274 non-integral DECL_BIT_FIELD_REPRESENTATIVEs.
1275
1276 PR target/88905
1277 * optabs.c (add_equal_note): Add op0_mode argument, use it instead of
1278 GET_MODE (op0).
1279 (expand_binop_directly, expand_doubleword_clz,
1280 expand_doubleword_popcount, expand_ctz, expand_ffs,
1281 expand_unop_direct, maybe_emit_unop_insn): Adjust callers.
1282
1283 PR rtl-optimization/49429
1284 PR target/49454
1285 PR rtl-optimization/86334
1286 PR target/88906
1287 * expr.c (emit_block_move_hints): Move marking of MEM_EXPRs
1288 addressable from here...
1289 (emit_block_op_via_libcall): ... to here.
1290
1291 2019-01-17 Jakub Jelinek <jakub@redhat.com>
1292
1293 PR target/88734
1294 * config/aarch64/arm_neon.h: Fix #pragma GCC target syntax - replace
1295 (("..."))) with ("..."). Use arch=armv8.2-a+sha3 instead of
1296 arch=armv8.2-a+crypto for vsha512hq_u64 etc. intrinsics.
1297
1298 PR rtl-optimization/88870
1299 * dce.c (deletable_insn_p): Never delete const/pure calls that can
1300 throw if we can't alter the cfg or delete dead exceptions.
1301 (mark_insn): Don't call find_call_stack_args for such calls.
1302
1303 2019-01-11 Jakub Jelinek <jakub@redhat.com>
1304
1305 PR bootstrap/88714
1306 * passes.c (finish_optimization_passes): Call print_combine_total_stats
1307 inside of pass_combine_1 dump rather than pass_profile_1.
1308
1309 2019-01-10 Jakub Jelinek <jakub@redhat.com>
1310
1311 PR c/88568
1312 * attribs.c (handle_dll_attribute): Clear TREE_STATIC after setting
1313 DECL_EXTERNAL.
1314
1315 2019-01-07 Jakub Jelinek <jakub@redhat.com>
1316
1317 PR debug/88723
1318 * dwarf2out.c (const_ok_for_output_1): Remove redundant call to
1319 const_not_ok_for_debug_p target hook.
1320 (mem_loc_descriptor) <case UNSPEC>: Only call const_ok_for_output_1
1321 on UNSPEC and subexpressions thereof if all subexpressions of the
1322 UNSPEC are CONSTANT_P.
1323
1324 2019-01-05 Jakub Jelinek <jakub@redhat.com>
1325
1326 PR debug/88635
1327 * dwarf2out.c (const_ok_for_output_1): Reject MINUS that contains
1328 SYMBOL_REF, CODE_LABEL or UNSPEC in subexpressions of second argument.
1329 Reject PLUS that contains SYMBOL_REF, CODE_LABEL or UNSPEC in
1330 subexpressions of both operands.
1331 (mem_loc_descriptor): Handle UNSPEC if target hook acks it and all the
1332 subrtxes are CONSTANT_P.
1333
1334 2019-02-07 Richard Biener <rguenther@suse.de>
1335
1336 Backport from mainline
1337 2018-11-20 Richard Biener <rguenther@suse.de>
1338
1339 PR tree-optimization/88105
1340 * tree-ssa-dom.c (pass_dominator::execute): Do not walk
1341 backedges.
1342
1343 2018-11-28 Richard Biener <rguenther@suse.de>
1344
1345 PR tree-optimization/88223
1346 * tree-ssa-sccvn.c (vn_reference_lookup_3): When skipping
1347 over a stored-same value may-alias store make sure to consider
1348 partial overlaps which are valid when TBAA reasonings do not
1349 apply and byte-granular overlaps are possible at all.
1350
1351 2019-02-07 Richard Biener <rguenther@suse.de>
1352
1353 Backport from mainline
1354 2018-12-11 Richard Biener <rguenther@suse.de>
1355
1356 PR middle-end/88448
1357 PR middle-end/88415
1358 * tree-complex.c (update_complex_assignment): Properly transfer
1359 or clean EH info around gimple_assign_set_rhs_with_ops.
1360
1361 2018-11-15 Richard Biener <rguenther@suse.de>
1362
1363 PR tree-optimization/88030
1364 * tree-complex.c (need_eh_cleanup): New global.
1365 (update_complex_assignment): Mark blocks that need EH update.
1366 (expand_complex_comparison): Likewise.
1367 (tree_lower_complex): Allocate and deallocate need_eh_cleanup,
1368 perform EH cleanup and schedule CFG cleanup if that did anything.
1369
1370 2018-11-08 Richard Biener <rguenther@suse.de>
1371
1372 PR tree-optimization/87929
1373 * tree-complex.c (expand_complex_comparison): Clean EH.
1374
1375 2019-02-06 Eric Botcazou <ebotcazou@adacore.com>
1376
1377 * config/i386/i386.c (ix86_expand_prologue): Emit a memory blockage
1378 after restoring registers saved to allocate the frame on Windows.
1379
1380 2019-02-06 Richard Biener <rguenther@suse.de>
1381
1382 Backport from mainline
1383 2019-01-31 Richard Biener <rguenther@suse.de>
1384
1385 PR tree-optimization/89135
1386 * tree-ssa-phiprop.c (pass_phiprop::execute): Skip blocks
1387 with abnormal preds.
1388
1389 2019-01-18 Richard Biener <rguenther@suse.de>
1390
1391 PR tree-optimization/88903
1392 * tree-vect-stmts.c (vectorizable_shift): Verify we see all
1393 scalar stmts a SLP shift amount is composed of when detecting
1394 shifts by scalars.
1395
1396 2019-02-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
1397
1398 Backport from mainline.
1399 2019-01-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
1400 * config/rs6000/rs6000-c.c (altivec-resolve_overloaded_builtin):
1401 Change handling of ALTIVEC_BUILTIN_VEC_EXTRACT. Coerce result to
1402 type of vector element when vec_extract is implemented by direct
1403 move.
1404
1405 2019-02-05 Andreas Krebbel <krebbel@linux.ibm.com>
1406
1407 Backport from mainline
1408 2019-02-05 Andreas Krebbel <krebbel@linux.ibm.com>
1409
1410 PR target/88856
1411 * config/s390/s390.md: Remove load and test FP splitter.
1412
1413 2019-02-04 Bill Schmidt <wshmidt@linux.ibm.com>
1414
1415 PR target/87064
1416 Backport from mainline
1417
1418 2019-01-30 Bill Schmidt <wschmidt@linux.ibm.com>
1419
1420 PR target/87064
1421 * config/rs6000/vsx.md (*vsx_reduc_<VEC_reduc_name>_v4sf_scalar):
1422 Disable for little-endian.
1423
1424 2019-01-22 Jakub Jelinek <jakub@redhat.com>
1425
1426 PR target/87064
1427 * config/rs6000/vsx.md (*vsx_reduc_<VEC_reduc_name>_v2df_scalar):
1428 Disable for little endian.
1429
1430 2019-02-04 Eric Botcazou <ebotcazou@adacore.com>
1431
1432 * config/sparc/sparc.h: Remove superfluous blank lines.
1433 * config/sparc/sparc.c (global_offset_table_rtx): Rename into...
1434 (got_register_rtx): ...this.
1435 (sparc_got): Adjust to above renaming.
1436 (sparc_tls_got): Likewise.
1437 (sparc_output_mi_thunk): Likewise.
1438 (sparc_init_pic_reg): Likewise.
1439 (save_local_or_in_reg_p): Fix test on the GOT register.
1440 (USE_HIDDEN_LINKONCE): Move around.
1441 (get_pc_thunk_name): Likewise.
1442 (gen_load_pcrel_sym): Likewise.
1443 (load_got_register): Likewise.
1444
1445 2019-02-01 Bin Cheng <bin.cheng@linux.alibaba.com>
1446
1447 Backport from mainline
1448 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
1449
1450 PR tree-optimization/87022
1451 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
1452 bits in dist vector rather than the first one.
1453
1454 2019-02-01 Bin Cheng <bin.cheng@linux.alibaba.com>
1455
1456 Backport from mainline
1457 2019-02-01 Bin Cheng <bin.cheng@linux.alibaba.com>
1458
1459 PR tree-optimization/88932
1460 * tree-predcom.c (try_combine_chains): Get loop bbs in dom order.
1461
1462 2018-01-31 Bill Schmidt <wschmidt@linux.ibm.com>
1463
1464 Backport from mainline
1465 2018-01-31 Bill Schmidt <wschmidt@linux.ibm.com>
1466
1467 PR tree-optimization/89008
1468 * gimple-ssa-strength-reduction.c (slsr_process_mul): Don't
1469 process anything of the form X * 0.
1470
1471 2019-01-31 Richard Biener <rguenther@suse.de>
1472
1473 Backport from mainline
1474 2019-01-31 Richard Biener <rguenther@suse.de>
1475
1476 PR rtl-optimization/89115
1477 * lra.c (lra_rtx_hash): Properly hash CONST_INT values.
1478
1479 2019-01-30 Richard Biener <rguenther@suse.de>
1480
1481 PR rtl-optimization/89115
1482 * opts.c (default_options_optimization): Reduce
1483 PARAM_MAX_DSE_ACTIVE_LOCAL_STORES by a factor of 10 at -O1.
1484 Make PARAM_LOOP_INVARIANT_MAX_BBS_IN_LOOP reduction relative
1485 to the default.
1486
1487 2019-01-30 Kewen Lin <linkw@gcc.gnu.org>
1488
1489 Backport from mainline.
1490 2019-01-17 Kewen Lin <linkw@gcc.gnu.org>
1491
1492 * doc/extend.texi: Add four new prototypes for vec_ld and seven new
1493 prototypes for vec_st.
1494 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add entries
1495 for scalar address type variants of altivec_vec_ld/altivec_vec_st,
1496 mainly on signed/unsigned long long and double.
1497
1498 2019-01-29 Vineet Gupta <vgupta@synopsys.com>
1499
1500 Backport from mainline.
1501 * gcc/config.gcc: Force .init_array for ARC.
1502
1503 2019-01-29 Vineet Gupta <vgupta@synopsys.com>
1504
1505 Backport from mainline.
1506 * config/arc/atomic.md: Add operand to DMB instruction.
1507
1508 2019-01-27 Uroš Bizjak <ubizjak@gmail.com>
1509
1510 PR target/88948
1511 * rtl.h (prepare_copy_insn): New prototype.
1512 * gcse.c (prepare_copy_insn): New function, split out from
1513 process_insert_insn.
1514 (process_insert_insn): Use prepare_copy_insn.
1515 * store-motion.c (replace_store_insn): Use prepare_copy_insn
1516 instead of gen_move_insn.
1517
1518 2019-01-25 Richard Biener <rguenther@suse.de>
1519
1520 PR tree-optimization/86865
1521 * graphite-scop-detection.c (scop_detection::can_represent_loop):
1522 Reject non-do-while loops.
1523
1524 2019-01-24 Uroš Bizjak <ubizjak@gmail.com>
1525
1526 PR target/88998
1527 * config/i386/sse.md (sse2_cvtpi2pd): Add SSE alternatives.
1528 Disparage MMX alternative.
1529 (sse2_cvtpd2pi): Ditto.
1530 (sse2_cvttpd2pi): Ditto.
1531
1532 2019-01-24 Richard Earnshaw <rearnsha@arm.com>
1533
1534 PR target/88469
1535 * profile-count.h (profile_count): On ARM systems using GCC 6/7/8
1536 force the alignment of m_val.
1537
1538 2019-01-24 Richard Biener <rguenther@suse.de>
1539
1540 Backport from mainline
1541 2019-01-23 Richard Biener <rguenther@suse.de>
1542
1543 PR tree-optimization/89008
1544 * tree-ssa-reassoc.c (eliminate_using_constants): For * 0 do
1545 not leave another stray operand.
1546
1547 2019-01-22 Uroš Bizjak <ubizjak@gmail.com>
1548
1549 PR target/88938
1550 * config/i386/i386.c (ix86_expand_builtin) [case IX86_BUILTIN_BEXTRI32,
1551 case IX86_BUILTIN_BEXTRI64]: Sanitize operands.
1552
1553 2019-01-18 Richard Earnshaw <rearnsha@arm.com>
1554
1555 PR target/88799
1556 * config/arm/arm-cpus.in (mp): New feature.
1557 (sec): New feature.
1558 (fgroup ARMv7ve): Add mp and sec features.
1559 (arch armv7-a): Add options to allow mp and sec extensions.
1560 (cpu generic-armv7-a): Add options to allow mp and sec extensions.
1561 (cpu cortex-a5, cpu cortex-7, cpu cortex-a9): Add mp and sec
1562 extenstions to the base architecture.
1563 (cpu cortex-a8): Add sec extension to the base architecture.
1564 (cpu marvell-pj4): Add mp and sec extensions to the base architecture.
1565 * config/arm/t-aprofile (MULTILIB_MATCHES): Map all armv7-a arch
1566 variants down to the base v7-a varaint.
1567 * config/arm/t-multilib (v7_a_arch_variants): New variable.
1568 * doc/invoke.texi (ARM Options): Add +mp and +sec to the list
1569 of permitted extensions for -march=armv7-a and for
1570 -mcpu=generic-armv7-a.
1571
1572 2019-01-17 Uroš Bizjak <ubizjak@gmail.com>
1573
1574 * config/alpha/alpha.c (alpha_gimplify_va_arg):
1575 Handle split indirect COMPLEX_TYPE arguments.
1576
1577 2019-01-17 Eric Botcazou <ebotcazou@adacore.com>
1578
1579 * gimple-ssa-isolate-paths.c (stmt_uses_name_in_undefined_way): Replace
1580 flag_non_call_exceptions with cfun->can_throw_non_call_exceptions.
1581 (stmt_uses_0_or_null_in_undefined_way): Likewise.
1582 * tree-ssa-alias.c (same_addr_size_stores_p): Likewise.
1583
1584 2019-01-16 Aaron Sawdey <acsawdey@linux.ibm.com>
1585
1586 Backported from mainline
1587 2019-01-03 Aaron Sawdey <acsawdey@linux.ibm.com>
1588 * config/rs6000/rs6000-string.c (expand_block_move): Don't use
1589 unaligned vsx and avoid lxvd2x/stxvd2x.
1590 (gen_lvx_v4si_move): New function.
1591
1592 2019-01-16 Martin Jambor <mjambor@suse.cz>
1593
1594 Backported from mainline
1595 2018-12-10 Martin Jambor <mjambor@suse.cz>
1596
1597 PR ipa/88214
1598 * ipa-prop.c (determine_locally_known_aggregate_parts): Make sure
1599 we check pointers against pointers.
1600
1601 2019-01-10 Jan Hubicka <hubicka@ucw.cz>
1602
1603 Backported from mainline
1604 2018-12-27 Jan Hubicka <hubicka@ucw.cz>
1605
1606 * ipa-devirt.c (polymorphic_call_target_d): Add n_odr_types.
1607 (polymorphic_call_target_hasher::hash): Hash it.
1608 (polymorphic_call_target_hasher::equal): Compare it.
1609 (possible_polymorphic_call_targets): Set it.
1610 * tree.c (free_lang_data): Rebuild type inheritance graph even on
1611 non-LTO path.
1612
1613 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1614
1615 Backported from mainline
1616 2019-01-02 Richard Biener <rguenther@suse.de>
1617
1618 PR ipa/85574
1619 * ipa-icf.h (sem_item_optimizer::sort_congruence_split): Declare.
1620 * ipa-icf.c (sem_item_optimizer::sort_congruence_split): New
1621 function.
1622 (sem_item_optimizer::do_congruence_step_f): Sort the congruence
1623 set after UIDs before splitting them.
1624
1625 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1626
1627 Backported from mainline
1628 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1629
1630 PR tree-optimization/85574
1631 * tree-ssa-uncprop.c (struct equiv_hash_elt): Remove unused
1632 structure.
1633 (struct ssa_equip_hash_traits): Declare.
1634 (val_ssa_equiv): Use custom hash traits using operand_equal_p.
1635
1636 2019-01-09 Eric Botcazou <ebotcazou@adacore.com>
1637
1638 * config/sparc/sparc.md (*tablejump_sp32): Merge into...
1639 (*tablejump_sp64): Likewise.
1640 (*tablejump<P:mode>): ...this.
1641 (*call_address_sp32): Merge into...
1642 (*call_address_sp64): Likewise.
1643 (*call_address<P:mode>): ...this.
1644 (*call_symbolic_sp32): Merge into...
1645 (*call_symbolic_sp64): Likewise.
1646 (*call_symbolic<P:mode>): ...this.
1647 (call_value): Remove constraint and add predicate.
1648 (*call_value_address_sp32): Merge into...
1649 (*call_value_address_sp64): Likewise.
1650 (*call_value_address<P:mode>): ...this.
1651 (*call_value_symbolic_sp32): Merge into...
1652 (*call_value_symbolic_sp64): Likewise.
1653 (*call_value_symbolic<P:mode>): ...this.
1654 (*sibcall_symbolic_sp32): Merge into...
1655 (*sibcall_symbolic_sp64): Likewise.
1656 (*sibcall_symbolic<P:mode>): ...this.
1657 (sibcall_value): Remove constraint and add predicate.
1658 (*sibcall_value_symbolic_sp32): Merge into...
1659 (*sibcall_value_symbolic_sp64): Likewise.
1660 (*sibcall_value_symbolic<P:mode>): ...this.
1661 (window_save): Minor tweak.
1662 (*branch_sp32): Merge into...
1663 (*branch_sp64): Likewise.
1664 (*branch<P:mode>): ...this.
1665
1666 2019-01-09 Eric Botcazou <ebotcazou@adacore.com>
1667 James Clarke <jrtc27@jrtc27.com>
1668
1669 PR target/84010
1670 * config/sparc/sparc.c (sparc_legitimize_tls_address): Only use Pmode
1671 consistently in TLS address generation and adjust code to the renaming
1672 of patterns. Mark calls to __tls_get_addr as const.
1673 * config/sparc/sparc.md (tgd_hi22): Turn into...
1674 (tgd_hi22<P:mode>): ...this and use Pmode throughout.
1675 (tgd_lo10): Turn into...
1676 (tgd_lo10<P:mode>): ...this and use Pmode throughout.
1677 (tgd_add32): Merge into...
1678 (tgd_add64): Likewise.
1679 (tgd_add<P:mode>): ...this and use Pmode throughout.
1680 (tldm_hi22): Turn into...
1681 (tldm_hi22<P:mode>): ...this and use Pmode throughout.
1682 (tldm_lo10): Turn into...
1683 (tldm_lo10<P:mode>): ...this and use Pmode throughout.
1684 (tldm_add32): Merge into...
1685 (tldm_add64): Likewise.
1686 (tldm_add<P:mode>): ...this and use Pmode throughout.
1687 (tldm_call32): Merge into...
1688 (tldm_call64): Likewise.
1689 (tldm_call<P:mode>): ...this and use Pmode throughout.
1690 (tldo_hix22): Turn into...
1691 (tldo_hix22<P:mode>): ...this and use Pmode throughout.
1692 (tldo_lox10): Turn into...
1693 (tldo_lox10<P:mode>): ...this and use Pmode throughout.
1694 (tldo_add32): Merge into...
1695 (tldo_add64): Likewise.
1696 (tldo_add<P:mode>): ...this and use Pmode throughout.
1697 (tie_hi22): Turn into...
1698 (tie_hi22<P:mode>): ...this and use Pmode throughout.
1699 (tie_lo10): Turn into...
1700 (tie_lo10<P:mode>): ...this and use Pmode throughout.
1701 (tie_ld64): Use DImode throughout.
1702 (tie_add32): Merge into...
1703 (tie_add64): Likewise.
1704 (tie_add<P:mode>): ...this and use Pmode throughout.
1705 (tle_hix22_sp32): Merge into...
1706 (tle_hix22_sp64): Likewise.
1707 (tle_hix22<P:mode>): ...this and use Pmode throughout.
1708 (tle_lox22_sp32): Merge into...
1709 (tle_lox22_sp64): Likewise.
1710 (tle_lox22<P:mode>): ...this and use Pmode throughout.
1711 (*tldo_ldub_sp32): Merge into...
1712 (*tldo_ldub_sp64): Likewise.
1713 (*tldo_ldub<P:mode>): ...this and use Pmode throughout.
1714 (*tldo_ldub1_sp32): Merge into...
1715 (*tldo_ldub1_sp64): Likewise.
1716 (*tldo_ldub1<P:mode>): ...this and use Pmode throughout.
1717 (*tldo_ldub2_sp32): Merge into...
1718 (*tldo_ldub2_sp64): Likewise.
1719 (*tldo_ldub2<P:mode>): ...this and use Pmode throughout.
1720 (*tldo_ldsb1_sp32): Merge into...
1721 (*tldo_ldsb1_sp64): Likewise.
1722 (*tldo_ldsb1<P:mode>): ...this and use Pmode throughout.
1723 (*tldo_ldsb2_sp32): Merge into...
1724 (*tldo_ldsb2_sp64): Likewise.
1725 (*tldo_ldsb2<P:mode>): ...this and use Pmode throughout.
1726 (*tldo_ldub3_sp64): Use DImode throughout.
1727 (*tldo_ldsb3_sp64): Likewise.
1728 (*tldo_lduh_sp32): Merge into...
1729 (*tldo_lduh_sp64): Likewise.
1730 (*tldo_lduh<P:mode>): ...this and use Pmode throughout.
1731 (*tldo_lduh1_sp32): Merge into...
1732 (*tldo_lduh1_sp64): Likewise.
1733 (*tldo_lduh1<P:mode>): ...this and use Pmode throughout.
1734 (*tldo_ldsh1_sp32): Merge into...
1735 (*tldo_ldsh1_sp64): Likewise.
1736 (*tldo_ldsh1<P:mode>): ...this and use Pmode throughout.
1737 (*tldo_lduh2_sp64): Use DImode throughout.
1738 (*tldo_ldsh2_sp64): Likewise.
1739 (*tldo_lduw_sp32): Merge into...
1740 (*tldo_lduw_sp64): Likewise.
1741 (*tldo_lduw<P:mode>): ...this and use Pmode throughout.
1742 (*tldo_lduw1_sp64): Use DImode throughout.
1743 (*tldo_ldsw1_sp64): Likewise.
1744 (*tldo_ldx_sp64): Likewise.
1745 (*tldo_stb_sp32): Merge into...
1746 (*tldo_stb_sp64): Likewise.
1747 (*tldo_stb<P:mode>): ...this and use Pmode throughout.
1748 (*tldo_sth_sp32): Merge into...
1749 (*tldo_sth_sp64): Likewise.
1750 (*tldo_sth<P:mode>): ...this and use Pmode throughout.
1751 (*tldo_stw_sp32): Merge into...
1752 (*tldo_stw_sp64): Likewise.
1753 (*tldo_stw<P:mode>): ...this and use Pmode throughout.
1754 (*tldo_stx_sp64): Use DImode throughout.
1755
1756 2019-01-09 Eric Botcazou <ebotcazou@adacore.com>
1757
1758 * doc/invoke.texi (-Os): Add reference to -finline-functions.
1759 (-finline-functions): Remove reference to -O2, add references
1760 to -fprofile-use and -fauto-profile.
1761
1762 2019-01-08 Jakub Jelinek <jakub@redhat.com>
1763
1764 Backported from mainline
1765 2019-01-05 Jakub Jelinek <jakub@redhat.com>
1766
1767 PR middle-end/82564
1768 PR target/88620
1769 * expr.c (expand_assignment): For calls returning VLA structures
1770 if to_rtx is not a MEM, force it into a stack temporary.
1771
1772 2019-01-04 Jakub Jelinek <jakub@redhat.com>
1773
1774 PR target/88594
1775 * config/i386/i386.c (ix86_expand_divmod_libfunc): Use mode instead
1776 of GET_MODE (opN) as modes of the libcall arguments.
1777
1778 2019-01-03 Jakub Jelinek <jakub@redhat.com>
1779
1780 PR debug/88644
1781 * dwarf2out.c (modified_type_die): If type is equal to sizetype,
1782 change it to qualified_type.
1783
1784 2018-12-21 Jakub Jelinek <jakub@redhat.com>
1785
1786 PR middle-end/85594
1787 PR middle-end/88553
1788 * omp-expand.c (extract_omp_for_update_vars): Regimplify the condition
1789 if needed.
1790 (expand_omp_for_generic): Don't clobber t temporary for ordered loops.
1791
1792 PR target/88522
1793 * config/i386/sse.md (*avx512pf_gatherpf<mode>sf_mask,
1794 *avx512pf_gatherpf<mode>df_mask, *avx512pf_scatterpf<mode>sf_mask,
1795 *avx512pf_scatterpf<mode>df_mask): Use %X5 instead of %5 for
1796 -masm=intel.
1797 (gatherq_mode): Remove mode iterator.
1798 (*avx512f_gathersi<mode>, *avx512f_gathersi<mode>_2): Use X instead
1799 of <xtg_mode>.
1800 (*avx512f_gatherdi<mode>): Use X instead of <gatherq_mode>.
1801 (*avx512f_gatherdi<mode>_2, *avx512f_scattersi<mode>,
1802 *avx512f_scatterdi<mode>): Use %X5 for -masm=intel.
1803
1804 PR rtl-optimization/88563
1805 * expr.c (expand_expr_real_2) <case WIDEN_MULT_EXPR>: Swap innermode
1806 and mode arguments to convert_modes. Likewise swap mode and word_mode
1807 arguments. Handle both arguments with VOIDmode before convert_modes
1808 of one of them. Formatting fixes.
1809
1810 2018-12-19 Jakub Jelinek <jakub@redhat.com>
1811
1812 PR target/88541
1813 * config/i386/vpclmulqdqintrin.h (_mm256_clmulepi64_epi128): Enable
1814 for -mavx -mvpclmulqdq rather than just for -mavx512vl -mvpclmulqdq.
1815
1816 2018-12-14 Jakub Jelinek <jakub@redhat.com>
1817
1818 PR c++/82294
1819 PR c++/87436
1820 * expr.h (categorize_ctor_elements): Add p_unique_nz_elts argument.
1821 * expr.c (categorize_ctor_elements_1): Likewise. Compute it like
1822 p_nz_elts, except don't multiply it by mult. Adjust recursive call.
1823 Fix up COMPLEX_CST handling.
1824 (categorize_ctor_elements): Add p_unique_nz_elts argument, initialize
1825 it and pass it through to categorize_ctor_elements_1.
1826 (mostly_zeros_p, all_zeros_p): Adjust categorize_ctor_elements callers.
1827 * gimplify.c (gimplify_init_constructor): Likewise. Don't force
1828 ctor into readonly data section if num_unique_nonzero_elements is
1829 smaller or equal to 1/8 of num_nonzero_elements and size is >= 64
1830 bytes.
1831
1832 2018-12-13 Jakub Jelinek <jakub@redhat.com>
1833
1834 PR rtl-optimization/88470
1835 * cfgcleanup.c (outgoing_edges_match): If the function is
1836 shrink-wrapped and bb1 ends with a JUMP_INSN with a single fake
1837 edge to EXIT, return false.
1838
1839 PR rtl-optimization/88416
1840 * valtrack.c (cleanup_auto_inc_dec): Handle pre/post-inc/dec/modify
1841 even if !AUTO_INC_DEC.
1842
1843 2018-12-07 Jakub Jelinek <jakub@redhat.com>
1844
1845 PR target/85593
1846 * final.c (rest_of_handle_final): Don't call collect_fn_hard_reg_usage
1847 for functions with naked attribute.
1848
1849 2018-12-06 Jakub Jelinek <jakub@redhat.com>
1850
1851 PR target/87598
1852 * config/aarch64/aarch64.c (aarch64_print_address_internal): Don't
1853 call output_operand_lossage on VOIDmode CONST_INTs. After
1854 output_operand_lossage do return false.
1855
1856 2018-12-05 Jakub Jelinek <jakub@redhat.com>
1857
1858 PR tree-optimization/87360
1859 * gimple-loop-jam.c (tree_loop_unroll_and_jam): On failure to analyze
1860 data dependencies, don't return false, just continue.
1861
1862 2018-11-29 Jakub Jelinek <jakub@redhat.com>
1863
1864 PR target/88234
1865 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): For
1866 vec_add and vec_sub builtins, perform PLUS_EXPR or MINUS_EXPR
1867 in unsigned_type_for instead of vector integral type where overflow
1868 doesn't wrap.
1869
1870 2018-11-26 Jakub Jelinek <jakub@redhat.com>
1871
1872 PR c++/86900
1873 * dwarf2out.c (secname_for_decl): For functions with
1874 DECL_SECTION_NAME if in_cold_section_p, try to return
1875 current_function_section's name if it is a named section.
1876
1877 2018-11-22 Jakub Jelinek <jakub@redhat.com>
1878
1879 PR target/85644
1880 PR target/86832
1881 * config/i386/i386.c (ix86_option_override_internal): Default
1882 ix86_stack_protector_guard to SSP_TLS only if TARGET_THREAD_SSP_OFFSET
1883 is defined.
1884 * config/i386/i386.md (stack_protect_set, stack_protect_set_<mode>,
1885 stack_protect_test, stack_protect_test_<mode>): Use empty condition
1886 instead of TARGET_SSP_TLS_GUARD.
1887
1888 2018-11-20 Jakub Jelinek <jakub@redhat.com>
1889
1890 PR tree-optimization/87895
1891 * omp-simd-clone.c (ipa_simd_modify_function_body): When removing
1892 or replacing GIMPLE_RETURN, set EDGE_FALLTHRU on the edge to EXIT.
1893 (simd_clone_adjust): Don't set EDGE_FALLTHRU here. In a loop that
1894 redirects edges to EXIT to edges to incr_bb, iterate while EXIT
1895 has any preds and always use EDGE_PRED (, 0).
1896
1897 2018-11-19 Jakub Jelinek <jakub@redhat.com>
1898
1899 PR tree-optimization/88071
1900 * tree-vect-loop.c (vectorize_fold_left_reduction): Pass true instead
1901 of false as last argument to gsi_remove.
1902 * tree-vect-stmts.c (vect_finish_replace_stmt): Pass true instead of
1903 false as last argument to gsi_replace.
1904
1905 PR debug/87039
1906 * omp-expand.c: Don't include debug.h.
1907 (adjust_context_and_scope): Add REGION argument. Find DECL_CONTEXT
1908 from innermost outer parallel, task, or target that has a
1909 child_fn set, or, if there is no such outer region, use
1910 current_function_decl. Do the DECL_CONTEXT adjustment regardless of
1911 whether a suitable BLOCK is found or not.
1912 (expand_parallel_call): Don't call adjust_context_and_scope here.
1913 (grid_expand_target_grid_body): Revert 2017-01-25 changes.
1914 (expand_omp_taskreg, expand_omp_target): Likewise. Call
1915 adjust_context_and_scope.
1916 * dwarf2out.c (dwarf2out_early_global_decl): For
1917 decl_function_context recurse instead of calling dwarf2out_decl.
1918
1919 2018-11-16 Jakub Jelinek <jakub@redhat.com>
1920
1921 PR rtl-optimization/87475
1922 * cfgrtl.c (patch_jump_insn): Allow redirection failure for
1923 CROSSING_JUMP_P insns.
1924 (cfg_layout_redirect_edge_and_branch): Don't ICE if ret is NULL.
1925
1926 2018-11-15 Jakub Jelinek <jakub@redhat.com>
1927
1928 PR rtl-optimization/88018
1929 * cfgrtl.c (fixup_abnormal_edges): Guard moving insns to fallthru edge
1930 on the presence of fallthru edge, rather than if it is a USE or not.
1931
1932 2018-11-13 Jakub Jelinek <jakub@redhat.com>
1933
1934 PR tree-optimization/87898
1935 * omp-simd-clone.c (ipa_simd_modify_function_body): Remove debug stmts
1936 where the first argument was changed into a non-decl.
1937
1938 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1939
1940 Backport from mainline
1941 2019-01-02 Jan Hubicka <hubicka@ucw.cz>
1942
1943 PR lto/88130
1944 * varpool.c (varpool_node::ctor_useable_for_folding_p): Also return
1945 false at WPA time when body was removed.
1946
1947 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1948
1949 Backport from mainline
1950 2018-08-29 Jan Hubicka <jh@suse.cz>
1951
1952 PR lto/86517
1953 PR lto/88185
1954 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
1955 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
1956
1957 2019-01-04 Aaron Sawdey <acsawdey@linux.ibm.com>
1958
1959 Backport from mainline
1960 2018-11-28 Aaron Sawdey <acsawdey@linux.ibm.com>
1961
1962 * config/rs6000/rs6000-string.c (expand_block_clear): Change how
1963 we determine if unaligned vsx is ok.
1964
1965 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1966
1967 Backport from mainline
1968 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1969
1970 * ipa-utils.c (scale_ipa_profile_for_fn): Break out from ...
1971 (ipa_merge_profiles): ... here; do not ICE on thunks and aliases.
1972
1973 2019-01-03 Martin Liska <mliska@suse.cz>
1974
1975 Backport from mainline
1976 2019-01-01 Jan Hubicka <hubicka@ucw.cz>
1977
1978 * coverage.c (get_coverage_counts): Use current_function_decl.
1979 * profile.c (read_thunk_profile): New function.
1980 (branch_prob): Add THUNK parameter.
1981 * tree-profile.c (tree_profiling): Handle thunks.
1982 * value-prof.c (init_node_map): Handle thunks.
1983 * value-prof.h (branch_prob): Upate prototype.
1984 (read_thunk_profile): Declare.
1985
1986 2019-01-03 Iain Sandoe <iain@sandoe.co.uk>
1987
1988 revert:
1989 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
1990
1991 backport from mainline.
1992 2018-12-12 Segher Boessenkool <segher@kernel.crashing.org>
1993 Iain Sandoe <iain@sandoe.co.uk>
1994
1995 PR target/88343
1996 * config/rs6000/rs6000.c (save_reg_p): Do not save the picbase reg
1997 unless it has been used.
1998 (first_reg_to_save): Remove dead code.
1999
2000 2019-01-02 Segher Boessenkool <segher@kernel.crashing.org>
2001
2002 Backport from trunk
2003 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
2004
2005 PR inline-asm/55681
2006 * doc/extend.texi (Basic Asm): Update grammar.
2007 (Extended Asm): Update grammar.
2008
2009 Backport from trunk
2010 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
2011
2012 * doc/extend.texi (Using Assembly Language with C): Document asm inline.
2013 (Size of an asm): Fix typo. Document asm inline.
2014 * gimple-pretty-print.c (dump_gimple_asm): Handle asm inline.
2015 * gimple.h (enum gf_mask): Add GF_ASM_INLINE.
2016 (gimple_asm_set_volatile): Fix typo.
2017 (gimple_asm_inline_p): New.
2018 (gimple_asm_set_inline): New.
2019 * gimplify.c (gimplify_asm_expr): Propagate the asm inline flag from
2020 tree to gimple.
2021 * ipa-icf-gimple.c (func_checker::compare_gimple_asm): Compare the
2022 gimple_asm_inline_p flag, too.
2023 * tree-core.h (tree_base): Document that protected_flag is ASM_INLINE_P
2024 in an ASM_EXPR.
2025 * tree-inline.c (estimate_num_insns): If gimple_asm_inline_p return
2026 a minimum size for an asm.
2027 * tree.h (ASM_INLINE_P): New.
2028
2029 2018-12-28 Thomas Schwinge <thomas@codesourcery.com>
2030 Julian Brown <julian@codesourcery.com>
2031
2032 * gimplify.c (gimplify_scan_omp_clauses): Fix known_eq typo/bug.
2033
2034 2018-12-27 Martin Liska <mliska@suse.cz>
2035
2036 Backport from mainline
2037 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
2038
2039 PR ipa/88561
2040 * ipa-polymorphic-call.c
2041 (ipa_polymorphic_call_context::ipa_polymorphic_call_context): Handle
2042 arguments of thunks correctly.
2043 (ipa_polymorphic_call_context::get_dynamic_context): Be ready for
2044 NULL instance pinter.
2045 * lto-cgraph.c (lto_output_node): Always stream thunk info.
2046
2047 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
2048
2049 backport from mainline.
2050 2018-12-12 Segher Boessenkool <segher@kernel.crashing.org>
2051 Iain Sandoe <iain@sandoe.co.uk>
2052
2053 PR target/88343
2054 * config/rs6000/rs6000.c (save_reg_p): Do not save the picbase reg
2055 unless it has been used.
2056 (first_reg_to_save): Remove dead code.
2057
2058 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
2059
2060 Backport from mainline
2061 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
2062
2063 PR c++/87380
2064 * config/darwin.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC) Remove, use the
2065 default.
2066 * config/rs6000/darwin7.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC): New.
2067
2068 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
2069
2070 Backport from mainline
2071 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
2072
2073 PR target/78444
2074 * config/i386/darwin.h (STACK_BOUNDARY): Remove macro.
2075 * config/i386/i386.c (ix86_compute_frame_layout): Ensure at least 128b
2076 stack alignment in non-leaf functions.
2077
2078 2018-12-21 Uros Bizjak <ubizjak@gmail.com>
2079
2080 Backport from mainline
2081 2018-12-10 Uros Bizjak <ubizjak@gmail.com>
2082
2083 PR target/88418
2084 * config/i386/i386.c (ix86_expand_sse_cmp): For vector modes,
2085 check operand 1 with vector_operand predicate.
2086 (ix86_expand_sse_movcc): For vector modes, check op_true with
2087 vector_operand, not nonimmediate_operand.
2088
2089 2018-12-19 Bill Schmidt <wschmidt@linux.ibm.com>
2090
2091 Backport from mainline
2092 2018-12-18 Bill Schmidt <wschmidt@linux.ibm.com>
2093
2094 * doc/extend.texi (PowerPC Altivec/VSX Built-in Functions):
2095 Describe when a typedef name can be used as the type specifier for
2096 a vector type, and when it cannot.
2097
2098 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
2099
2100 Backport from trunk
2101 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
2102
2103 PR target/88213
2104 * config/rs6000/vsx.md (*vsx_extract_<P:mode>_<VSX_D:mode>_load):
2105 Require TARGET_POWERPC64.
2106
2107 2018-12-17 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
2108
2109 Backport from trunk
2110 2018-12-17 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
2111
2112 PR rtl-optimization/88253
2113 * combine.c (combine_simplify_rtx): Test for side-effects before
2114 substituting by zero.
2115
2116 2018-12-15 Segher Boessenkool <segher@kernel.crashing.org>
2117
2118 Backport from trunk
2119 2018-12-14 Segher Boessenkool <segher@kernel.crashing.org>
2120
2121 PR rtl-optimization/88001
2122 * function.c (match_asm_constraints_1): Don't invalidly share RTL.
2123
2124 2018-12-15 Jan Hubicka <jh@suse.cz>
2125
2126 * ipa.c (cgraph_build_static_cdtor_1): Add OPTIMIZATION and TARGET
2127 parameters.
2128 (cgraph_build_static_cdtor): Update.
2129 (build_cdtor): Use OPTIMIZATION and TARGET of the first real cdtor
2130 callsed.
2131
2132 2018-12-15 Jan Hubicka <jh@suse.cz>
2133
2134 Backport from mainline
2135 2018-11-02 Richard Biener <rguenther@suse.de>
2136
2137 * dwarf2out.c (build_abbrev_table): Guard lookup_external_ref call
2138 with is_type_die.
2139
2140 2018-12-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2141
2142 Backport from mainline
2143 2018-12-13 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2144
2145 * doc/invoke.texi (-msve-vector-bits): Clarify -msve-vector-bits=128
2146 behavior.
2147
2148 2018-12-14 Andre Vieira <andre.simoesdiasvieira@arm.com>
2149
2150 Backport from mainline
2151 PR target/88224
2152 * config/arm/arm-cpus.in (armv7-r): Add FP16conv configurations.
2153 (cortex-r7, cortex-r8): Update fpu and add new configuration.
2154 * doc/invoke.texi (armv7-r): Add two new vfp options.
2155 (nofp.dp): Add cortex-r7 and cortex-r8 to the list of targets that
2156 support this option.
2157
2158 2018-12-13 H.J. Lu <hongjiu.lu@intel.com>
2159
2160 Backport from mainline
2161 2018-11-05 Xuepeng Guo <xuepeng.guo@intel.com>
2162
2163 PR target/87853
2164 * config/i386/emmintrin.h (__v16qs): New to cope with option
2165 -funsigned-char.
2166 (_mm_cmpeq_epi8): Replace __v16qi with __v16qs.
2167 (_mm_cmplt_epi8): Likewise.
2168 (_mm_cmpgt_epi8): Likewise.
2169
2170 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
2171
2172 Backport from mainline
2173 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
2174
2175 * config/s390/s390-builtins.def (s390_vec_double_s64): Map to
2176 s390_vec_double_s64 instead of s390_vcdgb.
2177 (s390_vec_double_u64): Map to s390_vec_double_u64 instead of
2178 s390_vcdlgb.
2179
2180 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
2181
2182 Backport from mainline
2183 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
2184
2185 * config/s390/vx-builtins.md ("vec_ctd_s64", "vec_ctd_u64")
2186 ("vec_ctsl", "vec_ctul"): Replace 0 with VEC_NOINEXACT.
2187 ("vec_double_s64", "vec_double_u64"): Replace 4 with VEC_INEXACT.
2188
2189 2018-12-13 Eric Botcazou <ebotcazou@adacore.com>
2190
2191 Backport from mainline
2192 2018-12-11 Eric Botcazou <ebotcazou@adacore.com>
2193
2194 * config/rs6000/vxworks.h (RS6000_STARTING_FRAME_OFFSET): Define,
2195 accounting for STACK_BOUNDARY 128.
2196 (STACK_DYNAMIC_OFFSET): Likewise.
2197
2198 2018-12-12 Peter Bergner <bergner@linux.ibm.com>
2199
2200 Backport from mainline
2201 2018-12-07 Peter Bergner <bergner@linux.ibm.com>
2202
2203 PR target/87496
2204 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
2205 -mabi=ieeelongdouble and -mabi=ibmlongdouble without -mlong-double-128.
2206 Do not error for -mabi=ibmlongdouble and no ISA 2.06 support.
2207 * doc/invoke.texi: Document -mabi=ibmlongdouble and -mabi=ieeelongdouble
2208 require -mlong-double-128.
2209
2210 2018-12-05 Richard Biener <rguenther@suse.de>
2211
2212 Backport from mainline
2213 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
2214
2215 PR tree-optimization/87288
2216 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
2217 into account when determining PEELING_FOR_NITERS.
2218
2219 2018-12-05 Iain Sandoe <iain@sandoe.co.uk>
2220
2221 Backport from mainline
2222 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
2223
2224 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
2225 emit a diagnostic that it is not supported and reset the option.
2226 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
2227 supported and consume the option. (ASM_FINAL_SPEC): New.
2228
2229 2018-12-04 Iain Sandoe <iain@sandoe.co.uk>
2230
2231 Backport from mainline
2232 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
2233
2234 PR target/81685
2235 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
2236 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
2237 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
2238
2239 2018-11-29 Peter Bergner <bergner@linux.ibm.com>
2240
2241 Backport from mainline
2242 2018-11-29 Peter Bergner <bergner@linux.ibm.com>
2243
2244 PR target/87496
2245 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
2246 -mabi=ieeelongdouble without both -mpopcntd and -mvsx.
2247
2248 2018-11-28 Aaron Sawdey <acsawdey@linux.ibm.com>
2249
2250 Backport from mainline
2251 2018-10-25 Aaron Sawdey <acsawdey@linux.ibm.com>
2252
2253 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Change to
2254 a shorter sequence with fewer branches.
2255 (emit_final_str_compare_gpr): Ditto.
2256
2257 Backport from mainline to allow the above code to go in:
2258 2018-06-14 Aaron Sawdey <acsawdey@linux.ibm.com>
2259
2260 * config/rs6000/rs6000-string.c (do_and3, do_and3_mask,
2261 do_cmpb3, do_rotl3): New functions.
2262
2263 2018-11-28 Richard Biener <rguenther@suse.de>
2264
2265 PR tree-optimization/79351
2266 * tree-ssa-sccvn.c (vn_reference_lookup_3): For assignments from
2267 empty CONSTRUCTORs ensure the store is at a constant position.
2268
2269 2018-11-28 Richard Biener <rguenther@suse.de>
2270
2271 PR tree-optimization/88229
2272 * tree-ssa.c (non_rewritable_mem_ref_base): Check DECL_SIZE_UNIT
2273 is an INTEGER_CST before accessing it so.
2274
2275 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2276
2277 Backport from mainline
2278 2018-11-20 Andreas Krebbel <krebbel@linux.ibm.com>
2279
2280 * config/s390/s390.md ("clztidi2"): Swap the RTX's written to the
2281 DImode parts of the target operand.
2282
2283 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2284
2285 Backport from mainline
2286 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2287
2288 * doc/invoke.texi: Document z14/arch12 -march option.
2289
2290 2018-11-23 Tamar Christina <tamar.christina@arm.com>
2291
2292 Backported from mainline.
2293 2018-08-16 Tamar Christina <tamar.christina@arm.com>
2294
2295 PR target/84711
2296 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
2297 (mov<mov>): ..this and enable unconditionally.
2298
2299 2018-11-22 Uros Bizjak <ubizjak@gmail.com>
2300
2301 Backport from mainline
2302 2018-11-16 Uros Bizjak <ubizjak@gmail.com>
2303
2304 PR target/88051
2305 * config/i386/sse.md (UNSPEC_MOVDI_TO_SSE): New UNSPEC.
2306 (movdi_to_sse): Rewrite using UNSPEC_MOVDI_TO_SSE unspec.
2307
2308 2018-11-20 Eric Botcazou <ebotcazou@adacore.com>
2309
2310 PR rtl-optimization/85925
2311 * rtl.h (word_register_operation_p): New predicate.
2312 * combine.c (record_dead_and_set_regs_1): Only apply specific handling
2313 for WORD_REGISTER_OPERATIONS targets to word_register_operation_p RTX.
2314 * rtlanal.c (nonzero_bits1): Likewise. Adjust couple of comments.
2315 (num_sign_bit_copies1): Likewise.
2316
2317 2018-11-19 Martin Liska <mliska@suse.cz>
2318
2319 PR gcov-profile/88045
2320 * coverage.c (coverage_begin_function): One can't relly on the
2321 fact that function ends on the same line it starts or later.
2322
2323 2018-11-18 Uros Bizjak <ubizjak@gmail.com>
2324
2325 Backport from mainline
2326 2018-11-11 Uros Bizjak <ubizjak@gmail.com>
2327
2328 PR target/87928
2329 * config/i386/i386.h (STACK_BOUNDARY): Use TARGET_64BIT_MS_ABI
2330 instead of (TARGET_64BIT && ix86_abi == MS_ABI).
2331 * config/i386/darwin.h (STACK_BOUNDARY): Ditto.
2332 * config/i386/cygming.h (STACK_BOUNDARY): Remove.
2333
2334 2018-11-16 Eric Botcazou <ebotcazou@adacore.com>
2335
2336 * tree-switch-conversion.c (emit_case_decision_tree): Pass location
2337 of switch statement to emit_case_nodes.
2338 (do_jump_if_equal): Add LOC parameter and set it on the newly built
2339 GIMPLE comparison statement.
2340 (emit_cmp_and_jump_insns): Likewise.
2341 (emit_case_nodes): Add LOC parameter and pass it to do_jump_if_equal
2342 as well as recursive calls.
2343
2344 2018-11-15 Nathan Sidwell <nathan@acm.org>
2345
2346 PR debug/88006
2347 PR debug/87462
2348 * dwarf2out.c (dwarf2out_finish): Apply resolve_addr to comdat
2349 type list.
2350
2351 2018-11-14 Paul A. Clarke <pc@us.ibm.com>
2352
2353 Backport from mainline
2354 * config/rs6000/xmmintrin.h (_mm_extract_pi16): Fix for big-endian.
2355
2356 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2357
2358 Backport from mainline
2359 PR target/85968
2360 * config/arc/arc.c (arc_return_address_register): Fix
2361 if-condition.
2362
2363 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2364
2365 Backport from mainline
2366 * config/arc/arc.h (FUNCTION_PROFILER): Redefine to empty.
2367 * config/arc/elf.h (PROFILE_HOOK): Define.
2368 * config/arc/linux.h (PROFILE_HOOK): Likewise.
2369
2370 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2371
2372 Backport from mainline
2373 * config/arc/arc.c (hwloop_optimize): Bailout when detecting a
2374 jump table data in the text section.
2375
2376 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2377
2378 Backport from mainline
2379 * config/arc/arc.c (arc_eh_return_address_location): Repurpose it
2380 to fit the eh_return pattern.
2381 * config/arc/arc.md (eh_return): Define.
2382 (VUNSPEC_ARC_EH_RETURN): Likewise.
2383 * config/arc/arc-protos.h (arc_eh_return_address_location): Match
2384 new implementation.
2385 * config/arc/arc.h (EH_RETURN_HANDLER_RTX): Remove it.
2386
2387 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2388
2389 Backport from mainline
2390 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
2391
2392 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
2393
2394 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2395
2396 Backport from mainline
2397 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
2398
2399 2018-11-11 Uros Bizjak <ubizjak@gmail.com>
2400
2401 Backport from mainline
2402 2018-11-04 Uros Bizjak <ubizjak@gmail.com>
2403
2404 PR middle-end/58372
2405 * cfgexpand.c (pass_expand::execute): Move the call to
2406 finish_eh_generation in front of the call to expand_stack_alignment.
2407
2408 2018-11-07 Max Filippov <jcmvbkbc@gmail.com>
2409
2410 Backport from mainline
2411 2018-11-05 Max Filippov <jcmvbkbc@gmail.com>
2412
2413 * config/xtensa/uclinux.h (XTENSA_ALWAYS_PIC): Change to 0.
2414
2415 2018-11-05 Jakub Jelinek <jakub@redhat.com>
2416
2417 PR tree-optimization/87859
2418 * gimple-ssa-store-merging.c (struct merged_store_group): Add
2419 first_nonmergeable_order member.
2420 (merged_store_group::merged_store_group): Initialize them.
2421 (imm_store_chain_info::coalesce_immediate_stores): Don't merge
2422 stores with order >= first_nonmergeable_order.
2423 Set merged_store->first_nonmergeable_order if we've skipped any
2424 stores. Attempt to merge overlapping INTEGER_CST stores that
2425 we would otherwise skip.
2426
2427 PR sanitizer/87837
2428 * match.pd (X + Y < X): Don't optimize if TYPE_OVERFLOW_SANITIZED.
2429
2430 Backported from mainline
2431 2018-10-20 Jakub Jelinek <jakub@redhat.com>
2432
2433 PR middle-end/87647
2434 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
2435
2436 2018-10-19 Jakub Jelinek <jakub@redhat.com>
2437
2438 PR middle-end/85488
2439 PR middle-end/87649
2440 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
2441 depend closely nested inside of loop with ordered clause with
2442 a parameter.
2443
2444 2018-10-29 Richard Biener <rguenther@suse.de>
2445
2446 Backport from mainline
2447 2018-09-26 Richard Biener <rguenther@suse.de>
2448
2449 PR debug/87428
2450 PR debug/87362
2451 * tree-inline.c (expand_call_inline): When the location
2452 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
2453 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
2454 the inserted BLOCK to make inlined_function_outer_scope_p
2455 recognize it.
2456 * dwarf2out.c (add_call_src_coords_attributes): Do not add
2457 coords for reserved locations.
2458
2459 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
2460
2461 Backport from mainline
2462 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
2463
2464 PR bootstrap/81033
2465 PR target/81733
2466 PR target/52795
2467 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
2468 (dwarf2out_switch_text_section): Generate a local label for the second
2469 function sub-section and apply it as the second FDE start label.
2470 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
2471 second sub-section start.
2472
2473 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
2474
2475 Backport from mainline
2476 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
2477
2478 * config/darwin.c
2479 (darwin_function_switched_text_sections): Delete.
2480 * gcc/config/darwin.h
2481 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
2482
2483 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
2484
2485 backport from mainline.
2486 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
2487
2488 PR target/85669
2489 * config/rs6000/darwin.h (STACK_BOUNDARY): New.
2490 (RS6000_STARTING_FRAME_OFFSET): Adjust to preserve 16byte alignment.
2491 (STACK_DYNAMIC_OFFSET): Likewise.
2492
2493 2018-10-26 Bill Schmidt <wschmidt@linux.ibm.com>
2494
2495 Backport from mainline
2496 2018-10-19 Bill Schmidt <wschmidt@linux.ibm.com>
2497
2498 PR tree-optimization/87473
2499 * gimple-ssa-strength-reduction.c (record_phi_increments_1): For
2500 phi arguments identical to the base expression of the phi
2501 candidate, record a phi-adjust increment of zero minus the index
2502 expression of the hidden basis.
2503 (phi_incr_cost_1): For phi arguments identical to the base
2504 expression of the phi candidate, the difference to compare against
2505 the increment is zero minus the index expression of the hidden
2506 basis, and there is no potential savings from replacing the (phi)
2507 statement.
2508 (ncd_with_phi): For phi arguments identical to the base expression
2509 of the phi candidate, the difference to compare against the
2510 increment is zero minus the index expression of the hidden basis.
2511 (all_phi_incrs_profitable_1): For phi arguments identical to the
2512 base expression of the phi candidate, the increment to be checked
2513 for profitability is zero minus the index expression of the hidden
2514 basis.
2515
2516 2018-10-25 Richard Biener <rguenther@suse.de>
2517
2518 PR tree-optimization/87665
2519 PR tree-optimization/87745
2520 * tree-vectorizer.h (get_earlier_stmt): Remove.
2521 (get_later_stmt): Pick up UID from the original non-pattern stmt.
2522
2523 2018-10-24 Richard Biener <rguenther@suse.de>
2524
2525 PR tree-optimization/87665
2526 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
2527 to reflect reality.
2528
2529 2018-10-23 Richard Biener <rguenther@suse.de>
2530
2531 PR tree-optimization/87700
2532 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
2533
2534 2018-10-19 Richard Biener <rguenther@suse.de>
2535
2536 PR middle-end/87645
2537 Backport from mainline
2538 2018-07-12 Richard Biener <rguenther@suse.de>
2539
2540 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
2541 (vn_lookup_simplify_result): Remove recursion limit applied
2542 here.
2543 (vn_nary_build_or_lookup_1): Adjust.
2544 (try_to_simplify): Likewise.
2545 * gimple-match-head.c (gimple_resimplify1): Instead apply one
2546 here.
2547 (gimple_resimplify2): Likewise.
2548 (gimple_resimplify3): Likewise.
2549 (gimple_resimplify4): Likewise.
2550
2551 2018-10-19 Andreas Krebbel <krebbel@linux.ibm.com>
2552
2553 Backport from mainline
2554 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
2555
2556 * config/s390/s390.c (s390_expand_vec_init): Force vector element
2557 into reg if it isn't a general operand.
2558
2559 2018-10-18 Richard Biener <rguenther@suse.de>
2560
2561 PR middle-end/87087
2562 Revert
2563 2018-02-07 Richard Biener <rguenther@suse.de>
2564
2565 PR tree-optimization/84204
2566 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
2567 this place.
2568
2569 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
2570
2571 PR middle-end/87623
2572 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
2573 bail out if both sides do not have the same storage order.
2574
2575 2018-10-17 Richard Biener <rguenther@suse.de>
2576
2577 Backport from mainline
2578 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
2579
2580 PR middle-end/63155
2581 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
2582 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
2583
2584 2018-10-16 Richard Biener <rguenther@suse.de>
2585
2586 Backport from mainline
2587 2018-10-08 Richard Biener <rguenther@suse.de>
2588
2589 PR tree-optimization/63155
2590 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
2591 (ssa_propagation_engine::ssa_propagate): Remove redundant
2592 bitmap bit clearing.
2593
2594 2018-10-05 Richard Biener <rguenther@suse.de>
2595
2596 PR tree-optimization/63155
2597 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
2598 vertical space in dumpfiles.
2599 * tree-ssa-propagate.h
2600 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
2601 * tree-ssa-propagate.c (cfg_blocks_back): New global.
2602 (ssa_edge_worklist_back): Likewise.
2603 (curr_order): Likewise.
2604 (cfg_blocks_get): Remove abstraction.
2605 (cfg_blocks_add): Likewise.
2606 (cfg_blocks_empty_p): Likewise.
2607 (add_ssa_edge): Add to current or next worklist based on
2608 RPO index.
2609 (add_control_edge): Likewise.
2610 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
2611 into ...
2612 (ssa_propagation_engine::ssa_propagate): ... here. Unify
2613 iteration from CFG and SSA edge worklist so we process
2614 everything in RPO order, prioritizing forward progress
2615 over iteration.
2616 (ssa_prop_init): Allocate new worklists, do not dump
2617 immediate uses.
2618 (ssa_prop_fini): Free new worklists.
2619
2620 2018-09-24 Richard Biener <rguenther@suse.de>
2621
2622 PR tree-optimization/63155
2623 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
2624 the worklist when the edge of the respective argument isn't
2625 executable.
2626
2627 2018-10-16 Wilco Dijkstra <wdijkstr@arm.com>
2628
2629 Backported from mainline
2630 PR target/87511
2631 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
2632 Use HOST_WIDE_INT_1U for shift.
2633
2634 2018-10-16 Richard Biener <rguenther@suse.de>
2635
2636 Backport from mainline
2637 2018-09-18 Richard Biener <rguenther@suse.de>
2638
2639 PR middle-end/63155
2640 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
2641 (compute_samebase_partition_bases): Likewise.
2642 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
2643 (gimple_can_coalesce_p): Simplify.
2644
2645 2018-10-16 Richard Biener <rguenther@suse.de>
2646
2647 Backport from mainline
2648 2018-10-15 Richard Biener <rguenther@suse.de>
2649
2650 PR middle-end/87610
2651 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
2652 (visit_loadstore): When a used restrict tag escaped verify that
2653 the points-to solution of "other" pointers do not include
2654 escaped.
2655 (compute_dependence_clique): If a used restrict tag escaped
2656 communicated that down to visit_loadstore.
2657
2658 2018-10-01 Richard Biener <rguenther@suse.de>
2659
2660 PR tree-optimization/87465
2661 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
2662 causing branch miscounts.
2663
2664 2018-10-11 Jakub Jelinek <jakub@redhat.com>
2665
2666 Backported from mainline
2667 2018-10-10 Jakub Jelinek <jakub@redhat.com>
2668
2669 PR target/87550
2670 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
2671 to special_args set.
2672
2673 2018-09-26 Jakub Jelinek <jakub@redhat.com>
2674
2675 PR target/87414
2676 * config/i386/i386.c: Include debug.h and dwarf2out.h.
2677 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
2678 call.
2679
2680 2018-09-12 Jakub Jelinek <jakub@redhat.com>
2681 Andreas Krebbel <krebbel@linux.ibm.com>
2682
2683 PR tree-optimization/86844
2684 * gimple-ssa-store-merging.c
2685 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
2686 there are any overlapping stores in between them, make sure they are
2687 also coalesced or we give up completely.
2688
2689 2018-10-09 Will Schmidt <will_schmidt@vnet.ibm.com>
2690
2691 Backport from trunk.
2692 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
2693
2694 PR target/86731
2695 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
2696 around folding of vec_sl to handle out of range shift values.
2697
2698 2018-10-09 H.J. Lu <hongjiu.lu@intel.com>
2699
2700 Backport from mainline
2701 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
2702
2703 PR target/87370
2704 * config/i386/i386.c (construct_container): Use TImode for
2705 BLKmode values in 2 integer registers.
2706
2707 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
2708
2709 Backport from mainline
2710 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
2711
2712 PR target/87517
2713 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
2714 Defined with __builtin_ia32_vfmaddsubpd512_mask.
2715
2716 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
2717
2718 Backport from mainline
2719 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
2720
2721 PR target/87522
2722 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
2723 assembler for -mavx.
2724 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
2725
2726 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
2727
2728 Backport from mainline
2729 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
2730
2731 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
2732 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
2733
2734 2018-10-03 Jonathan Wakely <jwakely@redhat.com>
2735
2736 PR other/87353
2737 * doc/invoke.texi (Link Options): Fix formatting and grammar.
2738
2739 2018-10-03 Martin Liska <mliska@suse.cz>
2740
2741 Backport from mainline
2742 2018-10-03 Martin Liska <mliska@suse.cz>
2743
2744 PR gcov-profile/86109
2745 * coverage.c (coverage_begin_function): Do not
2746 mark lambdas as artificial.
2747 * tree-core.h (struct GTY): Remove tm_clone_flag
2748 and introduce new lambda_function.
2749 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
2750
2751 2018-10-02 H.J. Lu <hongjiu.lu@intel.com>
2752
2753 Backport from mainline
2754 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
2755
2756 PR target/82699
2757 * config/i386/i386.c (rest_of_insert_endbranch): Set
2758 endbr_queued_at_entrance to true and don't insert ENDBR if
2759 x86_function_profiler will be called.
2760 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
2761 is true.
2762 * config/i386/i386.h (machine_function): Add
2763 endbr_queued_at_entrance.
2764
2765 2018-10-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2766
2767 Backport from mainline
2768 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2769
2770 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
2771 if starting source register is not even.
2772
2773 2018-09-29 Jakub Jelinek <jakub@redhat.com>
2774
2775 PR target/87467
2776 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
2777 __m512d type for __A argument rather than __m512.
2778
2779 2018-09-27 Michael Meissner <meissner@linux.ibm.com>
2780
2781 Backport from mainline
2782 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
2783
2784 PR target/87033
2785 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
2786 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
2787 for indexed loads.
2788
2789 2018-09-25 Martin Liska <mliska@suse.cz>
2790
2791 Backport from mainline
2792 2018-09-24 Martin Liska <mliska@suse.cz>
2793
2794 PR sanitizer/85774
2795 * asan.c: Make asan_handled_variables extern.
2796 * asan.h: Likewise.
2797 * cfgexpand.c (expand_stack_vars): Make sure
2798 a representative is unpoison if another
2799 variable in the partition is handled by
2800 use-after-scope sanitization.
2801
2802 2018-09-24 Andrew Pinski <apinski@marvell.com>
2803
2804 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
2805 access prev before checking it for NULLness in the
2806 AARCH64_FUSE_CMP_BRANCH case.
2807
2808 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
2809
2810 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
2811 if the call takes a static chain.
2812
2813 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
2814
2815 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
2816 (atomic_storehi): Likewise.
2817 (atomic_storesi): Likewise.
2818 (atomic_loaddi): Restore compare and swap exchange loop code.
2819
2820 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
2821
2822 Backport from trunk
2823 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
2824
2825 PR rtl-optimization/86882
2826 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
2827
2828 2018-09-18 Martin Liska <mliska@suse.cz>
2829
2830 Backport from mainline
2831 2018-09-17 Martin Liska <mliska@suse.cz>
2832
2833 PR gcov-profile/85871
2834 * gcov.c (output_intermediate_file): Fix out of bounds
2835 access.
2836
2837 2018-09-16 Hans-Peter Nilsson <hp@bitrange.com>
2838
2839 PR target/85666
2840 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
2841 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
2842 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
2843 leaf_function_p, instead use has_hard_reg_initial_val.
2844
2845 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
2846
2847 PR middle-end/87188
2848 * dojump.c (do_compare_and_jump): Canonicalize function pointers
2849 when one operand is a function pointer. Use POINTER_TYPE_P and
2850 FUNC_OR_METHOD_TYPE_P.
2851 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
2852 * fold-const.c (build_range_check): Likewise.
2853 * match.pd (simple_comparison): Likewise.
2854
2855 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
2856
2857 Backport from trunk
2858 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
2859
2860 PR target/87224
2861 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
2862 alternatives.
2863
2864 2018-09-14 Carl Love <cel@us.ibm.com>
2865
2866 Backport from trunk
2867 2018-09-14 Carl Love <cel@us.ibm.com>
2868
2869 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
2870 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
2871
2872 2018-09-12 Segher Boessenkool <segher@kernel.crashing.org>
2873
2874 Backport from trunk
2875 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
2876
2877 PR target/86989
2878 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
2879 the TOC register.
2880
2881 2018-09-12 Segher Boessenkool <segher@kernel.crashing.org>
2882
2883 Backport from trunk
2884 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
2885
2886 PR rtl-optimization/86771
2887 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
2888 of two SETs into those two SETs, one to be placed at i2, if that SETs
2889 destination is modified between i2 and i3.
2890
2891 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
2892
2893 Backport from mainline
2894 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
2895
2896 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
2897 constants.
2898 ("trunc<BFP:mode><DFP_ALL:mode>2")
2899 ("trunc<DFP_ALL:mode><BFP:mode>2")
2900 ("extend<BFP:mode><DFP_ALL:mode>2")
2901 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
2902 according to the target operand type.
2903
2904 2018-09-12 Jakub Jelinek <jakub@redhat.com>
2905
2906 PR middle-end/87248
2907 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
2908 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
2909
2910 2018-09-05 Nathan Sidwell <nathan@acm.org>
2911
2912 PR c++/87137
2913 * stor-layout.c (place_field): Scan forwards to check last
2914 bitfield when ms_bitfield_placement is in effect.
2915
2916 2018-09-05 Richard Biener <rguenther@suse.de>
2917
2918 PR bootstrap/87225
2919 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
2920 return.
2921
2922 2018-09-05 Jakub Jelinek <jakub@redhat.com>
2923
2924 Backported from mainline
2925 2018-09-04 Jakub Jelinek <jakub@redhat.com>
2926
2927 PR target/87198
2928 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
2929 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
2930 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
2931 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
2932 and OPTION_MASK_ISA_XSAVEC_UNSET.
2933
2934 2018-08-31 Jakub Jelinek <jakub@redhat.com>
2935
2936 PR middle-end/87138
2937 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
2938 gen_int_mode. Formatting fixes.
2939
2940 2018-08-11 Jakub Jelinek <jakub@redhat.com>
2941
2942 PR tree-optimization/86835
2943 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
2944 new_stmt after def_gsi, make sure to insert new_square_stmt after
2945 that stmt, not 2 stmts before it.
2946
2947 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
2948
2949 Backport from mainline
2950 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
2951
2952 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
2953 XOR operations in NAND case.
2954
2955 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
2956
2957 * doc/invoke.texi (Option Summary): Add -Waligned-new.
2958
2959 2018-09-03 Tom de Vries <tdevries@suse.de>
2960
2961 backport from trunk:
2962 2018-06-21 Tom de Vries <tdevries@suse.de>
2963
2964 PR tree-optimization/85859
2965 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
2966 test with comment from bb_no_side_effects_p.
2967
2968 2018-09-01 Michael Matz <matz@suse.de>
2969
2970 Backport from mainline
2971 PR tree-optimization/87074
2972 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
2973 PHIs for outer-loop uses.
2974
2975 2018-08-31 Richard Biener <rguenther@suse.de>
2976
2977 Backport from mainline
2978 2018-08-27 Richard Biener <rguenther@suse.de>
2979
2980 PR tree-optimization/86927
2981 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
2982 use const cond reduction code.
2983
2984 2018-08-23 Richard Biener <rguenther@suse.de>
2985
2986 PR middle-end/87024
2987 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
2988 calls.
2989
2990 2018-08-22 Richard Biener <rguenther@suse.de>
2991
2992 PR tree-optimization/86945
2993 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
2994
2995 2018-08-17 Richard Biener <rguenther@suse.de>
2996
2997 PR middle-end/86505
2998 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
2999 across a va-arg-pack using call adjust its return value accordingly.
3000
3001 2018-08-02 Richard Biener <rguenther@suse.de>
3002
3003 PR tree-optimization/86816
3004 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
3005 which checks for value availability before querying it.
3006 (gvn_uses_equal): Use it.
3007 (same_succ_hash): Likewise.
3008 (gimple_equal_p): Likewise.
3009
3010 2018-07-17 Richard Biener <rguenther@suse.de>
3011
3012 PR lto/86456
3013 * dwarf2out.c (init_sections_and_labels): Always generate
3014 a debug_line_str_section for early LTO debug.
3015 (dwarf2out_finish): Reset debug_line_str_hash output early.
3016 Bump counter for extra dwarf5 .debug_loc labels to not conflict
3017 with fat LTO part.
3018 (dwarf2out_early_finish): Output debug_line_str.
3019
3020 2018-08-29 Luis Machado <luis.machado@linaro.org>
3021
3022 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static global.
3023 (qdf24xx_tunings): Set vector cost structure to qdf24xx_vector_cost.
3024
3025 2018-08-29 Luis Machado <luis.machado@linaro.org>
3026
3027 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
3028 <register_sextend>: Set to 3.
3029
3030 2018-08-27 Martin Sebor <msebor@redhat.com>
3031
3032 PR tree-optimization/86914
3033 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
3034
3035 2018-08-28 Jakub Jelinek <jakub@redhat.com>
3036
3037 PR middle-end/87099
3038 * calls.c (maybe_warn_nonstring_arg): Punt early if
3039 warn_stringop_overflow is zero. Don't call get_range_strlen
3040 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
3041 Only use lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
3042 increment lenrng[0].
3043
3044 2018-08-27 Jakub Jelinek <jakub@redhat.com>
3045
3046 PR rtl-optimization/87065
3047 * combine.c (simplify_if_then_else): Formatting fix.
3048 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
3049 check.
3050 (known_cond): Don't return const_true_rtx for vector modes. Use
3051 CONST0_RTX instead of const0_rtx. Formatting fixes.
3052
3053 2018-08-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3054
3055 Backport from mainline
3056 PR target/86662
3057 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
3058 with all enabled __intN types.
3059
3060 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
3061
3062 2018-08-21 H.J. Lu <hongjiu.lu@intel.com>
3063
3064 Backport from mainline
3065 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
3066
3067 PR target/87014
3068 * config/i386/i386.md (eh_return): Always update EH return
3069 address in word_mode.
3070
3071 2018-08-17 John David Anglin <danglin@gcc.gnu.org>
3072
3073 Backport from mainline
3074 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
3075
3076 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
3077 Update comment for atomic instructions.
3078 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
3079 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
3080 Remove.
3081 (atomic_loaddi): Revise fence expansion to only emit fence prior to
3082 load for __ATOMIC_SEQ_CST model.
3083 (atomic_loaddi_1): Remove float register target.
3084 (atomic_storedi): Handle CONST_INT values.
3085 (atomic_storedi_1): Remove float register source. Add special case
3086 for zero value.
3087 (memory_barrier): New expander and insn.
3088
3089 2018-08-16 Tamar Christina <tamar.christina@arm.com>
3090
3091 Backport from mainline
3092 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
3093
3094 PR target/86640
3095 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
3096 instead of GEN_INT.
3097
3098 2018-08-16 Martin Liska <mliska@suse.cz>
3099
3100 Backport from mainline
3101 2018-08-02 Martin Liska <mliska@suse.cz>
3102
3103 PR gcov-profile/86817
3104 * gcov.c (process_all_functions): New function.
3105 (main): Call it.
3106 (process_file): Move functions processing to
3107 process_all_functions.
3108
3109 2018-08-14 Siddhesh Poyarekar <siddhesh@sourceware.org>
3110
3111 Backport from mainline
3112 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
3113
3114 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
3115 neon_dup_q to...
3116 (falkor_am_1_gtov_gtov): ... a new insn reservation.
3117
3118 2018-08-13 Liu Hao <lh_mouse@126.com>
3119
3120 Backport from mainline
3121 2018-08-13 Liu Hao <lh_mouse@126.com>
3122
3123 * pretty-print.c (eat_esc_sequence): Swap the foreground and
3124 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
3125 and clear it thereafter, as it only works for DBCS.
3126
3127 2018-08-13 Liu Hao <lh_mouse@126.com>
3128
3129 Backport from mainline
3130 2018-08-13 Liu Hao <lh_mouse@126.com>
3131
3132 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
3133 handle returned by _get_osf_handle().
3134
3135 2018-08-14 Richard Sandiford <richard.sandiford@arm.com>
3136
3137 Backport from mainline
3138 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
3139
3140 PR tree-optimization/86871
3141 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
3142 instead of gimple_assign_lhs.
3143
3144 2018-08-07 H.J. Lu <hongjiu.lu@intel.com>
3145
3146 Backport from mainline
3147 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
3148
3149 PR target/86386
3150 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
3151 cfun->machine->max_used_stack_alignment if needed.
3152
3153 2018-08-02 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3154
3155 Backport from mainline
3156 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3157
3158 PR middle-end/86705
3159 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
3160 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
3161 requested variable alignment.
3162 (expand_one_ssa_partition): Likewise.
3163 (expand_one_var): Likewise.
3164
3165 2018-08-02 Andreas Schwab <schwab@linux-m68k.org>
3166
3167 Backport from mainline
3168 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
3169
3170 PR target/86820
3171 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
3172 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
3173
3174 2018-08-01 Richard Biener <rguenther@suse.de>
3175
3176 PR bootstrap/86724
3177 * graphite.h: Include isl/id.h and isl/space.h to allow build
3178 with ISL 0.20.
3179
3180 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
3181
3182 PR target/86651
3183 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
3184 mode for COFF targets.
3185 * defaults.h (TARGET_COFF): Define.
3186 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
3187 TARGET_COFF): Define.
3188 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
3189 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
3190 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
3191
3192 2018-07-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
3193
3194 Backport from mainline
3195 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
3196
3197 PR c/86617
3198 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
3199
3200 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
3201
3202 * config/pa/pa.c (pa_output_addr_vec): Align address table.
3203 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
3204 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
3205
3206 2018-07-26 Uros Bizjak <ubizjak@gmail.com>
3207
3208 Backport from mainline
3209 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
3210
3211 PR target/86511
3212 * expmed.c (emit_store_flag): Do not emit setcc followed by a
3213 conditional move when trapping comparison was split to a
3214 non-trapping one (and vice versa).
3215
3216 2018-07-26 Jakub Jelinek <jakub@redhat.com>
3217
3218 Backported from mainline
3219 2018-07-24 Jakub Jelinek <jakub@redhat.com>
3220
3221 PR middle-end/86627
3222 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
3223 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
3224 and abs_d == d, do the power of two handling if profitable.
3225
3226 2018-07-17 Jakub Jelinek <jakub@redhat.com>
3227
3228 PR middle-end/86542
3229 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
3230 to _looptemp_ clauses, other than the first two.
3231
3232 PR middle-end/86539
3233 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
3234 and cond temporaries don't have reference type if iterator has
3235 pointer type. For init use &for_pre_body instead of pre_p if
3236 for_pre_body is non-empty.
3237
3238 2018-07-26 Jakub Jelinek <jakub@redhat.com>
3239
3240 PR middle-end/86660
3241 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
3242 declare target to variables if they have always,{to,from,tofrom} map
3243 kinds.
3244
3245 * BASE-VER: Set to 8.2.1.
3246
3247 2018-07-26 Release Manager
3248
3249 * GCC 8.2.0 released.
3250
3251 2018-07-18 Martin Sebor <msebor@redhat.com>
3252
3253 PR middle-end/85602
3254 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
3255 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
3256 Handle integer subtraction.
3257 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
3258 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
3259 * doc/invoke.texi (-Wstringop-truncation): Update.
3260
3261 gcc/testsuite/ChangeLog:
3262
3263 2018-07-16 Claudiu Zissulescu <claziss@synopsys.com>
3264
3265 Backport from mainline
3266 2017-03-24 Claudiu Zissulescu <claziss@synopsys.com>
3267
3268 * config/arc/arc-protos.h (arc_pad_return): Remove.
3269 * config/arc/arc.c (machine_function): Remove force_short_suffix
3270 and size_reason.
3271 (arc_print_operand): Adjust printing of '&'.
3272 (arc_verify_short): Remove conditional printing of short suffix.
3273 (arc_final_prescan_insn): Remove reference to size_reason.
3274 (pad_return): New function.
3275 (arc_reorg): Call pad_return.
3276 (arc_pad_return): Remove.
3277 (arc_init_machine_status): Remove reference to force_short_suffix.
3278 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
3279 (attr length): When attribute iscompact is true force to 2
3280 regardless; in the case of maybe check if we want to force the
3281 instruction to have 4 bytes length.
3282 (nopv): Change it to generate 4 byte long nop as well.
3283 (blockage): New pattern.
3284 (simple_return): Remove call to arc_pad_return.
3285 (p_return_i): Likewise.
3286
3287 2018-07-19 Richard Biener <rguenther@suse.de>
3288
3289 Backport from mainline
3290 2018-07-13 Richard Biener <rguenther@suse.de>
3291
3292 PR debug/86452
3293 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
3294 instead of get_context_die.
3295
3296 2018-07-11 Richard Biener <rguenther@suse.de>
3297
3298 PR debug/86457
3299 * dwarf2out.c (init_sections_and_labels): Use
3300 output_asm_line_debug_info consistently.
3301 (dwarf2out_early_finish): Likewise.
3302 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
3303 type units.
3304
3305 2018-07-16 Richard Biener <rguenther@suse.de>
3306
3307 Backport from mainline
3308 2018-07-13 Richard Biener <rguenther@suse.de>
3309
3310 PR middle-end/85974
3311 * match.pd (addr1 - addr2): Allow either of the operand to
3312 have a conversion.
3313
3314 2018-06-15 Richard Biener <rguenther@suse.de>
3315
3316 PR middle-end/86076
3317 * tree-cfg.c (move_stmt_op): unshare invariant addresses
3318 before adjusting their block.
3319
3320 2018-06-06 Richard Biener <rguenther@suse.de>
3321
3322 PR tree-optimization/85935
3323 * graphite-scop-detection.c (find_params_in_bb): Analyze
3324 condition operands with respect to the correct loop. Assert
3325 the analysis doesn't fail.
3326
3327 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
3328
3329 PR tree-optimization/86514
3330 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
3331 conversion to a boolean type from a type with greater precision.
3332
3333 2018-07-15 Bill Schmidt <wschmidt@linux.ibm.com>
3334
3335 Backport from mainline
3336 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
3337 Steve Munroe <munroesj52@gmail.com>
3338
3339 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
3340 (_mm_andnot_si128): Likewise.
3341 (_mm_or_si128): Likewise.
3342 (_mm_xor_si128): Likewise.
3343
3344 2018-07-14 Martin Sebor <msebor@redhat.com>
3345
3346 PR tree-optimization/86274
3347 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
3348 precondition.
3349 (format_floating): Correct handling of infinities and NaNs.
3350
3351 2018-07-13 H.J. Lu <hongjiu.lu@intel.com>
3352
3353 Backport from mainline
3354 2018-07-13 H.J. Lu <hongjiu.lu@intel.com>
3355 Sunil K Pandey <sunil.k.pandey@intel.com>
3356
3357 PR target/84413
3358 * config/i386/i386.c (m_CORE_AVX512): New.
3359 (m_CORE_AVX2): Likewise.
3360 (m_CORE_ALL): Add m_CORE_AVX2.
3361 * config/i386/x86-tune.def: Replace m_HASWELL with m_CORE_AVX2.
3362 Replace m_SKYLAKE_AVX512 with m_CORE_AVX512 on avx256_optimal
3363 and remove the rest of m_SKYLAKE_AVX512.
3364
3365 2018-07-13 Marek Polacek <polacek@redhat.com>
3366
3367 Backport from trunk
3368 2018-07-03 Marek Polacek <polacek@redhat.com>
3369
3370 PR middle-end/86202
3371 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
3372
3373 2018-07-12 Richard Biener <rguenther@suse.de>
3374
3375 PR target/84829
3376 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
3377 Remove -mieee-fp handling.
3378
3379 2018-07-12 Jakub Jelinek <jakub@redhat.com>
3380
3381 PR tree-optimization/86492
3382 * gimple-ssa-store-merging.c
3383 (imm_store_chain_info::coalesce_immediate_stores): Call
3384 check_no_overlap even for the merge_overlapping case.
3385
3386 2018-07-11 Jakub Jelinek <jakub@redhat.com>
3387
3388 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
3389 Use __mmask64 type instead of __mmask8 for __M argument.
3390 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
3391 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
3392 __U argument.
3393 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
3394 __mmask16 for __M argument.
3395 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
3396 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
3397 to __mmask16 instead of __mmask8.
3398 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
3399 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
3400 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
3401 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
3402 instead of __mmask16 for __U argument.
3403 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
3404 __mmask16 instead of __mmask8 for __U argument.
3405 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
3406 __U argument.
3407 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
3408 __mmask16.
3409 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
3410 argument.
3411 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
3412 __U argument.
3413 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
3414 __mmask16.
3415 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
3416 of __mmask16.
3417 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
3418 __U argument.
3419 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
3420 __U argument.
3421 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
3422 __U argument.
3423 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
3424 __U argument.
3425 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
3426 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
3427 return type as well as __M argument type and all casts from __mmask8
3428 to __mmask32.
3429 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
3430 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
3431 return type as well as __M argument type and all casts from __mmask8
3432 to __mmask16.
3433 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
3434 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
3435 return type as well as __M argument type and all casts from __mmask8
3436 to __mmask32.
3437 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
3438 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
3439 return type as well as __M argument type and all casts from __mmask8
3440 to __mmask16.
3441 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
3442 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
3443 __mmask16.
3444
3445 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
3446
3447 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
3448 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
3449 for __U argument.
3450
3451 2018-07-05 Martin Sebor <msebor@redhat.com>
3452
3453 PR c++/86400
3454 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
3455 than its domain to compute its the upper bound of a char array.
3456
3457 2018-07-03 Carl Love <cel@us.ibm.com>
3458
3459 Backport from trunk
3460 2018-07-03 Carl Love <cel@us.ibm.com>
3461
3462 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
3463 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
3464 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
3465 VSX_BUILTIN_DOUBLEL_V4SF.
3466
3467 2018-07-04 Luis Machado <luis.machado@linaro.org>
3468
3469 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
3470 global.
3471 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
3472
3473 2018-07-02 Segher Boessenkool <segher@kernel.crashing.org>
3474
3475 Backport from trunk
3476 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
3477
3478 PR target/86285
3479 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
3480 ieee128_float_type_node to long_double_type_node unless
3481 TARGET_LONG_DOUBLE_128 is set.
3482
3483 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
3484
3485 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
3486 -fno-omit-frame-pointer when not optimizing.
3487
3488 2018-06-30 Alexandre Oliva <aoliva@redhat.com>
3489
3490 PR debug/86064
3491 * dwarf2out.c (loc_list_has_views): Adjust comments.
3492 (dw_loc_list): Split single cross-partition range with
3493 nonzero locview.
3494
3495 2018-06-29 Kelvin Nilsen <kelvin@gcc.gnu.org>
3496
3497 Backport from mainline
3498 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
3499
3500 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
3501 behavior of vec_pack (vector double, vector double) to match
3502 behavior of vec_float2 (vector double, vector double).
3503
3504 2018-06-29 Jakub Jelinek <jakub@redhat.com>
3505
3506 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
3507
3508 2018-06-28 Kelvin Nilsen <kelvin@gcc.gnu.org>
3509
3510 Backport from mainline
3511 2017-05-23 Segher Boessenkool <segher@kernel.crashing.org>
3512
3513 * doc/sourcebuild.texi (Endianness): New subsubsection.
3514
3515 2018-06-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
3516
3517 Backport from mainline
3518 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
3519
3520 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
3521 behavior of vec_packsu (vector unsigned long long, vector unsigned
3522 long long) to match behavior of vec_packs with same signature.
3523
3524 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
3525
3526 Backport from trunk
3527 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
3528
3529 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
3530 unaligned vsx for 16B memset.
3531
3532 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
3533
3534 Backport from trunk
3535 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
3536
3537 PR target/86222
3538 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
3539 correctly.
3540
3541 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
3542
3543 Backport from trunk
3544 2018-05-08 Segher Boessenkool <segher@kernel.crashing.org>
3545
3546 PR rtl-optimization/85645
3547 * regrename.c (build_def_use): Also kill the chains that include the
3548 destination of a REG_CFA_REGISTER note.
3549
3550 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
3551
3552 Backport from trunk
3553 2018-05-08 Segher Boessenkool <segher@kernel.crashing.org>
3554
3555 PR rtl-optimization/85645
3556 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
3557 insn that has a REG_CFA_REGISTER note.
3558
3559 2018-06-26 Robin Dapp <rdapp@linux.ibm.com>
3560
3561 * config/s390/s390.h (enum processor_flags): Do not use
3562 default tune parameter when -march was specified.
3563
3564 2018-06-26 Jakub Jelinek <jakub@redhat.com>
3565
3566 PR target/86314
3567 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
3568 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
3569 operands.
3570
3571 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
3572
3573 Back port from trunk
3574 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
3575
3576 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
3577 added IEEE/IBM long double multilib support on PowerPC little
3578 endian Linux systems.
3579 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
3580 (MULTILIB_DEFAULTS): Likewise.
3581 * config/rs6000/rs6000.c (rs6000_option_override_internal):
3582 Likewise.
3583 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
3584 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
3585 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
3586
3587 2018-06-25 Segher Boessenkool <segher@kernel.crashing.org>
3588
3589 Backport from trunk
3590 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
3591
3592 * config/rs6000/rs6000.md (abs<mode>2): Handle IFmode.
3593
3594 2018-05-02 Jan Hubicka <jh@suse.cz>
3595
3596 Backport from mainline
3597 2018-04-30 Jan Hubicka <jh@suse.cz>
3598
3599 * lto-wrapper.c (ltrans_priorities): New static var.
3600 (cmp_priority): New.
3601 (run_gcc): Read priorities and if doing parallel build order
3602 the Makefile by them.
3603
3604 2018-06-25 Segher Boessenkool <segher@kernel.crashing.org>
3605
3606 Backport from trunk
3607 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
3608
3609 PR target/86197
3610 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
3611 ieee128 argument takes up only one (vector) register, not two (floating
3612 point) registers.
3613
3614 2018-06-23 Richard Sandiford <richard.sandiford@linaro.org>
3615
3616 PR tree-optimization/85989
3617 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
3618 variable.
3619 (backprop::intersect_uses): Check it when deciding whether this
3620 is a backedge reference.
3621 (backprop::process_block): Add each phi to m_visited_phis
3622 after visiting it, then clear it at the end.
3623
3624 2018-06-22 David Edelsohn <dje.gcc@gmail.com>
3625
3626 Backport from mainline
3627
3628 2018-06-19 Tony Reix <tony.reix@atos.com>
3629 Damien Bergamini <damien.bergamini@atos.com>
3630 David Edelsohn <dje.gcc@gmail.com>
3631
3632 * collect2.c (static_obj): New variable.
3633 (static_libs): New variable.
3634 (is_in_list): Uncomment declaration.
3635 (main): Track AIX libraries linked statically.
3636 (is_in_list): Uncomment definition.
3637 (scan_prog_file): Don't add AIX shared libraries initializer
3638 to constructor list if linking statically.
3639
3640 2018-06-22 Michael Meissner <meissner@linux.ibm.com>
3641
3642 Back port from trunk
3643 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
3644
3645 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
3646 conversion insn that shows up when pr85657-3.c is compiled using
3647 IEEE 128-bit long double.
3648
3649 Back port from trunk
3650 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
3651
3652 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
3653 multiply and divide external functions from being created more
3654 than once.
3655
3656 Back port from trunk
3657 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
3658
3659 * config/rs6000/rs6000.md (neg<mode>2_internal): Use the correct
3660 mode to check whether the mode is IBM extended.
3661
3662 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
3663
3664 PR target/85358
3665 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
3666 floating point modes, so that IFmode is numerically greater than
3667 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
3668 to declare the ordering. This prevents IFmode from being
3669 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
3670 machine. Include rs6000-modes.h to share the fractional values
3671 between genmodes* and the rest of the compiler.
3672 (IFmode): Likewise.
3673 (KFmode): Likewise.
3674 (TFmode): Likewise.
3675 * config/rs6000/rs6000-modes.h: New file.
3676 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
3677 meaning of rs6000_long_double_size so that 126..128 selects an
3678 appropriate 128-bit floating point type.
3679 (rs6000_option_override_internal): Likewise.
3680 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
3681 (TARGET_LONG_DOUBLE_128): Change the meaning of
3682 rs6000_long_double_size so that 126..128 selects an appropriate
3683 128-bit floating point type.
3684 (LONG_DOUBLE_TYPE_SIZE): Update comment.
3685 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
3686 source and destination to match the standard usage.
3687 (truncifkf2): Likewise.
3688 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
3689 ISA 2.07 to use an explicit clobber, instead of passing in a
3690 temporary.
3691 (copysign<mode>3_soft): Likewise.
3692
3693 Back port from trunk
3694 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
3695
3696 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
3697 TARGET_ELF.
3698
3699 Back port from trunk
3700 2018-06-04 Michael Meissner <meissner@linux.ibm.com>
3701
3702 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
3703 track if we pass or return IEEE 128-bit floating point.
3704 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
3705 C++ mangling that is compatible with GCC 8.1.
3706 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
3707 (init_cumulative_args): Note if we pass or return IEEE 128-bit
3708 floating point types.
3709 (rs6000_function_arg_advance_1): Likewise.
3710 (rs6000_mangle_type): Optionally generate mangled names that match
3711 what GCC 8.1 generated for IEEE 128-bit floating point types.
3712 (rs6000_globalize_decl_name): If we have an external function that
3713 passes or returns IEEE 128-bit types, generate a weak reference
3714 from the mangled name used in GCC 8.1 to the current mangled
3715 name.
3716 (rs6000_init_builtins): Make __ibm128 use the long double type if
3717 long double is IBM extended double. Make __float128 use the long
3718 double type if long double is IEEE 128-bit.
3719
3720 PR target/85657
3721 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
3722 macro for __ibm128 built-in functions.
3723 (PACK_IF): Add __ibm128 pack/unpack functions.
3724 (UNPACK_IF): Likewise.
3725 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
3726 enable long double built-in functions if long double is IEEE
3727 128-bit floating point.
3728 (rs6000_invalid_builtin): Update long double built-in function
3729 error message.
3730 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
3731 functions, adjust the built-in function to use the long double
3732 built-in function if __ibm128 and long double are the same type.
3733 * doc/extend.texi (PowerPC builtins): Update documention for
3734 __builtin_{,un}pack_longdouble. Add documentation for
3735 __builtin_{,un}pack_ibm128.
3736
3737 Back port from trunk
3738 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
3739
3740 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
3741 the 128-bit floating point types. Fix function comment.
3742
3743 2018-06-22 Michael Meissner <meissner@linux.ibm.com>
3744
3745 Back port from trunk
3746 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
3747
3748 PR target/85657
3749 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
3750 define __ibm128 as long double.
3751 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
3752 as a distinct type with IEEE 128-bit floating point is supported.
3753 (init_float128_ieee): Fix up conversions between IFmode and IEEE
3754 128-bit types to use the correct functions.
3755 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
3756 convert between 128-bit floating point types that have different
3757 modes but the same representation, instead of using gen_lowpart to
3758 makean alias.
3759 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
3760 KFmode.
3761 (IFKF_reg): New attributes to give the register constraints for
3762 IFmode and KFmode.
3763 (extend<mode>tf2_internal): New insns to mark an explicit
3764 conversion between 128-bit floating point types that have a
3765 different mode but share the same representation.
3766
3767 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3768
3769 PR target/85994
3770 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
3771 -x assembler-with-cpp.
3772
3773 2018-06-21 Sebastian Huber <sebastian.huber@embedded-brains.de>
3774
3775 Backported from mainline
3776 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
3777
3778 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
3779 multilibs for *-*-rtems*.
3780 * config/riscv/t-rtems: New file.
3781
3782 2018-06-20 Jakub Jelinek <jakub@redhat.com>
3783
3784 Backported from mainline
3785 2018-06-16 Jakub Jelinek <jakub@redhat.com>
3786
3787 PR rtl-optimization/86108
3788 * bb-reorder.c (create_forwarder_block): Renamed to ...
3789 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
3790 jump from new landing pad to the second part.
3791 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
3792 Adjust callers.
3793
3794 2018-06-20 Jakub Jelinek <jakub@redhat.com>
3795
3796 PR debug/86194
3797 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
3798 be narrowed.
3799
3800 PR tree-optimization/86231
3801 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
3802 anti-range don't overwrite *vr0min before using it to compute *vr0max.
3803
3804 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
3805
3806 Backport from mainline
3807 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
3808
3809 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
3810 constant.
3811 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
3812
3813 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
3814
3815 * gimplify.c (gimplify_init_constructor): Really never clear for an
3816 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
3817
3818 2018-06-18 Martin Sebor <msebor@redhat.com>
3819
3820 PR c/82063
3821 * calls.c (alloc_max_size): Correct a logic error/typo.
3822 Treat excessive arguments as infinite. Warn for invalid arguments.
3823 * doc/invoke.texi (-Walloc-size-larger-than): Update.
3824
3825 2018-06-16 Jakub Jelinek <jakub@redhat.com>
3826
3827 PR middle-end/86095
3828 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
3829 documented as preserved for backward compatibility only.
3830 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
3831
3832 2018-06-15 Jakub Jelinek <jakub@redhat.com>
3833
3834 PR middle-end/85878
3835 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
3836 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
3837 Only call store_expr for halves if the mode is the same.
3838
3839 PR middle-end/86123
3840 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
3841 Fix up comment formatting.
3842
3843 2018-06-14 Jakub Jelinek <jakub@redhat.com>
3844
3845 PR middle-end/86122
3846 * match.pd ((A +- CST1) +- CST2): Punt if last resort
3847 unsigned_type_for returns NULL.
3848
3849 PR target/85945
3850 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
3851 subregs of multi-word pseudos unless the float mode has word size.
3852
3853 2018-06-14 Richard Biener <rguenther@suse.de>
3854
3855 PR middle-end/86139
3856 * tree-vect-generic.c (build_word_mode_vector_type): Remove
3857 duplicate and harmful type_hash_canon.
3858 * tree.c (type_hash_canon): Assert we didn't find ourselves.
3859
3860 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
3861
3862 Backport from mainline
3863 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
3864
3865 * config/rtems.h (STDINT_LONG32): Define.
3866
3867 2018-05-05 Roland McGrath <mcgrathr@google.com>
3868
3869 PR other/77609
3870 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
3871 any section for which we don't know a specific type it should have,
3872 regardless of name. Previously this was done only for the exact
3873 names ".init_array", ".fini_array", and ".preinit_array".
3874 (default_elf_asm_named_section): Add comment about
3875 relationship with default_section_type_flags and SECTION_NOTYPE.
3876 (get_section): Don't consider it a type conflict if one side has
3877 SECTION_NOTYPE and the other doesn't, as long as neither has the
3878 SECTION_BSS et al used in the default_section_type_flags logic.
3879
3880 2018-06-13 Martin Sebor <msebor@redhat.com>
3881
3882 PR tree-optimization/86114
3883 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
3884 of integer types.
3885 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
3886
3887 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
3888
3889 PR target/86048
3890 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
3891 offsets for register save directives. Emit a second batch of save
3892 directives, if need be, when the function accesses prior frames.
3893
3894 2018-06-11 Jason Merrill <jason@redhat.com>
3895
3896 PR c++/80485 - inline function non-zero address.
3897 * symtab.c (nonzero_address): Check DECL_COMDAT.
3898
3899 2018-06-11 Peter Bergner <bergner@vnet.ibm.com>
3900
3901 Backport from mainline
3902 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
3903
3904 PR target/85755
3905 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
3906 addresses.
3907
3908 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
3909
3910 Backport from trunk
3911 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
3912
3913 PR target/85755
3914 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
3915 on the correct operand.
3916 (*movdi_internal64): Ditto.
3917
3918 2018-06-08 Carl Love <cel@us.ibm.com>
3919
3920 Backport from mainline
3921 * gcc/config/rs6000/vsx.md (vextract_fp_from_shorth,
3922 vextract_fp_from_shortl): Add BE support.
3923
3924 2018-06-08 Carl Love <cel@us.ibm.com>
3925
3926 Backport from mainline
3927 * gcc/config/rs6000/vsx.md (first_match_index_<mode>):
3928 Calculate index using natureal element order.
3929 (first_match_or_eos_index_<mode>):
3930 Calculate index using natural element order.
3931 (first_match_index_<mode>):
3932 Calculate index using natural element order.
3933 (first_match_or_eos_index_<mode>):
3934 Calculate index using natural order.
3935 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
3936 for BE and LE modes.
3937 * gcc/config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
3938 P9V_BUILTIN_VCLZLSBB_V16QI.
3939 * gcc/config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
3940 specific.
3941
3942 2018-06-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3943
3944 Backport from mainline
3945 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3946
3947 PR target/81497
3948 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
3949 qualifier_void_pointer and qualifier_const_void_pointer.
3950 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
3951 (arm_init_builtins): Handle the above.
3952 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
3953 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
3954 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
3955 void intrinsics.
3956
3957 2018-06-07 Uros Bizjak <ubizjak@gmail.com>
3958
3959 PR target/85684
3960 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
3961 Generate SImode target register for null target.
3962 <case IX86_BUILTIN_XGETBV>: Ditto.
3963 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
3964 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
3965
3966 2018-06-07 Peter Bergner <bergner@vnet.ibm.com>
3967
3968 Backport from mainline
3969 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
3970
3971 PR target/63177
3972 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
3973 Don't handle -mcpu=power8 if -mpower9-vector is also used.
3974
3975 2018-06-06 Richard Biener <rguenther@suse.de>
3976
3977 Backport from mainline
3978 2018-06-04 Richard Biener <rguenther@suse.de>
3979
3980 PR tree-optimization/86038
3981 * tracer.c (find_best_successor): Check probability for
3982 being initialized, bail out if not.
3983
3984 2018-05-30 Richard Biener <rguenther@suse.de>
3985
3986 PR tree-optimization/85964
3987 * tracer.c (better_p): Drop initialized count check, we only
3988 call the function with initialized counts now.
3989 (find_best_successor): Do find a best edge if one
3990 has uninitialized count.
3991 (find_best_predecessor): Likewise. Do BB frequency check only
3992 if count is initialized.
3993
3994 2018-05-28 Richard Biener <rguenther@suse.de>
3995
3996 PR tree-optimization/85934
3997 * tree-vect-generic.c (expand_vector_operations_1): Hoist
3998 vector boolean check before scalar optimization.
3999
4000 2018-05-22 Richard Biener <rguenther@suse.de>
4001
4002 PR tree-optimization/85863
4003 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
4004 comparisons when vectype is specified.
4005 (vectorizable_condition): Do not specify vectype for
4006 vect_is_simple_cond when SLP vectorizing.
4007
4008 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
4009
4010 Backport from mainline
4011 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
4012
4013 * config/s390/s390-builtin-types.def: Add void function type.
4014 * config/s390/s390-builtins.def: Use the function type for the
4015 tbeginc builtin.
4016
4017 2018-06-04 Martin Sebor <msebor@redhat.com>
4018
4019 PR c/85623
4020 * calls.c (maybe_warn_nonstring_arg): Use string length to set
4021 or ajust the presumed bound on an operation to avoid unnecessary
4022 warnings.
4023
4024 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
4025
4026 PR target/86003
4027 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
4028 of bits to ignore when comparing architectures.
4029
4030 2018-06-04 Jakub Jelinek <jakub@redhat.com>
4031
4032 PR c++/86025
4033 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
4034
4035 2018-06-01 Bill Schmidt <wschmidt@linux.ibm.com>
4036
4037 PR tree-optimization/85712
4038 Backport from mainline:
4039 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
4040
4041 PR tree-optimization/85712
4042 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
4043 first_interp field.
4044 (alloc_cand_and_find_basis): Initialize first_interp field.
4045 (slsr_process_mul): Modify first_interp field.
4046 (slsr_process_add): Likewise.
4047 (slsr_process_cast): Modify first_interp field for each new
4048 interpretation.
4049 (slsr_process_copy): Likewise.
4050 (dump_candidate): Dump first_interp field.
4051 (replace_mult_candidate): Process all interpretations, not just
4052 subsequent ones.
4053 (replace_rhs_if_not_dup): Likewise.
4054 (replace_one_candidate): Likewise.
4055
4056 Backport from mainline:
4057 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
4058
4059 PR tree-optimization/85712
4060 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
4061 this candidate has already been replaced in-situ by a copy.
4062
4063 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
4064
4065 PR target/85950
4066 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
4067 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
4068 sequence.
4069 (sse4_1_round<mode>2): Use nonimmediate_operand
4070 for operand 1 predicate.
4071
4072 2018-05-31 Jakub Jelinek <jakub@redhat.com>
4073
4074 PR target/85984
4075 * bb-reorder.c (pass_partition_blocks::gate): Return false for
4076 functions with naked attribute.
4077
4078 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
4079
4080 PR target/85829
4081 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
4082 and movx for Haswell.
4083
4084 2018-05-30 Jakub Jelinek <jakub@redhat.com>
4085
4086 Backported from mainline
4087 2018-05-14 Jakub Jelinek <jakub@redhat.com>
4088
4089 PR target/85756
4090 * config/i386/i386.md: Disallow non-commutative arithmetics in
4091 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
4092 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
4093 in the peephole2 before it.
4094
4095 2018-05-08 Jakub Jelinek <jakub@redhat.com>
4096
4097 PR target/85683
4098 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
4099 after cmpelim optimization.
4100
4101 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
4102
4103 Backport from mainline
4104 2018-05-26 H.J. Lu <hongjiu.lu@intel.com>
4105
4106 PR target/85900
4107 PR target/85345
4108 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
4109
4110 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
4111
4112 PR target/85900
4113 PR target/85345
4114 * varasm.c (assemble_alias): Check ifunc_resolver only on
4115 FUNCTION_DECL.
4116
4117 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
4118
4119 PR target/85345
4120 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
4121 attribute.
4122 (cgraph_node::create_alias): Likewise.
4123 (cgraph_node::get_availability): Check ifunc_resolver instead
4124 of looking up ifunc attribute.
4125 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
4126 * varasm.c (do_assemble_alias): Likewise.
4127 (assemble_alias): Likewise.
4128 (default_binds_local_p_3): Likewise.
4129 * cgraph.h (cgraph_node): Add ifunc_resolver.
4130 (cgraph_node::only_called_directly_or_aliased_p): Return false
4131 for IFUNC resolver.
4132 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
4133 attribute.
4134 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
4135 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
4136 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
4137 instead of looking up ifunc attribute.
4138
4139 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
4140
4141 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
4142
4143 2018-05-25 Richard Biener <rguenther@suse.de>
4144
4145 PR c++/85912
4146 * tree-dump.c (dequeue_and_dump): Remove access to removed
4147 operand 2 of a SWITCH_EXPR.
4148
4149 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
4150
4151 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
4152 Add {q} suffix to insn mnemonic.
4153
4154 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
4155
4156 PR target/85903
4157 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
4158 when memory input operand is handled.
4159
4160 2018-05-23 Bin Cheng <bin.cheng@arm.com>
4161
4162 Backport from mainline
4163 2018-05-17 Bin Cheng <bin.cheng@arm.com>
4164 Richard Biener <rguenther@suse.de>
4165
4166 PR tree-optimization/85793
4167 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
4168 for VMAT_ELEMENTWISE.
4169
4170 2018-05-23 Richard Biener <rguenther@suse.de>
4171
4172 PR middle-end/85874
4173 * tree-data-ref.c (create_runtime_alias_checks): Defer
4174 and ignore overflow warnings.
4175
4176 2018-05-23 Martin Liska <mliska@suse.cz>
4177
4178 Backport from mainline
4179 2018-05-23 Yury Gribov <tetra2005@gmail.com>
4180
4181 PR tree-optimization/85822
4182 * tree-vrp.c (is_masked_range_test): Fix handling of negative
4183 constants.
4184
4185 2018-05-23 Martin Liska <mliska@suse.cz>
4186
4187 Backport from mainline
4188 2018-05-11 Martin Liska <mliska@suse.cz>
4189
4190 PR sanitizer/85556
4191 * doc/extend.texi: Document LLVM style format for no_sanitize
4192 attribute.
4193
4194 2018-05-22 Martin Sebor <msebor@redhat.com>
4195
4196 PR middle-end/85643
4197 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
4198
4199 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
4200
4201 PR tree-optimization/85814
4202 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
4203 a null return from get_strinfo when unsharing the next
4204 strinfo in the chain.
4205
4206 2018-05-21 Pat Haugen <pthaugen@us.ibm.com>
4207
4208 Backport from mainline
4209 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
4210 Segher Boessenkool <segher@kernel.crashing.org>
4211
4212 PR target/85698
4213 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest operand.
4214
4215 2018-05-18 Toon Moene <toon@moene.org>
4216
4217 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
4218 directly after that of -floop-interchange. Indicate that both
4219 options are enabled by default when specifying -O3.
4220
4221 2018-05-11 Martin Jambor <mjambor@suse.cz>
4222
4223 PR ipa/85655
4224 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
4225 single const.
4226
4227 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
4228
4229 PR target/85733
4230 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
4231
4232 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
4233
4234 PR target/85606
4235 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
4236 equivalent.
4237 (cortex-m0): Use armv6s-m isa.
4238 (cortex-m0plus): Likewise.
4239 (cortex-m1): Likewise.
4240 (cortex-m0.small-multiply): Likewise.
4241 (cortex-m0plus.small-multiply): Likewise.
4242 (cortex-m1.small-multiply): Likewise.
4243
4244 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
4245
4246 PR rtl-optimization/85638
4247 * bb-reorder.c: Include common/common-target.h.
4248 (create_forwarder_block): New function extracted from...
4249 (fix_up_crossing_landing_pad): ...here. Rename into...
4250 (dw2_fix_up_crossing_landing_pad): ...this.
4251 (sjlj_fix_up_crossing_landing_pad): New function.
4252 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
4253 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
4254 from both partitions and exit the loop after one iteration.
4255
4256 2018-05-08 Richard Biener <rguenther@suse.de>
4257
4258 Backport from mainline
4259 2018-05-04 Richard Biener <rguenther@suse.de>
4260
4261 PR middle-end/85588
4262 * fold-const.c (negate_expr_p): Restrict negation of operand
4263 zero of a division to when we know that can happen without
4264 overflow.
4265 (fold_negate_expr_1): Likewise.
4266
4267 2018-05-03 Richard Biener <rguenther@suse.de>
4268
4269 PR tree-optimization/85615
4270 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
4271 to loops not nested in BBs loop father to avoid creating multi-entry
4272 loops.
4273
4274 2018-05-02 Richard Biener <rguenther@suse.de>
4275
4276 PR middle-end/85567
4277 * gimplify.c (gimplify_save_expr): When in SSA form allow
4278 SAVE_EXPRs to compute to SSA vars.
4279
4280 2018-05-02 Richard Biener <rguenther@suse.de>
4281
4282 PR tree-optimization/85597
4283 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
4284 do not use split vect_get_vec_defs call but call vect_get_slp_defs
4285 directly.
4286
4287 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
4288
4289 PR target/85658
4290 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
4291 (check_arch): Likewise.
4292 (check_fpu): Return the result rather than printing it.
4293 (end arch): Fix operator precedence.
4294 (end cpu): Likewise.
4295 (END): Print the result from check_fpu.
4296
4297 2018-05-08 Richard Biener <rguenther@suse.de>
4298
4299 Backport from mainline
4300 2018-05-04 Richard Biener <rguenther@suse.de>
4301
4302 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
4303 * gimple-ssa-store-merging.c
4304 (imm_store_chain_info::output_merged_store): Remove redundant create,
4305 release split_store vector contents on failure.
4306 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
4307 scalar stmt vector on cache hit.
4308
4309 2018-05-04 Richard Biener <rguenther@suse.de>
4310
4311 PR middle-end/85627
4312 * tree-complex.c (tree_lower_complex): Handle removed blocks.
4313
4314 2018-05-07 Chung-Ju Wu <jasonwucj@gmail.com>
4315
4316 Backport from mainline.
4317 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
4318
4319 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
4320 GET_MODE_MASK before any checking.
4321 (nds32_can_use_bset_p): Likewise.
4322 (nds32_can_use_btgl_p): Likewise.
4323
4324 2018-05-07 Chung-Ju Wu <jasonwucj@gmail.com>
4325
4326 Backport from mainline.
4327 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
4328
4329 * config/nds32/nds32-doubleword.md: New define_split pattern for
4330 illegal register number.
4331
4332 2018-05-07 Chung-Ju Wu <jasonwucj@gmail.com>
4333
4334 Backport from mainline.
4335 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
4336
4337 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
4338
4339 2018-05-07 Chung-Ju Wu <jasonwucj@gmail.com>
4340
4341 Backport from mainline.
4342 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
4343
4344 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
4345
4346 2018-05-06 Jakub Jelinek <jakub@redhat.com>
4347
4348 PR c++/85659
4349 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
4350 the type is addressable. Don't force op into register if it has
4351 BLKmode.
4352
4353 2018-05-04 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4354
4355 Backport from trunk.
4356 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4357
4358 PR target/85512
4359 * config/aarch64/constraints.md (Usg): Limit to 31.
4360 (Usj): Limit to 63.
4361
4362 2018-05-02 Jakub Jelinek <jakub@redhat.com>
4363
4364 * BASE-VER: Set to 8.1.1.
4365
4366 2018-05-02 Release Manager
4367
4368 * GCC 8.1.0 released.
4369
4370 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
4371
4372 PR tree-optimization/85586
4373 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
4374 exit early for statements in the same group if the accesses are
4375 not strided.
4376
4377 2018-05-01 Jakub Jelinek <jakub@redhat.com>
4378
4379 PR web/85578
4380 * doc/install.texi2html: Replace _002d with - and _002a with * in
4381 generated html files using sed.
4382
4383 2018-04-27 Martin Jambor <mjambor@suse.cz>
4384
4385 PR ipa/85549
4386 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
4387 the jump function allows for passing through aggregate values.
4388
4389 2018-04-27 Jeff Law <law@redhat.com>
4390
4391 * config.gcc: Mark tile* targets as deprecated/obsolete.
4392
4393 2018-04-27 Jakub Jelinek <jakub@redhat.com>
4394
4395 PR tree-optimization/85529
4396 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
4397 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
4398 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
4399 zero extension or masking of the MSB bit.
4400 (optimize_range_tests): Add FIRST_BB argument, pass it through
4401 to optimize_range_tests_var_bound.
4402 (maybe_optimize_range_tests, reassociate_bb): Adjust
4403 optimize_range_tests callers.
4404
4405 2018-04-26 Richard Biener <rguenther@suse.de>
4406 Jakub Jelinek <jakub@redhat.com>
4407
4408 * cgraph.h (symbol_table): Just declare debug method here.
4409 * symtab.c (symbol_table::debug): Define.
4410
4411 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
4412
4413 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
4414
4415 2018-04-25 H.J. Lu <hongjiu.lu@intel.com>
4416
4417 Backport from mainline
4418 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
4419
4420 PR target/85473
4421 * config/i386/i386.c (ix86_expand_builtin): Change memory
4422 operand to XI, extend p0 to Pmode.
4423 * config/i386/i386.md: Change unspec volatile and operand
4424 1 mode to XI, change operand 0 mode to P.
4425
4426 2018-04-25 Jakub Jelinek <jakub@redhat.com>
4427
4428 * DEV-PHASE: Set to prerelease.
4429
4430 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
4431
4432 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
4433 in __abskf2 and __powikf2.
4434
4435 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4436
4437 PR target/85512
4438 * config/aarch64/constraints.md (Usg, Usj): New constraints.
4439 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
4440 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
4441 Use the above on operand 2. Reindent.
4442 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
4443
4444 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
4445
4446 PR target/85485
4447 * common/config/i386/i386-common.c (ix86_handle_option): Don't
4448 handle OPT_mcet.
4449 * config/i386/i386.opt (mcet): Removed.
4450 * doc/install.texi: Remove -mcet documentation.
4451 * doc/invoke.texi: Likewise.
4452
4453 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
4454
4455 PR target/85485
4456 * doc/install.texi: Remove -mcet from bootstrap-cet.
4457
4458 2018-04-24 Jakub Jelinek <jakub@redhat.com>
4459
4460 PR target/85511
4461 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
4462 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
4463 if TARGET_64BIT.
4464
4465 PR target/85503
4466 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
4467 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
4468 containing a CONST_VECTOR.
4469
4470 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
4471
4472 * doc/install.texi: Update newlib dependency for nvptx.
4473
4474 2018-04-24 Jakub Jelinek <jakub@redhat.com>
4475
4476 PR target/85508
4477 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
4478 instead of INTVAL when shifting x left.
4479
4480 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
4481
4482 PR tree-optimization/85478
4483 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
4484 vect_grouped_store_supported for single element vectors.
4485
4486 2018-04-24 Richard Biener <rguenther@suse.de>
4487
4488 PR target/85491
4489 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
4490 load cost increase to the case of non-constant step.
4491
4492 2018-04-24 Jakub Jelinek <jakub@redhat.com>
4493
4494 PR target/84828
4495 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
4496 destination if any_malformed_asm.
4497
4498 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
4499
4500 PR middle-end/85496
4501 * expr.c (store_field): In the bitfield case, if the value comes from
4502 a function call and is returned in registers by means of a PARALLEL,
4503 do not change the mode of the temporary unless BLKmode and VOIDmode.
4504
4505 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
4506
4507 PR rtl-optimization/85423
4508 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
4509 dependencies to debug insns when the previous insn is non-debug.
4510
4511 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
4512
4513 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
4514 enums into a single definition.
4515 (fls): Fix predicates and printing.
4516 (seti): Likewise.
4517
4518 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
4519
4520 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
4521 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
4522 and short u6 immediate.
4523 (check_if_valid_sleep_operand): Remove.
4524 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
4525
4526 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4527
4528 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
4529 flag_always_save_lp condition.
4530 * config/nds32/nds32.opt (malways-save-lp): New option.
4531
4532 2018-04-22 Shiva Chen <shiva0217@gmail.com>
4533
4534 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
4535 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
4536 * config/nds32/nds32.h
4537 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
4538 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
4539
4540 2018-04-22 Shiva Chen <shiva0217@gmail.com>
4541
4542 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
4543 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
4544
4545 2018-04-22 Shiva Chen <shiva0217@gmail.com>
4546 Chung-Ju Wu <jasonwucj@gmail.com>
4547
4548 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
4549 Declare.
4550 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
4551 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
4552
4553 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4554
4555 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
4556
4557 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4558
4559 * config/nds32/nds32-protos.h (nds32_data_alignment,
4560 nds32_local_alignment): Declare.
4561 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
4562 nds32_local_alignment): New functions.
4563 (TARGET_CONSTANT_ALIGNMENT): Define.
4564 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
4565
4566 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4567
4568 * config/nds32/nds32.c
4569 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
4570 (TARGET_MODES_TIEABLE_P): Likewise.
4571
4572 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4573
4574 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
4575 level Ofast and Og.
4576
4577 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
4578 Chung-Ju Wu <jasonwucj@gmail.com>
4579
4580 * config/nds32/constants.md (unspec_volatile_element): Add enum values
4581 for unaligned access.
4582 * config/nds32/nds32-intrinsic.c: Implementation of expanding
4583 unaligned access.
4584 * config/nds32/nds32-intrinsic.md: Likewise.
4585 * config/nds32/nds32_intrinsic.h: Likewise.
4586 * config/nds32/nds32.h (nds32_builtins): Likewise.
4587 * config/nds32/nds32.opt (munaligned-access): New option.
4588 * config/nds32/nds32.c (nds32_asm_file_start): Display
4589 flag_unaligned_access status.
4590
4591 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
4592
4593 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
4594 -mno-relax is present.
4595 * config/riscv/linux.h (LINK_SPEC): Ditto.
4596
4597 2018-04-20 Martin Sebor <msebor@redhat.com>
4598
4599 PR c/85365
4600 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
4601 for null pointers.
4602 (gimple_fold_builtin_stxcpy_chk): Same.
4603 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
4604
4605 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
4606
4607 PR target/85456
4608 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
4609 __powikf2 when long double is IEEE 128-bit.
4610
4611 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
4612
4613 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
4614 step to make sure stack always aligned.
4615
4616 2018-04-20 Carl Love <cel@us.ibm.com>
4617
4618 PR target/83402
4619 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
4620 size check for arg0.
4621
4622 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
4623 Tom de Vries <tom@codesourcery.com>
4624
4625 PR target/85445
4626 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
4627 Emit insns for calls too.
4628 (nvptx_find_par): Always look for worker-level predecessor insn.
4629 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
4630 calls.
4631 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
4632 (nvptx_process_pars): Propagate frames for calls.
4633
4634 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
4635
4636 PR target/85469
4637 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
4638 Removed.
4639 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
4640 (ix86_handle_option): Don't handle OPT_mibt.
4641 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
4642 __SHSTK__.
4643 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
4644 has_ibt and ibt.
4645 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
4646 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
4647 (ix86_target_macros): Define __CET__ with flag_cf_protection
4648 for -fcf-protection.
4649 * config/i386/i386.c (isa2_opts): Remove -mibt.
4650 * config/i386/i386.h (TARGET_IBT): Removed.
4651 (TARGET_IBT_P): Likewise.
4652 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
4653 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
4654 * config/i386/i386.opt (mcet): Update help message.
4655 (mshstk): Likewise.
4656 (mibt): Removed.
4657 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
4658 -mcet as an alias for -mshstk.
4659
4660 2018-04-20 Richard Biener <rguenther@suse.de>
4661
4662 PR middle-end/85475
4663 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
4664 complexity by forcing a single use of the multiply operand.
4665
4666 2018-04-20 Martin Jambor <mjambor@suse.cz>
4667
4668 ipa/85449
4669 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
4670 recursion dependency to only apply to non-clones.
4671
4672 2018-04-20 Martin Jambor <mjambor@suse.cz>
4673
4674 ipa/85447
4675 * ipa-cp.c (create_specialized_node): Check that clones of
4676 self-recursive edges exist during IPA-CP.
4677
4678 2018-04-19 Toon Moene <toon@moene.org>
4679
4680 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
4681 by -O3.
4682
4683 2018-04-19 Jakub Jelinek <jakub@redhat.com>
4684
4685 PR tree-optimization/85467
4686 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
4687 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
4688 VECTOR_CST element to type.
4689
4690 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
4691
4692 PR target/85397
4693 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
4694 * config/i386/i386.md (builtin_setjmp_setup): Removed.
4695 (builtin_longjmp): Likewise.
4696 (save_stack_nonlocal): New pattern.
4697 (restore_stack_nonlocal): Likewise.
4698
4699 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
4700
4701 PR target/85404
4702 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
4703 Replace ASM_OUTPUT_LABEL with fprintf.
4704
4705 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
4706
4707 PR target/85417
4708 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
4709 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
4710 * config/i386/i386-c.c (ix86_target_macros_internal): Also
4711 define __IBT__ and __SHSTK__ for -fcf-protection.
4712 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
4713 TARGET_IBT.
4714 (ix86_trampoline_init): Likewise.
4715 (x86_output_mi_thunk): Likewise.
4716 (ix86_notrack_prefixed_insn_p): Likewise.
4717 (ix86_option_override_internal): Don't disallow -fcf-protection.
4718 * config/i386/i386.md (rdssp<mode>): Also enable for
4719 -fcf-protection.
4720 (incssp<mode>): Likewise.
4721 (nop_endbr): Likewise.
4722 * config/i386/i386.opt (mcet): Change help message to built-in
4723 functions only.
4724 (mibt): Likewise.
4725 (mshstk): Likewise.
4726 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
4727 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
4728 enable CET built-in functions.
4729
4730 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
4731
4732 * common/config/i386/i386-common.c
4733 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
4734 OPTION_MASK_ISA_MOVDIRI_UNSET,
4735 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
4736 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
4737 * config.gcc (movdirintrin.h): New header.
4738 * config/i386/cpuid.h (bit_MOVDIRI,
4739 bit_MOVDIR64B): New bits.
4740 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
4741 and -mmvodir64b.
4742 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
4743 (VOID, PVOID, PCVOID)): New function types.
4744 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
4745 __builtin_ia32_directstoreu_u64,
4746 __builtin_ia32_movdir64b): New builtins.
4747 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
4748 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
4749 and -mmovdiri.
4750 (ix86_valid_target_attribute_inner_p): Ditto.
4751 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
4752 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
4753 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
4754 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
4755 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
4756 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
4757 (movdiri<mode>, movdir64b_<mode>): New.
4758 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
4759 * config/i386/immintrin.h: Include movdirintrin.h.
4760 * config/i386/movdirintrin.h: New file.
4761 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
4762
4763 2018-04-19 Richard Biener <rguenther@suse.de>
4764
4765 PR middle-end/85455
4766 * cfg.c (clear_bb_flags): When loop state says we have
4767 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
4768
4769 2018-04-19 Richard Biener <rguenther@suse.de>
4770
4771 PR tree-optimization/84737
4772 * tree-vect-data-refs.c (vect_copy_ref_info): New function
4773 copying restrict info.
4774 (vect_setup_realignment): Use it.
4775 * tree-vectorizer.h (vect_copy_ref_info): Declare.
4776 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
4777 the first DR to all generated stores.
4778 (vectorizable_load): Likewise for loads.
4779
4780 2018-04-19 Jakub Jelinek <jakub@redhat.com>
4781
4782 PR tree-optimization/85446
4783 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
4784 the integral and pointer types to have the same precision.
4785
4786 * doc/install.texi: Document --disable-cet being the default and
4787 --enable-cet=auto.
4788
4789 2018-04-18 Martin Liska <mliska@suse.cz>
4790
4791 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
4792 style.
4793
4794 2018-04-18 Martin Liska <mliska@suse.cz>
4795
4796 Revert
4797 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
4798
4799 PR ipa/83983
4800 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
4801 arguments if they are comparable.
4802
4803 2018-04-18 Martin Liska <mliska@suse.cz>
4804
4805 Revert
4806 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
4807
4808 PR lto/84805
4809 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
4810 incomplete types.
4811
4812 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
4813
4814 PR target/85388
4815 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
4816 ENDBR after calling __morestack.
4817
4818 2018-04-18 David Malcolm <dmalcolm@redhat.com>
4819
4820 PR jit/85384
4821 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
4822 by using gcc_base_ver to generate a gcc_driver_version, and use
4823 it when generating GCC_DRIVER_NAME.
4824 * configure: Regenerate.
4825
4826 2018-04-18 Jakub Jelinek <jakub@redhat.com>
4827
4828 PR target/81084
4829 * config.gcc: Obsolete powerpc*-*-*spe*.
4830
4831 2018-04-17 Jakub Jelinek <jakub@redhat.com>
4832
4833 PR debug/84637
4834 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
4835 (stabstr_D): Change type of unum from unsigned int to
4836 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
4837 type.
4838
4839 2018-04-17 Jim Wilson <jimw@sifive.com>
4840
4841 PR 84856
4842 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
4843 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
4844 Set arg_pointer_offset after using pretend_args_size.
4845
4846 2018-04-17 Jakub Jelinek <jakub@redhat.com>
4847
4848 PR rtl-optimization/85431
4849 * dse.c (record_store): Ignore zero width stores.
4850
4851 PR sanitizer/85230
4852 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
4853 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
4854 __builtin_stack_restore rather than after it.
4855 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
4856 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
4857 argument instead of virtual_dynamic_stack_rtx.
4858
4859 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
4860
4861 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
4862 New prototype.
4863 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
4864 Add note to error message to explain internal mapping of overloaded
4865 built-in function name to non-overloaded built-in function name.
4866 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
4867 function.
4868
4869 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
4870
4871 PR target/85424
4872 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
4873 where the inputs overlap with the output.
4874
4875 2018-04-17 Jakub Jelinek <jakub@redhat.com>
4876
4877 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
4878 (=v, v) alternative and explicit "memory" attribute.
4879 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
4880 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
4881 attributes.
4882 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
4883 "sselog1" type instead of "sselog".
4884 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
4885 "sselog". Remove explicit "memory" attribute.
4886 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
4887 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
4888 attributes.
4889 (vec_extract_hi_v32hi): Merge all alternatives into one, use
4890 "sselog1" type instead of "sselog". Remove explicit "memory"
4891 attribute.
4892 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
4893 use "sselog1" type instead of "sselog". Remove explicit "memory"
4894 attribute.
4895 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
4896 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
4897 attributes.
4898 (vec_extract_hi_v64qi): Merge all alternatives into one, use
4899 "sselog1" type instead of "sselog". Remove explicit "memory"
4900 attribute.
4901 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
4902 use "sselog1" type instead of "sselog". Remove explicit "memory"
4903 attribute.
4904
4905 PR target/85430
4906 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
4907
4908 PR middle-end/85414
4909 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
4910 on a SUBREG.
4911
4912 2018-04-17 Martin Jambor <mjambor@suse.cz>
4913
4914 PR ipa/85421
4915 * ipa-cp.c (create_specialized_node): Call
4916 expand_all_artificial_thunks if necessary.
4917
4918 2018-04-17 Martin Liska <mliska@suse.cz>
4919
4920 PR lto/85405
4921 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
4922 in message, remote space in between '_G' and '('.
4923
4924 2018-04-17 Jakub Jelinek <jakub@redhat.com>
4925
4926 PR target/85281
4927 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
4928 avx512f_vmcmp<mode>3<round_saeonly_name>,
4929 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
4930 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
4931 avx512f_rndscale<mode><round_saeonly_name>,
4932 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
4933 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
4934 Use %<iptr>2 instead of %2 for -masm=intel.
4935 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
4936 avx512f_vcvttss2usi<round_saeonly_name>,
4937 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
4938 -masm=intel.
4939 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
4940 avx512f_vcvttsd2usi<round_saeonly_name>,
4941 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
4942 Use %q1 instead of %1 for -masm=intel.
4943 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
4944 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
4945 of %3 for -masm=intel.
4946 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
4947 -masm=intel.
4948 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
4949 -masm=intel.
4950 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
4951 -masm=intel.
4952 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
4953 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
4954 %g1.
4955 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
4956 -masm=intel.
4957 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
4958 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
4959 %g1 and one with %0 and %1.
4960 (avx512er_vmrcp28<mode><round_saeonly_name>,
4961 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
4962 %1 for -masm=intel.
4963 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
4964 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
4965 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
4966 of %0 and %{%4%} for -masm=intel.
4967 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
4968 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
4969 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
4970 order of %0 and %{%5%}%{z%} for -masm=intel.
4971
4972 2018-04-17 Jan Hubicka <jh@suse.cz>
4973
4974 PR lto/85405
4975 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
4976
4977 2018-04-17 Martin Liska <mliska@suse.cz>
4978
4979 PR ipa/85329
4980 * multiple_target.c (create_dispatcher_calls): Set apostrophes
4981 for target_clone error message. Make default implementation
4982 clone to be a local declaration.
4983 (separate_attrs): Add new argument and check for an empty
4984 string.
4985 (expand_target_clones): Handle it.
4986 (ipa_target_clone): Make redirection just for target_clones
4987 functions.
4988
4989 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
4990 Tom de Vries <tom@codesourcery.com>
4991
4992 PR middle-end/84955
4993 * omp-expand.c (expand_oacc_for): Add dummy false branch for
4994 tiled basic blocks without omp continue statements.
4995
4996 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
4997
4998 PR target/83660
4999 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
5000 vec_extract expression as having side effects to make sure it gets
5001 a cleanup point.
5002
5003 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
5004
5005 PR target/85403
5006 * config/i386/i386.c (get_builtin_code_for_version): Check
5007 error_mark_node.
5008
5009 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
5010
5011 PR target/84331
5012 * gcc/config.gcc: Support "skylake".
5013 * gcc/config/i386/i386-c.c (ix86_target_macros_internal): Handle
5014 PROCESSOR_SKYLAKE.
5015 * gcc/config/i386/i386.c (m_SKYLAKE): Define.
5016 (processor_target_table): Add "skylake".
5017 (ix86_option_override_internal): Add "skylake".
5018 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
5019 PROCESSOR_CANNONLAKE.
5020 (get_builtin_code_for_version): Fix priority for
5021 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
5022 PROCESSOR_SKYLAKE-AVX512.
5023 * gcc/config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
5024 (processor_type): Add PROCESSOR_SKYLAKE.
5025
5026 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
5027 Jason Merrill <jason@redhat.com>
5028
5029 PR c++/85112
5030 * convert.c (convert_to_integer_1): Use direct recursion for
5031 enumeral types and types with a precision less than the number
5032 of bits in their mode.
5033
5034 2018-04-16 Julia Koval <julia.koval@intel.com>
5035
5036 PR target/84413
5037 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
5038 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
5039
5040 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
5041
5042 PR target/85293
5043 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
5044 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
5045 and -mno-direct-move.
5046
5047 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
5048
5049 PR target/83402
5050 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
5051 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
5052 Ensure negative shifts result in {0}.
5053
5054 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
5055
5056 PR rtl-optimization/79916
5057 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
5058 regs (if any) to define how to gnerate SD moves when LRA is in
5059 progress.
5060
5061 2018-04-13 Jakub Jelinek <jakub@redhat.com>
5062
5063 PR rtl-optimization/85393
5064 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
5065 * except.c (expand_dw2_landing_pad_for_region): Make static.
5066 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
5067 a label and unconditional jump to old_bb, rather than
5068 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
5069 basic block.
5070
5071 PR rtl-optimization/85376
5072 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
5073 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
5074 instead of a specific value.
5075
5076 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
5077 Bin Cheng <bin.cheng@arm.com>
5078
5079 PR tree-optimization/82965
5080 PR tree-optimization/83991
5081 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
5082 by_profile_only parameter.
5083 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
5084 information if the loop was predicted to iterate too many times.
5085 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
5086
5087 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
5088
5089 PR lto/71991
5090 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
5091 always inline.
5092
5093 2018-04-13 Martin Liska <mliska@suse.cz>
5094 Jakub Jelinek <jakub@redhat.com>
5095
5096 PR middle-end/81657
5097 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
5098 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
5099 * builtins.c (expand_builtin_memory_copy_args): Use
5100 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
5101 handle dest_addr == pc_rtx.
5102
5103 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
5104
5105 PR target/85291
5106 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
5107 asked to not generate direct moves.
5108 (fix_trunc<mode>si2_stfiwx): Similar.
5109 (fix_trunc<mode>si2_internal): Similar.
5110
5111 2018-04-12 Jakub Jelinek <jakub@redhat.com>
5112
5113 PR debug/83157
5114 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
5115 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
5116 lookup if dest in some wider mode is known to be const0_rtx and
5117 if so, record permanent equivalence for it to be ZERO_EXTEND of
5118 the narrower mode destination.
5119
5120 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
5121
5122 * lto-streamer-out.c (output_function): Revert 259346.
5123 * omp-expand.c (expand_oacc_for): Likewise.
5124
5125 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
5126
5127 PR rtl-optimization/85354
5128 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
5129 * sel-sched.c (sel_global_init): ... here.
5130
5131 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
5132
5133 PR target/85238
5134 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
5135 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
5136 mode for PE-COFF targets.
5137 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
5138 (i386_pe_asm_lto_end): Likewise.
5139 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
5140 (TARGET_ASM_LTO_END): Likewise.
5141 * config/i386/winnt.c (saved_debug_info_level): New static variable.
5142 (i386_pe_asm_lto_start): New function.
5143 (i386_pe_asm_lto_end): Likewise.
5144
5145 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
5146 Richard Biener <rguenther@suse.de>
5147
5148 PR middle-end/84955
5149 * lto-streamer-out.c (output_function): Fix CFG loop state before
5150 streaming out.
5151 * omp-expand.c (expand_oacc_for): Handle calls to internal
5152 functions like regular functions.
5153
5154 2018-04-12 Richard Biener <rguenther@suse.de>
5155
5156 PR lto/85371
5157 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
5158 for the early LTO debug to properly generate references to it
5159 during DIE emission. Do not re-use that for the skeleton for
5160 split-dwarf.
5161 (dwarf2out_early_finish): Likewise.
5162
5163 2018-04-12 Jakub Jelinek <jakub@redhat.com>
5164
5165 PR target/85328
5166 * config/i386/sse.md
5167 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
5168 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
5169 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
5170 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
5171 and output is a reg, avoid creating invalid lowpart subreg, but
5172 instead split into a 512-bit move. Don't split if not AVX512VL,
5173 input is xmm16+ reg and output is a mem.
5174 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
5175 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
5176 xmm16+ reg and output is a mem.
5177
5178 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
5179
5180 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
5181 also for flag_dwarf2_cfi_asm.
5182
5183 2018-04-12 Jakub Jelinek <jakub@redhat.com>
5184
5185 PR rtl-optimization/85342
5186 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
5187 a bool scalar var inside of the loop instead. Don't try to update
5188 recog_data.operand after failed apply_change_group.
5189
5190 2018-04-12 Tom de Vries <tom@codesourcery.com>
5191
5192 PR target/85296
5193 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
5194 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
5195 array with flexible array member as array without given dimension.
5196 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
5197 argument for undefined param to true.
5198
5199 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
5200
5201 PR target/85321
5202 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
5203 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
5204 from PowerPC section.
5205 * config/rs6000/sysv4.opt (mcall-): Improve help text.
5206 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
5207 help text that is too long.
5208 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
5209 help text that is too long.
5210 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
5211 help text that is too long.
5212
5213 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
5214
5215 * config/alpha/alpha.md (stack_probe_internal): Rename
5216 from "probe_stack". Update all callers.
5217
5218 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
5219
5220 PR rtl-optimization/84566
5221 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
5222 sched_macro_fuse_insns.
5223
5224 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
5225
5226 PR target/84301
5227 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
5228 (compute_block_dependences): ... from here.
5229
5230 2018-04-11 Jakub Jelinek <jakub@redhat.com>
5231
5232 PR tree-optimization/85331
5233 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
5234 from int to HOST_WIDE_INT.
5235
5236 2018-04-11 Martin Jambor <mjambor@suse.cz>
5237
5238 PR ipa/84149
5239 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
5240 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
5241 not the same as the source val.
5242 (cgraph_edge_brings_value_p): New parameter.
5243 (gather_edges_for_value): Pass destination value to
5244 cgraph_edge_brings_value_p.
5245 (perhaps_add_new_callers): Likewise.
5246 (get_info_about_necessary_edges): Likewise and exclude values brought
5247 only by self-recursive edges.
5248 (create_specialized_node): Redirect only clones of self-calling edges.
5249 (+self_recursive_pass_through_p): New function.
5250 (find_more_scalar_values_for_callers_subset): Use it.
5251 (find_aggregate_values_for_callers_subset): Likewise.
5252 (known_aggs_to_agg_replacement_list): Removed.
5253 (decide_whether_version_node): Re-calculate known constants for all
5254 remaining context clones.
5255
5256 2018-04-11 Richard Biener <rguenther@suse.de>
5257
5258 PR lto/85339
5259 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
5260 from early DWARF output.
5261 (dwarf2out_early_finish): Output line info unconditionally into
5262 early DWARF and add reference to it.
5263
5264 2018-04-11 Jakub Jelinek <jakub@redhat.com>
5265
5266 PR target/85281
5267 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
5268 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
5269 other than V2DFmode using iptr mode attribute.
5270 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
5271
5272 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
5273
5274 PR rtl-optimization/84659
5275 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
5276
5277 2018-04-11 Jakub Jelinek <jakub@redhat.com>
5278
5279 PR debug/85302
5280 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
5281 SIZEP is NULL.
5282 (output_loc_list): Pass address of a dummy size variable even in the
5283 locview handling loop.
5284 (index_location_lists): Add comment on why skip_loc_list_entry can't
5285 call size_of_locs.
5286
5287 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
5288
5289 PR target/85261
5290 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
5291 into register.
5292
5293 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
5294
5295 PR target/85321
5296 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
5297 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
5298 and -mstring-compare-inline-limit.
5299
5300 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
5301
5302 PR target/85287
5303 * gcc/config/rs6000/rs6000.md (allocate_stack): Put the residual size
5304 for stack clash protection in a register whenever we need it to be in
5305 a register.
5306
5307 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
5308
5309 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
5310 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
5311
5312 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
5313
5314 PR target/85321
5315 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
5316 the help text.
5317 (mlong-double-): Ditto.
5318 * config/rs6000/sysv4.opt (msdata=): Ditto.
5319 (mtls-size=): Ditto.
5320
5321 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
5322
5323 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
5324 erroneous entries for
5325 "vector int vec_ldl (int, long int *)", and
5326 "vector unsigned int vec_ldl (int, unsigned long int *)".
5327 Add comments and entries for
5328 "vector bool char vec_ldl (int, bool char *)",
5329 "vector bool short vec_ldl (int, bool short *)",
5330 "vector bool int vec_ldl (int, bool int *)",
5331 "vector bool long long vec_ldl (int, bool long long *)",
5332 "vector pixel vec_ldl (int, pixel *)",
5333 "vector long long vec_ldl (int, long long *)",
5334 "vector unsigned long long vec_ldl (int, unsigned long long *)".
5335 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
5336 type tree bool_long_long_type_node and correct definition of
5337 bool_V2DI_type_node to make reference to this new type tree.
5338 (rs6000_mangle_type): Replace erroneous reference to
5339 bool_long_type_node with bool_long_long_type_node.
5340 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
5341 comments to emphasize sign distinctions for char and int types and
5342 replace RS6000_BTI_bool_long constant with
5343 RS6000_BTI_bool_long_long constant. Also add comment to restrict
5344 use of RS6000_BTI_pixel.
5345 (bool_long_type_node): Remove this macro definition.
5346 (bool_long_long_type_node): New macro definition
5347
5348 2018-04-10 Jakub Jelinek <jakub@redhat.com>
5349
5350 PR rtl-optimization/85300
5351 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
5352 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
5353 simplify_unary_operation fails.
5354
5355 2018-04-10 Martin Liska <mliska@suse.cz>
5356
5357 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
5358 cgraph_edge and ipa_ref.
5359
5360 2018-04-10 Jakub Jelinek <jakub@redhat.com>
5361
5362 PR target/85177
5363 PR target/85255
5364 * config/i386/sse.md
5365 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
5366 computation of the VEC_MERGE selector from mask.
5367 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
5368 Fix decoding of the VEC_MERGE selector into mask.
5369
5370 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
5371
5372 PR tree-optimization/85286
5373 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
5374
5375 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
5376
5377 * final.c (final_1): Set insn_last_address as well as
5378 insn_current_address.
5379
5380 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5381
5382 PR target/85173
5383 * explow.c (emit_stack_probe): Call validize_mem on memory location
5384 before passing it to gen_probe_stack. Create address operand and
5385 legitimize it for the probe_stack_address case.
5386
5387 2018-04-09 Jan Hubicka <jh@suse.cz>
5388
5389 PR lto/85078
5390 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
5391 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
5392 * tree.c (free_lang_data_in_type): Fix handling of binfos;
5393 walk basetypes.
5394 (free_lang_data): Rebuild type inheritance graph.
5395
5396 2018-04-09 Martin Sebor <msebor@redhat.com>
5397
5398 * invoke.texi (-finline-small-functions): Mention other optimization
5399 options.
5400 (-findirect-inlining, -fpartial-inlining): Same.
5401 (-finline-functions-called-once): Same.
5402 (-freorder-blocks-and-partition): Same.
5403
5404 2018-04-09 Jan Hubicka <jh@suse.cz>
5405
5406 PR rtl/84058
5407 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
5408 jumps; choose last target that matches the criteria (i.e.
5409 no partition changes for non-crossing jumps).
5410 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
5411 support for redirecting crossing jumps to non-crossing.
5412
5413 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
5414
5415 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
5416 also for naked functions.
5417
5418 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
5419
5420 * config/arc/arc.md (add_shift): New pattern.
5421 (add_shift2): Likewise.
5422 (sub_shift): Likewise.
5423 (sub_shift_cmp0_noout): Likewise.
5424 (compare_si_ashiftsi): Likewise.
5425 (xbfu_cmp0_noout): New combine pattern.
5426 (xbfu_cmp0"): Likewise.
5427 (movsi_set_cc_insn): Place the predicable variant first.
5428 (commutative_binary_cmp0_noout): Remove clobber.
5429 (commutative_binary_cmp0): New pattern.
5430 (noncommutative_binary_cmp0): Likewise.
5431 (noncommutative_binary_cmp0_noout): Likewise.
5432 (noncommutative_binary_comparison_result_used): Removed.
5433 (rsub_cmp0): New pattern.
5434 (rsub_cmp0_noout): Likewise.
5435 (extzvsi): Changed, keep only meaningful variants.
5436 (SQH, SEZ): New iterators.
5437 (SQH_postfix): New mode attribute.
5438 (SEZ_prefix): New code attribute.
5439 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
5440 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
5441 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
5442 of numerical value.
5443 (noncommutative_operator): Check the availability of barrel
5444 shifter option.
5445
5446 2018-04-09 Richard Biener <rguenther@suse.de>
5447
5448 PR tree-optimization/85284
5449 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
5450 Only use the niter constraining form of simple_iv when the exit
5451 is always executed.
5452
5453 2018-04-09 Tom de Vries <tom@codesourcery.com>
5454
5455 PR target/84041
5456 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
5457 (define_expand "*memory_barrier"): New define_expand.
5458 (define_insn "memory_barrier"): New insn.
5459
5460 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
5461
5462 PR rtl-optimization/80463
5463 PR rtl-optimization/83972
5464 PR rtl-optimization/83480
5465
5466 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
5467 correct producer for the insn.
5468 (tidy_control_flow): Fixup seqnos in case of debug insns.
5469
5470 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
5471
5472 PR rtl-optimization/83913
5473
5474 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
5475 different sched-times when merging exprs.
5476
5477 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
5478
5479 PR rtl-optimization/83962
5480
5481 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
5482 tidy_fallthru_edge and tidy_control_flow.
5483
5484 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
5485
5486 PR rtl-optimization/83530
5487
5488 * sel-sched.c (force_next_insn): New global variable.
5489 (remove_insn_for_debug): When force_next_insn is true, also leave only
5490 next insn in the ready list.
5491 (sel_sched_region): When the region wasn't scheduled, make another pass
5492 over it with force_next_insn set to 1.
5493
5494 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
5495
5496 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
5497 into tm_file.
5498 * config/nds32/constants.md (unspec_volatile_element): Add enum values
5499 for interrupt control.
5500 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
5501 functions for interrupt control.
5502 * config/nds32/nds32-intrinsic.md: Likewise.
5503 * config/nds32/nds32_intrinsic.h: Likewise.
5504 * config/nds32/nds32.h (nds32_builtins): Likewise.
5505
5506 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
5507
5508 * config/nds32/nds32.c (nds32_init_machine_status,
5509 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
5510 strict_aligned_p field.
5511 (nds32_expand_to_rtl_hook): New function.
5512 (TARGET_EXPAND_TO_RTL_HOOK): Define.
5513 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
5514
5515 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
5516 Chung-Ju Wu <jasonwucj@gmail.com>
5517
5518 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
5519 * config/nds32/nds32-n7.md: New file.
5520 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
5521 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
5522 pipeline.
5523 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
5524 * config/nds32/nds32.md (pipeline_model): Add n7.
5525 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
5526 * config/nds32/pipelines.md: Include n7 settings.
5527
5528 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
5529 Chung-Ju Wu <jasonwucj@gmail.com>
5530
5531 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
5532 * config/nds32/nds32-e8.md: New file.
5533 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
5534 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
5535 pipeline.
5536 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
5537 * config/nds32/nds32.md (pipeline_model): Add e8.
5538 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
5539 * config/nds32/pipelines.md: Include e8 settings.
5540
5541 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
5542 Chung-Ju Wu <jasonwucj@gmail.com>
5543
5544 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
5545 * config/nds32/nds32-n8.md: New file.
5546 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
5547 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
5548 pipeline.
5549 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
5550 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
5551 * config/nds32/nds32.md (pipeline_model): Add n8.
5552 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
5553 * config/nds32/pipelines.md: Include n8 settings.
5554
5555 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
5556 Chung-Ju Wu <jasonwucj@gmail.com>
5557
5558 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
5559 * config/nds32/nds32-n9-2r1w.md: New file.
5560 * config/nds32/nds32-n9-3r2w.md: New file.
5561 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
5562 nds32_register_ports): New or modify for cpu n9.
5563 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
5564 pipeline.
5565 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
5566 * config/nds32/nds32-utils.c: New file.
5567 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
5568 TARGET_MUL_SLOW): Define.
5569 * config/nds32/nds32.md (pipeline_model): New attribute.
5570 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
5571 New options that support cpu n9.
5572 * config/nds32/pipelines.md: Include n9 settings.
5573 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
5574
5575 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
5576
5577 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
5578 information if necessary.
5579 (output_cond_branch_compare_zero): Likewise.
5580 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
5581 (nds32_target_alignment): Refine for alignment.
5582 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
5583 (FUNCTION_BOUNDARY): Modify.
5584 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
5585 align case.
5586 * config/nds32/nds32.opt (malways-align, malign-functions): New.
5587
5588 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
5589
5590 * config/nds32/constants.md (unspec_volatile_element): Add values for
5591 TLB operation and data prefetch.
5592 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
5593 functions for TLB operation and data prefetch.
5594 * config/nds32/nds32-intrinsic.md: Likewise.
5595 * config/nds32/nds32_intrinsic.h: Likewise.
5596 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
5597 (nds32_print_operand): Likewise.
5598 * config/nds32/nds32.h (nds32_builtins): Likewise.
5599
5600 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
5601 Andrew Pinski <pinsika@gcc.gnu.org>
5602
5603 PR middle-end/82976
5604 * match.pd: Use constant_boolean_node of correct type instead of
5605 boolean_true_node or boolean_false_node for simplifying
5606 pointer comparisons to zero.
5607
5608 2018-04-07 Jakub Jelinek <jakub@redhat.com>
5609
5610 PR tree-optimization/80021
5611 * tree.c (verify_type_variant): Make error call in verify_variant_match
5612 translatable and remove final full stop.
5613
5614 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
5615
5616 * config/nds32/constants.md (unspec_volatile_element): Add
5617 UNSPEC_VOLATILE_EH_RETURN.
5618 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
5619 nds32_output_stack_pop): Support dwarf exception handling process.
5620 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
5621 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
5622 exception handling process.
5623 (nds32_compute_stack_frame): Likewise.
5624 (nds32_return_addr_rtx): Likewise.
5625 (nds32_initial_elimination_offset): Likewise.
5626 (nds32_expand_prologue): Likewise.
5627 (nds32_expand_epilogue): Likewise.
5628 (nds32_dynamic_chain_address): New function.
5629 * config/nds32/nds32.h (machine_function): Add fields for dwarf
5630 exception handling.
5631 (DYNAMIC_CHAIN_ADDRESS): Define.
5632 (EH_RETURN_DATA_REGNO): Define.
5633 (EH_RETURN_STACKADJ_RTX): Define.
5634 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
5635 patterns for dwarf exception handling.
5636
5637 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
5638
5639 * config/nds32/nds32.h: Clean up obsolete macros.
5640
5641 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5642
5643 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
5644 Add enum values for particular instructions.
5645 * config/nds32/nds32-intrinsic.c: Implementation of expanding
5646 particular intrinsic functions.
5647 * config/nds32/nds32-intrinsic.md: Likewise.
5648 * config/nds32/nds32_intrinsic.h: Likewise.
5649 * config/nds32/nds32.h (nds32_builtins): Likewise.
5650 * config/nds32/nds32.md (type): Add pbsad and pbsada.
5651 (btst, ave): New patterns for particular instructions.
5652
5653 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5654
5655 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
5656 Add enum values for atomic load/store and memory sync.
5657 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
5658 and memory sync.
5659 * config/nds32/nds32-intrinsic.md: Likewise.
5660 * config/nds32/nds32_intrinsic.h: Likewise.
5661 * config/nds32/nds32.h (nds32_builtins): Likewise.
5662
5663 2018-04-07 Jakub Jelinek <jakub@redhat.com>
5664
5665 PR tree-optimization/85257
5666 * fold-const.c (native_encode_vector): If not all elts could fit
5667 and off is -1, return 0 rather than offset.
5668 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
5669 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
5670 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
5671 adjust buffer in native_interpret_expr call.
5672
5673 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5674
5675 * config/nds32/constants.md (unspec_volatile_element): Add cache
5676 control enum values.
5677 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
5678 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
5679 * config/nds32/nds32.c (nds32_cctl_names): New.
5680 (nds32_print_operand): Handle cache control register names.
5681 * config/nds32/nds32.h (nds32_builtins): New enum values.
5682 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
5683 macros.
5684 * config/nds32/nds32.md (type): Add mmu.
5685 * config/nds32/pipelines.md (simple_insn): Add mmu.
5686
5687 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
5688
5689 * config/nds32/nds32.md (type): Remove call.
5690 * config/nds32/pipelines.md (simple_insn): Likewise.
5691
5692 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5693
5694 * config/nds32/constants.md (unspec_volatile_element): Add
5695 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
5696 UNSPEC_VOLATILE_FMFCFG.
5697 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
5698 description for fmfcfg and fmfcsr.
5699 (bdesc_1arg): Add fmtcsr.
5700 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
5701 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
5702 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
5703 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
5704 unspec_fmfcfg): New patterns.
5705 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
5706 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
5707 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
5708 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
5709 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
5710 __nds32__fmfcfg): Define.
5711
5712 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5713
5714 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
5715 intrinsic register names.
5716 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
5717 intrinsic register enum values and macros.
5718
5719 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
5720
5721 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
5722 for load/store addressing form.
5723 (nds32_print_operand_address): Likewise.
5724
5725 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
5726
5727 PR target/85196
5728 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
5729 based on LABEL_REF. Remove useless assertion.
5730 (pic_address_needs_scratch): Fix formatting.
5731 (sparc_legitimize_pic_address): Minor tweaks.
5732 (sparc_delegitimize_address): Adjust assertion accordingly.
5733 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
5734 into symbolic_operand.
5735 (movsi_high_pic_label_ref): Likewise.
5736 (movsi_lo_sum_pic_label_ref): Likewise.
5737 (movdi_pic_label_ref): Likewise.
5738 (movdi_high_pic_label_ref): Likewise.
5739 (movdi_lo_sum_pic_label_ref): Likewise.
5740
5741 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
5742
5743 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
5744 custom LIB_SPEC setup.
5745
5746 2018-04-06 Ruslan Bukin <br@bsdpad.com>
5747 Kito Cheng <kito.cheng@gmail.com>
5748
5749 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
5750 * config/riscv/freebsd.h: New.
5751
5752 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
5753
5754 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
5755 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
5756 file.
5757
5758 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
5759 Kito Cheng <kito.cheng@gmail.com>
5760
5761 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
5762 nds32_output_call, nds32_symbol_binds_local_p): New functions.
5763 * config/nds32/nds32-protos.h (nds32_output_call,
5764 nds32_output_return): Declare.
5765 * config/nds32/nds32.md: Refine all the call and return patterns.
5766
5767 2018-04-06 Jakub Jelinek <jakub@redhat.com>
5768
5769 PR debug/85252
5770 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
5771 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
5772
5773 PR rtl-optimization/84872
5774 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
5775 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
5776 EDGE_CROSSING edge.
5777
5778 2018-04-06 Tamar Christina <tamar.christina@arm.com>
5779
5780 * expr.c (copy_blkmode_to_reg): Revert 254862.
5781 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
5782
5783 2018-04-06 Richard Biener <rguenther@suse.de>
5784
5785 PR middle-end/85244
5786 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
5787 after seeing a component reference with an adjacent field. Treat
5788 refs to arrays at struct end of external decls similar to
5789 refs to unconstrained commons.
5790
5791 2018-04-06 Jakub Jelinek <jakub@redhat.com>
5792
5793 PR sanitizer/85213
5794 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
5795 look through SAVE_EXPRs with non-side-effects argument. Adjust
5796 recursive calls.
5797 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
5798 save_p here.
5799
5800 2018-04-06 Richard Biener <rguenther@suse.de>
5801
5802 PR middle-end/85180
5803 * alias.c (find_base_term): New wrapper around find_base_term
5804 unwinding CSELIB_VAL_PTR changes.
5805 (find_base_term): Do not restore CSELIB_VAL_PTR during the
5806 recursion.
5807
5808 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
5809
5810 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
5811 instructions.
5812 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
5813 constant definitions.
5814 ("nop"): lr 0,0 -> nopr r0
5815 ("nop_lr0", "nop_lr1"): New insn definitions.
5816
5817 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
5818
5819 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
5820 NDS32_V3PUSH_AVAILABLE_P macro.
5821
5822 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
5823 Chung-Ju Wu <jasonwucj@gmail.com>
5824
5825 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
5826 (nds32*-*-*): Add float and fpu_config into supported_defaults.
5827 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
5828 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
5829 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
5830 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
5831 * config/nds32/constraints.md: New constraints and checking for hard
5832 float configuration.
5833 * config/nds32/iterators.md: New mode iterator and attribute for hard
5834 float configuration.
5835 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
5836 patterns.
5837 * config/nds32/nds32-fpu.md: New file.
5838 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
5839 deal with hard float code generation.
5840 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
5841 ARCH_V3S.
5842 (abi_type, float_reg_number): New enum type.
5843 * config/nds32/nds32-predicates.c: New predicates for hard float.
5844 * config/nds32/nds32-protos.h: Declare functions for hard float.
5845 * config/nds32/nds32.c: Implementation for hard float configuration.
5846 * config/nds32/nds32.h: Definitions for hard float configuration.
5847 * config/nds32/nds32.md: Include hard float machine description and
5848 modify patterns for hard float configuration.
5849 * config/nds32/nds32.opt: New options for hard float configuration.
5850 * config/nds32/predicates.md: New predicates for hard float
5851 configuration.
5852
5853 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
5854
5855 * common/config/nds32/nds32-common.c
5856 (nds32_option_optimization_table): Enable -mreleax-hint by default.
5857
5858 2018-04-05 Jakub Jelinek <jakub@redhat.com>
5859
5860 PR middle-end/85195
5861 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
5862 CONSTRUCTOR_ELT (ctor, ...)->value.
5863
5864 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
5865
5866 PR target/85193
5867 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
5868
5869 2018-04-05 Tom de Vries <tom@codesourcery.com>
5870
5871 PR target/85204
5872 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
5873 cond jump.
5874
5875 2018-04-05 Shiva Chen <shiva0217@gmail.com>
5876 Kito Cheng <kito.cheng@gmail.com>
5877
5878 * config/nds32/constraints.md (U33): Fine-tune checking condition.
5879 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
5880 * config/nds32/nds32.h (nds32_16bit_address_type): Add
5881 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
5882
5883 2018-04-05 Shiva Chen <shiva0217@gmail.com>
5884 Kito Cheng <kito.cheng@gmail.com>
5885
5886 * config/nds32/constraints.md (Ufe): New memory constraint.
5887 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
5888 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
5889 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
5890 operands.
5891 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
5892 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
5893
5894 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5895
5896 * config/nds32/nds32.md: Use optimize_size in the condition for
5897 alu-shift instructions.
5898
5899 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5900
5901 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
5902
5903 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5904
5905 * config/nds32/nds32.md (negsi2): Refine pattern.
5906
5907 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
5908 Chung-Ju Wu <jasonwucj@gmail.com>
5909
5910 * config/nds32/iterators.md (shift_rotate): New code iterator.
5911 (shift): New code attribute.
5912 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
5913 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
5914 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
5915 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
5916 bit-wise operations.
5917 (andsi3, *andsi3): Ditto.
5918 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
5919 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
5920 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
5921 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
5922 nds32_ior_operand, nds32_xor_operand): New predicates.
5923
5924 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5925
5926 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
5927 (addsi3, subsi3): ... this.
5928
5929 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5930
5931 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
5932
5933 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5934
5935 * config/nds32/nds32.md: Adjust indention.
5936
5937 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
5938
5939 * config/nds32/nds32.md (feature): New attribute.
5940
5941 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5942
5943 * config/nds32/nds32.md (subtype): New attribute.
5944
5945 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
5946
5947 PR target/85203
5948 * config/arm/arm-builtins.c (arm_expand_builtin): Change
5949 expansion to perform a bitwise AND of the argument followed by a
5950 boolean negation of the result.
5951
5952 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
5953
5954 PR rtl-optimization/84878
5955 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
5956 the basic block. Assert the use reference is not artificial and that
5957 it has an associated insn.
5958
5959 2018-04-04 Michael Matz <matz@suse.de>
5960
5961 * builtins.c (compute_objsize): Pass correct operand
5962 to array_at_struct_end_p.
5963
5964 2018-04-04 Richard Biener <rguenther@suse.de>
5965
5966 PR lto/85176
5967 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
5968 from contexts for DINFO_LEVEL_TERSE and below.
5969
5970 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
5971
5972 * config/nds32/nds32-doubleword.md (move_<mode>): Require
5973 resiter_operand condition.
5974 * config/nds32/nds32.md (*move<mode>): Ditto.
5975
5976 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
5977 Monk Chiang <sh.chiang04@gmail.com>
5978
5979 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
5980
5981 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
5982
5983 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
5984
5985 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
5986 Kito Cheng <kito.cheng@gmail.com>
5987
5988 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
5989 nds32_cond_code_str, output_cond_branch,
5990 output_cond_branch_compare_zero, nds32_expand_cbranch,
5991 nds32_expand_cstore, nds32_expand_movcc,
5992 nds32_output_cbranchsi4_equality_zero,
5993 nds32_output_cbranchsi4_equality_reg,
5994 nds32_output_cbranchsi4_equality_reg_or_const_int,
5995 nds32_output_cbranchsi4_greater_less_zero: New functions.
5996 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
5997 nds32_expand_cstore, nds32_expand_movcc,
5998 nds32_output_cbranchsi4_equality_zero,
5999 nds32_output_cbranchsi4_equality_reg,
6000 nds32_output_cbranchsi4_equality_reg_or_const_int,
6001 nds32_output_cbranchsi4_greater_less_zero): Declare.
6002 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
6003 nds32_rimm11s_operand): New predicates.
6004 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
6005 * config/nds32/nds32.md: Rewrite all the branch and conditional move
6006 patterns.
6007
6008 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
6009
6010 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
6011 * config/nds32/nds32.md: Ditto.
6012 * config/nds32/pipelines.md: Ditto.
6013
6014 2018-04-04 Richard Biener <rguenther@suse.de>
6015
6016 PR tree-optimization/85168
6017 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
6018 propagating abnormals.
6019
6020 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
6021
6022 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
6023
6024 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
6025 Kito Cheng <kito.cheng@gmail.com>
6026
6027 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
6028 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
6029 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
6030 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
6031 * config/nds32/nds32.md (sibcall_internal): New.
6032 (sibcall_register): Remove.
6033 (sibcall_immediate): Remove.
6034 (sibcall_value_internal): New.
6035 (sibcall_value_register): Remove.
6036 (sibcall_value_immediate): Remove.
6037 * config/nds32/predicates.md (nds32_general_register_operand): New.
6038 (nds32_call_address_operand): New.
6039
6040 2018-04-03 Jakub Jelinek <jakub@redhat.com>
6041
6042 PR rtl-optimization/85167
6043 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
6044 bb_defs if *split_p, instead preinitialize it to NULL.
6045
6046 PR tree-optimization/85156
6047 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
6048 evaluating the argument multiple times.
6049
6050 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
6051
6052 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
6053 than vector.
6054 (_mm_cvtpd_ps): Likewise.
6055 (_mm_cvttpd_epi32): Likewise.
6056 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
6057 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
6058 vector, pixel, and bool following altivec.h include.
6059
6060 2018-04-03 Martin Sebor <msebor@redhat.com>
6061
6062 * doc/extend.texi (Common Function Attributes): Clarify.
6063 (const attribute): Likewise.
6064 (pure attribute): Likewise.
6065
6066 2018-04-03 Jakub Jelinek <jakub@redhat.com>
6067
6068 PR target/85169
6069 * config/i386/i386.c (ix86_expand_vector_set): Use
6070 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
6071
6072 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
6073
6074 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
6075 instructions when changing rounding bits to preserve precision bits
6076 in the x87 control word.
6077
6078 2018-04-03 Martin Liska <mliska@suse.cz>
6079
6080 PR tree-optimization/82491
6081 * rtl.h (strip_offset_and_add): Replace += suboffset with
6082 poly_uint64 () + suboffset.
6083
6084 2018-03-29 Martin Liska <mliska@suse.cz>
6085 Martin Jambor <mjambor@suse.cz>
6086
6087 PR ipa/84947
6088 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
6089 param_type is not an integral or pointer type.
6090
6091 2018-04-03 Richard Biener <rguenther@suse.de>
6092
6093 * sese.h (recompute_all_dominators): Remove.
6094
6095 2018-04-02 Martin Sebor <msebor@redhat.com>
6096
6097 * doc/invoke.texi (-Wrestrict): Fix typos.
6098
6099 2018-04-02 Jim Wilson <jimw@sifive.com>
6100
6101 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
6102 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
6103 (<optab>di3, <optab>si3_extend): Likewise.
6104 (<optab>si3_mask, <optab>si3_mask_1): New.
6105 (<optab>di3_mask, <optab>di3_mask_1): New.
6106 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
6107 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
6108 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
6109
6110 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
6111
6112 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
6113 example.
6114
6115 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
6116
6117 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
6118 (nds32_canonicalize_comparison): New function.
6119
6120 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
6121 Kito Cheng <kito.cheng@gmail.com>
6122 Kuan-Lin Chen <kuanlinchentw@gmail.com>
6123
6124 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
6125 * config/nds32/constants.md (unspec_volatile_element): Add
6126 UNSPEC_VOLATILE_RELAX_GROUP.
6127 * config/nds32/nds32-relax-opt.c: New file.
6128 * config/nds32/nds32-predicates.c
6129 (nds32_symbol_load_store_p): New function.
6130 * config/nds32/nds32-protos.h
6131 (nds32_symbol_load_store_p): Declare function.
6132 (make_pass_nds32_relax_opt): Declare new rtl pass function.
6133 * config/nds32/nds32.c
6134 (nds32_register_pass): New function to register pass.
6135 (nds32_register_passes): New function to register passes.
6136 * config/nds32/nds32.md (relax_group): New pattern.
6137 * config/nds32/nds32.opt (mrelax-hint): New option.
6138 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
6139
6140 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
6141
6142 * config/nds32/t-nds32: Modify files dependency.
6143
6144 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
6145
6146 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
6147 (PROFILE_HOOK): Define its implementation.
6148
6149 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
6150
6151 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
6152 type and 32-bit size.
6153
6154 2018-04-01 Jakub Jelinek <jakub@redhat.com>
6155
6156 PR middle-end/85090
6157 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
6158 (V_128_256): New mode iterator.
6159 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
6160 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
6161 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
6162 of V.
6163 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
6164 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
6165
6166 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
6167
6168 PR target/83315
6169 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
6170 NaN inputs correctly.
6171
6172 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
6173
6174 PR target/80546
6175 * config/rs6000/vsx.md (??r): New mode attribute.
6176 (*vsx_mov<mode>_64bit): Use it.
6177 (*vsx_mov<mode>_32bit): Likewise.
6178
6179 2018-03-30 Martin Sebor <msebor@redhat.com>
6180
6181 PR tree-optimization/84818
6182 * builtins.c (check_access): Use warning_n.
6183
6184 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
6185
6186 PR target/83822
6187 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
6188 condition.
6189 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
6190 condition.
6191
6192 2018-03-30 Julia Koval <julia.koval@intel.com>
6193
6194 PR target/84413
6195 * x86-tune.def (movx, partial_reg_dependency): Enable for
6196 m_SKYLAKE_AVX512.
6197
6198 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
6199
6200 PR inline-asm/84985
6201 * lra-constraints.c (process_alt_operands): Move setting
6202 this_alternative_matches below.
6203
6204 2018-03-29 Martin Liska <mliska@suse.cz>
6205
6206 PR lto/84995.
6207 * doc/invoke.texi: Document how LTO works with debug info.
6208 Describe auto-load support of binutils. Mention 'x86-64'
6209 as valid option value of -march option.
6210
6211 2018-03-29 Jakub Jelinek <jakub@redhat.com>
6212
6213 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
6214
6215 PR c/85094
6216 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
6217 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
6218 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
6219 checking.
6220
6221 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
6222
6223 PR target/84912
6224 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
6225 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
6226 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
6227 for RS6000_BTM_POWERPC64.
6228 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
6229 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
6230 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
6231 definition.
6232 (DIVDE): Use it.
6233 (DIVDEU): Likewise.
6234
6235 2018-03-28 Carl Love <cel@us.ibm.com>
6236
6237 Revert
6238 2017-09-27 Carl Love <cel@us.ibm.com>
6239
6240 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
6241 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
6242 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
6243 fctiw instruction.
6244
6245 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
6246
6247 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
6248 instead of __vector bool.
6249 (_mm_max_pu8): Likewise.
6250 (_mm_min_pi16): Likewise.
6251
6252 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
6253
6254 PR target/84912
6255 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
6256 (DIVWEUO): Likewise.
6257 (DIVDEO): Likewise.
6258 (DIVDEUO): Likewise.
6259 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
6260 DIVWEUO and DIVDEUO.
6261 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
6262 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
6263 (div_extend): Likewise.
6264 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
6265 builtin function.
6266 (__builtin_divweuo): Likewise.
6267 (__builtin_divdeo): Likewise.
6268 (__builtin_divdeuo): Likewise.
6269
6270 2018-03-28 Jakub Jelinek <jakub@redhat.com>
6271
6272 PR target/85095
6273 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
6274 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
6275
6276 PR tree-optimization/82004
6277 * gimple-match-head.c (optimize_pow_to_exp): New function.
6278 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
6279 Don't fold to exp if optimize_pow_to_exp is false.
6280
6281 2018-03-28 Martin Liska <mliska@suse.cz>
6282
6283 PR other/84819
6284 * calls.c (initialize_argument_information): Fix trailing space.
6285 * common.opt: Fix typo and provide better explanation for
6286 -fsanitize-coverage option.
6287 * config/i386/i386.opt: Fix typo.
6288
6289 2018-03-28 Jakub Jelinek <jakub@redhat.com>
6290 Martin Liska <mliska@suse.cz>
6291
6292 PR sanitizer/85081
6293 * gimplify.c (asan_poison_variable): Don't do the check for
6294 gimplify_omp_ctxp here.
6295 (gimplify_decl_expr): Do it here.
6296 (gimplify_target_expr): Likewise.
6297
6298 2018-03-28 Martin Liska <mliska@suse.cz>
6299
6300 PR target/84988
6301 * config/i386/i386.c (ix86_function_arg_advance): Do not call
6302 chkp_type_bounds_count if MPX is not enabled.
6303
6304 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
6305
6306 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
6307
6308 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
6309
6310 PR target/84914
6311 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
6312 function to create the function decl for complex long double
6313 multiply and divide for -mabi=ieeelongdouble.
6314 (init_float128_ieee): Call it.
6315
6316 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
6317
6318 PR target/85044
6319 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
6320 -fcf-protection=branch -mibt.
6321 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
6322
6323 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
6324
6325 PR target/81863
6326 * config/arm/arm.c (arm_valid_symbolic_address): Handle arm_word_relocations
6327
6328 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
6329
6330 PR target/85056
6331 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
6332 extern array declarations.
6333
6334 2018-03-27 Richard Biener <rguenther@suse.de>
6335
6336 PR middle-end/84067
6337 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
6338 explicit single_use checks.
6339
6340 2018-03-27 Richard Biener <rguenther@suse.de>
6341
6342 PR tree-optimization/85082
6343 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
6344 Valueize the VUSE.
6345
6346 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
6347
6348 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
6349 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
6350 Turn on fasynchronous-unwind-tables and funwind-tables.
6351
6352 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
6353
6354 PR target/85073
6355 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
6356 (*bmi_blsr_<mode>_ccz): Ditto.
6357
6358 2018-03-26 Tom de Vries <tom@codesourcery.com>
6359
6360 PR tree-optimization/85063
6361 * omp-general.c (offloading_function_p): New function. Factor out
6362 of ...
6363 * omp-offload.c (pass_omp_target_link::gate): ... here.
6364 * omp-general.h (offloading_function_p): Declare.
6365 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
6366 with attribute omp declare target for offloading functions.
6367
6368 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
6369
6370 PR tree-optimization/84005
6371 * tree-data-ref.h (get_base_for_alignment): Declare.
6372 * tree-data-ref.c (get_base_for_alignment_1): New function.
6373 (get_base_for_alignment): Likewise.
6374 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
6375 get_base_for_alignment to find a suitable base object, instead
6376 of always using drb->base_address.
6377
6378 2018-03-23 Jakub Jelinek <jakub@redhat.com>
6379
6380 PR inline-asm/85022
6381 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
6382 known size by default.
6383
6384 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
6385
6386 PR inline-asm/85030
6387 * lra-constraints.c (process_alt_operands): Don't match BLKmode
6388 and non BLKmode operands.
6389
6390 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
6391
6392 PR target/85026
6393 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
6394 Clean up attributes.
6395
6396 2018-03-23 Richard Biener <rguenther@suse.de>
6397
6398 PR debug/85020
6399 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
6400 we are going to emit early debug for LTO.
6401
6402 2018-03-23 Jakub Jelinek <jakub@redhat.com>
6403
6404 PR inline-asm/85034
6405 * function.c (match_asm_constraints_1): Don't optimize if input
6406 doesn't satisfy general_operand predicate for output's mode.
6407
6408 PR inline-asm/85022
6409 * alias.c (write_dependence_p): Don't require for x_canonicalized
6410 non-VOIDmode if x has VOIDmode.
6411
6412 PR sanitizer/85029
6413 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
6414 just don't try to optimize it rather than assert it never happens.
6415
6416 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
6417
6418 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
6419 macro expansions for definition of ST_INTERNAL_<mode> and
6420 LD_INTERNAL_<mode> builtins.
6421 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
6422 Remove prototype.
6423 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
6424 function.
6425 (altivec_expand_st_builtin): Likewise.
6426 (altivec_expand_builtin): Remove calls to deleted functions.
6427 (rs6000_address_for_altivec): Delete this function.
6428 * config/rs6000/vector.md: Remove expands for
6429 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
6430
6431 2018-03-22 Sudakshina Das <sudi.das@arm.com>
6432
6433 PR target/84826
6434 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
6435 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
6436 re-computing once computed.
6437 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
6438 (arm_init_machine_status): Initialize
6439 machine->static_chain_stack_bytes.
6440
6441 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
6442
6443 PR target/84760
6444 * doc/extend.texi: Add four new prototypes for vec_ld.
6445 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
6446 definitions for more logical presentation.
6447 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
6448 entries for V1TI variants of __builtin_altivec_ld builtin.
6449 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
6450 handling of V1TI variant of LVX icode pattern.
6451 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
6452 (rs6000_gimple_fold_builtin): Likewise.
6453 (altivec_init_builtins): Add code to define
6454 __builtin_altivec_lvx_v1ti function.
6455
6456 2018-03-22 Jakub Jelinek <jakub@redhat.com>
6457
6458 PR inline-asm/84941
6459 * function.c (match_asm_constraints_1): Don't do the optimization
6460 if input isn't a REG, SUBREG, MEM or constant.
6461
6462 2018-03-22 Tom de Vries <tom@codesourcery.com>
6463
6464 PR tree-optimization/84956
6465 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
6466 bb_has_abnormal_pred.
6467
6468 2018-03-22 Jakub Jelinek <jakub@redhat.com>
6469
6470 PR sanitizer/85018
6471 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
6472 DECL_INITIAL (decl) to decl at the end.
6473 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
6474 adjust the comment.
6475
6476 2018-03-21 Joseph Myers <joseph@codesourcery.com>
6477
6478 * doc/extend.texi (__builtin_tgmath): Document when complex
6479 integer types are treated as _Complex _Float64.
6480
6481 2018-03-21 Tom de Vries <tom@codesourcery.com>
6482
6483 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
6484
6485 2018-03-21 Jakub Jelinek <jakub@redhat.com>
6486
6487 PR tree-optimization/84960
6488 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
6489 if it is ENTRY block, move them into single succ of ENTRY in that case.
6490
6491 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
6492
6493 PR tree-optimization/84811
6494 * poly-int.h (poly_span_traits): Remove the T3 parameter and
6495 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
6496 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
6497 (known_subrange_p): Update accordingly. Cast each value involved
6498 in the size comparison, rather than casting the result of the
6499 subtraction.
6500
6501 2018-03-21 Jakub Jelinek <jakub@redhat.com>
6502
6503 PR tree-optimization/84982
6504 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
6505 by flipping the least significant bit rather than all bits from
6506 bitpos to bitpos + bitsize - 1.
6507
6508 2018-03-21 Nathan Sidwell <nathan@acm.org>
6509
6510 * doc/extend.texi (Deprecated Features): Remove mention of
6511 long-deleted deprecations.
6512
6513 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6514
6515 PR jit/84288
6516 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
6517 * configure: Regenerate.
6518
6519 2018-03-21 Tom de Vries <tom@codesourcery.com>
6520
6521 PR tree-optimization/83126
6522 * tree-parloops.c (num_phis): New function.
6523 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
6524
6525 2018-03-21 Nathan Sidwell <nathan@acm.org>
6526
6527 * doc/extend.texi (Deprecated Features): Update deprecated flags,
6528 mention anon-struct/union members and trailing attributes.
6529
6530 2018-03-21 Bin Cheng <bin.cheng@arm.com>
6531
6532 PR tree-optimization/84969
6533 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
6534 builtin memset partitions if they set different rhs values.
6535
6536 2018-03-21 Jakub Jelinek <jakub@redhat.com>
6537
6538 PR rtl-optimization/84989
6539 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
6540 VEC_DUPLICATE with scalar result mode.
6541
6542 2018-03-21 Martin Liska <mliska@suse.cz>
6543
6544 PR ipa/84963
6545 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
6546 not intended return statement.
6547
6548 2018-03-21 Martin Liska <mliska@suse.cz>
6549
6550 PR target/84988
6551 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
6552 (chkp_find_bound_slots_1): Limit number of iterations.
6553
6554 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
6555
6556 PR target/84838
6557 * Minor grammar fixes for x86 options.
6558
6559 2018-03-20 Jakub Jelinek <jakub@redhat.com>
6560
6561 PR debug/84875
6562 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
6563 holding REG_CFA_RESTORE notes, instead turn them into a USE.
6564
6565 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
6566
6567 PR target/83789
6568 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
6569 (altivec_lvx_<mode>_1op): Likewise.
6570 (altivec_stvx_<mode>_2op): Likewise.
6571 (altivec_stvx_<mode>_1op): Likewise.
6572 (altivec_lvx_<VM2:mode>): New define_expand.
6573 (altivec_stvx_<VM2:mode>): Likewise.
6574 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
6575 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
6576 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
6577 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
6578 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
6579 (rs6000_gen_lvx): Likewise.
6580 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
6581 (altivec_expand_stv_builtin): Likewise.
6582 (altivec_expand_builtin): Likewise.
6583 * config/rs6000/vector.md: Likewise.
6584
6585 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
6586
6587 PR target/82518
6588 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
6589 BYTES_BIG_ENDIAN.
6590
6591 2018-03-20 Richard Biener <rguenther@suse.de>
6592
6593 PR target/84986
6594 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
6595 sign-conversions as zero, fall back to standard scalar_stmt
6596 cost for the rest.
6597
6598 2018-03-20 Martin Liska <mliska@suse.cz>
6599
6600 PR ipa/84825
6601 * predict.c (rebuild_frequencies): Handle case when we have
6602 PROFILE_ABSENT, but flag_guess_branch_prob is false.
6603
6604 2018-03-20 Jakub Jelinek <jakub@redhat.com>
6605
6606 PR target/84990
6607 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
6608 flag_section_anchors.
6609 * varasm.c (use_blocks_for_decl_p): Remove hack for
6610 dw2_force_const_mem.
6611
6612 PR target/84845
6613 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
6614 to ...
6615 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
6616 be created, use lowpart_subreg of operands[0] rather than operands[0]
6617 itself.
6618 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
6619 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
6620 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
6621 and n constraint instead of aarch64_shift_imm_di and Usd.
6622 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
6623 (*aarch64_<optab>_reg_minus<mode>3): ... this.
6624
6625 2018-03-20 Sudakshina Das <sudi.das@arm.com>
6626
6627 PR target/82989
6628 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
6629 to favor GPR over NEON registers.
6630 (<shift>di3_neon): Likewise.
6631
6632 2018-03-20 Tom de Vries <tom@codesourcery.com>
6633
6634 PR target/84952
6635 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
6636 (nvptx_process_pars): Emit bar.sync asap and alap.
6637
6638 2018-03-20 Tom de Vries <tom@codesourcery.com>
6639
6640 PR target/84954
6641 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
6642 seen_label if seen_label is already set.
6643
6644 2018-03-20 Jakub Jelinek <jakub@redhat.com>
6645
6646 PR target/84945
6647 * config/i386/i386.c (fold_builtin_cpu): For features above 31
6648 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
6649 Use 1U instead of 1. Formatting fixes.
6650
6651 PR c/84953
6652 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
6653 instead of TREE_TYPE (s1) for the return value.
6654
6655 2018-03-19 Jakub Jelinek <jakub@redhat.com>
6656
6657 PR tree-optimization/84946
6658 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
6659 bitsize + bitsize in poly_uint64 rather than poly_int64.
6660
6661 PR sanitizer/78651
6662 * dwarf2asm.c: Include fold-const.c.
6663 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
6664 of decl rather than decl itself.
6665
6666 PR rtl-optimization/84643
6667 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
6668
6669 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
6670
6671 PR sanitizer/78651
6672 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
6673 calling assemble_variable.
6674
6675 2018-03-19 Sudakshina Das <sudi.das@arm.com>
6676
6677 PR target/81647
6678 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
6679 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
6680
6681 2018-03-19 Jim Wilson <jimw@sifive.com>
6682
6683 PR bootstrap/84856
6684 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
6685 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
6686 (riscv_first_stack_step): Likewise.
6687 (riscv_option_override): Use STACK_BOUNDARY instead of
6688 MIN_STACK_BOUNDARY.
6689 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
6690 MIN_STACK_BOUNDARY.
6691 (BIGGEST_ALIGNMENT): Set to 128.
6692 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
6693 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
6694 STACK_BOUNDARY.
6695
6696 2018-03-19 Richard Biener <rguenther@suse.de>
6697
6698 PR tree-optimization/84933
6699 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
6700 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
6701
6702 2018-03-19 Richard Biener <rguenther@suse.de>
6703
6704 PR tree-optimization/84859
6705 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
6706 (cond_if_else_store_replacement): Perform sinking operation on
6707 single-store BBs regardless of MAX_STORES_TO_SINK setting.
6708 Generalize what a BB with a single eligible store is.
6709
6710 2018-03-19 Richard Biener <rguenther@suse.de>
6711
6712 PR tree-optimization/84929
6713 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
6714 chrec_is_positive against non-chrec arg.
6715
6716 2018-03-19 Tamar Christina <tamar.christina@arm.com>
6717
6718 PR target/84711
6719 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
6720
6721 2018-03-18 Martin Liska <mliska@suse.cz>
6722
6723 PR rtl-optimization/84635
6724 * regrename.c (build_def_use): Use matches_mode only when
6725 matches >= 0.
6726
6727 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
6728
6729 PR tree-optimization/84913
6730 * tree-vect-loop.c (vectorizable_reduction): Don't try to
6731 vectorize chains of COND_EXPRs.
6732
6733 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
6734
6735 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
6736
6737 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
6738
6739 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
6740
6741 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
6742
6743 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
6744
6745 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
6746 Kito Cheng <kito.cheng@gmail.com>
6747
6748 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
6749 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
6750 (nds32_adjust_reg_alloc_order): New function.
6751 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
6752
6753 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
6754
6755 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
6756 nds32_print_operand, nds32_print_operand_address): Use
6757 HOST_WIDE_INT_PRINT_DEC instead.
6758
6759 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
6760
6761 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
6762
6763 2018-03-17 Jakub Jelinek <jakub@redhat.com>
6764
6765 PR target/84902
6766 * config/i386/i386.c (initial_ix86_tune_features,
6767 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
6768 unsigned long long.
6769 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
6770 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
6771 rather than 1u << ix86_tune. Formatting fix.
6772 (ix86_option_override_internal): Change ix86_arch_mask from
6773 unsigned int to unsigned HOST_WIDE_INT, initialize to
6774 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
6775 (ix86_function_specific_restore): Likewise.
6776
6777 2018-03-16 Jakub Jelinek <jakub@redhat.com>
6778
6779 PR target/84899
6780 * postreload.c (reload_combine_recognize_pattern): Perform
6781 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
6782 truncate_int_for_mode the result for the destination's mode.
6783
6784 PR c/84909
6785 * hsa-gen.c (mem_type_for_type): Fix comment typo.
6786 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
6787 Likewise.
6788 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
6789 Likewise.
6790
6791 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
6792
6793 PR target/84876
6794 * lra-assigns.c (lra_split_hard_reg_for): Don't use
6795 regno_allocno_class_array and sorted_pseudos.
6796 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
6797 insns where regno is used.
6798
6799 2018-03-16 Martin Liska <mliska@suse.cz>
6800
6801 PR ipa/84833
6802 * multiple_target.c (create_dispatcher_calls): Redirect
6803 reference in the symbol table.
6804
6805 2018-03-16 Martin Liska <mliska@suse.cz>
6806
6807 PR ipa/84722
6808 * multiple_target.c (create_dispatcher_calls): Redirect also
6809 an alias.
6810
6811 2018-03-16 Jakub Jelinek <jakub@redhat.com>
6812
6813 PR c++/79937
6814 PR c++/82410
6815 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
6816 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
6817 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
6818
6819 2018-03-16 Julia Koval <julia.koval@intel.com>
6820
6821 * doc/invoke.texi (Skylake Server): Add CLWB.
6822 Cannonlake): Remove CLWB.
6823
6824 2018-03-16 Jakub Jelinek <jakub@redhat.com>
6825
6826 PR tree-optimization/84841
6827 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
6828 1 << 3.
6829 (FLOAT_ONE_CONST_TYPE): Define.
6830 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
6831 (sort_by_operand_rank): Put entries with higher constant_type last
6832 rather than first to match comments.
6833
6834 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
6835
6836 * config/nios2/nios2.md (movsi_internal): Fix thinko in
6837 split predicate.
6838
6839 2018-03-15 Jakub Jelinek <jakub@redhat.com>
6840
6841 PR c++/79085
6842 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
6843 check and use address of target always.
6844
6845 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
6846
6847 PR target/84574
6848 * config/i386/i386.c (indirect_thunk_needed): Update comments.
6849 (indirect_thunk_bnd_needed): Likewise.
6850 (indirect_thunks_used): Likewise.
6851 (indirect_thunks_bnd_used): Likewise.
6852 (indirect_return_needed): New.
6853 (indirect_return_bnd_needed): Likewise.
6854 (output_indirect_thunk_function): Add a bool argument for
6855 function return.
6856 (output_indirect_thunk_function): Don't generate alias for
6857 function return thunk.
6858 (ix86_code_end): Call output_indirect_thunk_function to generate
6859 function return thunks.
6860 (ix86_output_function_return): Set indirect_return_bnd_needed
6861 and indirect_return_needed instead of indirect_thunk_bnd_needed
6862 and indirect_thunk_needed.
6863
6864 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
6865
6866 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
6867 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
6868 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
6869
6870 2018-03-15 David Malcolm <dmalcolm@redhat.com>
6871 Paul Hua <paul.hua.gm@gmail.com>
6872
6873 PR c/84852
6874 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
6875
6876 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
6877
6878 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
6879 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
6880 resp. SFmode cases.
6881
6882 2018-03-15 Tamar Christina <tamar.christina@arm.com>
6883
6884 PR target/84711
6885 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
6886 instead of GET_MODE_SIZE when comparing Units.
6887
6888 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6889
6890 PR target/68256
6891 * varasm.c (hash_section): Return an unchangeble hash value
6892 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
6893 Return !aarch64_can_use_per_function_literal_pools_p ().
6894
6895 2018-03-15 Jakub Jelinek <jakub@redhat.com>
6896
6897 PR target/84860
6898 * optabs.c (emit_conditional_move): Pass address of cmode's copy
6899 rather than address of cmode as last argument to prepare_cmp_insn.
6900
6901 2018-03-15 Julia Koval <julia.koval@intel.com>
6902
6903 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
6904 F_AVX512VNNI, F_AVX512BITALG): New.
6905
6906 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
6907
6908 PR target/83451
6909 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
6910 insn for floating-point loads and stores.
6911
6912 2018-03-14 Carl Love <cel@us.ibm.com>
6913
6914 * config/rs6000/rs6000-c.c: Add macro definitions for
6915 ALTIVEC_BUILTIN_VEC_PERMXOR.
6916 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
6917 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
6918 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
6919 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
6920 UNSPEC_VPERMXOR.
6921 * config/doc/extend.texi: Add prototypes for vec_permxor.
6922
6923 2018-03-14 David Malcolm <dmalcolm@redhat.com>
6924
6925 PR c/84852
6926 * diagnostic-show-locus.c (class layout_point): Convert m_line
6927 from int to linenum_type.
6928 (line_span::comparator): Use linenum "compare" function when
6929 comparing line numbers.
6930 (test_line_span): New function.
6931 (layout_range::contains_point): Convert param "row" from int to
6932 linenum_type.
6933 (layout_range::intersects_line_p): Likewise.
6934 (layout::will_show_line_p): Likewise.
6935 (layout::print_source_line): Likewise.
6936 (layout::should_print_annotation_line_p): Likewise.
6937 (layout::print_annotation_line): Likewise.
6938 (layout::print_leading_fixits): Likewise.
6939 (layout::annotation_line_showed_range_p): Likewise.
6940 (struct line_corrections): Likewise for field m_row.
6941 (line_corrections::line_corrections): Likewise for param "row".
6942 (layout::print_trailing_fixits): Likewise.
6943 (layout::get_state_at_point): Likewise.
6944 (layout::get_x_bound_for_row): Likewise.
6945 (layout::print_line): Likewise.
6946 (diagnostic_show_locus): Likewise for locals "last_line" and
6947 "row".
6948 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
6949 * input.c (selftest::test_linenum_comparisons): New function.
6950 (selftest::input_c_tests): Call it.
6951 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
6952 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
6953 * selftest.h (ASSERT_GT): New macro.
6954 (ASSERT_GT_AT): New macro.
6955 (ASSERT_LT): New macro.
6956 (ASSERT_LT_AT): New macro.
6957
6958 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
6959
6960 PR rtl-optimization/84780
6961 * combine.c (distribute_links): Don't make a link based on pc_rtx.
6962
6963 2018-03-14 Martin Liska <mliska@suse.cz>
6964
6965 * tree.c (record_node_allocation_statistics): Use
6966 get_stats_node_kind.
6967 (get_stats_node_kind): New function extracted from
6968 record_node_allocation_statistics.
6969 (free_node): Use get_stats_node_kind.
6970
6971 2018-03-14 Richard Biener <rguenther@suse.de>
6972
6973 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
6974 that the value-set of ANTIC_IN doesn't grow.
6975
6976 Revert
6977 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
6978 member.
6979 (BB_VISITED_WITH_VISITED_SUCCS): New define.
6980 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
6981
6982 2018-03-14 Julia Koval <julia.koval@intel.com>
6983
6984 * config.gcc (icelake-client, icelake-server): New.
6985 (icelake): Remove.
6986 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
6987 (initial_ix86_arch_features): Ditto.
6988 (PTA_SKYLAKE): Add SGX.
6989 (PTA_ICELAKE): Remove.
6990 (PTA_ICELAKE_CLIENT): New.
6991 (PTA_ICELAKE_SERVER): New.
6992 (ix86_option_override_internal): Split up icelake on icelake client and
6993 icelake server.
6994 (get_builtin_code_for_version): Ditto.
6995 (fold_builtin_cpu): Ditto.
6996 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
6997 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
6998 * config/i386/i386.h (processor_type): Ditto.
6999 * doc/invoke.texi: Ditto.
7000
7001 2018-03-14 Jakub Jelinek <jakub@redhat.com>
7002
7003 PR sanitizer/83392
7004 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
7005 INTEGER_CST offset, add it together with bitpos / 8 and
7006 sign extend based on POINTER_SIZE.
7007
7008 PR target/84844
7009 Revert
7010 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
7011
7012 PR target/78090
7013 * config/i386/constraints.md (Yc): New register constraint.
7014 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
7015 Use Yc constraint for alternative 2 of operand 0. Remove
7016 preferred_for_speed attribute.
7017
7018 2018-03-14 Richard Biener <rguenther@suse.de>
7019
7020 PR tree-optimization/84830
7021 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
7022 with the old one to avoid oscillations.
7023
7024 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
7025
7026 PR target/83712
7027 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
7028 pseudos.
7029 (assign_by_spills): Return a flag of reload assignment failure.
7030 Do not process the reload assignment failures. Do not spill other
7031 reload pseudos if they has the same reg class. Update n if
7032 necessary.
7033 (lra_assign): Add a return arg. Set up from the result of
7034 assign_by_spills call.
7035 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
7036 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
7037 usage_insns if it is not NULL.
7038 (spill_hard_reg_in_range): New function.
7039 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
7040 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
7041 function prototypes.
7042 (lra_assign): Change prototype.
7043 * lra.c (lra): Add code to deal with fails by splitting hard reg
7044 live ranges.
7045
7046 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
7047
7048 * config/riscv/riscv.opt (mrelax): New option.
7049 * config/riscv/riscv.c (riscv_file_start): Emit ".option
7050 "norelax" when riscv_mrelax is disabled.
7051 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
7052
7053 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
7054
7055 PR target/84743
7056 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
7057 reassociation for int modes.
7058
7059 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
7060
7061 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
7062 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
7063 for big-endian.
7064 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
7065 * config/aarch64/aarch64-sve.md
7066 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
7067 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
7068 (*extend<mode><Vwide>2): Rename to...
7069 (aarch64_sve_extend<mode><Vwide>2): ...this.
7070 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
7071 renaming the old pattern to...
7072 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
7073 unsigned packs.
7074 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
7075 define_expand, renaming the old pattern to...
7076 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
7077 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
7078 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
7079 account when deciding which SVE instruction the optab should use.
7080 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
7081
7082 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
7083
7084 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
7085 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
7086 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
7087 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
7088 (tlsdesc_small_<mode>): Turn a define_expand and use
7089 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
7090 (tlsdesc_small_advsimd_<mode>): ...this.
7091 (tlsdesc_small_sve_<mode>): New pattern.
7092
7093 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
7094
7095 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
7096 (UNSPEC_UMUL_HIGHPART): New constants.
7097 (MUL_HIGHPART): New int iteraor.
7098 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
7099 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
7100 define_expand.
7101 (*<su>mul<mode>3_highpart): New define_insn.
7102
7103 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
7104
7105 PR lto/84805
7106 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
7107 incomplete types.
7108
7109 2018-03-13 Martin Liska <mliska@suse.cz>
7110
7111 PR ipa/84658.
7112 * (sem_item_optimizer::sem_item_optimizer): Initialize new
7113 vector.
7114 (sem_item_optimizer::~sem_item_optimizer): Release it.
7115 (sem_item_optimizer::merge_classes): Register variable aliases.
7116 (sem_item_optimizer::fixup_pt_set): New function.
7117 (sem_item_optimizer::fixup_points_to_sets): Likewise.
7118 * ipa-icf.h: Declare new variables and functions.
7119
7120 2018-03-13 Jakub Jelinek <jakub@redhat.com>
7121
7122 PR middle-end/84834
7123 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
7124 integer_pow2p@2 and test integer_pow2p in condition.
7125 (A < 0 ? C : 0): Similarly for @1.
7126
7127 PR middle-end/84831
7128 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
7129 characters starting at p contain '\0' character, don't look beyond
7130 that.
7131
7132 PR target/84827
7133 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
7134 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
7135
7136 PR target/84828
7137 * reg-stack.c (change_stack): Change update_end var from int to
7138 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
7139 also call set_block_for_insn on the newly added insns and rescan.
7140
7141 PR target/84786
7142 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
7143 on the last operand.
7144
7145 PR c++/84704
7146 * tree.c (stabilize_reference_1): Return save_expr (e) for
7147 STATEMENT_LIST even if it doesn't have side-effects.
7148
7149 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
7150
7151 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
7152
7153 2018-03-12 Renlin Li <renlin.li@arm.com>
7154
7155 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
7156 aarch64_output_scalar_simd_mov_immediate.
7157
7158 2018-03-12 Martin Sebor <msebor@redhat.com>
7159
7160 PR tree-optimization/83456
7161 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
7162 for perfectly overlapping calls to memcpy.
7163 (gimple_fold_builtin_memory_chk): Same.
7164 (gimple_fold_builtin_strcpy): Handle no-warning.
7165 (gimple_fold_builtin_stxcpy_chk): Same.
7166 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
7167
7168 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
7169
7170 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
7171 parameter. Use it for SFmode.
7172 (rs6000_function_arg_advance_1): Adjust.
7173 (rs6000_function_arg): Adjust.
7174 (rs6000_gimplify_va_arg): Pass false for that new parameter.
7175
7176 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
7177
7178 PR rtl-optimization/84169
7179 PR rtl-optimization/84780
7180 * combine.c (can_combine_p): Check for a 2-insn combination whether
7181 the destination register is used between the two insns, too.
7182
7183 2018-03-12 Richard Biener <rguenther@suse.de>
7184
7185 PR tree-optimization/84803
7186 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
7187 for refs DR analysis didn't process.
7188
7189 2018-03-12 Richard Biener <rguenther@suse.de>
7190
7191 PR tree-optimization/84777
7192 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
7193 force-vectorize loops ignore whether we are optimizing for size.
7194
7195 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
7196
7197 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
7198 (TARGET_MD_ASM_ADJUST): Define.
7199
7200 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
7201 Kito Cheng <kito.cheng@gmail.com>
7202 Chung-Ju Wu <jasonwucj@gmail.com>
7203
7204 * config/nds32/nds32.c (nds32_compute_stack_frame,
7205 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
7206 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
7207 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
7208 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
7209 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
7210 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
7211 * config/nds32/nds32.md (prologue, epilogue): Use macro
7212 NDS32_V3PUSH_AVAILABLE_P to do checking.
7213
7214 2018-03-11 Jakub Jelinek <jakub@redhat.com>
7215
7216 PR debug/58150
7217 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
7218 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
7219 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
7220 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
7221 addition of most attributes on !orig_type_die or the attribute not
7222 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
7223
7224 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
7225 Chung-Ju Wu <jasonwucj@gmail.com>
7226
7227 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
7228 __NDS32_VH__ macro.
7229 * config/nds32/nds32.opt (mvh): New option.
7230
7231 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
7232 Chung-Ju Wu <jasonwucj@gmail.com>
7233
7234 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
7235 function.
7236 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
7237 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
7238 definition.
7239
7240 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
7241 Chung-Ju Wu <jasonwucj@gmail.com>
7242
7243 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
7244 function.
7245 * config/nds32/nds32-multiple.md (strlensi): New pattern.
7246 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
7247
7248 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
7249 Kito Cheng <kito.cheng@gmail.com>
7250 Chung-Ju Wu <jasonwucj@gmail.com>
7251
7252 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
7253 UNSPEC_FFMISM and UNSPEC_FLMISM.
7254 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
7255 for ffb, ffmism and flmism.
7256 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
7257 (unspec_ffmism): Ditto.
7258 (unspec_flmism): Ditto.
7259 (nds32_expand_builtin_impl): Check if string extension is available.
7260 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
7261 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
7262
7263 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
7264
7265 Reverting patch:
7266 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
7267
7268 PR target/83712
7269 * lra-assigns.c (assign_by_spills): Return a flag of reload
7270 assignment failure. Do not process the reload assignment
7271 failures. Do not spill other reload pseudos if they has the same
7272 reg class.
7273 (lra_assign): Add a return arg. Set up from the result of
7274 assign_by_spills call.
7275 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
7276 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
7277 usage_insns if it is not NULL.
7278 (spill_hard_reg_in_range): New function.
7279 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
7280 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
7281 function prototypes.
7282 (lra_assign): Change prototype.
7283 * lra.c (lra): Add code to deal with fails by splitting hard reg
7284 live ranges.
7285
7286 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
7287
7288 PR target/84807
7289 * config/i386/i386.opt: Replace Enforcment with Enforcement.
7290
7291 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
7292
7293 PR debug/84620
7294 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
7295 (dw_val_node): Add val_symbolic_view.
7296 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
7297 (symview_upper_bound): New.
7298 (new_line_info_table): Initialize symviews_since_reset.
7299 (dwarf2out_source_line): Count symviews_since_reset and set
7300 symview_upper_bound.
7301 (dw_val_equal_p): Handle symview.
7302 (add_AT_symview): New.
7303 (print_dw_val): Handle symview.
7304 (attr_checksum, attr_checksum_ordered): Likewise.
7305 (same_dw_val_p, size_of_die): Likewise.
7306 (value_format, output_die): Likewise.
7307 (add_high_low_attributes): Use add_AT_symview for entry_view.
7308 (dwarf2out_finish): Reset symview_upper_bound, clear
7309 zero_view_p.
7310
7311 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
7312
7313 PR target/83969
7314 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
7315 Add strict argument and use it.
7316 (rs6000_split_multireg_move): Update for new strict argument.
7317 (mem_operand_gpr): Disallow all non-offsettable addresses.
7318 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
7319
7320 2018-03-09 Jakub Jelinek <jakub@redhat.com>
7321
7322 PR target/84772
7323 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
7324 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
7325 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
7326
7327 PR c++/84767
7328 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
7329 decl, use remap_type if we want to use the type.
7330
7331 2018-03-09 Martin Sebor <msebor@redhat.com>
7332
7333 PR tree-optimization/84526
7334 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
7335 Remove dead code.
7336 (builtin_access::generic_overlap): Be prepared to handle non-array
7337 base objects.
7338
7339 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
7340
7341 PR rtl-optimization/84682
7342 * lra-constraints.c (process_address_1): Check is_address flag
7343 for address constraints.
7344 (process_alt_operands): Likewise.
7345 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
7346 preprocess_constraints.
7347 * recog.h (preprocess_constraints): Add oploc parameter.
7348 Adjust callers.
7349 * recog.c (preprocess_constraints): Test address_operand for
7350 CT_ADDRESS constraints.
7351
7352 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
7353
7354 PR target/83712
7355 * lra-assigns.c (assign_by_spills): Return a flag of reload
7356 assignment failure. Do not process the reload assignment
7357 failures. Do not spill other reload pseudos if they has the same
7358 reg class.
7359 (lra_assign): Add a return arg. Set up from the result of
7360 assign_by_spills call.
7361 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
7362 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
7363 usage_insns if it is not NULL.
7364 (spill_hard_reg_in_range): New function.
7365 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
7366 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
7367 function prototypes.
7368 (lra_assign): Change prototype.
7369 * lra.c (lra): Add code to deal with fails by splitting hard reg
7370 live ranges.
7371
7372 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
7373
7374 PR target/83193
7375 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
7376 Accept complain bool parameter. Only emit errors if it is true.
7377 (arm_parse_cpu_option_name): Likewise.
7378 (arm_target_thumb_only): Adjust callers of the above.
7379 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
7380 prototype to take a default true bool parameter.
7381 (arm_parse_arch_option_name): Likewise.
7382
7383 2018-03-09 David Malcolm <dmalcolm@redhat.com>
7384 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
7385
7386 PR jit/64089
7387 PR jit/84288
7388 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
7389 * configure: Regenerate.
7390 * configure.ac ("linker --version-script option"): New.
7391 ("linker soname option"): New.
7392
7393 2018-03-09 Richard Biener <rguenther@suse.de>
7394
7395 PR tree-optimization/84775
7396 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
7397 immediate uses of predicate stmts and mark them modified.
7398
7399 Revert
7400 PR tree-optimization/84178
7401 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
7402 to caller.
7403 (version_loop_for_if_conversion): Delay update_ssa call.
7404 (tree_if_conversion): Delay update_ssa until after predicate
7405 insertion.
7406
7407 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
7408
7409 PR target/84763
7410 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
7411 when the function accesses prior frames.
7412
7413 2018-03-08 Jakub Jelinek <jakub@redhat.com>
7414
7415 PR debug/84456
7416 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
7417 gen_llsym, otherwise call maybe_gen_llsym.
7418
7419 PR inline-asm/84742
7420 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
7421 has ',' character inside of it.
7422
7423 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
7424
7425 PR target/84748
7426 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
7427 as clobbering CC_REGNUM.
7428
7429 2018-03-08 Richard Biener <rguenther@suse.de>
7430
7431 PR middle-end/84552
7432 * tree-scalar-evolution.c: Include tree-into-ssa.h.
7433 (follow_copies_to_constant): Do not follow SSA names registered
7434 for update.
7435
7436 2018-03-08 Richard Biener <rguenther@suse.de>
7437
7438 PR tree-optimization/84178
7439 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
7440 to caller.
7441 (version_loop_for_if_conversion): Delay update_ssa call.
7442 (tree_if_conversion): Delay update_ssa until after predicate
7443 insertion.
7444
7445 2018-03-08 David Malcolm <dmalcolm@redhat.com>
7446
7447 PR tree-optimization/84178
7448 * tree-if-conv.c (release_bb_predicate): Remove the
7449 the assertion that the stmts have NULL use_ops.
7450 Discard the statements, asserting that they haven't
7451 yet been added to a BB.
7452
7453 2018-03-08 Richard Biener <rguenther@suse.de>
7454
7455 PR tree-optimization/84746
7456 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
7457 (phi_translate): Pass in destination ANTIC_OUT set.
7458 (phi_translate_1): Likewise. For a simplified result lookup
7459 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
7460 (phi_translate_set): Adjust.
7461 (do_pre_regular_insertion): Likewise.
7462 (do_pre_partial_partial_insertion): Likewise.
7463
7464 2018-03-08 Martin Liska <mliska@suse.cz>
7465
7466 PR gcov-profile/84735
7467 * doc/gcov.texi: Document usage of profile files.
7468 * gcov-io.h: Document changes in the format.
7469
7470 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
7471
7472 PR debug/84404
7473 PR debug/84408
7474 * dwarf2out.c (struct dw_line_info_table): Update comments for
7475 view == -1.
7476 (FORCE_RESET_NEXT_VIEW): New.
7477 (FORCE_RESETTING_VIEW_P): New.
7478 (RESETTING_VIEW_P): Check for -1 too.
7479 (ZERO_VIEW_P): Likewise.
7480 (new_line_info_table): Force-reset next view.
7481 (dwarf2out_begin_function): Likewise.
7482 (dwarf2out_source_line): Simplify zero_view_p initialization.
7483 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
7484 view directly. Omit view when omitting .loc at line 0.
7485
7486 2018-03-08 Jakub Jelinek <jakub@redhat.com>
7487
7488 PR tree-optimization/84740
7489 * tree-switch-conversion.c (process_switch): Call build_constructors
7490 only if info.phi_count is non-zero.
7491
7492 PR tree-optimization/84739
7493 * tree-tailcall.c (find_tail_calls): Check call arguments against
7494 DECL_ARGUMENTS (current_function_decl) rather than
7495 DECL_ARGUMENTS (func) when checking for tail recursion.
7496
7497 2018-03-07 Jakub Jelinek <jakub@redhat.com>
7498
7499 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
7500 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
7501 Volker Reichelt's entry and add entries for people that perform
7502 GCC fuzzy testing and report numerous bugs.
7503
7504 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
7505
7506 PR target/82411
7507 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
7508 readonly data in sdata, if that is disabled.
7509 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
7510 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
7511 -mreadonly-in-sdata option.
7512
7513 2018-03-07 Martin Sebor <msebor@redhat.com>
7514
7515 PR tree-optimization/84468
7516 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
7517 basic block when looking for nul assignment.
7518
7519 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
7520
7521 PR target/84277
7522 * except.h (output_function_exception_table): Adjust prototype.
7523 * except.c (output_function_exception_table): Remove FNNAME parameter
7524 and add SECTION parameter. Ouput one part of the table at a time.
7525 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
7526 the first part of the exception table and emit unwind directives.
7527 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
7528 (i386_pe_seh_cold_init): Likewise.
7529 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
7530 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
7531 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
7532 (ix86_output_call_insn): Emit a nop in one more case for SEH.
7533 * config/i386/winnt.c: Include except.h.
7534 (struct seh_frame_state): Add reg_offset, after_prologue and
7535 in_cold_section fields.
7536 (i386_pe_seh_end_prologue): Set seh->after_prologue.
7537 (i386_pe_seh_cold_init): New function.
7538 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
7539 to seh->in_cold_section.
7540 (seh_emit_push): Record the offset of the push.
7541 (seh_emit_save): Record the offet of the save.
7542 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
7543 Test seh->after_prologue to disregard the epilogue.
7544 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
7545 (i386_pe_end_cold_function): New function.
7546
7547 2018-03-07 Jakub Jelinek <jakub@redhat.com>
7548
7549 PR fortran/84565
7550 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
7551 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
7552
7553 PR c++/84704
7554 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
7555 on tmp_var.
7556 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
7557 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
7558
7559 PR middle-end/84723
7560 * multiple_target.c: Include tree-inline.h and intl.h.
7561 (expand_target_clones): Diagnose and fail if node->definition and
7562 !tree_versionable_function_p (node->decl).
7563
7564 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
7565
7566 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
7567 sprint_ul.
7568 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
7569 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
7570 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
7571
7572 2018-03-06 Jakub Jelinek <jakub@redhat.com>
7573
7574 PR target/84710
7575 * combine.c (try_combine): Use reg_or_subregno instead of handling
7576 just paradoxical SUBREGs and REGs.
7577
7578 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
7579
7580 * config/arc/arc.c (arc_finalize_pic): Remove function.
7581 (arc_must_save_register): We use single base PIC register, remove
7582 checks to save/restore the PIC register.
7583 (arc_expand_prologue): Likewise.
7584 * config/arc/arc-protos.h (arc_set_default_type_attributes):
7585 Remove.
7586 (arc_verify_short): Likewise.
7587 (arc_attr_type): Likewise.
7588 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
7589 (walk_stores): Likewise.
7590 (arc_address_cost): Make it static.
7591 (arc_verify_short): Likewise.
7592 (branch_dest): Likewise.
7593 (arc_attr_type): Likewise.
7594 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
7595 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
7596 (arc_final_prescan_insn): Remove inserting the nops due to
7597 hardware hazards. It is done in reorg step.
7598 (insn_length_variant_t): Remove.
7599 (insn_length_parameters_t): Likewise.
7600 (arc_insn_length_parameters): Likewise.
7601 (arc_get_insn_variants): Likewise.
7602 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
7603
7604 2018-03-06 Jakub Jelinek <jakub@redhat.com>
7605
7606 PR inline-asm/84683
7607 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
7608 assertion failure.
7609
7610 PR tree-optimization/84687
7611 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
7612 on new_node->decl.
7613 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
7614
7615 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
7616
7617 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
7618 Rename to ppc_speculation_barrier.
7619 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
7620 __builtin_ppc_speculation_barrier.
7621
7622 2018-03-05 Jakub Jelinek <jakub@redhat.com>
7623
7624 PR target/84700
7625 * combine.c (combine_simplify_rtx): Don't try to simplify if
7626 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
7627 are equal to x.
7628
7629 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
7630
7631 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
7632 to 32 bytes when compiling for POWER9.
7633
7634 2018-03-05 Jakub Jelinek <jakub@redhat.com>
7635
7636 PR target/84564
7637 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
7638 regparm >= 3 with no arg reg available also for calls with
7639 flag_force_indirect_call. Pass decl to ix86_function_regparm.
7640
7641 PR target/84524
7642 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
7643 orig,vex.
7644 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
7645
7646 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
7647
7648 PR target/84264
7649 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
7650
7651 2018-03-05 Richard Biener <rguenther@suse.de>
7652
7653 PR tree-optimization/84486
7654 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
7655 When inserting a __builtin_assume_aligned call set the LHS
7656 SSA name alignment info accordingly.
7657
7658 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
7659
7660 PR tree-optimization/84114
7661 * config/aarch64/aarch64.c (aarch64_reassociation_width)
7662 Avoid reassociation of FLOAT_MODE addition.
7663
7664 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
7665
7666 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
7667 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
7668 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
7669 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
7670 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
7671 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
7672 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
7673 and -mwbnoinvd.
7674 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
7675 __builtin_ia32_wbinvd): New builtins.
7676 (SPECIAL_ARGS2): New.
7677 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
7678 (SPECIAL_ARGS2): New.
7679 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
7680 (ix86_valid_target_attribute_inner_p): Ditto.
7681 (ix86_init_mmx_sse_builtins): Add special_args2.
7682 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
7683 TARGET_WBNOINVD_P): New.
7684 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
7685 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
7686 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
7687 * config/i386/immintrin.h (_wbinvd): New intrinsic.
7688 * config/i386/pconfigintrin.h: New file.
7689 * config/i386/wbnoinvdintrin.h: Ditto.
7690 * config/i386/x86intrin.h: Add headers pconfigintrin.h and wbnoinvdintrin.h.
7691 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
7692
7693 2018-03-05 Richard Biener <rguenther@suse.de>
7694
7695 PR tree-optimization/84670
7696 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
7697 member.
7698 (BB_VISITED_WITH_VISITED_SUCCS): New define.
7699 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
7700 (compute_antic_aux): Only assert the number of values in ANTIC_IN
7701 doesn't grow if all successors (recursively) were visited at least
7702 once.
7703
7704 2018-03-05 Richard Biener <rguenther@suse.de>
7705
7706 PR tree-optimization/84650
7707 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
7708 if executed in the loop pipeline.
7709
7710 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
7711
7712 * doc/configfiles.texi (Configuration Files): Move info about
7713 conditionalizing $target-protos.h to...
7714 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
7715 differs from $target-protos.h.
7716
7717 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
7718 Chung-Ju Wu <jasonwucj@gmail.com>
7719
7720 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
7721 * config/nds32/nds32-multiple.md (setmemsi): Define.
7722 * config/nds32/nds32-memory-manipulation.c
7723 (nds32_gen_dup_4_byte_to_word_value): New.
7724 (emit_setmem_word_loop): New.
7725 (emit_setmem_byte_loop): New.
7726 (nds32_expand_setmem_loop): New.
7727 (nds32_expand_setmem_loop_v3m): New.
7728 (nds32_expand_setmem_unroll): New.
7729 (nds32_expand_setmem): New.
7730
7731 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
7732 Chung-Ju Wu <jasonwucj@gmail.com>
7733
7734 * config/nds32/nds32-memory-manipulation.c
7735 (nds32_emit_load_store): New.
7736 (nds32_emit_post_inc_load_store): New.
7737 (nds32_emit_mem_move): New.
7738 (nds32_emit_mem_move_block): New.
7739 (nds32_expand_movmemsi_loop_unknown_size): New.
7740 (nds32_expand_movmemsi_loop_known_size): New.
7741 (nds32_expand_movmemsi_loop): New.
7742 (nds32_expand_movmemsi_unroll): New.
7743 (nds32_expand_movmemqi): Rename ...
7744 (nds32_expand_movmemsi): ... to this.
7745 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
7746 (movmemsi): ... to this.
7747 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
7748 (nds32_expand_movmemsi): ... to this.
7749
7750 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
7751 Monk Chiang <sh.chiang04@gmail.com>
7752 Chung-Ju Wu <jasonwucj@gmail.com>
7753
7754 * config/nds32/nds32-protos.h
7755 (nds32_expand_load_multiple): New arguments.
7756 (nds32_expand_store_multiple): Ditto.
7757 (nds32_valid_multiple_load_store): Rename ...
7758 (nds32_valid_multiple_load_store_p): ... to this.
7759 * config/nds32/nds32-memory-manipulation.c
7760 (nds32_expand_load_multiple): Refine implementation.
7761 (nds32_expand_store_multiple): Ditto.
7762 * config/nds32/nds32-multiple.md
7763 (load_multiple): Update nds32_expand_load_multiple interface.
7764 (store_multiple): Update nds32_expand_store_multiple interface.
7765 * config/nds32/nds32-predicates.c
7766 (nds32_valid_multiple_load_store): Rename ...
7767 (nds32_valid_multiple_load_store_p): ... to this and refine
7768 implementation.
7769 * config/nds32/predicates.md
7770 (nds32_load_multiple_and_update_address_operation): New predicate.
7771 (nds32_store_multiple_and_update_address_operation): New predicate.
7772
7773 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
7774 Chung-Ju Wu <jasonwucj@gmail.com>
7775
7776 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
7777 (combo): New attribute.
7778 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
7779
7780 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
7781
7782 * config/nds32/nds32.opt: Change -mcmodel= default value.
7783
7784 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
7785 Monk Chiang <sh.chiang04@gmail.com>
7786 Chung-Ju Wu <jasonwucj@gmail.com>
7787
7788 * config/nds32/constants.md (unspec_element): New enum.
7789 * config/nds32/constraints.md (Umw): New constraint.
7790 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
7791 * config/nds32/nds32-intrinsic.md: Likewise.
7792 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
7793 (nds32_valid_smw_lwm_base_p): New.
7794 (nds32_output_smw_single_word): New.
7795 (nds32_output_lmw_single_word): New.
7796 (nds32_expand_unaligned_load): New.
7797 (nds32_expand_unaligned_store): New.
7798 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
7799 (nds32_output_smw_single_word): Declare.
7800 (nds32_output_lmw_single_word): Declare.
7801 (nds32_expand_unaligned_load): Declare.
7802 (nds32_expand_unaligned_store): Declare.
7803 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
7804 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
7805 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
7806 NDS32_BUILTIN_UASTORE_DW.
7807 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
7808 predicate.
7809
7810 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
7811 Kito Cheng <kito.cheng@gmail.com>
7812 Chung-Ju Wu <jasonwucj@gmail.com>
7813
7814 * config/nds32/nds32-intrinsic.c
7815 (nds32_expand_builtin_null_ftype_reg): Delete.
7816 (nds32_expand_builtin_reg_ftype_imm): Ditto.
7817 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
7818 (nds32_read_argument): New.
7819 (nds32_legitimize_target): Ditto.
7820 (nds32_legitimize_argument): Ditto.
7821 (nds32_check_constant_argument): Ditto.
7822 (nds32_expand_unop_builtin): Ditto.
7823 (nds32_expand_unopimm_builtin): Ditto.
7824 (nds32_expand_binop_builtin): Ditto.
7825 (nds32_builtin_decl_impl): Ditto.
7826 (builtin_description): Ditto.
7827 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
7828 (nds32_init_builtins_impl): Ditto.
7829 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
7830 (nds32_builtin_decl): New.
7831 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
7832 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
7833
7834 2018-03-02 Jeff Law <law@redhat.com>
7835
7836 * reorg.c (stop_search_p): Handle DEBUG_INSN.
7837 (redundant_insn, fill_simple_delay_slots): Likewise.
7838 (fill_slots_from_thread): Likewise.
7839 * resource.c (mark_referenced_resources): Likewise.
7840 (mark_set_resources, find_dead_or_set_registers): Likewise.
7841
7842 2018-03-02 Jakub Jelinek <jakub@redhat.com>
7843
7844 * substring-locations.h (format_warning_va): Formatting fix for
7845 ATTRIBUTE_GCC_DIAG.
7846 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
7847 argument.
7848 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
7849 * substring-locations.c: Include intl.h.
7850 (format_warning_va): Turned into small wrapper around
7851 format_warning_n_va, renamed to ...
7852 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
7853 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
7854 use ngettext.
7855 (format_warning_at_substring_n): New function.
7856 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
7857 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
7858 format_warning_at_substring with just a shorter name instead of
7859 const function pointer.
7860 (fmtwarn_n): New function.
7861 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
7862 appropriate, get rid of all the fmtstr temporaries, move conditionals
7863 with G_() wrapped string literals directly into fmtwarn arguments,
7864 cast dir.len to (int), formatting fixes.
7865
7866 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
7867
7868 * doc/invoke.texi: Remove "Cilk Plus" references.
7869
7870 2018-03-02 Jakub Jelinek <jakub@redhat.com>
7871 Richard Biener <rguenther@suse.de>
7872
7873 PR ipa/84628
7874 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
7875 for error or warning attributes if CALL_FROM_THUNK_P is set.
7876 Formatting fixes.
7877
7878 2018-03-02 Jakub Jelinek <jakub@redhat.com>
7879
7880 PR target/56540
7881 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
7882 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
7883
7884 PR target/56540
7885 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
7886 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
7887
7888 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
7889 instead of -1U in last predictors element's probability member.
7890
7891 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
7892
7893 PR ipa/83983
7894 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
7895 arguments if they are comparable.
7896
7897 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
7898
7899 PR tree-optimization/84634
7900 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
7901 masks and masked_loop_p with a single loop_masks, making sure it's
7902 null for bb vectorization.
7903
7904 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
7905
7906 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
7907 (vect_analyze_data_ref_access): Use loop->safe_len rather than
7908 loop->force_vectorize to check whether there is no alias.
7909
7910 2018-03-02 Jakub Jelinek <jakub@redhat.com>
7911
7912 PR target/84614
7913 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
7914 prototypes.
7915 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
7916 comments.
7917 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
7918 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
7919 instead of a loop around prev_real_insn.
7920 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
7921 prev_real_insn.
7922
7923 PR inline-asm/84625
7924 * config/i386/i386.c (ix86_print_operand): Use conditional
7925 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
7926 zero vector.
7927
7928 2018-03-02 Richard Biener <rguenther@suse.de>
7929
7930 PR tree-optimization/84427
7931 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
7932 (bitmap_set_subtract_values): Rewrite to handle multiple
7933 exprs per value.
7934 (clean): Likewise.
7935 (prune_clobbered_mems): Likewise.
7936 (phi_translate): Take edge instead of pred/phiblock.
7937 (phi_translate_1): Likewise.
7938 (phi_translate_set): Likewise. Insert all translated
7939 exprs for a value into the set, keeping possibly multiple
7940 expressions per value.
7941 (compute_antic_aux): Adjust for phi_translate changes.
7942 When intersecting union the expressions and prune those
7943 not in the final value set, keeping possibly multiple
7944 expressions per value. Do not use value-insertion
7945 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
7946 all expressions. Add verification that the value-sets
7947 only shrink during iteration.
7948 (compute_partial_antic_aux): Adjust for the phi_translate changes.
7949 (do_pre_regular_insertion): Likewise.
7950 (do_pre_partial_partial_insertion): Likewise.
7951
7952 2018-03-02 Richard Biener <rguenther@suse.de>
7953
7954 PR target/82005
7955 * config/darwin.c (saved_debug_info_level): New static global.
7956 (darwin_asm_lto_start): Disable debug info generation for LTO out.
7957 (darwin_asm_lto_end): Restore debug info generation settings.
7958
7959 2018-03-01 Martin Liska <mliska@suse.cz>
7960
7961 PR sanitizer/82484
7962 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
7963 volatile arguments.
7964
7965 2018-03-01 Richard Biener <rguenther@suse.de>
7966
7967 PR debug/84645
7968 * dwarf2out.c (gen_variable_die): Properly handle late VLA
7969 type annotation with LTO when debug was disabled at compile-time.
7970
7971 2018-03-01 Matthew Fortune <mfortune@gmail.com>
7972
7973 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
7974 XINT with INTVAL.
7975 (mips_final_postscan_insn): Likewise.
7976
7977 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
7978
7979 PR rtl-optimization/84528
7980 * alias.c (init_alias_target): Add commentary.
7981 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
7982 a unique base value if the frame pointer is not eliminated
7983 to the stack pointer.
7984
7985 2018-03-01 Tom de Vries <tom@codesourcery.com>
7986
7987 PR rtl-optimization/83327
7988 * lra-int.h (hard_regs_spilled_into): Declare.
7989 * lra.c (hard_regs_spilled_into): Define.
7990 (init_reg_info): Init hard_regs_spilled_into.
7991 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
7992 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
7993 (process_bb_lives): Handle hard_regs_spilled_into.
7994 (lra_create_live_ranges_1): Before doing liveness propagation, clear
7995 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
7996
7997 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
7998
7999 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
8000 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
8001 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
8002 * config/rs6000/aix72.h: New file.
8003
8004 2018-02-28 Jakub Jelinek <jakub@redhat.com>
8005
8006 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
8007 instead of warning_at with conditional singular and plural messages
8008 where possible.
8009
8010 PR target/52991
8011 * stor-layout.c (update_alignment_for_field): For
8012 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
8013 && !DECL_PACKED (field), do the alignment update, just use
8014 only desired_align instead of MAX (type_align, desired_align)
8015 as the alignment.
8016 (place_field): Don't do known_align < desired_align handling
8017 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
8018 is non-NULL, instead do it after rli->prev_field handling and
8019 only if not within a bitfield word. For DECL_PACKED (field)
8020 use type_align of BITS_PER_UNIT.
8021
8022 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
8023
8024 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
8025 superfluous parentheses and trailing spaces.
8026
8027 2018-02-28 Richard Biener <rguenther@suse.de>
8028
8029 PR tree-optimization/84584
8030 * graphite-scop-detection.c (scop_detection::add_scop): Discard
8031 SCoPs with fake exit edge.
8032
8033 2018-02-28 Martin Liska <mliska@suse.cz>
8034
8035 PR testsuite/84597
8036 * timevar.c (timer::print): Fix format to properly print 100%
8037 values.
8038
8039 2018-02-28 Richard Biener <rguenther@suse.de>
8040
8041 PR middle-end/84607
8042 * genmatch.c (capture_info::walk_match): Do not mark
8043 captured expressions without operands as expr_p given
8044 they act more like predicates and should be subject to
8045 "lost tail" side-effect preserving.
8046
8047 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
8048
8049 PR rtl-optimization/81611
8050 * auto-inc-dec.c (attempt_change): Move dead note from
8051 mem_insn if it's the next use of regno
8052 (find_address): Take address use of reg holding
8053 non-incremented value. Add parm to limit search to the named
8054 reg only.
8055 (merge_in_block): Attempt to use a mem insn that is the next
8056 use of the original regno.
8057
8058 2018-02-27 Martin Sebor <msebor@redhat.com>
8059
8060 PR c++/83871
8061 * gcc/doc/invoke.texi (-Wmissing-attributes): New option.
8062 * gcc/print-tree.c (print_node): Handle DECL_UNINLINABLE.
8063
8064 2018-02-27 Martin Sebor <msebor@redhat.com>
8065
8066 PR translation/84207
8067 * diagnostic-core.h (warning_n, error_n, inform_n): Change
8068 n argument to unsigned HOST_WIDE_INT.
8069 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
8070 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
8071 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
8072 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
8073
8074 2018-02-27 Richard Biener <rguenther@suse.de>
8075
8076 PR tree-optimization/84512
8077 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
8078 Do not use the estimate returned from record_stmt_cost for
8079 the scalar iteration cost but sum properly using add_stmt_cost.
8080
8081 2018-02-27 Richard Biener <rguenther@suse.de>
8082
8083 PR tree-optimization/84466
8084 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
8085 Adjust last change to less strictly validate use operands.
8086
8087 2018-02-27 Martin Liska <mliska@suse.cz>
8088
8089 PR gcov-profile/84548
8090 * gcov.c (process_file): Allow partial overlap and consider it
8091 also as group functions.
8092 (output_lines): Properly calculate range of lines for a group.
8093
8094 2018-02-27 Martin Liska <mliska@suse.cz>
8095
8096 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
8097 'ggc' suffixes. Change first column width.
8098 (timer::print): Fix formatting of the column.
8099
8100 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
8101
8102 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
8103 preserve inline entry blocks for the sake of debug inline
8104 entry point markers alone.
8105 (remove_unused_locals): Suggest in comments a better place to
8106 force the preservation of inline entry blocks that are
8107 otherwise unused, but do not preserve them.
8108
8109 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
8110
8111 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
8112
8113 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
8114
8115 PR target/84039
8116 * config/i386/constraints.md (Bs): Replace
8117 ix86_indirect_branch_register with
8118 TARGET_INDIRECT_BRANCH_REGISTER.
8119 (Bw): Likewise.
8120 * config/i386/i386.md (indirect_jump): Likewise.
8121 (tablejump): Likewise.
8122 (*sibcall_memory): Likewise.
8123 (*sibcall_value_memory): Likewise.
8124 Peepholes of indirect call and jump via memory: Likewise.
8125 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
8126 (*sibcall_value_GOT_32): Likewise.
8127 * config/i386/predicates.md (indirect_branch_operand): Likewise.
8128 (GOT_memory_operand): Likewise.
8129 (call_insn_operand): Likewise.
8130 (sibcall_insn_operand): Likewise.
8131 (GOT32_symbol_operand): Likewise.
8132 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
8133
8134 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
8135
8136 PR rtl-optimization/83496
8137 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
8138 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
8139 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
8140 redundant insn, if any.
8141 (relax_delay_slots): Likewise.
8142 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
8143
8144 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
8145
8146 PR tree-optimization/83965
8147 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
8148 that grouped statements are part of a reduction chain. Return
8149 true if the statement is not marked as a reduction itself but
8150 is part of a group.
8151 (vect_recog_dot_prod_pattern): Don't check whether the statement
8152 is part of a group here.
8153 (vect_recog_sad_pattern): Likewise.
8154 (vect_recog_widen_sum_pattern): Likewise.
8155
8156 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
8157
8158 PR debug/84545
8159 * final.c (rest_of_clean_state): Also look for calls inside sequences.
8160
8161 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
8162
8163 PR target/84530
8164 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
8165 the bool argument.
8166 (ix86_output_indirect_function_return): New prototype.
8167 (ix86_split_simple_return_pop_internal): Likewise.
8168 * config/i386/i386.c (indirect_return_via_cx): New.
8169 (indirect_return_via_cx_bnd): Likewise.
8170 (indirect_thunk_name): Handle return va CX_REG.
8171 (output_indirect_thunk_function): Create alias for
8172 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
8173 (ix86_output_indirect_jmp): Remove the bool argument.
8174 (ix86_output_indirect_function_return): New function.
8175 (ix86_split_simple_return_pop_internal): Likewise.
8176 * config/i386/i386.md (*indirect_jump): Don't pass false
8177 to ix86_output_indirect_jmp.
8178 (*tablejump_1): Likewise.
8179 (simple_return_pop_internal): Change it to define_insn_and_split.
8180 Call ix86_split_simple_return_pop_internal to split it for
8181 -mfunction-return=.
8182 (simple_return_indirect_internal): Call
8183 ix86_output_indirect_function_return instead of
8184 ix86_output_indirect_jmp.
8185
8186 2018-02-26 Jakub Jelinek <jakub@redhat.com>
8187
8188 PR bootstrap/84405
8189 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
8190 memset and value initialization afterwards.
8191
8192 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
8193
8194 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
8195
8196 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
8197
8198 PR target/84521
8199 * common/config/aarch64/aarch64-common.c
8200 (aarch_option_optimization_table[]): Switch
8201 off fomit-frame-pointer
8202
8203 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
8204 Chung-Ju Wu <jasonwucj@gmail.com>
8205
8206 * config/nds32/nds32-multiple.md (load_multiple): Disallow
8207 volatile memory.
8208 (store_multiple): Ditto.
8209
8210 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
8211
8212 * config.gcc: Add --with-cpu support for nds32 target.
8213 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
8214 * config/nds32/nds32.opt: Add -mcpu= option.
8215
8216 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
8217
8218 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
8219 isel=yes): Warn for these deprecated options.
8220
8221 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
8222
8223 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
8224 ISA_2_5_MASKS_EMBEDDED.
8225
8226 2018-02-23 Jakub Jelinek <jakub@redhat.com>
8227
8228 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
8229 p->max as pointers rather than using iterative_hash_expr.
8230
8231 2018-02-23 Carl Love <cel@us.ibm.com>
8232
8233 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
8234 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
8235 BU_P8V_OVERLOAD_2.
8236 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
8237 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
8238 P8V_BUILTIN_VEC_VUNSIGNED2.
8239
8240 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
8241
8242 PR target/81572
8243 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
8244 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
8245 LRA_UNKNOWN_ALT.
8246 * lra-constraints.c (curr_insn_transform): Set up
8247 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
8248 LRA_UNKNOWN_ALT.
8249 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
8250 * lra-eliminations.c (spill_pseudos): Ditto.
8251 (process_insn_for_elimination): Ditto.
8252 * lra-lives.c (reg_early_clobber_p): Use the new macros.
8253 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
8254 LRA_NON_CLOBBERED_ALT.
8255
8256 2018-02-22 Martin Sebor <msebor@redhat.com>
8257
8258 PR tree-optimization/84480
8259 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
8260 to maybe_diag_stxncpy_trunc. Call it.
8261 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
8262 from gimple_fold_builtin_strcpy. Print inlining stack.
8263 (handle_builtin_stxncpy): Print inlining stack.
8264 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
8265
8266 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
8267
8268 PR target/84176
8269 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
8270 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
8271 and -fcheck-pointer-bounds are used together.
8272 (indirect_thunk_prefix): New enum.
8273 (indirect_thunk_need_prefix): New function.
8274 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
8275 "_nt" instead of "_bnd" for NOTRACK prefix.
8276 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
8277 (output_indirect_thunk_function): Likewise.
8278 (): Likewise.
8279 (ix86_code_end): Update output_indirect_thunk_function calls.
8280 (ix86_output_indirect_branch_via_reg): Replace
8281 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
8282 (ix86_output_indirect_branch_via_push): Likewise.
8283 (ix86_output_function_return): Likewise.
8284 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
8285 incompatible with -fcf-protection=branch and
8286 -fcheck-pointer-bounds.
8287
8288 2018-02-22 Steve Ellcey <sellcey@cavium.com>
8289
8290 PR target/83335
8291 * config/aarch64/aarch64.c (aarch64_print_address_internal):
8292 Change gcc_assert call to output_operand_lossage.
8293
8294 2018-02-22 Steve Ellcey <sellcey@cavium.com>
8295
8296 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
8297
8298 2018-02-22 DJ Delorie <dj@redhat.com>
8299 Sebastian Perta <sebastian.perta@renesas.com>
8300 Oleg Endo <olegendo@gcc.gnu.org>
8301
8302 * config/rx/rx.c (rx_rtx_costs): New function.
8303 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
8304
8305 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
8306
8307 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
8308
8309 2018-02-22 Martin Liska <mliska@suse.cz>
8310
8311 PR driver/83193
8312 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
8313 Add "native" as a possible value.
8314
8315 2018-02-22 Martin Liska <mliska@suse.cz>
8316
8317 PR driver/83193
8318 * config/i386/i386.c (ix86_option_override_internal):
8319 Add "native" as a possible value for -march and -mtune.
8320
8321 2018-02-22 Jakub Jelinek <jakub@redhat.com>
8322
8323 PR target/84502
8324 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
8325 to all type variants.
8326
8327 PR tree-optimization/84503
8328 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
8329 width as info->bitpos + info->bitsize - start.
8330 (merged_store_group::merge_overlapping): Simplify width computation.
8331 (check_no_overlap): New function.
8332 (imm_store_chain_info::try_coalesce_bswap): Compute expected
8333 start + width and last_order of the group, fail if check_no_overlap
8334 fails.
8335 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
8336 to group if check_no_overlap fails.
8337
8338 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
8339
8340 * config/rs6000/altivec.md: Delete contraint arguments to
8341 define_expand, define_split, and define_peephole2, and in
8342 define_insn_and_split if always unused.
8343 * config/rs6000/darwin.md: Ditto.
8344 * config/rs6000/dfp.md: Ditto.
8345 * config/rs6000/rs6000.md: Ditto.
8346 * config/rs6000/sync.md: Ditto.
8347 * config/rs6000/vector.md: Ditto.
8348 * config/rs6000/vsx.md: Ditto.
8349
8350 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
8351
8352 * config/rs6000/altivec.md: Write output control strings as braced
8353 blocks instead of double-quoted strings.
8354 * config/rs6000/darwin.md: Ditto.
8355 * config/rs6000/rs6000.md: Ditto.
8356 * config/rs6000/vector.md: Ditto.
8357 * config/rs6000/vsx.md: Ditto.
8358
8359 2018-02-21 Jason Merrill <jason@redhat.com>
8360
8361 PR c++/84314 - ICE with templates and fastcall attribute.
8362 * attribs.c (build_type_attribute_qual_variant): Remove assert.
8363
8364 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
8365
8366 * ipa-cp.c (determine_versionability): Fix comment typos.
8367
8368 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
8369
8370 PR c/84229
8371 * ipa-cp.c (determine_versionability): Do not version functions caling
8372 va_arg_pack.
8373
8374 2018-02-21 Martin Liska <mliska@suse.cz>
8375
8376 PR driver/83193
8377 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
8378 Add "native" as a possible value.
8379 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
8380 the macro when native cpu detection is available.
8381
8382 2018-02-21 Martin Liska <mliska@suse.cz>
8383
8384 PR driver/83193
8385 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
8386 Add "native" as a possible value.
8387 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
8388 when native cpu detection is available.
8389
8390 2018-02-21 Jakub Jelinek <jakub@redhat.com>
8391 Martin Sebor <msebor@redhat.com>
8392
8393 PR tree-optimization/84478
8394 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
8395 false.
8396 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
8397 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
8398 support which is conservatively correct, for 2 only stay conservative
8399 for maxlen. Formatting and comment capitalization fixes. Add STRICT
8400 argument to the 2 argument get_range_strlen, adjust 6 arg
8401 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
8402 false.
8403 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
8404 (gimple_fold_builtin_strlen): Pass true as last argument to
8405 get_range_strlen.
8406
8407 2018-02-20 Martin Sebor <msebor@redhat.com>
8408
8409 PR middle-end/84095
8410 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
8411 (builtin_memref::set_base_and_offset): Same. Handle inner references.
8412 (builtin_memref::builtin_memref): Factor out parts into
8413 set_base_and_offset and call it.
8414
8415 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
8416
8417 PR middle-end/84406
8418 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
8419 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
8420 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
8421 search at the associated MODE_INT.
8422
8423 2018-02-20 Jeff Law <law@redhat.com>
8424
8425 PR middle-end/82123
8426 PR tree-optimization/81592
8427 PR middle-end/79257
8428 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
8429 for range data rather than using global data.
8430 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
8431 range data rather than using global data.
8432 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
8433 pass it to children as needed.
8434 (struct directive::fmtresult): Similarly.
8435 (struct directive::set_width): Similarly.
8436 (struct directive::set_precision): Similarly.
8437 (format_integer, format_directive, parse_directive): Similarly.
8438 (format_none): Accept unnamed vr_values parameter.
8439 (format_percent, format_floating, format_character): Similarly.
8440 (format_string, format_plain): Similarly.
8441 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
8442 the EVRP range analyzer for range data rather than using global data.
8443 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
8444 gimple-ssa-evrp-analyze.h
8445 (class sprintf_dom_walker): Add after_dom_children member function.
8446 Add evrp_range_analyzer member.
8447 (sprintf_dom_walker::before_dom_children): Call into the EVRP
8448 range analyzer as needed.
8449 (sprintf_dom_walker::after_dom_children): New member function.
8450 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
8451 if not optimizing.
8452 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
8453 (evrp_range_analyzer::pop_to_marker): Likewise.
8454
8455 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
8456
8457 PR tree-optimization/84419
8458 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
8459 with the required type if its current type is compatible but
8460 different.
8461
8462 2018-02-20 Jakub Jelinek <jakub@redhat.com>
8463
8464 PR middle-end/82004
8465 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
8466 after vectorization.
8467
8468 2018-02-20 Martin Liska <mliska@suse.cz>
8469
8470 PR driver/83193
8471 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
8472 possible values if we don't have a hint.
8473
8474 2018-02-20 Martin Liska <mliska@suse.cz>
8475
8476 PR c/84310
8477 PR target/79747
8478 * final.c (shorten_branches): Build align_tab array with one
8479 more element.
8480 * opts.c (finish_options): Add alignment option limit check.
8481 (MAX_CODE_ALIGN): Likewise.
8482 (MAX_CODE_ALIGN_VALUE): Likewise.
8483 * doc/invoke.texi: Document maximum allowed option value for
8484 all -falign-* options.
8485
8486 2018-02-19 Jakub Jelinek <jakub@redhat.com>
8487
8488 PR target/84146
8489 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
8490 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
8491 * var-tracking.c (emit_note_insn_var_location): Remove all references
8492 to NOTE_INSN_CALL_ARG_LOCATION.
8493 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
8494 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
8495 Use copy_rtx_if_shared.
8496 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
8497 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
8498 (dwarf2out_var_location): Remove handling of
8499 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
8500 on call_insn.
8501 * final.c (final_scan_insn): Remove all references to
8502 NOTE_INSN_CALL_ARG_LOCATION.
8503 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
8504 before dumping final insns.
8505 * except.c (emit_note_eh_region_end): Remove all references to
8506 NOTE_INSN_CALL_ARG_LOCATION.
8507 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
8508 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
8509 * config/arc/arc.c (hwloop_optimize): Likewise.
8510 * config/arm/arm.c (create_fix_barrier): Likewise.
8511 * config/s390/s390.c (s390_chunkify_start): Likewise.
8512 * config/sh/sh.c (find_barrier): Likewise.
8513 * config/i386/i386.c (rest_of_insert_endbranch,
8514 ix86_seh_fixup_eh_fallthru): Likewise.
8515 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
8516 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
8517 * config/frv/frv.c (frv_function_prologue): Likewise.
8518 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
8519 reg note.
8520 (note_outside_basic_block_p): Remove all references to
8521 NOTE_INSN_CALL_ARG_LOCATION.
8522 * gengtype.c (adjust_field_rtx_def): Likewise.
8523 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
8524 Likewise.
8525 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
8526 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
8527
8528 PR c++/84444
8529 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
8530 is ADDR_EXPR.
8531
8532 PR tree-optimization/84452
8533 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
8534 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
8535 is NULL.
8536
8537 2018-02-19 Martin Liska <mliska@suse.cz>
8538
8539 PR sanitizer/82183
8540 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
8541
8542 2018-02-19 Martin Liska <mliska@suse.cz>
8543 Richard Sandiford <richard.sandiford@linaro.org>
8544
8545 PR tree-optimization/82491
8546 * gimple-fold.c (get_base_constructor): Make earlier bail out
8547 to prevent ubsan.
8548
8549 2018-02-19 Carl Love <cel@us.ibm.com>
8550
8551 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
8552 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
8553 BU_P8V_OVERLOAD_1.
8554 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
8555 P8V_BUILTIN_VEC_NEG.
8556
8557 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
8558
8559 * config/rl78/rl78.md (movdf): New define expand.
8560
8561 2018-02-19 Martin Liska <mliska@suse.cz>
8562
8563 PR other/80589
8564 * doc/invoke.texi: Fix typo.
8565 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
8566
8567 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
8568
8569 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
8570 handle rs6000_single_float and rs6000_double_float specially for
8571 e500 family CPUs.
8572
8573 2018-02-16 Jeff Law <law@redhat.com>
8574
8575 * config/rx/rx.c (add_pop_cfi_notes): New function.;
8576 (pop_regs): Use it.
8577
8578 2018-02-16 Jakub Jelinek <jakub@redhat.com>
8579
8580 PR ipa/84425
8581 * ipa-inline.c (inline_small_functions): Fix a typo.
8582
8583 2018-02-16 Nathan Sidwell <nathan@acm.org>
8584
8585 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
8586
8587 2018-02-16 Carl Love <cel@us.ibm.com>
8588
8589 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
8590 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
8591 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
8592 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
8593 expansion to P8V_BUILTIN_VEC_FLOAT2.
8594
8595 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
8596
8597 PR rtl-optimization/70023
8598 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
8599 src_regno into account.
8600
8601 2018-02-16 Carl Love <cel@us.ibm.com>
8602
8603 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
8604 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
8605 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
8606 * config/rs6000/rs6000.c: Remove case statements for
8607 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
8608 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
8609 and P9V_BUILTIN_VEC_VINSERT4B.
8610 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
8611 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
8612 * config/rs6000/vsx.md:
8613 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
8614 vec_insert4b.
8615
8616 2018-02-16 Carl Love <cel@us.ibm.com>
8617
8618 * config/rs6000/altivec.h: Add builtin names vec_extract4b
8619 vec_insert4b.
8620 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
8621 definitions.
8622 * config/rs6000/rs6000-c.c: Add the definitions for
8623 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
8624 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
8625 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
8626 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
8627 definition for insert4b and define insn *insert3b_internal.
8628 * doc/extend.texi: Add documentation for vec_extract4b.
8629
8630 2018-02-16 Nathan Sidwell <nathan@acm.org>
8631
8632 * doc/extend.texi (Backwards Compatibility): Mention friend
8633 injection. Note for-scope is deprecated.
8634 * doc/invoke.texi (-ffriend-injection): Deprecate.
8635
8636 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
8637
8638 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
8639 that moved to I2, also allow destinations that are a paradoxical
8640 subreg (instead of a normal reg).
8641
8642 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
8643
8644 PR target/83831
8645 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
8646 to QImode.
8647
8648 2018-02-16 Richard Biener <rguenther@suse.de>
8649
8650 PR tree-optimization/84037
8651 PR tree-optimization/84016
8652 PR target/82862
8653 * config/i386/i386.c (ix86_builtin_vectorization_cost):
8654 Adjust vec_construct for the fact we need additional higher latency
8655 128bit inserts for AVX256 and AVX512 vector builds.
8656 (ix86_add_stmt_cost): Scale vector construction cost for
8657 elementwise loads.
8658
8659 2018-02-16 Richard Biener <rguenther@suse.de>
8660
8661 PR tree-optimization/84417
8662 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
8663 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
8664 (non_rewritable_lvalue_p): Likewise, use poly-ints.
8665
8666 2018-02-16 Martin Liska <mliska@suse.cz>
8667
8668 PR sanitizer/84307
8669 * internal-fn.def (ASAN_CHECK): Set proper flags.
8670 (ASAN_MARK): Likewise.
8671
8672 2018-02-16 Julia Koval <julia.koval@intel.com>
8673
8674 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
8675 from PTA_CANNONLAKE.
8676
8677 2018-02-16 Jakub Jelinek <jakub@redhat.com>
8678
8679 PR target/84272
8680 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
8681 Use ++iter rather than iter++ for std::list iterators.
8682 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
8683 defer deleting them until all nodes in the forest are processed. Do
8684 free even leaf nodes. Change to_process into auto_vec.
8685
8686 PR bootstrap/84405
8687 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
8688 * vec.h (vec_default_construct): Use memset instead of placement new
8689 if BROKEN_VALUE_INITIALIZATION is defined.
8690 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
8691 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
8692 is defined.
8693
8694 PR rtl-optimization/83723
8695 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
8696 * lra.c (lra_substitute_pseudo): Likewise. If true, use
8697 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
8698 recursive calls.
8699 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
8700 callers.
8701 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
8702
8703 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
8704
8705 PR rtl-optimization/81443
8706 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
8707 from inner REGs to paradoxical SUBREGs.
8708
8709 2018-02-16 Richard Biener <rguenther@suse.de>
8710
8711 PR tree-optimization/84399
8712 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
8713 For operands we can analyze at their definition make sure we can
8714 analyze them at each use as well.
8715
8716 2018-02-16 Richard Biener <rguenther@suse.de>
8717
8718 PR tree-optimization/84190
8719 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
8720 volatile accesses if the decl isn't volatile.
8721
8722 2018-02-15 Jason Merrill <jason@redhat.com>
8723
8724 PR c++/84314 - ICE with templates and fastcall attribute.
8725 * attribs.c (build_type_attribute_qual_variant): Don't clobber
8726 TYPE_CANONICAL on an existing type.
8727
8728 2018-02-15 Jakub Jelinek <jakub@redhat.com>
8729
8730 PR tree-optimization/84383
8731 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
8732 dstoff nor call operand_equal_p if dstbase is NULL.
8733
8734 PR tree-optimization/84334
8735 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
8736 also a CONSTANT_CLASS_P, punt.
8737
8738 2018-02-14 Jim Wilson <jimw@sifive.com>
8739
8740 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
8741 first SMALL_OPERAND check. New local min_second_step. Move assert
8742 to where locals are set. Add TARGET_RVC support.
8743 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
8744
8745 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
8746
8747 * doc/invoke.texi: Correct -Wformat-overflow code sample.
8748
8749 2018-02-14 Martin Sebor <msebor@redhat.com>
8750
8751 PR tree-optimization/83698
8752 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
8753 arrays constrain the offset range to their bounds.
8754 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
8755 (builtin_access::overlap): Avoid setting the size of overlap if it's
8756 already been set.
8757 (maybe_diag_overlap): Also consider arrays when deciding what values
8758 of offsets to include in diagnostics.
8759
8760 2018-02-14 Martin Sebor <msebor@redhat.com>
8761
8762 PR c/84108
8763 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
8764 that correspond to the kind of a declaration.
8765
8766 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
8767
8768 PR target/83984
8769 * config/pa/pa.md: Load address of PIC label using the linkage table
8770 if the label is nonlocal.
8771
8772 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
8773
8774 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
8775 warning message if user requests -maltivec=be.
8776 * doc/invoke.texi: Document deprecation of -maltivec=be.
8777
8778 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
8779
8780 PR target/84220
8781 * config/rs6000/rs6000-c.c: Update definitions for
8782 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
8783 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
8784
8785 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
8786
8787 PR target/84239
8788 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
8789 add _get_ssp intrinsics. Remove argument from
8790 __builtin_ia32_rdssp[d|q].
8791 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
8792 * config/i386/i386-builtin.def: Remove argument from
8793 __builtin_ia32_rdssp[d|q].
8794 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
8795 ix86_expand_special_args_builtin for _rdssp[d|q].
8796 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
8797 Clear register before usage.
8798 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
8799 Add documentation for new _get_ssp and _inc_ssp intrinsics.
8800
8801 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
8802
8803 PR tree-optimization/84357
8804 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
8805 operand 1 of an ARRAY_REF too.
8806
8807 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
8808
8809 PR target/83831
8810 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
8811 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
8812 declarations.
8813 (set_of_reg): New struct.
8814 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
8815 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
8816 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
8817 functions.
8818 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
8819 Split into bitclr, bitset, bitinvert patterns if appropriate.
8820 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
8821 use rx_fuse_in_memory_bitop.
8822 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
8823 to named insn, correct maximum insn length.
8824
8825 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
8826
8827 PR target/79242
8828 * machmode.def: Define a complex mode for PARTIAL_INT.
8829 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
8830 MODE_PARTIAL_INT.
8831 * doc/rtl.texi: Document CSPImode.
8832 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
8833 handling.
8834 (msp430_hard_regno_nregs_with_padding): Likewise.
8835
8836 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
8837
8838 PR target/84279
8839 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
8840
8841 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
8842
8843 PR rtl-optimization/84169
8844 * combine.c (try_combine): New variable split_i2i3. Set it to true if
8845 we generated a parallel as new i3 and we split that to new i2 and i3
8846 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
8847 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
8848 those to i2, not i1. Partially rewrite this scan code.
8849
8850 2018-02-13 Jakub Jelinek <jakub@redhat.com>
8851
8852 PR c/82210
8853 * stor-layout.c (place_field): For variable length fields, adjust
8854 offset_align afterwards not just based on the field's alignment,
8855 but also on the size.
8856
8857 PR middle-end/84309
8858 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
8859 of exps and logs in the use_exp2 case.
8860
8861 2018-02-13 Jeff Law <law@redhat.com>
8862
8863 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
8864 entry for "vector".
8865
8866 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
8867 ARGS as unused.
8868
8869 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
8870
8871 PR debug/84342
8872 PR debug/84319
8873 * common.opt (gas-loc-support, gas-locview-support): New.
8874 (ginline-points, ginternal-reset-location-views): New.
8875 * doc/invoke.texi: Document them. Use @itemx where intended.
8876 (gvariable-location-views): Adjust.
8877 * target.def (reset_location_view): New.
8878 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
8879 (TARGET_RESET_LOCATION_VIEW): New.
8880 * doc/tm.texi: Rebuilt.
8881 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
8882 (dwarf2out_default_as_locview_support): New.
8883 (output_asm_line_debug_info): Use option variables.
8884 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
8885 (output_loc_list): Likewise.
8886 (add_high_low_attributes): Check option variables.
8887 Don't output entry view attribute in strict mode.
8888 (gen_inlined_subroutine_die): Check option variables.
8889 (dwarf2out_inline_entry): Likewise.
8890 (init_sections_and_labels): Likewise.
8891 (dwarf2out_early_finish): Likewise.
8892 (maybe_reset_location_view): New, from...
8893 (dwarf2out_var_location): ... here. Call it.
8894 * debug.h (dwarf2out_default_as_loc_support): Declare.
8895 (dwarf2out_default_as_locview_support): Declare.
8896 * hooks.c (hook_int_rtx_insn_0): New.
8897 * hooks.h (hook_int_rtx_insn_0): Declare.
8898 * toplev.c (process_options): Take -gas-loc-support and
8899 -gas-locview-support from dwarf2out. Enable
8900 -gvariable-location-views by default only with locview
8901 assembler support. Enable -ginternal-reset-location-views by
8902 default only if the target defines the corresponding hook.
8903 Enable -ginline-points by default if location views are
8904 enabled; force it disabled if statement frontiers are
8905 disabled.
8906 * tree-inline.c (expand_call_inline): Check option variables.
8907 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
8908
8909 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
8910
8911 PR tree-optimization/84321
8912 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
8913 handling. Also check whether the anti-range contains any values
8914 that satisfy the mask; switch to a VR_RANGE if not.
8915
8916 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
8917
8918 PR sanitizer/84340
8919 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
8920
8921 2018-02-13 Martin Jambor <mjambor@suse.cz>
8922
8923 PR c++/83990
8924 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
8925 of call statements, also set location of a load to a temporary.
8926
8927 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
8928
8929 * config/rl78/rl78.c (add_vector_labels): New function.
8930 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
8931 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
8932 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
8933 which checks that no arguments are passed.
8934 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
8935 * doc/extend.texi: Documentation for the new attribute.
8936
8937 2018-02-13 Andreas Schwab <schwab@suse.de>
8938
8939 * config/riscv/linux.h (CPP_SPEC): Define.
8940
8941 2018-02-13 Jakub Jelinek <jakub@redhat.com>
8942
8943 PR target/84335
8944 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
8945 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
8946 OPTION_MASK_ISA_AES as first argument to def_builtin_const
8947 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
8948 instead of OPTION_MASK_ISA_PCLMUL as first argument to
8949 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
8950 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
8951 temporarily for AES and PCLMUL builtins.
8952
8953 PR tree-optimization/84339
8954 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
8955 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
8956 Formatting fixes.
8957
8958 PR middle-end/84309
8959 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
8960 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
8961 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
8962 inline function.
8963 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
8964 inline function.
8965 * omp-simd-clone.h: New file.
8966 * omp-simd-clone.c: Include omp-simd-clone.h.
8967 (expand_simd_clones): No longer static.
8968 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
8969 cgraph.h and omp-simd-clone.h.
8970 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
8971 (vect_recog_widen_shift_pattern): Formatting fix.
8972 (vect_pattern_recog_1): Don't check optab for calls.
8973
8974 PR target/84336
8975 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
8976 operands[2] into a REG before using gen_lowpart on it.
8977
8978 2018-02-12 Jeff Law <law@redhat.com>
8979
8980 PR target/83760
8981 * config/sh/sh.c (find_barrier): Consider a sibling call
8982 a barrier as well.
8983
8984 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
8985 successfully back substituting a reg.
8986
8987 2018-02-12 Richard Biener <rguenther@suse.de>
8988
8989 PR tree-optimization/84037
8990 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
8991 parameter, move visited init to caller.
8992 (vect_slp_analyze_operations): Separate cost from validity
8993 check, initialize visited once for all instances.
8994 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
8995 for all instances.
8996 * tree-vect-stmts.c (vect_model_simple_cost): Make early
8997 out an assert.
8998 (vect_model_promotion_demotion_cost): Likewise.
8999 (vectorizable_bswap): Guard cost modeling with !slp_node
9000 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
9001 SLP stmts.
9002 (vectorizable_call): Likewise.
9003 (vectorizable_conversion): Likewise.
9004 (vectorizable_assignment): Likewise.
9005 (vectorizable_shift): Likewise.
9006 (vectorizable_operation): Likewise.
9007 (vectorizable_store): Likewise.
9008 (vectorizable_load): Likewise.
9009 (vectorizable_condition): Likewise.
9010 (vectorizable_comparison): Likewise.
9011
9012 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
9013
9014 PR sanitizer/84307
9015 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
9016 (ASAN_MARK): Fix fnspec to account for return value, change pointer
9017 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
9018
9019 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
9020
9021 PR middle-end/83665
9022 * params.def (inline-min-speedup): Increase from 8 to 15.
9023 (max-inline-insns-auto): Decrease from 40 to 30.
9024 * ipa-split.c (consider_split): Add some buffer for function to
9025 be considered inlining candidate.
9026 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
9027 default values.
9028
9029 2018-02-12 Richard Biener <rguenther@suse.de>
9030
9031 PR tree-optimization/84037
9032 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
9033 matched stmts if we cannot swap the non-matched ones.
9034
9035 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
9036
9037 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
9038 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
9039 _mm_maskz_scalef_round_ss): New intrinsics.
9040 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
9041 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
9042 __builtin_ia32_scalefss_round): Remove.
9043 (__builtin_ia32_scalefsd_mask_round,
9044 __builtin_ia32_scalefss_mask_round): New intrinsics.
9045 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
9046 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
9047 ((match_operand:VF_128 2 "<round_nimm_predicate>"
9048 "<round_constraint>")): Changed to ...
9049 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
9050 "<round_scalar_constraint>")): ... this.
9051 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
9052 %0, %1, %2<round_op3>}"): Changed to ...
9053 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
9054 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
9055 %2<round_scalar_mask_op3>}"): ... this.
9056 * config/i386/subst.md (round_scalar_nimm_predicate): New.
9057
9058 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
9059
9060 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
9061 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
9062 (_mm_maskz_sqrt_round_ss): New intrinsics.
9063 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
9064 (__builtin_ia32_sqrtsd_mask_round)
9065 (__builtin_ia32_sqrtss_mask_round): New builtins.
9066 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
9067 (__builtin_ia32_sqrtss_round): Remove.
9068 (__builtin_ia32_sqrtsd_mask_round)
9069 (__builtin_ia32_sqrtss_mask_round): New builtins.
9070 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
9071 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
9072 ((match_operand:VF_128 1 "vector_operand"
9073 "xBm,<round_constraint>")): Changed to ...
9074 ((match_operand:VF_128 1 "vector_operand"
9075 "xBm,<round_scalar_constraint>")): ... this.
9076 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
9077 %0, %2, %<iptr>1<round_op3>}): Changed to ...
9078 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
9079 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
9080 %<iptr>1<round_scalar_mask_op3>}): ... this.
9081 ((set_attr "prefix" "<round_prefix>")): Changed to ...
9082 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
9083
9084 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
9085
9086 PR target/84266
9087 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
9088 Cast vec_cmpeq result to correct type.
9089 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
9090 Cast vec_cmpgt result to correct type.
9091
9092 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
9093
9094 * final.c (final_scan_insn_1): Renamed from...
9095 (final_scan_insn): ... this. New wrapper, to recover
9096 seen from the outermost call in recursive ones.
9097 * config/sparc/sparc.c (output_return): Drop seen from call.
9098 (output_sibcall): Likewise.
9099 * config/visium/visium.c (output_branch): Likewise.
9100
9101 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
9102
9103 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
9104 function label.
9105
9106 2018-02-10 Alan Modra <amodra@gmail.com>
9107
9108 PR target/84300
9109 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
9110 Specify LR as an input.
9111
9112 2018-02-10 Jakub Jelinek <jakub@redhat.com>
9113
9114 PR sanitizer/83987
9115 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
9116 remove_member_access_dummy_vars): New functions.
9117 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
9118 lower_omp_1, execute_lower_omp): Use them.
9119
9120 PR rtl-optimization/84308
9121 * shrink-wrap.c (spread_components): Release todo vector.
9122
9123 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
9124
9125 PR rtl-optimization/57193
9126 * ira-color.c (struct allocno_color_data): Add member
9127 conflict_allocno_hard_prefs.
9128 (update_conflict_allocno_hard_prefs): New.
9129 (bucket_allocno_compare_func): Add a preference based on
9130 conflict_allocno_hard_prefs.
9131 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
9132 (color_allocnos): Remove a dead code. Initiate
9133 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
9134
9135 2018-02-09 Jakub Jelinek <jakub@redhat.com>
9136
9137 PR target/84226
9138 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
9139 constraint from =wa to wa. Avoid a subreg on the output operand,
9140 instead use a pseudo and subreg it in a move.
9141 (p9_xxbrd_<mode>): Changed to ...
9142 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
9143 (p9_xxbrd_v2df): New expander.
9144 (p9_xxbrw_<mode>): Changed to ...
9145 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
9146 (p9_xxbrw_v4sf): New expander.
9147
9148 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
9149
9150 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
9151
9152 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
9153
9154 PR target/83926
9155 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
9156 multiply in 32-bit mode.
9157 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
9158 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
9159 mode.
9160
9161 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
9162
9163 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
9164 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
9165 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
9166 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
9167
9168 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
9169
9170 PR lto/84213
9171 * dwarf2out.c (is_trivial_indirect_ref): New function.
9172 (dwarf2out_late_global_decl): Do not generate a location
9173 attribute for variables that have a non-trivial DECL_VALUE_EXPR
9174 and that are not defined in the current unit.
9175
9176 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
9177
9178 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
9179 instead of a libcall for UNORDERED.
9180
9181 2018-02-09 Tamar Christina <tamar.christina@arm.com>
9182
9183 PR target/82641
9184 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
9185 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
9186
9187 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
9188
9189 PR target/PR84295
9190 * config/s390/s390.c (s390_set_current_function): Invoke
9191 s390_indirect_branch_settings also if fndecl didn't change.
9192
9193 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
9194
9195 * config/rs6000/rs6000.md (blockage): Set length to zero.
9196
9197 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
9198
9199 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
9200
9201 2018-02-09 Jakub Jelinek <jakub@redhat.com>
9202
9203 PR sanitizer/84285
9204 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
9205 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
9206 -static-lib*san.
9207
9208 PR debug/84252
9209 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
9210 PARALLEL incoming that failed vt_get_decl_and_offset check.
9211
9212 PR middle-end/84237
9213 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
9214 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
9215 TREE_READONLY bit.
9216 (get_variable_section): For decls in named .bss* sections pass true as
9217 second argument to bss_initializer_p.
9218
9219 2018-02-09 Marek Polacek <polacek@redhat.com>
9220 Jakub Jelinek <jakub@redhat.com>
9221
9222 PR c++/83659
9223 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
9224 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
9225 Sync some changes from cxx_fold_indirect_ref.
9226
9227 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
9228
9229 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
9230 markers.
9231 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
9232 (BLOCK_INLINE_ENTRY_LABEL): New.
9233 (dwarf2out_var_location): Disregard inline entry markers.
9234 (inline_entry_data): New struct.
9235 (inline_entry_data_hasher): New hashtable type.
9236 (inline_entry_data_hasher::hash): New.
9237 (inline_entry_data_hasher::equal): New.
9238 (inline_entry_data_table): New variable.
9239 (add_high_low_attributes): Add DW_AT_entry_pc and
9240 DW_AT_GNU_entry_view attributes if a pending entry is found
9241 in inline_entry_data_table. Add old entry_pc attribute only
9242 if debug nonbinding markers are disabled.
9243 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
9244 markers are enabled.
9245 (block_within_block_p, dwarf2out_inline_entry): New.
9246 (dwarf2out_finish): Check that no entries remained in
9247 inline_entry_data_table.
9248 * final.c (reemit_insn_block_notes): Handle inline entry notes.
9249 (final_scan_insn, notice_source_line): Likewise.
9250 (rest_of_clean_state): Skip inline entry markers.
9251 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
9252 markers.
9253 * gimple.c (gimple_build_debug_inline_entry): New.
9254 * gimple.h (enum gimple_debug_subcode): Add
9255 GIMPLE_DEBUG_INLINE_ENTRY.
9256 (gimple_build_debug_inline_entry): Declare.
9257 (gimple_debug_inline_entry_p): New.
9258 (gimple_debug_nonbind_marker_p): Adjust.
9259 * insn-notes.def (INLINE_ENTRY): New.
9260 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
9261 inline entry marker notes.
9262 (print_insn): Likewise.
9263 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
9264 (INSN_DEBUG_MARKER_KIND): Likewise.
9265 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
9266 * tree-inline.c (expand_call_inline): Build and insert
9267 debug_inline_entry stmt.
9268 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
9269 inline entry blocks early, if nonbind markers are enabled.
9270 (dump_scope_block): Dump fragment info.
9271 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
9272 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
9273 (gimple_build_debug_inline_entry): New.
9274 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
9275 Enable/disable inline entry points too.
9276 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
9277 (DEBUG_INSN): Describe inline entry markers.
9278
9279 * common.opt (gvariable-location-views): New.
9280 (gvariable-location-views=incompat5): New.
9281 * config.in: Rebuilt.
9282 * configure: Rebuilt.
9283 * configure.ac: Test assembler for view support.
9284 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
9285 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
9286 * dwarf2out.c (var_loc_view): New typedef.
9287 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
9288 (dwarf2out_locviews_in_attribute): New.
9289 (dwarf2out_locviews_in_loclist): New.
9290 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
9291 (enum dw_line_info_opcode): Add LI_adv_address.
9292 (struct dw_line_info_table): Add view.
9293 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
9294 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
9295 (zero_view_p): New variable.
9296 (ZERO_VIEW_P): New macro.
9297 (output_asm_line_debug_info): New.
9298 (struct var_loc_node): Add view.
9299 (add_AT_view_list, AT_loc_list): New.
9300 (add_var_loc_to_decl): Add view param. Test it against last.
9301 (new_loc_list): Add view params. Record them.
9302 (AT_loc_list_ptr): Handle loc and view lists.
9303 (view_list_to_loc_list_val_node): New.
9304 (print_dw_val): Handle dw_val_class_view_list.
9305 (size_of_die): Likewise.
9306 (value_format): Likewise.
9307 (loc_list_has_views): New.
9308 (gen_llsym): Set vl_symbol too.
9309 (maybe_gen_llsym, skip_loc_list_entry): New.
9310 (dwarf2out_maybe_output_loclist_view_pair): New.
9311 (output_loc_list): Output view list or entries too.
9312 (output_view_list_offset): New.
9313 (output_die): Handle dw_val_class_view_list.
9314 (output_dwarf_version): New.
9315 (output_compilation_unit_header): Use it.
9316 (output_skeleton_debug_sections): Likewise.
9317 (output_rnglists, output_line_info): Likewise.
9318 (output_pubnames, output_aranges): Update version comments.
9319 (output_one_line_info_table): Output view numbers in asm comments.
9320 (dw_loc_list): Determine current endview, pass it to new_loc_list.
9321 Call maybe_gen_llsym.
9322 (loc_list_from_tree_1): Adjust.
9323 (add_AT_location_description): Create view list attribute if
9324 needed, check it's absent otherwise.
9325 (convert_cfa_to_fb_loc_list): Adjust.
9326 (maybe_emit_file): Call output_asm_line_debug_info for test.
9327 (dwarf2out_var_location): Reset views as needed. Precompute
9328 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
9329 attribute. Set view.
9330 (new_line_info_table): Reset next view.
9331 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
9332 (dwarf2out_source_line): Likewise. Output view resets and labels to
9333 the assembler, or select appropriate line info opcodes.
9334 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
9335 (optimize_string_length): Catch it. Adjust.
9336 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
9337 dw_val_class_view_list, and remove it if no longer needed.
9338 (hash_loc_list): Hash view numbers.
9339 (loc_list_hasher::equal): Compare them.
9340 (optimize_location_lists): Check whether a view list symbol is
9341 needed, and whether the locview attribute is present, and
9342 whether they match. Remove the locview attribute if no longer
9343 needed.
9344 (index_location_lists): Call skip_loc_list_entry for test.
9345 (dwarf2out_finish): Call output_asm_line_debug_info for test.
9346 Use output_dwarf_version.
9347 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
9348 (struct dw_val_node): Add val_view_list.
9349 * final.c (SEEN_NEXT_VIEW): New.
9350 (set_next_view_needed): New.
9351 (clear_next_view_needed): New.
9352 (maybe_output_next_view): New.
9353 (final_start_function): Rename to...
9354 (final_start_function_1): ... this. Take pointer to FIRST,
9355 add SEEN parameter. Emit param bindings in the initial view.
9356 (final_start_function): Reintroduce SEEN-less interface.
9357 (final): Rename to...
9358 (final_1): ... this. Take SEEN parameter. Output final pending
9359 next view at the end.
9360 (final): Reintroduce seen-less interface.
9361 (final_scan_insn): Output pending next view before switching
9362 sections or ending a block. Mark the next view as needed when
9363 outputting variable locations. Notify debug backend of section
9364 changes, and of location view changes.
9365 (rest_of_handle_final): Adjust.
9366 * toplev.c (process_options): Autodetect value for debug variable
9367 location views option. Warn on incompat5 without -gdwarf-5.
9368 * doc/invoke.texi (gvariable-location-views): New.
9369 (gvariable-location-views=incompat5): New.
9370 (gno-variable-location-views): New.
9371
9372 2018-02-08 David Malcolm <dmalcolm@redhat.com>
9373
9374 PR tree-optimization/84136
9375 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
9376 that the result of find_edge is non-NULL.
9377
9378 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
9379
9380 PR target/83008
9381 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
9382 storing integer register in SImode. Fix cost of 256 and 512
9383 byte aligned SSE register store.
9384
9385 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
9386
9387 * config/i386/i386.c (ix86_multiplication_cost): Fix
9388 multiplication cost for TARGET_AVX512DQ.
9389
9390 2018-02-08 Marek Polacek <polacek@redhat.com>
9391
9392 PR tree-optimization/84238
9393 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
9394 get_range_strlen.
9395
9396 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
9397
9398 PR tree-optimization/84265
9399 * tree-vect-stmts.c (vectorizable_store): Don't treat
9400 VMAT_CONTIGUOUS accesses as grouped.
9401 (vectorizable_load): Likewise.
9402
9403 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
9404
9405 PR tree-optimization/81635
9406 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
9407 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
9408 (test_round_for_mask): New functions.
9409 (wide_int_cc_tests): Call test_round_for_mask.
9410 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
9411 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
9412 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
9413 range returned by get_range_info.
9414
9415 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
9416
9417 PR ipa/81360
9418 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
9419 * symtab.c: Include builtins.h
9420 (symtab_node::output_to_lto_symbol_table_p): Move here
9421 from lto-streamer-out.c:output_symbol_p.
9422 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
9423 (output_symbol_p): Move all logic to symtab.c
9424 (produce_symtab): Update.
9425
9426 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
9427
9428 * config/s390/s390-opts.h (enum indirect_branch): Define.
9429 * config/s390/s390-protos.h (s390_return_addr_from_memory)
9430 (s390_indirect_branch_via_thunk)
9431 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
9432 (enum s390_indirect_branch_type): Define.
9433 * config/s390/s390.c (struct s390_frame_layout, struct
9434 machine_function): Remove.
9435 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
9436 (indirect_branch_table_label_no, indirect_branch_table_name):
9437 Define variables.
9438 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
9439 (enum s390_indirect_branch_option): Define.
9440 (s390_return_addr_from_memory): New function.
9441 (s390_handle_string_attribute): New function.
9442 (s390_attribute_table): Add new attribute handler.
9443 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
9444 (s390_indirect_branch_via_thunk): New function.
9445 (s390_indirect_branch_via_inline_thunk): New function.
9446 (s390_function_ok_for_sibcall): When jumping via thunk disallow
9447 sibling call optimization for non z10 compiles.
9448 (s390_emit_call): Force indirect branch target to be a single
9449 register. Add r1 clobber for non-z10 compiles.
9450 (s390_emit_epilogue): Emit return jump via return_use expander.
9451 (s390_reorg): Handle JUMP_INSNs as execute targets.
9452 (s390_option_override_internal): Perform validity checks for the
9453 new command line options.
9454 (s390_indirect_branch_attrvalue): New function.
9455 (s390_indirect_branch_settings): New function.
9456 (s390_set_current_function): Invoke s390_indirect_branch_settings.
9457 (s390_output_indirect_thunk_function): New function.
9458 (s390_code_end): Implement target hook.
9459 (s390_case_values_threshold): Implement target hook.
9460 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
9461 macros.
9462 * config/s390/s390.h (struct s390_frame_layout)
9463 (struct machine_function): Move here from s390.c.
9464 (TARGET_INDIRECT_BRANCH_NOBP_RET)
9465 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
9466 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
9467 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
9468 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
9469 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
9470 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
9471 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
9472 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
9473 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
9474 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
9475 (mnemonic attribute): Add values which aren't recognized
9476 automatically.
9477 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
9478 pattern for branch conversion. Fix mnemonic attribute.
9479 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
9480 indirect branch via thunk if requested.
9481 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
9482 ("*indirect_jump"): Disable for branch conversion using out of
9483 line thunks.
9484 ("indirect_jump_via_thunk<mode>_z10")
9485 ("indirect_jump_via_thunk<mode>")
9486 ("indirect_jump_via_inlinethunk<mode>_z10")
9487 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
9488 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
9489 ("casesi_jump_via_inlinethunk<mode>_z10")
9490 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
9491 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
9492 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
9493 ("*indirect2_jump"): Disable for branch conversion.
9494 ("casesi_jump"): Turn into expander and expand patterns for branch
9495 conversion.
9496 ("return_use"): New expander.
9497 ("*return"): Emit return via thunk and rename it to ...
9498 ("*return<mode>"): ... this one.
9499 * config/s390/s390.opt: Add new options and and enum for the
9500 option values.
9501
9502 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
9503
9504 * lra-constraints.c (match_reload): Unconditionally use
9505 gen_lowpart_SUBREG, rather than selecting between that
9506 and equivalent gen_rtx_SUBREG code.
9507
9508 2018-02-08 Richard Biener <rguenther@suse.de>
9509
9510 PR tree-optimization/84233
9511 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
9512 changed flag instead of boguously re-using phi_inserted.
9513
9514 2018-02-08 Martin Jambor <mjambor@suse.cz>
9515
9516 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
9517 static local variables.
9518
9519 2018-02-08 Richard Biener <rguenther@suse.de>
9520
9521 PR tree-optimization/84278
9522 * tree-vect-stmts.c (vectorizable_store): When looking for
9523 smaller vector types to perform grouped strided loads/stores
9524 make sure the mode is supported by the target.
9525 (vectorizable_load): Likewise.
9526
9527 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
9528
9529 * config/aarch64/aarch64.c (aarch64_components_for_bb):
9530 Increase LDP/STP opportunities by adding adjacent callee-saves.
9531
9532 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
9533
9534 PR rtl-optimization/84068
9535 PR rtl-optimization/83459
9536 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
9537
9538 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
9539
9540 PR tree-optimization/84224
9541 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
9542 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
9543 non-zero arguments.
9544
9545 2018-02-07 Iain Sandoe <iain@codesourcery.com>
9546
9547 PR target/84113
9548 * config/rs6000/altivec.md (*restore_world): Remove LR use.
9549 * config/rs6000/predicates.md (restore_world_operation): Adjust op
9550 count, remove one USE.
9551
9552 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
9553
9554 * doc/install.texi (Configuration): Document the
9555 --with-long-double-format={ibm,ieee} PowerPC configuration
9556 options.
9557
9558 PR target/84154
9559 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
9560 Convert from define_expand to be define_insn_and_split. Rework
9561 float/double/_Float128 conversions to QI/HI/SImode to work with
9562 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
9563 conversions to QI/HImode types did a store and then a load to
9564 truncate the value. For conversions to VSX registers, don't split
9565 the insn, instead emit the code directly. Use the code iterator
9566 any_fix to combine signed and unsigned conversions.
9567 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
9568 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
9569 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
9570 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
9571 (fix_<mode>di2_hw): Likewise.
9572 (fixuns_<mode>di2_hw): Likewise.
9573 (fix_<mode>si2_hw): Likewise.
9574 (fixuns_<mode>si2_hw): Likewise.
9575 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
9576 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
9577 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
9578 fix<uns>_trunc<SFDF:mode>si2_p8.
9579 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer
9580 used.
9581 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
9582 (fix<uns>_<mode>_mem): Likewise.
9583 (fctiw<u>z_<mode>_mem): Likewise.
9584 (fix<uns>_<mode>_mem): Likewise.
9585 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
9586 the register allocator from doing a direct move to the GPRs to do
9587 a store, and instead use the ISA 3.0 store byte/half-word from
9588 vector register instruction. For IEEE 128-bit floating point,
9589 also optimize stores of 32-bit ints.
9590 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
9591
9592 2018-02-07 Alan Hayward <alan.hayward@arm.com>
9593
9594 * genextract.c (push_pathstr_operand): New function to support
9595 [a-zA-Z].
9596 (walk_rtx): Call push_pathstr_operand.
9597 (print_path): Support [a-zA-Z].
9598
9599 2018-02-07 Richard Biener <rguenther@suse.de>
9600
9601 PR tree-optimization/84037
9602 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
9603 (cse_and_gimplify_to_preheader): Declare.
9604 (vect_get_place_in_interleaving_chain): Likewise.
9605 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
9606 ivexpr_map.
9607 (_loop_vec_info::~_loop_vec_info): Delete it.
9608 (cse_and_gimplify_to_preheader): New function.
9609 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
9610 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
9611 (vectorizable_load): Likewise. For grouped stores always base
9612 the IV on the first element.
9613 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
9614 condition before gimplifying.
9615
9616 2018-02-07 Jakub Jelinek <jakub@redhat.com>
9617
9618 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
9619 *DIV_EXPR and *MOD_EXPR.
9620
9621 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
9622
9623 PR target/84248
9624 * config/i386/i386.c (ix86_option_override_internal): Mask out
9625 the CF_SET bit when checking -fcf-protection.
9626
9627 2018-02-07 Tom de Vries <tom@codesourcery.com>
9628
9629 PR libgomp/84217
9630 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
9631 enough.
9632
9633 2018-02-07 Richard Biener <rguenther@suse.de>
9634
9635 PR tree-optimization/84204
9636 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
9637 this place.
9638
9639 PR tree-optimization/84205
9640 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
9641 special-case isl_ast_op_zdiv_r.
9642
9643 PR tree-optimization/84223
9644 * graphite-scop-detection.c (gather_bbs::before_dom_children):
9645 Only add conditions from within the region.
9646 (gather_bbs::after_dom_children): Adjust.
9647
9648 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
9649
9650 PR target/84209
9651 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
9652 * config/avr/avr.md: Only post-reload split REG-REG moves if
9653 either register is GENERAL_REG_P.
9654
9655 2018-02-07 Jakub Jelinek <jakub@redhat.com>
9656
9657 PR tree-optimization/84235
9658 * tree-ssa-scopedtables.c
9659 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
9660 if the subtraction is performed in floating point type where NaNs are
9661 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
9662 build 1. Formatting fix.
9663
9664 2018-02-06 Jakub Jelinek <jakub@redhat.com>
9665
9666 PR target/84146
9667 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
9668 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
9669 and skip it regardless of bb boundaries. Use CALL_P macro,
9670 don't test INSN_P (insn) together with CALL_P or JUMP_P check
9671 unnecessarily, formatting fix.
9672
9673 2018-02-06 Michael Collison <michael.collison@arm.com>
9674
9675 * config/arm/thumb2.md:
9676 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
9677 (*thumb_mov_notscc): Ditto.
9678
9679 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
9680
9681 PR target/84154
9682 * config/rs6000/rs6000.md (su code attribute): Use "u" for
9683 unsigned_fix, not "s".
9684
9685 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9686
9687 * configure.ac (gcc_fn_eh_frame_ro): New function.
9688 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
9689 correct .eh_frame permissions.
9690 * configure: Regenerate.
9691
9692 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
9693
9694 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
9695 irrelevant options.
9696
9697 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
9698
9699 * config/rs6000/rs6000.c (rs6000_option_override_internal):
9700 Display warning message for -mno-speculate-indirect-jumps.
9701
9702 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
9703
9704 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
9705 Undocumented.
9706 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
9707
9708 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
9709
9710 PR tree-optimization/84225
9711 * tree-eh.c (find_trapping_overflow): Only call
9712 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
9713
9714 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
9715
9716 PR target/84145
9717 * config/i386/i386.c: Reimplement the check of possible options
9718 -mibt/-mshstk conbination. Change error messages.
9719 * doc/invoke.texi: Fix a typo: remove extra '='.
9720
9721 2018-02-06 Marek Polacek <polacek@redhat.com>
9722
9723 PR tree-optimization/84228
9724 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
9725
9726 2018-02-06 Tamar Christina <tamar.christina@arm.com>
9727
9728 PR target/82641
9729 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
9730 emitted arch directives.
9731 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
9732 __ARM_FEATURE_COPROC before changing architectures.
9733
9734 2018-02-06 Richard Biener <rguenther@suse.de>
9735
9736 * config/i386/i386.c (print_reg): Fix typo.
9737 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
9738
9739 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
9740
9741 * configure: Regenerate.
9742
9743 2018-02-05 Martin Sebor <msebor@redhat.com>
9744
9745 PR tree-optimization/83369
9746 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
9747 inlining context.
9748
9749 2018-02-05 Martin Liska <mliska@suse.cz>
9750
9751 * doc/invoke.texi: Cherry-pick upstream r323995.
9752
9753 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
9754
9755 * ira.c (ira_init_register_move_cost): Adjust comment.
9756
9757 2018-02-05 Martin Liska <mliska@suse.cz>
9758
9759 PR gcov-profile/84137
9760 * doc/gcov.texi: Fix typo in documentation.
9761
9762 2018-02-05 Martin Liska <mliska@suse.cz>
9763
9764 PR gcov-profile/83879
9765 * doc/gcov.texi: Document necessity of --dynamic-list-data when
9766 using dlopen functionality.
9767
9768 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
9769
9770 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
9771 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
9772 _mm_maskz_range_ss, _mm_mask_range_round_ss,
9773 _mm_maskz_range_round_ss): New intrinsics.
9774 (__builtin_ia32_rangesd128_round)
9775 (__builtin_ia32_rangess128_round): Remove.
9776 (__builtin_ia32_rangesd128_mask_round,
9777 __builtin_ia32_rangess128_mask_round): New builtins.
9778 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
9779 __builtin_ia32_rangess128_round): Remove.
9780 (__builtin_ia32_rangesd128_mask_round,
9781 __builtin_ia32_rangess128_mask_round): New builtins.
9782 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
9783 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
9784 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
9785 "<round_saeonly_constraint>")): Changed to ...
9786 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
9787 "<round_saeonly_scalar_constraint>")): ... this.
9788 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
9789 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
9790 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
9791 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
9792 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
9793
9794 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
9795
9796 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
9797 options.
9798 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
9799 Remove all values except native, 8540 and 8548.
9800
9801 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
9802
9803 * config/i386/i386.c (ix86_output_function_return): Pass
9804 INVALID_REGNUM, instead of -1, as invalid register number to
9805 indirect_thunk_name and output_indirect_thunk.
9806
9807 2018-02-02 Julia Koval <julia.koval@intel.com>
9808
9809 * config.gcc: Add -march=icelake.
9810 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
9811 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
9812 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
9813 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
9814 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
9815 (processor_target_table): Add icelake.
9816 (ix86_option_override_internal): Handle new PTAs.
9817 (get_builtin_code_for_version): Handle icelake.
9818 (M_INTEL_COREI7_ICELAKE): New.
9819 (fold_builtin_cpu): Handle icelake.
9820 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
9821 * doc/invoke.texi: Add -march=icelake.
9822
9823 2018-02-02 Julia Koval <julia.koval@intel.com>
9824
9825 * config/i386/i386.c (ix86_option_override_internal): Change flags type
9826 to wide_int_bitmask.
9827 * wide-int-bitmask.h: New.
9828
9829 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
9830
9831 PR target/84066
9832 * config/i386/i386.md: Replace Pmode with word_mode in
9833 builtin_setjmp_setup and builtin_longjmp to support x32.
9834
9835 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
9836
9837 PR target/56010
9838 PR target/83743
9839 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
9840 #include "opts.h".
9841 (rs6000_supported_cpu_names): New static variable.
9842 (linux_cpu_translation_table): Likewise.
9843 (elf_platform) <cpu>: Define new static variable and use it.
9844 Translate kernel AT_PLATFORM name to canonical name if needed.
9845 Error if platform name is unknown.
9846
9847 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
9848
9849 PR target/84089
9850 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
9851
9852 2018-02-01 Jeff Law <law@redhat.com>
9853
9854 PR target/84128
9855 * config/i386/i386.c (release_scratch_register_on_entry): Add new
9856 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
9857 the scratch if RELEASE_VIA_POP is false.
9858 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
9859 If we have to save a temporary register, decrement SIZE appropriately.
9860 Pass new arguments to release_scratch_register_on_entry.
9861 (ix86_adjust_stack_and_probe): Likewise.
9862 (ix86_emit_probe_stack_range): Pass new arguments to
9863 release_scratch_register_on_entry.
9864
9865 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
9866
9867 PR rtl-optimization/84157
9868 * combine.c (change_zero_ext): Use REG_P predicate in
9869 front of HARD_REGISTER_P predicate.
9870
9871 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
9872
9873 * config/avr/avr.c (avr_option_override): Move disabling of
9874 -fdelete-null-pointer-checks to...
9875 * common/config/avr/avr-common.c (avr_option_optimization_table):
9876 ...here.
9877
9878 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9879
9880 PR tree-optimization/81635
9881 * tree-data-ref.c (split_constant_offset_1): For types that
9882 wrap on overflow, try to use range info to prove that wrapping
9883 cannot occur.
9884
9885 2018-02-01 Renlin Li <renlin.li@arm.com>
9886
9887 PR target/83370
9888 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
9889 TAILCALL_ADDR_REGS.
9890 (aarch64_register_move_cost): Likewise.
9891 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
9892 TAILCALL_ADDR_REGS.
9893 (REG_CLASS_NAMES): Likewise.
9894 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
9895 TAILCALL_ADDR_REGS. Remove IP registers.
9896 * config/aarch64/aarch64.md (Ucs): Update register constraint.
9897
9898 2018-02-01 Richard Biener <rguenther@suse.de>
9899
9900 * domwalk.h (dom_walker::dom_walker): Add additional constructor
9901 for specifying RPO order and allow NULL for that.
9902 * domwalk.c (dom_walker::dom_walker): Likewise.
9903 (dom_walker::walk): Handle NULL RPO order.
9904 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
9905 in RPO order.
9906 (rewrite_update_dom_walker): Likewise.
9907 (mark_def_dom_walker): Likewise.
9908
9909 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9910
9911 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
9912 (aarch64_maybe_expand_sve_subreg_move): Declare.
9913 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
9914 * config/aarch64/predicates.md (aarch64_any_register_operand): New
9915 predicate.
9916 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
9917 that are semantically a reverse operation.
9918 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
9919 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
9920 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
9921 functions.
9922 (aarch64_can_change_mode_class): For big-endian, forbid changes
9923 between two SVE modes if they have different element sizes.
9924
9925 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9926
9927 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
9928 the TImode handling for big-endian targets.
9929
9930 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9931
9932 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
9933 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
9934 not just bytes.
9935 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
9936 Remove BSWAP handing for big-endian targets and use the form of
9937 LD1RQ appropariate for the mode.
9938
9939 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9940
9941 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
9942 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
9943 duplicated element.
9944
9945 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9946
9947 PR tearget/83845
9948 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
9949 check for operands that need to go through aarch64_sve_reload_be.
9950
9951 2018-02-01 Jakub Jelinek <jakub@redhat.com>
9952
9953 PR tree-optimization/81661
9954 PR tree-optimization/84117
9955 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
9956 * tree-eh.c: Include gimplify.h.
9957 (find_trapping_overflow, replace_trapping_overflow,
9958 rewrite_to_non_trapping_overflow): New functions.
9959 * tree-vect-loop.c: Include tree-eh.h.
9960 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
9961 * tree-data-ref.c: Include tree-eh.h.
9962 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
9963
9964 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
9965
9966 PR rtl-optimization/84123
9967 * combine.c (change_zero_ext): Check if hard register satisfies
9968 can_change_dest_mode before calling gen_lowpart_SUBREG.
9969
9970 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
9971
9972 PR target/82444
9973 * ira.c (ira_init_register_move_cost): Remove assert.
9974
9975 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
9976
9977 PR rtl-optimization/84071
9978 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
9979 * doc/tm.texi: Regenerate.
9980
9981 2018-01-31 Richard Biener <rguenther@suse.de>
9982
9983 PR tree-optimization/84132
9984 * tree-data-ref.c (analyze_miv_subscript): Properly
9985 check whether evolution_function_is_affine_multivariate_p
9986 before calling gcd_of_steps_may_divide_p.
9987
9988 2018-01-31 Julia Koval <julia.koval@intel.com>
9989
9990 PR target/83618
9991 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
9992 * config/i386/i386.md (rdpid_rex64) New.
9993 (rdpid): Make 32bit only.
9994
9995 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
9996
9997 PR lto/84105
9998 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
9999 an IDENTIFIER_NODE for FUNCTION_TYPE's.
10000
10001 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
10002
10003 Revert
10004 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
10005
10006 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
10007
10008 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
10009
10010 PR rtl-optimization/84071
10011 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
10012 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
10013
10014 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
10015
10016 * config/arc/arc.c (arc_handle_aux_attribute): New function.
10017 (arc_attribute_table): Add 'aux' attribute.
10018 (arc_in_small_data_p): Consider aux like variables.
10019 (arc_is_aux_reg_p): New function.
10020 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
10021 (arc_get_aux_arg): New function.
10022 (prepare_move_operands): Handle aux-register access.
10023 (arc_handle_aux_attribute): New function.
10024 * doc/extend.texi (ARC Variable attributes): Add subsection.
10025
10026 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
10027
10028 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
10029 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
10030 (arc_attribute_table): Add 'uncached' attribute.
10031 (arc_print_operand): Print '.di' flag for uncached memory
10032 accesses.
10033 (arc_in_small_data_p): Do not consider for small data the uncached
10034 types.
10035 (arc_is_uncached_mem_p): New function.
10036 * config/arc/predicates.md (compact_store_memory_operand): Check
10037 for uncached memory accesses.
10038 (nonvol_nonimm_operand): Likewise.
10039 * gcc/doc/extend.texi (ARC Type Attribute): New subsection.
10040
10041 2018-01-31 Jakub Jelinek <jakub@redhat.com>
10042
10043 PR c/84100
10044 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
10045 falign-loops=): Add Optimization flag.
10046
10047 2018-01-30 Jeff Law <law@redhat.com>
10048
10049 PR target/84064
10050 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
10051 INT_REGISTERS_SAVED. Check it prior to calling
10052 get_scratch_register_on_entry.
10053 (ix86_adjust_stack_and_probe): Similarly.
10054 (ix86_emit_probe_stack_range): Similarly.
10055 (ix86_expand_prologue): Corresponding changes.
10056
10057 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10058
10059 PR target/40411
10060 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
10061 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
10062
10063 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
10064
10065 PR target/84112
10066 * lra-constraints.c (curr_insn_transform): Process AND in the
10067 address.
10068
10069 2018-01-30 Jakub Jelinek <jakub@redhat.com>
10070
10071 PR rtl-optimization/83986
10072 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
10073 dependence against last_pending_memory_flush in addition to
10074 pending_jump_insns.
10075
10076 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
10077
10078 PR tree-optimization/81611
10079 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
10080 copies.
10081
10082 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
10083
10084 PR target/83758
10085 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
10086 a reg rtx.
10087
10088 2018-01-30 Richard Biener <rguenther@suse.de>
10089 Jakub Jelinek <jakub@redhat.com>
10090
10091 PR tree-optimization/84111
10092 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
10093 inner loops added during recursion, as they don't have up-to-date
10094 SSA form.
10095
10096 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
10097
10098 PR ipa/81360
10099 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
10100 (can_inline_edge_by_limits_p): ... here.
10101 (can_early_inline_edge_p, check_callers,
10102 update_caller_keys, update_callee_keys, recursive_inlining,
10103 add_new_edges_to_heap, speculation_useful_p,
10104 inline_small_functions,
10105 inline_small_functions, flatten_function,
10106 inline_to_all_callers_1): Update.
10107
10108 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
10109
10110 * profile-count.c (profile_count::combine_with_ipa_count): Handle
10111 zeros correctly.
10112
10113 2018-01-30 Richard Biener <rguenther@suse.de>
10114
10115 PR tree-optimization/83008
10116 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
10117 invariant and constant vector uses in stmts when they need
10118 more than one stmt.
10119
10120 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10121
10122 PR bootstrap/84017
10123 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
10124 * configure: Regenerate.
10125
10126 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
10127
10128 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
10129 pattern.
10130 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
10131 Use gen_rtx_REG rather than gen_lowpart.
10132
10133 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
10134
10135 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
10136 rather than 0 when creating partial subregs.
10137
10138 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
10139
10140 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
10141 of usage.
10142
10143 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
10144
10145 PR target/81550
10146 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
10147 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
10148 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
10149 flags. This restores the settings used before the 2017-07-24.
10150 Turning off pre increment/decrement/modify allows IVOPTS to
10151 optimize DF/SF loops where the index is an int.
10152
10153 2018-01-29 Richard Biener <rguenther@suse.de>
10154 Kelvin Nilsen <kelvin@gcc.gnu.org>
10155
10156 PR bootstrap/80867
10157 * tree-vect-stmts.c (vectorizable_call): Don't call
10158 targetm.vectorize_builtin_md_vectorized_function if callee is
10159 NULL.
10160
10161 2018-01-22 Carl Love <cel@us.ibm.com>
10162
10163 * doc/extend.tex: Fix typo in second arg in
10164 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
10165
10166 2018-01-29 Richard Biener <rguenther@suse.de>
10167
10168 PR tree-optimization/84086
10169 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
10170 (flush_ssaname_freelist): When SSA names were released reset
10171 the SCEV hash table.
10172
10173 2018-01-29 Richard Biener <rguenther@suse.de>
10174
10175 PR tree-optimization/84057
10176 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
10177 removed paths when removing edges.
10178
10179 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
10180
10181 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
10182 -mfunction-return=@var{choice}.
10183
10184 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
10185
10186 PR diagnostic/84034
10187 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
10188 Handle CR like TAB.
10189 (layout::print_source_line): Likewise.
10190 (test_get_line_width_without_trailing_whitespace): Add test cases.
10191
10192 2018-01-27 Jakub Jelinek <jakub@redhat.com>
10193
10194 PR middle-end/84040
10195 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
10196 debug insns.
10197
10198 2018-01-26 Jim Wilson <jimw@sifive.com>
10199
10200 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
10201
10202 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
10203 specified.
10204
10205 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10206
10207 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
10208 and CMP + SUB-immediate -> SUBS.
10209
10210 2018-01-26 Martin Sebor <msebor@redhat.com>
10211
10212 PR tree-optimization/83896
10213 * tree-ssa-strlen.c (get_string_len): Rename...
10214 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
10215 Avoid assuming length is constant.
10216 (handle_char_store): Use HOST_WIDE_INT for string length.
10217
10218 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
10219
10220 PR target/81763
10221 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
10222 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
10223
10224 2018-01-26 Richard Biener <rguenther@suse.de>
10225
10226 PR rtl-optimization/84003
10227 * dse.c (record_store): Only record redundant stores when
10228 the earlier store aliases at least all accesses the later one does.
10229
10230 2018-01-26 Jakub Jelinek <jakub@redhat.com>
10231
10232 PR rtl-optimization/83985
10233 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
10234 REG_CFA_RESTORE insns.
10235 (delete_unmarked_insns): Don't ignore separate shrink wrapping
10236 REG_CFA_RESTORE insns here.
10237
10238 PR c/83989
10239 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
10240 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
10241
10242 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10243
10244 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
10245 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
10246 (arc_init): Likewise.
10247 (arc_override_options): Likewise.
10248 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
10249 value.
10250 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
10251 support.
10252 * config/arc/arc.h (TARGET_DBNZ): Define.
10253 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
10254 properly set the tune attribute.
10255 (dbnz): Use TARGET_DBNZ guard.
10256 * config/arc/arc.opt (mtune): Add core3 option.
10257
10258 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10259
10260 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
10261 recognize new pic like addresses.
10262 (arc_delegitimize_address): Clean up.
10263
10264 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10265
10266 * config/arc/arc-arches.def: Option mrf16 valid for all
10267 architectures.
10268 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
10269 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
10270 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
10271 * config/arc/arc-tables.opt: Regenerate.
10272 * config/arc/arc.c (arc_conditional_register_usage): Handle
10273 reduced register file case.
10274 (arc_file_start): Set must have build attributes.
10275 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
10276 mrf16 option value.
10277 * config/arc/arc.opt (mrf16): Add new option.
10278 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
10279 * config/arc/genmultilib.awk: Handle new mrf16 option.
10280 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
10281 * config/arc/t-multilib: Regenerate.
10282 * doc/invoke.texi (ARC Options): Document mrf16 option.
10283
10284 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10285
10286 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
10287 * config/arc/arc.c (arc_handle_secure_attribute): New function.
10288 (arc_attribute_table): Add 'secure_call' attribute.
10289 (arc_print_operand): Print secure call operand.
10290 (arc_function_ok_for_sibcall): Don't optimize tail calls when
10291 secure.
10292 (arc_is_secure_call_p): New function. * config/arc/arc.md
10293 (call_i): Add support for sjli instruction.
10294 (call_value_i): Likewise.
10295 * config/arc/constraints.md (Csc): New constraint.
10296
10297 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10298 John Eric Martin <John.Martin@emmicro-us.com>
10299
10300 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
10301 * config/arc/arc.c (_arc_jli_section): New struct.
10302 (arc_jli_section): New type.
10303 (rc_jli_sections): New static variable.
10304 (arc_handle_jli_attribute): New function.
10305 (arc_attribute_table): Add jli_always and jli_fixed attribute.
10306 (arc_file_end): New function.
10307 (TARGET_ASM_FILE_END): Define.
10308 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
10309 (arc_add_jli_section): New function.
10310 (jli_call_scan): Likewise.
10311 (arc_reorg): Call jli_call_scan.
10312 (arc_output_addsi): Remove 'S' from printing asm operand.
10313 (arc_is_jli_call_p): New function.
10314 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
10315 operand.
10316 (movhi_insn): Likewise.
10317 (movsi_insn): Likewise.
10318 (movsi_set_cc_insn): Likewise.
10319 (loadqi_update): Likewise.
10320 (load_zeroextendqisi_update): Likewise.
10321 (load_signextendqisi_update): Likewise.
10322 (loadhi_update): Likewise.
10323 (load_zeroextendhisi_update): Likewise.
10324 (load_signextendhisi_update): Likewise.
10325 (loadsi_update): Likewise.
10326 (loadsf_update): Likewise.
10327 (movsicc_insn): Likewise.
10328 (bset_insn): Likewise.
10329 (bxor_insn): Likewise.
10330 (bclr_insn): Likewise.
10331 (bmsk_insn): Likewise.
10332 (bicsi3_insn): Likewise.
10333 (cmpsi_cc_c_insn): Likewise.
10334 (movsi_ne): Likewise.
10335 (movsi_cond_exec): Likewise.
10336 (clrsbsi2): Likewise.
10337 (norm_f): Likewise.
10338 (normw): Likewise.
10339 (swap): Likewise.
10340 (divaw): Likewise.
10341 (flag): Likewise.
10342 (sr): Likewise.
10343 (kflag): Likewise.
10344 (ffs): Likewise.
10345 (ffs_f): Likewise.
10346 (fls): Likewise.
10347 (call_i): Remove 'S' asm letter, add jli instruction.
10348 (call_value_i): Likewise.
10349 * config/arc/arc.op (mjli-always): New option.
10350 * config/arc/constraints.md (Cji): New constraint.
10351 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
10352 operand.
10353 (subsf3_fpx): Likewise.
10354 (mulsf3_fpx): Likewise.
10355 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
10356 asm operand.
10357 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
10358 function attrbutes.
10359 * doc/invoke.texi (ARC): Document mjli-always option.
10360
10361 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
10362
10363 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
10364 avoid addition with 0 and use incw and decw where possible.
10365
10366 2018-01-26 Richard Biener <rguenther@suse.de>
10367
10368 PR tree-optimization/81082
10369 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
10370 association if it requires casting to unsigned.
10371 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
10372 from fold_plusminus_mult_expr to catch important cases late when
10373 range info is available.
10374
10375 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10376
10377 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
10378 * configure.ac (hidden_linkonce): New test.
10379 * configure: Regenerate.
10380 * config.in: Regenerate.
10381
10382 2018-01-26 Julia Koval <julia.koval@intel.com>
10383
10384 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
10385 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
10386 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
10387 _mm_mask_bitshuffle_epi64_mask): Fix type.
10388 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
10389 USI_FTYPE_V4DI_V4DI_USI): Remove.
10390 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
10391 __builtin_ia32_vpshufbitqmb256_mask,
10392 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
10393 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
10394 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
10395
10396 2018-01-26 Alan Modra <amodra@gmail.com>
10397
10398 PR target/84033
10399 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
10400 UNSPEC_VBPERMQ. Sort other unspecs.
10401
10402 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
10403
10404 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
10405
10406 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
10407
10408 PR middle-end/83055
10409 * predict.c (drop_profile): Do not push/pop cfun; update also
10410 node->count.
10411 (handle_missing_profiles): Fix logic looking for zero profiles.
10412
10413 2018-01-25 Jakub Jelinek <jakub@redhat.com>
10414
10415 PR middle-end/83977
10416 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
10417 on functions with #pragma omp declare simd or functions with simd
10418 attribute.
10419 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
10420 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
10421 Remove trailing \n from warning_at calls.
10422
10423 2018-01-25 Tom de Vries <tom@codesourcery.com>
10424
10425 PR target/84028
10426 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
10427 for neutered workers.
10428
10429 2018-01-24 Joseph Myers <joseph@codesourcery.com>
10430
10431 PR target/68467
10432 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
10433 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
10434
10435 2018-01-24 Jeff Law <law@redhat.com>
10436
10437 PR target/83994
10438 * i386.c (get_probe_interval): Move to earlier point.
10439 (ix86_compute_frame_layout): If -fstack-clash-protection and
10440 the frame is larger than the probe interval, then use pushes
10441 to save registers rather than reg->mem moves.
10442 (ix86_expand_prologue): Remove conditional for int_registers_saved
10443 assertion.
10444
10445 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
10446
10447 PR target/84014
10448 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
10449 min/max for never referenced object.
10450
10451 2018-01-24 Jakub Jelinek <jakub@redhat.com>
10452
10453 PR middle-end/83977
10454 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
10455 here.
10456 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
10457 attributes from DECL_ATTRIBUTES (decl) without affecting
10458 DECL_ATTRIBUTES (current_function_decl).
10459 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
10460 functions with non-NULL DECL_ABSTRACT_ORIGIN.
10461
10462 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
10463
10464 PR tree-optimization/83979
10465 * fold-const.c (fold_comparison): Use constant_boolean_node
10466 instead of boolean_{true,false}_node.
10467
10468 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
10469
10470 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
10471 with zero counts.
10472
10473 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
10474
10475 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
10476 Simplify the clause that sets the length attribute.
10477 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
10478 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
10479 clause that sets the length attribute.
10480 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
10481
10482 2018-01-24 Tom de Vries <tom@codesourcery.com>
10483
10484 PR target/83589
10485 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
10486 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
10487 Add strict parameter.
10488 (prevent_branch_around_nothing): Insert dummy insn between branch to
10489 label and label with no ptx insn inbetween.
10490 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
10491
10492 2018-01-24 Tom de Vries <tom@codesourcery.com>
10493
10494 PR target/81352
10495 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
10496 for neutered threads in warp.
10497 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
10498
10499 2018-01-24 Richard Biener <rguenther@suse.de>
10500
10501 PR tree-optimization/83176
10502 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
10503 operands.
10504
10505 2018-01-24 Richard Biener <rguenther@suse.de>
10506
10507 PR tree-optimization/82819
10508 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
10509 code generating pluses that are no-ops in the target precision.
10510
10511 2018-01-24 Richard Biener <rguenther@suse.de>
10512
10513 PR middle-end/84000
10514 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
10515
10516 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
10517
10518 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
10519 to merge probabilities.
10520 * predict.c (probably_never_executed): Also mark as cold functions
10521 with global 0 profile and guessed local profile.
10522 * profile-count.c (profile_probability::combine_with_count): New
10523 member function.
10524 * profile-count.h (profile_probability::operator*,
10525 profile_probability::operator*=, profile_probability::operator/,
10526 profile_probability::operator/=): Reduce precision to adjusted
10527 and set value to guessed on contradictory divisions.
10528 (profile_probability::combine_with_freq): Remove.
10529 (profile_probability::combine_wiht_count): Declare.
10530 (profile_count::force_nonzero):: Set to adjusted.
10531 (profile_count::probability_in):: Set quality to adjusted.
10532 * tree-ssa-tail-merge.c (replace_block_by): Use
10533 combine_with_count.
10534
10535 2018-01-23 Andrew Waterman <andrew@sifive.com>
10536 Jim Wilson <jimw@sifive.com>
10537
10538 * config/riscv/riscv.c (riscv_stack_boundary): New.
10539 (riscv_option_override): Set riscv_stack_boundary. Handle
10540 riscv_preferred_stack_boundary_arg.
10541 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
10542 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
10543 (STACK_BOUNDARY): Set to riscv_stack_boundary.
10544 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
10545 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
10546 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
10547
10548 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
10549
10550 PR target/83905
10551 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
10552 of struct ix86_frame.
10553 (ix86_expand_epilogue): Likewise. Add a local variable for
10554 the reg_save_offset field in struct ix86_frame.
10555
10556 2018-01-23 Bin Cheng <bin.cheng@arm.com>
10557
10558 PR tree-optimization/82604
10559 * tree-loop-distribution.c (enum partition_kind): New enum item
10560 PKIND_PARTIAL_MEMSET.
10561 (partition_builtin_p): Support above new enum item.
10562 (generate_code_for_partition): Ditto.
10563 (compute_access_range): Differentiate cases that equality can be
10564 proven at all loops, the innermost loops or no loops.
10565 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
10566 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
10567 (finalize_partitions, distribute_loop): Don't fuse partition of
10568 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
10569 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
10570 parloop is enabled.
10571
10572 2018-01-23 Martin Liska <mliska@suse.cz>
10573
10574 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
10575 order to ignore the predictor.
10576 (PRED_POLYMORPHIC_CALL): Likewise.
10577 (PRED_RECURSIVE_CALL): Likewise.
10578
10579 2018-01-23 Martin Liska <mliska@suse.cz>
10580
10581 * tree-profile.c (tree_profiling): Print function header to
10582 aware reader which function we are working on.
10583 * value-prof.c (gimple_find_values_to_profile): Do not print
10584 not interesting value histograms.
10585
10586 2018-01-23 Martin Liska <mliska@suse.cz>
10587
10588 * profile-count.h (enum profile_quality): Add
10589 profile_uninitialized as the first value. Do not number values
10590 as they are zero based.
10591 (profile_count::verify): Update sanity check.
10592 (profile_probability::verify): Likewise.
10593
10594 2018-01-23 Nathan Sidwell <nathan@acm.org>
10595
10596 * doc/invoke.texi (ffor-scope): Deprecate.
10597
10598 2018-01-23 David Malcolm <dmalcolm@redhat.com>
10599
10600 PR tree-optimization/83510
10601 * domwalk.c (set_all_edges_as_executable): New function.
10602 (dom_walker::dom_walker): Convert bool param
10603 "skip_unreachable_blocks" to enum reachability. Move setup of
10604 edge flags to set_all_edges_as_executable and only do it when
10605 reachability is REACHABLE_BLOCKS.
10606 * domwalk.h (enum dom_walker::reachability): New enum.
10607 (dom_walker::dom_walker): Convert bool param
10608 "skip_unreachable_blocks" to enum reachability.
10609 (set_all_edges_as_executable): New decl.
10610 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
10611 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
10612 "reachability".
10613 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
10614 but converting true to REACHABLE_BLOCKS.
10615 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
10616 * tree-vrp.c
10617 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
10618 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
10619 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
10620 REACHABLE_BLOCKS.
10621 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
10622 if check_all_array_refs will be called.
10623
10624 2018-01-23 David Malcolm <dmalcolm@redhat.com>
10625
10626 * tree.c (selftest::test_location_wrappers): Add more test
10627 coverage.
10628
10629 2018-01-23 David Malcolm <dmalcolm@redhat.com>
10630
10631 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
10632 (selftest::test_bit_in_range): Likewise.
10633
10634 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
10635
10636 PR testsuite/83888
10637 * doc/sourcebuild.texi (vect_float): Say that the selector
10638 only describes the situation when -funsafe-math-optimizations is on.
10639 (vect_float_strict): Document.
10640
10641 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
10642
10643 PR tree-optimization/83965
10644 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
10645 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
10646 instead of checking only for a reduction.
10647 (vect_recog_widen_sum_pattern): Likewise.
10648
10649 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
10650
10651 * predict.c (probably_never_executed): Only use precise profile info.
10652 (compute_function_frequency): Skip after inlining hack since we now
10653 have quality checking.
10654
10655 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
10656
10657 * profile-count.h (profile_probability::very_unlikely,
10658 profile_probability::unlikely, profile_probability::even): Set
10659 precision to guessed.
10660
10661 2018-01-23 Richard Biener <rguenther@suse.de>
10662
10663 PR tree-optimization/83963
10664 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
10665 Properly terminate dominator walk when crossing the exit edge not
10666 when visiting its source block.
10667
10668 2018-01-23 Jakub Jelinek <jakub@redhat.com>
10669
10670 PR c++/83918
10671 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
10672 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
10673
10674 2018-01-22 Jakub Jelinek <jakub@redhat.com>
10675
10676 PR tree-optimization/83957
10677 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
10678 semicolon after for body surrounded by braces.
10679
10680 PR tree-optimization/83081
10681 * profile-count.h (profile_probability::split): New method.
10682 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
10683 Use profile_probability::split.
10684 (do_compare_rtx_and_jump): Fix adjustment of probabilities
10685 when splitting a single conditional jump into 2.
10686
10687 2018-01-22 David Malcolm <dmalcolm@redhat.com>
10688
10689 PR tree-optimization/69452
10690 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
10691 decl.
10692
10693 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10694
10695 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
10696 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
10697 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
10698
10699 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10700
10701 * config/rl78/rl78-protos.h (rl78_split_movdi): New function declaration.
10702 * config/rl78/rl78.md (movdi): New define_expand.
10703 * config/rl78/rl78.c (rl78_split_movdi): New function.
10704
10705 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
10706
10707 PR target/83862
10708 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
10709 no longer used.
10710 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
10711 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
10712 128-bit to produce an UNSPEC move to get the double word with the
10713 signbit and then a shift directly to do signbit.
10714 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
10715 implementation with a new version that just does either a direct
10716 move or a regular move. Move memory interface to separate insns.
10717 Move insns so they are next to the expander.
10718 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
10719 with signbit move. Split big and little endian case.
10720 (signbit<mode>2_dm_mem_le): Likewise.
10721 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
10722 (signbit<mode>2_dm2): Likewise.
10723
10724 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10725
10726 * config/rl78/rl78.md (anddi3): New define_expand.
10727
10728 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10729
10730 * config/rl78/rl78.md (umindi3): New define_expand.
10731
10732 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10733
10734 * config/rl78/rl78.md (smindi3): New define_expand.
10735
10736 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10737
10738 * config/rl78/rl78.md (smaxdi3): New define_expand.
10739
10740 2018-01-22 Carl Love <cel@us.ibm.com>
10741
10742 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
10743 LVX_V1TI): Add macro expansion.
10744 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
10745 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
10746 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
10747 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
10748 Change check to determine if the instruction is a byte reversing
10749 entry. Fix typo in comment.
10750 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
10751 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
10752 Add def_builtin calls for new builtins.
10753 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
10754 Add define_insn expansion.
10755
10756 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10757
10758 * config/rl78/rl78.md (umaxdi3): New define_expand.
10759
10760 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10761
10762 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
10763 for non-QImode registers.
10764
10765 2018-01-22 Richard Biener <rguenther@suse.de>
10766
10767 PR tree-optimization/83963
10768 * graphite-scop-detection.c (scop_detection::get_sese): Delay
10769 including the loop exit block.
10770 (scop_detection::merge_sese): Likewise.
10771 (scop_detection::add_scop): Do it here instead.
10772
10773 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10774
10775 * doc/sourcebuild.texi (arm_softfloat): Document.
10776
10777 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
10778
10779 PR gcc/77734
10780 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
10781 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
10782 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
10783
10784 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
10785 David Edelsohn <dje.gcc@gmail.com>
10786
10787 PR target/83946
10788 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
10789 Change "crset eq" to "crset 2".
10790 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
10791 (*call_indirect_aix<mode>_nospec): Likewise.
10792 (*call_value_indirect_aix<mode>_nospec): Likewise.
10793 (*call_indirect_elfv2<mode>_nospec): Likewise.
10794 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
10795 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
10796 change assembly output from . to $.
10797 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
10798 (indirect_jump<mode>_nospec): Change assembly output from . to $.
10799 (*tablejump<mode>_internal1_nospec): Likewise.
10800
10801 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
10802
10803 PR target/80870
10804 * config/sh/sh_optimize_sett_clrt.cc:
10805 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
10806
10807 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
10808
10809 PR tree-optimization/83940
10810 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
10811 offset_dt to vect_constant_def rather than vect_unknown_def_type.
10812 (vect_check_load_store_mask): Add a mask_dt_out parameter and
10813 use it to pass back the definition type.
10814 (vect_check_store_rhs): Likewise rhs_dt_out.
10815 (vect_build_gather_load_calls): Add a mask_dt argument and use
10816 it instead of a call to vect_is_simple_use.
10817 (vectorizable_store): Update calls to vect_check_load_store_mask
10818 and vect_check_store_rhs. Use the dt returned by the latter instead
10819 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
10820 instead of calls to vect_is_simple_use. Pass the scalar rather
10821 than the vector operand to vect_is_simple_use when handling
10822 second and subsequent copies of an rhs value.
10823 (vectorizable_load): Update calls to vect_check_load_store_mask
10824 and vect_build_gather_load_calls. Use the cached mask_dt and
10825 gs_info.offset_dt instead of calls to vect_is_simple_use.
10826
10827 2018-01-20 Jakub Jelinek <jakub@redhat.com>
10828
10829 PR middle-end/83945
10830 * tree-emutls.c: Include gimplify.h.
10831 (lower_emutls_2): New function.
10832 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
10833 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
10834 it before further processing.
10835
10836 PR target/83930
10837 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
10838 UINTVAL (trueop1) instead of INTVAL (op1).
10839
10840 2018-01-19 Jakub Jelinek <jakub@redhat.com>
10841
10842 PR debug/81570
10843 PR debug/83728
10844 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
10845 INCOMING_FRAME_SP_OFFSET if not defined.
10846 (scan_trace): Add ENTRY argument. If true and
10847 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
10848 emit a note to adjust the CFA offset.
10849 (create_cfi_notes): Adjust scan_trace callers.
10850 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
10851 INCOMING_FRAME_SP_OFFSET in the CIE.
10852 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
10853 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
10854 Likewise.
10855 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
10856 * doc/tm.texi: Regenerated.
10857
10858 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
10859
10860 PR rtl-optimization/83147
10861 * lra-constraints.c (remove_inheritance_pseudos): Use
10862 lra_substitute_pseudo_within_insn.
10863
10864 2018-01-19 Tom de Vries <tom@codesourcery.com>
10865 Cesar Philippidis <cesar@codesourcery.com>
10866
10867 PR target/83920
10868 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
10869
10870 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
10871
10872 PR target/83790
10873 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
10874 spaces for function labels.
10875
10876 2018-01-19 Martin Liska <mliska@suse.cz>
10877
10878 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
10879 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
10880 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
10881 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
10882 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
10883 (PRED_CONST_RETURN): Change from 69 to 65.
10884 (PRED_NULL_RETURN): Change from 91 to 71.
10885 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
10886 (PRED_LOOP_GUARD): Change from 66 to 73.
10887
10888 2018-01-19 Martin Liska <mliska@suse.cz>
10889
10890 * predict.c (predict_insn_def): Add new assert.
10891 (struct branch_predictor): Change type to signed integer.
10892 (test_prediction_value_range): Amend test to cover
10893 PROB_UNINITIALIZED.
10894 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
10895 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
10896 (PRED_LOOP_ITERATIONS_MAX): Likewise.
10897 (PRED_LOOP_IV_COMPARE): Likewise.
10898 * predict.h (PROB_UNINITIALIZED): Define new constant.
10899
10900 2018-01-19 Martin Liska <mliska@suse.cz>
10901
10902 * predict.c (dump_prediction): Add new format for
10903 analyze_brprob.py script which is enabled with -details
10904 suboption.
10905 * profile-count.h (precise_p): New function.
10906
10907 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
10908
10909 PR tree-optimization/83922
10910 * tree-vect-loop.c (vect_verify_full_masking): Return false if
10911 there are no statements that need masking.
10912 (vect_active_double_reduction_p): New function.
10913 (vect_analyze_loop_operations): Use it when handling phis that
10914 are not in the loop header.
10915
10916 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
10917
10918 PR tree-optimization/83914
10919 * tree-vect-loop.c (vectorizable_induction): Don't convert
10920 init_expr or apply the peeling adjustment for inductions
10921 that are nested within the vectorized loop.
10922
10923 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10924
10925 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
10926 instead of NEG.
10927
10928 2018-01-18 Jakub Jelinek <jakub@redhat.com>
10929
10930 PR sanitizer/81715
10931 PR testsuite/83882
10932 * function.h (gimplify_parameters): Add gimple_seq * argument.
10933 * function.c: Include gimple.h and options.h.
10934 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
10935 for the added local temporaries if needed.
10936 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
10937 if there are any parameter cleanups, wrap whole body into a
10938 try/finally with the cleanups.
10939
10940 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
10941
10942 PR target/82964
10943 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
10944 Use GET_MODE_CLASS for scalar floating point.
10945
10946 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
10947
10948 PR ipa/82256
10949 patch by PaX Team
10950 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
10951 Fix call of call_cgraph_insertion_hooks.
10952
10953 2018-01-18 Martin Sebor <msebor@redhat.com>
10954
10955 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
10956
10957 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
10958
10959 PR ipa/83619
10960 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
10961 frequencies.
10962
10963 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
10964
10965 PR other/70268
10966 * common.opt: (-ffile-prefix-map): New option.
10967 * opts.c (common_handle_option): Defer it.
10968 * opts-global.c (handle_common_deferred_options): Handle it.
10969 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
10970 * file-prefix-map.h: New file.
10971 (remap_debug_filename, add_debug_prefix_map): ...here.
10972 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
10973 * final.c (debug_prefix_map, add_debug_prefix_map
10974 remap_debug_filename): Move to...
10975 * file-prefix-map.c: New file.
10976 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
10977 generalize, get rid of alloca(), use strrchr() instead of strchr().
10978 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
10979 Implement in terms of add_prefix_map().
10980 (remap_macro_filename, remap_debug_filename): Implement in term of
10981 remap_filename().
10982 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
10983 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
10984 * dbxout.c: Include file-prefix-map.h.
10985 * varasm.c: Likewise.
10986 * vmsdbgout.c: Likewise.
10987 * xcoffout.c: Likewise.
10988 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
10989 * doc/cppopts.texi (-fmacro-prefix-map): Document.
10990 * doc/invoke.texi (-ffile-prefix-map): Document.
10991 (-fdebug-prefix-map): Update description.
10992
10993 2018-01-18 Martin Liska <mliska@suse.cz>
10994
10995 * config/i386/i386.c (indirect_thunk_name): Document that also
10996 lfence is emitted.
10997 (output_indirect_thunk): Document why both instructions
10998 (pause and lfence) are generated.
10999
11000 2018-01-18 Richard Biener <rguenther@suse.de>
11001
11002 PR tree-optimization/83887
11003 * graphite-scop-detection.c
11004 (scop_detection::get_nearest_dom_with_single_entry): Remove.
11005 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
11006 (scop_detection::merge_sese): Re-implement with a flood-fill
11007 algorithm that properly finds a SESE region if it exists.
11008
11009 2018-01-18 Jakub Jelinek <jakub@redhat.com>
11010
11011 PR c/61240
11012 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
11013 pointer_diff optimizations use view_convert instead of convert.
11014
11015 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
11016
11017 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
11018 Generate different code for -mno-speculate-indirect-jumps.
11019 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
11020 (*call_indirect_aix<mode>): Disable for
11021 -mno-speculate-indirect-jumps.
11022 (*call_indirect_aix<mode>_nospec): New define_insn.
11023 (*call_value_indirect_aix<mode>): Disable for
11024 -mno-speculate-indirect-jumps.
11025 (*call_value_indirect_aix<mode>_nospec): New define_insn.
11026 (*sibcall_nonlocal_sysv<mode>): Generate different code for
11027 -mno-speculate-indirect-jumps.
11028 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
11029
11030 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
11031
11032 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
11033 long double type, set the flags for noting the default long double
11034 type, even if we don't pass or return a long double type.
11035
11036 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
11037
11038 PR ipa/83051
11039 * ipa-inline.c (flatten_function): Do not overwrite final inlining
11040 failure.
11041
11042 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
11043
11044 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
11045 support for merge[hl].
11046 (fold_mergehl_helper): New helper function.
11047 (tree-vector-builder.h): New #include for tree_vector_builder usage.
11048 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
11049 (altivec_vmrglw_direct): Add xxmrglw insn.
11050
11051 2018-01-17 Andrew Waterman <andrew@sifive.com>
11052
11053 * config/riscv/riscv.c (riscv_conditional_register_usage): If
11054 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
11055
11056 2018-01-17 David Malcolm <dmalcolm@redhat.com>
11057
11058 PR lto/83121
11059 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
11060 call the lto_location_cache before reading the
11061 DECL_SOURCE_LOCATION of the types.
11062
11063 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
11064 Richard Sandiford <richard.sandiford@linaro.org>
11065
11066 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
11067 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
11068 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
11069 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
11070 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
11071 Add declaration.
11072 * config/aarch64/constraints.md (aarch64_movti_operand):
11073 Limit immediates.
11074 * config/aarch64/predicates.md (Uti): Add new constraint.
11075
11076 2018-01-17 Carl Love <cel@us.ibm.com>
11077
11078 * config/rs6000/vsx.md (define_expand xl_len_r,
11079 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
11080 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
11081 lxvll.
11082 (define_expand, define_insn): Move the shift left from the
11083 define_insn to the define_expand for lxvl and stxvl instructions.
11084 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
11085 and XL_LEN_R definitions to PURE.
11086
11087 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
11088
11089 * config/i386/i386.c (indirect_thunk_name): Declare regno
11090 as unsigned int. Compare regno with INVALID_REGNUM.
11091 (output_indirect_thunk): Ditto.
11092 (output_indirect_thunk_function): Ditto.
11093 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
11094 in the call to output_indirect_thunk_function.
11095
11096 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
11097
11098 PR middle-end/83884
11099 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
11100 rather than the size of inner_type to determine the stack slot size
11101 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
11102
11103 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
11104
11105 PR target/83546
11106 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
11107 to PTA_SILVERMONT.
11108
11109 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
11110
11111 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
11112 endian Linux systems to optionally enable multilibs for selecting
11113 the long double type if the user configured an explicit type.
11114 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
11115 have no long double multilibs if not defined.
11116 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
11117 warn if the user used -mabi={ieee,ibm}longdouble and we built
11118 multilibs for long double.
11119 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
11120 appropriate multilib option.
11121 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
11122 multilib options.
11123 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
11124 for building long double multilibs.
11125 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
11126
11127 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
11128
11129 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
11130 copies.
11131
11132 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
11133 64 bits.
11134 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
11135 128 bits.
11136
11137 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
11138 variables.
11139
11140 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
11141 return value.
11142
11143 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
11144
11145 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
11146 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
11147
11148 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
11149
11150 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
11151 different rtl trees depending on TARGET_64BIT.
11152 (rs6000_gen_lvx): Likewise.
11153
11154 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
11155
11156 * config/visium/visium.md (nop): Tweak comment.
11157 (hazard_nop): Likewise.
11158
11159 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
11160
11161 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
11162 -mspeculate-indirect-jumps.
11163 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
11164 for -mno-speculate-indirect-jumps.
11165 (*call_indirect_elfv2<mode>_nospec): New define_insn.
11166 (*call_value_indirect_elfv2<mode>): Disable for
11167 -mno-speculate-indirect-jumps.
11168 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
11169 (indirect_jump): Emit different RTL for
11170 -mno-speculate-indirect-jumps.
11171 (*indirect_jump<mode>): Disable for
11172 -mno-speculate-indirect-jumps.
11173 (*indirect_jump<mode>_nospec): New define_insn.
11174 (tablejump): Emit different RTL for
11175 -mno-speculate-indirect-jumps.
11176 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
11177 (tablejumpsi_nospec): New define_expand.
11178 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
11179 (tablejumpdi_nospec): New define_expand.
11180 (*tablejump<mode>_internal1): Disable for
11181 -mno-speculate-indirect-jumps.
11182 (*tablejump<mode>_internal1_nospec): New define_insn.
11183 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
11184 option.
11185
11186 2018-01-16 Artyom Skrobov tyomitch@gmail.com
11187
11188 * caller-save.c (insert_save): Drop unnecessary parameter. All
11189 callers updated.
11190
11191 2018-01-16 Jakub Jelinek <jakub@redhat.com>
11192 Richard Biener <rguenth@suse.de>
11193
11194 PR libgomp/83590
11195 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
11196 return early, inline manually is_gimple_sizepos. Make sure if we
11197 call gimplify_expr we don't end up with a gimple constant.
11198 * tree.c (variably_modified_type_p): Don't return true for
11199 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
11200 * gimplify.h (is_gimple_sizepos): Remove.
11201
11202 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
11203
11204 PR tree-optimization/83857
11205 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
11206 vectorizable_live_operation for pure SLP statements.
11207 (vectorizable_live_operation): Handle PHIs.
11208
11209 2018-01-16 Richard Biener <rguenther@suse.de>
11210
11211 PR tree-optimization/83867
11212 * tree-vect-stmts.c (vect_transform_stmt): Precompute
11213 nested_in_vect_loop_p since the scalar stmt may get invalidated.
11214
11215 2018-01-16 Jakub Jelinek <jakub@redhat.com>
11216
11217 PR c/83844
11218 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
11219 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
11220 If off is not INTEGER_CST, issue a may not be aligned warning
11221 rather than isn't aligned. Use isn%'t rather than isn't.
11222 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
11223 into MULT_EXPR.
11224 <case MULT_EXPR>: Improve the case when bottom and one of the
11225 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
11226 operand, in that case check if the other operand is multiple of
11227 bottom divided by the INTEGER_CST operand.
11228
11229 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
11230
11231 PR target/83858
11232 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
11233 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
11234 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
11235 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
11236 * config/pa/pa.c (pa_function_arg_advance): Likewise.
11237 (pa_function_arg, pa_arg_partial_bytes): Likewise.
11238 (pa_function_arg_size): New function.
11239
11240 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
11241
11242 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
11243 in a separate statement.
11244
11245 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
11246
11247 PR tree-optimization/83847
11248 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
11249 group gathers and scatters.
11250
11251 2018-01-16 Jakub Jelinek <jakub@redhat.com>
11252
11253 PR rtl-optimization/86620
11254 * params.def (max-sched-ready-insns): Bump minimum value to 1.
11255
11256 PR rtl-optimization/83213
11257 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
11258 to last if both are JUMP_INSNs.
11259
11260 PR tree-optimization/83843
11261 * gimple-ssa-store-merging.c
11262 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
11263 store_immediate_info for bswap/nop orig_stores.
11264
11265 2018-01-15 Andrew Waterman <andrew@sifive.com>
11266
11267 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
11268 !TARGET_MUL.
11269 <UDIV>: Increase cost if !TARGET_DIV.
11270
11271 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
11272
11273 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
11274 (define_attr "cr_logical_3op"): New.
11275 (cceq_ior_compare): Adjust.
11276 (cceq_ior_compare_complement): Adjust.
11277 (*cceq_rev_compare): Adjust.
11278 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
11279 (is_cracked_insn): Adjust.
11280 (insn_must_be_first_in_group): Adjust.
11281 * config/rs6000/40x.md: Adjust.
11282 * config/rs6000/440.md: Adjust.
11283 * config/rs6000/476.md: Adjust.
11284 * config/rs6000/601.md: Adjust.
11285 * config/rs6000/603.md: Adjust.
11286 * config/rs6000/6xx.md: Adjust.
11287 * config/rs6000/7450.md: Adjust.
11288 * config/rs6000/7xx.md: Adjust.
11289 * config/rs6000/8540.md: Adjust.
11290 * config/rs6000/cell.md: Adjust.
11291 * config/rs6000/e300c2c3.md: Adjust.
11292 * config/rs6000/e500mc.md: Adjust.
11293 * config/rs6000/e500mc64.md: Adjust.
11294 * config/rs6000/e5500.md: Adjust.
11295 * config/rs6000/e6500.md: Adjust.
11296 * config/rs6000/mpc.md: Adjust.
11297 * config/rs6000/power4.md: Adjust.
11298 * config/rs6000/power5.md: Adjust.
11299 * config/rs6000/power6.md: Adjust.
11300 * config/rs6000/power7.md: Adjust.
11301 * config/rs6000/power8.md: Adjust.
11302 * config/rs6000/power9.md: Adjust.
11303 * config/rs6000/rs64.md: Adjust.
11304 * config/rs6000/titan.md: Adjust.
11305
11306 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11307
11308 * config/i386/predicates.md (indirect_branch_operand): Rewrite
11309 ix86_indirect_branch_register logic.
11310
11311 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11312
11313 * config/i386/constraints.md (Bs): Update
11314 ix86_indirect_branch_register check. Don't check
11315 ix86_indirect_branch_register with GOT_memory_operand.
11316 (Bw): Likewise.
11317 * config/i386/predicates.md (GOT_memory_operand): Don't check
11318 ix86_indirect_branch_register here.
11319 (GOT32_symbol_operand): Likewise.
11320
11321 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11322
11323 * config/i386/predicates.md (constant_call_address_operand):
11324 Rewrite ix86_indirect_branch_register logic.
11325 (sibcall_insn_operand): Likewise.
11326
11327 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11328
11329 * config/i386/constraints.md (Bs): Replace
11330 ix86_indirect_branch_thunk_register with
11331 ix86_indirect_branch_register.
11332 (Bw): Likewise.
11333 * config/i386/i386.md (indirect_jump): Likewise.
11334 (tablejump): Likewise.
11335 (*sibcall_memory): Likewise.
11336 (*sibcall_value_memory): Likewise.
11337 Peepholes of indirect call and jump via memory: Likewise.
11338 * config/i386/i386.opt: Likewise.
11339 * config/i386/predicates.md (indirect_branch_operand): Likewise.
11340 (GOT_memory_operand): Likewise.
11341 (call_insn_operand): Likewise.
11342 (sibcall_insn_operand): Likewise.
11343 (GOT32_symbol_operand): Likewise.
11344
11345 2018-01-15 Jakub Jelinek <jakub@redhat.com>
11346
11347 PR middle-end/83837
11348 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
11349 type rather than type addr's type points to.
11350 (expand_omp_atomic_mutex): Likewise.
11351 (expand_omp_atomic): Likewise.
11352
11353 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11354
11355 PR target/83839
11356 * config/i386/i386.c (output_indirect_thunk_function): Use
11357 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
11358 for __x86_return_thunk.
11359
11360 2018-01-15 Richard Biener <rguenther@suse.de>
11361
11362 PR middle-end/83850
11363 * expmed.c (extract_bit_field_1): Fix typo.
11364
11365 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11366
11367 PR target/83687
11368 * config/arm/iterators.md (VF): New mode iterator.
11369 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
11370 Remove integer-related logic from pattern.
11371 (neon_vabd<mode>_3): Likewise.
11372
11373 2018-01-15 Jakub Jelinek <jakub@redhat.com>
11374
11375 PR middle-end/82694
11376 * common.opt (fstrict-overflow): No longer an alias.
11377 (fwrapv-pointer): New option.
11378 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
11379 also for pointer types based on flag_wrapv_pointer.
11380 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
11381 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
11382 opts->x_flag_wrapv got set.
11383 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
11384 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
11385 POINTER_TYPE_OVERFLOW_UNDEFINED.
11386 * match.pd: Likewise in address comparison pattern.
11387 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
11388
11389 2018-01-15 Richard Biener <rguenther@suse.de>
11390
11391 PR lto/83804
11392 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
11393 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
11394 Reset type names to their identifier if their TYPE_DECL doesn't
11395 have linkage (and thus is used for ODR and devirt).
11396 (save_debug_info_for_decl): Remove.
11397 (save_debug_info_for_type): Likewise.
11398 (add_tree_to_fld_list): Adjust.
11399 * tree-pretty-print.c (dump_generic_node): Make dumping of
11400 type names more robust.
11401
11402 2018-01-15 Richard Biener <rguenther@suse.de>
11403
11404 * BASE-VER: Bump to 8.0.1.
11405
11406 2018-01-14 Martin Sebor <msebor@redhat.com>
11407
11408 PR other/83508
11409 * builtins.c (check_access): Avoid warning when the no-warning bit
11410 is set.
11411
11412 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
11413
11414 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
11415 * ira-color (allocno_hard_regs_compare): Likewise.
11416
11417 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
11418
11419 PR target/83013
11420 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
11421 Use .pushsection/.popsection.
11422
11423 2018-01-14 Martin Sebor <msebor@redhat.com>
11424
11425 PR c++/81327
11426 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
11427
11428 2018-01-14 Jakub Jelinek <jakub@redhat.com>
11429
11430 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
11431 entry from extra_headers.
11432 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
11433 extra_headers, make the list bitwise identical to the i?86-*-* one.
11434
11435 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11436
11437 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
11438 -mcmodel=large with -mindirect-branch=thunk,
11439 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
11440 -mfunction-return=thunk-extern.
11441 * doc/invoke.texi: Document -mcmodel=large is incompatible with
11442 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
11443 -mfunction-return=thunk and -mfunction-return=thunk-extern.
11444
11445 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11446
11447 * config/i386/i386.c (print_reg): Print the name of the full
11448 integer register without '%'.
11449 (ix86_print_operand): Handle 'V'.
11450 * doc/extend.texi: Document 'V' modifier.
11451
11452 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11453
11454 * config/i386/constraints.md (Bs): Disallow memory operand for
11455 -mindirect-branch-register.
11456 (Bw): Likewise.
11457 * config/i386/predicates.md (indirect_branch_operand): Likewise.
11458 (GOT_memory_operand): Likewise.
11459 (call_insn_operand): Likewise.
11460 (sibcall_insn_operand): Likewise.
11461 (GOT32_symbol_operand): Likewise.
11462 * config/i386/i386.md (indirect_jump): Call convert_memory_address
11463 for -mindirect-branch-register.
11464 (tablejump): Likewise.
11465 (*sibcall_memory): Likewise.
11466 (*sibcall_value_memory): Likewise.
11467 Disallow peepholes of indirect call and jump via memory for
11468 -mindirect-branch-register.
11469 (*call_pop): Replace m with Bw.
11470 (*call_value_pop): Likewise.
11471 (*sibcall_pop_memory): Replace m with Bs.
11472 * config/i386/i386.opt (mindirect-branch-register): New option.
11473 * doc/invoke.texi: Document -mindirect-branch-register option.
11474
11475 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11476
11477 * config/i386/i386-protos.h (ix86_output_function_return): New.
11478 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
11479 set function_return_type.
11480 (indirect_thunk_name): Add ret_p to indicate thunk for function
11481 return.
11482 (output_indirect_thunk_function): Pass false to
11483 indirect_thunk_name.
11484 (ix86_output_indirect_branch_via_reg): Likewise.
11485 (ix86_output_indirect_branch_via_push): Likewise.
11486 (output_indirect_thunk_function): Create alias for function
11487 return thunk if regno < 0.
11488 (ix86_output_function_return): New function.
11489 (ix86_handle_fndecl_attribute): Handle function_return.
11490 (ix86_attribute_table): Add function_return.
11491 * config/i386/i386.h (machine_function): Add
11492 function_return_type.
11493 * config/i386/i386.md (simple_return_internal): Use
11494 ix86_output_function_return.
11495 (simple_return_internal_long): Likewise.
11496 * config/i386/i386.opt (mfunction-return=): New option.
11497 (indirect_branch): Mention -mfunction-return=.
11498 * doc/extend.texi: Document function_return function attribute.
11499 * doc/invoke.texi: Document -mfunction-return= option.
11500
11501 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11502
11503 * config/i386/i386-opts.h (indirect_branch): New.
11504 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
11505 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
11506 with local indirect jump when converting indirect call and jump.
11507 (ix86_set_indirect_branch_type): New.
11508 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
11509 (indirectlabelno): New.
11510 (indirect_thunk_needed): Likewise.
11511 (indirect_thunk_bnd_needed): Likewise.
11512 (indirect_thunks_used): Likewise.
11513 (indirect_thunks_bnd_used): Likewise.
11514 (INDIRECT_LABEL): Likewise.
11515 (indirect_thunk_name): Likewise.
11516 (output_indirect_thunk): Likewise.
11517 (output_indirect_thunk_function): Likewise.
11518 (ix86_output_indirect_branch_via_reg): Likewise.
11519 (ix86_output_indirect_branch_via_push): Likewise.
11520 (ix86_output_indirect_branch): Likewise.
11521 (ix86_output_indirect_jmp): Likewise.
11522 (ix86_code_end): Call output_indirect_thunk_function if needed.
11523 (ix86_output_call_insn): Call ix86_output_indirect_branch if
11524 needed.
11525 (ix86_handle_fndecl_attribute): Handle indirect_branch.
11526 (ix86_attribute_table): Add indirect_branch.
11527 * config/i386/i386.h (machine_function): Add indirect_branch_type
11528 and has_local_indirect_jump.
11529 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
11530 to true.
11531 (tablejump): Likewise.
11532 (*indirect_jump): Use ix86_output_indirect_jmp.
11533 (*tablejump_1): Likewise.
11534 (simple_return_indirect_internal): Likewise.
11535 * config/i386/i386.opt (mindirect-branch=): New option.
11536 (indirect_branch): New.
11537 (keep): Likewise.
11538 (thunk): Likewise.
11539 (thunk-inline): Likewise.
11540 (thunk-extern): Likewise.
11541 * doc/extend.texi: Document indirect_branch function attribute.
11542 * doc/invoke.texi: Document -mindirect-branch= option.
11543
11544 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
11545
11546 PR ipa/83051
11547 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
11548
11549 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
11550
11551 * ipa-inline.c (want_inline_small_function_p): Return false if
11552 inlining has already failed with CIF_FINAL_ERROR.
11553 (update_caller_keys): Call want_inline_small_function_p before
11554 can_inline_edge_p.
11555 (update_callee_keys): Likewise.
11556
11557 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
11558
11559 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
11560 New function.
11561 (rs6000_quadword_masked_address_p): Likewise.
11562 (quad_aligned_load_p): Likewise.
11563 (quad_aligned_store_p): Likewise.
11564 (const_load_sequence_p): Add comment to describe the outer-most loop.
11565 (mimic_memory_attributes_and_flags): New function.
11566 (rs6000_gen_stvx): Likewise.
11567 (replace_swapped_aligned_store): Likewise.
11568 (rs6000_gen_lvx): Likewise.
11569 (replace_swapped_aligned_load): Likewise.
11570 (replace_swapped_load_constant): Capitalize argument name in
11571 comment describing this function.
11572 (rs6000_analyze_swaps): Add a third pass to search for vector loads
11573 and stores that access quad-word aligned addresses and replace
11574 with stvx or lvx instructions when appropriate.
11575 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
11576 New function prototype.
11577 (rs6000_quadword_masked_address_p): Likewise.
11578 (rs6000_gen_lvx): Likewise.
11579 (rs6000_gen_stvx): Likewise.
11580 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
11581 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
11582 when memory address is aligned.
11583 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
11584 this split to select lvx instruction when memory address is aligned.
11585 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
11586 instruction when memory address is aligned.
11587 (*vsx_le_perm_load_v16qi): Likewise.
11588 (four unnamed splitters): Modify to select the stvx instruction
11589 when memory is aligned.
11590
11591 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
11592
11593 * predict.c (determine_unlikely_bbs): Handle correctly BBs
11594 which appears in the queue multiple times.
11595
11596 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11597 Alan Hayward <alan.hayward@arm.com>
11598 David Sherwood <david.sherwood@arm.com>
11599
11600 * tree-vectorizer.h (vec_lower_bound): New structure.
11601 (_loop_vec_info): Add check_nonzero and lower_bounds.
11602 (LOOP_VINFO_CHECK_NONZERO): New macro.
11603 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
11604 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
11605 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
11606 fields. Make seg_len the distance travelled, not including the
11607 access size.
11608 (dr_direction_indicator): Declare.
11609 (dr_zero_step_indicator): Likewise.
11610 (dr_known_forward_stride_p): Likewise.
11611 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
11612 tree-ssanames.h.
11613 (runtime_alias_check_p): Allow runtime alias checks with
11614 variable strides.
11615 (operator ==): Compare access_size and align.
11616 (prune_runtime_alias_test_list): Rework for new distinction between
11617 the access_size and seg_len.
11618 (create_intersect_range_checks_index): Likewise. Cope with polynomial
11619 segment lengths.
11620 (get_segment_min_max): New function.
11621 (create_intersect_range_checks): Use it.
11622 (dr_step_indicator): New function.
11623 (dr_direction_indicator): Likewise.
11624 (dr_zero_step_indicator): Likewise.
11625 (dr_known_forward_stride_p): Likewise.
11626 * tree-loop-distribution.c (data_ref_segment_size): Return
11627 DR_STEP * (niters - 1).
11628 (compute_alias_check_pairs): Update call to the dr_with_seg_len
11629 constructor.
11630 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
11631 (vect_preserves_scalar_order_p): New function, split out from...
11632 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
11633 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
11634 (vect_vfa_access_size): New function.
11635 (vect_vfa_align): Likewise.
11636 (vect_compile_time_alias): Take access_size_a and access_b arguments.
11637 (dump_lower_bound): New function.
11638 (vect_check_lower_bound): Likewise.
11639 (vect_small_gap_p): Likewise.
11640 (vectorizable_with_step_bound_p): Likewise.
11641 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
11642 depencies if the vectorization factor is 1. Convert the checks
11643 for nonzero steps into checks on the bounds of DR_STEP. Try using
11644 a bunds check for variable steps if the minimum required step is
11645 relatively small. Update calls to the dr_with_seg_len
11646 constructor and to vect_compile_time_alias.
11647 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
11648 function.
11649 (vect_loop_versioning): Call it.
11650 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
11651 when retrying.
11652 (vect_estimate_min_profitable_iters): Account for any bounds checks.
11653
11654 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11655 Alan Hayward <alan.hayward@arm.com>
11656 David Sherwood <david.sherwood@arm.com>
11657
11658 * doc/sourcebuild.texi (vect_scatter_store): Document.
11659 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
11660 optabs.
11661 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
11662 Document.
11663 * genopinit.c (main): Add supports_vec_scatter_store and
11664 supports_vec_scatter_store_cached to target_optabs.
11665 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
11666 IFN_MASK_SCATTER_STORE.
11667 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
11668 functions.
11669 * internal-fn.h (internal_store_fn_p): Declare.
11670 (internal_fn_stored_value_index): Likewise.
11671 * internal-fn.c (scatter_store_direct): New macro.
11672 (expand_scatter_store_optab_fn): New function.
11673 (direct_scatter_store_optab_supported_p): New macro.
11674 (internal_store_fn_p): New function.
11675 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
11676 IFN_MASK_SCATTER_STORE.
11677 (internal_fn_mask_index): Likewise.
11678 (internal_fn_stored_value_index): New function.
11679 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
11680 for scatter stores.
11681 * optabs-query.h (supports_vec_scatter_store_p): Declare.
11682 * optabs-query.c (supports_vec_scatter_store_p): New function.
11683 * tree-vectorizer.h (vect_get_store_rhs): Declare.
11684 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
11685 true for scatter stores.
11686 (vect_gather_scatter_fn_p): Handle scatter stores too.
11687 (vect_check_gather_scatter): Consider using scatter stores if
11688 supports_vec_scatter_store_p.
11689 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
11690 scatter stores too.
11691 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
11692 internal_fn_stored_value_index.
11693 (check_load_store_masking): Handle scatter stores too.
11694 (vect_get_store_rhs): Make public.
11695 (vectorizable_call): Use internal_store_fn_p.
11696 (vectorizable_store): Handle scatter store internal functions.
11697 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
11698 when deciding whether the end of the group has been reached.
11699 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
11700 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
11701 (mask_scatter_store<mode>): New insns.
11702
11703 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11704 Alan Hayward <alan.hayward@arm.com>
11705 David Sherwood <david.sherwood@arm.com>
11706
11707 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
11708 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
11709 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
11710 function.
11711 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
11712 Use vect_truncate_gather_scatter_offset if we can't treat the
11713 operation as a normal gather load or scatter store.
11714 (get_group_load_store_type): Take the gather_scatter_info
11715 as argument. Try using a gather load or scatter store for
11716 single-element groups.
11717 (get_load_store_type): Update calls to get_group_load_store_type
11718 and vect_use_strided_gather_scatters_p.
11719
11720 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11721 Alan Hayward <alan.hayward@arm.com>
11722 David Sherwood <david.sherwood@arm.com>
11723
11724 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
11725 optional tree argument.
11726 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
11727 null target hooks.
11728 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
11729 but continue to use the current value as a fallback.
11730 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
11731 to compare the updates.
11732 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
11733 (get_load_store_type): Use it when handling a strided access.
11734 (vect_get_strided_load_store_ops): New function.
11735 (vect_get_data_ptr_increment): Likewise.
11736 (vectorizable_load): Handle strided gather loads. Always pass
11737 a step to vect_create_data_ref_ptr and bump_vector_ptr.
11738
11739 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11740 Alan Hayward <alan.hayward@arm.com>
11741 David Sherwood <david.sherwood@arm.com>
11742
11743 * doc/md.texi (gather_load@var{m}): Document.
11744 (mask_gather_load@var{m}): Likewise.
11745 * genopinit.c (main): Add supports_vec_gather_load and
11746 supports_vec_gather_load_cached to target_optabs.
11747 * optabs-tree.c (init_tree_optimization_optabs): Use
11748 ggc_cleared_alloc to allocate target_optabs.
11749 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
11750 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
11751 functions.
11752 * internal-fn.h (internal_load_fn_p): Declare.
11753 (internal_gather_scatter_fn_p): Likewise.
11754 (internal_fn_mask_index): Likewise.
11755 (internal_gather_scatter_fn_supported_p): Likewise.
11756 * internal-fn.c (gather_load_direct): New macro.
11757 (expand_gather_load_optab_fn): New function.
11758 (direct_gather_load_optab_supported_p): New macro.
11759 (direct_internal_fn_optab): New function.
11760 (internal_load_fn_p): Likewise.
11761 (internal_gather_scatter_fn_p): Likewise.
11762 (internal_fn_mask_index): Likewise.
11763 (internal_gather_scatter_fn_supported_p): Likewise.
11764 * optabs-query.c (supports_at_least_one_mode_p): New function.
11765 (supports_vec_gather_load_p): Likewise.
11766 * optabs-query.h (supports_vec_gather_load_p): Declare.
11767 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
11768 and memory_type field.
11769 (NUM_PATTERNS): Bump to 15.
11770 * tree-vect-data-refs.c: Include internal-fn.h.
11771 (vect_gather_scatter_fn_p): New function.
11772 (vect_describe_gather_scatter_call): Likewise.
11773 (vect_check_gather_scatter): Try using internal functions for
11774 gather loads. Recognize existing calls to a gather load function.
11775 (vect_analyze_data_refs): Consider using gather loads if
11776 supports_vec_gather_load_p.
11777 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
11778 (vect_get_gather_scatter_offset_type): Likewise.
11779 (vect_convert_mask_for_vectype): Likewise.
11780 (vect_add_conversion_to_patterm): Likewise.
11781 (vect_try_gather_scatter_pattern): Likewise.
11782 (vect_recog_gather_scatter_pattern): New pattern recognizer.
11783 (vect_vect_recog_func_ptrs): Add it.
11784 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
11785 internal_fn_mask_index and internal_gather_scatter_fn_p.
11786 (check_load_store_masking): Take the gather_scatter_info as an
11787 argument and handle gather loads.
11788 (vect_get_gather_scatter_ops): New function.
11789 (vectorizable_call): Check internal_load_fn_p.
11790 (vectorizable_load): Likewise. Handle gather load internal
11791 functions.
11792 (vectorizable_store): Update call to check_load_store_masking.
11793 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
11794 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
11795 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
11796 (aarch64_gather_scale_operand_d): New predicates.
11797 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
11798 (mask_gather_load<mode>): New insns.
11799
11800 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11801 Alan Hayward <alan.hayward@arm.com>
11802 David Sherwood <david.sherwood@arm.com>
11803
11804 * optabs.def (fold_left_plus_optab): New optab.
11805 * doc/md.texi (fold_left_plus_@var{m}): Document.
11806 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
11807 * internal-fn.c (fold_left_direct): Define.
11808 (expand_fold_left_optab_fn): Likewise.
11809 (direct_fold_left_optab_supported_p): Likewise.
11810 * fold-const-call.c (fold_const_fold_left): New function.
11811 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
11812 * tree-parloops.c (valid_reduction_p): New function.
11813 (gather_scalar_reductions): Use it.
11814 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
11815 (vect_finish_replace_stmt): Declare.
11816 * tree-vect-loop.c (fold_left_reduction_fn): New function.
11817 (needs_fold_left_reduction_p): New function, split out from...
11818 (vect_is_simple_reduction): ...here. Accept reductions that
11819 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
11820 (vect_force_simple_reduction): Also store the reduction type in
11821 the assignment's STMT_VINFO_REDUC_TYPE.
11822 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
11823 (merge_with_identity): New function.
11824 (vect_expand_fold_left): Likewise.
11825 (vectorize_fold_left_reduction): Likewise.
11826 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
11827 scalar phi in place for it. Check for target support and reject
11828 cases that would reassociate the operation. Defer the transform
11829 phase to vectorize_fold_left_reduction.
11830 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
11831 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
11832 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
11833
11834 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11835
11836 * tree-if-conv.c (predicate_mem_writes): Remove redundant
11837 call to ifc_temp_var.
11838
11839 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11840 Alan Hayward <alan.hayward@arm.com>
11841 David Sherwood <david.sherwood@arm.com>
11842
11843 * target.def (legitimize_address_displacement): Take the original
11844 offset as a poly_int.
11845 * targhooks.h (default_legitimize_address_displacement): Update
11846 accordingly.
11847 * targhooks.c (default_legitimize_address_displacement): Likewise.
11848 * doc/tm.texi: Regenerate.
11849 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
11850 as an argument, moving assert of ad->disp == ad->disp_term to...
11851 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
11852 Try calling targetm.legitimize_address_displacement before expanding
11853 the address rather than afterwards, and adjust for the new interface.
11854 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
11855 Match the new hook interface. Handle SVE addresses.
11856 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
11857 new hook interface.
11858
11859 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11860
11861 * Makefile.in (OBJS): Add early-remat.o.
11862 * target.def (select_early_remat_modes): New hook.
11863 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
11864 * doc/tm.texi: Regenerate.
11865 * targhooks.h (default_select_early_remat_modes): Declare.
11866 * targhooks.c (default_select_early_remat_modes): New function.
11867 * timevar.def (TV_EARLY_REMAT): New timevar.
11868 * passes.def (pass_early_remat): New pass.
11869 * tree-pass.h (make_pass_early_remat): Declare.
11870 * early-remat.c: New file.
11871 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
11872 function.
11873 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
11874
11875 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11876 Alan Hayward <alan.hayward@arm.com>
11877 David Sherwood <david.sherwood@arm.com>
11878
11879 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
11880 vfm1 with a bound_epilog parameter.
11881 (vect_do_peeling): Update calls accordingly, and move the prologue
11882 call earlier in the function. Treat the base bound_epilog as 0 for
11883 fully-masked loops and retain vf - 1 for other loops. Add 1 to
11884 this base when peeling for gaps.
11885 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
11886 with fully-masked loops.
11887 (vect_estimate_min_profitable_iters): Handle the single peeled
11888 iteration in that case.
11889
11890 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11891 Alan Hayward <alan.hayward@arm.com>
11892 David Sherwood <david.sherwood@arm.com>
11893
11894 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
11895 single-element interleaving even if the size is not a power of 2.
11896 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
11897 accesses for single-element interleaving if the group size is
11898 not a power of 2.
11899
11900 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11901 Alan Hayward <alan.hayward@arm.com>
11902 David Sherwood <david.sherwood@arm.com>
11903
11904 * doc/md.texi (fold_extract_last_@var{m}): Document.
11905 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
11906 * optabs.def (fold_extract_last_optab): New optab.
11907 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
11908 * internal-fn.c (fold_extract_direct): New macro.
11909 (expand_fold_extract_optab_fn): Likewise.
11910 (direct_fold_extract_optab_supported_p): Likewise.
11911 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
11912 * tree-vect-loop.c (vect_model_reduction_cost): Handle
11913 EXTRACT_LAST_REDUCTION.
11914 (get_initial_def_for_reduction): Do not create an initial vector
11915 for EXTRACT_LAST_REDUCTION reductions.
11916 (vectorizable_reduction): Leave the scalar phi in place for
11917 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
11918 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
11919 epilogue code for EXTRACT_LAST_REDUCTION and defer the
11920 transform phase to vectorizable_condition.
11921 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
11922 split out from...
11923 (vect_finish_stmt_generation): ...here.
11924 (vect_finish_replace_stmt): New function.
11925 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
11926 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
11927 pattern.
11928 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
11929
11930 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11931 Alan Hayward <alan.hayward@arm.com>
11932 David Sherwood <david.sherwood@arm.com>
11933
11934 * doc/md.texi (extract_last_@var{m}): Document.
11935 * optabs.def (extract_last_optab): New optab.
11936 * internal-fn.def (EXTRACT_LAST): New internal function.
11937 * internal-fn.c (cond_unary_direct): New macro.
11938 (expand_cond_unary_optab_fn): Likewise.
11939 (direct_cond_unary_optab_supported_p): Likewise.
11940 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
11941 loops using EXTRACT_LAST.
11942 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
11943 (extract_last_<mode>): ...this optab.
11944 (vec_extract<mode><Vel>): Update accordingly.
11945
11946 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11947 Alan Hayward <alan.hayward@arm.com>
11948 David Sherwood <david.sherwood@arm.com>
11949
11950 * target.def (empty_mask_is_expensive): New hook.
11951 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
11952 * doc/tm.texi: Regenerate.
11953 * targhooks.h (default_empty_mask_is_expensive): Declare.
11954 * targhooks.c (default_empty_mask_is_expensive): New function.
11955 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
11956 if the target says that empty masks are expensive.
11957 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
11958 New function.
11959 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
11960
11961 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11962 Alan Hayward <alan.hayward@arm.com>
11963 David Sherwood <david.sherwood@arm.com>
11964
11965 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
11966 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
11967 (vect_use_loop_mask_for_alignment_p): New function.
11968 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
11969 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
11970 niters_skip argument. Make sure that the first niters_skip elements
11971 of the first iteration are inactive.
11972 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
11973 Update call to vect_set_loop_masks_directly.
11974 (get_misalign_in_elems): New function, split out from...
11975 (vect_gen_prolog_loop_niters): ...here.
11976 (vect_update_init_of_dr): Take a code argument that specifies whether
11977 the adjustment should be added or subtracted.
11978 (vect_update_init_of_drs): Likewise.
11979 (vect_prepare_for_masked_peels): New function.
11980 (vect_do_peeling): Skip prologue peeling if we're using a mask
11981 instead. Update call to vect_update_inits_of_drs.
11982 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
11983 mask_skip_niters.
11984 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
11985 alignment. Do not include the number of peeled iterations in
11986 the minimum threshold in that case.
11987 (vectorizable_induction): Adjust the start value down by
11988 LOOP_VINFO_MASK_SKIP_NITERS iterations.
11989 (vect_transform_loop): Call vect_prepare_for_masked_peels.
11990 Take the number of skipped iterations into account when calculating
11991 the loop bounds.
11992 * tree-vect-stmts.c (vect_gen_while_not): New function.
11993
11994 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11995 Alan Hayward <alan.hayward@arm.com>
11996 David Sherwood <david.sherwood@arm.com>
11997
11998 * doc/sourcebuild.texi (vect_fully_masked): Document.
11999 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
12000 default value to 0.
12001 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
12002 split out from...
12003 (vect_analyze_loop_2): ...here. Don't check the vectorization
12004 factor against the number of loop iterations if the loop is
12005 fully-masked.
12006
12007 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12008 Alan Hayward <alan.hayward@arm.com>
12009 David Sherwood <david.sherwood@arm.com>
12010
12011 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
12012 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
12013 (dump_groups): Update accordingly.
12014 (iv_use::mem_type): New member variable.
12015 (address_p): New function.
12016 (record_use): Add a mem_type argument and initialize the new
12017 mem_type field.
12018 (record_group_use): Add a mem_type argument. Use address_p.
12019 Remove obsolete null checks of base_object. Update call to record_use.
12020 (find_interesting_uses_op): Update call to record_group_use.
12021 (find_interesting_uses_cond): Likewise.
12022 (find_interesting_uses_address): Likewise.
12023 (get_mem_type_for_internal_fn): New function.
12024 (find_address_like_use): Likewise.
12025 (find_interesting_uses_stmt): Try find_address_like_use before
12026 calling find_interesting_uses_op.
12027 (addr_offset_valid_p): Use the iv mem_type field as the type
12028 of the addressed memory.
12029 (add_autoinc_candidates): Likewise.
12030 (get_address_cost): Likewise.
12031 (split_small_address_groups_p): Use address_p.
12032 (split_address_groups): Likewise.
12033 (add_iv_candidate_for_use): Likewise.
12034 (autoinc_possible_for_pair): Likewise.
12035 (rewrite_groups): Likewise.
12036 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
12037 (determine_group_iv_cost): Update after split of USE_ADDRESS.
12038 (get_alias_ptr_type_for_ptr_address): New function.
12039 (rewrite_use_address): Rewrite address uses in calls that were
12040 identified by find_address_like_use.
12041
12042 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12043 Alan Hayward <alan.hayward@arm.com>
12044 David Sherwood <david.sherwood@arm.com>
12045
12046 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
12047 TARGET_MEM_REFs.
12048 * gimple-expr.h (is_gimple_addressable: Likewise.
12049 * gimple-expr.c (is_gimple_address): Likewise.
12050 * internal-fn.c (expand_call_mem_ref): New function.
12051 (expand_mask_load_optab_fn): Use it.
12052 (expand_mask_store_optab_fn): Likewise.
12053
12054 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12055 Alan Hayward <alan.hayward@arm.com>
12056 David Sherwood <david.sherwood@arm.com>
12057
12058 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
12059 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
12060 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
12061 (cond_umax@var{mode}): Document.
12062 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
12063 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
12064 (cond_umin_optab, cond_umax_optab): New optabs.
12065 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
12066 (COND_IOR, COND_XOR): New internal functions.
12067 * internal-fn.h (get_conditional_internal_fn): Declare.
12068 * internal-fn.c (cond_binary_direct): New macro.
12069 (expand_cond_binary_optab_fn): Likewise.
12070 (direct_cond_binary_optab_supported_p): Likewise.
12071 (get_conditional_internal_fn): New function.
12072 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
12073 Cope with reduction statements that are vectorized as calls rather
12074 than assignments.
12075 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
12076 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
12077 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
12078 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
12079 (UNSPEC_COND_EOR): New unspecs.
12080 (optab): Add mappings for them.
12081 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
12082 (sve_int_op, sve_fp_op): New int attributes.
12083
12084 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12085 Alan Hayward <alan.hayward@arm.com>
12086 David Sherwood <david.sherwood@arm.com>
12087
12088 * optabs.def (while_ult_optab): New optab.
12089 * doc/md.texi (while_ult@var{m}@var{n}): Document.
12090 * internal-fn.def (WHILE_ULT): New internal function.
12091 * internal-fn.h (direct_internal_fn_supported_p): New override
12092 that takes two types as argument.
12093 * internal-fn.c (while_direct): New macro.
12094 (expand_while_optab_fn): New function.
12095 (convert_optab_supported_p): Likewise.
12096 (direct_while_optab_supported_p): New macro.
12097 * wide-int.h (wi::udiv_ceil): New function.
12098 * tree-vectorizer.h (rgroup_masks): New structure.
12099 (vec_loop_masks): New typedef.
12100 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
12101 and fully_masked_p.
12102 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
12103 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
12104 (vect_max_vf): New function.
12105 (slpeel_make_loop_iterate_ntimes): Delete.
12106 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
12107 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
12108 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
12109 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
12110 internal-fn.h, stor-layout.h and optabs-query.h.
12111 (vect_set_loop_mask): New function.
12112 (add_preheader_seq): Likewise.
12113 (add_header_seq): Likewise.
12114 (interleave_supported_p): Likewise.
12115 (vect_maybe_permute_loop_masks): Likewise.
12116 (vect_set_loop_masks_directly): Likewise.
12117 (vect_set_loop_condition_masked): Likewise.
12118 (vect_set_loop_condition_unmasked): New function, split out from
12119 slpeel_make_loop_iterate_ntimes.
12120 (slpeel_make_loop_iterate_ntimes): Rename to..
12121 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
12122 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
12123 (vect_do_peeling): Update call accordingly.
12124 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
12125 loops.
12126 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
12127 mask_compare_type, can_fully_mask_p and fully_masked_p.
12128 (release_vec_loop_masks): New function.
12129 (_loop_vec_info): Use it to free the loop masks.
12130 (can_produce_all_loop_masks_p): New function.
12131 (vect_get_max_nscalars_per_iter): Likewise.
12132 (vect_verify_full_masking): Likewise.
12133 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
12134 retries, and free the mask rgroups before retrying. Check loop-wide
12135 reasons for disallowing fully-masked loops. Make the final decision
12136 about whether use a fully-masked loop or not.
12137 (vect_estimate_min_profitable_iters): Do not assume that peeling
12138 for the number of iterations will be needed for fully-masked loops.
12139 (vectorizable_reduction): Disable fully-masked loops.
12140 (vectorizable_live_operation): Likewise.
12141 (vect_halve_mask_nunits): New function.
12142 (vect_double_mask_nunits): Likewise.
12143 (vect_record_loop_mask): Likewise.
12144 (vect_get_loop_mask): Likewise.
12145 (vect_transform_loop): Handle the case in which the final loop
12146 iteration might handle a partial vector. Call vect_set_loop_condition
12147 instead of slpeel_make_loop_iterate_ntimes.
12148 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
12149 (check_load_store_masking): New function.
12150 (prepare_load_store_mask): Likewise.
12151 (vectorizable_store): Handle fully-masked loops.
12152 (vectorizable_load): Likewise.
12153 (supportable_widening_operation): Use vect_halve_mask_nunits for
12154 booleans.
12155 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
12156 (vect_gen_while): New function.
12157 * config/aarch64/aarch64.md (umax<mode>3): New expander.
12158 (aarch64_uqdec<mode>): New insn.
12159
12160 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12161 Alan Hayward <alan.hayward@arm.com>
12162 David Sherwood <david.sherwood@arm.com>
12163
12164 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
12165 (reduc_xor_scal_optab): New optabs.
12166 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
12167 (reduc_xor_scal_@var{m}): Document.
12168 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
12169 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
12170 internal functions.
12171 * fold-const-call.c (fold_const_call): Handle them.
12172 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
12173 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
12174 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
12175 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
12176 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
12177 (UNSPEC_XORV): New unspecs.
12178 (optab): Add entries for them.
12179 (BITWISEV): New int iterator.
12180 (bit_reduc_op): New int attributes.
12181
12182 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12183 Alan Hayward <alan.hayward@arm.com>
12184 David Sherwood <david.sherwood@arm.com>
12185
12186 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
12187 * internal-fn.def (VEC_SHL_INSERT): New internal function.
12188 * optabs.def (vec_shl_insert_optab): New optab.
12189 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
12190 (duplicate_and_interleave): Likewise.
12191 * tree-vect-loop.c: Include internal-fn.h.
12192 (neutral_op_for_slp_reduction): New function, split out from
12193 get_initial_defs_for_reduction.
12194 (get_initial_def_for_reduction): Handle option 2 for variable-length
12195 vectors by loading the neutral value into a vector and then shifting
12196 the initial value into element 0.
12197 (get_initial_defs_for_reduction): Replace the code argument with
12198 the neutral value calculated by neutral_op_for_slp_reduction.
12199 Use gimple_build_vector for constant-length vectors.
12200 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
12201 but the first group_size elements have a neutral value.
12202 Use duplicate_and_interleave otherwise.
12203 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
12204 Update call to get_initial_defs_for_reduction. Handle SLP
12205 reductions for variable-length vectors by creating one vector
12206 result for each scalar result, with the elements associated
12207 with other scalar results stubbed out with the neutral value.
12208 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
12209 Require IFN_VEC_SHL_INSERT for double reductions on
12210 variable-length vectors, or SLP reductions that have
12211 a neutral value. Require can_duplicate_and_interleave_p
12212 support for variable-length unchained SLP reductions if there
12213 is no neutral value, such as for MIN/MAX reductions. Also require
12214 the number of vector elements to be a multiple of the number of
12215 SLP statements when doing variable-length unchained SLP reductions.
12216 Update call to vect_create_epilog_for_reduction.
12217 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
12218 and remove initial values.
12219 (duplicate_and_interleave): Make public.
12220 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
12221 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
12222
12223 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12224 Alan Hayward <alan.hayward@arm.com>
12225 David Sherwood <david.sherwood@arm.com>
12226
12227 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
12228 (can_duplicate_and_interleave_p): New function.
12229 (vect_get_and_check_slp_defs): Take the vector of statements
12230 rather than just the current one. Remove excess parentheses.
12231 Restriction rejectinon of vect_constant_def and vect_external_def
12232 for variable-length vectors to boolean types, or types for which
12233 can_duplicate_and_interleave_p is false.
12234 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
12235 (duplicate_and_interleave): New function.
12236 (vect_get_constant_vectors): Use gimple_build_vector for
12237 constant-length vectors and suitable variable-length constant
12238 vectors. Use duplicate_and_interleave for other variable-length
12239 vectors. Don't defer the update when inserting new statements.
12240
12241 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12242 Alan Hayward <alan.hayward@arm.com>
12243 David Sherwood <david.sherwood@arm.com>
12244
12245 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
12246 min_profitable_iters doesn't go negative.
12247
12248 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12249 Alan Hayward <alan.hayward@arm.com>
12250 David Sherwood <david.sherwood@arm.com>
12251
12252 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
12253 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
12254 * optabs.def (vec_mask_load_lanes_optab): New optab.
12255 (vec_mask_store_lanes_optab): Likewise.
12256 * internal-fn.def (MASK_LOAD_LANES): New internal function.
12257 (MASK_STORE_LANES): Likewise.
12258 * internal-fn.c (mask_load_lanes_direct): New macro.
12259 (mask_store_lanes_direct): Likewise.
12260 (expand_mask_load_optab_fn): Handle masked operations.
12261 (expand_mask_load_lanes_optab_fn): New macro.
12262 (expand_mask_store_optab_fn): Handle masked operations.
12263 (expand_mask_store_lanes_optab_fn): New macro.
12264 (direct_mask_load_lanes_optab_supported_p): Likewise.
12265 (direct_mask_store_lanes_optab_supported_p): Likewise.
12266 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
12267 parameter.
12268 (vect_load_lanes_supported): Likewise.
12269 * tree-vect-data-refs.c (strip_conversion): New function.
12270 (can_group_stmts_p): Likewise.
12271 (vect_analyze_data_ref_accesses): Use it instead of checking
12272 for a pair of assignments.
12273 (vect_store_lanes_supported): Take a masked_p parameter.
12274 (vect_load_lanes_supported): Likewise.
12275 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
12276 vect_store_lanes_supported and vect_load_lanes_supported.
12277 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
12278 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
12279 parameter. Don't allow gaps for masked accesses.
12280 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
12281 and vect_load_lanes_supported.
12282 (get_load_store_type): Take a masked_p parameter and update
12283 call to get_group_load_store_type.
12284 (vectorizable_store): Update call to get_load_store_type.
12285 Handle IFN_MASK_STORE_LANES.
12286 (vectorizable_load): Update call to get_load_store_type.
12287 Handle IFN_MASK_LOAD_LANES.
12288
12289 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12290 Alan Hayward <alan.hayward@arm.com>
12291 David Sherwood <david.sherwood@arm.com>
12292
12293 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
12294 modes for SVE.
12295 * config/aarch64/aarch64-protos.h
12296 (aarch64_sve_struct_memory_operand_p): Declare.
12297 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
12298 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
12299 (VPRED, vpred): Handle SVE structure modes.
12300 * config/aarch64/constraints.md (Utx): New constraint.
12301 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
12302 (aarch64_sve_struct_nonimmediate_operand): New predicates.
12303 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
12304 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
12305 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
12306 structure modes. Split into pieces after RA.
12307 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
12308 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
12309 New patterns.
12310 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
12311 SVE structure modes.
12312 (aarch64_classify_address): Likewise.
12313 (sizetochar): Move earlier in file.
12314 (aarch64_print_operand): Handle SVE register lists.
12315 (aarch64_array_mode): New function.
12316 (aarch64_sve_struct_memory_operand_p): Likewise.
12317 (TARGET_ARRAY_MODE): Redefine.
12318
12319 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12320 Alan Hayward <alan.hayward@arm.com>
12321 David Sherwood <david.sherwood@arm.com>
12322
12323 * target.def (array_mode): New target hook.
12324 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
12325 * doc/tm.texi: Regenerate.
12326 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
12327 * hooks.c (hook_optmode_mode_uhwi_none): New function.
12328 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
12329 targetm.array_mode.
12330 * stor-layout.c (mode_for_array): Likewise. Support polynomial
12331 type sizes.
12332
12333 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12334 Alan Hayward <alan.hayward@arm.com>
12335 David Sherwood <david.sherwood@arm.com>
12336
12337 * fold-const.c (fold_binary_loc): Check the argument types
12338 rather than the result type when testing for a vector operation.
12339
12340 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12341
12342 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
12343 * doc/tm.texi: Regenerate.
12344
12345 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12346 Alan Hayward <alan.hayward@arm.com>
12347 David Sherwood <david.sherwood@arm.com>
12348
12349 * doc/invoke.texi (-msve-vector-bits=): Document new option.
12350 (sve): Document new AArch64 extension.
12351 * doc/md.texi (w): Extend the description of the AArch64
12352 constraint to include SVE vectors.
12353 (Upl, Upa): Document new AArch64 predicate constraints.
12354 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
12355 enum.
12356 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
12357 (msve-vector-bits=): New option.
12358 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
12359 SVE when these are disabled.
12360 (sve): New extension.
12361 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
12362 modes. Adjust their number of units based on aarch64_sve_vg.
12363 (MAX_BITSIZE_MODE_ANY_MODE): Define.
12364 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
12365 aarch64_addr_query_type.
12366 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
12367 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
12368 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
12369 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
12370 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
12371 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
12372 (aarch64_simd_imm_zero_p): Delete.
12373 (aarch64_check_zero_based_sve_index_immediate): Declare.
12374 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
12375 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
12376 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
12377 (aarch64_sve_float_mul_immediate_p): Likewise.
12378 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
12379 rather than an rtx.
12380 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
12381 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
12382 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
12383 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
12384 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
12385 (aarch64_regmode_natural_size): Likewise.
12386 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
12387 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
12388 left one place.
12389 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
12390 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
12391 for VG and the SVE predicate registers.
12392 (V_ALIASES): Add a "z"-prefixed alias.
12393 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
12394 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
12395 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
12396 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
12397 (REG_CLASS_NAMES): Add entries for them.
12398 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
12399 and the predicate registers.
12400 (aarch64_sve_vg): Declare.
12401 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
12402 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
12403 (REGMODE_NATURAL_SIZE): Define.
12404 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
12405 SVE macros.
12406 * config/aarch64/aarch64.c: Include cfgrtl.h.
12407 (simd_immediate_info): Add a constructor for series vectors,
12408 and an associated step field.
12409 (aarch64_sve_vg): New variable.
12410 (aarch64_dbx_register_number): Handle VG and the predicate registers.
12411 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
12412 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
12413 (VEC_ANY_DATA, VEC_STRUCT): New constants.
12414 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
12415 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
12416 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
12417 (aarch64_get_mask_mode): New functions.
12418 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
12419 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
12420 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
12421 predicate modes and predicate registers. Explicitly restrict
12422 GPRs to modes of 16 bytes or smaller. Only allow FP registers
12423 to store a vector mode if it is recognized by
12424 aarch64_classify_vector_mode.
12425 (aarch64_regmode_natural_size): New function.
12426 (aarch64_hard_regno_caller_save_mode): Return the original mode
12427 for predicates.
12428 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
12429 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
12430 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
12431 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
12432 functions.
12433 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
12434 does not overlap dest if the function is frame-related. Handle
12435 SVE constants.
12436 (aarch64_split_add_offset): New function.
12437 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
12438 them aarch64_add_offset.
12439 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
12440 and update call to aarch64_sub_sp.
12441 (aarch64_add_cfa_expression): New function.
12442 (aarch64_expand_prologue): Pass extra temporary registers to the
12443 functions above. Handle the case in which we need to emit new
12444 DW_CFA_expressions for registers that were originally saved
12445 relative to the stack pointer, but now have to be expressed
12446 relative to the frame pointer.
12447 (aarch64_output_mi_thunk): Pass extra temporary registers to the
12448 functions above.
12449 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
12450 IP0 and IP1 values for SVE frames.
12451 (aarch64_expand_vec_series): New function.
12452 (aarch64_expand_sve_widened_duplicate): Likewise.
12453 (aarch64_expand_sve_const_vector): Likewise.
12454 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
12455 Handle SVE constants. Use emit_move_insn to move a force_const_mem
12456 into the register, rather than emitting a SET directly.
12457 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
12458 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
12459 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
12460 (offset_9bit_signed_scaled_p): New functions.
12461 (aarch64_replicate_bitmask_imm): New function.
12462 (aarch64_bitmask_imm): Use it.
12463 (aarch64_cannot_force_const_mem): Reject expressions involving
12464 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
12465 (aarch64_classify_index): Handle SVE indices, by requiring
12466 a plain register index with a scale that matches the element size.
12467 (aarch64_classify_address): Handle SVE addresses. Assert that
12468 the mode of the address is VOIDmode or an integer mode.
12469 Update call to aarch64_classify_symbol.
12470 (aarch64_classify_symbolic_expression): Update call to
12471 aarch64_classify_symbol.
12472 (aarch64_const_vec_all_in_range_p): New function.
12473 (aarch64_print_vector_float_operand): Likewise.
12474 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
12475 "vN" for FP registers with SVE modes. Handle (const ...) vectors
12476 and the FP immediates 1.0 and 0.5.
12477 (aarch64_print_address_internal): Handle SVE addresses.
12478 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
12479 (aarch64_regno_regclass): Handle predicate registers.
12480 (aarch64_secondary_reload): Handle big-endian reloads of SVE
12481 data modes.
12482 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
12483 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
12484 (aarch64_convert_sve_vector_bits): New function.
12485 (aarch64_override_options): Use it to handle -msve-vector-bits=.
12486 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
12487 rather than an rtx.
12488 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
12489 Handle SVE vector and predicate modes. Accept VL-based constants
12490 that need only one temporary register, and VL offsets that require
12491 no temporary registers.
12492 (aarch64_conditional_register_usage): Mark the predicate registers
12493 as fixed if SVE isn't available.
12494 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
12495 Return true for SVE vector and predicate modes.
12496 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
12497 rather than an unsigned int. Handle SVE modes.
12498 (aarch64_preferred_simd_mode): Update call accordingly. Handle
12499 SVE modes.
12500 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
12501 if SVE is enabled.
12502 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
12503 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
12504 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
12505 (aarch64_sve_float_mul_immediate_p): New functions.
12506 (aarch64_sve_valid_immediate): New function.
12507 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
12508 Explicitly reject structure modes. Check for INDEX constants.
12509 Handle PTRUE and PFALSE constants.
12510 (aarch64_check_zero_based_sve_index_immediate): New function.
12511 (aarch64_simd_imm_zero_p): Delete.
12512 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
12513 vector modes. Accept constants in the range of CNT[BHWD].
12514 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
12515 ask for an Advanced SIMD mode.
12516 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
12517 (aarch64_simd_vector_alignment): Handle SVE predicates.
12518 (aarch64_vectorize_preferred_vector_alignment): New function.
12519 (aarch64_simd_vector_alignment_reachable): Use it instead of
12520 the vector size.
12521 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
12522 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
12523 functions.
12524 (MAX_VECT_LEN): Delete.
12525 (expand_vec_perm_d): Add a vec_flags field.
12526 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
12527 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
12528 (aarch64_evpc_ext): Don't apply a big-endian lane correction
12529 for SVE modes.
12530 (aarch64_evpc_rev): Rename to...
12531 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
12532 (aarch64_evpc_rev_global): New function.
12533 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
12534 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
12535 MAX_VECT_LEN.
12536 (aarch64_evpc_sve_tbl): New function.
12537 (aarch64_expand_vec_perm_const_1): Update after rename of
12538 aarch64_evpc_rev. Handle SVE permutes too, trying
12539 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
12540 than aarch64_evpc_tbl.
12541 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
12542 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
12543 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
12544 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
12545 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
12546 (aarch64_expand_sve_vcond): New functions.
12547 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
12548 of aarch64_vector_mode_p.
12549 (aarch64_dwarf_poly_indeterminate_value): New function.
12550 (aarch64_compute_pressure_classes): Likewise.
12551 (aarch64_can_change_mode_class): Likewise.
12552 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
12553 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
12554 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
12555 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
12556 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
12557 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
12558 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
12559 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
12560 constraints.
12561 (Dn, Dl, Dr): Accept const as well as const_vector.
12562 (Dz): Likewise. Compare against CONST0_RTX.
12563 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
12564 of "vector" where appropriate.
12565 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
12566 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
12567 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
12568 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
12569 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
12570 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
12571 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
12572 (v_int_equiv): Extend to SVE modes.
12573 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
12574 mode attributes.
12575 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
12576 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
12577 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
12578 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
12579 (SVE_COND_FP_CMP): New int iterators.
12580 (perm_hilo): Handle the new unpack unspecs.
12581 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
12582 attributes.
12583 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
12584 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
12585 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
12586 (aarch64_equality_operator, aarch64_constant_vector_operand)
12587 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
12588 (aarch64_sve_nonimmediate_operand): Likewise.
12589 (aarch64_sve_general_operand): Likewise.
12590 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
12591 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
12592 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
12593 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
12594 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
12595 (aarch64_sve_float_arith_immediate): Likewise.
12596 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
12597 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
12598 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
12599 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
12600 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
12601 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
12602 (aarch64_sve_float_arith_operand): Likewise.
12603 (aarch64_sve_float_arith_with_sub_operand): Likewise.
12604 (aarch64_sve_float_mul_operand): Likewise.
12605 (aarch64_sve_vec_perm_operand): Likewise.
12606 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
12607 (aarch64_mov_operand): Accept const_poly_int and const_vector.
12608 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
12609 as well as const_vector.
12610 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
12611 in file. Use CONST0_RTX and CONSTM1_RTX.
12612 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
12613 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
12614 Use aarch64_simd_imm_zero.
12615 * config/aarch64/aarch64-sve.md: New file.
12616 * config/aarch64/aarch64.md: Include it.
12617 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
12618 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
12619 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
12620 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
12621 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
12622 (sve): New attribute.
12623 (enabled): Disable instructions with the sve attribute unless
12624 TARGET_SVE.
12625 (movqi, movhi): Pass CONST_POLY_INT operaneds through
12626 aarch64_expand_mov_immediate.
12627 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
12628 CNT[BHSD] immediates.
12629 (movti): Split CONST_POLY_INT moves into two halves.
12630 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
12631 Split additions that need a temporary here if the destination
12632 is the stack pointer.
12633 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
12634 (*add<mode>3_poly_1): New instruction.
12635 (set_clobber_cc): New expander.
12636
12637 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12638
12639 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
12640 parameter and use it instead of GET_MODE_SIZE (innermode). Use
12641 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
12642 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
12643 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
12644 Change innermode from fixed_mode_size to machine_mode.
12645 (simplify_subreg): Update call accordingly. Handle a constant-sized
12646 subreg of a variable-length CONST_VECTOR.
12647
12648 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12649 Alan Hayward <alan.hayward@arm.com>
12650 David Sherwood <david.sherwood@arm.com>
12651
12652 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
12653 (add_offset_to_base): New function, split out from...
12654 (create_mem_ref): ...here. When handling a scale other than 1,
12655 check first whether the address is valid without the offset.
12656 Add it into the base if so, leaving the index and scale as-is.
12657
12658 2018-01-12 Jakub Jelinek <jakub@redhat.com>
12659
12660 PR c++/83778
12661 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
12662 fold_for_warn before checking if arg2 is INTEGER_CST.
12663
12664 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
12665
12666 * config/rs6000/predicates.md (load_multiple_operation): Delete.
12667 (store_multiple_operation): Delete.
12668 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
12669 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
12670 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
12671 guarded by TARGET_STRING.
12672 (rs6000_output_load_multiple): Delete.
12673 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
12674 OPTION_MASK_STRING / TARGET_STRING handling.
12675 (print_operand) <'N', 'O'>: Add comment that these are unused now.
12676 (const rs6000_opt_masks) <"string">: Change mask to 0.
12677 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
12678 (MASK_STRING): Delete.
12679 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
12680 parts. Simplify.
12681 (load_multiple): Delete.
12682 (*ldmsi8): Delete.
12683 (*ldmsi7): Delete.
12684 (*ldmsi6): Delete.
12685 (*ldmsi5): Delete.
12686 (*ldmsi4): Delete.
12687 (*ldmsi3): Delete.
12688 (store_multiple): Delete.
12689 (*stmsi8): Delete.
12690 (*stmsi7): Delete.
12691 (*stmsi6): Delete.
12692 (*stmsi5): Delete.
12693 (*stmsi4): Delete.
12694 (*stmsi3): Delete.
12695 (movmemsi_8reg): Delete.
12696 (corresponding unnamed define_insn): Delete.
12697 (movmemsi_6reg): Delete.
12698 (corresponding unnamed define_insn): Delete.
12699 (movmemsi_4reg): Delete.
12700 (corresponding unnamed define_insn): Delete.
12701 (movmemsi_2reg): Delete.
12702 (corresponding unnamed define_insn): Delete.
12703 (movmemsi_1reg): Delete.
12704 (corresponding unnamed define_insn): Delete.
12705 * config/rs6000/rs6000.opt (mno-string): New.
12706 (mstring): Replace by deprecation warning stub.
12707 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
12708
12709 2018-01-12 Jakub Jelinek <jakub@redhat.com>
12710
12711 * regrename.c (regrename_do_replace): If replacing the same
12712 reg multiple times, try to reuse last created gen_raw_REG.
12713
12714 PR debug/81155
12715 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
12716 main to workaround a bug in GDB.
12717
12718 2018-01-12 Tom de Vries <tom@codesourcery.com>
12719
12720 PR target/83737
12721 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
12722
12723 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
12724
12725 PR rtl-optimization/80481
12726 * ira-color.c (get_cap_member): New function.
12727 (allocnos_conflict_by_live_ranges_p): Use it.
12728 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
12729 (setup_slot_coalesced_allocno_live_ranges): Ditto.
12730
12731 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
12732
12733 PR target/83628
12734 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
12735 (*saddl_se_1): Ditto.
12736 (*ssubsi_1): Ditto.
12737 (*ssubl_se_1): Ditto.
12738
12739 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
12740
12741 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
12742 rather than wi::to_widest for DR_INITs.
12743 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
12744 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
12745 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
12746 INTEGER_CSTs.
12747 (vect_analyze_group_access_1): Note that here.
12748
12749 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
12750
12751 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
12752 polynomial type sizes.
12753
12754 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
12755
12756 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
12757 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
12758 (gimple_add_tmp_var): Likewise.
12759
12760 2018-01-12 Martin Liska <mliska@suse.cz>
12761
12762 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
12763 (gimple_alloc_sizes): Likewise.
12764 (dump_gimple_statistics): Use PRIu64 in printf format.
12765 * gimple.h: Change uint64_t to int.
12766
12767 2018-01-12 Martin Liska <mliska@suse.cz>
12768
12769 * tree-core.h: Use uint64_t instead of int.
12770 * tree.c (tree_node_counts): Likewise.
12771 (tree_node_sizes): Likewise.
12772 (dump_tree_statistics): Use PRIu64 in printf format.
12773
12774 2018-01-12 Martin Liska <mliska@suse.cz>
12775
12776 * Makefile.in: As qsort_chk is implemented in vec.c, add
12777 vec.o to linkage of gencfn-macros.
12778 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
12779 passing the info to record_node_allocation_statistics.
12780 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
12781 and pass the info.
12782 * ggc-common.c (struct ggc_usage): Add operator== and use
12783 it in operator< and compare function.
12784 * mem-stats.h (struct mem_usage): Likewise.
12785 * vec.c (struct vec_usage): Remove operator< and compare
12786 function. Can be simply inherited.
12787
12788 2018-01-12 Martin Jambor <mjambor@suse.cz>
12789
12790 PR target/81616
12791 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
12792 * tree-ssa-math-opts.c: Include domwalk.h.
12793 (convert_mult_to_fma_1): New function.
12794 (fma_transformation_info): New type.
12795 (fma_deferring_state): Likewise.
12796 (cancel_fma_deferring): New function.
12797 (result_of_phi): Likewise.
12798 (last_fma_candidate_feeds_initial_phi): Likewise.
12799 (convert_mult_to_fma): Added deferring logic, split actual
12800 transformation to convert_mult_to_fma_1.
12801 (math_opts_dom_walker): New type.
12802 (math_opts_dom_walker::after_dom_children): New method, body moved
12803 here from pass_optimize_widening_mul::execute, added deferring logic
12804 bits.
12805 (pass_optimize_widening_mul::execute): Moved most of code to
12806 math_opts_dom_walker::after_dom_children.
12807 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
12808 * config/i386/i386.c (ix86_option_override_internal): Added
12809 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
12810
12811 2018-01-12 Richard Biener <rguenther@suse.de>
12812
12813 PR debug/83157
12814 * dwarf2out.c (gen_variable_die): Do not reset old_die for
12815 inline instance vars.
12816
12817 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
12818
12819 PR target/81819
12820 * config/rx/rx.c (rx_is_restricted_memory_address):
12821 Handle SUBREG case.
12822
12823 2018-01-12 Richard Biener <rguenther@suse.de>
12824
12825 PR tree-optimization/80846
12826 * target.def (split_reduction): New target hook.
12827 * targhooks.c (default_split_reduction): New function.
12828 * targhooks.h (default_split_reduction): Declare.
12829 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
12830 target requests first reduce vectors by combining low and high
12831 parts.
12832 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
12833 (get_vectype_for_scalar_type_and_size): Export.
12834 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
12835 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
12836 * doc/tm.texi: Regenerate.
12837 * config/i386/i386.c (ix86_split_reduction): Implement
12838 TARGET_VECTORIZE_SPLIT_REDUCTION.
12839
12840 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
12841
12842 PR target/83368
12843 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
12844 in PIC mode except for TARGET_VXWORKS_RTP.
12845 * config/sparc/sparc.c: Include cfgrtl.h.
12846 (TARGET_INIT_PIC_REG): Define.
12847 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
12848 (sparc_pic_register_p): New predicate.
12849 (sparc_legitimate_address_p): Use it.
12850 (sparc_legitimize_pic_address): Likewise.
12851 (sparc_delegitimize_address): Likewise.
12852 (sparc_mode_dependent_address_p): Likewise.
12853 (gen_load_pcrel_sym): Remove 4th parameter.
12854 (load_got_register): Adjust call to above. Remove obsolete stuff.
12855 (sparc_expand_prologue): Do not call load_got_register here.
12856 (sparc_flat_expand_prologue): Likewise.
12857 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
12858 (sparc_use_pseudo_pic_reg): New function.
12859 (sparc_init_pic_reg): Likewise.
12860 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
12861 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
12862
12863 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
12864
12865 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
12866 Add item for branch_cost.
12867
12868 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
12869
12870 PR rtl-optimization/83565
12871 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
12872 not extend the result to a larger mode for rotate operations.
12873 (num_sign_bit_copies1): Likewise.
12874
12875 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12876
12877 PR target/40411
12878 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
12879 -symbolic.
12880 Use values-Xc.o for -pedantic.
12881 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
12882
12883 2018-01-12 Martin Liska <mliska@suse.cz>
12884
12885 PR ipa/83054
12886 * ipa-devirt.c (final_warning_record::grow_type_warnings):
12887 New function.
12888 (possible_polymorphic_call_targets): Use it.
12889 (ipa_devirt): Likewise.
12890
12891 2018-01-12 Martin Liska <mliska@suse.cz>
12892
12893 * profile-count.h (enum profile_quality): Use 0 as invalid
12894 enum value of profile_quality.
12895
12896 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
12897
12898 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
12899 -mext-string options.
12900
12901 2018-01-12 Richard Biener <rguenther@suse.de>
12902
12903 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
12904 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
12905 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
12906 Likewise.
12907 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
12908
12909 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
12910
12911 * configure.ac (--with-long-double-format): Add support for the
12912 configuration option to change the default long double format on
12913 PowerPC systems.
12914 * config.gcc (powerpc*-linux*-*): Likewise.
12915 * configure: Regenerate.
12916 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
12917 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
12918 used without modification.
12919
12920 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
12921
12922 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
12923 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
12924 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
12925 MISC_BUILTIN_SPEC_BARRIER.
12926 (rs6000_init_builtins): Likewise.
12927 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
12928 enum value.
12929 (speculation_barrier): New define_insn.
12930 * doc/extend.texi: Document __builtin_speculation_barrier.
12931
12932 2018-01-11 Jakub Jelinek <jakub@redhat.com>
12933
12934 PR target/83203
12935 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
12936 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
12937 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
12938 iterators.
12939 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
12940 integral modes instead of "ss" and "sd".
12941 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
12942 vectors with 32-bit and 64-bit elements.
12943 (vecdupssescalarmodesuffix): New mode attribute.
12944 (vec_dup<mode>): Use it.
12945
12946 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
12947
12948 PR target/83330
12949 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
12950 frame if argument is passed on stack.
12951
12952 2018-01-11 Jakub Jelinek <jakub@redhat.com>
12953
12954 PR target/82682
12955 * ree.c (combine_reaching_defs): Optimize also
12956 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
12957 reg2=any_extend(exp); reg1=reg2;, formatting fix.
12958
12959 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
12960
12961 PR middle-end/83189
12962 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
12963
12964 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
12965
12966 PR middle-end/83718
12967 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
12968 after they are computed.
12969
12970 2018-01-11 Bin Cheng <bin.cheng@arm.com>
12971
12972 PR tree-optimization/83695
12973 * gimple-loop-linterchange.cc
12974 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
12975 reset cached scev information after interchange.
12976 (pass_linterchange::execute): Remove call to scev_reset_htab.
12977
12978 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12979
12980 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
12981 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
12982 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
12983 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
12984 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
12985 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
12986 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
12987 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
12988 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
12989 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
12990 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
12991 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
12992 (V_lane_reg): Likewise.
12993 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
12994 New define_expand.
12995 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
12996 (vfmal_lane_low<mode>_intrinsic,
12997 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
12998 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
12999 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
13000 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
13001 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
13002 vfmsl_lane_high<mode>_intrinsic): New define_insns.
13003
13004 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13005
13006 * config/arm/arm-cpus.in (fp16fml): New feature.
13007 (ALL_SIMD): Add fp16fml.
13008 (armv8.2-a): Add fp16fml as an option.
13009 (armv8.3-a): Likewise.
13010 (armv8.4-a): Add fp16fml as part of fp16.
13011 * config/arm/arm.h (TARGET_FP16FML): Define.
13012 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
13013 when appropriate.
13014 * config/arm/arm-modes.def (V2HF): Define.
13015 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
13016 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
13017 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
13018 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
13019 vfmsl_low, vfmsl_high): New set of builtins.
13020 * config/arm/iterators.md (PLUSMINUS): New code iterator.
13021 (vfml_op): New code attribute.
13022 (VFMLHALVES): New int iterator.
13023 (VFML, VFMLSEL): New mode attributes.
13024 (V_reg): Define mapping for V2HF.
13025 (V_hi, V_lo): New mode attributes.
13026 (VF_constraint): Likewise.
13027 (vfml_half, vfml_half_selector): New int attributes.
13028 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
13029 define_expand.
13030 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
13031 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
13032 New define_insn.
13033 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
13034 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
13035 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
13036 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
13037 documentation.
13038 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
13039 Document new effective target and option set.
13040
13041 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13042
13043 * config/arm/arm-cpus.in (armv8_4): New feature.
13044 (ARMv8_4a): New fgroup.
13045 (armv8.4-a): New arch.
13046 * config/arm/arm-tables.opt: Regenerate.
13047 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
13048 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
13049 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
13050 Add matching rules for -march=armv8.4-a and extensions.
13051 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
13052
13053 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
13054
13055 PR target/81821
13056 * config/rx/rx.md (BW): New mode attribute.
13057 (sync_lock_test_and_setsi): Add mode suffix to insn output.
13058
13059 2018-01-11 Richard Biener <rguenther@suse.de>
13060
13061 PR tree-optimization/83435
13062 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
13063 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
13064 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
13065
13066 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13067 Alan Hayward <alan.hayward@arm.com>
13068 David Sherwood <david.sherwood@arm.com>
13069
13070 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
13071 field.
13072 (aarch64_classify_address): Initialize it. Track polynomial offsets.
13073 (aarch64_print_address_internal): Use it to check for a zero offset.
13074
13075 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13076 Alan Hayward <alan.hayward@arm.com>
13077 David Sherwood <david.sherwood@arm.com>
13078
13079 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
13080 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
13081 Return a poly_int64 rather than a HOST_WIDE_INT.
13082 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
13083 rather than a HOST_WIDE_INT.
13084 * config/aarch64/aarch64.h (aarch64_frame): Protect with
13085 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
13086 hard_fp_offset, frame_size, initial_adjust, callee_offset and
13087 final_offset from HOST_WIDE_INT to poly_int64.
13088 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
13089 to_constant when getting the number of units in an Advanced SIMD
13090 mode.
13091 (aarch64_builtin_vectorized_function): Check for a constant number
13092 of units.
13093 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
13094 GET_MODE_SIZE.
13095 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
13096 attribute instead of GET_MODE_NUNITS.
13097 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
13098 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
13099 GET_MODE_SIZE for fixed-size registers.
13100 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
13101 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
13102 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
13103 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
13104 (aarch64_print_operand, aarch64_print_address_internal)
13105 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
13106 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
13107 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
13108 Handle polynomial GET_MODE_SIZE.
13109 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
13110 wider than SImode without modification.
13111 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
13112 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
13113 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
13114 passing and returning SVE modes.
13115 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
13116 rather than GEN_INT.
13117 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
13118 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
13119 (aarch64_allocate_and_probe_stack_space): Likewise.
13120 (aarch64_layout_frame): Cope with polynomial offsets.
13121 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
13122 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
13123 polynomial offsets.
13124 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
13125 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
13126 poly_int64 rather than a HOST_WIDE_INT.
13127 (aarch64_get_separate_components, aarch64_process_components)
13128 (aarch64_expand_prologue, aarch64_expand_epilogue)
13129 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
13130 (aarch64_anchor_offset): New function, split out from...
13131 (aarch64_legitimize_address): ...here.
13132 (aarch64_builtin_vectorization_cost): Handle polynomial
13133 TYPE_VECTOR_SUBPARTS.
13134 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
13135 GET_MODE_NUNITS.
13136 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
13137 number of elements from the PARALLEL rather than the mode.
13138 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
13139 rather than GET_MODE_BITSIZE.
13140 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
13141 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
13142 (aarch64_expand_vec_perm_const_1): Handle polynomial
13143 d->perm.length () and d->perm elements.
13144 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
13145 Apply to_constant to d->perm elements.
13146 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
13147 polynomial CONST_VECTOR_NUNITS.
13148 (aarch64_move_pointer): Take amount as a poly_int64 rather
13149 than an int.
13150 (aarch64_progress_pointer): Avoid temporary variable.
13151 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
13152 the mode attribute instead of GET_MODE.
13153
13154 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13155 Alan Hayward <alan.hayward@arm.com>
13156 David Sherwood <david.sherwood@arm.com>
13157
13158 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
13159 x exists before using it.
13160 (aarch64_add_constant_internal): Rename to...
13161 (aarch64_add_offset_1): ...this. Replace regnum with separate
13162 src and dest rtxes. Handle the case in which they're different,
13163 including when the offset is zero. Replace scratchreg with an rtx.
13164 Use 2 additions if there is no spare register into which we can
13165 move a 16-bit constant.
13166 (aarch64_add_constant): Delete.
13167 (aarch64_add_offset): Replace reg with separate src and dest
13168 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
13169 Use aarch64_add_offset_1.
13170 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
13171 an rtx rather than an int. Take the delta as a poly_int64
13172 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
13173 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
13174 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
13175 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
13176 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
13177 and aarch64_add_sp.
13178 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
13179 aarch64_add_constant.
13180
13181 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13182
13183 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
13184 Use scalar_float_mode.
13185
13186 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13187
13188 * config/aarch64/aarch64-simd.md
13189 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
13190 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
13191 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
13192 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
13193 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
13194 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
13195 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
13196 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
13197 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
13198 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
13199
13200 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
13201
13202 PR target/83514
13203 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
13204 targ_options->x_arm_arch_string is non NULL.
13205
13206 2018-01-11 Tamar Christina <tamar.christina@arm.com>
13207
13208 * config/aarch64/aarch64.h
13209 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
13210
13211 2018-01-11 Sudakshina Das <sudi.das@arm.com>
13212
13213 PR target/82096
13214 * expmed.c (emit_store_flag_force): Swap if const op0
13215 and change VOIDmode to mode of op0.
13216
13217 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13218
13219 PR rtl-optimization/83761
13220 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
13221 than bytes to mode_for_size.
13222
13223 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
13224
13225 PR middle-end/83189
13226 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
13227 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
13228 profile.
13229
13230 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
13231
13232 PR middle-end/83575
13233 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
13234 when in layout mode.
13235 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
13236 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
13237 partition fixup.
13238
13239 2018-01-10 Michael Collison <michael.collison@arm.com>
13240
13241 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
13242 * config/aarch64/aarch64-option-extension.def: Add
13243 AARCH64_OPT_EXTENSION of 'fp16fml'.
13244 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
13245 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
13246 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
13247 * config/aarch64/constraints.md (Ui7): New constraint.
13248 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
13249 (VFMLA_SEL_W): Ditto.
13250 (f16quad): Ditto.
13251 (f16mac1): Ditto.
13252 (VFMLA16_LOW): New int iterator.
13253 (VFMLA16_HIGH): Ditto.
13254 (UNSPEC_FMLAL): New unspec.
13255 (UNSPEC_FMLSL): Ditto.
13256 (UNSPEC_FMLAL2): Ditto.
13257 (UNSPEC_FMLSL2): Ditto.
13258 (f16mac): New code attribute.
13259 * config/aarch64/aarch64-simd-builtins.def
13260 (aarch64_fmlal_lowv2sf): Ditto.
13261 (aarch64_fmlsl_lowv2sf): Ditto.
13262 (aarch64_fmlalq_lowv4sf): Ditto.
13263 (aarch64_fmlslq_lowv4sf): Ditto.
13264 (aarch64_fmlal_highv2sf): Ditto.
13265 (aarch64_fmlsl_highv2sf): Ditto.
13266 (aarch64_fmlalq_highv4sf): Ditto.
13267 (aarch64_fmlslq_highv4sf): Ditto.
13268 (aarch64_fmlal_lane_lowv2sf): Ditto.
13269 (aarch64_fmlsl_lane_lowv2sf): Ditto.
13270 (aarch64_fmlal_laneq_lowv2sf): Ditto.
13271 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
13272 (aarch64_fmlalq_lane_lowv4sf): Ditto.
13273 (aarch64_fmlsl_lane_lowv4sf): Ditto.
13274 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
13275 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
13276 (aarch64_fmlal_lane_highv2sf): Ditto.
13277 (aarch64_fmlsl_lane_highv2sf): Ditto.
13278 (aarch64_fmlal_laneq_highv2sf): Ditto.
13279 (aarch64_fmlsl_laneq_highv2sf): Ditto.
13280 (aarch64_fmlalq_lane_highv4sf): Ditto.
13281 (aarch64_fmlsl_lane_highv4sf): Ditto.
13282 (aarch64_fmlalq_laneq_highv4sf): Ditto.
13283 (aarch64_fmlsl_laneq_highv4sf): Ditto.
13284 * config/aarch64/aarch64-simd.md:
13285 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
13286 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
13287 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
13288 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
13289 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
13290 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
13291 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
13292 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
13293 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
13294 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
13295 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
13296 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
13297 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
13298 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
13299 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
13300 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
13301 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
13302 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
13303 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
13304 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
13305 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
13306 (vfmlsl_low_u32): Ditto.
13307 (vfmlalq_low_u32): Ditto.
13308 (vfmlslq_low_u32): Ditto.
13309 (vfmlal_high_u32): Ditto.
13310 (vfmlsl_high_u32): Ditto.
13311 (vfmlalq_high_u32): Ditto.
13312 (vfmlslq_high_u32): Ditto.
13313 (vfmlal_lane_low_u32): Ditto.
13314 (vfmlsl_lane_low_u32): Ditto.
13315 (vfmlal_laneq_low_u32): Ditto.
13316 (vfmlsl_laneq_low_u32): Ditto.
13317 (vfmlalq_lane_low_u32): Ditto.
13318 (vfmlslq_lane_low_u32): Ditto.
13319 (vfmlalq_laneq_low_u32): Ditto.
13320 (vfmlslq_laneq_low_u32): Ditto.
13321 (vfmlal_lane_high_u32): Ditto.
13322 (vfmlsl_lane_high_u32): Ditto.
13323 (vfmlal_laneq_high_u32): Ditto.
13324 (vfmlsl_laneq_high_u32): Ditto.
13325 (vfmlalq_lane_high_u32): Ditto.
13326 (vfmlslq_lane_high_u32): Ditto.
13327 (vfmlalq_laneq_high_u32): Ditto.
13328 (vfmlslq_laneq_high_u32): Ditto.
13329 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
13330 (AARCH64_FL_FOR_ARCH8_4): New.
13331 (AARCH64_ISA_F16FML): New ISA flag.
13332 (TARGET_F16FML): New feature flag for fp16fml.
13333 (doc/invoke.texi): Document new fp16fml option.
13334
13335 2018-01-10 Michael Collison <michael.collison@arm.com>
13336
13337 * config/aarch64/aarch64-builtins.c:
13338 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
13339 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
13340 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
13341 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
13342 (AARCH64_ISA_SHA3): New ISA flag.
13343 (TARGET_SHA3): New feature flag for sha3.
13344 * config/aarch64/iterators.md (sha512_op): New int attribute.
13345 (CRYPTO_SHA512): New int iterator.
13346 (UNSPEC_SHA512H): New unspec.
13347 (UNSPEC_SHA512H2): Ditto.
13348 (UNSPEC_SHA512SU0): Ditto.
13349 (UNSPEC_SHA512SU1): Ditto.
13350 * config/aarch64/aarch64-simd-builtins.def
13351 (aarch64_crypto_sha512hqv2di): New builtin.
13352 (aarch64_crypto_sha512h2qv2di): Ditto.
13353 (aarch64_crypto_sha512su0qv2di): Ditto.
13354 (aarch64_crypto_sha512su1qv2di): Ditto.
13355 (aarch64_eor3qv8hi): Ditto.
13356 (aarch64_rax1qv2di): Ditto.
13357 (aarch64_xarqv2di): Ditto.
13358 (aarch64_bcaxqv8hi): Ditto.
13359 * config/aarch64/aarch64-simd.md:
13360 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
13361 (aarch64_crypto_sha512su0qv2di): Ditto.
13362 (aarch64_crypto_sha512su1qv2di): Ditto.
13363 (aarch64_eor3qv8hi): Ditto.
13364 (aarch64_rax1qv2di): Ditto.
13365 (aarch64_xarqv2di): Ditto.
13366 (aarch64_bcaxqv8hi): Ditto.
13367 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
13368 (vsha512h2q_u64): Ditto.
13369 (vsha512su0q_u64): Ditto.
13370 (vsha512su1q_u64): Ditto.
13371 (veor3q_u16): Ditto.
13372 (vrax1q_u64): Ditto.
13373 (vxarq_u64): Ditto.
13374 (vbcaxq_u16): Ditto.
13375 * config/arm/types.md (crypto_sha512): New type attribute.
13376 (crypto_sha3): Ditto.
13377 (doc/invoke.texi): Document new sha3 option.
13378
13379 2018-01-10 Michael Collison <michael.collison@arm.com>
13380
13381 * config/aarch64/aarch64-builtins.c:
13382 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
13383 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
13384 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
13385 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
13386 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
13387 (AARCH64_ISA_SM4): New ISA flag.
13388 (TARGET_SM4): New feature flag for sm4.
13389 * config/aarch64/aarch64-simd-builtins.def
13390 (aarch64_sm3ss1qv4si): Ditto.
13391 (aarch64_sm3tt1aq4si): Ditto.
13392 (aarch64_sm3tt1bq4si): Ditto.
13393 (aarch64_sm3tt2aq4si): Ditto.
13394 (aarch64_sm3tt2bq4si): Ditto.
13395 (aarch64_sm3partw1qv4si): Ditto.
13396 (aarch64_sm3partw2qv4si): Ditto.
13397 (aarch64_sm4eqv4si): Ditto.
13398 (aarch64_sm4ekeyqv4si): Ditto.
13399 * config/aarch64/aarch64-simd.md:
13400 (aarch64_sm3ss1qv4si): Ditto.
13401 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
13402 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
13403 (aarch64_sm4eqv4si): Ditto.
13404 (aarch64_sm4ekeyqv4si): Ditto.
13405 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
13406 (sm3part_op): Ditto.
13407 (CRYPTO_SM3TT): Ditto.
13408 (CRYPTO_SM3PART): Ditto.
13409 (UNSPEC_SM3SS1): New unspec.
13410 (UNSPEC_SM3TT1A): Ditto.
13411 (UNSPEC_SM3TT1B): Ditto.
13412 (UNSPEC_SM3TT2A): Ditto.
13413 (UNSPEC_SM3TT2B): Ditto.
13414 (UNSPEC_SM3PARTW1): Ditto.
13415 (UNSPEC_SM3PARTW2): Ditto.
13416 (UNSPEC_SM4E): Ditto.
13417 (UNSPEC_SM4EKEY): Ditto.
13418 * config/aarch64/constraints.md (Ui2): New constraint.
13419 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
13420 * config/arm/types.md (crypto_sm3): New type attribute.
13421 (crypto_sm4): Ditto.
13422 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
13423 (vsm3tt1aq_u32): Ditto.
13424 (vsm3tt1bq_u32): Ditto.
13425 (vsm3tt2aq_u32): Ditto.
13426 (vsm3tt2bq_u32): Ditto.
13427 (vsm3partw1q_u32): Ditto.
13428 (vsm3partw2q_u32): Ditto.
13429 (vsm4eq_u32): Ditto.
13430 (vsm4ekeyq_u32): Ditto.
13431 (doc/invoke.texi): Document new sm4 option.
13432
13433 2018-01-10 Michael Collison <michael.collison@arm.com>
13434
13435 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
13436 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
13437 (AARCH64_FL_FOR_ARCH8_4): New.
13438 (AARCH64_FL_V8_4): New flag.
13439 (doc/invoke.texi): Document new armv8.4-a option.
13440
13441 2018-01-10 Michael Collison <michael.collison@arm.com>
13442
13443 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
13444 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
13445 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
13446 * config/aarch64/aarch64-option-extension.def: Add
13447 AARCH64_OPT_EXTENSION of 'sha2'.
13448 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
13449 (crypto): Disable sha2 and aes if crypto disabled.
13450 (crypto): Enable aes and sha2 if enabled.
13451 (simd): Disable sha2 and aes if simd disabled.
13452 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
13453 New flags.
13454 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
13455 (TARGET_SHA2): New feature flag for sha2.
13456 (TARGET_AES): New feature flag for aes.
13457 * config/aarch64/aarch64-simd.md:
13458 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
13459 conditional on TARGET_AES.
13460 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
13461 (aarch64_crypto_sha1hsi): Make pattern conditional
13462 on TARGET_SHA2.
13463 (aarch64_crypto_sha1hv4si): Ditto.
13464 (aarch64_be_crypto_sha1hv4si): Ditto.
13465 (aarch64_crypto_sha1su1v4si): Ditto.
13466 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
13467 (aarch64_crypto_sha1su0v4si): Ditto.
13468 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
13469 (aarch64_crypto_sha256su0v4si): Ditto.
13470 (aarch64_crypto_sha256su1v4si): Ditto.
13471 (doc/invoke.texi): Document new aes and sha2 options.
13472
13473 2018-01-10 Martin Sebor <msebor@redhat.com>
13474
13475 PR tree-optimization/83781
13476 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
13477 as string arrays.
13478
13479 2018-01-11 Martin Sebor <msebor@gmail.com>
13480 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
13481
13482 PR tree-optimization/83501
13483 PR tree-optimization/81703
13484
13485 * tree-ssa-strlen.c (get_string_cst): Rename...
13486 (get_string_len): ...to this. Handle global constants.
13487 (handle_char_store): Adjust.
13488
13489 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
13490 Jim Wilson <jimw@sifive.com>
13491
13492 * config/riscv/riscv-protos.h (riscv_output_return): New.
13493 * config/riscv/riscv.c (struct machine_function): New naked_p field.
13494 (riscv_attribute_table, riscv_output_return),
13495 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
13496 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
13497 (riscv_compute_frame_info): Only compute frame->mask if not a naked
13498 function.
13499 (riscv_expand_prologue): Add early return for naked function.
13500 (riscv_expand_epilogue): Likewise.
13501 (riscv_function_ok_for_sibcall): Return false for naked function.
13502 (riscv_set_current_function): New.
13503 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
13504 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
13505 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
13506 * doc/extend.texi (RISC-V Function Attributes): New.
13507
13508 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
13509
13510 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
13511 check for 128-bit long double before checking TCmode.
13512 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
13513 128-bit long doubles before checking TFmode or TCmode.
13514 (FLOAT128_IBM_P): Likewise.
13515
13516 2018-01-10 Martin Sebor <msebor@redhat.com>
13517
13518 PR tree-optimization/83671
13519 * builtins.c (c_strlen): Unconditionally return zero for the empty
13520 string.
13521 Use -Warray-bounds for warnings.
13522 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
13523 for non-constant array indices with COMPONENT_REF, arrays of
13524 arrays, and pointers to arrays.
13525 (gimple_fold_builtin_strlen): Determine and set length range for
13526 non-constant character arrays.
13527
13528 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
13529
13530 PR middle-end/81897
13531 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
13532 empty blocks.
13533
13534 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
13535
13536 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
13537
13538 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
13539
13540 PR target/83399
13541 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
13542 VECTOR_MEM_ALTIVEC_OR_VSX_P.
13543 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
13544 indexed_or_indirect_operand predicate.
13545 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
13546 (*vsx_le_perm_load_v8hi): Likewise.
13547 (*vsx_le_perm_load_v16qi): Likewise.
13548 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
13549 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
13550 (*vsx_le_perm_store_v8hi): Likewise.
13551 (*vsx_le_perm_store_v16qi): Likewise.
13552 (eight unnamed splitters): Likewise.
13553
13554 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
13555
13556 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
13557 * config/rs6000/emmintrin.h: Likewise.
13558 * config/rs6000/mmintrin.h: Likewise.
13559 * config/rs6000/xmmintrin.h: Likewise.
13560
13561 2018-01-10 David Malcolm <dmalcolm@redhat.com>
13562
13563 PR c++/43486
13564 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
13565 "public_flag".
13566 * tree.c (tree_nop_conversion): Return true for location wrapper
13567 nodes.
13568 (maybe_wrap_with_location): New function.
13569 (selftest::check_strip_nops): New function.
13570 (selftest::test_location_wrappers): New function.
13571 (selftest::tree_c_tests): Call it.
13572 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
13573 (maybe_wrap_with_location): New decl.
13574 (EXPR_LOCATION_WRAPPER_P): New macro.
13575 (location_wrapper_p): New inline function.
13576 (tree_strip_any_location_wrapper): New inline function.
13577
13578 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
13579
13580 PR target/83735
13581 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
13582 stack_realign_offset for the largest alignment of stack slot
13583 actually used.
13584 (ix86_find_max_used_stack_alignment): New function.
13585 (ix86_finalize_stack_frame_flags): Use it. Set
13586 max_used_stack_alignment if we don't realign stack.
13587 * config/i386/i386.h (machine_function): Add
13588 max_used_stack_alignment.
13589
13590 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
13591
13592 * config/arm/arm.opt (-mbranch-cost): New option.
13593 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
13594 account.
13595
13596 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
13597
13598 PR target/83629
13599 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
13600 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
13601
13602 2018-01-10 Richard Biener <rguenther@suse.de>
13603
13604 PR debug/83765
13605 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
13606 early out so it also covers the case where we have a non-NULL
13607 origin.
13608
13609 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
13610
13611 PR tree-optimization/83753
13612 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
13613 for non-strided grouped accesses if the number of elements is 1.
13614
13615 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
13616
13617 PR target/81616
13618 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
13619 * i386.h (TARGET_USE_GATHER): Define.
13620 * x86-tune.def (X86_TUNE_USE_GATHER): New.
13621
13622 2018-01-10 Martin Liska <mliska@suse.cz>
13623
13624 PR bootstrap/82831
13625 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
13626 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
13627 partitioning.
13628 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
13629 CLEANUP_NO_PARTITIONING is not set.
13630
13631 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
13632
13633 * doc/rtl.texi: Remove documentation of (const ...) wrappers
13634 for vectors, as a partial revert of r254296.
13635 * rtl.h (const_vec_p): Delete.
13636 (const_vec_duplicate_p): Don't test for vector CONSTs.
13637 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
13638 * expmed.c (make_tree): Likewise.
13639
13640 Revert:
13641 * common.md (E, F): Use CONSTANT_P instead of checking for
13642 CONST_VECTOR.
13643 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
13644 checking for CONST_VECTOR.
13645
13646 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
13647
13648 PR middle-end/83575
13649 * predict.c (force_edge_cold): Handle in more sane way edges
13650 with no prediction.
13651
13652 2018-01-09 Carl Love <cel@us.ibm.com>
13653
13654 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
13655 V4SI, V4SF types.
13656 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
13657 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
13658 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
13659 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
13660 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
13661 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
13662 * config/rs6000/rs6000-protos.h: Add extern defition for
13663 rs6000_generate_float2_double_code.
13664 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
13665 function.
13666 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
13667 (float2_v2df): Add define_expand.
13668
13669 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
13670
13671 PR target/83628
13672 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
13673 op_mode in the force_to_mode call.
13674
13675 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
13676
13677 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
13678 instead of checking each element individually.
13679 (aarch64_evpc_uzp): Likewise.
13680 (aarch64_evpc_zip): Likewise.
13681 (aarch64_evpc_ext): Likewise.
13682 (aarch64_evpc_rev): Likewise.
13683 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
13684 instead of checking each element individually. Return true without
13685 generating rtl if
13686 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
13687 whether all selected elements come from the same input, instead of
13688 checking each element individually. Remove calls to gen_rtx_REG,
13689 start_sequence and end_sequence and instead assert that no rtl is
13690 generated.
13691
13692 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
13693
13694 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
13695 order of HIGH and CONST checks.
13696
13697 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
13698
13699 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
13700 if the destination isn't an SSA_NAME.
13701
13702 2018-01-09 Richard Biener <rguenther@suse.de>
13703
13704 PR tree-optimization/83668
13705 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
13706 move prologue...
13707 (canonicalize_loop_form): ... here, renamed from ...
13708 (canonicalize_loop_closed_ssa_form): ... this and amended to
13709 swap successor edges for loop exit blocks to make us use
13710 the RPO order we need for initial schedule generation.
13711
13712 2018-01-09 Joseph Myers <joseph@codesourcery.com>
13713
13714 PR tree-optimization/64811
13715 * match.pd: When optimizing comparisons with Inf, avoid
13716 introducing or losing exceptions from comparisons with NaN.
13717
13718 2018-01-09 Martin Liska <mliska@suse.cz>
13719
13720 PR sanitizer/82517
13721 * asan.c (shadow_mem_size): Add gcc_assert.
13722
13723 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
13724
13725 Don't save registers in main().
13726
13727 PR target/83738
13728 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
13729 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
13730 * config/avr/avr.c (avr_set_current_function): Don't error if
13731 naked, OS_task or OS_main are specified at the same time.
13732 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
13733 OS_main.
13734 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
13735 attribute.
13736 * common/config/avr/avr-common.c (avr_option_optimization_table):
13737 Switch on -mmain-is-OS_task for optimizing compilations.
13738
13739 2018-01-09 Richard Biener <rguenther@suse.de>
13740
13741 PR tree-optimization/83572
13742 * graphite.c: Include cfganal.h.
13743 (graphite_transform_loops): Connect infinite loops to exit
13744 and remove fake edges at the end.
13745
13746 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
13747
13748 * ipa-inline.c (edge_badness): Revert accidental checkin.
13749
13750 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
13751
13752 PR ipa/80763
13753 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
13754 symbols; not inline clones.
13755
13756 2018-01-09 Jakub Jelinek <jakub@redhat.com>
13757
13758 PR target/83507
13759 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
13760 hard registers. Formatting fixes.
13761
13762 PR preprocessor/83722
13763 * gcc.c (try_generate_repro): Pass
13764 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
13765 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
13766 do_report_bug.
13767
13768 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
13769 Kito Cheng <kito.cheng@gmail.com>
13770
13771 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
13772 (riscv_leaf_function_p): Delete.
13773 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
13774
13775 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
13776
13777 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
13778 function.
13779 (do_ifelse): New function.
13780 (do_isel): New function.
13781 (do_sub3): New function.
13782 (do_add3): New function.
13783 (do_load_mask_compare): New function.
13784 (do_overlap_load_compare): New function.
13785 (expand_compare_loop): New function.
13786 (expand_block_compare): Call expand_compare_loop() when appropriate.
13787 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
13788 option description.
13789 (-mblock-compare-inline-loop-limit): New option.
13790
13791 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
13792
13793 PR target/83677
13794 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
13795 Reverse order of second and third operands in first alternative.
13796 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
13797 of first and second elements in UNSPEC_VPERMR vector.
13798 (altivec_expand_vec_perm_le): Likewise.
13799
13800 2018-01-08 Jeff Law <law@redhat.com>
13801
13802 PR rtl-optimizatin/81308
13803 * tree-switch-conversion.c (cfg_altered): New file scoped static.
13804 (process_switch): If group_case_labels makes a change, then set
13805 cfg_altered.
13806 (pass_convert_switch::execute): If a switch is converted, then
13807 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
13808
13809 PR rtl-optimization/81308
13810 * recog.c (split_all_insns): Conditionally cleanup the CFG after
13811 splitting insns.
13812
13813 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
13814
13815 PR target/83663 - Revert r255946
13816 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
13817 generation for cases where splatting a value is not useful.
13818 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
13819 across a vec_duplicate and a paradoxical subreg forming a vector
13820 mode to a vec_concat.
13821
13822 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13823
13824 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
13825 -march=armv8.3-a variants.
13826 * config/arm/t-multilib: Likewise.
13827 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
13828
13829 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
13830
13831 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
13832 to generate rtl.
13833 (cceq_ior_compare_complement): Give it a name so I can use it, and
13834 change boolean_or_operator predicate to boolean_operator so it can
13835 be used to generate a crand.
13836 (eqne): New code iterator.
13837 (bd/bd_neg): New code_attrs.
13838 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
13839 a single define_insn.
13840 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
13841 decrement (bdnzt/bdnzf/bdzt/bdzf).
13842 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
13843 with the new names of the branch decrement patterns, and added the
13844 names of the branch decrement conditional patterns.
13845
13846 2018-01-08 Richard Biener <rguenther@suse.de>
13847
13848 PR tree-optimization/83563
13849 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
13850 cache.
13851
13852 2018-01-08 Richard Biener <rguenther@suse.de>
13853
13854 PR middle-end/83713
13855 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
13856
13857 2018-01-08 Richard Biener <rguenther@suse.de>
13858
13859 PR tree-optimization/83685
13860 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
13861 references to abnormals.
13862
13863 2018-01-08 Richard Biener <rguenther@suse.de>
13864
13865 PR lto/83719
13866 * dwarf2out.c (output_indirect_strings): Handle empty
13867 skeleton_debug_str_hash.
13868 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
13869
13870 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
13871
13872 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
13873 (emit_store_direct): Likewise.
13874 (arc_trampoline_adjust_address): Likewise.
13875 (arc_asm_trampoline_template): New function.
13876 (arc_initialize_trampoline): Use asm_trampoline_template.
13877 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
13878 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
13879 * config/arc/arc.md (flush_icache): Delete pattern.
13880
13881 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
13882
13883 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
13884 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
13885 munaligned-access.
13886
13887 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
13888
13889 PR target/83681
13890 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
13891 by not USED_FOR_TARGET.
13892 (make_pass_resolve_sw_modes): Likewise.
13893
13894 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
13895
13896 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
13897 USED_FOR_TARGET.
13898
13899 2018-01-08 Richard Biener <rguenther@suse.de>
13900
13901 PR middle-end/83580
13902 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
13903
13904 2018-01-08 Richard Biener <rguenther@suse.de>
13905
13906 PR middle-end/83517
13907 * match.pd ((t * 2) / 2) -> t): Add missing :c.
13908
13909 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
13910
13911 PR middle-end/81897
13912 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
13913 basic blocks with a small number of successors.
13914 (convert_control_dep_chain_into_preds): Improve handling of
13915 forwarder blocks.
13916 (dump_predicates): Split apart into...
13917 (dump_pred_chain): ...here...
13918 (dump_pred_info): ...and here.
13919 (can_one_predicate_be_invalidated_p): Add debugging printfs.
13920 (can_chain_union_be_invalidated_p): Improve check for invalidation
13921 of paths.
13922 (uninit_uses_cannot_happen): Avoid unnecessary if
13923 convert_control_dep_chain_into_preds yielded nothing.
13924
13925 2018-01-06 Martin Sebor <msebor@redhat.com>
13926
13927 PR tree-optimization/83640
13928 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
13929 subtracting negative offset from size.
13930 (builtin_access::overlap): Adjust offset bounds of the access to fall
13931 within the size of the object if possible.
13932
13933 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
13934
13935 PR rtl-optimization/83699
13936 * expmed.c (extract_bit_field_1): Restrict the vector usage of
13937 extract_bit_field_as_subreg to cases in which the extracted
13938 value is also a vector.
13939
13940 * lra-constraints.c (process_alt_operands): Test for the equivalence
13941 substitutions when detecting a possible reload cycle.
13942
13943 2018-01-06 Jakub Jelinek <jakub@redhat.com>
13944
13945 PR debug/83480
13946 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
13947 by default if flag_selective_schedling{,2}. Formatting fixes.
13948
13949 PR rtl-optimization/83682
13950 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
13951 if it has non-VECTOR_MODE element mode.
13952 (vec_duplicate_p): Likewise.
13953
13954 PR middle-end/83694
13955 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
13956 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
13957
13958 2018-01-05 Jakub Jelinek <jakub@redhat.com>
13959
13960 PR target/83604
13961 * config/i386/i386-builtin.def
13962 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
13963 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
13964 Require also OPTION_MASK_ISA_AVX512F in addition to
13965 OPTION_MASK_ISA_GFNI.
13966 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
13967 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
13968 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
13969 to OPTION_MASK_ISA_GFNI.
13970 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
13971 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
13972 OPTION_MASK_ISA_AVX512BW.
13973 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
13974 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
13975 addition to OPTION_MASK_ISA_GFNI.
13976 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
13977 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
13978 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
13979 to OPTION_MASK_ISA_GFNI.
13980 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
13981 a requirement for all ISAs rather than any of them with a few
13982 exceptions.
13983 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
13984 processing.
13985 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
13986 bitmasks to be enabled with 3 exceptions, instead of requiring any
13987 enabled ISA with lots of exceptions.
13988 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
13989 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
13990 Change avx512bw in isa attribute to avx512f.
13991 * config/i386/sgxintrin.h: Add license boilerplate.
13992 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
13993 to __AVX512F__ and __AVX512VL to __AVX512VL__.
13994 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
13995 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
13996 defined.
13997 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
13998 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
13999 temporarily sse2 rather than sse if not enabled already.
14000
14001 PR target/83604
14002 * config/i386/sse.md (VI248_VLBW): Rename to ...
14003 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
14004 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
14005 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
14006 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
14007 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
14008 mode iterator instead of VI248_VLBW.
14009
14010 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
14011
14012 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
14013 (record_modified): Skip clobbers; add debug output.
14014 (param_change_prob): Use sreal frequencies.
14015
14016 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
14017
14018 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
14019 punt for user-aligned variables.
14020
14021 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
14022
14023 * tree-chrec.c (chrec_contains_symbols): Return true for
14024 POLY_INT_CST.
14025
14026 2018-01-05 Sudakshina Das <sudi.das@arm.com>
14027
14028 PR target/82439
14029 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
14030 of (x|y) == x for BICS pattern.
14031
14032 2018-01-05 Jakub Jelinek <jakub@redhat.com>
14033
14034 PR tree-optimization/83605
14035 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
14036 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
14037 can throw.
14038
14039 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
14040
14041 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
14042 * config/epiphany/rtems.h: New file.
14043
14044 2018-01-04 Jakub Jelinek <jakub@redhat.com>
14045 Uros Bizjak <ubizjak@gmail.com>
14046
14047 PR target/83554
14048 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
14049 QIreg_operand instead of register_operand predicate.
14050 * config/i386/i386.c (ix86_rop_should_change_byte_p,
14051 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
14052 comments instead of -fmitigate[-_]rop.
14053
14054 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
14055
14056 PR bootstrap/81926
14057 * cgraphunit.c (symbol_table::compile): Switch to text_section
14058 before calling assembly_start debug hook.
14059 * run-rtl-passes.c (run_rtl_passes): Likewise.
14060 Include output.h.
14061
14062 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
14063
14064 * tree-vrp.c (extract_range_from_binary_expr_1): Check
14065 range_int_cst_p rather than !symbolic_range_p before calling
14066 extract_range_from_multiplicative_op_1.
14067
14068 2018-01-04 Jeff Law <law@redhat.com>
14069
14070 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
14071 redundant test in assertion.
14072
14073 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
14074
14075 * doc/rtl.texi: Document machine_mode wrapper classes.
14076
14077 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
14078
14079 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
14080 using tree_to_uhwi.
14081
14082 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
14083
14084 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
14085 the VEC_PERM_EXPR fold to fail.
14086
14087 2018-01-04 Jakub Jelinek <jakub@redhat.com>
14088
14089 PR debug/83585
14090 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
14091 to switched_sections.
14092
14093 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
14094
14095 PR target/83680
14096 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
14097 test for d.testing.
14098
14099 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
14100
14101 PR target/83387
14102 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
14103 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
14104
14105 2018-01-04 Jakub Jelinek <jakub@redhat.com>
14106
14107 PR debug/83666
14108 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
14109 is BLKmode and bitpos not zero or mode change is needed.
14110
14111 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
14112
14113 PR target/83675
14114 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
14115 TARGET_VIS2.
14116
14117 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
14118
14119 PR target/83628
14120 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
14121 instead of MULT rtx. Update all corresponding splitters.
14122 (*saddl_se): Ditto.
14123 (*ssub<modesuffix>): Ditto.
14124 (*ssubl_se): Ditto.
14125 (*cmp_sadd_di): Update split patterns.
14126 (*cmp_sadd_si): Ditto.
14127 (*cmp_sadd_sidi): Ditto.
14128 (*cmp_ssub_di): Ditto.
14129 (*cmp_ssub_si): Ditto.
14130 (*cmp_ssub_sidi): Ditto.
14131 * config/alpha/predicates.md (const23_operand): New predicate.
14132 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
14133 Look for ASHIFT, not MULT inner operand.
14134 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
14135
14136 2018-01-04 Martin Liska <mliska@suse.cz>
14137
14138 PR gcov-profile/83669
14139 * gcov.c (output_intermediate_file): Add version to intermediate
14140 gcov file.
14141 * doc/gcov.texi: Document new field 'version' in intermediate
14142 file format. Fix location of '-k' option of gcov command.
14143
14144 2018-01-04 Martin Liska <mliska@suse.cz>
14145
14146 PR ipa/82352
14147 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
14148
14149 2018-01-04 Jakub Jelinek <jakub@redhat.com>
14150
14151 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
14152
14153 2018-01-03 Martin Sebor <msebor@redhat.com>
14154
14155 PR tree-optimization/83655
14156 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
14157 checking calls with invalid arguments.
14158
14159 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14160
14161 * tree-vect-stmts.c (vect_get_store_rhs): New function.
14162 (vectorizable_mask_load_store): Delete.
14163 (vectorizable_call): Return false for masked loads and stores.
14164 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
14165 instead of gimple_assign_rhs1.
14166 (vectorizable_load): Handle IFN_MASK_LOAD.
14167 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
14168
14169 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14170
14171 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
14172 split out from..,
14173 (vectorizable_mask_load_store): ...here.
14174 (vectorizable_load): ...and here.
14175
14176 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14177
14178 * tree-vect-stmts.c (vect_build_all_ones_mask)
14179 (vect_build_zero_merge_argument): New functions, split out from...
14180 (vectorizable_load): ...here.
14181
14182 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14183
14184 * tree-vect-stmts.c (vect_check_store_rhs): New function,
14185 split out from...
14186 (vectorizable_mask_load_store): ...here.
14187 (vectorizable_store): ...and here.
14188
14189 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14190
14191 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
14192 split out from...
14193 (vectorizable_mask_load_store): ...here.
14194
14195 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14196
14197 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
14198 (vect_model_store_cost): Take a vec_load_store_type instead of a
14199 vect_def_type.
14200 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
14201 (vect_model_store_cost): Take a vec_load_store_type instead of a
14202 vect_def_type.
14203 (vectorizable_mask_load_store): Update accordingly.
14204 (vectorizable_store): Likewise.
14205 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
14206
14207 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14208
14209 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
14210 IFN_MASK_LOAD calls here rather than...
14211 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
14212
14213 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14214 Alan Hayward <alan.hayward@arm.com>
14215 David Sherwood <david.sherwood@arm.com>
14216
14217 * expmed.c (extract_bit_field_1): For vector extracts,
14218 fall back to extract_bit_field_as_subreg if vec_extract
14219 isn't available.
14220
14221 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14222 Alan Hayward <alan.hayward@arm.com>
14223 David Sherwood <david.sherwood@arm.com>
14224
14225 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
14226 they are variable or constant sized.
14227 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
14228 slots for constant-sized data.
14229
14230 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14231 Alan Hayward <alan.hayward@arm.com>
14232 David Sherwood <david.sherwood@arm.com>
14233
14234 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
14235 handling COND_EXPRs with boolean comparisons, try to find a better
14236 basis for the mask type than the boolean itself.
14237
14238 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14239
14240 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
14241 is calculated and how it can be overridden.
14242 * genmodes.c (max_bitsize_mode_any_mode): New variable.
14243 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
14244 if defined.
14245 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
14246 if nonzero.
14247
14248 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14249 Alan Hayward <alan.hayward@arm.com>
14250 David Sherwood <david.sherwood@arm.com>
14251
14252 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
14253 Remove the mode argument.
14254 (aarch64_simd_valid_immediate): Remove the mode and inverse
14255 arguments.
14256 * config/aarch64/iterators.md (bitsize): New iterator.
14257 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
14258 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
14259 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
14260 aarch64_simd_valid_immediate.
14261 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
14262 (aarch64_reg_or_bic_imm): Likewise.
14263 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
14264 with an insn_type enum and msl with a modifier_type enum.
14265 Replace element_width with a scalar_mode. Change the shift
14266 to unsigned int. Add constructors for scalar_float_mode and
14267 scalar_int_mode elements.
14268 (aarch64_vect_float_const_representable_p): Delete.
14269 (aarch64_can_const_movi_rtx_p)
14270 (aarch64_simd_scalar_immediate_valid_for_move)
14271 (aarch64_simd_make_constant): Update call to
14272 aarch64_simd_valid_immediate.
14273 (aarch64_advsimd_valid_immediate_hs): New function.
14274 (aarch64_advsimd_valid_immediate): Likewise.
14275 (aarch64_simd_valid_immediate): Remove mode and inverse
14276 arguments. Rewrite to use the above. Use const_vec_duplicate_p
14277 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
14278 and aarch64_float_const_representable_p on the result.
14279 (aarch64_output_simd_mov_immediate): Remove mode argument.
14280 Update call to aarch64_simd_valid_immediate and use of
14281 simd_immediate_info.
14282 (aarch64_output_scalar_simd_mov_immediate): Update call
14283 accordingly.
14284
14285 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14286 Alan Hayward <alan.hayward@arm.com>
14287 David Sherwood <david.sherwood@arm.com>
14288
14289 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
14290 (mode_nunits): Likewise CONST_MODE_NUNITS.
14291 * machmode.def (ADJUST_NUNITS): Document.
14292 * genmodes.c (mode_data::need_nunits_adj): New field.
14293 (blank_mode): Update accordingly.
14294 (adj_nunits): New variable.
14295 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
14296 parameter.
14297 (emit_mode_size_inline): Set need_bytesize_adj for all modes
14298 listed in adj_nunits.
14299 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
14300 listed in adj_nunits. Don't emit case statements for such modes.
14301 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
14302 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
14303 nothing if adj_nunits is nonnull.
14304 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
14305 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
14306 (emit_mode_fbit): Update use of print_maybe_const_decl.
14307 (emit_move_size): Likewise. Treat the array as non-const
14308 if adj_nunits.
14309 (emit_mode_adjustments): Handle adj_nunits.
14310
14311 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14312
14313 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
14314 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
14315 (VECTOR_MODES): Use it.
14316 (make_vector_modes): Take the prefix as an argument.
14317
14318 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14319 Alan Hayward <alan.hayward@arm.com>
14320 David Sherwood <david.sherwood@arm.com>
14321
14322 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
14323 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
14324 for MODE_VECTOR_BOOL.
14325 * machmode.def (VECTOR_BOOL_MODE): Document.
14326 * genmodes.c (VECTOR_BOOL_MODE): New macro.
14327 (make_vector_bool_mode): New function.
14328 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
14329 MODE_VECTOR_BOOL.
14330 * lto-streamer-in.c (lto_input_mode_table): Likewise.
14331 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
14332 Likewise.
14333 * stor-layout.c (int_mode_for_mode): Likewise.
14334 * tree.c (build_vector_type_for_mode): Likewise.
14335 * varasm.c (output_constant_pool_2): Likewise.
14336 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
14337 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
14338 for MODE_VECTOR_BOOL.
14339 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
14340 of mode class checks.
14341 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
14342 instead of a list of mode class checks.
14343 (expand_vector_scalar_condition): Likewise.
14344 (type_for_widest_vector_mode): Handle BImode as an inner mode.
14345
14346 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14347 Alan Hayward <alan.hayward@arm.com>
14348 David Sherwood <david.sherwood@arm.com>
14349
14350 * machmode.h (mode_size): Change from unsigned short to
14351 poly_uint16_pod.
14352 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
14353 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
14354 or if measurement_type is not polynomial.
14355 (fixed_size_mode::includes_p): Check for constant-sized modes.
14356 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
14357 return a poly_uint16 rather than an unsigned short.
14358 (emit_mode_size): Change the type of mode_size from unsigned short
14359 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
14360 (emit_mode_adjustments): Cope with polynomial vector sizes.
14361 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
14362 for GET_MODE_SIZE.
14363 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
14364 for GET_MODE_SIZE.
14365 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
14366 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
14367 * caller-save.c (setup_save_areas): Likewise.
14368 (replace_reg_with_saved_mem): Likewise.
14369 * calls.c (emit_library_call_value_1): Likewise.
14370 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
14371 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
14372 (gen_lowpart_for_combine): Likewise.
14373 * convert.c (convert_to_integer_1): Likewise.
14374 * cse.c (equiv_constant, cse_insn): Likewise.
14375 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
14376 (cselib_subst_to_values): Likewise.
14377 * dce.c (word_dce_process_block): Likewise.
14378 * df-problems.c (df_word_lr_mark_ref): Likewise.
14379 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
14380 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
14381 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
14382 (rtl_for_decl_location): Likewise.
14383 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
14384 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
14385 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
14386 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
14387 (expand_expr_real_1): Likewise.
14388 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
14389 (pad_below): Likewise.
14390 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
14391 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
14392 * ira.c (get_subreg_tracking_sizes): Likewise.
14393 * ira-build.c (ira_create_allocno_objects): Likewise.
14394 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
14395 (ira_sort_regnos_for_alter_reg): Likewise.
14396 * ira-costs.c (record_operand_costs): Likewise.
14397 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
14398 (resolve_simple_move): Likewise.
14399 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
14400 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
14401 (lra_constraints): Likewise.
14402 (CONST_POOL_OK_P): Reject variable-sized modes.
14403 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
14404 (add_pseudo_to_slot, lra_spill): Likewise.
14405 * omp-low.c (omp_clause_aligned_alignment): Likewise.
14406 * optabs-query.c (get_best_extraction_insn): Likewise.
14407 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
14408 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
14409 (expand_mult_highpart, valid_multiword_target_p): Likewise.
14410 * recog.c (offsettable_address_addr_space_p): Likewise.
14411 * regcprop.c (maybe_mode_change): Likewise.
14412 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
14413 * regrename.c (build_def_use): Likewise.
14414 * regstat.c (dump_reg_info): Likewise.
14415 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
14416 (find_reloads, find_reloads_subreg_address): Likewise.
14417 * reload1.c (eliminate_regs_1): Likewise.
14418 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
14419 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
14420 (simplify_binary_operation_1, simplify_subreg): Likewise.
14421 * targhooks.c (default_function_arg_padding): Likewise.
14422 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
14423 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
14424 (verify_gimple_assign_ternary): Likewise.
14425 * tree-inline.c (estimate_move_cost): Likewise.
14426 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
14427 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
14428 (get_address_cost_ainc): Likewise.
14429 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
14430 (vect_supportable_dr_alignment): Likewise.
14431 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
14432 (vectorizable_reduction): Likewise.
14433 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
14434 (vectorizable_operation, vectorizable_load): Likewise.
14435 * tree.c (build_same_sized_truth_vector_type): Likewise.
14436 * valtrack.c (cleanup_auto_inc_dec): Likewise.
14437 * var-tracking.c (emit_note_insn_var_location): Likewise.
14438 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
14439 (ADDR_VEC_ALIGN): Likewise.
14440
14441 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14442 Alan Hayward <alan.hayward@arm.com>
14443 David Sherwood <david.sherwood@arm.com>
14444
14445 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
14446 unsigned short.
14447 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
14448 or if measurement_type is polynomial.
14449 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
14450 * combine.c (make_extraction): Likewise.
14451 * dse.c (find_shift_sequence): Likewise.
14452 * dwarf2out.c (mem_loc_descriptor): Likewise.
14453 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
14454 (extract_bit_field, extract_low_bits): Likewise.
14455 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
14456 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
14457 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
14458 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
14459 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
14460 * reload.c (find_reloads): Likewise.
14461 * reload1.c (alter_reg): Likewise.
14462 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
14463 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
14464 * tree-if-conv.c (predicate_mem_writes): Likewise.
14465 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
14466 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
14467 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
14468 * valtrack.c (dead_debug_insert_temp): Likewise.
14469 * varasm.c (mergeable_constant_section): Likewise.
14470 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
14471
14472 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14473 Alan Hayward <alan.hayward@arm.com>
14474 David Sherwood <david.sherwood@arm.com>
14475
14476 * expr.c (expand_assignment): Cope with polynomial mode sizes
14477 when assigning to a CONCAT.
14478
14479 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14480 Alan Hayward <alan.hayward@arm.com>
14481 David Sherwood <david.sherwood@arm.com>
14482
14483 * machmode.h (mode_precision): Change from unsigned short to
14484 poly_uint16_pod.
14485 (mode_to_precision): Return a poly_uint16 rather than an unsigned
14486 short.
14487 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
14488 or if measurement_type is not polynomial.
14489 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
14490 in which the mode is already known to be a scalar_int_mode.
14491 * genmodes.c (emit_mode_precision): Change the type of mode_precision
14492 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
14493 initializer.
14494 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
14495 for GET_MODE_PRECISION.
14496 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
14497 for GET_MODE_PRECISION.
14498 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
14499 as polynomial.
14500 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
14501 (expand_field_assignment, make_extraction): Likewise.
14502 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
14503 (get_last_value): Likewise.
14504 * convert.c (convert_to_integer_1): Likewise.
14505 * cse.c (cse_insn): Likewise.
14506 * expr.c (expand_expr_real_1): Likewise.
14507 * lra-constraints.c (simplify_operand_subreg): Likewise.
14508 * optabs-query.c (can_atomic_load_p): Likewise.
14509 * optabs.c (expand_atomic_load): Likewise.
14510 (expand_atomic_store): Likewise.
14511 * ree.c (combine_reaching_defs): Likewise.
14512 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
14513 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
14514 * tree.h (type_has_mode_precision_p): Likewise.
14515 * ubsan.c (instrument_si_overflow): Likewise.
14516
14517 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14518 Alan Hayward <alan.hayward@arm.com>
14519 David Sherwood <david.sherwood@arm.com>
14520
14521 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
14522 polynomial numbers of units.
14523 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
14524 (valid_vector_subparts_p): New function.
14525 (build_vector_type): Remove temporary shim and take the number
14526 of units as a poly_uint64 rather than an int.
14527 (build_opaque_vector_type): Take the number of units as a
14528 poly_uint64 rather than an int.
14529 * tree.c (build_vector_from_ctor): Handle polynomial
14530 TYPE_VECTOR_SUBPARTS.
14531 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
14532 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
14533 (build_vector_from_val): If the number of units is variable,
14534 use build_vec_duplicate_cst for constant operands and
14535 VEC_DUPLICATE_EXPR otherwise.
14536 (make_vector_type): Remove temporary is_constant ().
14537 (build_vector_type, build_opaque_vector_type): Take the number of
14538 units as a poly_uint64 rather than an int.
14539 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
14540 VECTOR_CST_NELTS.
14541 * cfgexpand.c (expand_debug_expr): Likewise.
14542 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
14543 (store_constructor, expand_expr_real_1): Likewise.
14544 (const_scalar_mask_from_tree): Likewise.
14545 * fold-const-call.c (fold_const_reduction): Likewise.
14546 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
14547 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
14548 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
14549 (fold_relational_const): Likewise.
14550 (native_interpret_vector): Likewise. Change the size from an
14551 int to an unsigned int.
14552 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
14553 TYPE_VECTOR_SUBPARTS.
14554 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
14555 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
14556 duplicating a non-constant operand into a variable-length vector.
14557 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
14558 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
14559 * ipa-icf.c (sem_variable::equals): Likewise.
14560 * match.pd: Likewise.
14561 * omp-simd-clone.c (simd_clone_subparts): Likewise.
14562 * print-tree.c (print_node): Likewise.
14563 * stor-layout.c (layout_type): Likewise.
14564 * targhooks.c (default_builtin_vectorization_cost): Likewise.
14565 * tree-cfg.c (verify_gimple_comparison): Likewise.
14566 (verify_gimple_assign_binary): Likewise.
14567 (verify_gimple_assign_ternary): Likewise.
14568 (verify_gimple_assign_single): Likewise.
14569 * tree-pretty-print.c (dump_generic_node): Likewise.
14570 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
14571 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
14572 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
14573 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
14574 (vect_shift_permute_load_chain): Likewise.
14575 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
14576 (expand_vector_condition, optimize_vector_constructor): Likewise.
14577 (lower_vec_perm, get_compute_type): Likewise.
14578 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
14579 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
14580 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
14581 (vect_recog_mask_conversion_pattern): Likewise.
14582 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
14583 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
14584 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
14585 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
14586 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
14587 (vectorizable_shift, vectorizable_operation, vectorizable_store)
14588 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
14589 (supportable_widening_operation): Likewise.
14590 (supportable_narrowing_operation): Likewise.
14591 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
14592 Likewise.
14593 * varasm.c (output_constant): Likewise.
14594
14595 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14596 Alan Hayward <alan.hayward@arm.com>
14597 David Sherwood <david.sherwood@arm.com>
14598
14599 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
14600 so that both the length == 3 and length != 3 cases set up their
14601 own permute vectors. Add comments explaining why we know the
14602 number of elements is constant.
14603 (vect_permute_load_chain): Likewise.
14604
14605 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14606 Alan Hayward <alan.hayward@arm.com>
14607 David Sherwood <david.sherwood@arm.com>
14608
14609 * machmode.h (mode_nunits): Change from unsigned char to
14610 poly_uint16_pod.
14611 (ONLY_FIXED_SIZE_MODES): New macro.
14612 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
14613 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
14614 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
14615 New typedefs.
14616 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
14617 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
14618 or if measurement_type is not polynomial.
14619 * genmodes.c (ZERO_COEFFS): New macro.
14620 (emit_mode_nunits_inline): Make mode_nunits_inline return a
14621 poly_uint16.
14622 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
14623 Use ZERO_COEFFS when emitting initializers.
14624 * data-streamer.h (bp_pack_poly_value): New function.
14625 (bp_unpack_poly_value): Likewise.
14626 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
14627 for GET_MODE_NUNITS.
14628 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
14629 for GET_MODE_NUNITS.
14630 * tree.c (make_vector_type): Remove temporary shim and make
14631 the real function take the number of units as a poly_uint64
14632 rather than an int.
14633 (build_vector_type_for_mode): Handle polynomial nunits.
14634 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
14635 * emit-rtl.c (const_vec_series_p_1): Likewise.
14636 (gen_rtx_CONST_VECTOR): Likewise.
14637 * fold-const.c (test_vec_duplicate_folding): Likewise.
14638 * genrecog.c (validate_pattern): Likewise.
14639 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
14640 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
14641 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
14642 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
14643 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
14644 * rtlanal.c (subreg_get_info): Likewise.
14645 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
14646 (vect_grouped_load_supported): Likewise.
14647 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
14648 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
14649 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
14650 (simplify_const_unary_operation, simplify_binary_operation_1)
14651 (simplify_const_binary_operation, simplify_ternary_operation)
14652 (test_vector_ops_duplicate, test_vector_ops): Likewise.
14653 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
14654 instead of CONST_VECTOR_NUNITS.
14655 * varasm.c (output_constant_pool_2): Likewise.
14656 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
14657 explicit-encoded elements in the XVEC for variable-length vectors.
14658
14659 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14660
14661 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
14662
14663 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14664 Alan Hayward <alan.hayward@arm.com>
14665 David Sherwood <david.sherwood@arm.com>
14666
14667 * coretypes.h (fixed_size_mode): Declare.
14668 (fixed_size_mode_pod): New typedef.
14669 * builtins.h (target_builtins::x_apply_args_mode)
14670 (target_builtins::x_apply_result_mode): Change type to
14671 fixed_size_mode_pod.
14672 * builtins.c (apply_args_size, apply_result_size, result_vector)
14673 (expand_builtin_apply_args_1, expand_builtin_apply)
14674 (expand_builtin_return): Update accordingly.
14675
14676 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14677
14678 * cse.c (hash_rtx_cb): Hash only the encoded elements.
14679 * cselib.c (cselib_hash_rtx): Likewise.
14680 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
14681 CONST_VECTOR encoding.
14682
14683 2018-01-03 Jakub Jelinek <jakub@redhat.com>
14684 Jeff Law <law@redhat.com>
14685
14686 PR target/83641
14687 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
14688 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
14689 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
14690 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
14691
14692 PR target/83641
14693 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
14694 explicitly probe *sp in a noreturn function if there were any callee
14695 register saves or frame pointer is needed.
14696
14697 2018-01-03 Jakub Jelinek <jakub@redhat.com>
14698
14699 PR debug/83621
14700 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
14701 BLKmode for ternary, binary or unary expressions.
14702
14703 PR debug/83645
14704 * var-tracking.c (delete_vta_debug_insn): New inline function.
14705 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
14706 insns from get_insns () to NULL instead of each bb separately.
14707 Use delete_vta_debug_insn. No longer static.
14708 (vt_debug_insns_local, variable_tracking_main_1): Adjust
14709 delete_vta_debug_insns callers.
14710 * rtl.h (delete_vta_debug_insns): Declare.
14711 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
14712 instead of variable_tracking_main.
14713
14714 2018-01-03 Martin Sebor <msebor@redhat.com>
14715
14716 PR tree-optimization/83603
14717 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
14718 arguments past the endof the argument list in functions declared
14719 without a prototype.
14720 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
14721 Avoid checking when arguments are null.
14722
14723 2018-01-03 Martin Sebor <msebor@redhat.com>
14724
14725 PR c/83559
14726 * doc/extend.texi (attribute const): Fix a typo.
14727 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
14728 issuing -Wsuggest-attribute for void functions.
14729
14730 2018-01-03 Martin Sebor <msebor@redhat.com>
14731
14732 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
14733 offset_int::from instead of wide_int::to_shwi.
14734 (maybe_diag_overlap): Remove assertion.
14735 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
14736 * gimple-ssa-sprintf.c (format_directive): Same.
14737 (parse_directive): Same.
14738 (sprintf_dom_walker::compute_format_length): Same.
14739 (try_substitute_return_value): Same.
14740
14741 2018-01-03 Jeff Law <law@redhat.com>
14742
14743 PR middle-end/83654
14744 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
14745 non-constant residual for zero at runtime and avoid probing in
14746 that case. Reorganize code for trailing problem to mirror handling
14747 of the residual.
14748
14749 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
14750
14751 PR tree-optimization/83501
14752 * tree-ssa-strlen.c (get_string_cst): New.
14753 (handle_char_store): Call get_string_cst.
14754
14755 2018-01-03 Martin Liska <mliska@suse.cz>
14756
14757 PR tree-optimization/83593
14758 * tree-ssa-strlen.c: Include tree-cfg.h.
14759 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
14760 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
14761 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
14762 to false.
14763 (strlen_dom_walker::before_dom_children): Call
14764 gimple_purge_dead_eh_edges. Dump tranformation with details
14765 dump flags.
14766 (strlen_dom_walker::before_dom_children): Update call by adding
14767 new argument cleanup_eh.
14768 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
14769
14770 2018-01-03 Martin Liska <mliska@suse.cz>
14771
14772 PR ipa/83549
14773 * cif-code.def (VARIADIC_THUNK): New enum value.
14774 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
14775 thunks.
14776
14777 2018-01-03 Jan Beulich <jbeulich@suse.com>
14778
14779 * sse.md (mov<mode>_internal): Tighten condition for when to use
14780 vmovdqu<ssescalarsize> for TI and OI modes.
14781
14782 2018-01-03 Jakub Jelinek <jakub@redhat.com>
14783
14784 Update copyright years.
14785
14786 2018-01-03 Martin Liska <mliska@suse.cz>
14787
14788 PR ipa/83594
14789 * ipa-visibility.c (function_and_variable_visibility): Skip
14790 functions with noipa attribure.
14791
14792 2018-01-03 Jakub Jelinek <jakub@redhat.com>
14793
14794 * gcc.c (process_command): Update copyright notice dates.
14795 * gcov-dump.c (print_version): Ditto.
14796 * gcov.c (print_version): Ditto.
14797 * gcov-tool.c (print_version): Ditto.
14798 * gengtype.c (create_file): Ditto.
14799 * doc/cpp.texi: Bump @copying's copyright year.
14800 * doc/cppinternals.texi: Ditto.
14801 * doc/gcc.texi: Ditto.
14802 * doc/gccint.texi: Ditto.
14803 * doc/gcov.texi: Ditto.
14804 * doc/install.texi: Ditto.
14805 * doc/invoke.texi: Ditto.
14806
14807 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14808
14809 * vector-builder.h (vector_builder::m_full_nelts): Change from
14810 unsigned int to poly_uint64.
14811 (vector_builder::full_nelts): Update prototype accordingly.
14812 (vector_builder::new_vector): Likewise.
14813 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
14814 (vector_builder::operator ==): Likewise.
14815 (vector_builder::finalize): Likewise.
14816 * int-vector-builder.h (int_vector_builder::int_vector_builder):
14817 Take the number of elements as a poly_uint64 rather than an
14818 unsigned int.
14819 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
14820 from unsigned int to poly_uint64.
14821 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
14822 (vec_perm_indices::new_vector): Likewise.
14823 (vec_perm_indices::length): Likewise.
14824 (vec_perm_indices::nelts_per_input): Likewise.
14825 (vec_perm_indices::input_nelts): Likewise.
14826 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
14827 number of elements per input as a poly_uint64 rather than an
14828 unsigned int. Use the original encoding for variable-length
14829 vectors, rather than clamping each individual element.
14830 For the second and subsequent elements in each pattern,
14831 clamp the step and base before clamping their sum.
14832 (vec_perm_indices::series_p): Handle polynomial element counts.
14833 (vec_perm_indices::all_in_range_p): Likewise.
14834 (vec_perm_indices_to_tree): Likewise.
14835 (vec_perm_indices_to_rtx): Likewise.
14836 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
14837 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
14838 (tree_vector_builder::new_binary_operation): Handle polynomial
14839 element counts. Return false if we need to know the number
14840 of elements at compile time.
14841 * fold-const.c (fold_vec_perm): Punt if the number of elements
14842 isn't known at compile time.
14843
14844 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14845
14846 * vec-perm-indices.h (vec_perm_builder): Change element type
14847 from HOST_WIDE_INT to poly_int64.
14848 (vec_perm_indices::element_type): Update accordingly.
14849 (vec_perm_indices::clamp): Handle polynomial element_types.
14850 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
14851 (vec_perm_indices::all_in_range_p): Likewise.
14852 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
14853 than shwi trees.
14854 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
14855 polynomial vec_perm_indices element types.
14856 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
14857 * fold-const.c (fold_vec_perm): Likewise.
14858 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
14859 * tree-vect-generic.c (lower_vec_perm): Likewise.
14860 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
14861 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
14862 element type to HOST_WIDE_INT.
14863
14864 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14865 Alan Hayward <alan.hayward@arm.com>
14866 David Sherwood <david.sherwood@arm.com>
14867
14868 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
14869 rather than an int. Use plus_constant.
14870 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
14871 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
14872
14873 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14874 Alan Hayward <alan.hayward@arm.com>
14875 David Sherwood <david.sherwood@arm.com>
14876
14877 * calls.c (emit_call_1, expand_call): Change struct_value_size from
14878 a HOST_WIDE_INT to a poly_int64.
14879
14880 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14881 Alan Hayward <alan.hayward@arm.com>
14882 David Sherwood <david.sherwood@arm.com>
14883
14884 * calls.c (load_register_parameters): Cope with polynomial
14885 mode sizes. Require a constant size for BLKmode parameters
14886 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
14887 forces a parameter to be padded at the lsb end in order to
14888 fill a complete number of words, require the parameter size
14889 to be ordered wrt UNITS_PER_WORD.
14890
14891 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14892 Alan Hayward <alan.hayward@arm.com>
14893 David Sherwood <david.sherwood@arm.com>
14894
14895 * reload1.c (spill_stack_slot_width): Change element type
14896 from unsigned int to poly_uint64_pod.
14897 (alter_reg): Treat mode sizes as polynomial.
14898
14899 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14900 Alan Hayward <alan.hayward@arm.com>
14901 David Sherwood <david.sherwood@arm.com>
14902
14903 * reload.c (complex_word_subreg_p): New function.
14904 (reload_inner_reg_of_subreg, push_reload): Use it.
14905
14906 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14907 Alan Hayward <alan.hayward@arm.com>
14908 David Sherwood <david.sherwood@arm.com>
14909
14910 * lra-constraints.c (process_alt_operands): Reject matched
14911 operands whose sizes aren't ordered.
14912 (match_reload): Refer to this check here.
14913
14914 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14915 Alan Hayward <alan.hayward@arm.com>
14916 David Sherwood <david.sherwood@arm.com>
14917
14918 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
14919 that the mode size is in the set {1, 2, 4, 8, 16}.
14920
14921 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14922 Alan Hayward <alan.hayward@arm.com>
14923 David Sherwood <david.sherwood@arm.com>
14924
14925 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
14926 Use plus_constant instead of gen_rtx_PLUS.
14927
14928 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14929 Alan Hayward <alan.hayward@arm.com>
14930 David Sherwood <david.sherwood@arm.com>
14931
14932 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
14933 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
14934 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
14935 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
14936 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
14937 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
14938 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
14939 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
14940 * config/i386/i386.c (ix86_push_rounding): ...this new function.
14941 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
14942 a poly_int64.
14943 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
14944 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
14945 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
14946 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
14947 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
14948 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
14949 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
14950 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
14951 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
14952 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
14953 function.
14954 * expr.c (emit_move_resolve_push): Treat the input and result
14955 of PUSH_ROUNDING as a poly_int64.
14956 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
14957 (emit_push_insn): Likewise.
14958 * lra-eliminations.c (mark_not_eliminable): Likewise.
14959 * recog.c (push_operand): Likewise.
14960 * reload1.c (elimination_effects): Likewise.
14961 * rtlanal.c (nonzero_bits1): Likewise.
14962 * calls.c (store_one_arg): Likewise. Require the padding to be
14963 known at compile time.
14964
14965 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14966 Alan Hayward <alan.hayward@arm.com>
14967 David Sherwood <david.sherwood@arm.com>
14968
14969 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
14970 Use plus_constant instead of gen_rtx_PLUS.
14971
14972 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14973 Alan Hayward <alan.hayward@arm.com>
14974 David Sherwood <david.sherwood@arm.com>
14975
14976 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
14977 rather than an int.
14978
14979 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14980 Alan Hayward <alan.hayward@arm.com>
14981 David Sherwood <david.sherwood@arm.com>
14982
14983 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
14984 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
14985 via stack temporaries. Treat the mode size as polynomial too.
14986
14987 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14988 Alan Hayward <alan.hayward@arm.com>
14989 David Sherwood <david.sherwood@arm.com>
14990
14991 * expr.c (expand_expr_real_2): When handling conversions involving
14992 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
14993 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
14994 as a poly_uint64 too.
14995
14996 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14997 Alan Hayward <alan.hayward@arm.com>
14998 David Sherwood <david.sherwood@arm.com>
14999
15000 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
15001
15002 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15003 Alan Hayward <alan.hayward@arm.com>
15004 David Sherwood <david.sherwood@arm.com>
15005
15006 * combine.c (can_change_dest_mode): Handle polynomial
15007 REGMODE_NATURAL_SIZE.
15008 * expmed.c (store_bit_field_1): Likewise.
15009 * expr.c (store_constructor): Likewise.
15010 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
15011 and polynomial REGMODE_NATURAL_SIZE.
15012 (gen_lowpart_common): Likewise.
15013 * reginfo.c (record_subregs_of_mode): Likewise.
15014 * rtlanal.c (read_modify_subreg_p): Likewise.
15015
15016 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15017 Alan Hayward <alan.hayward@arm.com>
15018 David Sherwood <david.sherwood@arm.com>
15019
15020 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
15021 numbers of elements.
15022
15023 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15024 Alan Hayward <alan.hayward@arm.com>
15025 David Sherwood <david.sherwood@arm.com>
15026
15027 * match.pd: Cope with polynomial numbers of vector elements.
15028
15029 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15030 Alan Hayward <alan.hayward@arm.com>
15031 David Sherwood <david.sherwood@arm.com>
15032
15033 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
15034 in a POINTER_PLUS_EXPR.
15035
15036 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15037 Alan Hayward <alan.hayward@arm.com>
15038 David Sherwood <david.sherwood@arm.com>
15039
15040 * omp-simd-clone.c (simd_clone_subparts): New function.
15041 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
15042 (ipa_simd_modify_function_body): Likewise.
15043
15044 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15045 Alan Hayward <alan.hayward@arm.com>
15046 David Sherwood <david.sherwood@arm.com>
15047
15048 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
15049 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
15050 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
15051 (expand_vector_condition, vector_element): Likewise.
15052 (subparts_gt): New function.
15053 (get_compute_type): Use subparts_gt.
15054 (count_type_subparts): Delete.
15055 (expand_vector_operations_1): Use subparts_gt instead of
15056 count_type_subparts.
15057
15058 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15059 Alan Hayward <alan.hayward@arm.com>
15060 David Sherwood <david.sherwood@arm.com>
15061
15062 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
15063 (vect_compile_time_alias): ...this new function. Do the calculation
15064 on poly_ints rather than trees.
15065 (vect_prune_runtime_alias_test_list): Update call accordingly.
15066
15067 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15068 Alan Hayward <alan.hayward@arm.com>
15069 David Sherwood <david.sherwood@arm.com>
15070
15071 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
15072 numbers of units.
15073 (vect_schedule_slp_instance): Likewise.
15074
15075 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15076 Alan Hayward <alan.hayward@arm.com>
15077 David Sherwood <david.sherwood@arm.com>
15078
15079 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
15080 constant and extern definitions for variable-length vectors.
15081 (vect_get_constant_vectors): Note that the number of units
15082 is known to be constant.
15083
15084 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15085 Alan Hayward <alan.hayward@arm.com>
15086 David Sherwood <david.sherwood@arm.com>
15087
15088 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
15089 of units as polynomial. Choose between WIDE and NARROW based
15090 on multiple_p.
15091
15092 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15093 Alan Hayward <alan.hayward@arm.com>
15094 David Sherwood <david.sherwood@arm.com>
15095
15096 * tree-vect-stmts.c (simd_clone_subparts): New function.
15097 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
15098
15099 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15100 Alan Hayward <alan.hayward@arm.com>
15101 David Sherwood <david.sherwood@arm.com>
15102
15103 * tree-vect-stmts.c (vectorizable_call): Treat the number of
15104 vectors as polynomial. Use build_index_vector for
15105 IFN_GOMP_SIMD_LANE.
15106
15107 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15108 Alan Hayward <alan.hayward@arm.com>
15109 David Sherwood <david.sherwood@arm.com>
15110
15111 * tree-vect-stmts.c (get_load_store_type): Treat the number of
15112 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
15113 for variable-length vectors.
15114 (vectorizable_mask_load_store): Treat the number of units as
15115 polynomial, asserting that it is constant if the condition has
15116 already been enforced.
15117 (vectorizable_store, vectorizable_load): Likewise.
15118
15119 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15120 Alan Hayward <alan.hayward@arm.com>
15121 David Sherwood <david.sherwood@arm.com>
15122
15123 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
15124 of units as polynomial. Punt if we can't tell at compile time
15125 which vector contains the final result.
15126
15127 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15128 Alan Hayward <alan.hayward@arm.com>
15129 David Sherwood <david.sherwood@arm.com>
15130
15131 * tree-vect-loop.c (vectorizable_induction): Treat the number
15132 of units as polynomial. Punt on SLP inductions. Use an integer
15133 VEC_SERIES_EXPR for variable-length integer reductions. Use a
15134 cast of such a series for variable-length floating-point
15135 reductions.
15136
15137 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15138 Alan Hayward <alan.hayward@arm.com>
15139 David Sherwood <david.sherwood@arm.com>
15140
15141 * tree.h (build_index_vector): Declare.
15142 * tree.c (build_index_vector): New function.
15143 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
15144 of units as polynomial, forcibly converting it to a constant if
15145 vectorizable_reduction has already enforced the condition.
15146 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
15147 to create a {1,2,3,...} vector.
15148 (vectorizable_reduction): Treat the number of units as polynomial.
15149 Choose vectype_in based on the largest scalar element size rather
15150 than the smallest number of units. Enforce the restrictions
15151 relied on above.
15152
15153 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15154 Alan Hayward <alan.hayward@arm.com>
15155 David Sherwood <david.sherwood@arm.com>
15156
15157 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
15158 number of units as polynomial.
15159
15160 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15161 Alan Hayward <alan.hayward@arm.com>
15162 David Sherwood <david.sherwood@arm.com>
15163
15164 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
15165 * target.def (autovectorize_vector_sizes): Return the vector sizes
15166 by pointer, using vector_sizes rather than a bitmask.
15167 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
15168 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
15169 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
15170 Likewise.
15171 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
15172 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
15173 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
15174 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
15175 * omp-general.c (omp_max_vf): Likewise.
15176 * omp-low.c (omp_clause_aligned_alignment): Likewise.
15177 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
15178 * tree-vect-loop.c (vect_analyze_loop): Likewise.
15179 * tree-vect-slp.c (vect_slp_bb): Likewise.
15180 * doc/tm.texi: Regenerate.
15181 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
15182 to a poly_uint64.
15183 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
15184 the vector size as a poly_uint64 rather than an unsigned int.
15185 (current_vector_size): Change from an unsigned int to a poly_uint64.
15186 (get_vectype_for_scalar_type): Update accordingly.
15187 * tree.h (build_truth_vector_type): Take the size and number of
15188 units as a poly_uint64 rather than an unsigned int.
15189 (build_vector_type): Add a temporary overload that takes
15190 the number of units as a poly_uint64 rather than an unsigned int.
15191 * tree.c (make_vector_type): Likewise.
15192 (build_truth_vector_type): Take the number of units as a poly_uint64
15193 rather than an unsigned int.
15194
15195 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15196 Alan Hayward <alan.hayward@arm.com>
15197 David Sherwood <david.sherwood@arm.com>
15198
15199 * target.def (get_mask_mode): Take the number of units and length
15200 as poly_uint64s rather than unsigned ints.
15201 * targhooks.h (default_get_mask_mode): Update accordingly.
15202 * targhooks.c (default_get_mask_mode): Likewise.
15203 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
15204 * doc/tm.texi: Regenerate.
15205
15206 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15207 Alan Hayward <alan.hayward@arm.com>
15208 David Sherwood <david.sherwood@arm.com>
15209
15210 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
15211 * omp-general.c (omp_max_vf): Likewise.
15212 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
15213 (expand_omp_simd): Handle polynomial safelen.
15214 * omp-low.c (omplow_simd_context): Add a default constructor.
15215 (omplow_simd_context::max_vf): Change from int to poly_uint64.
15216 (lower_rec_simd_input_clauses): Update accordingly.
15217 (lower_rec_input_clauses): Likewise.
15218
15219 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15220 Alan Hayward <alan.hayward@arm.com>
15221 David Sherwood <david.sherwood@arm.com>
15222
15223 * tree-vectorizer.h (vect_nunits_for_cost): New function.
15224 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
15225 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
15226 (vect_analyze_slp_cost): Likewise.
15227 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
15228 (vect_model_load_cost): Likewise.
15229
15230 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15231 Alan Hayward <alan.hayward@arm.com>
15232 David Sherwood <david.sherwood@arm.com>
15233
15234 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
15235 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
15236 from an unsigned int * to a poly_uint64_pod *.
15237 (calculate_unrolling_factor): New function.
15238 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
15239
15240 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15241 Alan Hayward <alan.hayward@arm.com>
15242 David Sherwood <david.sherwood@arm.com>
15243
15244 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
15245 from an unsigned int to a poly_uint64.
15246 (_loop_vec_info::slp_unrolling_factor): Likewise.
15247 (_loop_vec_info::vectorization_factor): Change from an int
15248 to a poly_uint64.
15249 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
15250 (vect_get_num_vectors): New function.
15251 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
15252 (vect_get_num_copies): Use vect_get_num_vectors.
15253 (vect_analyze_data_ref_dependences): Change max_vf from an int *
15254 to an unsigned int *.
15255 (vect_analyze_data_refs): Change min_vf from an int * to a
15256 poly_uint64 *.
15257 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
15258 than an unsigned HOST_WIDE_INT.
15259 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
15260 (vect_analyze_data_ref_dependence): Change max_vf from an int *
15261 to an unsigned int *.
15262 (vect_analyze_data_ref_dependences): Likewise.
15263 (vect_compute_data_ref_alignment): Handle polynomial vf.
15264 (vect_enhance_data_refs_alignment): Likewise.
15265 (vect_prune_runtime_alias_test_list): Likewise.
15266 (vect_shift_permute_load_chain): Likewise.
15267 (vect_supportable_dr_alignment): Likewise.
15268 (dependence_distance_ge_vf): Take the vectorization factor as a
15269 poly_uint64 rather than an unsigned HOST_WIDE_INT.
15270 (vect_analyze_data_refs): Change min_vf from an int * to a
15271 poly_uint64 *.
15272 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
15273 vfm1 as a poly_uint64 rather than an int. Make the same change
15274 for the returned bound_scalar.
15275 (vect_gen_vector_loop_niters): Handle polynomial vf.
15276 (vect_do_peeling): Likewise. Update call to
15277 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
15278 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
15279 be constant.
15280 * tree-vect-loop.c (vect_determine_vectorization_factor)
15281 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
15282 (vect_get_known_peeling_cost): Likewise.
15283 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
15284 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
15285 (vect_transform_loop): Likewise. Use the lowest possible VF when
15286 updating the upper bounds of the loop.
15287 (vect_min_worthwhile_factor): Make static. Return an unsigned int
15288 rather than an int.
15289 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
15290 polynomial unroll factors.
15291 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
15292 (vect_make_slp_decision): Likewise.
15293 (vect_supported_load_permutation_p): Likewise, and polynomial
15294 vf too.
15295 (vect_analyze_slp_cost): Handle polynomial vf.
15296 (vect_slp_analyze_node_operations): Likewise.
15297 (vect_slp_analyze_bb_1): Likewise.
15298 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
15299 than an unsigned HOST_WIDE_INT.
15300 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
15301 (vectorizable_load): Handle polynomial vf.
15302 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
15303 a poly_uint64.
15304 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
15305
15306 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15307 Alan Hayward <alan.hayward@arm.com>
15308 David Sherwood <david.sherwood@arm.com>
15309
15310 * match.pd: Handle bit operations involving three constants
15311 and try to fold one pair.
15312
15313 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15314
15315 * tree-vect-loop-manip.c: Include gimple-fold.h.
15316 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
15317 niters_maybe_zero parameters. Handle other cases besides a step of 1.
15318 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
15319 Add a path that uses a step of VF instead of 1, but disable it
15320 for now.
15321 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
15322 and niters_no_overflow parameters. Update calls to
15323 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
15324 Create a new SSA name if the latter choses to use a ste other
15325 than zero, and return it via niters_vector_mult_vf_var.
15326 * tree-vect-loop.c (vect_transform_loop): Update calls to
15327 vect_do_peeling, vect_gen_vector_loop_niters and
15328 slpeel_make_loop_iterate_ntimes.
15329 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
15330 (vect_gen_vector_loop_niters): Update declarations after above changes.
15331
15332 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
15333
15334 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
15335 128-bit round to integer instructions.
15336 (ceil<mode>2): Likewise.
15337 (btrunc<mode>2): Likewise.
15338 (round<mode>2): Likewise.
15339
15340 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
15341
15342 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
15343 unaligned VSX load/store on P8/P9.
15344 (expand_block_clear): Allow the use of unaligned VSX
15345 load/store on P8/P9.
15346
15347 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
15348
15349 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
15350 New function.
15351 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
15352 swap associated with both a load and a store.
15353
15354 2018-01-02 Andrew Waterman <andrew@sifive.com>
15355
15356 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
15357 * config/riscv/riscv.md (clear_cache): Use it.
15358
15359 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
15360
15361 * web.c: Remove out-of-date comment.
15362
15363 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15364
15365 * expr.c (fixup_args_size_notes): Check that any existing
15366 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
15367 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
15368 (emit_single_push_insn): ...here.
15369
15370 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15371
15372 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
15373 (const_vector_encoded_nelts): New function.
15374 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
15375 (const_vector_int_elt, const_vector_elt): Declare.
15376 * emit-rtl.c (const_vector_int_elt_1): New function.
15377 (const_vector_elt): Likewise.
15378 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
15379 of CONST_VECTOR_ELT.
15380
15381 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15382
15383 * expr.c: Include rtx-vector-builder.h.
15384 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
15385 directly on the tree encoding.
15386 (const_vector_from_tree): Likewise.
15387 * optabs.c: Include rtx-vector-builder.h.
15388 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
15389 sequence of "u" values.
15390 * vec-perm-indices.c: Include rtx-vector-builder.h.
15391 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
15392 directly on the vec_perm_indices encoding.
15393
15394 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15395
15396 * doc/rtl.texi (const_vector): Describe new encoding scheme.
15397 * Makefile.in (OBJS): Add rtx-vector-builder.o.
15398 * rtx-vector-builder.h: New file.
15399 * rtx-vector-builder.c: Likewise.
15400 * rtl.h (rtx_def::u2): Add a const_vector field.
15401 (CONST_VECTOR_NPATTERNS): New macro.
15402 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
15403 (CONST_VECTOR_DUPLICATE_P): Likewise.
15404 (CONST_VECTOR_STEPPED_P): Likewise.
15405 (CONST_VECTOR_ENCODED_ELT): Likewise.
15406 (const_vec_duplicate_p): Check for a duplicated vector encoding.
15407 (unwrap_const_vec_duplicate): Likewise.
15408 (const_vec_series_p): Check for a non-duplicated vector encoding.
15409 Say that the function only returns true for integer vectors.
15410 * emit-rtl.c: Include rtx-vector-builder.h.
15411 (gen_const_vec_duplicate_1): Delete.
15412 (gen_const_vector): Call gen_const_vec_duplicate instead of
15413 gen_const_vec_duplicate_1.
15414 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
15415 (gen_const_vec_duplicate): Use rtx_vector_builder.
15416 (gen_const_vec_series): Likewise.
15417 (gen_rtx_CONST_VECTOR): Likewise.
15418 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
15419 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
15420 Build a new vector rather than modifying a CONST_VECTOR in-place.
15421 (handle_special_swappables): Update call accordingly.
15422 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
15423 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
15424 Build a new vector rather than modifying a CONST_VECTOR in-place.
15425 (handle_special_swappables): Update call accordingly.
15426
15427 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15428
15429 * simplify-rtx.c (simplify_const_binary_operation): Use
15430 CONST_VECTOR_ELT instead of XVECEXP.
15431
15432 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15433
15434 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
15435 the selector elements to be different from the data elements
15436 if the selector is a VECTOR_CST.
15437 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
15438 ssizetype for the selector.
15439
15440 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15441
15442 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
15443 before testing each element individually.
15444 * tree-vect-generic.c (lower_vec_perm): Likewise.
15445
15446 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15447
15448 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
15449 * selftest-run-tests.c (selftest::run_tests): Call it.
15450 * vector-builder.h (vector_builder::operator ==): New function.
15451 (vector_builder::operator !=): Likewise.
15452 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
15453 (vec_perm_indices::all_from_input_p): New function.
15454 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
15455 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
15456 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
15457 instead of reading the VECTOR_CST directly. Detect whether both
15458 vector inputs are the same before constructing the vec_perm_indices,
15459 and update the number of inputs argument accordingly. Use the
15460 utility functions added above. Only construct sel2 if we need to.
15461
15462 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15463
15464 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
15465 the broadcast of the low byte.
15466 (expand_mult_highpart): Use an explicit encoding for the permutes.
15467 * optabs-query.c (can_mult_highpart_p): Likewise.
15468 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
15469 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
15470 (vectorizable_bswap): Likewise.
15471 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
15472 explicit encoding for the power-of-2 permutes.
15473 (vect_permute_store_chain): Likewise.
15474 (vect_grouped_load_supported): Likewise.
15475 (vect_permute_load_chain): Likewise.
15476
15477 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15478
15479 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
15480 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
15481 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
15482 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
15483 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
15484 (vect_gen_perm_mask_any): Likewise.
15485
15486 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15487
15488 * int-vector-builder.h: New file.
15489 * vec-perm-indices.h: Include int-vector-builder.h.
15490 (vec_perm_indices): Redefine as an int_vector_builder.
15491 (auto_vec_perm_indices): Delete.
15492 (vec_perm_builder): Redefine as a stand-alone class.
15493 (vec_perm_indices::vec_perm_indices): New function.
15494 (vec_perm_indices::clamp): Likewise.
15495 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
15496 (vec_perm_indices::new_vector): New function.
15497 (vec_perm_indices::new_expanded_vector): Update for new
15498 vec_perm_indices class.
15499 (vec_perm_indices::rotate_inputs): New function.
15500 (vec_perm_indices::all_in_range_p): Operate directly on the
15501 encoded form, without computing elided elements.
15502 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
15503 encoding. Update for new vec_perm_indices class.
15504 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
15505 the given vec_perm_builder.
15506 (expand_vec_perm_var): Update vec_perm_builder constructor.
15507 (expand_mult_highpart): Use vec_perm_builder instead of
15508 auto_vec_perm_indices.
15509 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
15510 vec_perm_indices instead of auto_vec_perm_indices. Use a single
15511 or double series encoding as appropriate.
15512 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
15513 vec_perm_indices instead of auto_vec_perm_indices.
15514 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
15515 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
15516 (vect_permute_store_chain): Likewise.
15517 (vect_grouped_load_supported): Likewise.
15518 (vect_permute_load_chain): Likewise.
15519 (vect_shift_permute_load_chain): Likewise.
15520 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
15521 (vect_transform_slp_perm_load): Likewise.
15522 (vect_schedule_slp_instance): Likewise.
15523 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
15524 (vectorizable_mask_load_store): Likewise.
15525 (vectorizable_bswap): Likewise.
15526 (vectorizable_store): Likewise.
15527 (vectorizable_load): Likewise.
15528 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
15529 vec_perm_indices instead of auto_vec_perm_indices. Use
15530 tree_to_vec_perm_builder to read the vector from a tree.
15531 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
15532 vec_perm_builder instead of a vec_perm_indices.
15533 (have_whole_vector_shift): Use vec_perm_builder and
15534 vec_perm_indices instead of auto_vec_perm_indices. Leave the
15535 truncation to calc_vec_perm_mask_for_shift.
15536 (vect_create_epilog_for_reduction): Likewise.
15537 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
15538 from auto_vec_perm_indices to vec_perm_indices.
15539 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
15540 instead of changing individual elements.
15541 (aarch64_vectorize_vec_perm_const): Use new_vector to install
15542 the vector in d.perm.
15543 * config/arm/arm.c (expand_vec_perm_d::perm): Change
15544 from auto_vec_perm_indices to vec_perm_indices.
15545 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
15546 instead of changing individual elements.
15547 (arm_vectorize_vec_perm_const): Use new_vector to install
15548 the vector in d.perm.
15549 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
15550 Update vec_perm_builder constructor.
15551 (rs6000_expand_interleave): Likewise.
15552 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
15553 (rs6000_expand_interleave): Likewise.
15554
15555 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15556
15557 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
15558 to qimode could truncate the indices.
15559 * optabs.c (expand_vec_perm_var): Likewise.
15560
15561 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15562
15563 * Makefile.in (OBJS): Add vec-perm-indices.o.
15564 * vec-perm-indices.h: New file.
15565 * vec-perm-indices.c: Likewise.
15566 * target.h (vec_perm_indices): Replace with a forward class
15567 declaration.
15568 (auto_vec_perm_indices): Move to vec-perm-indices.h.
15569 * optabs.h: Include vec-perm-indices.h.
15570 (expand_vec_perm): Delete.
15571 (selector_fits_mode_p, expand_vec_perm_var): Declare.
15572 (expand_vec_perm_const): Declare.
15573 * target.def (vec_perm_const_ok): Replace with...
15574 (vec_perm_const): ...this new hook.
15575 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
15576 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
15577 * doc/tm.texi: Regenerate.
15578 * optabs.def (vec_perm_const): Delete.
15579 * doc/md.texi (vec_perm_const): Likewise.
15580 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
15581 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
15582 expand_vec_perm for constant permutation vectors. Assert that
15583 the mode of variable permutation vectors is the integer equivalent
15584 of the mode that is being permuted.
15585 * optabs-query.h (selector_fits_mode_p): Declare.
15586 * optabs-query.c: Include vec-perm-indices.h.
15587 (selector_fits_mode_p): New function.
15588 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
15589 is defined, instead of checking whether the vec_perm_const_optab
15590 exists. Use targetm.vectorize.vec_perm_const instead of
15591 targetm.vectorize.vec_perm_const_ok. Check whether the indices
15592 fit in the vector mode before using a variable permute.
15593 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
15594 vec_perm_indices instead of an rtx.
15595 (expand_vec_perm): Replace with...
15596 (expand_vec_perm_const): ...this new function. Take the selector
15597 as a vec_perm_indices rather than an rtx. Also take the mode of
15598 the selector. Update call to shift_amt_for_vec_perm_mask.
15599 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
15600 Use vec_perm_indices::new_expanded_vector to expand the original
15601 selector into bytes. Check whether the indices fit in the vector
15602 mode before using a variable permute.
15603 (expand_vec_perm_var): Make global.
15604 (expand_mult_highpart): Use expand_vec_perm_const.
15605 * fold-const.c: Includes vec-perm-indices.h.
15606 * tree-ssa-forwprop.c: Likewise.
15607 * tree-vect-data-refs.c: Likewise.
15608 * tree-vect-generic.c: Likewise.
15609 * tree-vect-loop.c: Likewise.
15610 * tree-vect-slp.c: Likewise.
15611 * tree-vect-stmts.c: Likewise.
15612 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
15613 Delete.
15614 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
15615 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
15616 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
15617 (aarch64_vectorize_vec_perm_const): ...this new function.
15618 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
15619 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15620 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
15621 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
15622 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
15623 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15624 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
15625 into...
15626 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
15627 check for NEON modes.
15628 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
15629 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
15630 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
15631 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
15632 into...
15633 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
15634 the old VEC_PERM_CONST conditions.
15635 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
15636 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
15637 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
15638 (ia64_vectorize_vec_perm_const_ok): Merge into...
15639 (ia64_vectorize_vec_perm_const): ...this new function.
15640 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
15641 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
15642 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
15643 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
15644 * config/mips/mips.c (mips_expand_vec_perm_const)
15645 (mips_vectorize_vec_perm_const_ok): Merge into...
15646 (mips_vectorize_vec_perm_const): ...this new function.
15647 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
15648 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
15649 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
15650 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
15651 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
15652 (rs6000_expand_vec_perm_const): Delete.
15653 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
15654 Delete.
15655 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15656 (altivec_expand_vec_perm_const_le): Take each operand individually.
15657 Operate on constant selectors rather than rtxes.
15658 (altivec_expand_vec_perm_const): Likewise. Update call to
15659 altivec_expand_vec_perm_const_le.
15660 (rs6000_expand_vec_perm_const): Delete.
15661 (rs6000_vectorize_vec_perm_const_ok): Delete.
15662 (rs6000_vectorize_vec_perm_const): New function.
15663 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
15664 an element count and rtx array.
15665 (rs6000_expand_extract_even): Update call accordingly.
15666 (rs6000_expand_interleave): Likewise.
15667 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
15668 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
15669 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
15670 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
15671 (rs6000_expand_vec_perm_const): Delete.
15672 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
15673 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15674 (altivec_expand_vec_perm_const_le): Take each operand individually.
15675 Operate on constant selectors rather than rtxes.
15676 (altivec_expand_vec_perm_const): Likewise. Update call to
15677 altivec_expand_vec_perm_const_le.
15678 (rs6000_expand_vec_perm_const): Delete.
15679 (rs6000_vectorize_vec_perm_const_ok): Delete.
15680 (rs6000_vectorize_vec_perm_const): New function. Remove stray
15681 reference to the SPE evmerge intructions.
15682 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
15683 an element count and rtx array.
15684 (rs6000_expand_extract_even): Update call accordingly.
15685 (rs6000_expand_interleave): Likewise.
15686 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
15687 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
15688 new function.
15689 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15690
15691 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15692
15693 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
15694 vector mode and that that mode matches the mode of the data
15695 being permuted.
15696 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
15697 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
15698 directly using expand_vec_perm_1 when forcing selectors into
15699 registers.
15700 (expand_vec_perm_var): New function, split out from expand_vec_perm.
15701
15702 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15703
15704 * optabs-query.h (can_vec_perm_p): Delete.
15705 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
15706 * optabs-query.c (can_vec_perm_p): Split into...
15707 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
15708 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
15709 particular selector is valid.
15710 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
15711 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
15712 (vect_grouped_load_supported): Likewise.
15713 (vect_shift_permute_load_chain): Likewise.
15714 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
15715 (vect_transform_slp_perm_load): Likewise.
15716 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
15717 (vectorizable_bswap): Likewise.
15718 (vect_gen_perm_mask_checked): Likewise.
15719 * fold-const.c (fold_ternary_loc): Likewise. Don't take
15720 implementations of variable permutation vectors into account
15721 when deciding which selector to use.
15722 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
15723 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
15724 with a false third argument.
15725 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
15726 to test whether the constant selector is valid and can_vec_perm_var_p
15727 to test whether a variable selector is valid.
15728
15729 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15730
15731 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
15732 * optabs-query.c (can_vec_perm_p): Likewise.
15733 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
15734 instead of vec_perm_indices.
15735 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
15736 (vect_gen_perm_mask_checked): Likewise,
15737 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
15738 (vect_gen_perm_mask_checked): Likewise,
15739
15740 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15741
15742 * optabs-query.h (qimode_for_vec_perm): Declare.
15743 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
15744 (qimode_for_vec_perm): ...this new function.
15745 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
15746
15747 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
15748
15749 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
15750 does not have a conditional at the top.
15751
15752 2018-01-02 Richard Biener <rguenther@suse.de>
15753
15754 * ipa-inline.c (big_speedup_p): Fix expression.
15755
15756 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
15757
15758 PR target/81616
15759 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
15760 for generic 4->6.
15761
15762 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
15763
15764 PR target/81616
15765 Generic tuning.
15766 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
15767 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
15768 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
15769 cond_taken_branch_cost 3->4.
15770
15771 2018-01-01 Jakub Jelinek <jakub@redhat.com>
15772
15773 PR tree-optimization/83581
15774 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
15775 TODO_cleanup_cfg if any changes have been made.
15776
15777 PR middle-end/83608
15778 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
15779 convert_modes if target mode has the right side, but different mode
15780 class.
15781
15782 PR middle-end/83609
15783 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
15784 last argument when extracting from CONCAT. If either from_real or
15785 from_imag is NULL, use expansion through memory. If result is not
15786 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
15787 the parts directly to inner mode, if even that fails, use expansion
15788 through memory.
15789
15790 PR middle-end/83623
15791 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
15792 check for bswap in mode rather than HImode and use that in expand_unop
15793 too.
15794 \f
15795 Copyright (C) 2018 Free Software Foundation, Inc.
15796
15797 Copying and distribution of this file, with or without modification,
15798 are permitted in any medium without royalty provided the copyright
15799 notice and this notice are preserved.
This page took 0.711063 seconds and 6 git commands to generate.