]> gcc.gnu.org Git - gcc.git/blob - gcc/ChangeLog
backport: re PR middle-end/89412 (gcc ICE in simplify_subreg, at simplify-rtx.c:6273...
[gcc.git] / gcc / ChangeLog
1 2019-04-30 Jakub Jelinek <jakub@redhat.com>
2
3 Backported from mainline
4 2019-02-20 Jakub Jelinek <jakub@redhat.com>
5
6 PR middle-end/89412
7 * expr.c (expand_assignment): If result is a MEM, use change_address
8 instead of simplify_gen_subreg.
9
10 2019-02-20 Jakub Jelinek <jakub@redhat.com>
11 David Malcolm <dmalcolm@redhat.com>
12
13 PR middle-end/89091
14 * fold-const.c (decode_field_reference): Return NULL_TREE if
15 lang_hooks.types.type_for_size returns NULL. Check it before
16 overwriting *exp_. Use return NULL_TREE instead of return 0.
17
18 2019-02-20 Jakub Jelinek <jakub@redhat.com>
19
20 PR middle-end/88074
21 PR middle-end/89415
22 * toplev.c (do_compile): Double the emin/emax exponents to workaround
23 buggy mpc_norm.
24
25 2019-02-19 Richard Biener <rguenther@suse.de>
26
27 PR middle-end/88074
28 * toplev.c (do_compile): Initialize mpfr's exponent range
29 based on available float modes.
30
31 2019-04-30 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
32
33 Backport from mainline.
34 2019-04-30 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
35 PR target/86538
36 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
37 Define __ARM_FEATURE_ATOMICS.
38
39 2019-04-30 Srinath Parvathaneni <srinath.parvathaneni@arm.com>
40
41 Backport from mainline
42 2018-12-11 Richard Earnshaw <Richard.Earnshaw@arm.com>
43
44 PR target/37369
45 * config/aarch64/iterators.md (sizem1): Add sizes for
46 SFmode and DFmode.
47 (Vbtype): Add SFmode mapping.
48 * config/aarch64/aarch64.md (copysigndf3, copysignsf3): Delete.
49 (copysign<GPF:mode>3): New expand pattern.
50 (copysign<GPF:mode>3_insn): New insn pattern.
51
52 2019-04-29 Richard Sandiford <richard.sandiford@arm.com>
53
54 Backport from mainline:
55 2019-01-25 Richard Sandiford <richard.sandiford@arm.com>
56
57 PR middle-end/89037
58 * varasm.c (output_constructor_bitfield): Use wi::extract_uhwi
59 instead of accessing TREE_INT_CST_ELT directly.
60
61 2019-04-29 Richard Sandiford <richard.sandiford@arm.com>
62
63 Backport from mainline:
64 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
65
66 PR target/85910
67 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
68 aarch64_evpc_tbl guard.
69
70 2019-04-29 Richard Sandiford <richard.sandiford@arm.com>
71
72 Backport from mainline:
73 2019-03-08 Richard Sandiford <richard.sandiford@arm.com>
74
75 PR debug/89631
76 * dwarf2cfi.c (dwarf2out_frame_debug_expr): Use CONST_POLY_INT
77 instead of POLY_INT_CST.
78
79 2019-04-26 Roman Zhuykov <zhroma@ispras.ru>
80
81 Backport from mainline
82 2019-04-23 Roman Zhuykov <zhroma@ispras.ru>
83
84 PR rtl-optimization/87979
85 * modulo-sched.c (sms_schedule): Start ii value "mii" should
86 not equal zero.
87
88 PR rtl-optimization/84032
89 * modulo-sched.c (ps_insn_find_column): Change condition so that
90 branch will always be the last insn in a row inside partial
91 schedule.
92
93 2019-04-19 Pat Haugen <pthaugen@us.ibm.com>
94
95 Backport from mainline:
96 2019-04-16 Pat Haugen <pthaugen@us.ibm.com>
97
98 PR target/84369
99 * config/rs6000/power9.md: Add store forwarding bypass.
100
101 2019-04-17 Martin Jambor <mjambor@suse.cz>
102
103 Backport from mainline
104 2019-03-10 Martin Jambor <mjambor@suse.cz>
105
106 PR tree-optimization/85762
107 PR tree-optimization/87008
108 PR tree-optimization/85459
109 * tree-sra.c (contains_vce_or_bfcref_p): New parameter, set the bool
110 it points to if there is a type changing MEM_REF. Adjust all callers.
111 (build_accesses_from_assign): Disable total scalarization if
112 contains_vce_or_bfcref_p returns true through the new parameter, for
113 both rhs and lhs.
114
115 2019-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
116
117 Backport from mainline
118 2019-03-15 Kelvin Nilsen <kelvin@gcc.gnu.org>
119
120 PR target/87532
121 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
122 When handling vec_extract, use modular arithmetic to allow
123 constant selectors greater than vector length.
124 * config/rs6000/rs6000.c (rs6000_expand_vector_extract): Allow
125 V1TImode vectors to have constant selector values greater than 0.
126 Use modular arithmetic to compute vector index.
127 (rs6000_split_vec_extract_var): Use modular arithmetic to compute
128 index for in-memory vectors. Correct code generation for
129 in-register vectors. Use inner mode of vector rather than mode of
130 destination for move instruction.
131 (altivec_expand_vec_ext_builtin): Use modular arithmetic to
132 compute index.
133
134 2019-04-12 Kelvin Nilsen <kelvin@gcc.gnu.org>
135
136 PR target/87532
137 * config/rs6000/vsx.md (*vsx_extract_<mode>_<VS_scalar>mode_var):
138 Use QI inner mode with V16QI vector mode.
139
140 2019-04-15 Martin Jambor <mjambor@suse.cz>
141
142 Backport from mainline
143 2019-04-15 Martin Jambor <mjambor@suse.cz>
144
145 PR ipa/89693
146 * cgraph.c (clone_of_p): Loop over clone chain for each step in
147 the thunk chain.
148
149 2019-04-15 Martin Liska <mliska@suse.cz>
150
151 Backport from mainline
152 2019-01-18 Martin Liska <mliska@suse.cz>
153 Richard Biener <rguenther@suse.de>
154
155 PR middle-end/88587
156 * cgraph.h (create_version_clone_with_body): Add new argument
157 with attributes.
158 * cgraphclones.c (cgraph_node::create_version_clone): Add
159 DECL_ATTRIBUTES to a newly created decl. And call
160 valid_attribute_p so that proper cl_target_optimization_node
161 is set for the newly created declaration.
162 * multiple_target.c (create_target_clone): Set DECL_ATTRIBUTES
163 for declaration.
164 (expand_target_clones): Do not call valid_attribute_p, it must
165 be already done.
166 * tree-inline.c (copy_decl_for_dup_finish): Reset mode for
167 vector types.
168
169 2019-04-11 Richard Biener <rguenther@suse.de>
170
171 PR tree-optimization/90018
172 * tree-vect-data-refs.c (vect_preserves_scalar_order_p):
173 Test both SLP and interleaving variants.
174
175 2019-04-10 Matthew Malcomson <matthew.malcomson@arm.com>
176
177 PR target/90024
178 * config/arm/arm.c (neon_valid_immediate): Disallow VOIDmode parameter.
179 * config/arm/constraints.md (Dm, DN, Dn): Split previous Dn constraint
180 into three.
181 * config/arm/neon.md (*neon_mov<mode>): Account for TImode and DImode
182 differences directly.
183 (*smax<mode>3_neon, vashl<mode>3, vashr<mode>3_imm): Use Dm constraint.
184
185 2019-04-07 Uroš Bizjak <ubizjak@gmail.com>
186
187 PR target/89945
188 * config/i386/i386.md (anddi_1 to andsi_1_zext splitter):
189 Avoid calling gen_lowpart with SYMBOL_REF and LABEL_REF operand.
190
191 2019-04-04 Martin Sebor <msebor@redhat.com>
192
193 PR middle-end/89934
194 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Bail
195 out if the number of arguments is less than expected.
196
197 2019-04-03 Richard Biener <rguenther@suse.de>
198
199 PR lto/89896
200 * lto-wrapper.c (run_gcc): Avoid implicit rules making
201 the all target phony.
202
203 2019-04-02 Uroš Bizjak <ubizjak@gmail.com>
204
205 PR target/89902
206 PR target/89903
207 * config/i386/i386.c (dimode_scalar_to_vector_candidate_p):
208 Return false for variable DImode shifts.
209 (dimode_scalar_chain::compute_convert_gain): Do not handle
210 register count operand in variable DImode shifts.
211 (dimode_scalar_chain::make_vector_copies): Remove support to copy
212 count argument of a variable shift instruction to a vector register.
213 (dimode_scalar_chain::convert_reg): Remove support to convert
214 count argument of a variable shift instruction.
215
216 2019-03-29 Kugan Vivekanandarajah <kuganv@linaro.org>
217
218 Backport from mainline
219 2019-03-29 Kugan Vivekanandarajah <kuganv@linaro.org>
220 Eric Botcazou <ebotcazou@adacore.com>
221
222 PR rtl-optimization/89862
223 * rtl.h (word_register_operation_p): Exclude CONST_INT from operations
224 that operates on the full registers for WORD_REGISTER_OPERATIONS
225 architectures.
226
227 2019-03-28 Uroš Bizjak <ubizjak@gmail.com>
228
229 PR target/89848
230 * config/i386/i386.c (dimode_scalar_chain::make_vector_copies):
231 Also process XEXP (src, 0) of a shift insn.
232
233 2019-03-28 Martin Liska <mliska@suse.cz>
234
235 Backport from mainline
236 2018-11-05 Martin Liska <mliska@suse.cz>
237
238 PR web/87829
239 * doc/invoke.texi: Remove options that are
240 not disabled with -Os.
241
242 2019-03-26 Uroš Bizjak <ubizjak@gmail.com>
243
244 PR target/89827
245 * config/i386/i386.c (dimode_scalar_chain::convert_reg):
246 Also process XEXP (src, 0) of a shift insn.
247
248 2019-03-25 Andreas Krebbel <krebbel@linux.ibm.com>
249
250 Backport from mainline
251 2019-03-20 Andreas Krebbel <krebbel@linux.ibm.com>
252
253 PR target/89775
254 * config/s390/s390.c (global_not_special_regno_p): Move to make it
255 available to ...
256 (s390_optimize_register_info): Use global_not_special_regno_p to
257 check for global regs.
258
259 2019-03-22 Bill Schmidt <wschmidt@linux.ibm.com>
260
261 Backport from mainline
262 2019-03-22 Bill Schmidt <wschmidt@linux.ibm.com>
263
264 * config/rs6000/mmintrin.h (_mm_sub_pi32): Fix typo.
265
266 2019-03-21 Bill Schmidt <wschmidt@linux.ibm.com>
267
268 Backport from mainline
269 2019-03-08 Bill Schmidt <wschmidt@linux.ibm.com>
270
271 * config/rs6000/rs6000-p8swap.c (rs6000_analyze_swaps): Rebuild
272 ud- and du-chains between phases.
273
274 2019-03-19 Richard Biener <rguenther@suse.de>
275
276 PR debug/88389
277 * opts.c (finish_options): Disable -gsplit-dwarf when doing LTO.
278
279 2019-03-19 Eric Botcazou <ebotcazou@adacore.com>
280
281 PR rtl-optimization/89753
282 * loop-unroll.c (decide_unroll_constant_iterations): Make guard for
283 explicit unrolling factor even more robust.
284
285 2019-03-18 Martin Sebor <msebor@redhat.com>
286
287 PR middle-end/88273
288 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range):
289 Handle anti-ranges the same as no range at all.
290
291 2019-03-18 Martin Jambor <mjambor@suse.cz>
292
293 Backport from mainline
294 2019-03-18 Martin Jambor <mjambor@suse.cz>
295
296 PR tree-optimization/89546
297 * tree-sra.c (propagate_subaccesses_across_link): Requeue new_acc if
298 any propagation to its children took place.
299
300 2019-03-17 H.J. Lu <hongjiu.lu@intel.com>
301
302 Backport from mainline
303 2019-03-14 H.J. Lu <hongjiu.lu@intel.com>
304
305 PR target/89523
306 * config/i386/i386.c (ix86_print_operand): Handle 'M' to add
307 addr32 prefix to VSIB address for X32.
308 * config/i386/sse.md (*avx512pf_gatherpf<mode>sf_mask): Prepend
309 "%M2" to opcode.
310 (*avx512pf_gatherpf<mode>df_mask): Likewise.
311 (*avx512pf_scatterpf<mode>sf_mask): Likewise.
312 (*avx512pf_scatterpf<mode>df_mask): Likewise.
313 (*avx2_gathersi<mode>): Prepend "%M3" to opcode.
314 (*avx2_gathersi<mode>_2): Prepend "%M2" to opcode.
315 (*avx2_gatherdi<mode>): Prepend "%M3" to opcode.
316 (*avx2_gatherdi<mode>_2): Prepend "%M2" to opcode.
317 (*avx2_gatherdi<mode>_3): Prepend "%M3" to opcode.
318 (*avx2_gatherdi<mode>_4): Prepend "%M2" to opcode.`
319 (*avx512f_gathersi<mode>): Prepend "%M4" to opcode.
320 (*avx512f_gathersi<mode>_2): Prepend "%M3" to opcode.
321 (*avx512f_gatherdi<mode>): Prepend "%M4" to opcode.
322 (*avx512f_gatherdi<mode>_2): Prepend "%M3" to opcode.
323 (*avx512f_scattersi<mode>): Prepend "%M0" to opcode.
324 (*avx512f_scatterdi<mode>): Likewise.
325
326 2019-03-15 Richard Biener <rguenther@suse.de>
327
328 Backport from mainline
329 2018-11-30 Jakub Jelinek <jakub@redhat.com>
330
331 PR testsuite/85368
332 * params.def (PARAM_LOGICAL_OP_NON_SHORT_CIRCUIT): New param.
333 * tree-ssa-ifcombine.c (ifcombine_ifandif): If
334 --param logical-op-non-short-circuit is present, override
335 LOGICAL_OP_NON_SHORT_CIRCUIT value from the param.
336 * fold-const.c (fold_range_test, fold_truth_andor): Likewise.
337
338 2019-03-15 Martin Liska <mliska@suse.cz>
339
340 PR other/89712
341 * doc/invoke.texi: Remove -fdump-class-hierarchy option.
342
343 2019-03-14 Martin Jambor <mjambor@suse.cz>
344
345 Backport from mainline
346 2019-03-07 Martin Jambor <mjambor@suse.cz>
347
348 PR lto/87525
349 * ipa-cp.c (perform_estimation_of_a_value): Account zero time benefit
350 for extern inline functions.
351
352 2019-03-14 Richard Biener <rguenther@suse.de>
353
354 PR middle-end/89572
355 * tree-scalar-evolution.c (get_loop_exit_condition): Use
356 safe_dyn_cast.
357 * tree-ssa-loop-ivcanon.c (canonicalize_loop_induction_variables):
358 Use gimple_location_safe.
359
360 2019-03-13 Vladimir Makarov <vmakarov@redhat.com>
361
362 PR target/85860
363 * lra-constraints.c (inherit_in_ebb): Update
364 potential_reload_hard_regs along with live_hard_regs.
365
366 2019-03-14 Richard Biener <rguenther@suse.de>
367
368 Backport from mainline
369 2019-03-13 Richard Biener <rguenther@suse.de>
370
371 PR middle-end/89677
372 * tree-scalar-evolution.c (simplify_peeled_chrec): Do not
373 throw FP expressions at tree-affine.
374
375 2019-03-01 Richard Biener <rguenther@suse.de>
376
377 PR middle-end/89497
378 * tree-cfgcleanup.h (cleanup_tree_cfg): Add SSA update flags
379 argument, defaulted to zero.
380 * passes.c (execute_function_todo): Pass down SSA update flags
381 to cleanup_tree_cfg.
382 * tree-cfgcleanup.c: Include tree-into-ssa.h and tree-cfgcleanup.h.
383 (cleanup_tree_cfg_1): After cleanup_control_flow_pre update SSA
384 form if requested.
385 (cleanup_tree_cfg_noloop): Pass down SSA update flags.
386 (cleanup_tree_cfg): Get and pass down SSA update flags.
387
388 2019-02-18 Richard Biener <rguenther@suse.de>
389
390 PR tree-optimization/89296
391 * tree-ssa-loop-ch.c (ch_base::copy_headers): Restrict setting
392 of no-warning flag to cases that might emit the bogus warning.
393
394 2019-03-13 Andreas Krebbel <krebbel@linux.ibm.com>
395
396 Backport from mainline
397 2019-03-11 Andreas Krebbel <krebbel@linux.ibm.com>
398
399 * config/s390/s390.c (s390_expand_builtin): Do the copy_to_reg not
400 only on the else branch.
401
402 2019-03-13 Andreas Krebbel <krebbel@linux.ibm.com>
403
404 Backport from mainline
405 2019-02-07 Andreas Krebbel <krebbel@linux.ibm.com>
406
407 * config/s390/s390-builtin-types.def: Add new types.
408 * config/s390/s390-builtins.def: (s390_vec_xl, s390_vec_xld2)
409 (s390_vec_xlw4): Make the memory operand into a const pointer.
410 (s390_vec_xld2, s390_vec_xlw4): Add a variant for single precision
411 float.
412 * config/s390/s390-c.c (s390_expand_overloaded_builtin): Generate
413 a new vector type with the alignment of the scalar memory operand.
414
415 2019-03-12 Richard Biener <rguenther@suse.de>
416
417 PR tree-optimization/89664
418 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Properly
419 free the occurance tree after the early out.
420
421 2019-03-12 Andre Vieira <andre.simoesdiasvieira@arm.com>
422
423 Backport from mainline
424 2019-03-08 Andre Vieira <andre.simoesdiasvieira@arm.com>
425
426 * config/arm/arm.h (TARGET_FP16_TO_DOUBLE): Add TARGET_VFP_DOUBLE
427 requirement.
428
429 2019-03-11 Eric Botcazou <ebotcazou@adacore.com>
430
431 PR rtl-optimization/89588
432 * loop-unroll.c (decide_unroll_constant_iterations): Make guard for
433 explicit unrolling factor more robust.
434
435 2019-03-11 Martin Liska <mliska@suse.cz>
436
437 Backport from mainline
438 2019-03-08 Martin Liska <mliska@suse.cz>
439
440 PR target/86952
441 * config/i386/i386.c (ix86_option_override_internal): Disable
442 jump tables when retpolines are used.
443
444 2019-03-11 Martin Liska <mliska@suse.cz>
445
446 Backport from mainline
447 2019-02-11 David Malcolm <dmalcolm@redhat.com>
448
449 PR lto/88147
450 * input.c (selftest::test_line_offset_overflow): New selftest.
451 (selftest::input_c_tests): Call it.
452
453 2019-03-08 Martin Jambor <mjambor@suse.cz>
454
455 Backport from mainline
456 2019-03-07 Martin Jambor <mjambor@suse.cz>
457
458 PR ipa/88235
459 * cgraph.h (cgraph_node): New inline method former_thunk_p.
460 * cgraph.c (cgraph_node::dump): Dump a note if node is a former thunk.
461 (clone_of_p): Treat expanded thunks like thunks, be optimistic if they
462 have multiple callees. At the end check if declarations match as
463 opposed to cgraph_nodes.
464
465 2019-03-06 Tamar Christina <tamar.christina@arm.com>
466
467 Backport from trunk.
468 2019-02-25 Tamar Christina <tamar.christina@arm.com>
469
470 PR target/88530
471 * common/config/aarch64/aarch64-common.c
472 (struct aarch64_option_extension): Add is_synthetic.
473 (all_extensions): Use it.
474 (TARGET_OPTION_INIT_STRUCT): Define hook.
475 (struct gcc_targetm_common): Moved to end.
476 (all_extensions_by_on): New.
477 (opt_ext_cmp, typedef opt_ext): New.
478 (aarch64_option_init_struct): New.
479 (aarch64_contains_opt): New.
480 (aarch64_get_extension_string_for_isa_flags): Output smallest set.
481 * config/aarch64/aarch64-option-extensions.def
482 (AARCH64_OPT_EXTENSION): Explicitly include AES and SHA2 in crypto.
483 (fp, simd, crc, lse, fp16, rcpc, rdma, dotprod, aes, sha2, sha3,
484 sm4, fp16fml, sve):
485 Set is_synthetic to false.
486 (crypto): Set is_synthetic to true.
487 * config/aarch64/driver-aarch64.c (AARCH64_OPT_EXTENSION): Add
488 SYNTHETIC.
489
490 2019-03-06 Tamar Christina <tamar.christina@arm.com>
491
492 Backport from trunk.
493 2019-02-28 Tamar Christina <tamar.christina@arm.com>
494
495 PR target/88530
496 * config/aarch64/aarch64-option-extensions.def: Document it.
497 * config/aarch64/driver-aarch64.c (host_detect_local_cpu): Skip feature
498 if empty hwcaps.
499
500 2019-03-06 Xiong Hu Luo <luoxhu@linux.ibm.com>
501
502 Backport of r268834 from mainline to gcc-8-branch.
503 2019-02-13 Xiong Hu Luo <luoxhu@linux.vnet.ibm.com>
504
505 * config/rs6000/altivec.h (vec_sbox_be, vec_cipher_be,
506 vec_cipherlast_be, vec_ncipher_be, vec_ncipherlast_be): New #defines.
507 * config/rs6000/crypto.md (CR_vqdi): New define_mode_iterator.
508 (crypto_vsbox_<mode>, crypto_<CR_insn>_<mode>): New define_insns.
509 * config/rs6000/rs6000-builtin.def (VSBOX_BE): New BU_CRYPTO_1.
510 (VCIPHER_BE, VCIPHERLAST_BE, VNCIPHER_BE, VNCIPHERLAST_BE):
511 New BU_CRYPTO_2.
512 * config/rs6000/rs6000.c (builtin_function_type)
513 <CRYPTO_BUILTIN_VSBOX_BE, CRYPTO_BUILTIN_VCIPHER_BE,
514 CRYPTO_BUILTIN_VCIPHERLAST_BE, CRYPTO_BUILTIN_VNCIPHER_BE,
515 CRYPTO_BUILTIN_VNCIPHERLAST_BE>: New switch options.
516 * doc/extend.texi (vec_sbox_be, vec_cipher_be, vec_cipherlast_be,
517 vec_ncipher_be, vec_ncipherlast_be): New builtin functions.
518
519 2019-03-05 Richard Biener <rguenther@suse.de>
520
521 Backport from mainline
522 2019-02-26 Richard Biener <rguenther@suse.de>
523
524 PR tree-optimization/89505
525 * tree-ssa-structalias.c (compute_dependence_clique): Make sure
526 to handle restrict pointed-to vars with multiple subvars
527 correctly.
528
529 2019-03-01 Tamar Christina <tamar.christina@arm.com>
530
531 PR target/89517
532 * config/aarch64/aarch64-option-extensions.def (fp, simd, crypto,
533 fp16): Collapse line.
534
535 2019-03-01 Richard Biener <rguenther@suse.de>
536
537 Backport from mainline
538 2019-03-01 Jakub Jelinek <jakub@redhat.com>
539
540 PR bootstrap/89539
541 * dwarf2out.c (output_comdat_type_unit): Add ATTRIBUTE_UNUSED to
542 early_lto_debug argument.
543
544 2019-02-27 Richard Biener <rguenther@suse.de>
545
546 PR debug/88878
547 * dwarf2out.c (use_debug_types): Disable when in_lto_p.
548
549 2019-02-27 Richard Biener <rguenther@suse.de>
550
551 PR debug/88878
552 * dwarf2out.c (output_comdat_type_unit): Add early_lto_debug
553 parameter, prefix section name with .gnu.debuglto_ if true.
554 (dwarf2out_finish): Pass false to output_comdat_type_unit.
555 (dwarf2out_early_finish): Pass true to output_comdat_type_unit.
556
557 2019-02-27 Richard Biener <rguenther@suse.de>
558
559 PR debug/89514
560 * dwarf2out.c (size_of_die): Key on AT_ref (a)->comdat_type_p
561 rather than on use_debug_types, doing what output_die does.
562 (value_format): Likewise.
563
564 2019-02-28 Eric Botcazou <ebotcazou@adacore.com>
565
566 PR tree-optimization/89536
567 * tree-ssa-dom.c (edge_info::derive_equivalences) <BIT_NOT_EXPR>: Test
568 only whether bit #0 of the value is 0 instead of the entire value.
569
570 2019-02-28 Li Jia He <helijia@linux.ibm.com>
571
572 Backport from trunk
573 2019-02-20 Li Jia He <helijia@linux.ibm.com>
574
575 PR target/88100
576 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin)
577 <case ALTIVEC_BUILTIN_VSPLTISB, ALTIVEC_BUILTIN_VSPLTISH,
578 ALTIVEC_BUILTIN_VSPLTISW>: Don't convert the operand before
579 range checking it.
580
581 2019-02-27 Uroš Bizjak <ubizjak@gmail.com>
582
583 PR target/89397
584 * config/i386/i386.c (ix86_atomic_assign_expand_fenv): Check
585 TARGET_SSE in addition to TARGET_SSE_MATH.
586
587 (ix86_excess_precision): Ditto.
588 (ix86_float_exceptions_rounding_supported_p): Ditto.
589 (use_rsqrt_p): Ditto.
590 * config/i386/sse.md (rsqrt<mode>2): Ditto.
591
592 2019-02-27 Jakub Jelinek <jakub@redhat.com>
593
594 Backported from mainline
595 2019-02-18 Jakub Jelinek <jakub@redhat.com>
596
597 PR target/89361
598 * config/s390/s390.c (s390_indirect_branch_attrvalue,
599 s390_indirect_branch_settings): Define unconditionally.
600 (s390_set_current_function): Likewise, but guard the whole body except
601 the s390_indirect_branch_settings call with
602 #if S390_USE_TARGET_ATTRIBUTE.
603 (TARGET_SET_CURRENT_FUNCTION): Redefine unconditionally.
604
605 2019-02-26 Eric Botcazou <ebotcazou@adacore.com>
606
607 Backport from mainline
608 2019-02-19 Eric Botcazou <ebotcazou@adacore.com>
609
610 * rtlanal.c (get_initial_register_offset): Fall back to the estimate
611 as long as the epilogue isn't completed.
612
613 2019-02-26 Eric Botcazou <ebotcazou@adacore.com>
614
615 * tree-ssa-dom.c (edge_info::derive_equivalences) <BIT_IOR_EXPR>: Fix
616 and move around comment.
617 <BIT_AND_EXPR>: Likewise.
618 <BIT_NOT_EXPR>: Add specific handling for boolean types.
619
620 2019-02-24 Alan Modra <amodra@gmail.com>
621
622 PR target/89271
623 * config/rs6000/rs6000.md (<bd>_<mode> split): Check for an int
624 output reg on add insn.
625 (<bd>tf_<mode> split): Likewise. Match predicates with insn.
626
627 2019-02-22 Jakub Jelinek <jakub@redhat.com>
628
629 * BASE-VER: Set to 8.3.1.
630
631 2019-02-22 Release Manager
632
633 * GCC 8.3.0 released.
634
635 2019-02-15 Richard Biener <rguenther@suse.de>
636 Jakub Jelinek <jakub@redhat.com>
637
638 PR tree-optimization/89278
639 * tree-loop-distribution.c: Include tree-eh.h.
640 (generate_memset_builtin, generate_memcpy_builtin): Call
641 rewrite_to_non_trapping_overflow on builtin->size before passing it
642 to force_gimple_operand_gsi.
643
644 2019-02-15 Jakub Jelinek <jakub@redhat.com>
645
646 PR other/89342
647 * optc-save-gen.awk: Handle optimize_fast like optimize_size or
648 optimize_debug.
649 * opth-gen.awk: Likewise.
650
651 2019-02-14 David Malcolm <dmalcolm@redhat.com>
652
653 Backport of r267957 from trunk.
654 2019-01-15 David Malcolm <dmalcolm@redhat.com>
655
656 PR c++/88795
657 * tree.c (build_function_type): Assert that arg_types is not
658 error_mark_node.
659
660 2019-02-14 Jakub Jelinek <jakub@redhat.com>
661
662 PR rtl-optimization/89354
663 * combine.c (make_extraction): Punt if extraction_mode is narrower
664 than len bits.
665
666 2019-02-14 David Malcolm <dmalcolm@redhat.com>
667
668 Backport of r263339 from trunk.
669 2018-08-06 David Malcolm <dmalcolm@redhat.com>
670
671 * function-tests.c (selftest::test_expansion_to_rtl): Call
672 free_after_compilation.
673
674 2019-02-14 David Malcolm <dmalcolm@redhat.com>
675
676 Backport of r263295 from trunk.
677 2018-08-03 David Malcolm <dmalcolm@redhat.com>
678
679 * doc/gcov.texi (-x): Remove duplicate "to".
680 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
681 (-Wif-not-aligned): Remove duplicate "is".
682 (-flto): Remove duplicate "the".
683 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
684 duplicate "v5.00.b".
685 (MSP430 Options): Remove duplicate "and" from the description
686 of "-mgprel-sec=regexp".
687 (x86 Options): Remove duplicate copies of "vmldLog102" and
688 vmlsLog104 from description of "-mveclibabi=type".
689
690 2019-02-14 David Malcolm <dmalcolm@redhat.com>
691
692 Backport of r263275 from trunk.
693 2018-08-02 David Malcolm <dmalcolm@redhat.com>
694
695 * diagnostic-show-locus.c (diagnostic_show_locus): Use
696 pp_take_prefix when saving the existing prefix.
697 * diagnostic.c (diagnostic_append_note): Likewise.
698 * langhooks.c (lhd_print_error_function): Likewise.
699 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
700 param's type. Free the existing prefix.
701 (pp_take_prefix): New function.
702 (pretty_printer::pretty_printer): Drop the prefix parameter.
703 Rename the length parameter to match the comment.
704 (pretty_printer::~pretty_printer): Free the prefix.
705 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
706 parameter.
707 (struct pretty_printer): Drop the "const" from "prefix" field's
708 type and clarify memory management.
709 (pp_set_prefix): Drop the "const" from the 2nd param.
710 (pp_take_prefix): New decl.
711
712 2019-02-14 Segher Boessenkool <segher@kernel.crashing.org>
713
714 Backport from trunk
715 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
716
717 PR target/86684
718 PR target/87149
719 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
720
721 2019-02-14 Segher Boessenkool <segher@kernel.crashing.org>
722
723 Backport from trunk
724 2019-01-18 Segher Boessenkool <segher@kernel.crashing.org>
725
726 PR target/88892
727 * config/rs6000/rs6000.md (*movsi_from_df): Allow only register
728 operands.
729
730 2019-02-14 Segher Boessenkool <segher@kernel.crashing.org>
731
732 Backport from trunk
733 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
734
735 PR rtl-optimization/85805
736 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
737 value for hard registers if that was written in the same mode.
738
739 2019-02-14 Martin Liska <mliska@suse.cz>
740
741 Backport from mainline
742 2019-02-14 Martin Liska <mliska@suse.cz>
743
744 PR rtl-optimization/89242
745 * dce.c (delete_unmarked_insns): Call free_dominance_info we
746 process a transformation.
747
748 2019-02-14 Martin Liska <mliska@suse.cz>
749
750 Backport from mainline
751 2019-02-13 Martin Liska <mliska@suse.cz>
752
753 PR lto/88858
754 * cfgrtl.c (remove_barriers_from_footer): New function.
755 (try_redirect_by_replacing_jump): Use it.
756 (cfg_layout_redirect_edge_and_branch): Likewise.
757
758 2019-02-14 Martin Liska <mliska@suse.cz>
759
760 Backport from mainline
761 2019-02-11 Martin Liska <mliska@suse.cz>
762
763 PR ipa/89009
764 * ipa-cp.c (build_toporder_info): Remove usage of a param.
765 * ipa-inline.c (inline_small_functions): Likewise.
766 * ipa-pure-const.c (propagate_pure_const): Likewise.
767 (propagate_nothrow): Likewise.
768 * ipa-reference.c (propagate): Likewise.
769 * ipa-utils.c (struct searchc_env): Remove unused field.
770 (searchc): Always search across AVAIL_INTERPOSABLE.
771 (ipa_reduced_postorder): Always allow AVAIL_INTERPOSABLE as
772 the only called IPA pure const can properly not propagate
773 across interposable boundary.
774 * ipa-utils.h (ipa_reduced_postorder): Remove param.
775
776 2019-02-14 Jakub Jelinek <jakub@redhat.com>
777
778 PR tree-optimization/89314
779 * fold-const.c (fold_binary_loc): Cast strlen argument to
780 const char * before dereferencing it. Formatting fixes.
781
782 Backported from mainline
783 2019-02-13 Jakub Jelinek <jakub@redhat.com>
784
785 PR middle-end/89303
786 * tree-ssa-structalias.c (set_uids_in_ptset): Or in vi->is_heap_var
787 into pt->vars_contains_escaped_heap instead of setting
788 pt->vars_contains_escaped_heap to it.
789
790 PR middle-end/89281
791 * optabs.c (prepare_cmp_insn): Use UINTVAL (size) instead of
792 INTVAL (size), compare it to GET_MODE_MASK instead of
793 1 << GET_MODE_BITSIZE.
794
795 PR target/89290
796 * config/i386/predicates.md (x86_64_immediate_operand): Allow
797 TLS UNSPECs offsetted by signed 32-bit CONST_INT even with
798 -mcmodel=large.
799
800 2019-02-09 Jakub Jelinek <jakub@redhat.com>
801
802 PR middle-end/89246
803 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
804 If !node->definition and TYPE_ARG_TYPES is non-NULL, use
805 TYPE_ARG_TYPES instead of DECL_ARGUMENTS.
806
807 2019-02-13 Bill Schmidt <wschmidt@linux.ibm.com>
808
809 Backport from mainline
810 2019-02-11 Bill Schmidt <wschmidt@linux.ibm.com>
811
812 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Shift-right
813 and shift-left vector built-ins need to include a TRUNC_MOD_EXPR
814 for correct semantics.
815
816 2019-02-13 Richard Biener <rguenther@suse.de>
817
818 Backport from mainline
819 2019-01-08 Richard Biener <rguenther@suse.de>
820
821 PR tree-optimization/86554
822 * tree-ssa-sccvn.c (visit_nary_op): When value-numbering to
823 expressions with different overflow behavior make sure there's an
824 available expression on the path.
825
826 2019-02-13 Martin Liska <mliska@suse.cz>
827
828 PR lto/89260
829 * lto-streamer.h (LTO_minor_version): Bump version due
830 to r268698.
831
832 2019-02-13 Richard Biener <rguenther@suse.de>
833
834 Backport from mainline
835 2019-02-12 Richard Biener <rguenther@suse.de>
836
837 PR tree-optimization/89253
838 * tree-ssa-loop-split.c (tree_ssa_split_loops): Check we can
839 duplicate the loop.
840
841 2019-02-08 Richard Biener <rguenther@suse.de>
842
843 PR middle-end/89223
844 * tree-data-ref.c (initialize_matrix_A): Fail if constant
845 doesn't fit in HWI.
846 (analyze_subscript_affine_affine): Handle failure from
847 initialize_matrix_A.
848
849 2019-01-28 Richard Biener <rguenther@suse.de>
850
851 PR tree-optimization/88739
852 * tree-ssa-sccvn.c (vn_reference_lookup_3): Avoid generating
853 BIT_FIELD_REFs of non-mode-precision integral operands.
854
855 2019-02-12 Jan Hubicka <hubicka@ucw.cz>
856
857 Backport from mainline:
858 2019-02-09 Jan Hubicka <hubicka@ucw.cz>
859
860 * ipa-visibility.c (localize_node): Also do not localize
861 LDPR_PREVAILING_DEF_IRONLY_EXP.
862
863 2019-02-11 Stefan Agner <stefan@agner.ch>
864
865 Backport from mainline.
866 2019-01-10 Stefan Agner <stefan@agner.ch>
867
868 PR target/88648
869 * config/arm/arm.c (arm_option_override_internal): Force
870 opts->x_inline_asm_unified to true only if TARGET_THUMB2_P.
871
872 2019-02-09 Jan Hubicka <hubicka@ucw.cz>
873
874 Backport from mainline:
875 2019-01-05 Jan Hubicka <hubicka@ucw.cz>
876
877 PR tree-opt/86020
878 Revert:
879 2017-05-22 Jan Hubicka <hubicka@ucw.cz>
880
881 * ipa-inline.c (edge_badness): Use inlined_time instead of
882 inline_summaries->get.
883
884 2019-02-09 Aaron Sawdey <acsawdey@linux.ibm.com>
885
886 Backported from mainline
887 2019-02-05 Aaron Sawdey <acsawdey@linux.ibm.com>
888
889 PR target/89112
890 * config/rs6000/rs6000.md (<bd>tf_<mode>): Generate a local label
891 for the long branch case.
892
893 2019-02-05 Aaron Sawdey <acsawdey@linux.ibm.com>
894
895 PR target/89112
896 * config/rs6000/rs6000-string.c (do_ifelse, expand_cmp_vec_sequence,
897 expand_compare_loop, expand_block_compare_gpr,
898 expand_strncmp_align_check, expand_strncmp_gpr_sequence): Insert
899 REG_BR_PROB notes in inline expansion of memcmp/strncmp. Add
900 #include "profile-count.h" and "predict.h" for types and functions
901 needed to work with REG_BR_PROB notes.
902
903 2019-02-09 Aaron Sawdey <acsawdey@linux.ibm.com>
904
905 * config/rs6000/rs6000-string.c (expand_compare_loop,
906 expand_block_compare): Insert REG_BR_PROB notes in inline expansion of
907 memcmp/strncmp.
908
909 2019-02-09 Jakub Jelinek <jakub@redhat.com>
910
911 Backported from mainline
912 2019-01-16 David Malcolm <dmalcolm@redhat.com>
913
914 PR target/88861
915 * combine.c (delete_noop_moves): Convert to "bool" return,
916 returning true if any edges are eliminated.
917 (combine_instructions): Also return true if delete_noop_moves
918 returns true.
919
920 2019-02-08 Jakub Jelinek <jakub@redhat.com>
921
922 PR rtl-optimization/89234
923 * except.c (copy_reg_eh_region_note_forward): Return if note_or_insn
924 is a NOTE, CODE_LABEL etc. - rtx_insn * other than INSN_P.
925 (copy_reg_eh_region_note_backward): Likewise.
926
927 2019-02-09 Alan Modra <amodra@gmail.com>
928
929 PR target/88343
930 * config/rs6000/rs6000.c (save_reg_p): Match logic in
931 rs6000_emit_prologue emitting pic_offset_table setup.
932
933 2019-02-08 Richard Biener <rguenther@suse.de>
934
935 Backport from mainline
936 2018-11-13 Richard Biener <rguenther@suse.de>
937
938 PR tree-optimization/86991
939 * tree-vect-loop.c (vect_is_slp_reduction): Delay reduction
940 group building until we have successfully detected the SLP
941 reduction.
942 (vect_is_simple_reduction): Remove fixup code here.
943
944 2019-02-08 Richard Biener <rguenther@suse.de>
945
946 Backport from mainline
947 2019-02-03 Richard Biener <rguenther@suse.de>
948
949 PR debug/87295
950 * dwarf2out.c (copy_ancestor_tree): Register non-stubs as
951 orig.
952
953 2019-01-29 Richard Biener <rguenther@suse.de>
954
955 PR debug/87295
956 * dwarf2out.c (collect_skeleton_dies): New helper.
957 (copy_decls_for_unworthy_types): Call it.
958 (build_abbrev_table): Do not try to replace
959 DW_AT_signature refs with local refs.
960
961 2019-01-17 Richard Biener <rguenther@suse.de>
962
963 PR lto/86736
964 * dwarf2out.c (want_pubnames): Never generate pubnames sections
965 and friends for the LTO part of debug info.
966
967 2019-01-24 Richard Biener <rguenther@suse.de>
968
969 PR lto/87187
970 * tree-streamer-out.c (write_ts_decl_common_tree_pointers):
971 When in "legacy" debug mode make sure to reset self-origins.
972
973 2019-01-15 Richard Biener <rguenther@suse.de>
974
975 PR debug/88046
976 * dwarf2out.c (gen_member_die): Do not generate inheritance
977 DIEs late.
978
979 2018-11-22 Richard Biener <rguenther@suse.de>
980
981 PR lto/87229
982 PR lto/88112
983 * lto-streamer-out.c (lto_is_streamable): Allow CALL_EXPRs
984 which can appear in size expressions.
985 * tree-streamer-in.c (unpack_ts_base_value_fields): Stream
986 CALL_EXPR_BY_DESCRIPTOR.
987 (streamer_read_tree_bitfields): Stream CALL_EXPR_IFN.
988 * tree-streamer-out.c (pack_ts_base_value_fields): Stream
989 CALL_EXPR_BY_DESCRIPTOR.
990 (streamer_write_tree_bitfields): Stream CALL_EXPR_IFN.
991
992 2019-02-08 Christophe Lyon <christophe.lyon@linaro.org>
993
994 Backport from mainline
995 2019-01-07 Christophe Lyon <christophe.lyon@linaro.org>
996
997 PR target/85596
998 * doc/install.texi (with-multilib-list): Document for aarch64.
999
1000 2019-02-08 Richard Biener <rguenther@suse.de>
1001
1002 Backport from mainline
1003 2018-12-10 Richard Biener <rguenther@suse.de>
1004
1005 PR tree-optimization/88427
1006 * vr-values.c (vr_values::extract_range_from_phi_node):
1007 Handle symbolic ranges conservatively when trying to drop
1008 to Inf +- 1.
1009
1010 2018-11-28 Richard Biener <rguenther@suse.de>
1011
1012 PR tree-optimization/88217
1013 * vr-values.c (vr_values::extract_range_from_phi_node): Make
1014 sure to handle results > +INF and < -INF correctly when
1015 trying to drop down to +INF - 1 or -INF + 1.
1016
1017 2018-11-23 Richard Biener <rguenther@suse.de>
1018
1019 PR tree-optimization/88149
1020 * tree-vect-slp.c (vect_slp_analyze_node_operations): Detect
1021 the case where there are two different def types for the
1022 same operand at different operand position in the same stmt.
1023
1024 2019-02-07 Jakub Jelinek <jakub@redhat.com>
1025
1026 Backported from mainline
1027 2019-02-05 Jakub Jelinek <jakub@redhat.com>
1028
1029 PR target/89188
1030 * dce.c (delete_unmarked_insns): Don't remove no-op moves if they
1031 can throw, non-call exceptions are enabled and we can't delete
1032 dead exceptions or alter cfg. Set must_clean if
1033 delete_insn_and_edges returns true, don't set it blindly for calls.
1034
1035 PR rtl-optimization/89195
1036 * combine.c (make_extraction): For MEMs, don't extract bytes outside
1037 of the original MEM.
1038
1039 PR target/89186
1040 * optabs.c (prepare_cmp_insn): Pass x and y to
1041 emit_block_comp_via_libcall rather than XEXP (x, 0) and XEXP (y, 0).
1042
1043 2019-02-02 Jakub Jelinek <jakub@redhat.com>
1044
1045 PR middle-end/87887
1046 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
1047 Punt with warning on aggregate return or argument types. Ignore
1048 type/mode checking for uniform arguments.
1049
1050 2019-02-01 Jakub Jelinek <jakub@redhat.com>
1051
1052 PR tree-optimization/88107
1053 * tree-cfg.c (find_outermost_region_in_block): Add ALL argument,
1054 instead of assertion that eh_region_outermost is non-NULL, if it
1055 is NULL, set *ALL to true and return NULL.
1056 (move_sese_region_to_fn): Adjust caller, if all is set, call
1057 duplicate_eh_regions with NULL region.
1058
1059 2019-01-31 Jakub Jelinek <jakub@redhat.com>
1060
1061 PR sanitizer/89124
1062 * ipa-inline.c (sanitize_attrs_match_for_inline_p): Allow inlining
1063 always_inline callees into no_sanitize_address callers.
1064
1065 2019-01-30 Jakub Jelinek <jakub@redhat.com>
1066
1067 PR c++/89105
1068 * config/i386/i386.c (ix86_warn_parameter_passing_abi): Don't warn
1069 for arguments to functions that are TU-local and shouldn't be
1070 referenced by assembly.
1071
1072 2019-01-29 Jakub Jelinek <jakub@redhat.com>
1073
1074 PR c++/66676
1075 PR ipa/89104
1076 * omp-simd-clone.c (simd_clone_clauses_extract)
1077 <case OMP_CLAUSE_ALIGNED>: Ignore clauses with NULL
1078 OMP_CLAUSE_ALIGNED_ALIGNMENT.
1079
1080 2019-01-28 Jakub Jelinek <jakub@redhat.com>
1081
1082 PR middle-end/89002
1083 * gimplify.c (gimplify_omp_for): When adding OMP_CLAUSE_*_GIMPLE_SEQ
1084 for lastprivate/linear IV, push gimplify context around gimplify_assign
1085 and, if it needed any temporaries, pop it into a gimple bind around the
1086 sequence.
1087
1088 PR target/89073
1089 * doc/invoke.texi (-mclwb, -mprfchw, -mrdpid, -mrdseed, -msgx,
1090 -madx, -mhle, -mavx5124fmaps, -mavx512vnni, -mavx5124vnniw): Document
1091 x86 ISA options.
1092 (bmi2): Add missing @opindex.
1093 * doc/extend.texi (x86 target attribute): Move fma4, lwp, ssse3
1094 options alphabetically. Add missing 3dnow, 3dnowa, adx, avx, avx2,
1095 avx5124fmaps, avx5124vnniw, avx512bitalg, avx512bw, avx512cd,
1096 avx512dq, avx512er, avx512f, avx512ifma, avx512pf, avx512vbmi,
1097 avx512vbmi2, avx512vl, avx512vnni, avx512vpopcntdq, bmi, bmi2,
1098 clflushopt, clwb, clzero, crc32, cx16, f16c, fma, fsgsbase,
1099 fxsr, gfni, hle, lzcnt, movbe, movdir64b, movdiri, mwaitx, pconfig,
1100 pku, prefetchwt1, prfchw, rdpid, rdrnd, rdseed, rtm, sahf,
1101 sgx, sha, shstk, tbm, vaes, vpclmulqdq, wbnoinvd, xsave,
1102 xsavec, xsaveopt and xsaves options.
1103
1104 2019-01-27 Jakub Jelinek <jakub@redhat.com>
1105
1106 PR target/87214
1107 * config/i386/sse.md
1108 (<mask_codefor>avx512dq_shuf_<shuffletype>64x2_1<mask_name>,
1109 avx512f_shuf_<shuffletype>64x2_1<mask_name>): Ensure the
1110 first constants in pairs are multiples of 2. Formatting fixes.
1111 (avx512vl_shuf_<shuffletype>32x4_1<mask_name>,
1112 avx512vl_shuf_<shuffletype>32x4_1<mask_name>): Ensure the
1113 first constants in each quadruple are multiples of 4. Formatting fixes.
1114
1115 2019-01-24 Jakub Jelinek <jakub@redhat.com>
1116
1117 PR tree-optimization/88964
1118 * gimple-loop-interchange.cc (loop_cand::analyze_induction_var): Also
1119 punt if HONOR_SNANS (chrec).
1120
1121 2019-01-23 Jakub Jelinek <jakub@redhat.com>
1122
1123 PR tree-optimization/88964
1124 * gimple-loop-interchange.cc (loop_cand::analyze_induction_var): Use
1125 build_zero_cst instead of build_int_cst. Return false for loop
1126 invariants which honor signed zeros.
1127
1128 2019-01-22 Jakub Jelinek <jakub@redhat.com>
1129
1130 PR target/88965
1131 * config/rs6000/rs6000.c: Include tree-vrp.h and tree-ssanames.h.
1132 (rs6000_gimple_fold_builtin): If MEM_REF address doesn't satisfy
1133 is_gimple_mem_ref_addr predicate, force it into a SSA_NAME first.
1134
1135 PR middle-end/88968
1136 * gimplify.c (gimplify_omp_atomic): Handle bitfield atomics with
1137 non-integral DECL_BIT_FIELD_REPRESENTATIVEs.
1138
1139 PR target/88905
1140 * optabs.c (add_equal_note): Add op0_mode argument, use it instead of
1141 GET_MODE (op0).
1142 (expand_binop_directly, expand_doubleword_clz,
1143 expand_doubleword_popcount, expand_ctz, expand_ffs,
1144 expand_unop_direct, maybe_emit_unop_insn): Adjust callers.
1145
1146 PR rtl-optimization/49429
1147 PR target/49454
1148 PR rtl-optimization/86334
1149 PR target/88906
1150 * expr.c (emit_block_move_hints): Move marking of MEM_EXPRs
1151 addressable from here...
1152 (emit_block_op_via_libcall): ... to here.
1153
1154 2019-01-17 Jakub Jelinek <jakub@redhat.com>
1155
1156 PR target/88734
1157 * config/aarch64/arm_neon.h: Fix #pragma GCC target syntax - replace
1158 (("..."))) with ("..."). Use arch=armv8.2-a+sha3 instead of
1159 arch=armv8.2-a+crypto for vsha512hq_u64 etc. intrinsics.
1160
1161 PR rtl-optimization/88870
1162 * dce.c (deletable_insn_p): Never delete const/pure calls that can
1163 throw if we can't alter the cfg or delete dead exceptions.
1164 (mark_insn): Don't call find_call_stack_args for such calls.
1165
1166 2019-01-11 Jakub Jelinek <jakub@redhat.com>
1167
1168 PR bootstrap/88714
1169 * passes.c (finish_optimization_passes): Call print_combine_total_stats
1170 inside of pass_combine_1 dump rather than pass_profile_1.
1171
1172 2019-01-10 Jakub Jelinek <jakub@redhat.com>
1173
1174 PR c/88568
1175 * attribs.c (handle_dll_attribute): Clear TREE_STATIC after setting
1176 DECL_EXTERNAL.
1177
1178 2019-01-07 Jakub Jelinek <jakub@redhat.com>
1179
1180 PR debug/88723
1181 * dwarf2out.c (const_ok_for_output_1): Remove redundant call to
1182 const_not_ok_for_debug_p target hook.
1183 (mem_loc_descriptor) <case UNSPEC>: Only call const_ok_for_output_1
1184 on UNSPEC and subexpressions thereof if all subexpressions of the
1185 UNSPEC are CONSTANT_P.
1186
1187 2019-01-05 Jakub Jelinek <jakub@redhat.com>
1188
1189 PR debug/88635
1190 * dwarf2out.c (const_ok_for_output_1): Reject MINUS that contains
1191 SYMBOL_REF, CODE_LABEL or UNSPEC in subexpressions of second argument.
1192 Reject PLUS that contains SYMBOL_REF, CODE_LABEL or UNSPEC in
1193 subexpressions of both operands.
1194 (mem_loc_descriptor): Handle UNSPEC if target hook acks it and all the
1195 subrtxes are CONSTANT_P.
1196
1197 2019-02-07 Richard Biener <rguenther@suse.de>
1198
1199 Backport from mainline
1200 2018-11-20 Richard Biener <rguenther@suse.de>
1201
1202 PR tree-optimization/88105
1203 * tree-ssa-dom.c (pass_dominator::execute): Do not walk
1204 backedges.
1205
1206 2018-11-28 Richard Biener <rguenther@suse.de>
1207
1208 PR tree-optimization/88223
1209 * tree-ssa-sccvn.c (vn_reference_lookup_3): When skipping
1210 over a stored-same value may-alias store make sure to consider
1211 partial overlaps which are valid when TBAA reasonings do not
1212 apply and byte-granular overlaps are possible at all.
1213
1214 2019-02-07 Richard Biener <rguenther@suse.de>
1215
1216 Backport from mainline
1217 2018-12-11 Richard Biener <rguenther@suse.de>
1218
1219 PR middle-end/88448
1220 PR middle-end/88415
1221 * tree-complex.c (update_complex_assignment): Properly transfer
1222 or clean EH info around gimple_assign_set_rhs_with_ops.
1223
1224 2018-11-15 Richard Biener <rguenther@suse.de>
1225
1226 PR tree-optimization/88030
1227 * tree-complex.c (need_eh_cleanup): New global.
1228 (update_complex_assignment): Mark blocks that need EH update.
1229 (expand_complex_comparison): Likewise.
1230 (tree_lower_complex): Allocate and deallocate need_eh_cleanup,
1231 perform EH cleanup and schedule CFG cleanup if that did anything.
1232
1233 2018-11-08 Richard Biener <rguenther@suse.de>
1234
1235 PR tree-optimization/87929
1236 * tree-complex.c (expand_complex_comparison): Clean EH.
1237
1238 2019-02-06 Eric Botcazou <ebotcazou@adacore.com>
1239
1240 * config/i386/i386.c (ix86_expand_prologue): Emit a memory blockage
1241 after restoring registers saved to allocate the frame on Windows.
1242
1243 2019-02-06 Richard Biener <rguenther@suse.de>
1244
1245 Backport from mainline
1246 2019-01-31 Richard Biener <rguenther@suse.de>
1247
1248 PR tree-optimization/89135
1249 * tree-ssa-phiprop.c (pass_phiprop::execute): Skip blocks
1250 with abnormal preds.
1251
1252 2019-01-18 Richard Biener <rguenther@suse.de>
1253
1254 PR tree-optimization/88903
1255 * tree-vect-stmts.c (vectorizable_shift): Verify we see all
1256 scalar stmts a SLP shift amount is composed of when detecting
1257 shifts by scalars.
1258
1259 2019-02-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
1260
1261 Backport from mainline.
1262 2019-01-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
1263 * config/rs6000/rs6000-c.c (altivec-resolve_overloaded_builtin):
1264 Change handling of ALTIVEC_BUILTIN_VEC_EXTRACT. Coerce result to
1265 type of vector element when vec_extract is implemented by direct
1266 move.
1267
1268 2019-02-05 Andreas Krebbel <krebbel@linux.ibm.com>
1269
1270 Backport from mainline
1271 2019-02-05 Andreas Krebbel <krebbel@linux.ibm.com>
1272
1273 PR target/88856
1274 * config/s390/s390.md: Remove load and test FP splitter.
1275
1276 2019-02-04 Bill Schmidt <wshmidt@linux.ibm.com>
1277
1278 PR target/87064
1279 Backport from mainline
1280
1281 2019-01-30 Bill Schmidt <wschmidt@linux.ibm.com>
1282
1283 PR target/87064
1284 * config/rs6000/vsx.md (*vsx_reduc_<VEC_reduc_name>_v4sf_scalar):
1285 Disable for little-endian.
1286
1287 2019-01-22 Jakub Jelinek <jakub@redhat.com>
1288
1289 PR target/87064
1290 * config/rs6000/vsx.md (*vsx_reduc_<VEC_reduc_name>_v2df_scalar):
1291 Disable for little endian.
1292
1293 2019-02-04 Eric Botcazou <ebotcazou@adacore.com>
1294
1295 * config/sparc/sparc.h: Remove superfluous blank lines.
1296 * config/sparc/sparc.c (global_offset_table_rtx): Rename into...
1297 (got_register_rtx): ...this.
1298 (sparc_got): Adjust to above renaming.
1299 (sparc_tls_got): Likewise.
1300 (sparc_output_mi_thunk): Likewise.
1301 (sparc_init_pic_reg): Likewise.
1302 (save_local_or_in_reg_p): Fix test on the GOT register.
1303 (USE_HIDDEN_LINKONCE): Move around.
1304 (get_pc_thunk_name): Likewise.
1305 (gen_load_pcrel_sym): Likewise.
1306 (load_got_register): Likewise.
1307
1308 2019-02-01 Bin Cheng <bin.cheng@linux.alibaba.com>
1309
1310 Backport from mainline
1311 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
1312
1313 PR tree-optimization/87022
1314 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
1315 bits in dist vector rather than the first one.
1316
1317 2019-02-01 Bin Cheng <bin.cheng@linux.alibaba.com>
1318
1319 Backport from mainline
1320 2019-02-01 Bin Cheng <bin.cheng@linux.alibaba.com>
1321
1322 PR tree-optimization/88932
1323 * tree-predcom.c (try_combine_chains): Get loop bbs in dom order.
1324
1325 2018-01-31 Bill Schmidt <wschmidt@linux.ibm.com>
1326
1327 Backport from mainline
1328 2018-01-31 Bill Schmidt <wschmidt@linux.ibm.com>
1329
1330 PR tree-optimization/89008
1331 * gimple-ssa-strength-reduction.c (slsr_process_mul): Don't
1332 process anything of the form X * 0.
1333
1334 2019-01-31 Richard Biener <rguenther@suse.de>
1335
1336 Backport from mainline
1337 2019-01-31 Richard Biener <rguenther@suse.de>
1338
1339 PR rtl-optimization/89115
1340 * lra.c (lra_rtx_hash): Properly hash CONST_INT values.
1341
1342 2019-01-30 Richard Biener <rguenther@suse.de>
1343
1344 PR rtl-optimization/89115
1345 * opts.c (default_options_optimization): Reduce
1346 PARAM_MAX_DSE_ACTIVE_LOCAL_STORES by a factor of 10 at -O1.
1347 Make PARAM_LOOP_INVARIANT_MAX_BBS_IN_LOOP reduction relative
1348 to the default.
1349
1350 2019-01-30 Kewen Lin <linkw@gcc.gnu.org>
1351
1352 Backport from mainline.
1353 2019-01-17 Kewen Lin <linkw@gcc.gnu.org>
1354
1355 * doc/extend.texi: Add four new prototypes for vec_ld and seven new
1356 prototypes for vec_st.
1357 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add entries
1358 for scalar address type variants of altivec_vec_ld/altivec_vec_st,
1359 mainly on signed/unsigned long long and double.
1360
1361 2019-01-29 Vineet Gupta <vgupta@synopsys.com>
1362
1363 Backport from mainline.
1364 * gcc/config.gcc: Force .init_array for ARC.
1365
1366 2019-01-29 Vineet Gupta <vgupta@synopsys.com>
1367
1368 Backport from mainline.
1369 * config/arc/atomic.md: Add operand to DMB instruction.
1370
1371 2019-01-27 Uroš Bizjak <ubizjak@gmail.com>
1372
1373 PR target/88948
1374 * rtl.h (prepare_copy_insn): New prototype.
1375 * gcse.c (prepare_copy_insn): New function, split out from
1376 process_insert_insn.
1377 (process_insert_insn): Use prepare_copy_insn.
1378 * store-motion.c (replace_store_insn): Use prepare_copy_insn
1379 instead of gen_move_insn.
1380
1381 2019-01-25 Richard Biener <rguenther@suse.de>
1382
1383 PR tree-optimization/86865
1384 * graphite-scop-detection.c (scop_detection::can_represent_loop):
1385 Reject non-do-while loops.
1386
1387 2019-01-24 Uroš Bizjak <ubizjak@gmail.com>
1388
1389 PR target/88998
1390 * config/i386/sse.md (sse2_cvtpi2pd): Add SSE alternatives.
1391 Disparage MMX alternative.
1392 (sse2_cvtpd2pi): Ditto.
1393 (sse2_cvttpd2pi): Ditto.
1394
1395 2019-01-24 Richard Earnshaw <rearnsha@arm.com>
1396
1397 PR target/88469
1398 * profile-count.h (profile_count): On ARM systems using GCC 6/7/8
1399 force the alignment of m_val.
1400
1401 2019-01-24 Richard Biener <rguenther@suse.de>
1402
1403 Backport from mainline
1404 2019-01-23 Richard Biener <rguenther@suse.de>
1405
1406 PR tree-optimization/89008
1407 * tree-ssa-reassoc.c (eliminate_using_constants): For * 0 do
1408 not leave another stray operand.
1409
1410 2019-01-22 Uroš Bizjak <ubizjak@gmail.com>
1411
1412 PR target/88938
1413 * config/i386/i386.c (ix86_expand_builtin) [case IX86_BUILTIN_BEXTRI32,
1414 case IX86_BUILTIN_BEXTRI64]: Sanitize operands.
1415
1416 2019-01-18 Richard Earnshaw <rearnsha@arm.com>
1417
1418 PR target/88799
1419 * config/arm/arm-cpus.in (mp): New feature.
1420 (sec): New feature.
1421 (fgroup ARMv7ve): Add mp and sec features.
1422 (arch armv7-a): Add options to allow mp and sec extensions.
1423 (cpu generic-armv7-a): Add options to allow mp and sec extensions.
1424 (cpu cortex-a5, cpu cortex-7, cpu cortex-a9): Add mp and sec
1425 extenstions to the base architecture.
1426 (cpu cortex-a8): Add sec extension to the base architecture.
1427 (cpu marvell-pj4): Add mp and sec extensions to the base architecture.
1428 * config/arm/t-aprofile (MULTILIB_MATCHES): Map all armv7-a arch
1429 variants down to the base v7-a varaint.
1430 * config/arm/t-multilib (v7_a_arch_variants): New variable.
1431 * doc/invoke.texi (ARM Options): Add +mp and +sec to the list
1432 of permitted extensions for -march=armv7-a and for
1433 -mcpu=generic-armv7-a.
1434
1435 2019-01-17 Uroš Bizjak <ubizjak@gmail.com>
1436
1437 * config/alpha/alpha.c (alpha_gimplify_va_arg):
1438 Handle split indirect COMPLEX_TYPE arguments.
1439
1440 2019-01-17 Eric Botcazou <ebotcazou@adacore.com>
1441
1442 * gimple-ssa-isolate-paths.c (stmt_uses_name_in_undefined_way): Replace
1443 flag_non_call_exceptions with cfun->can_throw_non_call_exceptions.
1444 (stmt_uses_0_or_null_in_undefined_way): Likewise.
1445 * tree-ssa-alias.c (same_addr_size_stores_p): Likewise.
1446
1447 2019-01-16 Aaron Sawdey <acsawdey@linux.ibm.com>
1448
1449 Backported from mainline
1450 2019-01-03 Aaron Sawdey <acsawdey@linux.ibm.com>
1451 * config/rs6000/rs6000-string.c (expand_block_move): Don't use
1452 unaligned vsx and avoid lxvd2x/stxvd2x.
1453 (gen_lvx_v4si_move): New function.
1454
1455 2019-01-16 Martin Jambor <mjambor@suse.cz>
1456
1457 Backported from mainline
1458 2018-12-10 Martin Jambor <mjambor@suse.cz>
1459
1460 PR ipa/88214
1461 * ipa-prop.c (determine_locally_known_aggregate_parts): Make sure
1462 we check pointers against pointers.
1463
1464 2019-01-10 Jan Hubicka <hubicka@ucw.cz>
1465
1466 Backported from mainline
1467 2018-12-27 Jan Hubicka <hubicka@ucw.cz>
1468
1469 * ipa-devirt.c (polymorphic_call_target_d): Add n_odr_types.
1470 (polymorphic_call_target_hasher::hash): Hash it.
1471 (polymorphic_call_target_hasher::equal): Compare it.
1472 (possible_polymorphic_call_targets): Set it.
1473 * tree.c (free_lang_data): Rebuild type inheritance graph even on
1474 non-LTO path.
1475
1476 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1477
1478 Backported from mainline
1479 2019-01-02 Richard Biener <rguenther@suse.de>
1480
1481 PR ipa/85574
1482 * ipa-icf.h (sem_item_optimizer::sort_congruence_split): Declare.
1483 * ipa-icf.c (sem_item_optimizer::sort_congruence_split): New
1484 function.
1485 (sem_item_optimizer::do_congruence_step_f): Sort the congruence
1486 set after UIDs before splitting them.
1487
1488 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1489
1490 Backported from mainline
1491 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1492
1493 PR tree-optimization/85574
1494 * tree-ssa-uncprop.c (struct equiv_hash_elt): Remove unused
1495 structure.
1496 (struct ssa_equip_hash_traits): Declare.
1497 (val_ssa_equiv): Use custom hash traits using operand_equal_p.
1498
1499 2019-01-09 Eric Botcazou <ebotcazou@adacore.com>
1500
1501 * config/sparc/sparc.md (*tablejump_sp32): Merge into...
1502 (*tablejump_sp64): Likewise.
1503 (*tablejump<P:mode>): ...this.
1504 (*call_address_sp32): Merge into...
1505 (*call_address_sp64): Likewise.
1506 (*call_address<P:mode>): ...this.
1507 (*call_symbolic_sp32): Merge into...
1508 (*call_symbolic_sp64): Likewise.
1509 (*call_symbolic<P:mode>): ...this.
1510 (call_value): Remove constraint and add predicate.
1511 (*call_value_address_sp32): Merge into...
1512 (*call_value_address_sp64): Likewise.
1513 (*call_value_address<P:mode>): ...this.
1514 (*call_value_symbolic_sp32): Merge into...
1515 (*call_value_symbolic_sp64): Likewise.
1516 (*call_value_symbolic<P:mode>): ...this.
1517 (*sibcall_symbolic_sp32): Merge into...
1518 (*sibcall_symbolic_sp64): Likewise.
1519 (*sibcall_symbolic<P:mode>): ...this.
1520 (sibcall_value): Remove constraint and add predicate.
1521 (*sibcall_value_symbolic_sp32): Merge into...
1522 (*sibcall_value_symbolic_sp64): Likewise.
1523 (*sibcall_value_symbolic<P:mode>): ...this.
1524 (window_save): Minor tweak.
1525 (*branch_sp32): Merge into...
1526 (*branch_sp64): Likewise.
1527 (*branch<P:mode>): ...this.
1528
1529 2019-01-09 Eric Botcazou <ebotcazou@adacore.com>
1530 James Clarke <jrtc27@jrtc27.com>
1531
1532 PR target/84010
1533 * config/sparc/sparc.c (sparc_legitimize_tls_address): Only use Pmode
1534 consistently in TLS address generation and adjust code to the renaming
1535 of patterns. Mark calls to __tls_get_addr as const.
1536 * config/sparc/sparc.md (tgd_hi22): Turn into...
1537 (tgd_hi22<P:mode>): ...this and use Pmode throughout.
1538 (tgd_lo10): Turn into...
1539 (tgd_lo10<P:mode>): ...this and use Pmode throughout.
1540 (tgd_add32): Merge into...
1541 (tgd_add64): Likewise.
1542 (tgd_add<P:mode>): ...this and use Pmode throughout.
1543 (tldm_hi22): Turn into...
1544 (tldm_hi22<P:mode>): ...this and use Pmode throughout.
1545 (tldm_lo10): Turn into...
1546 (tldm_lo10<P:mode>): ...this and use Pmode throughout.
1547 (tldm_add32): Merge into...
1548 (tldm_add64): Likewise.
1549 (tldm_add<P:mode>): ...this and use Pmode throughout.
1550 (tldm_call32): Merge into...
1551 (tldm_call64): Likewise.
1552 (tldm_call<P:mode>): ...this and use Pmode throughout.
1553 (tldo_hix22): Turn into...
1554 (tldo_hix22<P:mode>): ...this and use Pmode throughout.
1555 (tldo_lox10): Turn into...
1556 (tldo_lox10<P:mode>): ...this and use Pmode throughout.
1557 (tldo_add32): Merge into...
1558 (tldo_add64): Likewise.
1559 (tldo_add<P:mode>): ...this and use Pmode throughout.
1560 (tie_hi22): Turn into...
1561 (tie_hi22<P:mode>): ...this and use Pmode throughout.
1562 (tie_lo10): Turn into...
1563 (tie_lo10<P:mode>): ...this and use Pmode throughout.
1564 (tie_ld64): Use DImode throughout.
1565 (tie_add32): Merge into...
1566 (tie_add64): Likewise.
1567 (tie_add<P:mode>): ...this and use Pmode throughout.
1568 (tle_hix22_sp32): Merge into...
1569 (tle_hix22_sp64): Likewise.
1570 (tle_hix22<P:mode>): ...this and use Pmode throughout.
1571 (tle_lox22_sp32): Merge into...
1572 (tle_lox22_sp64): Likewise.
1573 (tle_lox22<P:mode>): ...this and use Pmode throughout.
1574 (*tldo_ldub_sp32): Merge into...
1575 (*tldo_ldub_sp64): Likewise.
1576 (*tldo_ldub<P:mode>): ...this and use Pmode throughout.
1577 (*tldo_ldub1_sp32): Merge into...
1578 (*tldo_ldub1_sp64): Likewise.
1579 (*tldo_ldub1<P:mode>): ...this and use Pmode throughout.
1580 (*tldo_ldub2_sp32): Merge into...
1581 (*tldo_ldub2_sp64): Likewise.
1582 (*tldo_ldub2<P:mode>): ...this and use Pmode throughout.
1583 (*tldo_ldsb1_sp32): Merge into...
1584 (*tldo_ldsb1_sp64): Likewise.
1585 (*tldo_ldsb1<P:mode>): ...this and use Pmode throughout.
1586 (*tldo_ldsb2_sp32): Merge into...
1587 (*tldo_ldsb2_sp64): Likewise.
1588 (*tldo_ldsb2<P:mode>): ...this and use Pmode throughout.
1589 (*tldo_ldub3_sp64): Use DImode throughout.
1590 (*tldo_ldsb3_sp64): Likewise.
1591 (*tldo_lduh_sp32): Merge into...
1592 (*tldo_lduh_sp64): Likewise.
1593 (*tldo_lduh<P:mode>): ...this and use Pmode throughout.
1594 (*tldo_lduh1_sp32): Merge into...
1595 (*tldo_lduh1_sp64): Likewise.
1596 (*tldo_lduh1<P:mode>): ...this and use Pmode throughout.
1597 (*tldo_ldsh1_sp32): Merge into...
1598 (*tldo_ldsh1_sp64): Likewise.
1599 (*tldo_ldsh1<P:mode>): ...this and use Pmode throughout.
1600 (*tldo_lduh2_sp64): Use DImode throughout.
1601 (*tldo_ldsh2_sp64): Likewise.
1602 (*tldo_lduw_sp32): Merge into...
1603 (*tldo_lduw_sp64): Likewise.
1604 (*tldo_lduw<P:mode>): ...this and use Pmode throughout.
1605 (*tldo_lduw1_sp64): Use DImode throughout.
1606 (*tldo_ldsw1_sp64): Likewise.
1607 (*tldo_ldx_sp64): Likewise.
1608 (*tldo_stb_sp32): Merge into...
1609 (*tldo_stb_sp64): Likewise.
1610 (*tldo_stb<P:mode>): ...this and use Pmode throughout.
1611 (*tldo_sth_sp32): Merge into...
1612 (*tldo_sth_sp64): Likewise.
1613 (*tldo_sth<P:mode>): ...this and use Pmode throughout.
1614 (*tldo_stw_sp32): Merge into...
1615 (*tldo_stw_sp64): Likewise.
1616 (*tldo_stw<P:mode>): ...this and use Pmode throughout.
1617 (*tldo_stx_sp64): Use DImode throughout.
1618
1619 2019-01-09 Eric Botcazou <ebotcazou@adacore.com>
1620
1621 * doc/invoke.texi (-Os): Add reference to -finline-functions.
1622 (-finline-functions): Remove reference to -O2, add references
1623 to -fprofile-use and -fauto-profile.
1624
1625 2019-01-08 Jakub Jelinek <jakub@redhat.com>
1626
1627 Backported from mainline
1628 2019-01-05 Jakub Jelinek <jakub@redhat.com>
1629
1630 PR middle-end/82564
1631 PR target/88620
1632 * expr.c (expand_assignment): For calls returning VLA structures
1633 if to_rtx is not a MEM, force it into a stack temporary.
1634
1635 2019-01-04 Jakub Jelinek <jakub@redhat.com>
1636
1637 PR target/88594
1638 * config/i386/i386.c (ix86_expand_divmod_libfunc): Use mode instead
1639 of GET_MODE (opN) as modes of the libcall arguments.
1640
1641 2019-01-03 Jakub Jelinek <jakub@redhat.com>
1642
1643 PR debug/88644
1644 * dwarf2out.c (modified_type_die): If type is equal to sizetype,
1645 change it to qualified_type.
1646
1647 2018-12-21 Jakub Jelinek <jakub@redhat.com>
1648
1649 PR middle-end/85594
1650 PR middle-end/88553
1651 * omp-expand.c (extract_omp_for_update_vars): Regimplify the condition
1652 if needed.
1653 (expand_omp_for_generic): Don't clobber t temporary for ordered loops.
1654
1655 PR target/88522
1656 * config/i386/sse.md (*avx512pf_gatherpf<mode>sf_mask,
1657 *avx512pf_gatherpf<mode>df_mask, *avx512pf_scatterpf<mode>sf_mask,
1658 *avx512pf_scatterpf<mode>df_mask): Use %X5 instead of %5 for
1659 -masm=intel.
1660 (gatherq_mode): Remove mode iterator.
1661 (*avx512f_gathersi<mode>, *avx512f_gathersi<mode>_2): Use X instead
1662 of <xtg_mode>.
1663 (*avx512f_gatherdi<mode>): Use X instead of <gatherq_mode>.
1664 (*avx512f_gatherdi<mode>_2, *avx512f_scattersi<mode>,
1665 *avx512f_scatterdi<mode>): Use %X5 for -masm=intel.
1666
1667 PR rtl-optimization/88563
1668 * expr.c (expand_expr_real_2) <case WIDEN_MULT_EXPR>: Swap innermode
1669 and mode arguments to convert_modes. Likewise swap mode and word_mode
1670 arguments. Handle both arguments with VOIDmode before convert_modes
1671 of one of them. Formatting fixes.
1672
1673 2018-12-19 Jakub Jelinek <jakub@redhat.com>
1674
1675 PR target/88541
1676 * config/i386/vpclmulqdqintrin.h (_mm256_clmulepi64_epi128): Enable
1677 for -mavx -mvpclmulqdq rather than just for -mavx512vl -mvpclmulqdq.
1678
1679 2018-12-14 Jakub Jelinek <jakub@redhat.com>
1680
1681 PR c++/82294
1682 PR c++/87436
1683 * expr.h (categorize_ctor_elements): Add p_unique_nz_elts argument.
1684 * expr.c (categorize_ctor_elements_1): Likewise. Compute it like
1685 p_nz_elts, except don't multiply it by mult. Adjust recursive call.
1686 Fix up COMPLEX_CST handling.
1687 (categorize_ctor_elements): Add p_unique_nz_elts argument, initialize
1688 it and pass it through to categorize_ctor_elements_1.
1689 (mostly_zeros_p, all_zeros_p): Adjust categorize_ctor_elements callers.
1690 * gimplify.c (gimplify_init_constructor): Likewise. Don't force
1691 ctor into readonly data section if num_unique_nonzero_elements is
1692 smaller or equal to 1/8 of num_nonzero_elements and size is >= 64
1693 bytes.
1694
1695 2018-12-13 Jakub Jelinek <jakub@redhat.com>
1696
1697 PR rtl-optimization/88470
1698 * cfgcleanup.c (outgoing_edges_match): If the function is
1699 shrink-wrapped and bb1 ends with a JUMP_INSN with a single fake
1700 edge to EXIT, return false.
1701
1702 PR rtl-optimization/88416
1703 * valtrack.c (cleanup_auto_inc_dec): Handle pre/post-inc/dec/modify
1704 even if !AUTO_INC_DEC.
1705
1706 2018-12-07 Jakub Jelinek <jakub@redhat.com>
1707
1708 PR target/85593
1709 * final.c (rest_of_handle_final): Don't call collect_fn_hard_reg_usage
1710 for functions with naked attribute.
1711
1712 2018-12-06 Jakub Jelinek <jakub@redhat.com>
1713
1714 PR target/87598
1715 * config/aarch64/aarch64.c (aarch64_print_address_internal): Don't
1716 call output_operand_lossage on VOIDmode CONST_INTs. After
1717 output_operand_lossage do return false.
1718
1719 2018-12-05 Jakub Jelinek <jakub@redhat.com>
1720
1721 PR tree-optimization/87360
1722 * gimple-loop-jam.c (tree_loop_unroll_and_jam): On failure to analyze
1723 data dependencies, don't return false, just continue.
1724
1725 2018-11-29 Jakub Jelinek <jakub@redhat.com>
1726
1727 PR target/88234
1728 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): For
1729 vec_add and vec_sub builtins, perform PLUS_EXPR or MINUS_EXPR
1730 in unsigned_type_for instead of vector integral type where overflow
1731 doesn't wrap.
1732
1733 2018-11-26 Jakub Jelinek <jakub@redhat.com>
1734
1735 PR c++/86900
1736 * dwarf2out.c (secname_for_decl): For functions with
1737 DECL_SECTION_NAME if in_cold_section_p, try to return
1738 current_function_section's name if it is a named section.
1739
1740 2018-11-22 Jakub Jelinek <jakub@redhat.com>
1741
1742 PR target/85644
1743 PR target/86832
1744 * config/i386/i386.c (ix86_option_override_internal): Default
1745 ix86_stack_protector_guard to SSP_TLS only if TARGET_THREAD_SSP_OFFSET
1746 is defined.
1747 * config/i386/i386.md (stack_protect_set, stack_protect_set_<mode>,
1748 stack_protect_test, stack_protect_test_<mode>): Use empty condition
1749 instead of TARGET_SSP_TLS_GUARD.
1750
1751 2018-11-20 Jakub Jelinek <jakub@redhat.com>
1752
1753 PR tree-optimization/87895
1754 * omp-simd-clone.c (ipa_simd_modify_function_body): When removing
1755 or replacing GIMPLE_RETURN, set EDGE_FALLTHRU on the edge to EXIT.
1756 (simd_clone_adjust): Don't set EDGE_FALLTHRU here. In a loop that
1757 redirects edges to EXIT to edges to incr_bb, iterate while EXIT
1758 has any preds and always use EDGE_PRED (, 0).
1759
1760 2018-11-19 Jakub Jelinek <jakub@redhat.com>
1761
1762 PR tree-optimization/88071
1763 * tree-vect-loop.c (vectorize_fold_left_reduction): Pass true instead
1764 of false as last argument to gsi_remove.
1765 * tree-vect-stmts.c (vect_finish_replace_stmt): Pass true instead of
1766 false as last argument to gsi_replace.
1767
1768 PR debug/87039
1769 * omp-expand.c: Don't include debug.h.
1770 (adjust_context_and_scope): Add REGION argument. Find DECL_CONTEXT
1771 from innermost outer parallel, task, or target that has a
1772 child_fn set, or, if there is no such outer region, use
1773 current_function_decl. Do the DECL_CONTEXT adjustment regardless of
1774 whether a suitable BLOCK is found or not.
1775 (expand_parallel_call): Don't call adjust_context_and_scope here.
1776 (grid_expand_target_grid_body): Revert 2017-01-25 changes.
1777 (expand_omp_taskreg, expand_omp_target): Likewise. Call
1778 adjust_context_and_scope.
1779 * dwarf2out.c (dwarf2out_early_global_decl): For
1780 decl_function_context recurse instead of calling dwarf2out_decl.
1781
1782 2018-11-16 Jakub Jelinek <jakub@redhat.com>
1783
1784 PR rtl-optimization/87475
1785 * cfgrtl.c (patch_jump_insn): Allow redirection failure for
1786 CROSSING_JUMP_P insns.
1787 (cfg_layout_redirect_edge_and_branch): Don't ICE if ret is NULL.
1788
1789 2018-11-15 Jakub Jelinek <jakub@redhat.com>
1790
1791 PR rtl-optimization/88018
1792 * cfgrtl.c (fixup_abnormal_edges): Guard moving insns to fallthru edge
1793 on the presence of fallthru edge, rather than if it is a USE or not.
1794
1795 2018-11-13 Jakub Jelinek <jakub@redhat.com>
1796
1797 PR tree-optimization/87898
1798 * omp-simd-clone.c (ipa_simd_modify_function_body): Remove debug stmts
1799 where the first argument was changed into a non-decl.
1800
1801 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1802
1803 Backport from mainline
1804 2019-01-02 Jan Hubicka <hubicka@ucw.cz>
1805
1806 PR lto/88130
1807 * varpool.c (varpool_node::ctor_useable_for_folding_p): Also return
1808 false at WPA time when body was removed.
1809
1810 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1811
1812 Backport from mainline
1813 2018-08-29 Jan Hubicka <jh@suse.cz>
1814
1815 PR lto/86517
1816 PR lto/88185
1817 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
1818 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
1819
1820 2019-01-04 Aaron Sawdey <acsawdey@linux.ibm.com>
1821
1822 Backport from mainline
1823 2018-11-28 Aaron Sawdey <acsawdey@linux.ibm.com>
1824
1825 * config/rs6000/rs6000-string.c (expand_block_clear): Change how
1826 we determine if unaligned vsx is ok.
1827
1828 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1829
1830 Backport from mainline
1831 2019-01-03 Jan Hubicka <hubicka@ucw.cz>
1832
1833 * ipa-utils.c (scale_ipa_profile_for_fn): Break out from ...
1834 (ipa_merge_profiles): ... here; do not ICE on thunks and aliases.
1835
1836 2019-01-03 Martin Liska <mliska@suse.cz>
1837
1838 Backport from mainline
1839 2019-01-01 Jan Hubicka <hubicka@ucw.cz>
1840
1841 * coverage.c (get_coverage_counts): Use current_function_decl.
1842 * profile.c (read_thunk_profile): New function.
1843 (branch_prob): Add THUNK parameter.
1844 * tree-profile.c (tree_profiling): Handle thunks.
1845 * value-prof.c (init_node_map): Handle thunks.
1846 * value-prof.h (branch_prob): Upate prototype.
1847 (read_thunk_profile): Declare.
1848
1849 2019-01-03 Iain Sandoe <iain@sandoe.co.uk>
1850
1851 revert:
1852 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
1853
1854 backport from mainline.
1855 2018-12-12 Segher Boessenkool <segher@kernel.crashing.org>
1856 Iain Sandoe <iain@sandoe.co.uk>
1857
1858 PR target/88343
1859 * config/rs6000/rs6000.c (save_reg_p): Do not save the picbase reg
1860 unless it has been used.
1861 (first_reg_to_save): Remove dead code.
1862
1863 2019-01-02 Segher Boessenkool <segher@kernel.crashing.org>
1864
1865 Backport from trunk
1866 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
1867
1868 PR inline-asm/55681
1869 * doc/extend.texi (Basic Asm): Update grammar.
1870 (Extended Asm): Update grammar.
1871
1872 Backport from trunk
1873 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
1874
1875 * doc/extend.texi (Using Assembly Language with C): Document asm inline.
1876 (Size of an asm): Fix typo. Document asm inline.
1877 * gimple-pretty-print.c (dump_gimple_asm): Handle asm inline.
1878 * gimple.h (enum gf_mask): Add GF_ASM_INLINE.
1879 (gimple_asm_set_volatile): Fix typo.
1880 (gimple_asm_inline_p): New.
1881 (gimple_asm_set_inline): New.
1882 * gimplify.c (gimplify_asm_expr): Propagate the asm inline flag from
1883 tree to gimple.
1884 * ipa-icf-gimple.c (func_checker::compare_gimple_asm): Compare the
1885 gimple_asm_inline_p flag, too.
1886 * tree-core.h (tree_base): Document that protected_flag is ASM_INLINE_P
1887 in an ASM_EXPR.
1888 * tree-inline.c (estimate_num_insns): If gimple_asm_inline_p return
1889 a minimum size for an asm.
1890 * tree.h (ASM_INLINE_P): New.
1891
1892 2018-12-28 Thomas Schwinge <thomas@codesourcery.com>
1893 Julian Brown <julian@codesourcery.com>
1894
1895 * gimplify.c (gimplify_scan_omp_clauses): Fix known_eq typo/bug.
1896
1897 2018-12-27 Martin Liska <mliska@suse.cz>
1898
1899 Backport from mainline
1900 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
1901
1902 PR ipa/88561
1903 * ipa-polymorphic-call.c
1904 (ipa_polymorphic_call_context::ipa_polymorphic_call_context): Handle
1905 arguments of thunks correctly.
1906 (ipa_polymorphic_call_context::get_dynamic_context): Be ready for
1907 NULL instance pinter.
1908 * lto-cgraph.c (lto_output_node): Always stream thunk info.
1909
1910 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
1911
1912 backport from mainline.
1913 2018-12-12 Segher Boessenkool <segher@kernel.crashing.org>
1914 Iain Sandoe <iain@sandoe.co.uk>
1915
1916 PR target/88343
1917 * config/rs6000/rs6000.c (save_reg_p): Do not save the picbase reg
1918 unless it has been used.
1919 (first_reg_to_save): Remove dead code.
1920
1921 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
1922
1923 Backport from mainline
1924 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
1925
1926 PR c++/87380
1927 * config/darwin.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC) Remove, use the
1928 default.
1929 * config/rs6000/darwin7.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC): New.
1930
1931 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
1932
1933 Backport from mainline
1934 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
1935
1936 PR target/78444
1937 * config/i386/darwin.h (STACK_BOUNDARY): Remove macro.
1938 * config/i386/i386.c (ix86_compute_frame_layout): Ensure at least 128b
1939 stack alignment in non-leaf functions.
1940
1941 2018-12-21 Uros Bizjak <ubizjak@gmail.com>
1942
1943 Backport from mainline
1944 2018-12-10 Uros Bizjak <ubizjak@gmail.com>
1945
1946 PR target/88418
1947 * config/i386/i386.c (ix86_expand_sse_cmp): For vector modes,
1948 check operand 1 with vector_operand predicate.
1949 (ix86_expand_sse_movcc): For vector modes, check op_true with
1950 vector_operand, not nonimmediate_operand.
1951
1952 2018-12-19 Bill Schmidt <wschmidt@linux.ibm.com>
1953
1954 Backport from mainline
1955 2018-12-18 Bill Schmidt <wschmidt@linux.ibm.com>
1956
1957 * doc/extend.texi (PowerPC Altivec/VSX Built-in Functions):
1958 Describe when a typedef name can be used as the type specifier for
1959 a vector type, and when it cannot.
1960
1961 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
1962
1963 Backport from trunk
1964 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
1965
1966 PR target/88213
1967 * config/rs6000/vsx.md (*vsx_extract_<P:mode>_<VSX_D:mode>_load):
1968 Require TARGET_POWERPC64.
1969
1970 2018-12-17 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
1971
1972 Backport from trunk
1973 2018-12-17 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
1974
1975 PR rtl-optimization/88253
1976 * combine.c (combine_simplify_rtx): Test for side-effects before
1977 substituting by zero.
1978
1979 2018-12-15 Segher Boessenkool <segher@kernel.crashing.org>
1980
1981 Backport from trunk
1982 2018-12-14 Segher Boessenkool <segher@kernel.crashing.org>
1983
1984 PR rtl-optimization/88001
1985 * function.c (match_asm_constraints_1): Don't invalidly share RTL.
1986
1987 2018-12-15 Jan Hubicka <jh@suse.cz>
1988
1989 * ipa.c (cgraph_build_static_cdtor_1): Add OPTIMIZATION and TARGET
1990 parameters.
1991 (cgraph_build_static_cdtor): Update.
1992 (build_cdtor): Use OPTIMIZATION and TARGET of the first real cdtor
1993 callsed.
1994
1995 2018-12-15 Jan Hubicka <jh@suse.cz>
1996
1997 Backport from mainline
1998 2018-11-02 Richard Biener <rguenther@suse.de>
1999
2000 * dwarf2out.c (build_abbrev_table): Guard lookup_external_ref call
2001 with is_type_die.
2002
2003 2018-12-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2004
2005 Backport from mainline
2006 2018-12-13 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2007
2008 * doc/invoke.texi (-msve-vector-bits): Clarify -msve-vector-bits=128
2009 behavior.
2010
2011 2018-12-14 Andre Vieira <andre.simoesdiasvieira@arm.com>
2012
2013 Backport from mainline
2014 PR target/88224
2015 * config/arm/arm-cpus.in (armv7-r): Add FP16conv configurations.
2016 (cortex-r7, cortex-r8): Update fpu and add new configuration.
2017 * doc/invoke.texi (armv7-r): Add two new vfp options.
2018 (nofp.dp): Add cortex-r7 and cortex-r8 to the list of targets that
2019 support this option.
2020
2021 2018-12-13 H.J. Lu <hongjiu.lu@intel.com>
2022
2023 Backport from mainline
2024 2018-11-05 Xuepeng Guo <xuepeng.guo@intel.com>
2025
2026 PR target/87853
2027 * config/i386/emmintrin.h (__v16qs): New to cope with option
2028 -funsigned-char.
2029 (_mm_cmpeq_epi8): Replace __v16qi with __v16qs.
2030 (_mm_cmplt_epi8): Likewise.
2031 (_mm_cmpgt_epi8): Likewise.
2032
2033 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
2034
2035 Backport from mainline
2036 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
2037
2038 * config/s390/s390-builtins.def (s390_vec_double_s64): Map to
2039 s390_vec_double_s64 instead of s390_vcdgb.
2040 (s390_vec_double_u64): Map to s390_vec_double_u64 instead of
2041 s390_vcdlgb.
2042
2043 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
2044
2045 Backport from mainline
2046 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
2047
2048 * config/s390/vx-builtins.md ("vec_ctd_s64", "vec_ctd_u64")
2049 ("vec_ctsl", "vec_ctul"): Replace 0 with VEC_NOINEXACT.
2050 ("vec_double_s64", "vec_double_u64"): Replace 4 with VEC_INEXACT.
2051
2052 2018-12-13 Eric Botcazou <ebotcazou@adacore.com>
2053
2054 Backport from mainline
2055 2018-12-11 Eric Botcazou <ebotcazou@adacore.com>
2056
2057 * config/rs6000/vxworks.h (RS6000_STARTING_FRAME_OFFSET): Define,
2058 accounting for STACK_BOUNDARY 128.
2059 (STACK_DYNAMIC_OFFSET): Likewise.
2060
2061 2018-12-12 Peter Bergner <bergner@linux.ibm.com>
2062
2063 Backport from mainline
2064 2018-12-07 Peter Bergner <bergner@linux.ibm.com>
2065
2066 PR target/87496
2067 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
2068 -mabi=ieeelongdouble and -mabi=ibmlongdouble without -mlong-double-128.
2069 Do not error for -mabi=ibmlongdouble and no ISA 2.06 support.
2070 * doc/invoke.texi: Document -mabi=ibmlongdouble and -mabi=ieeelongdouble
2071 require -mlong-double-128.
2072
2073 2018-12-05 Richard Biener <rguenther@suse.de>
2074
2075 Backport from mainline
2076 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
2077
2078 PR tree-optimization/87288
2079 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
2080 into account when determining PEELING_FOR_NITERS.
2081
2082 2018-12-05 Iain Sandoe <iain@sandoe.co.uk>
2083
2084 Backport from mainline
2085 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
2086
2087 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
2088 emit a diagnostic that it is not supported and reset the option.
2089 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
2090 supported and consume the option. (ASM_FINAL_SPEC): New.
2091
2092 2018-12-04 Iain Sandoe <iain@sandoe.co.uk>
2093
2094 Backport from mainline
2095 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
2096
2097 PR target/81685
2098 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
2099 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
2100 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
2101
2102 2018-11-29 Peter Bergner <bergner@linux.ibm.com>
2103
2104 Backport from mainline
2105 2018-11-29 Peter Bergner <bergner@linux.ibm.com>
2106
2107 PR target/87496
2108 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
2109 -mabi=ieeelongdouble without both -mpopcntd and -mvsx.
2110
2111 2018-11-28 Aaron Sawdey <acsawdey@linux.ibm.com>
2112
2113 Backport from mainline
2114 2018-10-25 Aaron Sawdey <acsawdey@linux.ibm.com>
2115
2116 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Change to
2117 a shorter sequence with fewer branches.
2118 (emit_final_str_compare_gpr): Ditto.
2119
2120 Backport from mainline to allow the above code to go in:
2121 2018-06-14 Aaron Sawdey <acsawdey@linux.ibm.com>
2122
2123 * config/rs6000/rs6000-string.c (do_and3, do_and3_mask,
2124 do_cmpb3, do_rotl3): New functions.
2125
2126 2018-11-28 Richard Biener <rguenther@suse.de>
2127
2128 PR tree-optimization/79351
2129 * tree-ssa-sccvn.c (vn_reference_lookup_3): For assignments from
2130 empty CONSTRUCTORs ensure the store is at a constant position.
2131
2132 2018-11-28 Richard Biener <rguenther@suse.de>
2133
2134 PR tree-optimization/88229
2135 * tree-ssa.c (non_rewritable_mem_ref_base): Check DECL_SIZE_UNIT
2136 is an INTEGER_CST before accessing it so.
2137
2138 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2139
2140 Backport from mainline
2141 2018-11-20 Andreas Krebbel <krebbel@linux.ibm.com>
2142
2143 * config/s390/s390.md ("clztidi2"): Swap the RTX's written to the
2144 DImode parts of the target operand.
2145
2146 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2147
2148 Backport from mainline
2149 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2150
2151 * doc/invoke.texi: Document z14/arch12 -march option.
2152
2153 2018-11-23 Tamar Christina <tamar.christina@arm.com>
2154
2155 Backported from mainline.
2156 2018-08-16 Tamar Christina <tamar.christina@arm.com>
2157
2158 PR target/84711
2159 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
2160 (mov<mov>): ..this and enable unconditionally.
2161
2162 2018-11-22 Uros Bizjak <ubizjak@gmail.com>
2163
2164 Backport from mainline
2165 2018-11-16 Uros Bizjak <ubizjak@gmail.com>
2166
2167 PR target/88051
2168 * config/i386/sse.md (UNSPEC_MOVDI_TO_SSE): New UNSPEC.
2169 (movdi_to_sse): Rewrite using UNSPEC_MOVDI_TO_SSE unspec.
2170
2171 2018-11-20 Eric Botcazou <ebotcazou@adacore.com>
2172
2173 PR rtl-optimization/85925
2174 * rtl.h (word_register_operation_p): New predicate.
2175 * combine.c (record_dead_and_set_regs_1): Only apply specific handling
2176 for WORD_REGISTER_OPERATIONS targets to word_register_operation_p RTX.
2177 * rtlanal.c (nonzero_bits1): Likewise. Adjust couple of comments.
2178 (num_sign_bit_copies1): Likewise.
2179
2180 2018-11-19 Martin Liska <mliska@suse.cz>
2181
2182 PR gcov-profile/88045
2183 * coverage.c (coverage_begin_function): One can't relly on the
2184 fact that function ends on the same line it starts or later.
2185
2186 2018-11-18 Uros Bizjak <ubizjak@gmail.com>
2187
2188 Backport from mainline
2189 2018-11-11 Uros Bizjak <ubizjak@gmail.com>
2190
2191 PR target/87928
2192 * config/i386/i386.h (STACK_BOUNDARY): Use TARGET_64BIT_MS_ABI
2193 instead of (TARGET_64BIT && ix86_abi == MS_ABI).
2194 * config/i386/darwin.h (STACK_BOUNDARY): Ditto.
2195 * config/i386/cygming.h (STACK_BOUNDARY): Remove.
2196
2197 2018-11-16 Eric Botcazou <ebotcazou@adacore.com>
2198
2199 * tree-switch-conversion.c (emit_case_decision_tree): Pass location
2200 of switch statement to emit_case_nodes.
2201 (do_jump_if_equal): Add LOC parameter and set it on the newly built
2202 GIMPLE comparison statement.
2203 (emit_cmp_and_jump_insns): Likewise.
2204 (emit_case_nodes): Add LOC parameter and pass it to do_jump_if_equal
2205 as well as recursive calls.
2206
2207 2018-11-15 Nathan Sidwell <nathan@acm.org>
2208
2209 PR debug/88006
2210 PR debug/87462
2211 * dwarf2out.c (dwarf2out_finish): Apply resolve_addr to comdat
2212 type list.
2213
2214 2018-11-14 Paul A. Clarke <pc@us.ibm.com>
2215
2216 Backport from mainline
2217 * config/rs6000/xmmintrin.h (_mm_extract_pi16): Fix for big-endian.
2218
2219 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2220
2221 Backport from mainline
2222 PR target/85968
2223 * config/arc/arc.c (arc_return_address_register): Fix
2224 if-condition.
2225
2226 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2227
2228 Backport from mainline
2229 * config/arc/arc.h (FUNCTION_PROFILER): Redefine to empty.
2230 * config/arc/elf.h (PROFILE_HOOK): Define.
2231 * config/arc/linux.h (PROFILE_HOOK): Likewise.
2232
2233 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2234
2235 Backport from mainline
2236 * config/arc/arc.c (hwloop_optimize): Bailout when detecting a
2237 jump table data in the text section.
2238
2239 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2240
2241 Backport from mainline
2242 * config/arc/arc.c (arc_eh_return_address_location): Repurpose it
2243 to fit the eh_return pattern.
2244 * config/arc/arc.md (eh_return): Define.
2245 (VUNSPEC_ARC_EH_RETURN): Likewise.
2246 * config/arc/arc-protos.h (arc_eh_return_address_location): Match
2247 new implementation.
2248 * config/arc/arc.h (EH_RETURN_HANDLER_RTX): Remove it.
2249
2250 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2251
2252 Backport from mainline
2253 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
2254
2255 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
2256
2257 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
2258
2259 Backport from mainline
2260 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
2261
2262 2018-11-11 Uros Bizjak <ubizjak@gmail.com>
2263
2264 Backport from mainline
2265 2018-11-04 Uros Bizjak <ubizjak@gmail.com>
2266
2267 PR middle-end/58372
2268 * cfgexpand.c (pass_expand::execute): Move the call to
2269 finish_eh_generation in front of the call to expand_stack_alignment.
2270
2271 2018-11-07 Max Filippov <jcmvbkbc@gmail.com>
2272
2273 Backport from mainline
2274 2018-11-05 Max Filippov <jcmvbkbc@gmail.com>
2275
2276 * config/xtensa/uclinux.h (XTENSA_ALWAYS_PIC): Change to 0.
2277
2278 2018-11-05 Jakub Jelinek <jakub@redhat.com>
2279
2280 PR tree-optimization/87859
2281 * gimple-ssa-store-merging.c (struct merged_store_group): Add
2282 first_nonmergeable_order member.
2283 (merged_store_group::merged_store_group): Initialize them.
2284 (imm_store_chain_info::coalesce_immediate_stores): Don't merge
2285 stores with order >= first_nonmergeable_order.
2286 Set merged_store->first_nonmergeable_order if we've skipped any
2287 stores. Attempt to merge overlapping INTEGER_CST stores that
2288 we would otherwise skip.
2289
2290 PR sanitizer/87837
2291 * match.pd (X + Y < X): Don't optimize if TYPE_OVERFLOW_SANITIZED.
2292
2293 Backported from mainline
2294 2018-10-20 Jakub Jelinek <jakub@redhat.com>
2295
2296 PR middle-end/87647
2297 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
2298
2299 2018-10-19 Jakub Jelinek <jakub@redhat.com>
2300
2301 PR middle-end/85488
2302 PR middle-end/87649
2303 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
2304 depend closely nested inside of loop with ordered clause with
2305 a parameter.
2306
2307 2018-10-29 Richard Biener <rguenther@suse.de>
2308
2309 Backport from mainline
2310 2018-09-26 Richard Biener <rguenther@suse.de>
2311
2312 PR debug/87428
2313 PR debug/87362
2314 * tree-inline.c (expand_call_inline): When the location
2315 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
2316 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
2317 the inserted BLOCK to make inlined_function_outer_scope_p
2318 recognize it.
2319 * dwarf2out.c (add_call_src_coords_attributes): Do not add
2320 coords for reserved locations.
2321
2322 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
2323
2324 Backport from mainline
2325 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
2326
2327 PR bootstrap/81033
2328 PR target/81733
2329 PR target/52795
2330 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
2331 (dwarf2out_switch_text_section): Generate a local label for the second
2332 function sub-section and apply it as the second FDE start label.
2333 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
2334 second sub-section start.
2335
2336 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
2337
2338 Backport from mainline
2339 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
2340
2341 * config/darwin.c
2342 (darwin_function_switched_text_sections): Delete.
2343 * gcc/config/darwin.h
2344 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
2345
2346 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
2347
2348 backport from mainline.
2349 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
2350
2351 PR target/85669
2352 * config/rs6000/darwin.h (STACK_BOUNDARY): New.
2353 (RS6000_STARTING_FRAME_OFFSET): Adjust to preserve 16byte alignment.
2354 (STACK_DYNAMIC_OFFSET): Likewise.
2355
2356 2018-10-26 Bill Schmidt <wschmidt@linux.ibm.com>
2357
2358 Backport from mainline
2359 2018-10-19 Bill Schmidt <wschmidt@linux.ibm.com>
2360
2361 PR tree-optimization/87473
2362 * gimple-ssa-strength-reduction.c (record_phi_increments_1): For
2363 phi arguments identical to the base expression of the phi
2364 candidate, record a phi-adjust increment of zero minus the index
2365 expression of the hidden basis.
2366 (phi_incr_cost_1): For phi arguments identical to the base
2367 expression of the phi candidate, the difference to compare against
2368 the increment is zero minus the index expression of the hidden
2369 basis, and there is no potential savings from replacing the (phi)
2370 statement.
2371 (ncd_with_phi): For phi arguments identical to the base expression
2372 of the phi candidate, the difference to compare against the
2373 increment is zero minus the index expression of the hidden basis.
2374 (all_phi_incrs_profitable_1): For phi arguments identical to the
2375 base expression of the phi candidate, the increment to be checked
2376 for profitability is zero minus the index expression of the hidden
2377 basis.
2378
2379 2018-10-25 Richard Biener <rguenther@suse.de>
2380
2381 PR tree-optimization/87665
2382 PR tree-optimization/87745
2383 * tree-vectorizer.h (get_earlier_stmt): Remove.
2384 (get_later_stmt): Pick up UID from the original non-pattern stmt.
2385
2386 2018-10-24 Richard Biener <rguenther@suse.de>
2387
2388 PR tree-optimization/87665
2389 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
2390 to reflect reality.
2391
2392 2018-10-23 Richard Biener <rguenther@suse.de>
2393
2394 PR tree-optimization/87700
2395 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
2396
2397 2018-10-19 Richard Biener <rguenther@suse.de>
2398
2399 PR middle-end/87645
2400 Backport from mainline
2401 2018-07-12 Richard Biener <rguenther@suse.de>
2402
2403 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
2404 (vn_lookup_simplify_result): Remove recursion limit applied
2405 here.
2406 (vn_nary_build_or_lookup_1): Adjust.
2407 (try_to_simplify): Likewise.
2408 * gimple-match-head.c (gimple_resimplify1): Instead apply one
2409 here.
2410 (gimple_resimplify2): Likewise.
2411 (gimple_resimplify3): Likewise.
2412 (gimple_resimplify4): Likewise.
2413
2414 2018-10-19 Andreas Krebbel <krebbel@linux.ibm.com>
2415
2416 Backport from mainline
2417 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
2418
2419 * config/s390/s390.c (s390_expand_vec_init): Force vector element
2420 into reg if it isn't a general operand.
2421
2422 2018-10-18 Richard Biener <rguenther@suse.de>
2423
2424 PR middle-end/87087
2425 Revert
2426 2018-02-07 Richard Biener <rguenther@suse.de>
2427
2428 PR tree-optimization/84204
2429 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
2430 this place.
2431
2432 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
2433
2434 PR middle-end/87623
2435 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
2436 bail out if both sides do not have the same storage order.
2437
2438 2018-10-17 Richard Biener <rguenther@suse.de>
2439
2440 Backport from mainline
2441 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
2442
2443 PR middle-end/63155
2444 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
2445 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
2446
2447 2018-10-16 Richard Biener <rguenther@suse.de>
2448
2449 Backport from mainline
2450 2018-10-08 Richard Biener <rguenther@suse.de>
2451
2452 PR tree-optimization/63155
2453 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
2454 (ssa_propagation_engine::ssa_propagate): Remove redundant
2455 bitmap bit clearing.
2456
2457 2018-10-05 Richard Biener <rguenther@suse.de>
2458
2459 PR tree-optimization/63155
2460 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
2461 vertical space in dumpfiles.
2462 * tree-ssa-propagate.h
2463 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
2464 * tree-ssa-propagate.c (cfg_blocks_back): New global.
2465 (ssa_edge_worklist_back): Likewise.
2466 (curr_order): Likewise.
2467 (cfg_blocks_get): Remove abstraction.
2468 (cfg_blocks_add): Likewise.
2469 (cfg_blocks_empty_p): Likewise.
2470 (add_ssa_edge): Add to current or next worklist based on
2471 RPO index.
2472 (add_control_edge): Likewise.
2473 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
2474 into ...
2475 (ssa_propagation_engine::ssa_propagate): ... here. Unify
2476 iteration from CFG and SSA edge worklist so we process
2477 everything in RPO order, prioritizing forward progress
2478 over iteration.
2479 (ssa_prop_init): Allocate new worklists, do not dump
2480 immediate uses.
2481 (ssa_prop_fini): Free new worklists.
2482
2483 2018-09-24 Richard Biener <rguenther@suse.de>
2484
2485 PR tree-optimization/63155
2486 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
2487 the worklist when the edge of the respective argument isn't
2488 executable.
2489
2490 2018-10-16 Wilco Dijkstra <wdijkstr@arm.com>
2491
2492 Backported from mainline
2493 PR target/87511
2494 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
2495 Use HOST_WIDE_INT_1U for shift.
2496
2497 2018-10-16 Richard Biener <rguenther@suse.de>
2498
2499 Backport from mainline
2500 2018-09-18 Richard Biener <rguenther@suse.de>
2501
2502 PR middle-end/63155
2503 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
2504 (compute_samebase_partition_bases): Likewise.
2505 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
2506 (gimple_can_coalesce_p): Simplify.
2507
2508 2018-10-16 Richard Biener <rguenther@suse.de>
2509
2510 Backport from mainline
2511 2018-10-15 Richard Biener <rguenther@suse.de>
2512
2513 PR middle-end/87610
2514 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
2515 (visit_loadstore): When a used restrict tag escaped verify that
2516 the points-to solution of "other" pointers do not include
2517 escaped.
2518 (compute_dependence_clique): If a used restrict tag escaped
2519 communicated that down to visit_loadstore.
2520
2521 2018-10-01 Richard Biener <rguenther@suse.de>
2522
2523 PR tree-optimization/87465
2524 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
2525 causing branch miscounts.
2526
2527 2018-10-11 Jakub Jelinek <jakub@redhat.com>
2528
2529 Backported from mainline
2530 2018-10-10 Jakub Jelinek <jakub@redhat.com>
2531
2532 PR target/87550
2533 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
2534 to special_args set.
2535
2536 2018-09-26 Jakub Jelinek <jakub@redhat.com>
2537
2538 PR target/87414
2539 * config/i386/i386.c: Include debug.h and dwarf2out.h.
2540 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
2541 call.
2542
2543 2018-09-12 Jakub Jelinek <jakub@redhat.com>
2544 Andreas Krebbel <krebbel@linux.ibm.com>
2545
2546 PR tree-optimization/86844
2547 * gimple-ssa-store-merging.c
2548 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
2549 there are any overlapping stores in between them, make sure they are
2550 also coalesced or we give up completely.
2551
2552 2018-10-09 Will Schmidt <will_schmidt@vnet.ibm.com>
2553
2554 Backport from trunk.
2555 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
2556
2557 PR target/86731
2558 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
2559 around folding of vec_sl to handle out of range shift values.
2560
2561 2018-10-09 H.J. Lu <hongjiu.lu@intel.com>
2562
2563 Backport from mainline
2564 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
2565
2566 PR target/87370
2567 * config/i386/i386.c (construct_container): Use TImode for
2568 BLKmode values in 2 integer registers.
2569
2570 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
2571
2572 Backport from mainline
2573 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
2574
2575 PR target/87517
2576 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
2577 Defined with __builtin_ia32_vfmaddsubpd512_mask.
2578
2579 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
2580
2581 Backport from mainline
2582 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
2583
2584 PR target/87522
2585 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
2586 assembler for -mavx.
2587 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
2588
2589 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
2590
2591 Backport from mainline
2592 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
2593
2594 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
2595 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
2596
2597 2018-10-03 Jonathan Wakely <jwakely@redhat.com>
2598
2599 PR other/87353
2600 * doc/invoke.texi (Link Options): Fix formatting and grammar.
2601
2602 2018-10-03 Martin Liska <mliska@suse.cz>
2603
2604 Backport from mainline
2605 2018-10-03 Martin Liska <mliska@suse.cz>
2606
2607 PR gcov-profile/86109
2608 * coverage.c (coverage_begin_function): Do not
2609 mark lambdas as artificial.
2610 * tree-core.h (struct GTY): Remove tm_clone_flag
2611 and introduce new lambda_function.
2612 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
2613
2614 2018-10-02 H.J. Lu <hongjiu.lu@intel.com>
2615
2616 Backport from mainline
2617 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
2618
2619 PR target/82699
2620 * config/i386/i386.c (rest_of_insert_endbranch): Set
2621 endbr_queued_at_entrance to true and don't insert ENDBR if
2622 x86_function_profiler will be called.
2623 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
2624 is true.
2625 * config/i386/i386.h (machine_function): Add
2626 endbr_queued_at_entrance.
2627
2628 2018-10-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2629
2630 Backport from mainline
2631 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2632
2633 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
2634 if starting source register is not even.
2635
2636 2018-09-29 Jakub Jelinek <jakub@redhat.com>
2637
2638 PR target/87467
2639 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
2640 __m512d type for __A argument rather than __m512.
2641
2642 2018-09-27 Michael Meissner <meissner@linux.ibm.com>
2643
2644 Backport from mainline
2645 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
2646
2647 PR target/87033
2648 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
2649 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
2650 for indexed loads.
2651
2652 2018-09-25 Martin Liska <mliska@suse.cz>
2653
2654 Backport from mainline
2655 2018-09-24 Martin Liska <mliska@suse.cz>
2656
2657 PR sanitizer/85774
2658 * asan.c: Make asan_handled_variables extern.
2659 * asan.h: Likewise.
2660 * cfgexpand.c (expand_stack_vars): Make sure
2661 a representative is unpoison if another
2662 variable in the partition is handled by
2663 use-after-scope sanitization.
2664
2665 2018-09-24 Andrew Pinski <apinski@marvell.com>
2666
2667 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
2668 access prev before checking it for NULLness in the
2669 AARCH64_FUSE_CMP_BRANCH case.
2670
2671 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
2672
2673 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
2674 if the call takes a static chain.
2675
2676 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
2677
2678 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
2679 (atomic_storehi): Likewise.
2680 (atomic_storesi): Likewise.
2681 (atomic_loaddi): Restore compare and swap exchange loop code.
2682
2683 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
2684
2685 Backport from trunk
2686 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
2687
2688 PR rtl-optimization/86882
2689 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
2690
2691 2018-09-18 Martin Liska <mliska@suse.cz>
2692
2693 Backport from mainline
2694 2018-09-17 Martin Liska <mliska@suse.cz>
2695
2696 PR gcov-profile/85871
2697 * gcov.c (output_intermediate_file): Fix out of bounds
2698 access.
2699
2700 2018-09-16 Hans-Peter Nilsson <hp@bitrange.com>
2701
2702 PR target/85666
2703 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
2704 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
2705 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
2706 leaf_function_p, instead use has_hard_reg_initial_val.
2707
2708 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
2709
2710 PR middle-end/87188
2711 * dojump.c (do_compare_and_jump): Canonicalize function pointers
2712 when one operand is a function pointer. Use POINTER_TYPE_P and
2713 FUNC_OR_METHOD_TYPE_P.
2714 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
2715 * fold-const.c (build_range_check): Likewise.
2716 * match.pd (simple_comparison): Likewise.
2717
2718 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
2719
2720 Backport from trunk
2721 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
2722
2723 PR target/87224
2724 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
2725 alternatives.
2726
2727 2018-09-14 Carl Love <cel@us.ibm.com>
2728
2729 Backport from trunk
2730 2018-09-14 Carl Love <cel@us.ibm.com>
2731
2732 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
2733 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
2734
2735 2018-09-12 Segher Boessenkool <segher@kernel.crashing.org>
2736
2737 Backport from trunk
2738 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
2739
2740 PR target/86989
2741 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
2742 the TOC register.
2743
2744 2018-09-12 Segher Boessenkool <segher@kernel.crashing.org>
2745
2746 Backport from trunk
2747 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
2748
2749 PR rtl-optimization/86771
2750 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
2751 of two SETs into those two SETs, one to be placed at i2, if that SETs
2752 destination is modified between i2 and i3.
2753
2754 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
2755
2756 Backport from mainline
2757 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
2758
2759 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
2760 constants.
2761 ("trunc<BFP:mode><DFP_ALL:mode>2")
2762 ("trunc<DFP_ALL:mode><BFP:mode>2")
2763 ("extend<BFP:mode><DFP_ALL:mode>2")
2764 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
2765 according to the target operand type.
2766
2767 2018-09-12 Jakub Jelinek <jakub@redhat.com>
2768
2769 PR middle-end/87248
2770 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
2771 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
2772
2773 2018-09-05 Nathan Sidwell <nathan@acm.org>
2774
2775 PR c++/87137
2776 * stor-layout.c (place_field): Scan forwards to check last
2777 bitfield when ms_bitfield_placement is in effect.
2778
2779 2018-09-05 Richard Biener <rguenther@suse.de>
2780
2781 PR bootstrap/87225
2782 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
2783 return.
2784
2785 2018-09-05 Jakub Jelinek <jakub@redhat.com>
2786
2787 Backported from mainline
2788 2018-09-04 Jakub Jelinek <jakub@redhat.com>
2789
2790 PR target/87198
2791 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
2792 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
2793 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
2794 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
2795 and OPTION_MASK_ISA_XSAVEC_UNSET.
2796
2797 2018-08-31 Jakub Jelinek <jakub@redhat.com>
2798
2799 PR middle-end/87138
2800 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
2801 gen_int_mode. Formatting fixes.
2802
2803 2018-08-11 Jakub Jelinek <jakub@redhat.com>
2804
2805 PR tree-optimization/86835
2806 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
2807 new_stmt after def_gsi, make sure to insert new_square_stmt after
2808 that stmt, not 2 stmts before it.
2809
2810 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
2811
2812 Backport from mainline
2813 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
2814
2815 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
2816 XOR operations in NAND case.
2817
2818 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
2819
2820 * doc/invoke.texi (Option Summary): Add -Waligned-new.
2821
2822 2018-09-03 Tom de Vries <tdevries@suse.de>
2823
2824 backport from trunk:
2825 2018-06-21 Tom de Vries <tdevries@suse.de>
2826
2827 PR tree-optimization/85859
2828 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
2829 test with comment from bb_no_side_effects_p.
2830
2831 2018-09-01 Michael Matz <matz@suse.de>
2832
2833 Backport from mainline
2834 PR tree-optimization/87074
2835 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
2836 PHIs for outer-loop uses.
2837
2838 2018-08-31 Richard Biener <rguenther@suse.de>
2839
2840 Backport from mainline
2841 2018-08-27 Richard Biener <rguenther@suse.de>
2842
2843 PR tree-optimization/86927
2844 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
2845 use const cond reduction code.
2846
2847 2018-08-23 Richard Biener <rguenther@suse.de>
2848
2849 PR middle-end/87024
2850 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
2851 calls.
2852
2853 2018-08-22 Richard Biener <rguenther@suse.de>
2854
2855 PR tree-optimization/86945
2856 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
2857
2858 2018-08-17 Richard Biener <rguenther@suse.de>
2859
2860 PR middle-end/86505
2861 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
2862 across a va-arg-pack using call adjust its return value accordingly.
2863
2864 2018-08-02 Richard Biener <rguenther@suse.de>
2865
2866 PR tree-optimization/86816
2867 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
2868 which checks for value availability before querying it.
2869 (gvn_uses_equal): Use it.
2870 (same_succ_hash): Likewise.
2871 (gimple_equal_p): Likewise.
2872
2873 2018-07-17 Richard Biener <rguenther@suse.de>
2874
2875 PR lto/86456
2876 * dwarf2out.c (init_sections_and_labels): Always generate
2877 a debug_line_str_section for early LTO debug.
2878 (dwarf2out_finish): Reset debug_line_str_hash output early.
2879 Bump counter for extra dwarf5 .debug_loc labels to not conflict
2880 with fat LTO part.
2881 (dwarf2out_early_finish): Output debug_line_str.
2882
2883 2018-08-29 Luis Machado <luis.machado@linaro.org>
2884
2885 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static global.
2886 (qdf24xx_tunings): Set vector cost structure to qdf24xx_vector_cost.
2887
2888 2018-08-29 Luis Machado <luis.machado@linaro.org>
2889
2890 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
2891 <register_sextend>: Set to 3.
2892
2893 2018-08-27 Martin Sebor <msebor@redhat.com>
2894
2895 PR tree-optimization/86914
2896 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
2897
2898 2018-08-28 Jakub Jelinek <jakub@redhat.com>
2899
2900 PR middle-end/87099
2901 * calls.c (maybe_warn_nonstring_arg): Punt early if
2902 warn_stringop_overflow is zero. Don't call get_range_strlen
2903 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
2904 Only use lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
2905 increment lenrng[0].
2906
2907 2018-08-27 Jakub Jelinek <jakub@redhat.com>
2908
2909 PR rtl-optimization/87065
2910 * combine.c (simplify_if_then_else): Formatting fix.
2911 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
2912 check.
2913 (known_cond): Don't return const_true_rtx for vector modes. Use
2914 CONST0_RTX instead of const0_rtx. Formatting fixes.
2915
2916 2018-08-25 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2917
2918 Backport from mainline
2919 PR target/86662
2920 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
2921 with all enabled __intN types.
2922
2923 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
2924
2925 2018-08-21 H.J. Lu <hongjiu.lu@intel.com>
2926
2927 Backport from mainline
2928 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
2929
2930 PR target/87014
2931 * config/i386/i386.md (eh_return): Always update EH return
2932 address in word_mode.
2933
2934 2018-08-17 John David Anglin <danglin@gcc.gnu.org>
2935
2936 Backport from mainline
2937 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
2938
2939 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
2940 Update comment for atomic instructions.
2941 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
2942 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
2943 Remove.
2944 (atomic_loaddi): Revise fence expansion to only emit fence prior to
2945 load for __ATOMIC_SEQ_CST model.
2946 (atomic_loaddi_1): Remove float register target.
2947 (atomic_storedi): Handle CONST_INT values.
2948 (atomic_storedi_1): Remove float register source. Add special case
2949 for zero value.
2950 (memory_barrier): New expander and insn.
2951
2952 2018-08-16 Tamar Christina <tamar.christina@arm.com>
2953
2954 Backport from mainline
2955 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
2956
2957 PR target/86640
2958 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
2959 instead of GEN_INT.
2960
2961 2018-08-16 Martin Liska <mliska@suse.cz>
2962
2963 Backport from mainline
2964 2018-08-02 Martin Liska <mliska@suse.cz>
2965
2966 PR gcov-profile/86817
2967 * gcov.c (process_all_functions): New function.
2968 (main): Call it.
2969 (process_file): Move functions processing to
2970 process_all_functions.
2971
2972 2018-08-14 Siddhesh Poyarekar <siddhesh@sourceware.org>
2973
2974 Backport from mainline
2975 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
2976
2977 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
2978 neon_dup_q to...
2979 (falkor_am_1_gtov_gtov): ... a new insn reservation.
2980
2981 2018-08-13 Liu Hao <lh_mouse@126.com>
2982
2983 Backport from mainline
2984 2018-08-13 Liu Hao <lh_mouse@126.com>
2985
2986 * pretty-print.c (eat_esc_sequence): Swap the foreground and
2987 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
2988 and clear it thereafter, as it only works for DBCS.
2989
2990 2018-08-13 Liu Hao <lh_mouse@126.com>
2991
2992 Backport from mainline
2993 2018-08-13 Liu Hao <lh_mouse@126.com>
2994
2995 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
2996 handle returned by _get_osf_handle().
2997
2998 2018-08-14 Richard Sandiford <richard.sandiford@arm.com>
2999
3000 Backport from mainline
3001 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
3002
3003 PR tree-optimization/86871
3004 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
3005 instead of gimple_assign_lhs.
3006
3007 2018-08-07 H.J. Lu <hongjiu.lu@intel.com>
3008
3009 Backport from mainline
3010 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
3011
3012 PR target/86386
3013 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
3014 cfun->machine->max_used_stack_alignment if needed.
3015
3016 2018-08-02 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3017
3018 Backport from mainline
3019 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3020
3021 PR middle-end/86705
3022 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
3023 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
3024 requested variable alignment.
3025 (expand_one_ssa_partition): Likewise.
3026 (expand_one_var): Likewise.
3027
3028 2018-08-02 Andreas Schwab <schwab@linux-m68k.org>
3029
3030 Backport from mainline
3031 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
3032
3033 PR target/86820
3034 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
3035 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
3036
3037 2018-08-01 Richard Biener <rguenther@suse.de>
3038
3039 PR bootstrap/86724
3040 * graphite.h: Include isl/id.h and isl/space.h to allow build
3041 with ISL 0.20.
3042
3043 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
3044
3045 PR target/86651
3046 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
3047 mode for COFF targets.
3048 * defaults.h (TARGET_COFF): Define.
3049 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
3050 TARGET_COFF): Define.
3051 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
3052 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
3053 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
3054
3055 2018-07-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
3056
3057 Backport from mainline
3058 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
3059
3060 PR c/86617
3061 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
3062
3063 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
3064
3065 * config/pa/pa.c (pa_output_addr_vec): Align address table.
3066 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
3067 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
3068
3069 2018-07-26 Uros Bizjak <ubizjak@gmail.com>
3070
3071 Backport from mainline
3072 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
3073
3074 PR target/86511
3075 * expmed.c (emit_store_flag): Do not emit setcc followed by a
3076 conditional move when trapping comparison was split to a
3077 non-trapping one (and vice versa).
3078
3079 2018-07-26 Jakub Jelinek <jakub@redhat.com>
3080
3081 Backported from mainline
3082 2018-07-24 Jakub Jelinek <jakub@redhat.com>
3083
3084 PR middle-end/86627
3085 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
3086 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
3087 and abs_d == d, do the power of two handling if profitable.
3088
3089 2018-07-17 Jakub Jelinek <jakub@redhat.com>
3090
3091 PR middle-end/86542
3092 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
3093 to _looptemp_ clauses, other than the first two.
3094
3095 PR middle-end/86539
3096 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
3097 and cond temporaries don't have reference type if iterator has
3098 pointer type. For init use &for_pre_body instead of pre_p if
3099 for_pre_body is non-empty.
3100
3101 2018-07-26 Jakub Jelinek <jakub@redhat.com>
3102
3103 PR middle-end/86660
3104 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
3105 declare target to variables if they have always,{to,from,tofrom} map
3106 kinds.
3107
3108 * BASE-VER: Set to 8.2.1.
3109
3110 2018-07-26 Release Manager
3111
3112 * GCC 8.2.0 released.
3113
3114 2018-07-18 Martin Sebor <msebor@redhat.com>
3115
3116 PR middle-end/85602
3117 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
3118 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
3119 Handle integer subtraction.
3120 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
3121 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
3122 * doc/invoke.texi (-Wstringop-truncation): Update.
3123
3124 gcc/testsuite/ChangeLog:
3125
3126 2018-07-16 Claudiu Zissulescu <claziss@synopsys.com>
3127
3128 Backport from mainline
3129 2017-03-24 Claudiu Zissulescu <claziss@synopsys.com>
3130
3131 * config/arc/arc-protos.h (arc_pad_return): Remove.
3132 * config/arc/arc.c (machine_function): Remove force_short_suffix
3133 and size_reason.
3134 (arc_print_operand): Adjust printing of '&'.
3135 (arc_verify_short): Remove conditional printing of short suffix.
3136 (arc_final_prescan_insn): Remove reference to size_reason.
3137 (pad_return): New function.
3138 (arc_reorg): Call pad_return.
3139 (arc_pad_return): Remove.
3140 (arc_init_machine_status): Remove reference to force_short_suffix.
3141 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
3142 (attr length): When attribute iscompact is true force to 2
3143 regardless; in the case of maybe check if we want to force the
3144 instruction to have 4 bytes length.
3145 (nopv): Change it to generate 4 byte long nop as well.
3146 (blockage): New pattern.
3147 (simple_return): Remove call to arc_pad_return.
3148 (p_return_i): Likewise.
3149
3150 2018-07-19 Richard Biener <rguenther@suse.de>
3151
3152 Backport from mainline
3153 2018-07-13 Richard Biener <rguenther@suse.de>
3154
3155 PR debug/86452
3156 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
3157 instead of get_context_die.
3158
3159 2018-07-11 Richard Biener <rguenther@suse.de>
3160
3161 PR debug/86457
3162 * dwarf2out.c (init_sections_and_labels): Use
3163 output_asm_line_debug_info consistently.
3164 (dwarf2out_early_finish): Likewise.
3165 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
3166 type units.
3167
3168 2018-07-16 Richard Biener <rguenther@suse.de>
3169
3170 Backport from mainline
3171 2018-07-13 Richard Biener <rguenther@suse.de>
3172
3173 PR middle-end/85974
3174 * match.pd (addr1 - addr2): Allow either of the operand to
3175 have a conversion.
3176
3177 2018-06-15 Richard Biener <rguenther@suse.de>
3178
3179 PR middle-end/86076
3180 * tree-cfg.c (move_stmt_op): unshare invariant addresses
3181 before adjusting their block.
3182
3183 2018-06-06 Richard Biener <rguenther@suse.de>
3184
3185 PR tree-optimization/85935
3186 * graphite-scop-detection.c (find_params_in_bb): Analyze
3187 condition operands with respect to the correct loop. Assert
3188 the analysis doesn't fail.
3189
3190 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
3191
3192 PR tree-optimization/86514
3193 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
3194 conversion to a boolean type from a type with greater precision.
3195
3196 2018-07-15 Bill Schmidt <wschmidt@linux.ibm.com>
3197
3198 Backport from mainline
3199 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
3200 Steve Munroe <munroesj52@gmail.com>
3201
3202 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
3203 (_mm_andnot_si128): Likewise.
3204 (_mm_or_si128): Likewise.
3205 (_mm_xor_si128): Likewise.
3206
3207 2018-07-14 Martin Sebor <msebor@redhat.com>
3208
3209 PR tree-optimization/86274
3210 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
3211 precondition.
3212 (format_floating): Correct handling of infinities and NaNs.
3213
3214 2018-07-13 H.J. Lu <hongjiu.lu@intel.com>
3215
3216 Backport from mainline
3217 2018-07-13 H.J. Lu <hongjiu.lu@intel.com>
3218 Sunil K Pandey <sunil.k.pandey@intel.com>
3219
3220 PR target/84413
3221 * config/i386/i386.c (m_CORE_AVX512): New.
3222 (m_CORE_AVX2): Likewise.
3223 (m_CORE_ALL): Add m_CORE_AVX2.
3224 * config/i386/x86-tune.def: Replace m_HASWELL with m_CORE_AVX2.
3225 Replace m_SKYLAKE_AVX512 with m_CORE_AVX512 on avx256_optimal
3226 and remove the rest of m_SKYLAKE_AVX512.
3227
3228 2018-07-13 Marek Polacek <polacek@redhat.com>
3229
3230 Backport from trunk
3231 2018-07-03 Marek Polacek <polacek@redhat.com>
3232
3233 PR middle-end/86202
3234 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
3235
3236 2018-07-12 Richard Biener <rguenther@suse.de>
3237
3238 PR target/84829
3239 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
3240 Remove -mieee-fp handling.
3241
3242 2018-07-12 Jakub Jelinek <jakub@redhat.com>
3243
3244 PR tree-optimization/86492
3245 * gimple-ssa-store-merging.c
3246 (imm_store_chain_info::coalesce_immediate_stores): Call
3247 check_no_overlap even for the merge_overlapping case.
3248
3249 2018-07-11 Jakub Jelinek <jakub@redhat.com>
3250
3251 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
3252 Use __mmask64 type instead of __mmask8 for __M argument.
3253 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
3254 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
3255 __U argument.
3256 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
3257 __mmask16 for __M argument.
3258 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
3259 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
3260 to __mmask16 instead of __mmask8.
3261 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
3262 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
3263 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
3264 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
3265 instead of __mmask16 for __U argument.
3266 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
3267 __mmask16 instead of __mmask8 for __U argument.
3268 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
3269 __U argument.
3270 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
3271 __mmask16.
3272 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
3273 argument.
3274 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
3275 __U argument.
3276 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
3277 __mmask16.
3278 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
3279 of __mmask16.
3280 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
3281 __U argument.
3282 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
3283 __U argument.
3284 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
3285 __U argument.
3286 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
3287 __U argument.
3288 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
3289 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
3290 return type as well as __M argument type and all casts from __mmask8
3291 to __mmask32.
3292 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
3293 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
3294 return type as well as __M argument type and all casts from __mmask8
3295 to __mmask16.
3296 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
3297 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
3298 return type as well as __M argument type and all casts from __mmask8
3299 to __mmask32.
3300 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
3301 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
3302 return type as well as __M argument type and all casts from __mmask8
3303 to __mmask16.
3304 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
3305 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
3306 __mmask16.
3307
3308 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
3309
3310 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
3311 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
3312 for __U argument.
3313
3314 2018-07-05 Martin Sebor <msebor@redhat.com>
3315
3316 PR c++/86400
3317 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
3318 than its domain to compute its the upper bound of a char array.
3319
3320 2018-07-03 Carl Love <cel@us.ibm.com>
3321
3322 Backport from trunk
3323 2018-07-03 Carl Love <cel@us.ibm.com>
3324
3325 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
3326 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
3327 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
3328 VSX_BUILTIN_DOUBLEL_V4SF.
3329
3330 2018-07-04 Luis Machado <luis.machado@linaro.org>
3331
3332 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
3333 global.
3334 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
3335
3336 2018-07-02 Segher Boessenkool <segher@kernel.crashing.org>
3337
3338 Backport from trunk
3339 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
3340
3341 PR target/86285
3342 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
3343 ieee128_float_type_node to long_double_type_node unless
3344 TARGET_LONG_DOUBLE_128 is set.
3345
3346 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
3347
3348 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
3349 -fno-omit-frame-pointer when not optimizing.
3350
3351 2018-06-30 Alexandre Oliva <aoliva@redhat.com>
3352
3353 PR debug/86064
3354 * dwarf2out.c (loc_list_has_views): Adjust comments.
3355 (dw_loc_list): Split single cross-partition range with
3356 nonzero locview.
3357
3358 2018-06-29 Kelvin Nilsen <kelvin@gcc.gnu.org>
3359
3360 Backport from mainline
3361 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
3362
3363 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
3364 behavior of vec_pack (vector double, vector double) to match
3365 behavior of vec_float2 (vector double, vector double).
3366
3367 2018-06-29 Jakub Jelinek <jakub@redhat.com>
3368
3369 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
3370
3371 2018-06-28 Kelvin Nilsen <kelvin@gcc.gnu.org>
3372
3373 Backport from mainline
3374 2017-05-23 Segher Boessenkool <segher@kernel.crashing.org>
3375
3376 * doc/sourcebuild.texi (Endianness): New subsubsection.
3377
3378 2018-06-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
3379
3380 Backport from mainline
3381 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
3382
3383 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
3384 behavior of vec_packsu (vector unsigned long long, vector unsigned
3385 long long) to match behavior of vec_packs with same signature.
3386
3387 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
3388
3389 Backport from trunk
3390 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
3391
3392 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
3393 unaligned vsx for 16B memset.
3394
3395 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
3396
3397 Backport from trunk
3398 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
3399
3400 PR target/86222
3401 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
3402 correctly.
3403
3404 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
3405
3406 Backport from trunk
3407 2018-05-08 Segher Boessenkool <segher@kernel.crashing.org>
3408
3409 PR rtl-optimization/85645
3410 * regrename.c (build_def_use): Also kill the chains that include the
3411 destination of a REG_CFA_REGISTER note.
3412
3413 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
3414
3415 Backport from trunk
3416 2018-05-08 Segher Boessenkool <segher@kernel.crashing.org>
3417
3418 PR rtl-optimization/85645
3419 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
3420 insn that has a REG_CFA_REGISTER note.
3421
3422 2018-06-26 Robin Dapp <rdapp@linux.ibm.com>
3423
3424 * config/s390/s390.h (enum processor_flags): Do not use
3425 default tune parameter when -march was specified.
3426
3427 2018-06-26 Jakub Jelinek <jakub@redhat.com>
3428
3429 PR target/86314
3430 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
3431 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
3432 operands.
3433
3434 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
3435
3436 Back port from trunk
3437 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
3438
3439 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
3440 added IEEE/IBM long double multilib support on PowerPC little
3441 endian Linux systems.
3442 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
3443 (MULTILIB_DEFAULTS): Likewise.
3444 * config/rs6000/rs6000.c (rs6000_option_override_internal):
3445 Likewise.
3446 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
3447 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
3448 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
3449
3450 2018-06-25 Segher Boessenkool <segher@kernel.crashing.org>
3451
3452 Backport from trunk
3453 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
3454
3455 * config/rs6000/rs6000.md (abs<mode>2): Handle IFmode.
3456
3457 2018-05-02 Jan Hubicka <jh@suse.cz>
3458
3459 Backport from mainline
3460 2018-04-30 Jan Hubicka <jh@suse.cz>
3461
3462 * lto-wrapper.c (ltrans_priorities): New static var.
3463 (cmp_priority): New.
3464 (run_gcc): Read priorities and if doing parallel build order
3465 the Makefile by them.
3466
3467 2018-06-25 Segher Boessenkool <segher@kernel.crashing.org>
3468
3469 Backport from trunk
3470 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
3471
3472 PR target/86197
3473 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
3474 ieee128 argument takes up only one (vector) register, not two (floating
3475 point) registers.
3476
3477 2018-06-23 Richard Sandiford <richard.sandiford@linaro.org>
3478
3479 PR tree-optimization/85989
3480 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
3481 variable.
3482 (backprop::intersect_uses): Check it when deciding whether this
3483 is a backedge reference.
3484 (backprop::process_block): Add each phi to m_visited_phis
3485 after visiting it, then clear it at the end.
3486
3487 2018-06-22 David Edelsohn <dje.gcc@gmail.com>
3488
3489 Backport from mainline
3490
3491 2018-06-19 Tony Reix <tony.reix@atos.com>
3492 Damien Bergamini <damien.bergamini@atos.com>
3493 David Edelsohn <dje.gcc@gmail.com>
3494
3495 * collect2.c (static_obj): New variable.
3496 (static_libs): New variable.
3497 (is_in_list): Uncomment declaration.
3498 (main): Track AIX libraries linked statically.
3499 (is_in_list): Uncomment definition.
3500 (scan_prog_file): Don't add AIX shared libraries initializer
3501 to constructor list if linking statically.
3502
3503 2018-06-22 Michael Meissner <meissner@linux.ibm.com>
3504
3505 Back port from trunk
3506 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
3507
3508 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
3509 conversion insn that shows up when pr85657-3.c is compiled using
3510 IEEE 128-bit long double.
3511
3512 Back port from trunk
3513 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
3514
3515 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
3516 multiply and divide external functions from being created more
3517 than once.
3518
3519 Back port from trunk
3520 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
3521
3522 * config/rs6000/rs6000.md (neg<mode>2_internal): Use the correct
3523 mode to check whether the mode is IBM extended.
3524
3525 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
3526
3527 PR target/85358
3528 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
3529 floating point modes, so that IFmode is numerically greater than
3530 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
3531 to declare the ordering. This prevents IFmode from being
3532 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
3533 machine. Include rs6000-modes.h to share the fractional values
3534 between genmodes* and the rest of the compiler.
3535 (IFmode): Likewise.
3536 (KFmode): Likewise.
3537 (TFmode): Likewise.
3538 * config/rs6000/rs6000-modes.h: New file.
3539 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
3540 meaning of rs6000_long_double_size so that 126..128 selects an
3541 appropriate 128-bit floating point type.
3542 (rs6000_option_override_internal): Likewise.
3543 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
3544 (TARGET_LONG_DOUBLE_128): Change the meaning of
3545 rs6000_long_double_size so that 126..128 selects an appropriate
3546 128-bit floating point type.
3547 (LONG_DOUBLE_TYPE_SIZE): Update comment.
3548 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
3549 source and destination to match the standard usage.
3550 (truncifkf2): Likewise.
3551 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
3552 ISA 2.07 to use an explicit clobber, instead of passing in a
3553 temporary.
3554 (copysign<mode>3_soft): Likewise.
3555
3556 Back port from trunk
3557 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
3558
3559 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
3560 TARGET_ELF.
3561
3562 Back port from trunk
3563 2018-06-04 Michael Meissner <meissner@linux.ibm.com>
3564
3565 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
3566 track if we pass or return IEEE 128-bit floating point.
3567 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
3568 C++ mangling that is compatible with GCC 8.1.
3569 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
3570 (init_cumulative_args): Note if we pass or return IEEE 128-bit
3571 floating point types.
3572 (rs6000_function_arg_advance_1): Likewise.
3573 (rs6000_mangle_type): Optionally generate mangled names that match
3574 what GCC 8.1 generated for IEEE 128-bit floating point types.
3575 (rs6000_globalize_decl_name): If we have an external function that
3576 passes or returns IEEE 128-bit types, generate a weak reference
3577 from the mangled name used in GCC 8.1 to the current mangled
3578 name.
3579 (rs6000_init_builtins): Make __ibm128 use the long double type if
3580 long double is IBM extended double. Make __float128 use the long
3581 double type if long double is IEEE 128-bit.
3582
3583 PR target/85657
3584 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
3585 macro for __ibm128 built-in functions.
3586 (PACK_IF): Add __ibm128 pack/unpack functions.
3587 (UNPACK_IF): Likewise.
3588 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
3589 enable long double built-in functions if long double is IEEE
3590 128-bit floating point.
3591 (rs6000_invalid_builtin): Update long double built-in function
3592 error message.
3593 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
3594 functions, adjust the built-in function to use the long double
3595 built-in function if __ibm128 and long double are the same type.
3596 * doc/extend.texi (PowerPC builtins): Update documention for
3597 __builtin_{,un}pack_longdouble. Add documentation for
3598 __builtin_{,un}pack_ibm128.
3599
3600 Back port from trunk
3601 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
3602
3603 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
3604 the 128-bit floating point types. Fix function comment.
3605
3606 2018-06-22 Michael Meissner <meissner@linux.ibm.com>
3607
3608 Back port from trunk
3609 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
3610
3611 PR target/85657
3612 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
3613 define __ibm128 as long double.
3614 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
3615 as a distinct type with IEEE 128-bit floating point is supported.
3616 (init_float128_ieee): Fix up conversions between IFmode and IEEE
3617 128-bit types to use the correct functions.
3618 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
3619 convert between 128-bit floating point types that have different
3620 modes but the same representation, instead of using gen_lowpart to
3621 makean alias.
3622 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
3623 KFmode.
3624 (IFKF_reg): New attributes to give the register constraints for
3625 IFmode and KFmode.
3626 (extend<mode>tf2_internal): New insns to mark an explicit
3627 conversion between 128-bit floating point types that have a
3628 different mode but share the same representation.
3629
3630 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3631
3632 PR target/85994
3633 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
3634 -x assembler-with-cpp.
3635
3636 2018-06-21 Sebastian Huber <sebastian.huber@embedded-brains.de>
3637
3638 Backported from mainline
3639 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
3640
3641 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
3642 multilibs for *-*-rtems*.
3643 * config/riscv/t-rtems: New file.
3644
3645 2018-06-20 Jakub Jelinek <jakub@redhat.com>
3646
3647 Backported from mainline
3648 2018-06-16 Jakub Jelinek <jakub@redhat.com>
3649
3650 PR rtl-optimization/86108
3651 * bb-reorder.c (create_forwarder_block): Renamed to ...
3652 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
3653 jump from new landing pad to the second part.
3654 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
3655 Adjust callers.
3656
3657 2018-06-20 Jakub Jelinek <jakub@redhat.com>
3658
3659 PR debug/86194
3660 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
3661 be narrowed.
3662
3663 PR tree-optimization/86231
3664 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
3665 anti-range don't overwrite *vr0min before using it to compute *vr0max.
3666
3667 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
3668
3669 Backport from mainline
3670 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
3671
3672 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
3673 constant.
3674 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
3675
3676 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
3677
3678 * gimplify.c (gimplify_init_constructor): Really never clear for an
3679 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
3680
3681 2018-06-18 Martin Sebor <msebor@redhat.com>
3682
3683 PR c/82063
3684 * calls.c (alloc_max_size): Correct a logic error/typo.
3685 Treat excessive arguments as infinite. Warn for invalid arguments.
3686 * doc/invoke.texi (-Walloc-size-larger-than): Update.
3687
3688 2018-06-16 Jakub Jelinek <jakub@redhat.com>
3689
3690 PR middle-end/86095
3691 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
3692 documented as preserved for backward compatibility only.
3693 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
3694
3695 2018-06-15 Jakub Jelinek <jakub@redhat.com>
3696
3697 PR middle-end/85878
3698 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
3699 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
3700 Only call store_expr for halves if the mode is the same.
3701
3702 PR middle-end/86123
3703 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
3704 Fix up comment formatting.
3705
3706 2018-06-14 Jakub Jelinek <jakub@redhat.com>
3707
3708 PR middle-end/86122
3709 * match.pd ((A +- CST1) +- CST2): Punt if last resort
3710 unsigned_type_for returns NULL.
3711
3712 PR target/85945
3713 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
3714 subregs of multi-word pseudos unless the float mode has word size.
3715
3716 2018-06-14 Richard Biener <rguenther@suse.de>
3717
3718 PR middle-end/86139
3719 * tree-vect-generic.c (build_word_mode_vector_type): Remove
3720 duplicate and harmful type_hash_canon.
3721 * tree.c (type_hash_canon): Assert we didn't find ourselves.
3722
3723 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
3724
3725 Backport from mainline
3726 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
3727
3728 * config/rtems.h (STDINT_LONG32): Define.
3729
3730 2018-05-05 Roland McGrath <mcgrathr@google.com>
3731
3732 PR other/77609
3733 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
3734 any section for which we don't know a specific type it should have,
3735 regardless of name. Previously this was done only for the exact
3736 names ".init_array", ".fini_array", and ".preinit_array".
3737 (default_elf_asm_named_section): Add comment about
3738 relationship with default_section_type_flags and SECTION_NOTYPE.
3739 (get_section): Don't consider it a type conflict if one side has
3740 SECTION_NOTYPE and the other doesn't, as long as neither has the
3741 SECTION_BSS et al used in the default_section_type_flags logic.
3742
3743 2018-06-13 Martin Sebor <msebor@redhat.com>
3744
3745 PR tree-optimization/86114
3746 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
3747 of integer types.
3748 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
3749
3750 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
3751
3752 PR target/86048
3753 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
3754 offsets for register save directives. Emit a second batch of save
3755 directives, if need be, when the function accesses prior frames.
3756
3757 2018-06-11 Jason Merrill <jason@redhat.com>
3758
3759 PR c++/80485 - inline function non-zero address.
3760 * symtab.c (nonzero_address): Check DECL_COMDAT.
3761
3762 2018-06-11 Peter Bergner <bergner@vnet.ibm.com>
3763
3764 Backport from mainline
3765 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
3766
3767 PR target/85755
3768 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
3769 addresses.
3770
3771 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
3772
3773 Backport from trunk
3774 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
3775
3776 PR target/85755
3777 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
3778 on the correct operand.
3779 (*movdi_internal64): Ditto.
3780
3781 2018-06-08 Carl Love <cel@us.ibm.com>
3782
3783 Backport from mainline
3784 * gcc/config/rs6000/vsx.md (vextract_fp_from_shorth,
3785 vextract_fp_from_shortl): Add BE support.
3786
3787 2018-06-08 Carl Love <cel@us.ibm.com>
3788
3789 Backport from mainline
3790 * gcc/config/rs6000/vsx.md (first_match_index_<mode>):
3791 Calculate index using natureal element order.
3792 (first_match_or_eos_index_<mode>):
3793 Calculate index using natural element order.
3794 (first_match_index_<mode>):
3795 Calculate index using natural element order.
3796 (first_match_or_eos_index_<mode>):
3797 Calculate index using natural order.
3798 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
3799 for BE and LE modes.
3800 * gcc/config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
3801 P9V_BUILTIN_VCLZLSBB_V16QI.
3802 * gcc/config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
3803 specific.
3804
3805 2018-06-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3806
3807 Backport from mainline
3808 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3809
3810 PR target/81497
3811 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
3812 qualifier_void_pointer and qualifier_const_void_pointer.
3813 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
3814 (arm_init_builtins): Handle the above.
3815 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
3816 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
3817 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
3818 void intrinsics.
3819
3820 2018-06-07 Uros Bizjak <ubizjak@gmail.com>
3821
3822 PR target/85684
3823 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
3824 Generate SImode target register for null target.
3825 <case IX86_BUILTIN_XGETBV>: Ditto.
3826 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
3827 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
3828
3829 2018-06-07 Peter Bergner <bergner@vnet.ibm.com>
3830
3831 Backport from mainline
3832 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
3833
3834 PR target/63177
3835 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
3836 Don't handle -mcpu=power8 if -mpower9-vector is also used.
3837
3838 2018-06-06 Richard Biener <rguenther@suse.de>
3839
3840 Backport from mainline
3841 2018-06-04 Richard Biener <rguenther@suse.de>
3842
3843 PR tree-optimization/86038
3844 * tracer.c (find_best_successor): Check probability for
3845 being initialized, bail out if not.
3846
3847 2018-05-30 Richard Biener <rguenther@suse.de>
3848
3849 PR tree-optimization/85964
3850 * tracer.c (better_p): Drop initialized count check, we only
3851 call the function with initialized counts now.
3852 (find_best_successor): Do find a best edge if one
3853 has uninitialized count.
3854 (find_best_predecessor): Likewise. Do BB frequency check only
3855 if count is initialized.
3856
3857 2018-05-28 Richard Biener <rguenther@suse.de>
3858
3859 PR tree-optimization/85934
3860 * tree-vect-generic.c (expand_vector_operations_1): Hoist
3861 vector boolean check before scalar optimization.
3862
3863 2018-05-22 Richard Biener <rguenther@suse.de>
3864
3865 PR tree-optimization/85863
3866 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
3867 comparisons when vectype is specified.
3868 (vectorizable_condition): Do not specify vectype for
3869 vect_is_simple_cond when SLP vectorizing.
3870
3871 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
3872
3873 Backport from mainline
3874 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
3875
3876 * config/s390/s390-builtin-types.def: Add void function type.
3877 * config/s390/s390-builtins.def: Use the function type for the
3878 tbeginc builtin.
3879
3880 2018-06-04 Martin Sebor <msebor@redhat.com>
3881
3882 PR c/85623
3883 * calls.c (maybe_warn_nonstring_arg): Use string length to set
3884 or ajust the presumed bound on an operation to avoid unnecessary
3885 warnings.
3886
3887 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
3888
3889 PR target/86003
3890 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
3891 of bits to ignore when comparing architectures.
3892
3893 2018-06-04 Jakub Jelinek <jakub@redhat.com>
3894
3895 PR c++/86025
3896 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
3897
3898 2018-06-01 Bill Schmidt <wschmidt@linux.ibm.com>
3899
3900 PR tree-optimization/85712
3901 Backport from mainline:
3902 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
3903
3904 PR tree-optimization/85712
3905 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
3906 first_interp field.
3907 (alloc_cand_and_find_basis): Initialize first_interp field.
3908 (slsr_process_mul): Modify first_interp field.
3909 (slsr_process_add): Likewise.
3910 (slsr_process_cast): Modify first_interp field for each new
3911 interpretation.
3912 (slsr_process_copy): Likewise.
3913 (dump_candidate): Dump first_interp field.
3914 (replace_mult_candidate): Process all interpretations, not just
3915 subsequent ones.
3916 (replace_rhs_if_not_dup): Likewise.
3917 (replace_one_candidate): Likewise.
3918
3919 Backport from mainline:
3920 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
3921
3922 PR tree-optimization/85712
3923 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
3924 this candidate has already been replaced in-situ by a copy.
3925
3926 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
3927
3928 PR target/85950
3929 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
3930 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
3931 sequence.
3932 (sse4_1_round<mode>2): Use nonimmediate_operand
3933 for operand 1 predicate.
3934
3935 2018-05-31 Jakub Jelinek <jakub@redhat.com>
3936
3937 PR target/85984
3938 * bb-reorder.c (pass_partition_blocks::gate): Return false for
3939 functions with naked attribute.
3940
3941 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
3942
3943 PR target/85829
3944 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
3945 and movx for Haswell.
3946
3947 2018-05-30 Jakub Jelinek <jakub@redhat.com>
3948
3949 Backported from mainline
3950 2018-05-14 Jakub Jelinek <jakub@redhat.com>
3951
3952 PR target/85756
3953 * config/i386/i386.md: Disallow non-commutative arithmetics in
3954 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
3955 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
3956 in the peephole2 before it.
3957
3958 2018-05-08 Jakub Jelinek <jakub@redhat.com>
3959
3960 PR target/85683
3961 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
3962 after cmpelim optimization.
3963
3964 2018-05-28 H.J. Lu <hongjiu.lu@intel.com>
3965
3966 Backport from mainline
3967 2018-05-26 H.J. Lu <hongjiu.lu@intel.com>
3968
3969 PR target/85900
3970 PR target/85345
3971 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
3972
3973 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
3974
3975 PR target/85900
3976 PR target/85345
3977 * varasm.c (assemble_alias): Check ifunc_resolver only on
3978 FUNCTION_DECL.
3979
3980 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
3981
3982 PR target/85345
3983 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
3984 attribute.
3985 (cgraph_node::create_alias): Likewise.
3986 (cgraph_node::get_availability): Check ifunc_resolver instead
3987 of looking up ifunc attribute.
3988 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
3989 * varasm.c (do_assemble_alias): Likewise.
3990 (assemble_alias): Likewise.
3991 (default_binds_local_p_3): Likewise.
3992 * cgraph.h (cgraph_node): Add ifunc_resolver.
3993 (cgraph_node::only_called_directly_or_aliased_p): Return false
3994 for IFUNC resolver.
3995 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
3996 attribute.
3997 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
3998 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
3999 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
4000 instead of looking up ifunc attribute.
4001
4002 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
4003
4004 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
4005
4006 2018-05-25 Richard Biener <rguenther@suse.de>
4007
4008 PR c++/85912
4009 * tree-dump.c (dequeue_and_dump): Remove access to removed
4010 operand 2 of a SWITCH_EXPR.
4011
4012 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
4013
4014 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
4015 Add {q} suffix to insn mnemonic.
4016
4017 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
4018
4019 PR target/85903
4020 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
4021 when memory input operand is handled.
4022
4023 2018-05-23 Bin Cheng <bin.cheng@arm.com>
4024
4025 Backport from mainline
4026 2018-05-17 Bin Cheng <bin.cheng@arm.com>
4027 Richard Biener <rguenther@suse.de>
4028
4029 PR tree-optimization/85793
4030 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
4031 for VMAT_ELEMENTWISE.
4032
4033 2018-05-23 Richard Biener <rguenther@suse.de>
4034
4035 PR middle-end/85874
4036 * tree-data-ref.c (create_runtime_alias_checks): Defer
4037 and ignore overflow warnings.
4038
4039 2018-05-23 Martin Liska <mliska@suse.cz>
4040
4041 Backport from mainline
4042 2018-05-23 Yury Gribov <tetra2005@gmail.com>
4043
4044 PR tree-optimization/85822
4045 * tree-vrp.c (is_masked_range_test): Fix handling of negative
4046 constants.
4047
4048 2018-05-23 Martin Liska <mliska@suse.cz>
4049
4050 Backport from mainline
4051 2018-05-11 Martin Liska <mliska@suse.cz>
4052
4053 PR sanitizer/85556
4054 * doc/extend.texi: Document LLVM style format for no_sanitize
4055 attribute.
4056
4057 2018-05-22 Martin Sebor <msebor@redhat.com>
4058
4059 PR middle-end/85643
4060 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
4061
4062 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
4063
4064 PR tree-optimization/85814
4065 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
4066 a null return from get_strinfo when unsharing the next
4067 strinfo in the chain.
4068
4069 2018-05-21 Pat Haugen <pthaugen@us.ibm.com>
4070
4071 Backport from mainline
4072 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
4073 Segher Boessenkool <segher@kernel.crashing.org>
4074
4075 PR target/85698
4076 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest operand.
4077
4078 2018-05-18 Toon Moene <toon@moene.org>
4079
4080 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
4081 directly after that of -floop-interchange. Indicate that both
4082 options are enabled by default when specifying -O3.
4083
4084 2018-05-11 Martin Jambor <mjambor@suse.cz>
4085
4086 PR ipa/85655
4087 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
4088 single const.
4089
4090 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
4091
4092 PR target/85733
4093 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
4094
4095 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
4096
4097 PR target/85606
4098 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
4099 equivalent.
4100 (cortex-m0): Use armv6s-m isa.
4101 (cortex-m0plus): Likewise.
4102 (cortex-m1): Likewise.
4103 (cortex-m0.small-multiply): Likewise.
4104 (cortex-m0plus.small-multiply): Likewise.
4105 (cortex-m1.small-multiply): Likewise.
4106
4107 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
4108
4109 PR rtl-optimization/85638
4110 * bb-reorder.c: Include common/common-target.h.
4111 (create_forwarder_block): New function extracted from...
4112 (fix_up_crossing_landing_pad): ...here. Rename into...
4113 (dw2_fix_up_crossing_landing_pad): ...this.
4114 (sjlj_fix_up_crossing_landing_pad): New function.
4115 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
4116 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
4117 from both partitions and exit the loop after one iteration.
4118
4119 2018-05-08 Richard Biener <rguenther@suse.de>
4120
4121 Backport from mainline
4122 2018-05-04 Richard Biener <rguenther@suse.de>
4123
4124 PR middle-end/85588
4125 * fold-const.c (negate_expr_p): Restrict negation of operand
4126 zero of a division to when we know that can happen without
4127 overflow.
4128 (fold_negate_expr_1): Likewise.
4129
4130 2018-05-03 Richard Biener <rguenther@suse.de>
4131
4132 PR tree-optimization/85615
4133 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
4134 to loops not nested in BBs loop father to avoid creating multi-entry
4135 loops.
4136
4137 2018-05-02 Richard Biener <rguenther@suse.de>
4138
4139 PR middle-end/85567
4140 * gimplify.c (gimplify_save_expr): When in SSA form allow
4141 SAVE_EXPRs to compute to SSA vars.
4142
4143 2018-05-02 Richard Biener <rguenther@suse.de>
4144
4145 PR tree-optimization/85597
4146 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
4147 do not use split vect_get_vec_defs call but call vect_get_slp_defs
4148 directly.
4149
4150 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
4151
4152 PR target/85658
4153 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
4154 (check_arch): Likewise.
4155 (check_fpu): Return the result rather than printing it.
4156 (end arch): Fix operator precedence.
4157 (end cpu): Likewise.
4158 (END): Print the result from check_fpu.
4159
4160 2018-05-08 Richard Biener <rguenther@suse.de>
4161
4162 Backport from mainline
4163 2018-05-04 Richard Biener <rguenther@suse.de>
4164
4165 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
4166 * gimple-ssa-store-merging.c
4167 (imm_store_chain_info::output_merged_store): Remove redundant create,
4168 release split_store vector contents on failure.
4169 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
4170 scalar stmt vector on cache hit.
4171
4172 2018-05-04 Richard Biener <rguenther@suse.de>
4173
4174 PR middle-end/85627
4175 * tree-complex.c (tree_lower_complex): Handle removed blocks.
4176
4177 2018-05-07 Chung-Ju Wu <jasonwucj@gmail.com>
4178
4179 Backport from mainline.
4180 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
4181
4182 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
4183 GET_MODE_MASK before any checking.
4184 (nds32_can_use_bset_p): Likewise.
4185 (nds32_can_use_btgl_p): Likewise.
4186
4187 2018-05-07 Chung-Ju Wu <jasonwucj@gmail.com>
4188
4189 Backport from mainline.
4190 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
4191
4192 * config/nds32/nds32-doubleword.md: New define_split pattern for
4193 illegal register number.
4194
4195 2018-05-07 Chung-Ju Wu <jasonwucj@gmail.com>
4196
4197 Backport from mainline.
4198 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
4199
4200 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
4201
4202 2018-05-07 Chung-Ju Wu <jasonwucj@gmail.com>
4203
4204 Backport from mainline.
4205 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
4206
4207 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
4208
4209 2018-05-06 Jakub Jelinek <jakub@redhat.com>
4210
4211 PR c++/85659
4212 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
4213 the type is addressable. Don't force op into register if it has
4214 BLKmode.
4215
4216 2018-05-04 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4217
4218 Backport from trunk.
4219 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4220
4221 PR target/85512
4222 * config/aarch64/constraints.md (Usg): Limit to 31.
4223 (Usj): Limit to 63.
4224
4225 2018-05-02 Jakub Jelinek <jakub@redhat.com>
4226
4227 * BASE-VER: Set to 8.1.1.
4228
4229 2018-05-02 Release Manager
4230
4231 * GCC 8.1.0 released.
4232
4233 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
4234
4235 PR tree-optimization/85586
4236 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
4237 exit early for statements in the same group if the accesses are
4238 not strided.
4239
4240 2018-05-01 Jakub Jelinek <jakub@redhat.com>
4241
4242 PR web/85578
4243 * doc/install.texi2html: Replace _002d with - and _002a with * in
4244 generated html files using sed.
4245
4246 2018-04-27 Martin Jambor <mjambor@suse.cz>
4247
4248 PR ipa/85549
4249 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
4250 the jump function allows for passing through aggregate values.
4251
4252 2018-04-27 Jeff Law <law@redhat.com>
4253
4254 * config.gcc: Mark tile* targets as deprecated/obsolete.
4255
4256 2018-04-27 Jakub Jelinek <jakub@redhat.com>
4257
4258 PR tree-optimization/85529
4259 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
4260 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
4261 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
4262 zero extension or masking of the MSB bit.
4263 (optimize_range_tests): Add FIRST_BB argument, pass it through
4264 to optimize_range_tests_var_bound.
4265 (maybe_optimize_range_tests, reassociate_bb): Adjust
4266 optimize_range_tests callers.
4267
4268 2018-04-26 Richard Biener <rguenther@suse.de>
4269 Jakub Jelinek <jakub@redhat.com>
4270
4271 * cgraph.h (symbol_table): Just declare debug method here.
4272 * symtab.c (symbol_table::debug): Define.
4273
4274 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
4275
4276 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
4277
4278 2018-04-25 H.J. Lu <hongjiu.lu@intel.com>
4279
4280 Backport from mainline
4281 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
4282
4283 PR target/85473
4284 * config/i386/i386.c (ix86_expand_builtin): Change memory
4285 operand to XI, extend p0 to Pmode.
4286 * config/i386/i386.md: Change unspec volatile and operand
4287 1 mode to XI, change operand 0 mode to P.
4288
4289 2018-04-25 Jakub Jelinek <jakub@redhat.com>
4290
4291 * DEV-PHASE: Set to prerelease.
4292
4293 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
4294
4295 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
4296 in __abskf2 and __powikf2.
4297
4298 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4299
4300 PR target/85512
4301 * config/aarch64/constraints.md (Usg, Usj): New constraints.
4302 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
4303 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
4304 Use the above on operand 2. Reindent.
4305 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
4306
4307 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
4308
4309 PR target/85485
4310 * common/config/i386/i386-common.c (ix86_handle_option): Don't
4311 handle OPT_mcet.
4312 * config/i386/i386.opt (mcet): Removed.
4313 * doc/install.texi: Remove -mcet documentation.
4314 * doc/invoke.texi: Likewise.
4315
4316 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
4317
4318 PR target/85485
4319 * doc/install.texi: Remove -mcet from bootstrap-cet.
4320
4321 2018-04-24 Jakub Jelinek <jakub@redhat.com>
4322
4323 PR target/85511
4324 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
4325 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
4326 if TARGET_64BIT.
4327
4328 PR target/85503
4329 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
4330 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
4331 containing a CONST_VECTOR.
4332
4333 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
4334
4335 * doc/install.texi: Update newlib dependency for nvptx.
4336
4337 2018-04-24 Jakub Jelinek <jakub@redhat.com>
4338
4339 PR target/85508
4340 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
4341 instead of INTVAL when shifting x left.
4342
4343 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
4344
4345 PR tree-optimization/85478
4346 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
4347 vect_grouped_store_supported for single element vectors.
4348
4349 2018-04-24 Richard Biener <rguenther@suse.de>
4350
4351 PR target/85491
4352 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
4353 load cost increase to the case of non-constant step.
4354
4355 2018-04-24 Jakub Jelinek <jakub@redhat.com>
4356
4357 PR target/84828
4358 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
4359 destination if any_malformed_asm.
4360
4361 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
4362
4363 PR middle-end/85496
4364 * expr.c (store_field): In the bitfield case, if the value comes from
4365 a function call and is returned in registers by means of a PARALLEL,
4366 do not change the mode of the temporary unless BLKmode and VOIDmode.
4367
4368 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
4369
4370 PR rtl-optimization/85423
4371 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
4372 dependencies to debug insns when the previous insn is non-debug.
4373
4374 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
4375
4376 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
4377 enums into a single definition.
4378 (fls): Fix predicates and printing.
4379 (seti): Likewise.
4380
4381 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
4382
4383 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
4384 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
4385 and short u6 immediate.
4386 (check_if_valid_sleep_operand): Remove.
4387 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
4388
4389 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4390
4391 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
4392 flag_always_save_lp condition.
4393 * config/nds32/nds32.opt (malways-save-lp): New option.
4394
4395 2018-04-22 Shiva Chen <shiva0217@gmail.com>
4396
4397 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
4398 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
4399 * config/nds32/nds32.h
4400 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
4401 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
4402
4403 2018-04-22 Shiva Chen <shiva0217@gmail.com>
4404
4405 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
4406 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
4407
4408 2018-04-22 Shiva Chen <shiva0217@gmail.com>
4409 Chung-Ju Wu <jasonwucj@gmail.com>
4410
4411 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
4412 Declare.
4413 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
4414 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
4415
4416 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4417
4418 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
4419
4420 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4421
4422 * config/nds32/nds32-protos.h (nds32_data_alignment,
4423 nds32_local_alignment): Declare.
4424 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
4425 nds32_local_alignment): New functions.
4426 (TARGET_CONSTANT_ALIGNMENT): Define.
4427 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
4428
4429 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4430
4431 * config/nds32/nds32.c
4432 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
4433 (TARGET_MODES_TIEABLE_P): Likewise.
4434
4435 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
4436
4437 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
4438 level Ofast and Og.
4439
4440 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
4441 Chung-Ju Wu <jasonwucj@gmail.com>
4442
4443 * config/nds32/constants.md (unspec_volatile_element): Add enum values
4444 for unaligned access.
4445 * config/nds32/nds32-intrinsic.c: Implementation of expanding
4446 unaligned access.
4447 * config/nds32/nds32-intrinsic.md: Likewise.
4448 * config/nds32/nds32_intrinsic.h: Likewise.
4449 * config/nds32/nds32.h (nds32_builtins): Likewise.
4450 * config/nds32/nds32.opt (munaligned-access): New option.
4451 * config/nds32/nds32.c (nds32_asm_file_start): Display
4452 flag_unaligned_access status.
4453
4454 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
4455
4456 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
4457 -mno-relax is present.
4458 * config/riscv/linux.h (LINK_SPEC): Ditto.
4459
4460 2018-04-20 Martin Sebor <msebor@redhat.com>
4461
4462 PR c/85365
4463 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
4464 for null pointers.
4465 (gimple_fold_builtin_stxcpy_chk): Same.
4466 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
4467
4468 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
4469
4470 PR target/85456
4471 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
4472 __powikf2 when long double is IEEE 128-bit.
4473
4474 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
4475
4476 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
4477 step to make sure stack always aligned.
4478
4479 2018-04-20 Carl Love <cel@us.ibm.com>
4480
4481 PR target/83402
4482 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
4483 size check for arg0.
4484
4485 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
4486 Tom de Vries <tom@codesourcery.com>
4487
4488 PR target/85445
4489 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
4490 Emit insns for calls too.
4491 (nvptx_find_par): Always look for worker-level predecessor insn.
4492 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
4493 calls.
4494 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
4495 (nvptx_process_pars): Propagate frames for calls.
4496
4497 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
4498
4499 PR target/85469
4500 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
4501 Removed.
4502 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
4503 (ix86_handle_option): Don't handle OPT_mibt.
4504 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
4505 __SHSTK__.
4506 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
4507 has_ibt and ibt.
4508 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
4509 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
4510 (ix86_target_macros): Define __CET__ with flag_cf_protection
4511 for -fcf-protection.
4512 * config/i386/i386.c (isa2_opts): Remove -mibt.
4513 * config/i386/i386.h (TARGET_IBT): Removed.
4514 (TARGET_IBT_P): Likewise.
4515 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
4516 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
4517 * config/i386/i386.opt (mcet): Update help message.
4518 (mshstk): Likewise.
4519 (mibt): Removed.
4520 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
4521 -mcet as an alias for -mshstk.
4522
4523 2018-04-20 Richard Biener <rguenther@suse.de>
4524
4525 PR middle-end/85475
4526 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
4527 complexity by forcing a single use of the multiply operand.
4528
4529 2018-04-20 Martin Jambor <mjambor@suse.cz>
4530
4531 ipa/85449
4532 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
4533 recursion dependency to only apply to non-clones.
4534
4535 2018-04-20 Martin Jambor <mjambor@suse.cz>
4536
4537 ipa/85447
4538 * ipa-cp.c (create_specialized_node): Check that clones of
4539 self-recursive edges exist during IPA-CP.
4540
4541 2018-04-19 Toon Moene <toon@moene.org>
4542
4543 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
4544 by -O3.
4545
4546 2018-04-19 Jakub Jelinek <jakub@redhat.com>
4547
4548 PR tree-optimization/85467
4549 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
4550 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
4551 VECTOR_CST element to type.
4552
4553 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
4554
4555 PR target/85397
4556 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
4557 * config/i386/i386.md (builtin_setjmp_setup): Removed.
4558 (builtin_longjmp): Likewise.
4559 (save_stack_nonlocal): New pattern.
4560 (restore_stack_nonlocal): Likewise.
4561
4562 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
4563
4564 PR target/85404
4565 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
4566 Replace ASM_OUTPUT_LABEL with fprintf.
4567
4568 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
4569
4570 PR target/85417
4571 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
4572 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
4573 * config/i386/i386-c.c (ix86_target_macros_internal): Also
4574 define __IBT__ and __SHSTK__ for -fcf-protection.
4575 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
4576 TARGET_IBT.
4577 (ix86_trampoline_init): Likewise.
4578 (x86_output_mi_thunk): Likewise.
4579 (ix86_notrack_prefixed_insn_p): Likewise.
4580 (ix86_option_override_internal): Don't disallow -fcf-protection.
4581 * config/i386/i386.md (rdssp<mode>): Also enable for
4582 -fcf-protection.
4583 (incssp<mode>): Likewise.
4584 (nop_endbr): Likewise.
4585 * config/i386/i386.opt (mcet): Change help message to built-in
4586 functions only.
4587 (mibt): Likewise.
4588 (mshstk): Likewise.
4589 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
4590 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
4591 enable CET built-in functions.
4592
4593 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
4594
4595 * common/config/i386/i386-common.c
4596 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
4597 OPTION_MASK_ISA_MOVDIRI_UNSET,
4598 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
4599 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
4600 * config.gcc (movdirintrin.h): New header.
4601 * config/i386/cpuid.h (bit_MOVDIRI,
4602 bit_MOVDIR64B): New bits.
4603 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
4604 and -mmvodir64b.
4605 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
4606 (VOID, PVOID, PCVOID)): New function types.
4607 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
4608 __builtin_ia32_directstoreu_u64,
4609 __builtin_ia32_movdir64b): New builtins.
4610 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
4611 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
4612 and -mmovdiri.
4613 (ix86_valid_target_attribute_inner_p): Ditto.
4614 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
4615 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
4616 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
4617 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
4618 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
4619 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
4620 (movdiri<mode>, movdir64b_<mode>): New.
4621 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
4622 * config/i386/immintrin.h: Include movdirintrin.h.
4623 * config/i386/movdirintrin.h: New file.
4624 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
4625
4626 2018-04-19 Richard Biener <rguenther@suse.de>
4627
4628 PR middle-end/85455
4629 * cfg.c (clear_bb_flags): When loop state says we have
4630 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
4631
4632 2018-04-19 Richard Biener <rguenther@suse.de>
4633
4634 PR tree-optimization/84737
4635 * tree-vect-data-refs.c (vect_copy_ref_info): New function
4636 copying restrict info.
4637 (vect_setup_realignment): Use it.
4638 * tree-vectorizer.h (vect_copy_ref_info): Declare.
4639 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
4640 the first DR to all generated stores.
4641 (vectorizable_load): Likewise for loads.
4642
4643 2018-04-19 Jakub Jelinek <jakub@redhat.com>
4644
4645 PR tree-optimization/85446
4646 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
4647 the integral and pointer types to have the same precision.
4648
4649 * doc/install.texi: Document --disable-cet being the default and
4650 --enable-cet=auto.
4651
4652 2018-04-18 Martin Liska <mliska@suse.cz>
4653
4654 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
4655 style.
4656
4657 2018-04-18 Martin Liska <mliska@suse.cz>
4658
4659 Revert
4660 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
4661
4662 PR ipa/83983
4663 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
4664 arguments if they are comparable.
4665
4666 2018-04-18 Martin Liska <mliska@suse.cz>
4667
4668 Revert
4669 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
4670
4671 PR lto/84805
4672 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
4673 incomplete types.
4674
4675 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
4676
4677 PR target/85388
4678 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
4679 ENDBR after calling __morestack.
4680
4681 2018-04-18 David Malcolm <dmalcolm@redhat.com>
4682
4683 PR jit/85384
4684 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
4685 by using gcc_base_ver to generate a gcc_driver_version, and use
4686 it when generating GCC_DRIVER_NAME.
4687 * configure: Regenerate.
4688
4689 2018-04-18 Jakub Jelinek <jakub@redhat.com>
4690
4691 PR target/81084
4692 * config.gcc: Obsolete powerpc*-*-*spe*.
4693
4694 2018-04-17 Jakub Jelinek <jakub@redhat.com>
4695
4696 PR debug/84637
4697 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
4698 (stabstr_D): Change type of unum from unsigned int to
4699 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
4700 type.
4701
4702 2018-04-17 Jim Wilson <jimw@sifive.com>
4703
4704 PR 84856
4705 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
4706 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
4707 Set arg_pointer_offset after using pretend_args_size.
4708
4709 2018-04-17 Jakub Jelinek <jakub@redhat.com>
4710
4711 PR rtl-optimization/85431
4712 * dse.c (record_store): Ignore zero width stores.
4713
4714 PR sanitizer/85230
4715 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
4716 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
4717 __builtin_stack_restore rather than after it.
4718 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
4719 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
4720 argument instead of virtual_dynamic_stack_rtx.
4721
4722 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
4723
4724 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
4725 New prototype.
4726 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
4727 Add note to error message to explain internal mapping of overloaded
4728 built-in function name to non-overloaded built-in function name.
4729 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
4730 function.
4731
4732 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
4733
4734 PR target/85424
4735 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
4736 where the inputs overlap with the output.
4737
4738 2018-04-17 Jakub Jelinek <jakub@redhat.com>
4739
4740 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
4741 (=v, v) alternative and explicit "memory" attribute.
4742 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
4743 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
4744 attributes.
4745 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
4746 "sselog1" type instead of "sselog".
4747 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
4748 "sselog". Remove explicit "memory" attribute.
4749 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
4750 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
4751 attributes.
4752 (vec_extract_hi_v32hi): Merge all alternatives into one, use
4753 "sselog1" type instead of "sselog". Remove explicit "memory"
4754 attribute.
4755 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
4756 use "sselog1" type instead of "sselog". Remove explicit "memory"
4757 attribute.
4758 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
4759 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
4760 attributes.
4761 (vec_extract_hi_v64qi): Merge all alternatives into one, use
4762 "sselog1" type instead of "sselog". Remove explicit "memory"
4763 attribute.
4764 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
4765 use "sselog1" type instead of "sselog". Remove explicit "memory"
4766 attribute.
4767
4768 PR target/85430
4769 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
4770
4771 PR middle-end/85414
4772 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
4773 on a SUBREG.
4774
4775 2018-04-17 Martin Jambor <mjambor@suse.cz>
4776
4777 PR ipa/85421
4778 * ipa-cp.c (create_specialized_node): Call
4779 expand_all_artificial_thunks if necessary.
4780
4781 2018-04-17 Martin Liska <mliska@suse.cz>
4782
4783 PR lto/85405
4784 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
4785 in message, remote space in between '_G' and '('.
4786
4787 2018-04-17 Jakub Jelinek <jakub@redhat.com>
4788
4789 PR target/85281
4790 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
4791 avx512f_vmcmp<mode>3<round_saeonly_name>,
4792 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
4793 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
4794 avx512f_rndscale<mode><round_saeonly_name>,
4795 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
4796 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
4797 Use %<iptr>2 instead of %2 for -masm=intel.
4798 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
4799 avx512f_vcvttss2usi<round_saeonly_name>,
4800 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
4801 -masm=intel.
4802 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
4803 avx512f_vcvttsd2usi<round_saeonly_name>,
4804 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
4805 Use %q1 instead of %1 for -masm=intel.
4806 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
4807 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
4808 of %3 for -masm=intel.
4809 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
4810 -masm=intel.
4811 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
4812 -masm=intel.
4813 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
4814 -masm=intel.
4815 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
4816 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
4817 %g1.
4818 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
4819 -masm=intel.
4820 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
4821 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
4822 %g1 and one with %0 and %1.
4823 (avx512er_vmrcp28<mode><round_saeonly_name>,
4824 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
4825 %1 for -masm=intel.
4826 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
4827 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
4828 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
4829 of %0 and %{%4%} for -masm=intel.
4830 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
4831 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
4832 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
4833 order of %0 and %{%5%}%{z%} for -masm=intel.
4834
4835 2018-04-17 Jan Hubicka <jh@suse.cz>
4836
4837 PR lto/85405
4838 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
4839
4840 2018-04-17 Martin Liska <mliska@suse.cz>
4841
4842 PR ipa/85329
4843 * multiple_target.c (create_dispatcher_calls): Set apostrophes
4844 for target_clone error message. Make default implementation
4845 clone to be a local declaration.
4846 (separate_attrs): Add new argument and check for an empty
4847 string.
4848 (expand_target_clones): Handle it.
4849 (ipa_target_clone): Make redirection just for target_clones
4850 functions.
4851
4852 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
4853 Tom de Vries <tom@codesourcery.com>
4854
4855 PR middle-end/84955
4856 * omp-expand.c (expand_oacc_for): Add dummy false branch for
4857 tiled basic blocks without omp continue statements.
4858
4859 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
4860
4861 PR target/83660
4862 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
4863 vec_extract expression as having side effects to make sure it gets
4864 a cleanup point.
4865
4866 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
4867
4868 PR target/85403
4869 * config/i386/i386.c (get_builtin_code_for_version): Check
4870 error_mark_node.
4871
4872 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
4873
4874 PR target/84331
4875 * gcc/config.gcc: Support "skylake".
4876 * gcc/config/i386/i386-c.c (ix86_target_macros_internal): Handle
4877 PROCESSOR_SKYLAKE.
4878 * gcc/config/i386/i386.c (m_SKYLAKE): Define.
4879 (processor_target_table): Add "skylake".
4880 (ix86_option_override_internal): Add "skylake".
4881 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
4882 PROCESSOR_CANNONLAKE.
4883 (get_builtin_code_for_version): Fix priority for
4884 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
4885 PROCESSOR_SKYLAKE-AVX512.
4886 * gcc/config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
4887 (processor_type): Add PROCESSOR_SKYLAKE.
4888
4889 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
4890 Jason Merrill <jason@redhat.com>
4891
4892 PR c++/85112
4893 * convert.c (convert_to_integer_1): Use direct recursion for
4894 enumeral types and types with a precision less than the number
4895 of bits in their mode.
4896
4897 2018-04-16 Julia Koval <julia.koval@intel.com>
4898
4899 PR target/84413
4900 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
4901 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
4902
4903 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
4904
4905 PR target/85293
4906 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
4907 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
4908 and -mno-direct-move.
4909
4910 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
4911
4912 PR target/83402
4913 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
4914 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
4915 Ensure negative shifts result in {0}.
4916
4917 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
4918
4919 PR rtl-optimization/79916
4920 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
4921 regs (if any) to define how to gnerate SD moves when LRA is in
4922 progress.
4923
4924 2018-04-13 Jakub Jelinek <jakub@redhat.com>
4925
4926 PR rtl-optimization/85393
4927 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
4928 * except.c (expand_dw2_landing_pad_for_region): Make static.
4929 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
4930 a label and unconditional jump to old_bb, rather than
4931 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
4932 basic block.
4933
4934 PR rtl-optimization/85376
4935 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
4936 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
4937 instead of a specific value.
4938
4939 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
4940 Bin Cheng <bin.cheng@arm.com>
4941
4942 PR tree-optimization/82965
4943 PR tree-optimization/83991
4944 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
4945 by_profile_only parameter.
4946 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
4947 information if the loop was predicted to iterate too many times.
4948 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
4949
4950 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
4951
4952 PR lto/71991
4953 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
4954 always inline.
4955
4956 2018-04-13 Martin Liska <mliska@suse.cz>
4957 Jakub Jelinek <jakub@redhat.com>
4958
4959 PR middle-end/81657
4960 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
4961 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
4962 * builtins.c (expand_builtin_memory_copy_args): Use
4963 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
4964 handle dest_addr == pc_rtx.
4965
4966 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
4967
4968 PR target/85291
4969 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
4970 asked to not generate direct moves.
4971 (fix_trunc<mode>si2_stfiwx): Similar.
4972 (fix_trunc<mode>si2_internal): Similar.
4973
4974 2018-04-12 Jakub Jelinek <jakub@redhat.com>
4975
4976 PR debug/83157
4977 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
4978 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
4979 lookup if dest in some wider mode is known to be const0_rtx and
4980 if so, record permanent equivalence for it to be ZERO_EXTEND of
4981 the narrower mode destination.
4982
4983 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
4984
4985 * lto-streamer-out.c (output_function): Revert 259346.
4986 * omp-expand.c (expand_oacc_for): Likewise.
4987
4988 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
4989
4990 PR rtl-optimization/85354
4991 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
4992 * sel-sched.c (sel_global_init): ... here.
4993
4994 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
4995
4996 PR target/85238
4997 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
4998 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
4999 mode for PE-COFF targets.
5000 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
5001 (i386_pe_asm_lto_end): Likewise.
5002 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
5003 (TARGET_ASM_LTO_END): Likewise.
5004 * config/i386/winnt.c (saved_debug_info_level): New static variable.
5005 (i386_pe_asm_lto_start): New function.
5006 (i386_pe_asm_lto_end): Likewise.
5007
5008 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
5009 Richard Biener <rguenther@suse.de>
5010
5011 PR middle-end/84955
5012 * lto-streamer-out.c (output_function): Fix CFG loop state before
5013 streaming out.
5014 * omp-expand.c (expand_oacc_for): Handle calls to internal
5015 functions like regular functions.
5016
5017 2018-04-12 Richard Biener <rguenther@suse.de>
5018
5019 PR lto/85371
5020 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
5021 for the early LTO debug to properly generate references to it
5022 during DIE emission. Do not re-use that for the skeleton for
5023 split-dwarf.
5024 (dwarf2out_early_finish): Likewise.
5025
5026 2018-04-12 Jakub Jelinek <jakub@redhat.com>
5027
5028 PR target/85328
5029 * config/i386/sse.md
5030 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
5031 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
5032 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
5033 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
5034 and output is a reg, avoid creating invalid lowpart subreg, but
5035 instead split into a 512-bit move. Don't split if not AVX512VL,
5036 input is xmm16+ reg and output is a mem.
5037 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
5038 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
5039 xmm16+ reg and output is a mem.
5040
5041 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
5042
5043 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
5044 also for flag_dwarf2_cfi_asm.
5045
5046 2018-04-12 Jakub Jelinek <jakub@redhat.com>
5047
5048 PR rtl-optimization/85342
5049 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
5050 a bool scalar var inside of the loop instead. Don't try to update
5051 recog_data.operand after failed apply_change_group.
5052
5053 2018-04-12 Tom de Vries <tom@codesourcery.com>
5054
5055 PR target/85296
5056 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
5057 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
5058 array with flexible array member as array without given dimension.
5059 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
5060 argument for undefined param to true.
5061
5062 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
5063
5064 PR target/85321
5065 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
5066 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
5067 from PowerPC section.
5068 * config/rs6000/sysv4.opt (mcall-): Improve help text.
5069 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
5070 help text that is too long.
5071 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
5072 help text that is too long.
5073 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
5074 help text that is too long.
5075
5076 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
5077
5078 * config/alpha/alpha.md (stack_probe_internal): Rename
5079 from "probe_stack". Update all callers.
5080
5081 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
5082
5083 PR rtl-optimization/84566
5084 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
5085 sched_macro_fuse_insns.
5086
5087 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
5088
5089 PR target/84301
5090 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
5091 (compute_block_dependences): ... from here.
5092
5093 2018-04-11 Jakub Jelinek <jakub@redhat.com>
5094
5095 PR tree-optimization/85331
5096 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
5097 from int to HOST_WIDE_INT.
5098
5099 2018-04-11 Martin Jambor <mjambor@suse.cz>
5100
5101 PR ipa/84149
5102 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
5103 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
5104 not the same as the source val.
5105 (cgraph_edge_brings_value_p): New parameter.
5106 (gather_edges_for_value): Pass destination value to
5107 cgraph_edge_brings_value_p.
5108 (perhaps_add_new_callers): Likewise.
5109 (get_info_about_necessary_edges): Likewise and exclude values brought
5110 only by self-recursive edges.
5111 (create_specialized_node): Redirect only clones of self-calling edges.
5112 (+self_recursive_pass_through_p): New function.
5113 (find_more_scalar_values_for_callers_subset): Use it.
5114 (find_aggregate_values_for_callers_subset): Likewise.
5115 (known_aggs_to_agg_replacement_list): Removed.
5116 (decide_whether_version_node): Re-calculate known constants for all
5117 remaining context clones.
5118
5119 2018-04-11 Richard Biener <rguenther@suse.de>
5120
5121 PR lto/85339
5122 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
5123 from early DWARF output.
5124 (dwarf2out_early_finish): Output line info unconditionally into
5125 early DWARF and add reference to it.
5126
5127 2018-04-11 Jakub Jelinek <jakub@redhat.com>
5128
5129 PR target/85281
5130 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
5131 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
5132 other than V2DFmode using iptr mode attribute.
5133 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
5134
5135 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
5136
5137 PR rtl-optimization/84659
5138 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
5139
5140 2018-04-11 Jakub Jelinek <jakub@redhat.com>
5141
5142 PR debug/85302
5143 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
5144 SIZEP is NULL.
5145 (output_loc_list): Pass address of a dummy size variable even in the
5146 locview handling loop.
5147 (index_location_lists): Add comment on why skip_loc_list_entry can't
5148 call size_of_locs.
5149
5150 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
5151
5152 PR target/85261
5153 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
5154 into register.
5155
5156 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
5157
5158 PR target/85321
5159 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
5160 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
5161 and -mstring-compare-inline-limit.
5162
5163 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
5164
5165 PR target/85287
5166 * gcc/config/rs6000/rs6000.md (allocate_stack): Put the residual size
5167 for stack clash protection in a register whenever we need it to be in
5168 a register.
5169
5170 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
5171
5172 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
5173 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
5174
5175 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
5176
5177 PR target/85321
5178 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
5179 the help text.
5180 (mlong-double-): Ditto.
5181 * config/rs6000/sysv4.opt (msdata=): Ditto.
5182 (mtls-size=): Ditto.
5183
5184 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
5185
5186 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
5187 erroneous entries for
5188 "vector int vec_ldl (int, long int *)", and
5189 "vector unsigned int vec_ldl (int, unsigned long int *)".
5190 Add comments and entries for
5191 "vector bool char vec_ldl (int, bool char *)",
5192 "vector bool short vec_ldl (int, bool short *)",
5193 "vector bool int vec_ldl (int, bool int *)",
5194 "vector bool long long vec_ldl (int, bool long long *)",
5195 "vector pixel vec_ldl (int, pixel *)",
5196 "vector long long vec_ldl (int, long long *)",
5197 "vector unsigned long long vec_ldl (int, unsigned long long *)".
5198 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
5199 type tree bool_long_long_type_node and correct definition of
5200 bool_V2DI_type_node to make reference to this new type tree.
5201 (rs6000_mangle_type): Replace erroneous reference to
5202 bool_long_type_node with bool_long_long_type_node.
5203 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
5204 comments to emphasize sign distinctions for char and int types and
5205 replace RS6000_BTI_bool_long constant with
5206 RS6000_BTI_bool_long_long constant. Also add comment to restrict
5207 use of RS6000_BTI_pixel.
5208 (bool_long_type_node): Remove this macro definition.
5209 (bool_long_long_type_node): New macro definition
5210
5211 2018-04-10 Jakub Jelinek <jakub@redhat.com>
5212
5213 PR rtl-optimization/85300
5214 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
5215 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
5216 simplify_unary_operation fails.
5217
5218 2018-04-10 Martin Liska <mliska@suse.cz>
5219
5220 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
5221 cgraph_edge and ipa_ref.
5222
5223 2018-04-10 Jakub Jelinek <jakub@redhat.com>
5224
5225 PR target/85177
5226 PR target/85255
5227 * config/i386/sse.md
5228 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
5229 computation of the VEC_MERGE selector from mask.
5230 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
5231 Fix decoding of the VEC_MERGE selector into mask.
5232
5233 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
5234
5235 PR tree-optimization/85286
5236 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
5237
5238 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
5239
5240 * final.c (final_1): Set insn_last_address as well as
5241 insn_current_address.
5242
5243 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5244
5245 PR target/85173
5246 * explow.c (emit_stack_probe): Call validize_mem on memory location
5247 before passing it to gen_probe_stack. Create address operand and
5248 legitimize it for the probe_stack_address case.
5249
5250 2018-04-09 Jan Hubicka <jh@suse.cz>
5251
5252 PR lto/85078
5253 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
5254 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
5255 * tree.c (free_lang_data_in_type): Fix handling of binfos;
5256 walk basetypes.
5257 (free_lang_data): Rebuild type inheritance graph.
5258
5259 2018-04-09 Martin Sebor <msebor@redhat.com>
5260
5261 * invoke.texi (-finline-small-functions): Mention other optimization
5262 options.
5263 (-findirect-inlining, -fpartial-inlining): Same.
5264 (-finline-functions-called-once): Same.
5265 (-freorder-blocks-and-partition): Same.
5266
5267 2018-04-09 Jan Hubicka <jh@suse.cz>
5268
5269 PR rtl/84058
5270 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
5271 jumps; choose last target that matches the criteria (i.e.
5272 no partition changes for non-crossing jumps).
5273 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
5274 support for redirecting crossing jumps to non-crossing.
5275
5276 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
5277
5278 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
5279 also for naked functions.
5280
5281 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
5282
5283 * config/arc/arc.md (add_shift): New pattern.
5284 (add_shift2): Likewise.
5285 (sub_shift): Likewise.
5286 (sub_shift_cmp0_noout): Likewise.
5287 (compare_si_ashiftsi): Likewise.
5288 (xbfu_cmp0_noout): New combine pattern.
5289 (xbfu_cmp0"): Likewise.
5290 (movsi_set_cc_insn): Place the predicable variant first.
5291 (commutative_binary_cmp0_noout): Remove clobber.
5292 (commutative_binary_cmp0): New pattern.
5293 (noncommutative_binary_cmp0): Likewise.
5294 (noncommutative_binary_cmp0_noout): Likewise.
5295 (noncommutative_binary_comparison_result_used): Removed.
5296 (rsub_cmp0): New pattern.
5297 (rsub_cmp0_noout): Likewise.
5298 (extzvsi): Changed, keep only meaningful variants.
5299 (SQH, SEZ): New iterators.
5300 (SQH_postfix): New mode attribute.
5301 (SEZ_prefix): New code attribute.
5302 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
5303 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
5304 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
5305 of numerical value.
5306 (noncommutative_operator): Check the availability of barrel
5307 shifter option.
5308
5309 2018-04-09 Richard Biener <rguenther@suse.de>
5310
5311 PR tree-optimization/85284
5312 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
5313 Only use the niter constraining form of simple_iv when the exit
5314 is always executed.
5315
5316 2018-04-09 Tom de Vries <tom@codesourcery.com>
5317
5318 PR target/84041
5319 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
5320 (define_expand "*memory_barrier"): New define_expand.
5321 (define_insn "memory_barrier"): New insn.
5322
5323 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
5324
5325 PR rtl-optimization/80463
5326 PR rtl-optimization/83972
5327 PR rtl-optimization/83480
5328
5329 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
5330 correct producer for the insn.
5331 (tidy_control_flow): Fixup seqnos in case of debug insns.
5332
5333 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
5334
5335 PR rtl-optimization/83913
5336
5337 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
5338 different sched-times when merging exprs.
5339
5340 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
5341
5342 PR rtl-optimization/83962
5343
5344 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
5345 tidy_fallthru_edge and tidy_control_flow.
5346
5347 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
5348
5349 PR rtl-optimization/83530
5350
5351 * sel-sched.c (force_next_insn): New global variable.
5352 (remove_insn_for_debug): When force_next_insn is true, also leave only
5353 next insn in the ready list.
5354 (sel_sched_region): When the region wasn't scheduled, make another pass
5355 over it with force_next_insn set to 1.
5356
5357 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
5358
5359 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
5360 into tm_file.
5361 * config/nds32/constants.md (unspec_volatile_element): Add enum values
5362 for interrupt control.
5363 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
5364 functions for interrupt control.
5365 * config/nds32/nds32-intrinsic.md: Likewise.
5366 * config/nds32/nds32_intrinsic.h: Likewise.
5367 * config/nds32/nds32.h (nds32_builtins): Likewise.
5368
5369 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
5370
5371 * config/nds32/nds32.c (nds32_init_machine_status,
5372 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
5373 strict_aligned_p field.
5374 (nds32_expand_to_rtl_hook): New function.
5375 (TARGET_EXPAND_TO_RTL_HOOK): Define.
5376 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
5377
5378 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
5379 Chung-Ju Wu <jasonwucj@gmail.com>
5380
5381 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
5382 * config/nds32/nds32-n7.md: New file.
5383 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
5384 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
5385 pipeline.
5386 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
5387 * config/nds32/nds32.md (pipeline_model): Add n7.
5388 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
5389 * config/nds32/pipelines.md: Include n7 settings.
5390
5391 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
5392 Chung-Ju Wu <jasonwucj@gmail.com>
5393
5394 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
5395 * config/nds32/nds32-e8.md: New file.
5396 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
5397 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
5398 pipeline.
5399 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
5400 * config/nds32/nds32.md (pipeline_model): Add e8.
5401 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
5402 * config/nds32/pipelines.md: Include e8 settings.
5403
5404 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
5405 Chung-Ju Wu <jasonwucj@gmail.com>
5406
5407 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
5408 * config/nds32/nds32-n8.md: New file.
5409 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
5410 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
5411 pipeline.
5412 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
5413 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
5414 * config/nds32/nds32.md (pipeline_model): Add n8.
5415 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
5416 * config/nds32/pipelines.md: Include n8 settings.
5417
5418 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
5419 Chung-Ju Wu <jasonwucj@gmail.com>
5420
5421 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
5422 * config/nds32/nds32-n9-2r1w.md: New file.
5423 * config/nds32/nds32-n9-3r2w.md: New file.
5424 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
5425 nds32_register_ports): New or modify for cpu n9.
5426 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
5427 pipeline.
5428 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
5429 * config/nds32/nds32-utils.c: New file.
5430 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
5431 TARGET_MUL_SLOW): Define.
5432 * config/nds32/nds32.md (pipeline_model): New attribute.
5433 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
5434 New options that support cpu n9.
5435 * config/nds32/pipelines.md: Include n9 settings.
5436 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
5437
5438 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
5439
5440 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
5441 information if necessary.
5442 (output_cond_branch_compare_zero): Likewise.
5443 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
5444 (nds32_target_alignment): Refine for alignment.
5445 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
5446 (FUNCTION_BOUNDARY): Modify.
5447 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
5448 align case.
5449 * config/nds32/nds32.opt (malways-align, malign-functions): New.
5450
5451 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
5452
5453 * config/nds32/constants.md (unspec_volatile_element): Add values for
5454 TLB operation and data prefetch.
5455 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
5456 functions for TLB operation and data prefetch.
5457 * config/nds32/nds32-intrinsic.md: Likewise.
5458 * config/nds32/nds32_intrinsic.h: Likewise.
5459 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
5460 (nds32_print_operand): Likewise.
5461 * config/nds32/nds32.h (nds32_builtins): Likewise.
5462
5463 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
5464 Andrew Pinski <pinsika@gcc.gnu.org>
5465
5466 PR middle-end/82976
5467 * match.pd: Use constant_boolean_node of correct type instead of
5468 boolean_true_node or boolean_false_node for simplifying
5469 pointer comparisons to zero.
5470
5471 2018-04-07 Jakub Jelinek <jakub@redhat.com>
5472
5473 PR tree-optimization/80021
5474 * tree.c (verify_type_variant): Make error call in verify_variant_match
5475 translatable and remove final full stop.
5476
5477 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
5478
5479 * config/nds32/constants.md (unspec_volatile_element): Add
5480 UNSPEC_VOLATILE_EH_RETURN.
5481 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
5482 nds32_output_stack_pop): Support dwarf exception handling process.
5483 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
5484 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
5485 exception handling process.
5486 (nds32_compute_stack_frame): Likewise.
5487 (nds32_return_addr_rtx): Likewise.
5488 (nds32_initial_elimination_offset): Likewise.
5489 (nds32_expand_prologue): Likewise.
5490 (nds32_expand_epilogue): Likewise.
5491 (nds32_dynamic_chain_address): New function.
5492 * config/nds32/nds32.h (machine_function): Add fields for dwarf
5493 exception handling.
5494 (DYNAMIC_CHAIN_ADDRESS): Define.
5495 (EH_RETURN_DATA_REGNO): Define.
5496 (EH_RETURN_STACKADJ_RTX): Define.
5497 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
5498 patterns for dwarf exception handling.
5499
5500 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
5501
5502 * config/nds32/nds32.h: Clean up obsolete macros.
5503
5504 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5505
5506 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
5507 Add enum values for particular instructions.
5508 * config/nds32/nds32-intrinsic.c: Implementation of expanding
5509 particular intrinsic functions.
5510 * config/nds32/nds32-intrinsic.md: Likewise.
5511 * config/nds32/nds32_intrinsic.h: Likewise.
5512 * config/nds32/nds32.h (nds32_builtins): Likewise.
5513 * config/nds32/nds32.md (type): Add pbsad and pbsada.
5514 (btst, ave): New patterns for particular instructions.
5515
5516 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5517
5518 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
5519 Add enum values for atomic load/store and memory sync.
5520 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
5521 and memory sync.
5522 * config/nds32/nds32-intrinsic.md: Likewise.
5523 * config/nds32/nds32_intrinsic.h: Likewise.
5524 * config/nds32/nds32.h (nds32_builtins): Likewise.
5525
5526 2018-04-07 Jakub Jelinek <jakub@redhat.com>
5527
5528 PR tree-optimization/85257
5529 * fold-const.c (native_encode_vector): If not all elts could fit
5530 and off is -1, return 0 rather than offset.
5531 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
5532 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
5533 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
5534 adjust buffer in native_interpret_expr call.
5535
5536 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5537
5538 * config/nds32/constants.md (unspec_volatile_element): Add cache
5539 control enum values.
5540 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
5541 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
5542 * config/nds32/nds32.c (nds32_cctl_names): New.
5543 (nds32_print_operand): Handle cache control register names.
5544 * config/nds32/nds32.h (nds32_builtins): New enum values.
5545 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
5546 macros.
5547 * config/nds32/nds32.md (type): Add mmu.
5548 * config/nds32/pipelines.md (simple_insn): Add mmu.
5549
5550 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
5551
5552 * config/nds32/nds32.md (type): Remove call.
5553 * config/nds32/pipelines.md (simple_insn): Likewise.
5554
5555 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5556
5557 * config/nds32/constants.md (unspec_volatile_element): Add
5558 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
5559 UNSPEC_VOLATILE_FMFCFG.
5560 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
5561 description for fmfcfg and fmfcsr.
5562 (bdesc_1arg): Add fmtcsr.
5563 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
5564 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
5565 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
5566 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
5567 unspec_fmfcfg): New patterns.
5568 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
5569 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
5570 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
5571 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
5572 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
5573 __nds32__fmfcfg): Define.
5574
5575 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
5576
5577 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
5578 intrinsic register names.
5579 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
5580 intrinsic register enum values and macros.
5581
5582 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
5583
5584 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
5585 for load/store addressing form.
5586 (nds32_print_operand_address): Likewise.
5587
5588 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
5589
5590 PR target/85196
5591 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
5592 based on LABEL_REF. Remove useless assertion.
5593 (pic_address_needs_scratch): Fix formatting.
5594 (sparc_legitimize_pic_address): Minor tweaks.
5595 (sparc_delegitimize_address): Adjust assertion accordingly.
5596 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
5597 into symbolic_operand.
5598 (movsi_high_pic_label_ref): Likewise.
5599 (movsi_lo_sum_pic_label_ref): Likewise.
5600 (movdi_pic_label_ref): Likewise.
5601 (movdi_high_pic_label_ref): Likewise.
5602 (movdi_lo_sum_pic_label_ref): Likewise.
5603
5604 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
5605
5606 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
5607 custom LIB_SPEC setup.
5608
5609 2018-04-06 Ruslan Bukin <br@bsdpad.com>
5610 Kito Cheng <kito.cheng@gmail.com>
5611
5612 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
5613 * config/riscv/freebsd.h: New.
5614
5615 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
5616
5617 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
5618 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
5619 file.
5620
5621 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
5622 Kito Cheng <kito.cheng@gmail.com>
5623
5624 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
5625 nds32_output_call, nds32_symbol_binds_local_p): New functions.
5626 * config/nds32/nds32-protos.h (nds32_output_call,
5627 nds32_output_return): Declare.
5628 * config/nds32/nds32.md: Refine all the call and return patterns.
5629
5630 2018-04-06 Jakub Jelinek <jakub@redhat.com>
5631
5632 PR debug/85252
5633 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
5634 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
5635
5636 PR rtl-optimization/84872
5637 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
5638 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
5639 EDGE_CROSSING edge.
5640
5641 2018-04-06 Tamar Christina <tamar.christina@arm.com>
5642
5643 * expr.c (copy_blkmode_to_reg): Revert 254862.
5644 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
5645
5646 2018-04-06 Richard Biener <rguenther@suse.de>
5647
5648 PR middle-end/85244
5649 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
5650 after seeing a component reference with an adjacent field. Treat
5651 refs to arrays at struct end of external decls similar to
5652 refs to unconstrained commons.
5653
5654 2018-04-06 Jakub Jelinek <jakub@redhat.com>
5655
5656 PR sanitizer/85213
5657 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
5658 look through SAVE_EXPRs with non-side-effects argument. Adjust
5659 recursive calls.
5660 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
5661 save_p here.
5662
5663 2018-04-06 Richard Biener <rguenther@suse.de>
5664
5665 PR middle-end/85180
5666 * alias.c (find_base_term): New wrapper around find_base_term
5667 unwinding CSELIB_VAL_PTR changes.
5668 (find_base_term): Do not restore CSELIB_VAL_PTR during the
5669 recursion.
5670
5671 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
5672
5673 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
5674 instructions.
5675 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
5676 constant definitions.
5677 ("nop"): lr 0,0 -> nopr r0
5678 ("nop_lr0", "nop_lr1"): New insn definitions.
5679
5680 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
5681
5682 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
5683 NDS32_V3PUSH_AVAILABLE_P macro.
5684
5685 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
5686 Chung-Ju Wu <jasonwucj@gmail.com>
5687
5688 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
5689 (nds32*-*-*): Add float and fpu_config into supported_defaults.
5690 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
5691 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
5692 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
5693 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
5694 * config/nds32/constraints.md: New constraints and checking for hard
5695 float configuration.
5696 * config/nds32/iterators.md: New mode iterator and attribute for hard
5697 float configuration.
5698 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
5699 patterns.
5700 * config/nds32/nds32-fpu.md: New file.
5701 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
5702 deal with hard float code generation.
5703 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
5704 ARCH_V3S.
5705 (abi_type, float_reg_number): New enum type.
5706 * config/nds32/nds32-predicates.c: New predicates for hard float.
5707 * config/nds32/nds32-protos.h: Declare functions for hard float.
5708 * config/nds32/nds32.c: Implementation for hard float configuration.
5709 * config/nds32/nds32.h: Definitions for hard float configuration.
5710 * config/nds32/nds32.md: Include hard float machine description and
5711 modify patterns for hard float configuration.
5712 * config/nds32/nds32.opt: New options for hard float configuration.
5713 * config/nds32/predicates.md: New predicates for hard float
5714 configuration.
5715
5716 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
5717
5718 * common/config/nds32/nds32-common.c
5719 (nds32_option_optimization_table): Enable -mreleax-hint by default.
5720
5721 2018-04-05 Jakub Jelinek <jakub@redhat.com>
5722
5723 PR middle-end/85195
5724 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
5725 CONSTRUCTOR_ELT (ctor, ...)->value.
5726
5727 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
5728
5729 PR target/85193
5730 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
5731
5732 2018-04-05 Tom de Vries <tom@codesourcery.com>
5733
5734 PR target/85204
5735 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
5736 cond jump.
5737
5738 2018-04-05 Shiva Chen <shiva0217@gmail.com>
5739 Kito Cheng <kito.cheng@gmail.com>
5740
5741 * config/nds32/constraints.md (U33): Fine-tune checking condition.
5742 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
5743 * config/nds32/nds32.h (nds32_16bit_address_type): Add
5744 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
5745
5746 2018-04-05 Shiva Chen <shiva0217@gmail.com>
5747 Kito Cheng <kito.cheng@gmail.com>
5748
5749 * config/nds32/constraints.md (Ufe): New memory constraint.
5750 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
5751 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
5752 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
5753 operands.
5754 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
5755 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
5756
5757 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5758
5759 * config/nds32/nds32.md: Use optimize_size in the condition for
5760 alu-shift instructions.
5761
5762 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5763
5764 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
5765
5766 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5767
5768 * config/nds32/nds32.md (negsi2): Refine pattern.
5769
5770 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
5771 Chung-Ju Wu <jasonwucj@gmail.com>
5772
5773 * config/nds32/iterators.md (shift_rotate): New code iterator.
5774 (shift): New code attribute.
5775 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
5776 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
5777 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
5778 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
5779 bit-wise operations.
5780 (andsi3, *andsi3): Ditto.
5781 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
5782 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
5783 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
5784 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
5785 nds32_ior_operand, nds32_xor_operand): New predicates.
5786
5787 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5788
5789 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
5790 (addsi3, subsi3): ... this.
5791
5792 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5793
5794 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
5795
5796 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5797
5798 * config/nds32/nds32.md: Adjust indention.
5799
5800 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
5801
5802 * config/nds32/nds32.md (feature): New attribute.
5803
5804 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
5805
5806 * config/nds32/nds32.md (subtype): New attribute.
5807
5808 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
5809
5810 PR target/85203
5811 * config/arm/arm-builtins.c (arm_expand_builtin): Change
5812 expansion to perform a bitwise AND of the argument followed by a
5813 boolean negation of the result.
5814
5815 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
5816
5817 PR rtl-optimization/84878
5818 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
5819 the basic block. Assert the use reference is not artificial and that
5820 it has an associated insn.
5821
5822 2018-04-04 Michael Matz <matz@suse.de>
5823
5824 * builtins.c (compute_objsize): Pass correct operand
5825 to array_at_struct_end_p.
5826
5827 2018-04-04 Richard Biener <rguenther@suse.de>
5828
5829 PR lto/85176
5830 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
5831 from contexts for DINFO_LEVEL_TERSE and below.
5832
5833 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
5834
5835 * config/nds32/nds32-doubleword.md (move_<mode>): Require
5836 resiter_operand condition.
5837 * config/nds32/nds32.md (*move<mode>): Ditto.
5838
5839 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
5840 Monk Chiang <sh.chiang04@gmail.com>
5841
5842 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
5843
5844 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
5845
5846 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
5847
5848 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
5849 Kito Cheng <kito.cheng@gmail.com>
5850
5851 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
5852 nds32_cond_code_str, output_cond_branch,
5853 output_cond_branch_compare_zero, nds32_expand_cbranch,
5854 nds32_expand_cstore, nds32_expand_movcc,
5855 nds32_output_cbranchsi4_equality_zero,
5856 nds32_output_cbranchsi4_equality_reg,
5857 nds32_output_cbranchsi4_equality_reg_or_const_int,
5858 nds32_output_cbranchsi4_greater_less_zero: New functions.
5859 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
5860 nds32_expand_cstore, nds32_expand_movcc,
5861 nds32_output_cbranchsi4_equality_zero,
5862 nds32_output_cbranchsi4_equality_reg,
5863 nds32_output_cbranchsi4_equality_reg_or_const_int,
5864 nds32_output_cbranchsi4_greater_less_zero): Declare.
5865 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
5866 nds32_rimm11s_operand): New predicates.
5867 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
5868 * config/nds32/nds32.md: Rewrite all the branch and conditional move
5869 patterns.
5870
5871 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
5872
5873 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
5874 * config/nds32/nds32.md: Ditto.
5875 * config/nds32/pipelines.md: Ditto.
5876
5877 2018-04-04 Richard Biener <rguenther@suse.de>
5878
5879 PR tree-optimization/85168
5880 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
5881 propagating abnormals.
5882
5883 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
5884
5885 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
5886
5887 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
5888 Kito Cheng <kito.cheng@gmail.com>
5889
5890 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
5891 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
5892 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
5893 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
5894 * config/nds32/nds32.md (sibcall_internal): New.
5895 (sibcall_register): Remove.
5896 (sibcall_immediate): Remove.
5897 (sibcall_value_internal): New.
5898 (sibcall_value_register): Remove.
5899 (sibcall_value_immediate): Remove.
5900 * config/nds32/predicates.md (nds32_general_register_operand): New.
5901 (nds32_call_address_operand): New.
5902
5903 2018-04-03 Jakub Jelinek <jakub@redhat.com>
5904
5905 PR rtl-optimization/85167
5906 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
5907 bb_defs if *split_p, instead preinitialize it to NULL.
5908
5909 PR tree-optimization/85156
5910 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
5911 evaluating the argument multiple times.
5912
5913 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
5914
5915 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
5916 than vector.
5917 (_mm_cvtpd_ps): Likewise.
5918 (_mm_cvttpd_epi32): Likewise.
5919 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
5920 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
5921 vector, pixel, and bool following altivec.h include.
5922
5923 2018-04-03 Martin Sebor <msebor@redhat.com>
5924
5925 * doc/extend.texi (Common Function Attributes): Clarify.
5926 (const attribute): Likewise.
5927 (pure attribute): Likewise.
5928
5929 2018-04-03 Jakub Jelinek <jakub@redhat.com>
5930
5931 PR target/85169
5932 * config/i386/i386.c (ix86_expand_vector_set): Use
5933 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
5934
5935 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
5936
5937 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
5938 instructions when changing rounding bits to preserve precision bits
5939 in the x87 control word.
5940
5941 2018-04-03 Martin Liska <mliska@suse.cz>
5942
5943 PR tree-optimization/82491
5944 * rtl.h (strip_offset_and_add): Replace += suboffset with
5945 poly_uint64 () + suboffset.
5946
5947 2018-03-29 Martin Liska <mliska@suse.cz>
5948 Martin Jambor <mjambor@suse.cz>
5949
5950 PR ipa/84947
5951 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
5952 param_type is not an integral or pointer type.
5953
5954 2018-04-03 Richard Biener <rguenther@suse.de>
5955
5956 * sese.h (recompute_all_dominators): Remove.
5957
5958 2018-04-02 Martin Sebor <msebor@redhat.com>
5959
5960 * doc/invoke.texi (-Wrestrict): Fix typos.
5961
5962 2018-04-02 Jim Wilson <jimw@sifive.com>
5963
5964 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
5965 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
5966 (<optab>di3, <optab>si3_extend): Likewise.
5967 (<optab>si3_mask, <optab>si3_mask_1): New.
5968 (<optab>di3_mask, <optab>di3_mask_1): New.
5969 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
5970 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
5971 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
5972
5973 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
5974
5975 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
5976 example.
5977
5978 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
5979
5980 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
5981 (nds32_canonicalize_comparison): New function.
5982
5983 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
5984 Kito Cheng <kito.cheng@gmail.com>
5985 Kuan-Lin Chen <kuanlinchentw@gmail.com>
5986
5987 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
5988 * config/nds32/constants.md (unspec_volatile_element): Add
5989 UNSPEC_VOLATILE_RELAX_GROUP.
5990 * config/nds32/nds32-relax-opt.c: New file.
5991 * config/nds32/nds32-predicates.c
5992 (nds32_symbol_load_store_p): New function.
5993 * config/nds32/nds32-protos.h
5994 (nds32_symbol_load_store_p): Declare function.
5995 (make_pass_nds32_relax_opt): Declare new rtl pass function.
5996 * config/nds32/nds32.c
5997 (nds32_register_pass): New function to register pass.
5998 (nds32_register_passes): New function to register passes.
5999 * config/nds32/nds32.md (relax_group): New pattern.
6000 * config/nds32/nds32.opt (mrelax-hint): New option.
6001 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
6002
6003 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
6004
6005 * config/nds32/t-nds32: Modify files dependency.
6006
6007 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
6008
6009 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
6010 (PROFILE_HOOK): Define its implementation.
6011
6012 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
6013
6014 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
6015 type and 32-bit size.
6016
6017 2018-04-01 Jakub Jelinek <jakub@redhat.com>
6018
6019 PR middle-end/85090
6020 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
6021 (V_128_256): New mode iterator.
6022 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
6023 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
6024 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
6025 of V.
6026 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
6027 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
6028
6029 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
6030
6031 PR target/83315
6032 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
6033 NaN inputs correctly.
6034
6035 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
6036
6037 PR target/80546
6038 * config/rs6000/vsx.md (??r): New mode attribute.
6039 (*vsx_mov<mode>_64bit): Use it.
6040 (*vsx_mov<mode>_32bit): Likewise.
6041
6042 2018-03-30 Martin Sebor <msebor@redhat.com>
6043
6044 PR tree-optimization/84818
6045 * builtins.c (check_access): Use warning_n.
6046
6047 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
6048
6049 PR target/83822
6050 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
6051 condition.
6052 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
6053 condition.
6054
6055 2018-03-30 Julia Koval <julia.koval@intel.com>
6056
6057 PR target/84413
6058 * x86-tune.def (movx, partial_reg_dependency): Enable for
6059 m_SKYLAKE_AVX512.
6060
6061 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
6062
6063 PR inline-asm/84985
6064 * lra-constraints.c (process_alt_operands): Move setting
6065 this_alternative_matches below.
6066
6067 2018-03-29 Martin Liska <mliska@suse.cz>
6068
6069 PR lto/84995.
6070 * doc/invoke.texi: Document how LTO works with debug info.
6071 Describe auto-load support of binutils. Mention 'x86-64'
6072 as valid option value of -march option.
6073
6074 2018-03-29 Jakub Jelinek <jakub@redhat.com>
6075
6076 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
6077
6078 PR c/85094
6079 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
6080 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
6081 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
6082 checking.
6083
6084 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
6085
6086 PR target/84912
6087 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
6088 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
6089 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
6090 for RS6000_BTM_POWERPC64.
6091 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
6092 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
6093 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
6094 definition.
6095 (DIVDE): Use it.
6096 (DIVDEU): Likewise.
6097
6098 2018-03-28 Carl Love <cel@us.ibm.com>
6099
6100 Revert
6101 2017-09-27 Carl Love <cel@us.ibm.com>
6102
6103 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
6104 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
6105 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
6106 fctiw instruction.
6107
6108 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
6109
6110 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
6111 instead of __vector bool.
6112 (_mm_max_pu8): Likewise.
6113 (_mm_min_pi16): Likewise.
6114
6115 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
6116
6117 PR target/84912
6118 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
6119 (DIVWEUO): Likewise.
6120 (DIVDEO): Likewise.
6121 (DIVDEUO): Likewise.
6122 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
6123 DIVWEUO and DIVDEUO.
6124 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
6125 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
6126 (div_extend): Likewise.
6127 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
6128 builtin function.
6129 (__builtin_divweuo): Likewise.
6130 (__builtin_divdeo): Likewise.
6131 (__builtin_divdeuo): Likewise.
6132
6133 2018-03-28 Jakub Jelinek <jakub@redhat.com>
6134
6135 PR target/85095
6136 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
6137 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
6138
6139 PR tree-optimization/82004
6140 * gimple-match-head.c (optimize_pow_to_exp): New function.
6141 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
6142 Don't fold to exp if optimize_pow_to_exp is false.
6143
6144 2018-03-28 Martin Liska <mliska@suse.cz>
6145
6146 PR other/84819
6147 * calls.c (initialize_argument_information): Fix trailing space.
6148 * common.opt: Fix typo and provide better explanation for
6149 -fsanitize-coverage option.
6150 * config/i386/i386.opt: Fix typo.
6151
6152 2018-03-28 Jakub Jelinek <jakub@redhat.com>
6153 Martin Liska <mliska@suse.cz>
6154
6155 PR sanitizer/85081
6156 * gimplify.c (asan_poison_variable): Don't do the check for
6157 gimplify_omp_ctxp here.
6158 (gimplify_decl_expr): Do it here.
6159 (gimplify_target_expr): Likewise.
6160
6161 2018-03-28 Martin Liska <mliska@suse.cz>
6162
6163 PR target/84988
6164 * config/i386/i386.c (ix86_function_arg_advance): Do not call
6165 chkp_type_bounds_count if MPX is not enabled.
6166
6167 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
6168
6169 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
6170
6171 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
6172
6173 PR target/84914
6174 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
6175 function to create the function decl for complex long double
6176 multiply and divide for -mabi=ieeelongdouble.
6177 (init_float128_ieee): Call it.
6178
6179 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
6180
6181 PR target/85044
6182 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
6183 -fcf-protection=branch -mibt.
6184 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
6185
6186 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
6187
6188 PR target/81863
6189 * config/arm/arm.c (arm_valid_symbolic_address): Handle arm_word_relocations
6190
6191 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
6192
6193 PR target/85056
6194 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
6195 extern array declarations.
6196
6197 2018-03-27 Richard Biener <rguenther@suse.de>
6198
6199 PR middle-end/84067
6200 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
6201 explicit single_use checks.
6202
6203 2018-03-27 Richard Biener <rguenther@suse.de>
6204
6205 PR tree-optimization/85082
6206 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
6207 Valueize the VUSE.
6208
6209 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
6210
6211 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
6212 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
6213 Turn on fasynchronous-unwind-tables and funwind-tables.
6214
6215 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
6216
6217 PR target/85073
6218 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
6219 (*bmi_blsr_<mode>_ccz): Ditto.
6220
6221 2018-03-26 Tom de Vries <tom@codesourcery.com>
6222
6223 PR tree-optimization/85063
6224 * omp-general.c (offloading_function_p): New function. Factor out
6225 of ...
6226 * omp-offload.c (pass_omp_target_link::gate): ... here.
6227 * omp-general.h (offloading_function_p): Declare.
6228 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
6229 with attribute omp declare target for offloading functions.
6230
6231 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
6232
6233 PR tree-optimization/84005
6234 * tree-data-ref.h (get_base_for_alignment): Declare.
6235 * tree-data-ref.c (get_base_for_alignment_1): New function.
6236 (get_base_for_alignment): Likewise.
6237 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
6238 get_base_for_alignment to find a suitable base object, instead
6239 of always using drb->base_address.
6240
6241 2018-03-23 Jakub Jelinek <jakub@redhat.com>
6242
6243 PR inline-asm/85022
6244 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
6245 known size by default.
6246
6247 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
6248
6249 PR inline-asm/85030
6250 * lra-constraints.c (process_alt_operands): Don't match BLKmode
6251 and non BLKmode operands.
6252
6253 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
6254
6255 PR target/85026
6256 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
6257 Clean up attributes.
6258
6259 2018-03-23 Richard Biener <rguenther@suse.de>
6260
6261 PR debug/85020
6262 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
6263 we are going to emit early debug for LTO.
6264
6265 2018-03-23 Jakub Jelinek <jakub@redhat.com>
6266
6267 PR inline-asm/85034
6268 * function.c (match_asm_constraints_1): Don't optimize if input
6269 doesn't satisfy general_operand predicate for output's mode.
6270
6271 PR inline-asm/85022
6272 * alias.c (write_dependence_p): Don't require for x_canonicalized
6273 non-VOIDmode if x has VOIDmode.
6274
6275 PR sanitizer/85029
6276 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
6277 just don't try to optimize it rather than assert it never happens.
6278
6279 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
6280
6281 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
6282 macro expansions for definition of ST_INTERNAL_<mode> and
6283 LD_INTERNAL_<mode> builtins.
6284 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
6285 Remove prototype.
6286 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
6287 function.
6288 (altivec_expand_st_builtin): Likewise.
6289 (altivec_expand_builtin): Remove calls to deleted functions.
6290 (rs6000_address_for_altivec): Delete this function.
6291 * config/rs6000/vector.md: Remove expands for
6292 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
6293
6294 2018-03-22 Sudakshina Das <sudi.das@arm.com>
6295
6296 PR target/84826
6297 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
6298 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
6299 re-computing once computed.
6300 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
6301 (arm_init_machine_status): Initialize
6302 machine->static_chain_stack_bytes.
6303
6304 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
6305
6306 PR target/84760
6307 * doc/extend.texi: Add four new prototypes for vec_ld.
6308 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
6309 definitions for more logical presentation.
6310 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
6311 entries for V1TI variants of __builtin_altivec_ld builtin.
6312 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
6313 handling of V1TI variant of LVX icode pattern.
6314 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
6315 (rs6000_gimple_fold_builtin): Likewise.
6316 (altivec_init_builtins): Add code to define
6317 __builtin_altivec_lvx_v1ti function.
6318
6319 2018-03-22 Jakub Jelinek <jakub@redhat.com>
6320
6321 PR inline-asm/84941
6322 * function.c (match_asm_constraints_1): Don't do the optimization
6323 if input isn't a REG, SUBREG, MEM or constant.
6324
6325 2018-03-22 Tom de Vries <tom@codesourcery.com>
6326
6327 PR tree-optimization/84956
6328 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
6329 bb_has_abnormal_pred.
6330
6331 2018-03-22 Jakub Jelinek <jakub@redhat.com>
6332
6333 PR sanitizer/85018
6334 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
6335 DECL_INITIAL (decl) to decl at the end.
6336 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
6337 adjust the comment.
6338
6339 2018-03-21 Joseph Myers <joseph@codesourcery.com>
6340
6341 * doc/extend.texi (__builtin_tgmath): Document when complex
6342 integer types are treated as _Complex _Float64.
6343
6344 2018-03-21 Tom de Vries <tom@codesourcery.com>
6345
6346 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
6347
6348 2018-03-21 Jakub Jelinek <jakub@redhat.com>
6349
6350 PR tree-optimization/84960
6351 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
6352 if it is ENTRY block, move them into single succ of ENTRY in that case.
6353
6354 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
6355
6356 PR tree-optimization/84811
6357 * poly-int.h (poly_span_traits): Remove the T3 parameter and
6358 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
6359 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
6360 (known_subrange_p): Update accordingly. Cast each value involved
6361 in the size comparison, rather than casting the result of the
6362 subtraction.
6363
6364 2018-03-21 Jakub Jelinek <jakub@redhat.com>
6365
6366 PR tree-optimization/84982
6367 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
6368 by flipping the least significant bit rather than all bits from
6369 bitpos to bitpos + bitsize - 1.
6370
6371 2018-03-21 Nathan Sidwell <nathan@acm.org>
6372
6373 * doc/extend.texi (Deprecated Features): Remove mention of
6374 long-deleted deprecations.
6375
6376 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6377
6378 PR jit/84288
6379 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
6380 * configure: Regenerate.
6381
6382 2018-03-21 Tom de Vries <tom@codesourcery.com>
6383
6384 PR tree-optimization/83126
6385 * tree-parloops.c (num_phis): New function.
6386 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
6387
6388 2018-03-21 Nathan Sidwell <nathan@acm.org>
6389
6390 * doc/extend.texi (Deprecated Features): Update deprecated flags,
6391 mention anon-struct/union members and trailing attributes.
6392
6393 2018-03-21 Bin Cheng <bin.cheng@arm.com>
6394
6395 PR tree-optimization/84969
6396 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
6397 builtin memset partitions if they set different rhs values.
6398
6399 2018-03-21 Jakub Jelinek <jakub@redhat.com>
6400
6401 PR rtl-optimization/84989
6402 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
6403 VEC_DUPLICATE with scalar result mode.
6404
6405 2018-03-21 Martin Liska <mliska@suse.cz>
6406
6407 PR ipa/84963
6408 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
6409 not intended return statement.
6410
6411 2018-03-21 Martin Liska <mliska@suse.cz>
6412
6413 PR target/84988
6414 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
6415 (chkp_find_bound_slots_1): Limit number of iterations.
6416
6417 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
6418
6419 PR target/84838
6420 * Minor grammar fixes for x86 options.
6421
6422 2018-03-20 Jakub Jelinek <jakub@redhat.com>
6423
6424 PR debug/84875
6425 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
6426 holding REG_CFA_RESTORE notes, instead turn them into a USE.
6427
6428 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
6429
6430 PR target/83789
6431 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
6432 (altivec_lvx_<mode>_1op): Likewise.
6433 (altivec_stvx_<mode>_2op): Likewise.
6434 (altivec_stvx_<mode>_1op): Likewise.
6435 (altivec_lvx_<VM2:mode>): New define_expand.
6436 (altivec_stvx_<VM2:mode>): Likewise.
6437 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
6438 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
6439 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
6440 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
6441 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
6442 (rs6000_gen_lvx): Likewise.
6443 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
6444 (altivec_expand_stv_builtin): Likewise.
6445 (altivec_expand_builtin): Likewise.
6446 * config/rs6000/vector.md: Likewise.
6447
6448 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
6449
6450 PR target/82518
6451 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
6452 BYTES_BIG_ENDIAN.
6453
6454 2018-03-20 Richard Biener <rguenther@suse.de>
6455
6456 PR target/84986
6457 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
6458 sign-conversions as zero, fall back to standard scalar_stmt
6459 cost for the rest.
6460
6461 2018-03-20 Martin Liska <mliska@suse.cz>
6462
6463 PR ipa/84825
6464 * predict.c (rebuild_frequencies): Handle case when we have
6465 PROFILE_ABSENT, but flag_guess_branch_prob is false.
6466
6467 2018-03-20 Jakub Jelinek <jakub@redhat.com>
6468
6469 PR target/84990
6470 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
6471 flag_section_anchors.
6472 * varasm.c (use_blocks_for_decl_p): Remove hack for
6473 dw2_force_const_mem.
6474
6475 PR target/84845
6476 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
6477 to ...
6478 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
6479 be created, use lowpart_subreg of operands[0] rather than operands[0]
6480 itself.
6481 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
6482 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
6483 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
6484 and n constraint instead of aarch64_shift_imm_di and Usd.
6485 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
6486 (*aarch64_<optab>_reg_minus<mode>3): ... this.
6487
6488 2018-03-20 Sudakshina Das <sudi.das@arm.com>
6489
6490 PR target/82989
6491 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
6492 to favor GPR over NEON registers.
6493 (<shift>di3_neon): Likewise.
6494
6495 2018-03-20 Tom de Vries <tom@codesourcery.com>
6496
6497 PR target/84952
6498 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
6499 (nvptx_process_pars): Emit bar.sync asap and alap.
6500
6501 2018-03-20 Tom de Vries <tom@codesourcery.com>
6502
6503 PR target/84954
6504 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
6505 seen_label if seen_label is already set.
6506
6507 2018-03-20 Jakub Jelinek <jakub@redhat.com>
6508
6509 PR target/84945
6510 * config/i386/i386.c (fold_builtin_cpu): For features above 31
6511 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
6512 Use 1U instead of 1. Formatting fixes.
6513
6514 PR c/84953
6515 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
6516 instead of TREE_TYPE (s1) for the return value.
6517
6518 2018-03-19 Jakub Jelinek <jakub@redhat.com>
6519
6520 PR tree-optimization/84946
6521 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
6522 bitsize + bitsize in poly_uint64 rather than poly_int64.
6523
6524 PR sanitizer/78651
6525 * dwarf2asm.c: Include fold-const.c.
6526 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
6527 of decl rather than decl itself.
6528
6529 PR rtl-optimization/84643
6530 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
6531
6532 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
6533
6534 PR sanitizer/78651
6535 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
6536 calling assemble_variable.
6537
6538 2018-03-19 Sudakshina Das <sudi.das@arm.com>
6539
6540 PR target/81647
6541 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
6542 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
6543
6544 2018-03-19 Jim Wilson <jimw@sifive.com>
6545
6546 PR bootstrap/84856
6547 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
6548 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
6549 (riscv_first_stack_step): Likewise.
6550 (riscv_option_override): Use STACK_BOUNDARY instead of
6551 MIN_STACK_BOUNDARY.
6552 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
6553 MIN_STACK_BOUNDARY.
6554 (BIGGEST_ALIGNMENT): Set to 128.
6555 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
6556 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
6557 STACK_BOUNDARY.
6558
6559 2018-03-19 Richard Biener <rguenther@suse.de>
6560
6561 PR tree-optimization/84933
6562 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
6563 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
6564
6565 2018-03-19 Richard Biener <rguenther@suse.de>
6566
6567 PR tree-optimization/84859
6568 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
6569 (cond_if_else_store_replacement): Perform sinking operation on
6570 single-store BBs regardless of MAX_STORES_TO_SINK setting.
6571 Generalize what a BB with a single eligible store is.
6572
6573 2018-03-19 Richard Biener <rguenther@suse.de>
6574
6575 PR tree-optimization/84929
6576 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
6577 chrec_is_positive against non-chrec arg.
6578
6579 2018-03-19 Tamar Christina <tamar.christina@arm.com>
6580
6581 PR target/84711
6582 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
6583
6584 2018-03-18 Martin Liska <mliska@suse.cz>
6585
6586 PR rtl-optimization/84635
6587 * regrename.c (build_def_use): Use matches_mode only when
6588 matches >= 0.
6589
6590 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
6591
6592 PR tree-optimization/84913
6593 * tree-vect-loop.c (vectorizable_reduction): Don't try to
6594 vectorize chains of COND_EXPRs.
6595
6596 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
6597
6598 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
6599
6600 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
6601
6602 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
6603
6604 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
6605
6606 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
6607
6608 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
6609 Kito Cheng <kito.cheng@gmail.com>
6610
6611 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
6612 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
6613 (nds32_adjust_reg_alloc_order): New function.
6614 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
6615
6616 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
6617
6618 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
6619 nds32_print_operand, nds32_print_operand_address): Use
6620 HOST_WIDE_INT_PRINT_DEC instead.
6621
6622 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
6623
6624 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
6625
6626 2018-03-17 Jakub Jelinek <jakub@redhat.com>
6627
6628 PR target/84902
6629 * config/i386/i386.c (initial_ix86_tune_features,
6630 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
6631 unsigned long long.
6632 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
6633 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
6634 rather than 1u << ix86_tune. Formatting fix.
6635 (ix86_option_override_internal): Change ix86_arch_mask from
6636 unsigned int to unsigned HOST_WIDE_INT, initialize to
6637 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
6638 (ix86_function_specific_restore): Likewise.
6639
6640 2018-03-16 Jakub Jelinek <jakub@redhat.com>
6641
6642 PR target/84899
6643 * postreload.c (reload_combine_recognize_pattern): Perform
6644 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
6645 truncate_int_for_mode the result for the destination's mode.
6646
6647 PR c/84909
6648 * hsa-gen.c (mem_type_for_type): Fix comment typo.
6649 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
6650 Likewise.
6651 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
6652 Likewise.
6653
6654 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
6655
6656 PR target/84876
6657 * lra-assigns.c (lra_split_hard_reg_for): Don't use
6658 regno_allocno_class_array and sorted_pseudos.
6659 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
6660 insns where regno is used.
6661
6662 2018-03-16 Martin Liska <mliska@suse.cz>
6663
6664 PR ipa/84833
6665 * multiple_target.c (create_dispatcher_calls): Redirect
6666 reference in the symbol table.
6667
6668 2018-03-16 Martin Liska <mliska@suse.cz>
6669
6670 PR ipa/84722
6671 * multiple_target.c (create_dispatcher_calls): Redirect also
6672 an alias.
6673
6674 2018-03-16 Jakub Jelinek <jakub@redhat.com>
6675
6676 PR c++/79937
6677 PR c++/82410
6678 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
6679 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
6680 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
6681
6682 2018-03-16 Julia Koval <julia.koval@intel.com>
6683
6684 * doc/invoke.texi (Skylake Server): Add CLWB.
6685 Cannonlake): Remove CLWB.
6686
6687 2018-03-16 Jakub Jelinek <jakub@redhat.com>
6688
6689 PR tree-optimization/84841
6690 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
6691 1 << 3.
6692 (FLOAT_ONE_CONST_TYPE): Define.
6693 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
6694 (sort_by_operand_rank): Put entries with higher constant_type last
6695 rather than first to match comments.
6696
6697 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
6698
6699 * config/nios2/nios2.md (movsi_internal): Fix thinko in
6700 split predicate.
6701
6702 2018-03-15 Jakub Jelinek <jakub@redhat.com>
6703
6704 PR c++/79085
6705 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
6706 check and use address of target always.
6707
6708 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
6709
6710 PR target/84574
6711 * config/i386/i386.c (indirect_thunk_needed): Update comments.
6712 (indirect_thunk_bnd_needed): Likewise.
6713 (indirect_thunks_used): Likewise.
6714 (indirect_thunks_bnd_used): Likewise.
6715 (indirect_return_needed): New.
6716 (indirect_return_bnd_needed): Likewise.
6717 (output_indirect_thunk_function): Add a bool argument for
6718 function return.
6719 (output_indirect_thunk_function): Don't generate alias for
6720 function return thunk.
6721 (ix86_code_end): Call output_indirect_thunk_function to generate
6722 function return thunks.
6723 (ix86_output_function_return): Set indirect_return_bnd_needed
6724 and indirect_return_needed instead of indirect_thunk_bnd_needed
6725 and indirect_thunk_needed.
6726
6727 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
6728
6729 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
6730 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
6731 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
6732
6733 2018-03-15 David Malcolm <dmalcolm@redhat.com>
6734 Paul Hua <paul.hua.gm@gmail.com>
6735
6736 PR c/84852
6737 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
6738
6739 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
6740
6741 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
6742 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
6743 resp. SFmode cases.
6744
6745 2018-03-15 Tamar Christina <tamar.christina@arm.com>
6746
6747 PR target/84711
6748 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
6749 instead of GET_MODE_SIZE when comparing Units.
6750
6751 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6752
6753 PR target/68256
6754 * varasm.c (hash_section): Return an unchangeble hash value
6755 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
6756 Return !aarch64_can_use_per_function_literal_pools_p ().
6757
6758 2018-03-15 Jakub Jelinek <jakub@redhat.com>
6759
6760 PR target/84860
6761 * optabs.c (emit_conditional_move): Pass address of cmode's copy
6762 rather than address of cmode as last argument to prepare_cmp_insn.
6763
6764 2018-03-15 Julia Koval <julia.koval@intel.com>
6765
6766 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
6767 F_AVX512VNNI, F_AVX512BITALG): New.
6768
6769 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
6770
6771 PR target/83451
6772 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
6773 insn for floating-point loads and stores.
6774
6775 2018-03-14 Carl Love <cel@us.ibm.com>
6776
6777 * config/rs6000/rs6000-c.c: Add macro definitions for
6778 ALTIVEC_BUILTIN_VEC_PERMXOR.
6779 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
6780 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
6781 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
6782 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
6783 UNSPEC_VPERMXOR.
6784 * config/doc/extend.texi: Add prototypes for vec_permxor.
6785
6786 2018-03-14 David Malcolm <dmalcolm@redhat.com>
6787
6788 PR c/84852
6789 * diagnostic-show-locus.c (class layout_point): Convert m_line
6790 from int to linenum_type.
6791 (line_span::comparator): Use linenum "compare" function when
6792 comparing line numbers.
6793 (test_line_span): New function.
6794 (layout_range::contains_point): Convert param "row" from int to
6795 linenum_type.
6796 (layout_range::intersects_line_p): Likewise.
6797 (layout::will_show_line_p): Likewise.
6798 (layout::print_source_line): Likewise.
6799 (layout::should_print_annotation_line_p): Likewise.
6800 (layout::print_annotation_line): Likewise.
6801 (layout::print_leading_fixits): Likewise.
6802 (layout::annotation_line_showed_range_p): Likewise.
6803 (struct line_corrections): Likewise for field m_row.
6804 (line_corrections::line_corrections): Likewise for param "row".
6805 (layout::print_trailing_fixits): Likewise.
6806 (layout::get_state_at_point): Likewise.
6807 (layout::get_x_bound_for_row): Likewise.
6808 (layout::print_line): Likewise.
6809 (diagnostic_show_locus): Likewise for locals "last_line" and
6810 "row".
6811 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
6812 * input.c (selftest::test_linenum_comparisons): New function.
6813 (selftest::input_c_tests): Call it.
6814 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
6815 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
6816 * selftest.h (ASSERT_GT): New macro.
6817 (ASSERT_GT_AT): New macro.
6818 (ASSERT_LT): New macro.
6819 (ASSERT_LT_AT): New macro.
6820
6821 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
6822
6823 PR rtl-optimization/84780
6824 * combine.c (distribute_links): Don't make a link based on pc_rtx.
6825
6826 2018-03-14 Martin Liska <mliska@suse.cz>
6827
6828 * tree.c (record_node_allocation_statistics): Use
6829 get_stats_node_kind.
6830 (get_stats_node_kind): New function extracted from
6831 record_node_allocation_statistics.
6832 (free_node): Use get_stats_node_kind.
6833
6834 2018-03-14 Richard Biener <rguenther@suse.de>
6835
6836 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
6837 that the value-set of ANTIC_IN doesn't grow.
6838
6839 Revert
6840 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
6841 member.
6842 (BB_VISITED_WITH_VISITED_SUCCS): New define.
6843 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
6844
6845 2018-03-14 Julia Koval <julia.koval@intel.com>
6846
6847 * config.gcc (icelake-client, icelake-server): New.
6848 (icelake): Remove.
6849 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
6850 (initial_ix86_arch_features): Ditto.
6851 (PTA_SKYLAKE): Add SGX.
6852 (PTA_ICELAKE): Remove.
6853 (PTA_ICELAKE_CLIENT): New.
6854 (PTA_ICELAKE_SERVER): New.
6855 (ix86_option_override_internal): Split up icelake on icelake client and
6856 icelake server.
6857 (get_builtin_code_for_version): Ditto.
6858 (fold_builtin_cpu): Ditto.
6859 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
6860 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
6861 * config/i386/i386.h (processor_type): Ditto.
6862 * doc/invoke.texi: Ditto.
6863
6864 2018-03-14 Jakub Jelinek <jakub@redhat.com>
6865
6866 PR sanitizer/83392
6867 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
6868 INTEGER_CST offset, add it together with bitpos / 8 and
6869 sign extend based on POINTER_SIZE.
6870
6871 PR target/84844
6872 Revert
6873 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
6874
6875 PR target/78090
6876 * config/i386/constraints.md (Yc): New register constraint.
6877 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
6878 Use Yc constraint for alternative 2 of operand 0. Remove
6879 preferred_for_speed attribute.
6880
6881 2018-03-14 Richard Biener <rguenther@suse.de>
6882
6883 PR tree-optimization/84830
6884 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
6885 with the old one to avoid oscillations.
6886
6887 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
6888
6889 PR target/83712
6890 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
6891 pseudos.
6892 (assign_by_spills): Return a flag of reload assignment failure.
6893 Do not process the reload assignment failures. Do not spill other
6894 reload pseudos if they has the same reg class. Update n if
6895 necessary.
6896 (lra_assign): Add a return arg. Set up from the result of
6897 assign_by_spills call.
6898 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
6899 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
6900 usage_insns if it is not NULL.
6901 (spill_hard_reg_in_range): New function.
6902 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
6903 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
6904 function prototypes.
6905 (lra_assign): Change prototype.
6906 * lra.c (lra): Add code to deal with fails by splitting hard reg
6907 live ranges.
6908
6909 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
6910
6911 * config/riscv/riscv.opt (mrelax): New option.
6912 * config/riscv/riscv.c (riscv_file_start): Emit ".option
6913 "norelax" when riscv_mrelax is disabled.
6914 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
6915
6916 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
6917
6918 PR target/84743
6919 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
6920 reassociation for int modes.
6921
6922 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
6923
6924 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
6925 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
6926 for big-endian.
6927 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
6928 * config/aarch64/aarch64-sve.md
6929 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
6930 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
6931 (*extend<mode><Vwide>2): Rename to...
6932 (aarch64_sve_extend<mode><Vwide>2): ...this.
6933 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
6934 renaming the old pattern to...
6935 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
6936 unsigned packs.
6937 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
6938 define_expand, renaming the old pattern to...
6939 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
6940 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
6941 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
6942 account when deciding which SVE instruction the optab should use.
6943 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
6944
6945 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
6946
6947 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
6948 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
6949 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
6950 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
6951 (tlsdesc_small_<mode>): Turn a define_expand and use
6952 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
6953 (tlsdesc_small_advsimd_<mode>): ...this.
6954 (tlsdesc_small_sve_<mode>): New pattern.
6955
6956 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
6957
6958 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
6959 (UNSPEC_UMUL_HIGHPART): New constants.
6960 (MUL_HIGHPART): New int iteraor.
6961 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
6962 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
6963 define_expand.
6964 (*<su>mul<mode>3_highpart): New define_insn.
6965
6966 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
6967
6968 PR lto/84805
6969 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
6970 incomplete types.
6971
6972 2018-03-13 Martin Liska <mliska@suse.cz>
6973
6974 PR ipa/84658.
6975 * (sem_item_optimizer::sem_item_optimizer): Initialize new
6976 vector.
6977 (sem_item_optimizer::~sem_item_optimizer): Release it.
6978 (sem_item_optimizer::merge_classes): Register variable aliases.
6979 (sem_item_optimizer::fixup_pt_set): New function.
6980 (sem_item_optimizer::fixup_points_to_sets): Likewise.
6981 * ipa-icf.h: Declare new variables and functions.
6982
6983 2018-03-13 Jakub Jelinek <jakub@redhat.com>
6984
6985 PR middle-end/84834
6986 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
6987 integer_pow2p@2 and test integer_pow2p in condition.
6988 (A < 0 ? C : 0): Similarly for @1.
6989
6990 PR middle-end/84831
6991 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
6992 characters starting at p contain '\0' character, don't look beyond
6993 that.
6994
6995 PR target/84827
6996 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
6997 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
6998
6999 PR target/84828
7000 * reg-stack.c (change_stack): Change update_end var from int to
7001 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
7002 also call set_block_for_insn on the newly added insns and rescan.
7003
7004 PR target/84786
7005 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
7006 on the last operand.
7007
7008 PR c++/84704
7009 * tree.c (stabilize_reference_1): Return save_expr (e) for
7010 STATEMENT_LIST even if it doesn't have side-effects.
7011
7012 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
7013
7014 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
7015
7016 2018-03-12 Renlin Li <renlin.li@arm.com>
7017
7018 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
7019 aarch64_output_scalar_simd_mov_immediate.
7020
7021 2018-03-12 Martin Sebor <msebor@redhat.com>
7022
7023 PR tree-optimization/83456
7024 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
7025 for perfectly overlapping calls to memcpy.
7026 (gimple_fold_builtin_memory_chk): Same.
7027 (gimple_fold_builtin_strcpy): Handle no-warning.
7028 (gimple_fold_builtin_stxcpy_chk): Same.
7029 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
7030
7031 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
7032
7033 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
7034 parameter. Use it for SFmode.
7035 (rs6000_function_arg_advance_1): Adjust.
7036 (rs6000_function_arg): Adjust.
7037 (rs6000_gimplify_va_arg): Pass false for that new parameter.
7038
7039 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
7040
7041 PR rtl-optimization/84169
7042 PR rtl-optimization/84780
7043 * combine.c (can_combine_p): Check for a 2-insn combination whether
7044 the destination register is used between the two insns, too.
7045
7046 2018-03-12 Richard Biener <rguenther@suse.de>
7047
7048 PR tree-optimization/84803
7049 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
7050 for refs DR analysis didn't process.
7051
7052 2018-03-12 Richard Biener <rguenther@suse.de>
7053
7054 PR tree-optimization/84777
7055 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
7056 force-vectorize loops ignore whether we are optimizing for size.
7057
7058 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
7059
7060 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
7061 (TARGET_MD_ASM_ADJUST): Define.
7062
7063 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
7064 Kito Cheng <kito.cheng@gmail.com>
7065 Chung-Ju Wu <jasonwucj@gmail.com>
7066
7067 * config/nds32/nds32.c (nds32_compute_stack_frame,
7068 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
7069 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
7070 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
7071 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
7072 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
7073 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
7074 * config/nds32/nds32.md (prologue, epilogue): Use macro
7075 NDS32_V3PUSH_AVAILABLE_P to do checking.
7076
7077 2018-03-11 Jakub Jelinek <jakub@redhat.com>
7078
7079 PR debug/58150
7080 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
7081 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
7082 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
7083 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
7084 addition of most attributes on !orig_type_die or the attribute not
7085 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
7086
7087 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
7088 Chung-Ju Wu <jasonwucj@gmail.com>
7089
7090 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
7091 __NDS32_VH__ macro.
7092 * config/nds32/nds32.opt (mvh): New option.
7093
7094 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
7095 Chung-Ju Wu <jasonwucj@gmail.com>
7096
7097 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
7098 function.
7099 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
7100 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
7101 definition.
7102
7103 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
7104 Chung-Ju Wu <jasonwucj@gmail.com>
7105
7106 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
7107 function.
7108 * config/nds32/nds32-multiple.md (strlensi): New pattern.
7109 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
7110
7111 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
7112 Kito Cheng <kito.cheng@gmail.com>
7113 Chung-Ju Wu <jasonwucj@gmail.com>
7114
7115 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
7116 UNSPEC_FFMISM and UNSPEC_FLMISM.
7117 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
7118 for ffb, ffmism and flmism.
7119 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
7120 (unspec_ffmism): Ditto.
7121 (unspec_flmism): Ditto.
7122 (nds32_expand_builtin_impl): Check if string extension is available.
7123 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
7124 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
7125
7126 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
7127
7128 Reverting patch:
7129 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
7130
7131 PR target/83712
7132 * lra-assigns.c (assign_by_spills): Return a flag of reload
7133 assignment failure. Do not process the reload assignment
7134 failures. Do not spill other reload pseudos if they has the same
7135 reg class.
7136 (lra_assign): Add a return arg. Set up from the result of
7137 assign_by_spills call.
7138 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
7139 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
7140 usage_insns if it is not NULL.
7141 (spill_hard_reg_in_range): New function.
7142 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
7143 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
7144 function prototypes.
7145 (lra_assign): Change prototype.
7146 * lra.c (lra): Add code to deal with fails by splitting hard reg
7147 live ranges.
7148
7149 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
7150
7151 PR target/84807
7152 * config/i386/i386.opt: Replace Enforcment with Enforcement.
7153
7154 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
7155
7156 PR debug/84620
7157 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
7158 (dw_val_node): Add val_symbolic_view.
7159 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
7160 (symview_upper_bound): New.
7161 (new_line_info_table): Initialize symviews_since_reset.
7162 (dwarf2out_source_line): Count symviews_since_reset and set
7163 symview_upper_bound.
7164 (dw_val_equal_p): Handle symview.
7165 (add_AT_symview): New.
7166 (print_dw_val): Handle symview.
7167 (attr_checksum, attr_checksum_ordered): Likewise.
7168 (same_dw_val_p, size_of_die): Likewise.
7169 (value_format, output_die): Likewise.
7170 (add_high_low_attributes): Use add_AT_symview for entry_view.
7171 (dwarf2out_finish): Reset symview_upper_bound, clear
7172 zero_view_p.
7173
7174 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
7175
7176 PR target/83969
7177 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
7178 Add strict argument and use it.
7179 (rs6000_split_multireg_move): Update for new strict argument.
7180 (mem_operand_gpr): Disallow all non-offsettable addresses.
7181 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
7182
7183 2018-03-09 Jakub Jelinek <jakub@redhat.com>
7184
7185 PR target/84772
7186 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
7187 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
7188 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
7189
7190 PR c++/84767
7191 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
7192 decl, use remap_type if we want to use the type.
7193
7194 2018-03-09 Martin Sebor <msebor@redhat.com>
7195
7196 PR tree-optimization/84526
7197 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
7198 Remove dead code.
7199 (builtin_access::generic_overlap): Be prepared to handle non-array
7200 base objects.
7201
7202 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
7203
7204 PR rtl-optimization/84682
7205 * lra-constraints.c (process_address_1): Check is_address flag
7206 for address constraints.
7207 (process_alt_operands): Likewise.
7208 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
7209 preprocess_constraints.
7210 * recog.h (preprocess_constraints): Add oploc parameter.
7211 Adjust callers.
7212 * recog.c (preprocess_constraints): Test address_operand for
7213 CT_ADDRESS constraints.
7214
7215 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
7216
7217 PR target/83712
7218 * lra-assigns.c (assign_by_spills): Return a flag of reload
7219 assignment failure. Do not process the reload assignment
7220 failures. Do not spill other reload pseudos if they has the same
7221 reg class.
7222 (lra_assign): Add a return arg. Set up from the result of
7223 assign_by_spills call.
7224 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
7225 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
7226 usage_insns if it is not NULL.
7227 (spill_hard_reg_in_range): New function.
7228 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
7229 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
7230 function prototypes.
7231 (lra_assign): Change prototype.
7232 * lra.c (lra): Add code to deal with fails by splitting hard reg
7233 live ranges.
7234
7235 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
7236
7237 PR target/83193
7238 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
7239 Accept complain bool parameter. Only emit errors if it is true.
7240 (arm_parse_cpu_option_name): Likewise.
7241 (arm_target_thumb_only): Adjust callers of the above.
7242 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
7243 prototype to take a default true bool parameter.
7244 (arm_parse_arch_option_name): Likewise.
7245
7246 2018-03-09 David Malcolm <dmalcolm@redhat.com>
7247 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
7248
7249 PR jit/64089
7250 PR jit/84288
7251 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
7252 * configure: Regenerate.
7253 * configure.ac ("linker --version-script option"): New.
7254 ("linker soname option"): New.
7255
7256 2018-03-09 Richard Biener <rguenther@suse.de>
7257
7258 PR tree-optimization/84775
7259 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
7260 immediate uses of predicate stmts and mark them modified.
7261
7262 Revert
7263 PR tree-optimization/84178
7264 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
7265 to caller.
7266 (version_loop_for_if_conversion): Delay update_ssa call.
7267 (tree_if_conversion): Delay update_ssa until after predicate
7268 insertion.
7269
7270 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
7271
7272 PR target/84763
7273 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
7274 when the function accesses prior frames.
7275
7276 2018-03-08 Jakub Jelinek <jakub@redhat.com>
7277
7278 PR debug/84456
7279 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
7280 gen_llsym, otherwise call maybe_gen_llsym.
7281
7282 PR inline-asm/84742
7283 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
7284 has ',' character inside of it.
7285
7286 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
7287
7288 PR target/84748
7289 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
7290 as clobbering CC_REGNUM.
7291
7292 2018-03-08 Richard Biener <rguenther@suse.de>
7293
7294 PR middle-end/84552
7295 * tree-scalar-evolution.c: Include tree-into-ssa.h.
7296 (follow_copies_to_constant): Do not follow SSA names registered
7297 for update.
7298
7299 2018-03-08 Richard Biener <rguenther@suse.de>
7300
7301 PR tree-optimization/84178
7302 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
7303 to caller.
7304 (version_loop_for_if_conversion): Delay update_ssa call.
7305 (tree_if_conversion): Delay update_ssa until after predicate
7306 insertion.
7307
7308 2018-03-08 David Malcolm <dmalcolm@redhat.com>
7309
7310 PR tree-optimization/84178
7311 * tree-if-conv.c (release_bb_predicate): Remove the
7312 the assertion that the stmts have NULL use_ops.
7313 Discard the statements, asserting that they haven't
7314 yet been added to a BB.
7315
7316 2018-03-08 Richard Biener <rguenther@suse.de>
7317
7318 PR tree-optimization/84746
7319 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
7320 (phi_translate): Pass in destination ANTIC_OUT set.
7321 (phi_translate_1): Likewise. For a simplified result lookup
7322 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
7323 (phi_translate_set): Adjust.
7324 (do_pre_regular_insertion): Likewise.
7325 (do_pre_partial_partial_insertion): Likewise.
7326
7327 2018-03-08 Martin Liska <mliska@suse.cz>
7328
7329 PR gcov-profile/84735
7330 * doc/gcov.texi: Document usage of profile files.
7331 * gcov-io.h: Document changes in the format.
7332
7333 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
7334
7335 PR debug/84404
7336 PR debug/84408
7337 * dwarf2out.c (struct dw_line_info_table): Update comments for
7338 view == -1.
7339 (FORCE_RESET_NEXT_VIEW): New.
7340 (FORCE_RESETTING_VIEW_P): New.
7341 (RESETTING_VIEW_P): Check for -1 too.
7342 (ZERO_VIEW_P): Likewise.
7343 (new_line_info_table): Force-reset next view.
7344 (dwarf2out_begin_function): Likewise.
7345 (dwarf2out_source_line): Simplify zero_view_p initialization.
7346 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
7347 view directly. Omit view when omitting .loc at line 0.
7348
7349 2018-03-08 Jakub Jelinek <jakub@redhat.com>
7350
7351 PR tree-optimization/84740
7352 * tree-switch-conversion.c (process_switch): Call build_constructors
7353 only if info.phi_count is non-zero.
7354
7355 PR tree-optimization/84739
7356 * tree-tailcall.c (find_tail_calls): Check call arguments against
7357 DECL_ARGUMENTS (current_function_decl) rather than
7358 DECL_ARGUMENTS (func) when checking for tail recursion.
7359
7360 2018-03-07 Jakub Jelinek <jakub@redhat.com>
7361
7362 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
7363 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
7364 Volker Reichelt's entry and add entries for people that perform
7365 GCC fuzzy testing and report numerous bugs.
7366
7367 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
7368
7369 PR target/82411
7370 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
7371 readonly data in sdata, if that is disabled.
7372 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
7373 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
7374 -mreadonly-in-sdata option.
7375
7376 2018-03-07 Martin Sebor <msebor@redhat.com>
7377
7378 PR tree-optimization/84468
7379 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
7380 basic block when looking for nul assignment.
7381
7382 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
7383
7384 PR target/84277
7385 * except.h (output_function_exception_table): Adjust prototype.
7386 * except.c (output_function_exception_table): Remove FNNAME parameter
7387 and add SECTION parameter. Ouput one part of the table at a time.
7388 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
7389 the first part of the exception table and emit unwind directives.
7390 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
7391 (i386_pe_seh_cold_init): Likewise.
7392 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
7393 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
7394 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
7395 (ix86_output_call_insn): Emit a nop in one more case for SEH.
7396 * config/i386/winnt.c: Include except.h.
7397 (struct seh_frame_state): Add reg_offset, after_prologue and
7398 in_cold_section fields.
7399 (i386_pe_seh_end_prologue): Set seh->after_prologue.
7400 (i386_pe_seh_cold_init): New function.
7401 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
7402 to seh->in_cold_section.
7403 (seh_emit_push): Record the offset of the push.
7404 (seh_emit_save): Record the offet of the save.
7405 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
7406 Test seh->after_prologue to disregard the epilogue.
7407 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
7408 (i386_pe_end_cold_function): New function.
7409
7410 2018-03-07 Jakub Jelinek <jakub@redhat.com>
7411
7412 PR fortran/84565
7413 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
7414 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
7415
7416 PR c++/84704
7417 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
7418 on tmp_var.
7419 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
7420 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
7421
7422 PR middle-end/84723
7423 * multiple_target.c: Include tree-inline.h and intl.h.
7424 (expand_target_clones): Diagnose and fail if node->definition and
7425 !tree_versionable_function_p (node->decl).
7426
7427 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
7428
7429 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
7430 sprint_ul.
7431 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
7432 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
7433 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
7434
7435 2018-03-06 Jakub Jelinek <jakub@redhat.com>
7436
7437 PR target/84710
7438 * combine.c (try_combine): Use reg_or_subregno instead of handling
7439 just paradoxical SUBREGs and REGs.
7440
7441 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
7442
7443 * config/arc/arc.c (arc_finalize_pic): Remove function.
7444 (arc_must_save_register): We use single base PIC register, remove
7445 checks to save/restore the PIC register.
7446 (arc_expand_prologue): Likewise.
7447 * config/arc/arc-protos.h (arc_set_default_type_attributes):
7448 Remove.
7449 (arc_verify_short): Likewise.
7450 (arc_attr_type): Likewise.
7451 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
7452 (walk_stores): Likewise.
7453 (arc_address_cost): Make it static.
7454 (arc_verify_short): Likewise.
7455 (branch_dest): Likewise.
7456 (arc_attr_type): Likewise.
7457 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
7458 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
7459 (arc_final_prescan_insn): Remove inserting the nops due to
7460 hardware hazards. It is done in reorg step.
7461 (insn_length_variant_t): Remove.
7462 (insn_length_parameters_t): Likewise.
7463 (arc_insn_length_parameters): Likewise.
7464 (arc_get_insn_variants): Likewise.
7465 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
7466
7467 2018-03-06 Jakub Jelinek <jakub@redhat.com>
7468
7469 PR inline-asm/84683
7470 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
7471 assertion failure.
7472
7473 PR tree-optimization/84687
7474 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
7475 on new_node->decl.
7476 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
7477
7478 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
7479
7480 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
7481 Rename to ppc_speculation_barrier.
7482 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
7483 __builtin_ppc_speculation_barrier.
7484
7485 2018-03-05 Jakub Jelinek <jakub@redhat.com>
7486
7487 PR target/84700
7488 * combine.c (combine_simplify_rtx): Don't try to simplify if
7489 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
7490 are equal to x.
7491
7492 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
7493
7494 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
7495 to 32 bytes when compiling for POWER9.
7496
7497 2018-03-05 Jakub Jelinek <jakub@redhat.com>
7498
7499 PR target/84564
7500 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
7501 regparm >= 3 with no arg reg available also for calls with
7502 flag_force_indirect_call. Pass decl to ix86_function_regparm.
7503
7504 PR target/84524
7505 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
7506 orig,vex.
7507 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
7508
7509 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
7510
7511 PR target/84264
7512 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
7513
7514 2018-03-05 Richard Biener <rguenther@suse.de>
7515
7516 PR tree-optimization/84486
7517 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
7518 When inserting a __builtin_assume_aligned call set the LHS
7519 SSA name alignment info accordingly.
7520
7521 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
7522
7523 PR tree-optimization/84114
7524 * config/aarch64/aarch64.c (aarch64_reassociation_width)
7525 Avoid reassociation of FLOAT_MODE addition.
7526
7527 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
7528
7529 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
7530 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
7531 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
7532 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
7533 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
7534 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
7535 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
7536 and -mwbnoinvd.
7537 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
7538 __builtin_ia32_wbinvd): New builtins.
7539 (SPECIAL_ARGS2): New.
7540 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
7541 (SPECIAL_ARGS2): New.
7542 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
7543 (ix86_valid_target_attribute_inner_p): Ditto.
7544 (ix86_init_mmx_sse_builtins): Add special_args2.
7545 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
7546 TARGET_WBNOINVD_P): New.
7547 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
7548 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
7549 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
7550 * config/i386/immintrin.h (_wbinvd): New intrinsic.
7551 * config/i386/pconfigintrin.h: New file.
7552 * config/i386/wbnoinvdintrin.h: Ditto.
7553 * config/i386/x86intrin.h: Add headers pconfigintrin.h and wbnoinvdintrin.h.
7554 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
7555
7556 2018-03-05 Richard Biener <rguenther@suse.de>
7557
7558 PR tree-optimization/84670
7559 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
7560 member.
7561 (BB_VISITED_WITH_VISITED_SUCCS): New define.
7562 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
7563 (compute_antic_aux): Only assert the number of values in ANTIC_IN
7564 doesn't grow if all successors (recursively) were visited at least
7565 once.
7566
7567 2018-03-05 Richard Biener <rguenther@suse.de>
7568
7569 PR tree-optimization/84650
7570 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
7571 if executed in the loop pipeline.
7572
7573 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
7574
7575 * doc/configfiles.texi (Configuration Files): Move info about
7576 conditionalizing $target-protos.h to...
7577 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
7578 differs from $target-protos.h.
7579
7580 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
7581 Chung-Ju Wu <jasonwucj@gmail.com>
7582
7583 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
7584 * config/nds32/nds32-multiple.md (setmemsi): Define.
7585 * config/nds32/nds32-memory-manipulation.c
7586 (nds32_gen_dup_4_byte_to_word_value): New.
7587 (emit_setmem_word_loop): New.
7588 (emit_setmem_byte_loop): New.
7589 (nds32_expand_setmem_loop): New.
7590 (nds32_expand_setmem_loop_v3m): New.
7591 (nds32_expand_setmem_unroll): New.
7592 (nds32_expand_setmem): New.
7593
7594 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
7595 Chung-Ju Wu <jasonwucj@gmail.com>
7596
7597 * config/nds32/nds32-memory-manipulation.c
7598 (nds32_emit_load_store): New.
7599 (nds32_emit_post_inc_load_store): New.
7600 (nds32_emit_mem_move): New.
7601 (nds32_emit_mem_move_block): New.
7602 (nds32_expand_movmemsi_loop_unknown_size): New.
7603 (nds32_expand_movmemsi_loop_known_size): New.
7604 (nds32_expand_movmemsi_loop): New.
7605 (nds32_expand_movmemsi_unroll): New.
7606 (nds32_expand_movmemqi): Rename ...
7607 (nds32_expand_movmemsi): ... to this.
7608 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
7609 (movmemsi): ... to this.
7610 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
7611 (nds32_expand_movmemsi): ... to this.
7612
7613 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
7614 Monk Chiang <sh.chiang04@gmail.com>
7615 Chung-Ju Wu <jasonwucj@gmail.com>
7616
7617 * config/nds32/nds32-protos.h
7618 (nds32_expand_load_multiple): New arguments.
7619 (nds32_expand_store_multiple): Ditto.
7620 (nds32_valid_multiple_load_store): Rename ...
7621 (nds32_valid_multiple_load_store_p): ... to this.
7622 * config/nds32/nds32-memory-manipulation.c
7623 (nds32_expand_load_multiple): Refine implementation.
7624 (nds32_expand_store_multiple): Ditto.
7625 * config/nds32/nds32-multiple.md
7626 (load_multiple): Update nds32_expand_load_multiple interface.
7627 (store_multiple): Update nds32_expand_store_multiple interface.
7628 * config/nds32/nds32-predicates.c
7629 (nds32_valid_multiple_load_store): Rename ...
7630 (nds32_valid_multiple_load_store_p): ... to this and refine
7631 implementation.
7632 * config/nds32/predicates.md
7633 (nds32_load_multiple_and_update_address_operation): New predicate.
7634 (nds32_store_multiple_and_update_address_operation): New predicate.
7635
7636 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
7637 Chung-Ju Wu <jasonwucj@gmail.com>
7638
7639 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
7640 (combo): New attribute.
7641 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
7642
7643 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
7644
7645 * config/nds32/nds32.opt: Change -mcmodel= default value.
7646
7647 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
7648 Monk Chiang <sh.chiang04@gmail.com>
7649 Chung-Ju Wu <jasonwucj@gmail.com>
7650
7651 * config/nds32/constants.md (unspec_element): New enum.
7652 * config/nds32/constraints.md (Umw): New constraint.
7653 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
7654 * config/nds32/nds32-intrinsic.md: Likewise.
7655 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
7656 (nds32_valid_smw_lwm_base_p): New.
7657 (nds32_output_smw_single_word): New.
7658 (nds32_output_lmw_single_word): New.
7659 (nds32_expand_unaligned_load): New.
7660 (nds32_expand_unaligned_store): New.
7661 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
7662 (nds32_output_smw_single_word): Declare.
7663 (nds32_output_lmw_single_word): Declare.
7664 (nds32_expand_unaligned_load): Declare.
7665 (nds32_expand_unaligned_store): Declare.
7666 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
7667 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
7668 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
7669 NDS32_BUILTIN_UASTORE_DW.
7670 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
7671 predicate.
7672
7673 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
7674 Kito Cheng <kito.cheng@gmail.com>
7675 Chung-Ju Wu <jasonwucj@gmail.com>
7676
7677 * config/nds32/nds32-intrinsic.c
7678 (nds32_expand_builtin_null_ftype_reg): Delete.
7679 (nds32_expand_builtin_reg_ftype_imm): Ditto.
7680 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
7681 (nds32_read_argument): New.
7682 (nds32_legitimize_target): Ditto.
7683 (nds32_legitimize_argument): Ditto.
7684 (nds32_check_constant_argument): Ditto.
7685 (nds32_expand_unop_builtin): Ditto.
7686 (nds32_expand_unopimm_builtin): Ditto.
7687 (nds32_expand_binop_builtin): Ditto.
7688 (nds32_builtin_decl_impl): Ditto.
7689 (builtin_description): Ditto.
7690 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
7691 (nds32_init_builtins_impl): Ditto.
7692 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
7693 (nds32_builtin_decl): New.
7694 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
7695 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
7696
7697 2018-03-02 Jeff Law <law@redhat.com>
7698
7699 * reorg.c (stop_search_p): Handle DEBUG_INSN.
7700 (redundant_insn, fill_simple_delay_slots): Likewise.
7701 (fill_slots_from_thread): Likewise.
7702 * resource.c (mark_referenced_resources): Likewise.
7703 (mark_set_resources, find_dead_or_set_registers): Likewise.
7704
7705 2018-03-02 Jakub Jelinek <jakub@redhat.com>
7706
7707 * substring-locations.h (format_warning_va): Formatting fix for
7708 ATTRIBUTE_GCC_DIAG.
7709 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
7710 argument.
7711 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
7712 * substring-locations.c: Include intl.h.
7713 (format_warning_va): Turned into small wrapper around
7714 format_warning_n_va, renamed to ...
7715 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
7716 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
7717 use ngettext.
7718 (format_warning_at_substring_n): New function.
7719 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
7720 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
7721 format_warning_at_substring with just a shorter name instead of
7722 const function pointer.
7723 (fmtwarn_n): New function.
7724 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
7725 appropriate, get rid of all the fmtstr temporaries, move conditionals
7726 with G_() wrapped string literals directly into fmtwarn arguments,
7727 cast dir.len to (int), formatting fixes.
7728
7729 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
7730
7731 * doc/invoke.texi: Remove "Cilk Plus" references.
7732
7733 2018-03-02 Jakub Jelinek <jakub@redhat.com>
7734 Richard Biener <rguenther@suse.de>
7735
7736 PR ipa/84628
7737 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
7738 for error or warning attributes if CALL_FROM_THUNK_P is set.
7739 Formatting fixes.
7740
7741 2018-03-02 Jakub Jelinek <jakub@redhat.com>
7742
7743 PR target/56540
7744 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
7745 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
7746
7747 PR target/56540
7748 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
7749 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
7750
7751 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
7752 instead of -1U in last predictors element's probability member.
7753
7754 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
7755
7756 PR ipa/83983
7757 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
7758 arguments if they are comparable.
7759
7760 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
7761
7762 PR tree-optimization/84634
7763 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
7764 masks and masked_loop_p with a single loop_masks, making sure it's
7765 null for bb vectorization.
7766
7767 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
7768
7769 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
7770 (vect_analyze_data_ref_access): Use loop->safe_len rather than
7771 loop->force_vectorize to check whether there is no alias.
7772
7773 2018-03-02 Jakub Jelinek <jakub@redhat.com>
7774
7775 PR target/84614
7776 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
7777 prototypes.
7778 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
7779 comments.
7780 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
7781 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
7782 instead of a loop around prev_real_insn.
7783 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
7784 prev_real_insn.
7785
7786 PR inline-asm/84625
7787 * config/i386/i386.c (ix86_print_operand): Use conditional
7788 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
7789 zero vector.
7790
7791 2018-03-02 Richard Biener <rguenther@suse.de>
7792
7793 PR tree-optimization/84427
7794 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
7795 (bitmap_set_subtract_values): Rewrite to handle multiple
7796 exprs per value.
7797 (clean): Likewise.
7798 (prune_clobbered_mems): Likewise.
7799 (phi_translate): Take edge instead of pred/phiblock.
7800 (phi_translate_1): Likewise.
7801 (phi_translate_set): Likewise. Insert all translated
7802 exprs for a value into the set, keeping possibly multiple
7803 expressions per value.
7804 (compute_antic_aux): Adjust for phi_translate changes.
7805 When intersecting union the expressions and prune those
7806 not in the final value set, keeping possibly multiple
7807 expressions per value. Do not use value-insertion
7808 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
7809 all expressions. Add verification that the value-sets
7810 only shrink during iteration.
7811 (compute_partial_antic_aux): Adjust for the phi_translate changes.
7812 (do_pre_regular_insertion): Likewise.
7813 (do_pre_partial_partial_insertion): Likewise.
7814
7815 2018-03-02 Richard Biener <rguenther@suse.de>
7816
7817 PR target/82005
7818 * config/darwin.c (saved_debug_info_level): New static global.
7819 (darwin_asm_lto_start): Disable debug info generation for LTO out.
7820 (darwin_asm_lto_end): Restore debug info generation settings.
7821
7822 2018-03-01 Martin Liska <mliska@suse.cz>
7823
7824 PR sanitizer/82484
7825 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
7826 volatile arguments.
7827
7828 2018-03-01 Richard Biener <rguenther@suse.de>
7829
7830 PR debug/84645
7831 * dwarf2out.c (gen_variable_die): Properly handle late VLA
7832 type annotation with LTO when debug was disabled at compile-time.
7833
7834 2018-03-01 Matthew Fortune <mfortune@gmail.com>
7835
7836 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
7837 XINT with INTVAL.
7838 (mips_final_postscan_insn): Likewise.
7839
7840 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
7841
7842 PR rtl-optimization/84528
7843 * alias.c (init_alias_target): Add commentary.
7844 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
7845 a unique base value if the frame pointer is not eliminated
7846 to the stack pointer.
7847
7848 2018-03-01 Tom de Vries <tom@codesourcery.com>
7849
7850 PR rtl-optimization/83327
7851 * lra-int.h (hard_regs_spilled_into): Declare.
7852 * lra.c (hard_regs_spilled_into): Define.
7853 (init_reg_info): Init hard_regs_spilled_into.
7854 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
7855 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
7856 (process_bb_lives): Handle hard_regs_spilled_into.
7857 (lra_create_live_ranges_1): Before doing liveness propagation, clear
7858 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
7859
7860 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
7861
7862 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
7863 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
7864 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
7865 * config/rs6000/aix72.h: New file.
7866
7867 2018-02-28 Jakub Jelinek <jakub@redhat.com>
7868
7869 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
7870 instead of warning_at with conditional singular and plural messages
7871 where possible.
7872
7873 PR target/52991
7874 * stor-layout.c (update_alignment_for_field): For
7875 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
7876 && !DECL_PACKED (field), do the alignment update, just use
7877 only desired_align instead of MAX (type_align, desired_align)
7878 as the alignment.
7879 (place_field): Don't do known_align < desired_align handling
7880 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
7881 is non-NULL, instead do it after rli->prev_field handling and
7882 only if not within a bitfield word. For DECL_PACKED (field)
7883 use type_align of BITS_PER_UNIT.
7884
7885 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
7886
7887 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
7888 superfluous parentheses and trailing spaces.
7889
7890 2018-02-28 Richard Biener <rguenther@suse.de>
7891
7892 PR tree-optimization/84584
7893 * graphite-scop-detection.c (scop_detection::add_scop): Discard
7894 SCoPs with fake exit edge.
7895
7896 2018-02-28 Martin Liska <mliska@suse.cz>
7897
7898 PR testsuite/84597
7899 * timevar.c (timer::print): Fix format to properly print 100%
7900 values.
7901
7902 2018-02-28 Richard Biener <rguenther@suse.de>
7903
7904 PR middle-end/84607
7905 * genmatch.c (capture_info::walk_match): Do not mark
7906 captured expressions without operands as expr_p given
7907 they act more like predicates and should be subject to
7908 "lost tail" side-effect preserving.
7909
7910 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
7911
7912 PR rtl-optimization/81611
7913 * auto-inc-dec.c (attempt_change): Move dead note from
7914 mem_insn if it's the next use of regno
7915 (find_address): Take address use of reg holding
7916 non-incremented value. Add parm to limit search to the named
7917 reg only.
7918 (merge_in_block): Attempt to use a mem insn that is the next
7919 use of the original regno.
7920
7921 2018-02-27 Martin Sebor <msebor@redhat.com>
7922
7923 PR c++/83871
7924 * gcc/doc/invoke.texi (-Wmissing-attributes): New option.
7925 * gcc/print-tree.c (print_node): Handle DECL_UNINLINABLE.
7926
7927 2018-02-27 Martin Sebor <msebor@redhat.com>
7928
7929 PR translation/84207
7930 * diagnostic-core.h (warning_n, error_n, inform_n): Change
7931 n argument to unsigned HOST_WIDE_INT.
7932 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
7933 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
7934 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
7935 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
7936
7937 2018-02-27 Richard Biener <rguenther@suse.de>
7938
7939 PR tree-optimization/84512
7940 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
7941 Do not use the estimate returned from record_stmt_cost for
7942 the scalar iteration cost but sum properly using add_stmt_cost.
7943
7944 2018-02-27 Richard Biener <rguenther@suse.de>
7945
7946 PR tree-optimization/84466
7947 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
7948 Adjust last change to less strictly validate use operands.
7949
7950 2018-02-27 Martin Liska <mliska@suse.cz>
7951
7952 PR gcov-profile/84548
7953 * gcov.c (process_file): Allow partial overlap and consider it
7954 also as group functions.
7955 (output_lines): Properly calculate range of lines for a group.
7956
7957 2018-02-27 Martin Liska <mliska@suse.cz>
7958
7959 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
7960 'ggc' suffixes. Change first column width.
7961 (timer::print): Fix formatting of the column.
7962
7963 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
7964
7965 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
7966 preserve inline entry blocks for the sake of debug inline
7967 entry point markers alone.
7968 (remove_unused_locals): Suggest in comments a better place to
7969 force the preservation of inline entry blocks that are
7970 otherwise unused, but do not preserve them.
7971
7972 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
7973
7974 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
7975
7976 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
7977
7978 PR target/84039
7979 * config/i386/constraints.md (Bs): Replace
7980 ix86_indirect_branch_register with
7981 TARGET_INDIRECT_BRANCH_REGISTER.
7982 (Bw): Likewise.
7983 * config/i386/i386.md (indirect_jump): Likewise.
7984 (tablejump): Likewise.
7985 (*sibcall_memory): Likewise.
7986 (*sibcall_value_memory): Likewise.
7987 Peepholes of indirect call and jump via memory: Likewise.
7988 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
7989 (*sibcall_value_GOT_32): Likewise.
7990 * config/i386/predicates.md (indirect_branch_operand): Likewise.
7991 (GOT_memory_operand): Likewise.
7992 (call_insn_operand): Likewise.
7993 (sibcall_insn_operand): Likewise.
7994 (GOT32_symbol_operand): Likewise.
7995 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
7996
7997 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
7998
7999 PR rtl-optimization/83496
8000 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
8001 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
8002 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
8003 redundant insn, if any.
8004 (relax_delay_slots): Likewise.
8005 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
8006
8007 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
8008
8009 PR tree-optimization/83965
8010 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
8011 that grouped statements are part of a reduction chain. Return
8012 true if the statement is not marked as a reduction itself but
8013 is part of a group.
8014 (vect_recog_dot_prod_pattern): Don't check whether the statement
8015 is part of a group here.
8016 (vect_recog_sad_pattern): Likewise.
8017 (vect_recog_widen_sum_pattern): Likewise.
8018
8019 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
8020
8021 PR debug/84545
8022 * final.c (rest_of_clean_state): Also look for calls inside sequences.
8023
8024 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
8025
8026 PR target/84530
8027 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
8028 the bool argument.
8029 (ix86_output_indirect_function_return): New prototype.
8030 (ix86_split_simple_return_pop_internal): Likewise.
8031 * config/i386/i386.c (indirect_return_via_cx): New.
8032 (indirect_return_via_cx_bnd): Likewise.
8033 (indirect_thunk_name): Handle return va CX_REG.
8034 (output_indirect_thunk_function): Create alias for
8035 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
8036 (ix86_output_indirect_jmp): Remove the bool argument.
8037 (ix86_output_indirect_function_return): New function.
8038 (ix86_split_simple_return_pop_internal): Likewise.
8039 * config/i386/i386.md (*indirect_jump): Don't pass false
8040 to ix86_output_indirect_jmp.
8041 (*tablejump_1): Likewise.
8042 (simple_return_pop_internal): Change it to define_insn_and_split.
8043 Call ix86_split_simple_return_pop_internal to split it for
8044 -mfunction-return=.
8045 (simple_return_indirect_internal): Call
8046 ix86_output_indirect_function_return instead of
8047 ix86_output_indirect_jmp.
8048
8049 2018-02-26 Jakub Jelinek <jakub@redhat.com>
8050
8051 PR bootstrap/84405
8052 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
8053 memset and value initialization afterwards.
8054
8055 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
8056
8057 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
8058
8059 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
8060
8061 PR target/84521
8062 * common/config/aarch64/aarch64-common.c
8063 (aarch_option_optimization_table[]): Switch
8064 off fomit-frame-pointer
8065
8066 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
8067 Chung-Ju Wu <jasonwucj@gmail.com>
8068
8069 * config/nds32/nds32-multiple.md (load_multiple): Disallow
8070 volatile memory.
8071 (store_multiple): Ditto.
8072
8073 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
8074
8075 * config.gcc: Add --with-cpu support for nds32 target.
8076 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
8077 * config/nds32/nds32.opt: Add -mcpu= option.
8078
8079 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
8080
8081 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
8082 isel=yes): Warn for these deprecated options.
8083
8084 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
8085
8086 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
8087 ISA_2_5_MASKS_EMBEDDED.
8088
8089 2018-02-23 Jakub Jelinek <jakub@redhat.com>
8090
8091 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
8092 p->max as pointers rather than using iterative_hash_expr.
8093
8094 2018-02-23 Carl Love <cel@us.ibm.com>
8095
8096 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
8097 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
8098 BU_P8V_OVERLOAD_2.
8099 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
8100 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
8101 P8V_BUILTIN_VEC_VUNSIGNED2.
8102
8103 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
8104
8105 PR target/81572
8106 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
8107 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
8108 LRA_UNKNOWN_ALT.
8109 * lra-constraints.c (curr_insn_transform): Set up
8110 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
8111 LRA_UNKNOWN_ALT.
8112 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
8113 * lra-eliminations.c (spill_pseudos): Ditto.
8114 (process_insn_for_elimination): Ditto.
8115 * lra-lives.c (reg_early_clobber_p): Use the new macros.
8116 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
8117 LRA_NON_CLOBBERED_ALT.
8118
8119 2018-02-22 Martin Sebor <msebor@redhat.com>
8120
8121 PR tree-optimization/84480
8122 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
8123 to maybe_diag_stxncpy_trunc. Call it.
8124 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
8125 from gimple_fold_builtin_strcpy. Print inlining stack.
8126 (handle_builtin_stxncpy): Print inlining stack.
8127 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
8128
8129 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
8130
8131 PR target/84176
8132 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
8133 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
8134 and -fcheck-pointer-bounds are used together.
8135 (indirect_thunk_prefix): New enum.
8136 (indirect_thunk_need_prefix): New function.
8137 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
8138 "_nt" instead of "_bnd" for NOTRACK prefix.
8139 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
8140 (output_indirect_thunk_function): Likewise.
8141 (): Likewise.
8142 (ix86_code_end): Update output_indirect_thunk_function calls.
8143 (ix86_output_indirect_branch_via_reg): Replace
8144 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
8145 (ix86_output_indirect_branch_via_push): Likewise.
8146 (ix86_output_function_return): Likewise.
8147 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
8148 incompatible with -fcf-protection=branch and
8149 -fcheck-pointer-bounds.
8150
8151 2018-02-22 Steve Ellcey <sellcey@cavium.com>
8152
8153 PR target/83335
8154 * config/aarch64/aarch64.c (aarch64_print_address_internal):
8155 Change gcc_assert call to output_operand_lossage.
8156
8157 2018-02-22 Steve Ellcey <sellcey@cavium.com>
8158
8159 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
8160
8161 2018-02-22 DJ Delorie <dj@redhat.com>
8162 Sebastian Perta <sebastian.perta@renesas.com>
8163 Oleg Endo <olegendo@gcc.gnu.org>
8164
8165 * config/rx/rx.c (rx_rtx_costs): New function.
8166 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
8167
8168 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
8169
8170 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
8171
8172 2018-02-22 Martin Liska <mliska@suse.cz>
8173
8174 PR driver/83193
8175 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
8176 Add "native" as a possible value.
8177
8178 2018-02-22 Martin Liska <mliska@suse.cz>
8179
8180 PR driver/83193
8181 * config/i386/i386.c (ix86_option_override_internal):
8182 Add "native" as a possible value for -march and -mtune.
8183
8184 2018-02-22 Jakub Jelinek <jakub@redhat.com>
8185
8186 PR target/84502
8187 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
8188 to all type variants.
8189
8190 PR tree-optimization/84503
8191 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
8192 width as info->bitpos + info->bitsize - start.
8193 (merged_store_group::merge_overlapping): Simplify width computation.
8194 (check_no_overlap): New function.
8195 (imm_store_chain_info::try_coalesce_bswap): Compute expected
8196 start + width and last_order of the group, fail if check_no_overlap
8197 fails.
8198 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
8199 to group if check_no_overlap fails.
8200
8201 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
8202
8203 * config/rs6000/altivec.md: Delete contraint arguments to
8204 define_expand, define_split, and define_peephole2, and in
8205 define_insn_and_split if always unused.
8206 * config/rs6000/darwin.md: Ditto.
8207 * config/rs6000/dfp.md: Ditto.
8208 * config/rs6000/rs6000.md: Ditto.
8209 * config/rs6000/sync.md: Ditto.
8210 * config/rs6000/vector.md: Ditto.
8211 * config/rs6000/vsx.md: Ditto.
8212
8213 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
8214
8215 * config/rs6000/altivec.md: Write output control strings as braced
8216 blocks instead of double-quoted strings.
8217 * config/rs6000/darwin.md: Ditto.
8218 * config/rs6000/rs6000.md: Ditto.
8219 * config/rs6000/vector.md: Ditto.
8220 * config/rs6000/vsx.md: Ditto.
8221
8222 2018-02-21 Jason Merrill <jason@redhat.com>
8223
8224 PR c++/84314 - ICE with templates and fastcall attribute.
8225 * attribs.c (build_type_attribute_qual_variant): Remove assert.
8226
8227 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
8228
8229 * ipa-cp.c (determine_versionability): Fix comment typos.
8230
8231 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
8232
8233 PR c/84229
8234 * ipa-cp.c (determine_versionability): Do not version functions caling
8235 va_arg_pack.
8236
8237 2018-02-21 Martin Liska <mliska@suse.cz>
8238
8239 PR driver/83193
8240 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
8241 Add "native" as a possible value.
8242 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
8243 the macro when native cpu detection is available.
8244
8245 2018-02-21 Martin Liska <mliska@suse.cz>
8246
8247 PR driver/83193
8248 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
8249 Add "native" as a possible value.
8250 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
8251 when native cpu detection is available.
8252
8253 2018-02-21 Jakub Jelinek <jakub@redhat.com>
8254 Martin Sebor <msebor@redhat.com>
8255
8256 PR tree-optimization/84478
8257 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
8258 false.
8259 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
8260 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
8261 support which is conservatively correct, for 2 only stay conservative
8262 for maxlen. Formatting and comment capitalization fixes. Add STRICT
8263 argument to the 2 argument get_range_strlen, adjust 6 arg
8264 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
8265 false.
8266 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
8267 (gimple_fold_builtin_strlen): Pass true as last argument to
8268 get_range_strlen.
8269
8270 2018-02-20 Martin Sebor <msebor@redhat.com>
8271
8272 PR middle-end/84095
8273 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
8274 (builtin_memref::set_base_and_offset): Same. Handle inner references.
8275 (builtin_memref::builtin_memref): Factor out parts into
8276 set_base_and_offset and call it.
8277
8278 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
8279
8280 PR middle-end/84406
8281 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
8282 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
8283 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
8284 search at the associated MODE_INT.
8285
8286 2018-02-20 Jeff Law <law@redhat.com>
8287
8288 PR middle-end/82123
8289 PR tree-optimization/81592
8290 PR middle-end/79257
8291 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
8292 for range data rather than using global data.
8293 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
8294 range data rather than using global data.
8295 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
8296 pass it to children as needed.
8297 (struct directive::fmtresult): Similarly.
8298 (struct directive::set_width): Similarly.
8299 (struct directive::set_precision): Similarly.
8300 (format_integer, format_directive, parse_directive): Similarly.
8301 (format_none): Accept unnamed vr_values parameter.
8302 (format_percent, format_floating, format_character): Similarly.
8303 (format_string, format_plain): Similarly.
8304 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
8305 the EVRP range analyzer for range data rather than using global data.
8306 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
8307 gimple-ssa-evrp-analyze.h
8308 (class sprintf_dom_walker): Add after_dom_children member function.
8309 Add evrp_range_analyzer member.
8310 (sprintf_dom_walker::before_dom_children): Call into the EVRP
8311 range analyzer as needed.
8312 (sprintf_dom_walker::after_dom_children): New member function.
8313 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
8314 if not optimizing.
8315 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
8316 (evrp_range_analyzer::pop_to_marker): Likewise.
8317
8318 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
8319
8320 PR tree-optimization/84419
8321 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
8322 with the required type if its current type is compatible but
8323 different.
8324
8325 2018-02-20 Jakub Jelinek <jakub@redhat.com>
8326
8327 PR middle-end/82004
8328 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
8329 after vectorization.
8330
8331 2018-02-20 Martin Liska <mliska@suse.cz>
8332
8333 PR driver/83193
8334 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
8335 possible values if we don't have a hint.
8336
8337 2018-02-20 Martin Liska <mliska@suse.cz>
8338
8339 PR c/84310
8340 PR target/79747
8341 * final.c (shorten_branches): Build align_tab array with one
8342 more element.
8343 * opts.c (finish_options): Add alignment option limit check.
8344 (MAX_CODE_ALIGN): Likewise.
8345 (MAX_CODE_ALIGN_VALUE): Likewise.
8346 * doc/invoke.texi: Document maximum allowed option value for
8347 all -falign-* options.
8348
8349 2018-02-19 Jakub Jelinek <jakub@redhat.com>
8350
8351 PR target/84146
8352 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
8353 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
8354 * var-tracking.c (emit_note_insn_var_location): Remove all references
8355 to NOTE_INSN_CALL_ARG_LOCATION.
8356 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
8357 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
8358 Use copy_rtx_if_shared.
8359 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
8360 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
8361 (dwarf2out_var_location): Remove handling of
8362 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
8363 on call_insn.
8364 * final.c (final_scan_insn): Remove all references to
8365 NOTE_INSN_CALL_ARG_LOCATION.
8366 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
8367 before dumping final insns.
8368 * except.c (emit_note_eh_region_end): Remove all references to
8369 NOTE_INSN_CALL_ARG_LOCATION.
8370 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
8371 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
8372 * config/arc/arc.c (hwloop_optimize): Likewise.
8373 * config/arm/arm.c (create_fix_barrier): Likewise.
8374 * config/s390/s390.c (s390_chunkify_start): Likewise.
8375 * config/sh/sh.c (find_barrier): Likewise.
8376 * config/i386/i386.c (rest_of_insert_endbranch,
8377 ix86_seh_fixup_eh_fallthru): Likewise.
8378 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
8379 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
8380 * config/frv/frv.c (frv_function_prologue): Likewise.
8381 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
8382 reg note.
8383 (note_outside_basic_block_p): Remove all references to
8384 NOTE_INSN_CALL_ARG_LOCATION.
8385 * gengtype.c (adjust_field_rtx_def): Likewise.
8386 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
8387 Likewise.
8388 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
8389 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
8390
8391 PR c++/84444
8392 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
8393 is ADDR_EXPR.
8394
8395 PR tree-optimization/84452
8396 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
8397 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
8398 is NULL.
8399
8400 2018-02-19 Martin Liska <mliska@suse.cz>
8401
8402 PR sanitizer/82183
8403 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
8404
8405 2018-02-19 Martin Liska <mliska@suse.cz>
8406 Richard Sandiford <richard.sandiford@linaro.org>
8407
8408 PR tree-optimization/82491
8409 * gimple-fold.c (get_base_constructor): Make earlier bail out
8410 to prevent ubsan.
8411
8412 2018-02-19 Carl Love <cel@us.ibm.com>
8413
8414 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
8415 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
8416 BU_P8V_OVERLOAD_1.
8417 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
8418 P8V_BUILTIN_VEC_NEG.
8419
8420 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
8421
8422 * config/rl78/rl78.md (movdf): New define expand.
8423
8424 2018-02-19 Martin Liska <mliska@suse.cz>
8425
8426 PR other/80589
8427 * doc/invoke.texi: Fix typo.
8428 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
8429
8430 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
8431
8432 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
8433 handle rs6000_single_float and rs6000_double_float specially for
8434 e500 family CPUs.
8435
8436 2018-02-16 Jeff Law <law@redhat.com>
8437
8438 * config/rx/rx.c (add_pop_cfi_notes): New function.;
8439 (pop_regs): Use it.
8440
8441 2018-02-16 Jakub Jelinek <jakub@redhat.com>
8442
8443 PR ipa/84425
8444 * ipa-inline.c (inline_small_functions): Fix a typo.
8445
8446 2018-02-16 Nathan Sidwell <nathan@acm.org>
8447
8448 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
8449
8450 2018-02-16 Carl Love <cel@us.ibm.com>
8451
8452 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
8453 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
8454 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
8455 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
8456 expansion to P8V_BUILTIN_VEC_FLOAT2.
8457
8458 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
8459
8460 PR rtl-optimization/70023
8461 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
8462 src_regno into account.
8463
8464 2018-02-16 Carl Love <cel@us.ibm.com>
8465
8466 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
8467 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
8468 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
8469 * config/rs6000/rs6000.c: Remove case statements for
8470 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
8471 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
8472 and P9V_BUILTIN_VEC_VINSERT4B.
8473 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
8474 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
8475 * config/rs6000/vsx.md:
8476 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
8477 vec_insert4b.
8478
8479 2018-02-16 Carl Love <cel@us.ibm.com>
8480
8481 * config/rs6000/altivec.h: Add builtin names vec_extract4b
8482 vec_insert4b.
8483 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
8484 definitions.
8485 * config/rs6000/rs6000-c.c: Add the definitions for
8486 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
8487 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
8488 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
8489 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
8490 definition for insert4b and define insn *insert3b_internal.
8491 * doc/extend.texi: Add documentation for vec_extract4b.
8492
8493 2018-02-16 Nathan Sidwell <nathan@acm.org>
8494
8495 * doc/extend.texi (Backwards Compatibility): Mention friend
8496 injection. Note for-scope is deprecated.
8497 * doc/invoke.texi (-ffriend-injection): Deprecate.
8498
8499 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
8500
8501 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
8502 that moved to I2, also allow destinations that are a paradoxical
8503 subreg (instead of a normal reg).
8504
8505 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
8506
8507 PR target/83831
8508 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
8509 to QImode.
8510
8511 2018-02-16 Richard Biener <rguenther@suse.de>
8512
8513 PR tree-optimization/84037
8514 PR tree-optimization/84016
8515 PR target/82862
8516 * config/i386/i386.c (ix86_builtin_vectorization_cost):
8517 Adjust vec_construct for the fact we need additional higher latency
8518 128bit inserts for AVX256 and AVX512 vector builds.
8519 (ix86_add_stmt_cost): Scale vector construction cost for
8520 elementwise loads.
8521
8522 2018-02-16 Richard Biener <rguenther@suse.de>
8523
8524 PR tree-optimization/84417
8525 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
8526 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
8527 (non_rewritable_lvalue_p): Likewise, use poly-ints.
8528
8529 2018-02-16 Martin Liska <mliska@suse.cz>
8530
8531 PR sanitizer/84307
8532 * internal-fn.def (ASAN_CHECK): Set proper flags.
8533 (ASAN_MARK): Likewise.
8534
8535 2018-02-16 Julia Koval <julia.koval@intel.com>
8536
8537 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
8538 from PTA_CANNONLAKE.
8539
8540 2018-02-16 Jakub Jelinek <jakub@redhat.com>
8541
8542 PR target/84272
8543 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
8544 Use ++iter rather than iter++ for std::list iterators.
8545 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
8546 defer deleting them until all nodes in the forest are processed. Do
8547 free even leaf nodes. Change to_process into auto_vec.
8548
8549 PR bootstrap/84405
8550 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
8551 * vec.h (vec_default_construct): Use memset instead of placement new
8552 if BROKEN_VALUE_INITIALIZATION is defined.
8553 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
8554 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
8555 is defined.
8556
8557 PR rtl-optimization/83723
8558 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
8559 * lra.c (lra_substitute_pseudo): Likewise. If true, use
8560 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
8561 recursive calls.
8562 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
8563 callers.
8564 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
8565
8566 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
8567
8568 PR rtl-optimization/81443
8569 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
8570 from inner REGs to paradoxical SUBREGs.
8571
8572 2018-02-16 Richard Biener <rguenther@suse.de>
8573
8574 PR tree-optimization/84399
8575 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
8576 For operands we can analyze at their definition make sure we can
8577 analyze them at each use as well.
8578
8579 2018-02-16 Richard Biener <rguenther@suse.de>
8580
8581 PR tree-optimization/84190
8582 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
8583 volatile accesses if the decl isn't volatile.
8584
8585 2018-02-15 Jason Merrill <jason@redhat.com>
8586
8587 PR c++/84314 - ICE with templates and fastcall attribute.
8588 * attribs.c (build_type_attribute_qual_variant): Don't clobber
8589 TYPE_CANONICAL on an existing type.
8590
8591 2018-02-15 Jakub Jelinek <jakub@redhat.com>
8592
8593 PR tree-optimization/84383
8594 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
8595 dstoff nor call operand_equal_p if dstbase is NULL.
8596
8597 PR tree-optimization/84334
8598 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
8599 also a CONSTANT_CLASS_P, punt.
8600
8601 2018-02-14 Jim Wilson <jimw@sifive.com>
8602
8603 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
8604 first SMALL_OPERAND check. New local min_second_step. Move assert
8605 to where locals are set. Add TARGET_RVC support.
8606 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
8607
8608 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
8609
8610 * doc/invoke.texi: Correct -Wformat-overflow code sample.
8611
8612 2018-02-14 Martin Sebor <msebor@redhat.com>
8613
8614 PR tree-optimization/83698
8615 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
8616 arrays constrain the offset range to their bounds.
8617 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
8618 (builtin_access::overlap): Avoid setting the size of overlap if it's
8619 already been set.
8620 (maybe_diag_overlap): Also consider arrays when deciding what values
8621 of offsets to include in diagnostics.
8622
8623 2018-02-14 Martin Sebor <msebor@redhat.com>
8624
8625 PR c/84108
8626 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
8627 that correspond to the kind of a declaration.
8628
8629 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
8630
8631 PR target/83984
8632 * config/pa/pa.md: Load address of PIC label using the linkage table
8633 if the label is nonlocal.
8634
8635 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
8636
8637 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
8638 warning message if user requests -maltivec=be.
8639 * doc/invoke.texi: Document deprecation of -maltivec=be.
8640
8641 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
8642
8643 PR target/84220
8644 * config/rs6000/rs6000-c.c: Update definitions for
8645 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
8646 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
8647
8648 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
8649
8650 PR target/84239
8651 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
8652 add _get_ssp intrinsics. Remove argument from
8653 __builtin_ia32_rdssp[d|q].
8654 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
8655 * config/i386/i386-builtin.def: Remove argument from
8656 __builtin_ia32_rdssp[d|q].
8657 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
8658 ix86_expand_special_args_builtin for _rdssp[d|q].
8659 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
8660 Clear register before usage.
8661 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
8662 Add documentation for new _get_ssp and _inc_ssp intrinsics.
8663
8664 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
8665
8666 PR tree-optimization/84357
8667 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
8668 operand 1 of an ARRAY_REF too.
8669
8670 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
8671
8672 PR target/83831
8673 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
8674 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
8675 declarations.
8676 (set_of_reg): New struct.
8677 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
8678 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
8679 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
8680 functions.
8681 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
8682 Split into bitclr, bitset, bitinvert patterns if appropriate.
8683 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
8684 use rx_fuse_in_memory_bitop.
8685 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
8686 to named insn, correct maximum insn length.
8687
8688 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
8689
8690 PR target/79242
8691 * machmode.def: Define a complex mode for PARTIAL_INT.
8692 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
8693 MODE_PARTIAL_INT.
8694 * doc/rtl.texi: Document CSPImode.
8695 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
8696 handling.
8697 (msp430_hard_regno_nregs_with_padding): Likewise.
8698
8699 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
8700
8701 PR target/84279
8702 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
8703
8704 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
8705
8706 PR rtl-optimization/84169
8707 * combine.c (try_combine): New variable split_i2i3. Set it to true if
8708 we generated a parallel as new i3 and we split that to new i2 and i3
8709 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
8710 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
8711 those to i2, not i1. Partially rewrite this scan code.
8712
8713 2018-02-13 Jakub Jelinek <jakub@redhat.com>
8714
8715 PR c/82210
8716 * stor-layout.c (place_field): For variable length fields, adjust
8717 offset_align afterwards not just based on the field's alignment,
8718 but also on the size.
8719
8720 PR middle-end/84309
8721 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
8722 of exps and logs in the use_exp2 case.
8723
8724 2018-02-13 Jeff Law <law@redhat.com>
8725
8726 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
8727 entry for "vector".
8728
8729 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
8730 ARGS as unused.
8731
8732 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
8733
8734 PR debug/84342
8735 PR debug/84319
8736 * common.opt (gas-loc-support, gas-locview-support): New.
8737 (ginline-points, ginternal-reset-location-views): New.
8738 * doc/invoke.texi: Document them. Use @itemx where intended.
8739 (gvariable-location-views): Adjust.
8740 * target.def (reset_location_view): New.
8741 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
8742 (TARGET_RESET_LOCATION_VIEW): New.
8743 * doc/tm.texi: Rebuilt.
8744 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
8745 (dwarf2out_default_as_locview_support): New.
8746 (output_asm_line_debug_info): Use option variables.
8747 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
8748 (output_loc_list): Likewise.
8749 (add_high_low_attributes): Check option variables.
8750 Don't output entry view attribute in strict mode.
8751 (gen_inlined_subroutine_die): Check option variables.
8752 (dwarf2out_inline_entry): Likewise.
8753 (init_sections_and_labels): Likewise.
8754 (dwarf2out_early_finish): Likewise.
8755 (maybe_reset_location_view): New, from...
8756 (dwarf2out_var_location): ... here. Call it.
8757 * debug.h (dwarf2out_default_as_loc_support): Declare.
8758 (dwarf2out_default_as_locview_support): Declare.
8759 * hooks.c (hook_int_rtx_insn_0): New.
8760 * hooks.h (hook_int_rtx_insn_0): Declare.
8761 * toplev.c (process_options): Take -gas-loc-support and
8762 -gas-locview-support from dwarf2out. Enable
8763 -gvariable-location-views by default only with locview
8764 assembler support. Enable -ginternal-reset-location-views by
8765 default only if the target defines the corresponding hook.
8766 Enable -ginline-points by default if location views are
8767 enabled; force it disabled if statement frontiers are
8768 disabled.
8769 * tree-inline.c (expand_call_inline): Check option variables.
8770 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
8771
8772 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
8773
8774 PR tree-optimization/84321
8775 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
8776 handling. Also check whether the anti-range contains any values
8777 that satisfy the mask; switch to a VR_RANGE if not.
8778
8779 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
8780
8781 PR sanitizer/84340
8782 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
8783
8784 2018-02-13 Martin Jambor <mjambor@suse.cz>
8785
8786 PR c++/83990
8787 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
8788 of call statements, also set location of a load to a temporary.
8789
8790 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
8791
8792 * config/rl78/rl78.c (add_vector_labels): New function.
8793 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
8794 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
8795 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
8796 which checks that no arguments are passed.
8797 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
8798 * doc/extend.texi: Documentation for the new attribute.
8799
8800 2018-02-13 Andreas Schwab <schwab@suse.de>
8801
8802 * config/riscv/linux.h (CPP_SPEC): Define.
8803
8804 2018-02-13 Jakub Jelinek <jakub@redhat.com>
8805
8806 PR target/84335
8807 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
8808 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
8809 OPTION_MASK_ISA_AES as first argument to def_builtin_const
8810 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
8811 instead of OPTION_MASK_ISA_PCLMUL as first argument to
8812 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
8813 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
8814 temporarily for AES and PCLMUL builtins.
8815
8816 PR tree-optimization/84339
8817 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
8818 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
8819 Formatting fixes.
8820
8821 PR middle-end/84309
8822 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
8823 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
8824 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
8825 inline function.
8826 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
8827 inline function.
8828 * omp-simd-clone.h: New file.
8829 * omp-simd-clone.c: Include omp-simd-clone.h.
8830 (expand_simd_clones): No longer static.
8831 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
8832 cgraph.h and omp-simd-clone.h.
8833 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
8834 (vect_recog_widen_shift_pattern): Formatting fix.
8835 (vect_pattern_recog_1): Don't check optab for calls.
8836
8837 PR target/84336
8838 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
8839 operands[2] into a REG before using gen_lowpart on it.
8840
8841 2018-02-12 Jeff Law <law@redhat.com>
8842
8843 PR target/83760
8844 * config/sh/sh.c (find_barrier): Consider a sibling call
8845 a barrier as well.
8846
8847 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
8848 successfully back substituting a reg.
8849
8850 2018-02-12 Richard Biener <rguenther@suse.de>
8851
8852 PR tree-optimization/84037
8853 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
8854 parameter, move visited init to caller.
8855 (vect_slp_analyze_operations): Separate cost from validity
8856 check, initialize visited once for all instances.
8857 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
8858 for all instances.
8859 * tree-vect-stmts.c (vect_model_simple_cost): Make early
8860 out an assert.
8861 (vect_model_promotion_demotion_cost): Likewise.
8862 (vectorizable_bswap): Guard cost modeling with !slp_node
8863 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
8864 SLP stmts.
8865 (vectorizable_call): Likewise.
8866 (vectorizable_conversion): Likewise.
8867 (vectorizable_assignment): Likewise.
8868 (vectorizable_shift): Likewise.
8869 (vectorizable_operation): Likewise.
8870 (vectorizable_store): Likewise.
8871 (vectorizable_load): Likewise.
8872 (vectorizable_condition): Likewise.
8873 (vectorizable_comparison): Likewise.
8874
8875 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
8876
8877 PR sanitizer/84307
8878 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
8879 (ASAN_MARK): Fix fnspec to account for return value, change pointer
8880 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
8881
8882 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
8883
8884 PR middle-end/83665
8885 * params.def (inline-min-speedup): Increase from 8 to 15.
8886 (max-inline-insns-auto): Decrease from 40 to 30.
8887 * ipa-split.c (consider_split): Add some buffer for function to
8888 be considered inlining candidate.
8889 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
8890 default values.
8891
8892 2018-02-12 Richard Biener <rguenther@suse.de>
8893
8894 PR tree-optimization/84037
8895 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
8896 matched stmts if we cannot swap the non-matched ones.
8897
8898 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
8899
8900 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
8901 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
8902 _mm_maskz_scalef_round_ss): New intrinsics.
8903 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
8904 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
8905 __builtin_ia32_scalefss_round): Remove.
8906 (__builtin_ia32_scalefsd_mask_round,
8907 __builtin_ia32_scalefss_mask_round): New intrinsics.
8908 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
8909 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
8910 ((match_operand:VF_128 2 "<round_nimm_predicate>"
8911 "<round_constraint>")): Changed to ...
8912 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
8913 "<round_scalar_constraint>")): ... this.
8914 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
8915 %0, %1, %2<round_op3>}"): Changed to ...
8916 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
8917 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
8918 %2<round_scalar_mask_op3>}"): ... this.
8919 * config/i386/subst.md (round_scalar_nimm_predicate): New.
8920
8921 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
8922
8923 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
8924 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
8925 (_mm_maskz_sqrt_round_ss): New intrinsics.
8926 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
8927 (__builtin_ia32_sqrtsd_mask_round)
8928 (__builtin_ia32_sqrtss_mask_round): New builtins.
8929 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
8930 (__builtin_ia32_sqrtss_round): Remove.
8931 (__builtin_ia32_sqrtsd_mask_round)
8932 (__builtin_ia32_sqrtss_mask_round): New builtins.
8933 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
8934 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
8935 ((match_operand:VF_128 1 "vector_operand"
8936 "xBm,<round_constraint>")): Changed to ...
8937 ((match_operand:VF_128 1 "vector_operand"
8938 "xBm,<round_scalar_constraint>")): ... this.
8939 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
8940 %0, %2, %<iptr>1<round_op3>}): Changed to ...
8941 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
8942 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
8943 %<iptr>1<round_scalar_mask_op3>}): ... this.
8944 ((set_attr "prefix" "<round_prefix>")): Changed to ...
8945 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
8946
8947 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
8948
8949 PR target/84266
8950 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
8951 Cast vec_cmpeq result to correct type.
8952 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
8953 Cast vec_cmpgt result to correct type.
8954
8955 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
8956
8957 * final.c (final_scan_insn_1): Renamed from...
8958 (final_scan_insn): ... this. New wrapper, to recover
8959 seen from the outermost call in recursive ones.
8960 * config/sparc/sparc.c (output_return): Drop seen from call.
8961 (output_sibcall): Likewise.
8962 * config/visium/visium.c (output_branch): Likewise.
8963
8964 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
8965
8966 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
8967 function label.
8968
8969 2018-02-10 Alan Modra <amodra@gmail.com>
8970
8971 PR target/84300
8972 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
8973 Specify LR as an input.
8974
8975 2018-02-10 Jakub Jelinek <jakub@redhat.com>
8976
8977 PR sanitizer/83987
8978 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
8979 remove_member_access_dummy_vars): New functions.
8980 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
8981 lower_omp_1, execute_lower_omp): Use them.
8982
8983 PR rtl-optimization/84308
8984 * shrink-wrap.c (spread_components): Release todo vector.
8985
8986 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
8987
8988 PR rtl-optimization/57193
8989 * ira-color.c (struct allocno_color_data): Add member
8990 conflict_allocno_hard_prefs.
8991 (update_conflict_allocno_hard_prefs): New.
8992 (bucket_allocno_compare_func): Add a preference based on
8993 conflict_allocno_hard_prefs.
8994 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
8995 (color_allocnos): Remove a dead code. Initiate
8996 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
8997
8998 2018-02-09 Jakub Jelinek <jakub@redhat.com>
8999
9000 PR target/84226
9001 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
9002 constraint from =wa to wa. Avoid a subreg on the output operand,
9003 instead use a pseudo and subreg it in a move.
9004 (p9_xxbrd_<mode>): Changed to ...
9005 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
9006 (p9_xxbrd_v2df): New expander.
9007 (p9_xxbrw_<mode>): Changed to ...
9008 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
9009 (p9_xxbrw_v4sf): New expander.
9010
9011 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
9012
9013 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
9014
9015 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
9016
9017 PR target/83926
9018 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
9019 multiply in 32-bit mode.
9020 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
9021 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
9022 mode.
9023
9024 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
9025
9026 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
9027 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
9028 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
9029 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
9030
9031 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
9032
9033 PR lto/84213
9034 * dwarf2out.c (is_trivial_indirect_ref): New function.
9035 (dwarf2out_late_global_decl): Do not generate a location
9036 attribute for variables that have a non-trivial DECL_VALUE_EXPR
9037 and that are not defined in the current unit.
9038
9039 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
9040
9041 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
9042 instead of a libcall for UNORDERED.
9043
9044 2018-02-09 Tamar Christina <tamar.christina@arm.com>
9045
9046 PR target/82641
9047 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
9048 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
9049
9050 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
9051
9052 PR target/PR84295
9053 * config/s390/s390.c (s390_set_current_function): Invoke
9054 s390_indirect_branch_settings also if fndecl didn't change.
9055
9056 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
9057
9058 * config/rs6000/rs6000.md (blockage): Set length to zero.
9059
9060 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
9061
9062 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
9063
9064 2018-02-09 Jakub Jelinek <jakub@redhat.com>
9065
9066 PR sanitizer/84285
9067 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
9068 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
9069 -static-lib*san.
9070
9071 PR debug/84252
9072 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
9073 PARALLEL incoming that failed vt_get_decl_and_offset check.
9074
9075 PR middle-end/84237
9076 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
9077 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
9078 TREE_READONLY bit.
9079 (get_variable_section): For decls in named .bss* sections pass true as
9080 second argument to bss_initializer_p.
9081
9082 2018-02-09 Marek Polacek <polacek@redhat.com>
9083 Jakub Jelinek <jakub@redhat.com>
9084
9085 PR c++/83659
9086 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
9087 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
9088 Sync some changes from cxx_fold_indirect_ref.
9089
9090 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
9091
9092 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
9093 markers.
9094 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
9095 (BLOCK_INLINE_ENTRY_LABEL): New.
9096 (dwarf2out_var_location): Disregard inline entry markers.
9097 (inline_entry_data): New struct.
9098 (inline_entry_data_hasher): New hashtable type.
9099 (inline_entry_data_hasher::hash): New.
9100 (inline_entry_data_hasher::equal): New.
9101 (inline_entry_data_table): New variable.
9102 (add_high_low_attributes): Add DW_AT_entry_pc and
9103 DW_AT_GNU_entry_view attributes if a pending entry is found
9104 in inline_entry_data_table. Add old entry_pc attribute only
9105 if debug nonbinding markers are disabled.
9106 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
9107 markers are enabled.
9108 (block_within_block_p, dwarf2out_inline_entry): New.
9109 (dwarf2out_finish): Check that no entries remained in
9110 inline_entry_data_table.
9111 * final.c (reemit_insn_block_notes): Handle inline entry notes.
9112 (final_scan_insn, notice_source_line): Likewise.
9113 (rest_of_clean_state): Skip inline entry markers.
9114 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
9115 markers.
9116 * gimple.c (gimple_build_debug_inline_entry): New.
9117 * gimple.h (enum gimple_debug_subcode): Add
9118 GIMPLE_DEBUG_INLINE_ENTRY.
9119 (gimple_build_debug_inline_entry): Declare.
9120 (gimple_debug_inline_entry_p): New.
9121 (gimple_debug_nonbind_marker_p): Adjust.
9122 * insn-notes.def (INLINE_ENTRY): New.
9123 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
9124 inline entry marker notes.
9125 (print_insn): Likewise.
9126 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
9127 (INSN_DEBUG_MARKER_KIND): Likewise.
9128 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
9129 * tree-inline.c (expand_call_inline): Build and insert
9130 debug_inline_entry stmt.
9131 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
9132 inline entry blocks early, if nonbind markers are enabled.
9133 (dump_scope_block): Dump fragment info.
9134 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
9135 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
9136 (gimple_build_debug_inline_entry): New.
9137 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
9138 Enable/disable inline entry points too.
9139 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
9140 (DEBUG_INSN): Describe inline entry markers.
9141
9142 * common.opt (gvariable-location-views): New.
9143 (gvariable-location-views=incompat5): New.
9144 * config.in: Rebuilt.
9145 * configure: Rebuilt.
9146 * configure.ac: Test assembler for view support.
9147 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
9148 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
9149 * dwarf2out.c (var_loc_view): New typedef.
9150 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
9151 (dwarf2out_locviews_in_attribute): New.
9152 (dwarf2out_locviews_in_loclist): New.
9153 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
9154 (enum dw_line_info_opcode): Add LI_adv_address.
9155 (struct dw_line_info_table): Add view.
9156 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
9157 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
9158 (zero_view_p): New variable.
9159 (ZERO_VIEW_P): New macro.
9160 (output_asm_line_debug_info): New.
9161 (struct var_loc_node): Add view.
9162 (add_AT_view_list, AT_loc_list): New.
9163 (add_var_loc_to_decl): Add view param. Test it against last.
9164 (new_loc_list): Add view params. Record them.
9165 (AT_loc_list_ptr): Handle loc and view lists.
9166 (view_list_to_loc_list_val_node): New.
9167 (print_dw_val): Handle dw_val_class_view_list.
9168 (size_of_die): Likewise.
9169 (value_format): Likewise.
9170 (loc_list_has_views): New.
9171 (gen_llsym): Set vl_symbol too.
9172 (maybe_gen_llsym, skip_loc_list_entry): New.
9173 (dwarf2out_maybe_output_loclist_view_pair): New.
9174 (output_loc_list): Output view list or entries too.
9175 (output_view_list_offset): New.
9176 (output_die): Handle dw_val_class_view_list.
9177 (output_dwarf_version): New.
9178 (output_compilation_unit_header): Use it.
9179 (output_skeleton_debug_sections): Likewise.
9180 (output_rnglists, output_line_info): Likewise.
9181 (output_pubnames, output_aranges): Update version comments.
9182 (output_one_line_info_table): Output view numbers in asm comments.
9183 (dw_loc_list): Determine current endview, pass it to new_loc_list.
9184 Call maybe_gen_llsym.
9185 (loc_list_from_tree_1): Adjust.
9186 (add_AT_location_description): Create view list attribute if
9187 needed, check it's absent otherwise.
9188 (convert_cfa_to_fb_loc_list): Adjust.
9189 (maybe_emit_file): Call output_asm_line_debug_info for test.
9190 (dwarf2out_var_location): Reset views as needed. Precompute
9191 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
9192 attribute. Set view.
9193 (new_line_info_table): Reset next view.
9194 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
9195 (dwarf2out_source_line): Likewise. Output view resets and labels to
9196 the assembler, or select appropriate line info opcodes.
9197 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
9198 (optimize_string_length): Catch it. Adjust.
9199 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
9200 dw_val_class_view_list, and remove it if no longer needed.
9201 (hash_loc_list): Hash view numbers.
9202 (loc_list_hasher::equal): Compare them.
9203 (optimize_location_lists): Check whether a view list symbol is
9204 needed, and whether the locview attribute is present, and
9205 whether they match. Remove the locview attribute if no longer
9206 needed.
9207 (index_location_lists): Call skip_loc_list_entry for test.
9208 (dwarf2out_finish): Call output_asm_line_debug_info for test.
9209 Use output_dwarf_version.
9210 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
9211 (struct dw_val_node): Add val_view_list.
9212 * final.c (SEEN_NEXT_VIEW): New.
9213 (set_next_view_needed): New.
9214 (clear_next_view_needed): New.
9215 (maybe_output_next_view): New.
9216 (final_start_function): Rename to...
9217 (final_start_function_1): ... this. Take pointer to FIRST,
9218 add SEEN parameter. Emit param bindings in the initial view.
9219 (final_start_function): Reintroduce SEEN-less interface.
9220 (final): Rename to...
9221 (final_1): ... this. Take SEEN parameter. Output final pending
9222 next view at the end.
9223 (final): Reintroduce seen-less interface.
9224 (final_scan_insn): Output pending next view before switching
9225 sections or ending a block. Mark the next view as needed when
9226 outputting variable locations. Notify debug backend of section
9227 changes, and of location view changes.
9228 (rest_of_handle_final): Adjust.
9229 * toplev.c (process_options): Autodetect value for debug variable
9230 location views option. Warn on incompat5 without -gdwarf-5.
9231 * doc/invoke.texi (gvariable-location-views): New.
9232 (gvariable-location-views=incompat5): New.
9233 (gno-variable-location-views): New.
9234
9235 2018-02-08 David Malcolm <dmalcolm@redhat.com>
9236
9237 PR tree-optimization/84136
9238 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
9239 that the result of find_edge is non-NULL.
9240
9241 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
9242
9243 PR target/83008
9244 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
9245 storing integer register in SImode. Fix cost of 256 and 512
9246 byte aligned SSE register store.
9247
9248 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
9249
9250 * config/i386/i386.c (ix86_multiplication_cost): Fix
9251 multiplication cost for TARGET_AVX512DQ.
9252
9253 2018-02-08 Marek Polacek <polacek@redhat.com>
9254
9255 PR tree-optimization/84238
9256 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
9257 get_range_strlen.
9258
9259 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
9260
9261 PR tree-optimization/84265
9262 * tree-vect-stmts.c (vectorizable_store): Don't treat
9263 VMAT_CONTIGUOUS accesses as grouped.
9264 (vectorizable_load): Likewise.
9265
9266 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
9267
9268 PR tree-optimization/81635
9269 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
9270 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
9271 (test_round_for_mask): New functions.
9272 (wide_int_cc_tests): Call test_round_for_mask.
9273 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
9274 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
9275 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
9276 range returned by get_range_info.
9277
9278 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
9279
9280 PR ipa/81360
9281 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
9282 * symtab.c: Include builtins.h
9283 (symtab_node::output_to_lto_symbol_table_p): Move here
9284 from lto-streamer-out.c:output_symbol_p.
9285 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
9286 (output_symbol_p): Move all logic to symtab.c
9287 (produce_symtab): Update.
9288
9289 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
9290
9291 * config/s390/s390-opts.h (enum indirect_branch): Define.
9292 * config/s390/s390-protos.h (s390_return_addr_from_memory)
9293 (s390_indirect_branch_via_thunk)
9294 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
9295 (enum s390_indirect_branch_type): Define.
9296 * config/s390/s390.c (struct s390_frame_layout, struct
9297 machine_function): Remove.
9298 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
9299 (indirect_branch_table_label_no, indirect_branch_table_name):
9300 Define variables.
9301 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
9302 (enum s390_indirect_branch_option): Define.
9303 (s390_return_addr_from_memory): New function.
9304 (s390_handle_string_attribute): New function.
9305 (s390_attribute_table): Add new attribute handler.
9306 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
9307 (s390_indirect_branch_via_thunk): New function.
9308 (s390_indirect_branch_via_inline_thunk): New function.
9309 (s390_function_ok_for_sibcall): When jumping via thunk disallow
9310 sibling call optimization for non z10 compiles.
9311 (s390_emit_call): Force indirect branch target to be a single
9312 register. Add r1 clobber for non-z10 compiles.
9313 (s390_emit_epilogue): Emit return jump via return_use expander.
9314 (s390_reorg): Handle JUMP_INSNs as execute targets.
9315 (s390_option_override_internal): Perform validity checks for the
9316 new command line options.
9317 (s390_indirect_branch_attrvalue): New function.
9318 (s390_indirect_branch_settings): New function.
9319 (s390_set_current_function): Invoke s390_indirect_branch_settings.
9320 (s390_output_indirect_thunk_function): New function.
9321 (s390_code_end): Implement target hook.
9322 (s390_case_values_threshold): Implement target hook.
9323 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
9324 macros.
9325 * config/s390/s390.h (struct s390_frame_layout)
9326 (struct machine_function): Move here from s390.c.
9327 (TARGET_INDIRECT_BRANCH_NOBP_RET)
9328 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
9329 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
9330 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
9331 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
9332 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
9333 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
9334 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
9335 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
9336 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
9337 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
9338 (mnemonic attribute): Add values which aren't recognized
9339 automatically.
9340 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
9341 pattern for branch conversion. Fix mnemonic attribute.
9342 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
9343 indirect branch via thunk if requested.
9344 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
9345 ("*indirect_jump"): Disable for branch conversion using out of
9346 line thunks.
9347 ("indirect_jump_via_thunk<mode>_z10")
9348 ("indirect_jump_via_thunk<mode>")
9349 ("indirect_jump_via_inlinethunk<mode>_z10")
9350 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
9351 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
9352 ("casesi_jump_via_inlinethunk<mode>_z10")
9353 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
9354 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
9355 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
9356 ("*indirect2_jump"): Disable for branch conversion.
9357 ("casesi_jump"): Turn into expander and expand patterns for branch
9358 conversion.
9359 ("return_use"): New expander.
9360 ("*return"): Emit return via thunk and rename it to ...
9361 ("*return<mode>"): ... this one.
9362 * config/s390/s390.opt: Add new options and and enum for the
9363 option values.
9364
9365 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
9366
9367 * lra-constraints.c (match_reload): Unconditionally use
9368 gen_lowpart_SUBREG, rather than selecting between that
9369 and equivalent gen_rtx_SUBREG code.
9370
9371 2018-02-08 Richard Biener <rguenther@suse.de>
9372
9373 PR tree-optimization/84233
9374 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
9375 changed flag instead of boguously re-using phi_inserted.
9376
9377 2018-02-08 Martin Jambor <mjambor@suse.cz>
9378
9379 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
9380 static local variables.
9381
9382 2018-02-08 Richard Biener <rguenther@suse.de>
9383
9384 PR tree-optimization/84278
9385 * tree-vect-stmts.c (vectorizable_store): When looking for
9386 smaller vector types to perform grouped strided loads/stores
9387 make sure the mode is supported by the target.
9388 (vectorizable_load): Likewise.
9389
9390 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
9391
9392 * config/aarch64/aarch64.c (aarch64_components_for_bb):
9393 Increase LDP/STP opportunities by adding adjacent callee-saves.
9394
9395 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
9396
9397 PR rtl-optimization/84068
9398 PR rtl-optimization/83459
9399 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
9400
9401 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
9402
9403 PR tree-optimization/84224
9404 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
9405 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
9406 non-zero arguments.
9407
9408 2018-02-07 Iain Sandoe <iain@codesourcery.com>
9409
9410 PR target/84113
9411 * config/rs6000/altivec.md (*restore_world): Remove LR use.
9412 * config/rs6000/predicates.md (restore_world_operation): Adjust op
9413 count, remove one USE.
9414
9415 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
9416
9417 * doc/install.texi (Configuration): Document the
9418 --with-long-double-format={ibm,ieee} PowerPC configuration
9419 options.
9420
9421 PR target/84154
9422 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
9423 Convert from define_expand to be define_insn_and_split. Rework
9424 float/double/_Float128 conversions to QI/HI/SImode to work with
9425 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
9426 conversions to QI/HImode types did a store and then a load to
9427 truncate the value. For conversions to VSX registers, don't split
9428 the insn, instead emit the code directly. Use the code iterator
9429 any_fix to combine signed and unsigned conversions.
9430 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
9431 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
9432 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
9433 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
9434 (fix_<mode>di2_hw): Likewise.
9435 (fixuns_<mode>di2_hw): Likewise.
9436 (fix_<mode>si2_hw): Likewise.
9437 (fixuns_<mode>si2_hw): Likewise.
9438 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
9439 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
9440 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
9441 fix<uns>_trunc<SFDF:mode>si2_p8.
9442 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer
9443 used.
9444 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
9445 (fix<uns>_<mode>_mem): Likewise.
9446 (fctiw<u>z_<mode>_mem): Likewise.
9447 (fix<uns>_<mode>_mem): Likewise.
9448 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
9449 the register allocator from doing a direct move to the GPRs to do
9450 a store, and instead use the ISA 3.0 store byte/half-word from
9451 vector register instruction. For IEEE 128-bit floating point,
9452 also optimize stores of 32-bit ints.
9453 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
9454
9455 2018-02-07 Alan Hayward <alan.hayward@arm.com>
9456
9457 * genextract.c (push_pathstr_operand): New function to support
9458 [a-zA-Z].
9459 (walk_rtx): Call push_pathstr_operand.
9460 (print_path): Support [a-zA-Z].
9461
9462 2018-02-07 Richard Biener <rguenther@suse.de>
9463
9464 PR tree-optimization/84037
9465 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
9466 (cse_and_gimplify_to_preheader): Declare.
9467 (vect_get_place_in_interleaving_chain): Likewise.
9468 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
9469 ivexpr_map.
9470 (_loop_vec_info::~_loop_vec_info): Delete it.
9471 (cse_and_gimplify_to_preheader): New function.
9472 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
9473 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
9474 (vectorizable_load): Likewise. For grouped stores always base
9475 the IV on the first element.
9476 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
9477 condition before gimplifying.
9478
9479 2018-02-07 Jakub Jelinek <jakub@redhat.com>
9480
9481 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
9482 *DIV_EXPR and *MOD_EXPR.
9483
9484 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
9485
9486 PR target/84248
9487 * config/i386/i386.c (ix86_option_override_internal): Mask out
9488 the CF_SET bit when checking -fcf-protection.
9489
9490 2018-02-07 Tom de Vries <tom@codesourcery.com>
9491
9492 PR libgomp/84217
9493 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
9494 enough.
9495
9496 2018-02-07 Richard Biener <rguenther@suse.de>
9497
9498 PR tree-optimization/84204
9499 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
9500 this place.
9501
9502 PR tree-optimization/84205
9503 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
9504 special-case isl_ast_op_zdiv_r.
9505
9506 PR tree-optimization/84223
9507 * graphite-scop-detection.c (gather_bbs::before_dom_children):
9508 Only add conditions from within the region.
9509 (gather_bbs::after_dom_children): Adjust.
9510
9511 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
9512
9513 PR target/84209
9514 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
9515 * config/avr/avr.md: Only post-reload split REG-REG moves if
9516 either register is GENERAL_REG_P.
9517
9518 2018-02-07 Jakub Jelinek <jakub@redhat.com>
9519
9520 PR tree-optimization/84235
9521 * tree-ssa-scopedtables.c
9522 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
9523 if the subtraction is performed in floating point type where NaNs are
9524 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
9525 build 1. Formatting fix.
9526
9527 2018-02-06 Jakub Jelinek <jakub@redhat.com>
9528
9529 PR target/84146
9530 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
9531 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
9532 and skip it regardless of bb boundaries. Use CALL_P macro,
9533 don't test INSN_P (insn) together with CALL_P or JUMP_P check
9534 unnecessarily, formatting fix.
9535
9536 2018-02-06 Michael Collison <michael.collison@arm.com>
9537
9538 * config/arm/thumb2.md:
9539 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
9540 (*thumb_mov_notscc): Ditto.
9541
9542 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
9543
9544 PR target/84154
9545 * config/rs6000/rs6000.md (su code attribute): Use "u" for
9546 unsigned_fix, not "s".
9547
9548 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9549
9550 * configure.ac (gcc_fn_eh_frame_ro): New function.
9551 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
9552 correct .eh_frame permissions.
9553 * configure: Regenerate.
9554
9555 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
9556
9557 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
9558 irrelevant options.
9559
9560 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
9561
9562 * config/rs6000/rs6000.c (rs6000_option_override_internal):
9563 Display warning message for -mno-speculate-indirect-jumps.
9564
9565 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
9566
9567 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
9568 Undocumented.
9569 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
9570
9571 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
9572
9573 PR tree-optimization/84225
9574 * tree-eh.c (find_trapping_overflow): Only call
9575 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
9576
9577 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
9578
9579 PR target/84145
9580 * config/i386/i386.c: Reimplement the check of possible options
9581 -mibt/-mshstk conbination. Change error messages.
9582 * doc/invoke.texi: Fix a typo: remove extra '='.
9583
9584 2018-02-06 Marek Polacek <polacek@redhat.com>
9585
9586 PR tree-optimization/84228
9587 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
9588
9589 2018-02-06 Tamar Christina <tamar.christina@arm.com>
9590
9591 PR target/82641
9592 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
9593 emitted arch directives.
9594 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
9595 __ARM_FEATURE_COPROC before changing architectures.
9596
9597 2018-02-06 Richard Biener <rguenther@suse.de>
9598
9599 * config/i386/i386.c (print_reg): Fix typo.
9600 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
9601
9602 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
9603
9604 * configure: Regenerate.
9605
9606 2018-02-05 Martin Sebor <msebor@redhat.com>
9607
9608 PR tree-optimization/83369
9609 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
9610 inlining context.
9611
9612 2018-02-05 Martin Liska <mliska@suse.cz>
9613
9614 * doc/invoke.texi: Cherry-pick upstream r323995.
9615
9616 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
9617
9618 * ira.c (ira_init_register_move_cost): Adjust comment.
9619
9620 2018-02-05 Martin Liska <mliska@suse.cz>
9621
9622 PR gcov-profile/84137
9623 * doc/gcov.texi: Fix typo in documentation.
9624
9625 2018-02-05 Martin Liska <mliska@suse.cz>
9626
9627 PR gcov-profile/83879
9628 * doc/gcov.texi: Document necessity of --dynamic-list-data when
9629 using dlopen functionality.
9630
9631 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
9632
9633 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
9634 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
9635 _mm_maskz_range_ss, _mm_mask_range_round_ss,
9636 _mm_maskz_range_round_ss): New intrinsics.
9637 (__builtin_ia32_rangesd128_round)
9638 (__builtin_ia32_rangess128_round): Remove.
9639 (__builtin_ia32_rangesd128_mask_round,
9640 __builtin_ia32_rangess128_mask_round): New builtins.
9641 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
9642 __builtin_ia32_rangess128_round): Remove.
9643 (__builtin_ia32_rangesd128_mask_round,
9644 __builtin_ia32_rangess128_mask_round): New builtins.
9645 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
9646 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
9647 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
9648 "<round_saeonly_constraint>")): Changed to ...
9649 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
9650 "<round_saeonly_scalar_constraint>")): ... this.
9651 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
9652 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
9653 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
9654 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
9655 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
9656
9657 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
9658
9659 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
9660 options.
9661 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
9662 Remove all values except native, 8540 and 8548.
9663
9664 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
9665
9666 * config/i386/i386.c (ix86_output_function_return): Pass
9667 INVALID_REGNUM, instead of -1, as invalid register number to
9668 indirect_thunk_name and output_indirect_thunk.
9669
9670 2018-02-02 Julia Koval <julia.koval@intel.com>
9671
9672 * config.gcc: Add -march=icelake.
9673 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
9674 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
9675 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
9676 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
9677 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
9678 (processor_target_table): Add icelake.
9679 (ix86_option_override_internal): Handle new PTAs.
9680 (get_builtin_code_for_version): Handle icelake.
9681 (M_INTEL_COREI7_ICELAKE): New.
9682 (fold_builtin_cpu): Handle icelake.
9683 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
9684 * doc/invoke.texi: Add -march=icelake.
9685
9686 2018-02-02 Julia Koval <julia.koval@intel.com>
9687
9688 * config/i386/i386.c (ix86_option_override_internal): Change flags type
9689 to wide_int_bitmask.
9690 * wide-int-bitmask.h: New.
9691
9692 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
9693
9694 PR target/84066
9695 * config/i386/i386.md: Replace Pmode with word_mode in
9696 builtin_setjmp_setup and builtin_longjmp to support x32.
9697
9698 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
9699
9700 PR target/56010
9701 PR target/83743
9702 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
9703 #include "opts.h".
9704 (rs6000_supported_cpu_names): New static variable.
9705 (linux_cpu_translation_table): Likewise.
9706 (elf_platform) <cpu>: Define new static variable and use it.
9707 Translate kernel AT_PLATFORM name to canonical name if needed.
9708 Error if platform name is unknown.
9709
9710 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
9711
9712 PR target/84089
9713 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
9714
9715 2018-02-01 Jeff Law <law@redhat.com>
9716
9717 PR target/84128
9718 * config/i386/i386.c (release_scratch_register_on_entry): Add new
9719 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
9720 the scratch if RELEASE_VIA_POP is false.
9721 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
9722 If we have to save a temporary register, decrement SIZE appropriately.
9723 Pass new arguments to release_scratch_register_on_entry.
9724 (ix86_adjust_stack_and_probe): Likewise.
9725 (ix86_emit_probe_stack_range): Pass new arguments to
9726 release_scratch_register_on_entry.
9727
9728 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
9729
9730 PR rtl-optimization/84157
9731 * combine.c (change_zero_ext): Use REG_P predicate in
9732 front of HARD_REGISTER_P predicate.
9733
9734 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
9735
9736 * config/avr/avr.c (avr_option_override): Move disabling of
9737 -fdelete-null-pointer-checks to...
9738 * common/config/avr/avr-common.c (avr_option_optimization_table):
9739 ...here.
9740
9741 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9742
9743 PR tree-optimization/81635
9744 * tree-data-ref.c (split_constant_offset_1): For types that
9745 wrap on overflow, try to use range info to prove that wrapping
9746 cannot occur.
9747
9748 2018-02-01 Renlin Li <renlin.li@arm.com>
9749
9750 PR target/83370
9751 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
9752 TAILCALL_ADDR_REGS.
9753 (aarch64_register_move_cost): Likewise.
9754 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
9755 TAILCALL_ADDR_REGS.
9756 (REG_CLASS_NAMES): Likewise.
9757 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
9758 TAILCALL_ADDR_REGS. Remove IP registers.
9759 * config/aarch64/aarch64.md (Ucs): Update register constraint.
9760
9761 2018-02-01 Richard Biener <rguenther@suse.de>
9762
9763 * domwalk.h (dom_walker::dom_walker): Add additional constructor
9764 for specifying RPO order and allow NULL for that.
9765 * domwalk.c (dom_walker::dom_walker): Likewise.
9766 (dom_walker::walk): Handle NULL RPO order.
9767 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
9768 in RPO order.
9769 (rewrite_update_dom_walker): Likewise.
9770 (mark_def_dom_walker): Likewise.
9771
9772 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9773
9774 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
9775 (aarch64_maybe_expand_sve_subreg_move): Declare.
9776 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
9777 * config/aarch64/predicates.md (aarch64_any_register_operand): New
9778 predicate.
9779 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
9780 that are semantically a reverse operation.
9781 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
9782 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
9783 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
9784 functions.
9785 (aarch64_can_change_mode_class): For big-endian, forbid changes
9786 between two SVE modes if they have different element sizes.
9787
9788 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9789
9790 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
9791 the TImode handling for big-endian targets.
9792
9793 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9794
9795 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
9796 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
9797 not just bytes.
9798 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
9799 Remove BSWAP handing for big-endian targets and use the form of
9800 LD1RQ appropariate for the mode.
9801
9802 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9803
9804 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
9805 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
9806 duplicated element.
9807
9808 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
9809
9810 PR tearget/83845
9811 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
9812 check for operands that need to go through aarch64_sve_reload_be.
9813
9814 2018-02-01 Jakub Jelinek <jakub@redhat.com>
9815
9816 PR tree-optimization/81661
9817 PR tree-optimization/84117
9818 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
9819 * tree-eh.c: Include gimplify.h.
9820 (find_trapping_overflow, replace_trapping_overflow,
9821 rewrite_to_non_trapping_overflow): New functions.
9822 * tree-vect-loop.c: Include tree-eh.h.
9823 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
9824 * tree-data-ref.c: Include tree-eh.h.
9825 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
9826
9827 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
9828
9829 PR rtl-optimization/84123
9830 * combine.c (change_zero_ext): Check if hard register satisfies
9831 can_change_dest_mode before calling gen_lowpart_SUBREG.
9832
9833 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
9834
9835 PR target/82444
9836 * ira.c (ira_init_register_move_cost): Remove assert.
9837
9838 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
9839
9840 PR rtl-optimization/84071
9841 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
9842 * doc/tm.texi: Regenerate.
9843
9844 2018-01-31 Richard Biener <rguenther@suse.de>
9845
9846 PR tree-optimization/84132
9847 * tree-data-ref.c (analyze_miv_subscript): Properly
9848 check whether evolution_function_is_affine_multivariate_p
9849 before calling gcd_of_steps_may_divide_p.
9850
9851 2018-01-31 Julia Koval <julia.koval@intel.com>
9852
9853 PR target/83618
9854 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
9855 * config/i386/i386.md (rdpid_rex64) New.
9856 (rdpid): Make 32bit only.
9857
9858 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
9859
9860 PR lto/84105
9861 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
9862 an IDENTIFIER_NODE for FUNCTION_TYPE's.
9863
9864 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
9865
9866 Revert
9867 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
9868
9869 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
9870
9871 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
9872
9873 PR rtl-optimization/84071
9874 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
9875 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
9876
9877 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
9878
9879 * config/arc/arc.c (arc_handle_aux_attribute): New function.
9880 (arc_attribute_table): Add 'aux' attribute.
9881 (arc_in_small_data_p): Consider aux like variables.
9882 (arc_is_aux_reg_p): New function.
9883 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
9884 (arc_get_aux_arg): New function.
9885 (prepare_move_operands): Handle aux-register access.
9886 (arc_handle_aux_attribute): New function.
9887 * doc/extend.texi (ARC Variable attributes): Add subsection.
9888
9889 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
9890
9891 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
9892 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
9893 (arc_attribute_table): Add 'uncached' attribute.
9894 (arc_print_operand): Print '.di' flag for uncached memory
9895 accesses.
9896 (arc_in_small_data_p): Do not consider for small data the uncached
9897 types.
9898 (arc_is_uncached_mem_p): New function.
9899 * config/arc/predicates.md (compact_store_memory_operand): Check
9900 for uncached memory accesses.
9901 (nonvol_nonimm_operand): Likewise.
9902 * gcc/doc/extend.texi (ARC Type Attribute): New subsection.
9903
9904 2018-01-31 Jakub Jelinek <jakub@redhat.com>
9905
9906 PR c/84100
9907 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
9908 falign-loops=): Add Optimization flag.
9909
9910 2018-01-30 Jeff Law <law@redhat.com>
9911
9912 PR target/84064
9913 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
9914 INT_REGISTERS_SAVED. Check it prior to calling
9915 get_scratch_register_on_entry.
9916 (ix86_adjust_stack_and_probe): Similarly.
9917 (ix86_emit_probe_stack_range): Similarly.
9918 (ix86_expand_prologue): Corresponding changes.
9919
9920 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9921
9922 PR target/40411
9923 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
9924 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
9925
9926 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
9927
9928 PR target/84112
9929 * lra-constraints.c (curr_insn_transform): Process AND in the
9930 address.
9931
9932 2018-01-30 Jakub Jelinek <jakub@redhat.com>
9933
9934 PR rtl-optimization/83986
9935 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
9936 dependence against last_pending_memory_flush in addition to
9937 pending_jump_insns.
9938
9939 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
9940
9941 PR tree-optimization/81611
9942 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
9943 copies.
9944
9945 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
9946
9947 PR target/83758
9948 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
9949 a reg rtx.
9950
9951 2018-01-30 Richard Biener <rguenther@suse.de>
9952 Jakub Jelinek <jakub@redhat.com>
9953
9954 PR tree-optimization/84111
9955 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
9956 inner loops added during recursion, as they don't have up-to-date
9957 SSA form.
9958
9959 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
9960
9961 PR ipa/81360
9962 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
9963 (can_inline_edge_by_limits_p): ... here.
9964 (can_early_inline_edge_p, check_callers,
9965 update_caller_keys, update_callee_keys, recursive_inlining,
9966 add_new_edges_to_heap, speculation_useful_p,
9967 inline_small_functions,
9968 inline_small_functions, flatten_function,
9969 inline_to_all_callers_1): Update.
9970
9971 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
9972
9973 * profile-count.c (profile_count::combine_with_ipa_count): Handle
9974 zeros correctly.
9975
9976 2018-01-30 Richard Biener <rguenther@suse.de>
9977
9978 PR tree-optimization/83008
9979 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
9980 invariant and constant vector uses in stmts when they need
9981 more than one stmt.
9982
9983 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9984
9985 PR bootstrap/84017
9986 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
9987 * configure: Regenerate.
9988
9989 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
9990
9991 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
9992 pattern.
9993 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
9994 Use gen_rtx_REG rather than gen_lowpart.
9995
9996 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
9997
9998 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
9999 rather than 0 when creating partial subregs.
10000
10001 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
10002
10003 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
10004 of usage.
10005
10006 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
10007
10008 PR target/81550
10009 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
10010 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
10011 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
10012 flags. This restores the settings used before the 2017-07-24.
10013 Turning off pre increment/decrement/modify allows IVOPTS to
10014 optimize DF/SF loops where the index is an int.
10015
10016 2018-01-29 Richard Biener <rguenther@suse.de>
10017 Kelvin Nilsen <kelvin@gcc.gnu.org>
10018
10019 PR bootstrap/80867
10020 * tree-vect-stmts.c (vectorizable_call): Don't call
10021 targetm.vectorize_builtin_md_vectorized_function if callee is
10022 NULL.
10023
10024 2018-01-22 Carl Love <cel@us.ibm.com>
10025
10026 * doc/extend.tex: Fix typo in second arg in
10027 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
10028
10029 2018-01-29 Richard Biener <rguenther@suse.de>
10030
10031 PR tree-optimization/84086
10032 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
10033 (flush_ssaname_freelist): When SSA names were released reset
10034 the SCEV hash table.
10035
10036 2018-01-29 Richard Biener <rguenther@suse.de>
10037
10038 PR tree-optimization/84057
10039 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
10040 removed paths when removing edges.
10041
10042 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
10043
10044 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
10045 -mfunction-return=@var{choice}.
10046
10047 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
10048
10049 PR diagnostic/84034
10050 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
10051 Handle CR like TAB.
10052 (layout::print_source_line): Likewise.
10053 (test_get_line_width_without_trailing_whitespace): Add test cases.
10054
10055 2018-01-27 Jakub Jelinek <jakub@redhat.com>
10056
10057 PR middle-end/84040
10058 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
10059 debug insns.
10060
10061 2018-01-26 Jim Wilson <jimw@sifive.com>
10062
10063 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
10064
10065 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
10066 specified.
10067
10068 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10069
10070 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
10071 and CMP + SUB-immediate -> SUBS.
10072
10073 2018-01-26 Martin Sebor <msebor@redhat.com>
10074
10075 PR tree-optimization/83896
10076 * tree-ssa-strlen.c (get_string_len): Rename...
10077 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
10078 Avoid assuming length is constant.
10079 (handle_char_store): Use HOST_WIDE_INT for string length.
10080
10081 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
10082
10083 PR target/81763
10084 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
10085 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
10086
10087 2018-01-26 Richard Biener <rguenther@suse.de>
10088
10089 PR rtl-optimization/84003
10090 * dse.c (record_store): Only record redundant stores when
10091 the earlier store aliases at least all accesses the later one does.
10092
10093 2018-01-26 Jakub Jelinek <jakub@redhat.com>
10094
10095 PR rtl-optimization/83985
10096 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
10097 REG_CFA_RESTORE insns.
10098 (delete_unmarked_insns): Don't ignore separate shrink wrapping
10099 REG_CFA_RESTORE insns here.
10100
10101 PR c/83989
10102 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
10103 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
10104
10105 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10106
10107 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
10108 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
10109 (arc_init): Likewise.
10110 (arc_override_options): Likewise.
10111 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
10112 value.
10113 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
10114 support.
10115 * config/arc/arc.h (TARGET_DBNZ): Define.
10116 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
10117 properly set the tune attribute.
10118 (dbnz): Use TARGET_DBNZ guard.
10119 * config/arc/arc.opt (mtune): Add core3 option.
10120
10121 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10122
10123 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
10124 recognize new pic like addresses.
10125 (arc_delegitimize_address): Clean up.
10126
10127 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10128
10129 * config/arc/arc-arches.def: Option mrf16 valid for all
10130 architectures.
10131 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
10132 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
10133 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
10134 * config/arc/arc-tables.opt: Regenerate.
10135 * config/arc/arc.c (arc_conditional_register_usage): Handle
10136 reduced register file case.
10137 (arc_file_start): Set must have build attributes.
10138 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
10139 mrf16 option value.
10140 * config/arc/arc.opt (mrf16): Add new option.
10141 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
10142 * config/arc/genmultilib.awk: Handle new mrf16 option.
10143 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
10144 * config/arc/t-multilib: Regenerate.
10145 * doc/invoke.texi (ARC Options): Document mrf16 option.
10146
10147 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10148
10149 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
10150 * config/arc/arc.c (arc_handle_secure_attribute): New function.
10151 (arc_attribute_table): Add 'secure_call' attribute.
10152 (arc_print_operand): Print secure call operand.
10153 (arc_function_ok_for_sibcall): Don't optimize tail calls when
10154 secure.
10155 (arc_is_secure_call_p): New function. * config/arc/arc.md
10156 (call_i): Add support for sjli instruction.
10157 (call_value_i): Likewise.
10158 * config/arc/constraints.md (Csc): New constraint.
10159
10160 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
10161 John Eric Martin <John.Martin@emmicro-us.com>
10162
10163 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
10164 * config/arc/arc.c (_arc_jli_section): New struct.
10165 (arc_jli_section): New type.
10166 (rc_jli_sections): New static variable.
10167 (arc_handle_jli_attribute): New function.
10168 (arc_attribute_table): Add jli_always and jli_fixed attribute.
10169 (arc_file_end): New function.
10170 (TARGET_ASM_FILE_END): Define.
10171 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
10172 (arc_add_jli_section): New function.
10173 (jli_call_scan): Likewise.
10174 (arc_reorg): Call jli_call_scan.
10175 (arc_output_addsi): Remove 'S' from printing asm operand.
10176 (arc_is_jli_call_p): New function.
10177 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
10178 operand.
10179 (movhi_insn): Likewise.
10180 (movsi_insn): Likewise.
10181 (movsi_set_cc_insn): Likewise.
10182 (loadqi_update): Likewise.
10183 (load_zeroextendqisi_update): Likewise.
10184 (load_signextendqisi_update): Likewise.
10185 (loadhi_update): Likewise.
10186 (load_zeroextendhisi_update): Likewise.
10187 (load_signextendhisi_update): Likewise.
10188 (loadsi_update): Likewise.
10189 (loadsf_update): Likewise.
10190 (movsicc_insn): Likewise.
10191 (bset_insn): Likewise.
10192 (bxor_insn): Likewise.
10193 (bclr_insn): Likewise.
10194 (bmsk_insn): Likewise.
10195 (bicsi3_insn): Likewise.
10196 (cmpsi_cc_c_insn): Likewise.
10197 (movsi_ne): Likewise.
10198 (movsi_cond_exec): Likewise.
10199 (clrsbsi2): Likewise.
10200 (norm_f): Likewise.
10201 (normw): Likewise.
10202 (swap): Likewise.
10203 (divaw): Likewise.
10204 (flag): Likewise.
10205 (sr): Likewise.
10206 (kflag): Likewise.
10207 (ffs): Likewise.
10208 (ffs_f): Likewise.
10209 (fls): Likewise.
10210 (call_i): Remove 'S' asm letter, add jli instruction.
10211 (call_value_i): Likewise.
10212 * config/arc/arc.op (mjli-always): New option.
10213 * config/arc/constraints.md (Cji): New constraint.
10214 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
10215 operand.
10216 (subsf3_fpx): Likewise.
10217 (mulsf3_fpx): Likewise.
10218 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
10219 asm operand.
10220 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
10221 function attrbutes.
10222 * doc/invoke.texi (ARC): Document mjli-always option.
10223
10224 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
10225
10226 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
10227 avoid addition with 0 and use incw and decw where possible.
10228
10229 2018-01-26 Richard Biener <rguenther@suse.de>
10230
10231 PR tree-optimization/81082
10232 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
10233 association if it requires casting to unsigned.
10234 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
10235 from fold_plusminus_mult_expr to catch important cases late when
10236 range info is available.
10237
10238 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10239
10240 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
10241 * configure.ac (hidden_linkonce): New test.
10242 * configure: Regenerate.
10243 * config.in: Regenerate.
10244
10245 2018-01-26 Julia Koval <julia.koval@intel.com>
10246
10247 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
10248 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
10249 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
10250 _mm_mask_bitshuffle_epi64_mask): Fix type.
10251 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
10252 USI_FTYPE_V4DI_V4DI_USI): Remove.
10253 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
10254 __builtin_ia32_vpshufbitqmb256_mask,
10255 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
10256 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
10257 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
10258
10259 2018-01-26 Alan Modra <amodra@gmail.com>
10260
10261 PR target/84033
10262 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
10263 UNSPEC_VBPERMQ. Sort other unspecs.
10264
10265 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
10266
10267 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
10268
10269 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
10270
10271 PR middle-end/83055
10272 * predict.c (drop_profile): Do not push/pop cfun; update also
10273 node->count.
10274 (handle_missing_profiles): Fix logic looking for zero profiles.
10275
10276 2018-01-25 Jakub Jelinek <jakub@redhat.com>
10277
10278 PR middle-end/83977
10279 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
10280 on functions with #pragma omp declare simd or functions with simd
10281 attribute.
10282 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
10283 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
10284 Remove trailing \n from warning_at calls.
10285
10286 2018-01-25 Tom de Vries <tom@codesourcery.com>
10287
10288 PR target/84028
10289 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
10290 for neutered workers.
10291
10292 2018-01-24 Joseph Myers <joseph@codesourcery.com>
10293
10294 PR target/68467
10295 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
10296 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
10297
10298 2018-01-24 Jeff Law <law@redhat.com>
10299
10300 PR target/83994
10301 * i386.c (get_probe_interval): Move to earlier point.
10302 (ix86_compute_frame_layout): If -fstack-clash-protection and
10303 the frame is larger than the probe interval, then use pushes
10304 to save registers rather than reg->mem moves.
10305 (ix86_expand_prologue): Remove conditional for int_registers_saved
10306 assertion.
10307
10308 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
10309
10310 PR target/84014
10311 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
10312 min/max for never referenced object.
10313
10314 2018-01-24 Jakub Jelinek <jakub@redhat.com>
10315
10316 PR middle-end/83977
10317 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
10318 here.
10319 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
10320 attributes from DECL_ATTRIBUTES (decl) without affecting
10321 DECL_ATTRIBUTES (current_function_decl).
10322 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
10323 functions with non-NULL DECL_ABSTRACT_ORIGIN.
10324
10325 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
10326
10327 PR tree-optimization/83979
10328 * fold-const.c (fold_comparison): Use constant_boolean_node
10329 instead of boolean_{true,false}_node.
10330
10331 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
10332
10333 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
10334 with zero counts.
10335
10336 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
10337
10338 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
10339 Simplify the clause that sets the length attribute.
10340 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
10341 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
10342 clause that sets the length attribute.
10343 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
10344
10345 2018-01-24 Tom de Vries <tom@codesourcery.com>
10346
10347 PR target/83589
10348 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
10349 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
10350 Add strict parameter.
10351 (prevent_branch_around_nothing): Insert dummy insn between branch to
10352 label and label with no ptx insn inbetween.
10353 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
10354
10355 2018-01-24 Tom de Vries <tom@codesourcery.com>
10356
10357 PR target/81352
10358 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
10359 for neutered threads in warp.
10360 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
10361
10362 2018-01-24 Richard Biener <rguenther@suse.de>
10363
10364 PR tree-optimization/83176
10365 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
10366 operands.
10367
10368 2018-01-24 Richard Biener <rguenther@suse.de>
10369
10370 PR tree-optimization/82819
10371 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
10372 code generating pluses that are no-ops in the target precision.
10373
10374 2018-01-24 Richard Biener <rguenther@suse.de>
10375
10376 PR middle-end/84000
10377 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
10378
10379 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
10380
10381 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
10382 to merge probabilities.
10383 * predict.c (probably_never_executed): Also mark as cold functions
10384 with global 0 profile and guessed local profile.
10385 * profile-count.c (profile_probability::combine_with_count): New
10386 member function.
10387 * profile-count.h (profile_probability::operator*,
10388 profile_probability::operator*=, profile_probability::operator/,
10389 profile_probability::operator/=): Reduce precision to adjusted
10390 and set value to guessed on contradictory divisions.
10391 (profile_probability::combine_with_freq): Remove.
10392 (profile_probability::combine_wiht_count): Declare.
10393 (profile_count::force_nonzero):: Set to adjusted.
10394 (profile_count::probability_in):: Set quality to adjusted.
10395 * tree-ssa-tail-merge.c (replace_block_by): Use
10396 combine_with_count.
10397
10398 2018-01-23 Andrew Waterman <andrew@sifive.com>
10399 Jim Wilson <jimw@sifive.com>
10400
10401 * config/riscv/riscv.c (riscv_stack_boundary): New.
10402 (riscv_option_override): Set riscv_stack_boundary. Handle
10403 riscv_preferred_stack_boundary_arg.
10404 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
10405 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
10406 (STACK_BOUNDARY): Set to riscv_stack_boundary.
10407 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
10408 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
10409 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
10410
10411 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
10412
10413 PR target/83905
10414 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
10415 of struct ix86_frame.
10416 (ix86_expand_epilogue): Likewise. Add a local variable for
10417 the reg_save_offset field in struct ix86_frame.
10418
10419 2018-01-23 Bin Cheng <bin.cheng@arm.com>
10420
10421 PR tree-optimization/82604
10422 * tree-loop-distribution.c (enum partition_kind): New enum item
10423 PKIND_PARTIAL_MEMSET.
10424 (partition_builtin_p): Support above new enum item.
10425 (generate_code_for_partition): Ditto.
10426 (compute_access_range): Differentiate cases that equality can be
10427 proven at all loops, the innermost loops or no loops.
10428 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
10429 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
10430 (finalize_partitions, distribute_loop): Don't fuse partition of
10431 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
10432 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
10433 parloop is enabled.
10434
10435 2018-01-23 Martin Liska <mliska@suse.cz>
10436
10437 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
10438 order to ignore the predictor.
10439 (PRED_POLYMORPHIC_CALL): Likewise.
10440 (PRED_RECURSIVE_CALL): Likewise.
10441
10442 2018-01-23 Martin Liska <mliska@suse.cz>
10443
10444 * tree-profile.c (tree_profiling): Print function header to
10445 aware reader which function we are working on.
10446 * value-prof.c (gimple_find_values_to_profile): Do not print
10447 not interesting value histograms.
10448
10449 2018-01-23 Martin Liska <mliska@suse.cz>
10450
10451 * profile-count.h (enum profile_quality): Add
10452 profile_uninitialized as the first value. Do not number values
10453 as they are zero based.
10454 (profile_count::verify): Update sanity check.
10455 (profile_probability::verify): Likewise.
10456
10457 2018-01-23 Nathan Sidwell <nathan@acm.org>
10458
10459 * doc/invoke.texi (ffor-scope): Deprecate.
10460
10461 2018-01-23 David Malcolm <dmalcolm@redhat.com>
10462
10463 PR tree-optimization/83510
10464 * domwalk.c (set_all_edges_as_executable): New function.
10465 (dom_walker::dom_walker): Convert bool param
10466 "skip_unreachable_blocks" to enum reachability. Move setup of
10467 edge flags to set_all_edges_as_executable and only do it when
10468 reachability is REACHABLE_BLOCKS.
10469 * domwalk.h (enum dom_walker::reachability): New enum.
10470 (dom_walker::dom_walker): Convert bool param
10471 "skip_unreachable_blocks" to enum reachability.
10472 (set_all_edges_as_executable): New decl.
10473 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
10474 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
10475 "reachability".
10476 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
10477 but converting true to REACHABLE_BLOCKS.
10478 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
10479 * tree-vrp.c
10480 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
10481 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
10482 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
10483 REACHABLE_BLOCKS.
10484 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
10485 if check_all_array_refs will be called.
10486
10487 2018-01-23 David Malcolm <dmalcolm@redhat.com>
10488
10489 * tree.c (selftest::test_location_wrappers): Add more test
10490 coverage.
10491
10492 2018-01-23 David Malcolm <dmalcolm@redhat.com>
10493
10494 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
10495 (selftest::test_bit_in_range): Likewise.
10496
10497 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
10498
10499 PR testsuite/83888
10500 * doc/sourcebuild.texi (vect_float): Say that the selector
10501 only describes the situation when -funsafe-math-optimizations is on.
10502 (vect_float_strict): Document.
10503
10504 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
10505
10506 PR tree-optimization/83965
10507 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
10508 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
10509 instead of checking only for a reduction.
10510 (vect_recog_widen_sum_pattern): Likewise.
10511
10512 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
10513
10514 * predict.c (probably_never_executed): Only use precise profile info.
10515 (compute_function_frequency): Skip after inlining hack since we now
10516 have quality checking.
10517
10518 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
10519
10520 * profile-count.h (profile_probability::very_unlikely,
10521 profile_probability::unlikely, profile_probability::even): Set
10522 precision to guessed.
10523
10524 2018-01-23 Richard Biener <rguenther@suse.de>
10525
10526 PR tree-optimization/83963
10527 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
10528 Properly terminate dominator walk when crossing the exit edge not
10529 when visiting its source block.
10530
10531 2018-01-23 Jakub Jelinek <jakub@redhat.com>
10532
10533 PR c++/83918
10534 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
10535 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
10536
10537 2018-01-22 Jakub Jelinek <jakub@redhat.com>
10538
10539 PR tree-optimization/83957
10540 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
10541 semicolon after for body surrounded by braces.
10542
10543 PR tree-optimization/83081
10544 * profile-count.h (profile_probability::split): New method.
10545 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
10546 Use profile_probability::split.
10547 (do_compare_rtx_and_jump): Fix adjustment of probabilities
10548 when splitting a single conditional jump into 2.
10549
10550 2018-01-22 David Malcolm <dmalcolm@redhat.com>
10551
10552 PR tree-optimization/69452
10553 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
10554 decl.
10555
10556 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10557
10558 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
10559 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
10560 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
10561
10562 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10563
10564 * config/rl78/rl78-protos.h (rl78_split_movdi): New function declaration.
10565 * config/rl78/rl78.md (movdi): New define_expand.
10566 * config/rl78/rl78.c (rl78_split_movdi): New function.
10567
10568 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
10569
10570 PR target/83862
10571 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
10572 no longer used.
10573 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
10574 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
10575 128-bit to produce an UNSPEC move to get the double word with the
10576 signbit and then a shift directly to do signbit.
10577 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
10578 implementation with a new version that just does either a direct
10579 move or a regular move. Move memory interface to separate insns.
10580 Move insns so they are next to the expander.
10581 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
10582 with signbit move. Split big and little endian case.
10583 (signbit<mode>2_dm_mem_le): Likewise.
10584 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
10585 (signbit<mode>2_dm2): Likewise.
10586
10587 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10588
10589 * config/rl78/rl78.md (anddi3): New define_expand.
10590
10591 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10592
10593 * config/rl78/rl78.md (umindi3): New define_expand.
10594
10595 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10596
10597 * config/rl78/rl78.md (smindi3): New define_expand.
10598
10599 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10600
10601 * config/rl78/rl78.md (smaxdi3): New define_expand.
10602
10603 2018-01-22 Carl Love <cel@us.ibm.com>
10604
10605 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
10606 LVX_V1TI): Add macro expansion.
10607 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
10608 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
10609 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
10610 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
10611 Change check to determine if the instruction is a byte reversing
10612 entry. Fix typo in comment.
10613 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
10614 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
10615 Add def_builtin calls for new builtins.
10616 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
10617 Add define_insn expansion.
10618
10619 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10620
10621 * config/rl78/rl78.md (umaxdi3): New define_expand.
10622
10623 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
10624
10625 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
10626 for non-QImode registers.
10627
10628 2018-01-22 Richard Biener <rguenther@suse.de>
10629
10630 PR tree-optimization/83963
10631 * graphite-scop-detection.c (scop_detection::get_sese): Delay
10632 including the loop exit block.
10633 (scop_detection::merge_sese): Likewise.
10634 (scop_detection::add_scop): Do it here instead.
10635
10636 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10637
10638 * doc/sourcebuild.texi (arm_softfloat): Document.
10639
10640 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
10641
10642 PR gcc/77734
10643 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
10644 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
10645 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
10646
10647 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
10648 David Edelsohn <dje.gcc@gmail.com>
10649
10650 PR target/83946
10651 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
10652 Change "crset eq" to "crset 2".
10653 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
10654 (*call_indirect_aix<mode>_nospec): Likewise.
10655 (*call_value_indirect_aix<mode>_nospec): Likewise.
10656 (*call_indirect_elfv2<mode>_nospec): Likewise.
10657 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
10658 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
10659 change assembly output from . to $.
10660 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
10661 (indirect_jump<mode>_nospec): Change assembly output from . to $.
10662 (*tablejump<mode>_internal1_nospec): Likewise.
10663
10664 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
10665
10666 PR target/80870
10667 * config/sh/sh_optimize_sett_clrt.cc:
10668 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
10669
10670 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
10671
10672 PR tree-optimization/83940
10673 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
10674 offset_dt to vect_constant_def rather than vect_unknown_def_type.
10675 (vect_check_load_store_mask): Add a mask_dt_out parameter and
10676 use it to pass back the definition type.
10677 (vect_check_store_rhs): Likewise rhs_dt_out.
10678 (vect_build_gather_load_calls): Add a mask_dt argument and use
10679 it instead of a call to vect_is_simple_use.
10680 (vectorizable_store): Update calls to vect_check_load_store_mask
10681 and vect_check_store_rhs. Use the dt returned by the latter instead
10682 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
10683 instead of calls to vect_is_simple_use. Pass the scalar rather
10684 than the vector operand to vect_is_simple_use when handling
10685 second and subsequent copies of an rhs value.
10686 (vectorizable_load): Update calls to vect_check_load_store_mask
10687 and vect_build_gather_load_calls. Use the cached mask_dt and
10688 gs_info.offset_dt instead of calls to vect_is_simple_use.
10689
10690 2018-01-20 Jakub Jelinek <jakub@redhat.com>
10691
10692 PR middle-end/83945
10693 * tree-emutls.c: Include gimplify.h.
10694 (lower_emutls_2): New function.
10695 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
10696 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
10697 it before further processing.
10698
10699 PR target/83930
10700 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
10701 UINTVAL (trueop1) instead of INTVAL (op1).
10702
10703 2018-01-19 Jakub Jelinek <jakub@redhat.com>
10704
10705 PR debug/81570
10706 PR debug/83728
10707 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
10708 INCOMING_FRAME_SP_OFFSET if not defined.
10709 (scan_trace): Add ENTRY argument. If true and
10710 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
10711 emit a note to adjust the CFA offset.
10712 (create_cfi_notes): Adjust scan_trace callers.
10713 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
10714 INCOMING_FRAME_SP_OFFSET in the CIE.
10715 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
10716 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
10717 Likewise.
10718 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
10719 * doc/tm.texi: Regenerated.
10720
10721 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
10722
10723 PR rtl-optimization/83147
10724 * lra-constraints.c (remove_inheritance_pseudos): Use
10725 lra_substitute_pseudo_within_insn.
10726
10727 2018-01-19 Tom de Vries <tom@codesourcery.com>
10728 Cesar Philippidis <cesar@codesourcery.com>
10729
10730 PR target/83920
10731 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
10732
10733 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
10734
10735 PR target/83790
10736 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
10737 spaces for function labels.
10738
10739 2018-01-19 Martin Liska <mliska@suse.cz>
10740
10741 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
10742 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
10743 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
10744 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
10745 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
10746 (PRED_CONST_RETURN): Change from 69 to 65.
10747 (PRED_NULL_RETURN): Change from 91 to 71.
10748 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
10749 (PRED_LOOP_GUARD): Change from 66 to 73.
10750
10751 2018-01-19 Martin Liska <mliska@suse.cz>
10752
10753 * predict.c (predict_insn_def): Add new assert.
10754 (struct branch_predictor): Change type to signed integer.
10755 (test_prediction_value_range): Amend test to cover
10756 PROB_UNINITIALIZED.
10757 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
10758 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
10759 (PRED_LOOP_ITERATIONS_MAX): Likewise.
10760 (PRED_LOOP_IV_COMPARE): Likewise.
10761 * predict.h (PROB_UNINITIALIZED): Define new constant.
10762
10763 2018-01-19 Martin Liska <mliska@suse.cz>
10764
10765 * predict.c (dump_prediction): Add new format for
10766 analyze_brprob.py script which is enabled with -details
10767 suboption.
10768 * profile-count.h (precise_p): New function.
10769
10770 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
10771
10772 PR tree-optimization/83922
10773 * tree-vect-loop.c (vect_verify_full_masking): Return false if
10774 there are no statements that need masking.
10775 (vect_active_double_reduction_p): New function.
10776 (vect_analyze_loop_operations): Use it when handling phis that
10777 are not in the loop header.
10778
10779 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
10780
10781 PR tree-optimization/83914
10782 * tree-vect-loop.c (vectorizable_induction): Don't convert
10783 init_expr or apply the peeling adjustment for inductions
10784 that are nested within the vectorized loop.
10785
10786 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10787
10788 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
10789 instead of NEG.
10790
10791 2018-01-18 Jakub Jelinek <jakub@redhat.com>
10792
10793 PR sanitizer/81715
10794 PR testsuite/83882
10795 * function.h (gimplify_parameters): Add gimple_seq * argument.
10796 * function.c: Include gimple.h and options.h.
10797 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
10798 for the added local temporaries if needed.
10799 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
10800 if there are any parameter cleanups, wrap whole body into a
10801 try/finally with the cleanups.
10802
10803 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
10804
10805 PR target/82964
10806 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
10807 Use GET_MODE_CLASS for scalar floating point.
10808
10809 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
10810
10811 PR ipa/82256
10812 patch by PaX Team
10813 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
10814 Fix call of call_cgraph_insertion_hooks.
10815
10816 2018-01-18 Martin Sebor <msebor@redhat.com>
10817
10818 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
10819
10820 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
10821
10822 PR ipa/83619
10823 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
10824 frequencies.
10825
10826 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
10827
10828 PR other/70268
10829 * common.opt: (-ffile-prefix-map): New option.
10830 * opts.c (common_handle_option): Defer it.
10831 * opts-global.c (handle_common_deferred_options): Handle it.
10832 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
10833 * file-prefix-map.h: New file.
10834 (remap_debug_filename, add_debug_prefix_map): ...here.
10835 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
10836 * final.c (debug_prefix_map, add_debug_prefix_map
10837 remap_debug_filename): Move to...
10838 * file-prefix-map.c: New file.
10839 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
10840 generalize, get rid of alloca(), use strrchr() instead of strchr().
10841 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
10842 Implement in terms of add_prefix_map().
10843 (remap_macro_filename, remap_debug_filename): Implement in term of
10844 remap_filename().
10845 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
10846 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
10847 * dbxout.c: Include file-prefix-map.h.
10848 * varasm.c: Likewise.
10849 * vmsdbgout.c: Likewise.
10850 * xcoffout.c: Likewise.
10851 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
10852 * doc/cppopts.texi (-fmacro-prefix-map): Document.
10853 * doc/invoke.texi (-ffile-prefix-map): Document.
10854 (-fdebug-prefix-map): Update description.
10855
10856 2018-01-18 Martin Liska <mliska@suse.cz>
10857
10858 * config/i386/i386.c (indirect_thunk_name): Document that also
10859 lfence is emitted.
10860 (output_indirect_thunk): Document why both instructions
10861 (pause and lfence) are generated.
10862
10863 2018-01-18 Richard Biener <rguenther@suse.de>
10864
10865 PR tree-optimization/83887
10866 * graphite-scop-detection.c
10867 (scop_detection::get_nearest_dom_with_single_entry): Remove.
10868 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
10869 (scop_detection::merge_sese): Re-implement with a flood-fill
10870 algorithm that properly finds a SESE region if it exists.
10871
10872 2018-01-18 Jakub Jelinek <jakub@redhat.com>
10873
10874 PR c/61240
10875 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
10876 pointer_diff optimizations use view_convert instead of convert.
10877
10878 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
10879
10880 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
10881 Generate different code for -mno-speculate-indirect-jumps.
10882 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
10883 (*call_indirect_aix<mode>): Disable for
10884 -mno-speculate-indirect-jumps.
10885 (*call_indirect_aix<mode>_nospec): New define_insn.
10886 (*call_value_indirect_aix<mode>): Disable for
10887 -mno-speculate-indirect-jumps.
10888 (*call_value_indirect_aix<mode>_nospec): New define_insn.
10889 (*sibcall_nonlocal_sysv<mode>): Generate different code for
10890 -mno-speculate-indirect-jumps.
10891 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
10892
10893 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
10894
10895 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
10896 long double type, set the flags for noting the default long double
10897 type, even if we don't pass or return a long double type.
10898
10899 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
10900
10901 PR ipa/83051
10902 * ipa-inline.c (flatten_function): Do not overwrite final inlining
10903 failure.
10904
10905 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
10906
10907 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
10908 support for merge[hl].
10909 (fold_mergehl_helper): New helper function.
10910 (tree-vector-builder.h): New #include for tree_vector_builder usage.
10911 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
10912 (altivec_vmrglw_direct): Add xxmrglw insn.
10913
10914 2018-01-17 Andrew Waterman <andrew@sifive.com>
10915
10916 * config/riscv/riscv.c (riscv_conditional_register_usage): If
10917 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
10918
10919 2018-01-17 David Malcolm <dmalcolm@redhat.com>
10920
10921 PR lto/83121
10922 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
10923 call the lto_location_cache before reading the
10924 DECL_SOURCE_LOCATION of the types.
10925
10926 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
10927 Richard Sandiford <richard.sandiford@linaro.org>
10928
10929 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
10930 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
10931 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
10932 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
10933 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
10934 Add declaration.
10935 * config/aarch64/constraints.md (aarch64_movti_operand):
10936 Limit immediates.
10937 * config/aarch64/predicates.md (Uti): Add new constraint.
10938
10939 2018-01-17 Carl Love <cel@us.ibm.com>
10940
10941 * config/rs6000/vsx.md (define_expand xl_len_r,
10942 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
10943 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
10944 lxvll.
10945 (define_expand, define_insn): Move the shift left from the
10946 define_insn to the define_expand for lxvl and stxvl instructions.
10947 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
10948 and XL_LEN_R definitions to PURE.
10949
10950 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
10951
10952 * config/i386/i386.c (indirect_thunk_name): Declare regno
10953 as unsigned int. Compare regno with INVALID_REGNUM.
10954 (output_indirect_thunk): Ditto.
10955 (output_indirect_thunk_function): Ditto.
10956 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
10957 in the call to output_indirect_thunk_function.
10958
10959 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
10960
10961 PR middle-end/83884
10962 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
10963 rather than the size of inner_type to determine the stack slot size
10964 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
10965
10966 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
10967
10968 PR target/83546
10969 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
10970 to PTA_SILVERMONT.
10971
10972 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
10973
10974 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
10975 endian Linux systems to optionally enable multilibs for selecting
10976 the long double type if the user configured an explicit type.
10977 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
10978 have no long double multilibs if not defined.
10979 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
10980 warn if the user used -mabi={ieee,ibm}longdouble and we built
10981 multilibs for long double.
10982 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
10983 appropriate multilib option.
10984 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
10985 multilib options.
10986 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
10987 for building long double multilibs.
10988 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
10989
10990 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
10991
10992 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
10993 copies.
10994
10995 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
10996 64 bits.
10997 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
10998 128 bits.
10999
11000 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
11001 variables.
11002
11003 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
11004 return value.
11005
11006 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
11007
11008 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
11009 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
11010
11011 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
11012
11013 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
11014 different rtl trees depending on TARGET_64BIT.
11015 (rs6000_gen_lvx): Likewise.
11016
11017 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
11018
11019 * config/visium/visium.md (nop): Tweak comment.
11020 (hazard_nop): Likewise.
11021
11022 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
11023
11024 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
11025 -mspeculate-indirect-jumps.
11026 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
11027 for -mno-speculate-indirect-jumps.
11028 (*call_indirect_elfv2<mode>_nospec): New define_insn.
11029 (*call_value_indirect_elfv2<mode>): Disable for
11030 -mno-speculate-indirect-jumps.
11031 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
11032 (indirect_jump): Emit different RTL for
11033 -mno-speculate-indirect-jumps.
11034 (*indirect_jump<mode>): Disable for
11035 -mno-speculate-indirect-jumps.
11036 (*indirect_jump<mode>_nospec): New define_insn.
11037 (tablejump): Emit different RTL for
11038 -mno-speculate-indirect-jumps.
11039 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
11040 (tablejumpsi_nospec): New define_expand.
11041 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
11042 (tablejumpdi_nospec): New define_expand.
11043 (*tablejump<mode>_internal1): Disable for
11044 -mno-speculate-indirect-jumps.
11045 (*tablejump<mode>_internal1_nospec): New define_insn.
11046 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
11047 option.
11048
11049 2018-01-16 Artyom Skrobov tyomitch@gmail.com
11050
11051 * caller-save.c (insert_save): Drop unnecessary parameter. All
11052 callers updated.
11053
11054 2018-01-16 Jakub Jelinek <jakub@redhat.com>
11055 Richard Biener <rguenth@suse.de>
11056
11057 PR libgomp/83590
11058 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
11059 return early, inline manually is_gimple_sizepos. Make sure if we
11060 call gimplify_expr we don't end up with a gimple constant.
11061 * tree.c (variably_modified_type_p): Don't return true for
11062 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
11063 * gimplify.h (is_gimple_sizepos): Remove.
11064
11065 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
11066
11067 PR tree-optimization/83857
11068 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
11069 vectorizable_live_operation for pure SLP statements.
11070 (vectorizable_live_operation): Handle PHIs.
11071
11072 2018-01-16 Richard Biener <rguenther@suse.de>
11073
11074 PR tree-optimization/83867
11075 * tree-vect-stmts.c (vect_transform_stmt): Precompute
11076 nested_in_vect_loop_p since the scalar stmt may get invalidated.
11077
11078 2018-01-16 Jakub Jelinek <jakub@redhat.com>
11079
11080 PR c/83844
11081 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
11082 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
11083 If off is not INTEGER_CST, issue a may not be aligned warning
11084 rather than isn't aligned. Use isn%'t rather than isn't.
11085 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
11086 into MULT_EXPR.
11087 <case MULT_EXPR>: Improve the case when bottom and one of the
11088 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
11089 operand, in that case check if the other operand is multiple of
11090 bottom divided by the INTEGER_CST operand.
11091
11092 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
11093
11094 PR target/83858
11095 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
11096 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
11097 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
11098 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
11099 * config/pa/pa.c (pa_function_arg_advance): Likewise.
11100 (pa_function_arg, pa_arg_partial_bytes): Likewise.
11101 (pa_function_arg_size): New function.
11102
11103 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
11104
11105 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
11106 in a separate statement.
11107
11108 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
11109
11110 PR tree-optimization/83847
11111 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
11112 group gathers and scatters.
11113
11114 2018-01-16 Jakub Jelinek <jakub@redhat.com>
11115
11116 PR rtl-optimization/86620
11117 * params.def (max-sched-ready-insns): Bump minimum value to 1.
11118
11119 PR rtl-optimization/83213
11120 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
11121 to last if both are JUMP_INSNs.
11122
11123 PR tree-optimization/83843
11124 * gimple-ssa-store-merging.c
11125 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
11126 store_immediate_info for bswap/nop orig_stores.
11127
11128 2018-01-15 Andrew Waterman <andrew@sifive.com>
11129
11130 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
11131 !TARGET_MUL.
11132 <UDIV>: Increase cost if !TARGET_DIV.
11133
11134 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
11135
11136 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
11137 (define_attr "cr_logical_3op"): New.
11138 (cceq_ior_compare): Adjust.
11139 (cceq_ior_compare_complement): Adjust.
11140 (*cceq_rev_compare): Adjust.
11141 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
11142 (is_cracked_insn): Adjust.
11143 (insn_must_be_first_in_group): Adjust.
11144 * config/rs6000/40x.md: Adjust.
11145 * config/rs6000/440.md: Adjust.
11146 * config/rs6000/476.md: Adjust.
11147 * config/rs6000/601.md: Adjust.
11148 * config/rs6000/603.md: Adjust.
11149 * config/rs6000/6xx.md: Adjust.
11150 * config/rs6000/7450.md: Adjust.
11151 * config/rs6000/7xx.md: Adjust.
11152 * config/rs6000/8540.md: Adjust.
11153 * config/rs6000/cell.md: Adjust.
11154 * config/rs6000/e300c2c3.md: Adjust.
11155 * config/rs6000/e500mc.md: Adjust.
11156 * config/rs6000/e500mc64.md: Adjust.
11157 * config/rs6000/e5500.md: Adjust.
11158 * config/rs6000/e6500.md: Adjust.
11159 * config/rs6000/mpc.md: Adjust.
11160 * config/rs6000/power4.md: Adjust.
11161 * config/rs6000/power5.md: Adjust.
11162 * config/rs6000/power6.md: Adjust.
11163 * config/rs6000/power7.md: Adjust.
11164 * config/rs6000/power8.md: Adjust.
11165 * config/rs6000/power9.md: Adjust.
11166 * config/rs6000/rs64.md: Adjust.
11167 * config/rs6000/titan.md: Adjust.
11168
11169 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11170
11171 * config/i386/predicates.md (indirect_branch_operand): Rewrite
11172 ix86_indirect_branch_register logic.
11173
11174 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11175
11176 * config/i386/constraints.md (Bs): Update
11177 ix86_indirect_branch_register check. Don't check
11178 ix86_indirect_branch_register with GOT_memory_operand.
11179 (Bw): Likewise.
11180 * config/i386/predicates.md (GOT_memory_operand): Don't check
11181 ix86_indirect_branch_register here.
11182 (GOT32_symbol_operand): Likewise.
11183
11184 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11185
11186 * config/i386/predicates.md (constant_call_address_operand):
11187 Rewrite ix86_indirect_branch_register logic.
11188 (sibcall_insn_operand): Likewise.
11189
11190 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11191
11192 * config/i386/constraints.md (Bs): Replace
11193 ix86_indirect_branch_thunk_register with
11194 ix86_indirect_branch_register.
11195 (Bw): Likewise.
11196 * config/i386/i386.md (indirect_jump): Likewise.
11197 (tablejump): Likewise.
11198 (*sibcall_memory): Likewise.
11199 (*sibcall_value_memory): Likewise.
11200 Peepholes of indirect call and jump via memory: Likewise.
11201 * config/i386/i386.opt: Likewise.
11202 * config/i386/predicates.md (indirect_branch_operand): Likewise.
11203 (GOT_memory_operand): Likewise.
11204 (call_insn_operand): Likewise.
11205 (sibcall_insn_operand): Likewise.
11206 (GOT32_symbol_operand): Likewise.
11207
11208 2018-01-15 Jakub Jelinek <jakub@redhat.com>
11209
11210 PR middle-end/83837
11211 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
11212 type rather than type addr's type points to.
11213 (expand_omp_atomic_mutex): Likewise.
11214 (expand_omp_atomic): Likewise.
11215
11216 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
11217
11218 PR target/83839
11219 * config/i386/i386.c (output_indirect_thunk_function): Use
11220 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
11221 for __x86_return_thunk.
11222
11223 2018-01-15 Richard Biener <rguenther@suse.de>
11224
11225 PR middle-end/83850
11226 * expmed.c (extract_bit_field_1): Fix typo.
11227
11228 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11229
11230 PR target/83687
11231 * config/arm/iterators.md (VF): New mode iterator.
11232 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
11233 Remove integer-related logic from pattern.
11234 (neon_vabd<mode>_3): Likewise.
11235
11236 2018-01-15 Jakub Jelinek <jakub@redhat.com>
11237
11238 PR middle-end/82694
11239 * common.opt (fstrict-overflow): No longer an alias.
11240 (fwrapv-pointer): New option.
11241 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
11242 also for pointer types based on flag_wrapv_pointer.
11243 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
11244 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
11245 opts->x_flag_wrapv got set.
11246 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
11247 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
11248 POINTER_TYPE_OVERFLOW_UNDEFINED.
11249 * match.pd: Likewise in address comparison pattern.
11250 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
11251
11252 2018-01-15 Richard Biener <rguenther@suse.de>
11253
11254 PR lto/83804
11255 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
11256 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
11257 Reset type names to their identifier if their TYPE_DECL doesn't
11258 have linkage (and thus is used for ODR and devirt).
11259 (save_debug_info_for_decl): Remove.
11260 (save_debug_info_for_type): Likewise.
11261 (add_tree_to_fld_list): Adjust.
11262 * tree-pretty-print.c (dump_generic_node): Make dumping of
11263 type names more robust.
11264
11265 2018-01-15 Richard Biener <rguenther@suse.de>
11266
11267 * BASE-VER: Bump to 8.0.1.
11268
11269 2018-01-14 Martin Sebor <msebor@redhat.com>
11270
11271 PR other/83508
11272 * builtins.c (check_access): Avoid warning when the no-warning bit
11273 is set.
11274
11275 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
11276
11277 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
11278 * ira-color (allocno_hard_regs_compare): Likewise.
11279
11280 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
11281
11282 PR target/83013
11283 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
11284 Use .pushsection/.popsection.
11285
11286 2018-01-14 Martin Sebor <msebor@redhat.com>
11287
11288 PR c++/81327
11289 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
11290
11291 2018-01-14 Jakub Jelinek <jakub@redhat.com>
11292
11293 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
11294 entry from extra_headers.
11295 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
11296 extra_headers, make the list bitwise identical to the i?86-*-* one.
11297
11298 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11299
11300 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
11301 -mcmodel=large with -mindirect-branch=thunk,
11302 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
11303 -mfunction-return=thunk-extern.
11304 * doc/invoke.texi: Document -mcmodel=large is incompatible with
11305 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
11306 -mfunction-return=thunk and -mfunction-return=thunk-extern.
11307
11308 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11309
11310 * config/i386/i386.c (print_reg): Print the name of the full
11311 integer register without '%'.
11312 (ix86_print_operand): Handle 'V'.
11313 * doc/extend.texi: Document 'V' modifier.
11314
11315 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11316
11317 * config/i386/constraints.md (Bs): Disallow memory operand for
11318 -mindirect-branch-register.
11319 (Bw): Likewise.
11320 * config/i386/predicates.md (indirect_branch_operand): Likewise.
11321 (GOT_memory_operand): Likewise.
11322 (call_insn_operand): Likewise.
11323 (sibcall_insn_operand): Likewise.
11324 (GOT32_symbol_operand): Likewise.
11325 * config/i386/i386.md (indirect_jump): Call convert_memory_address
11326 for -mindirect-branch-register.
11327 (tablejump): Likewise.
11328 (*sibcall_memory): Likewise.
11329 (*sibcall_value_memory): Likewise.
11330 Disallow peepholes of indirect call and jump via memory for
11331 -mindirect-branch-register.
11332 (*call_pop): Replace m with Bw.
11333 (*call_value_pop): Likewise.
11334 (*sibcall_pop_memory): Replace m with Bs.
11335 * config/i386/i386.opt (mindirect-branch-register): New option.
11336 * doc/invoke.texi: Document -mindirect-branch-register option.
11337
11338 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11339
11340 * config/i386/i386-protos.h (ix86_output_function_return): New.
11341 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
11342 set function_return_type.
11343 (indirect_thunk_name): Add ret_p to indicate thunk for function
11344 return.
11345 (output_indirect_thunk_function): Pass false to
11346 indirect_thunk_name.
11347 (ix86_output_indirect_branch_via_reg): Likewise.
11348 (ix86_output_indirect_branch_via_push): Likewise.
11349 (output_indirect_thunk_function): Create alias for function
11350 return thunk if regno < 0.
11351 (ix86_output_function_return): New function.
11352 (ix86_handle_fndecl_attribute): Handle function_return.
11353 (ix86_attribute_table): Add function_return.
11354 * config/i386/i386.h (machine_function): Add
11355 function_return_type.
11356 * config/i386/i386.md (simple_return_internal): Use
11357 ix86_output_function_return.
11358 (simple_return_internal_long): Likewise.
11359 * config/i386/i386.opt (mfunction-return=): New option.
11360 (indirect_branch): Mention -mfunction-return=.
11361 * doc/extend.texi: Document function_return function attribute.
11362 * doc/invoke.texi: Document -mfunction-return= option.
11363
11364 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
11365
11366 * config/i386/i386-opts.h (indirect_branch): New.
11367 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
11368 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
11369 with local indirect jump when converting indirect call and jump.
11370 (ix86_set_indirect_branch_type): New.
11371 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
11372 (indirectlabelno): New.
11373 (indirect_thunk_needed): Likewise.
11374 (indirect_thunk_bnd_needed): Likewise.
11375 (indirect_thunks_used): Likewise.
11376 (indirect_thunks_bnd_used): Likewise.
11377 (INDIRECT_LABEL): Likewise.
11378 (indirect_thunk_name): Likewise.
11379 (output_indirect_thunk): Likewise.
11380 (output_indirect_thunk_function): Likewise.
11381 (ix86_output_indirect_branch_via_reg): Likewise.
11382 (ix86_output_indirect_branch_via_push): Likewise.
11383 (ix86_output_indirect_branch): Likewise.
11384 (ix86_output_indirect_jmp): Likewise.
11385 (ix86_code_end): Call output_indirect_thunk_function if needed.
11386 (ix86_output_call_insn): Call ix86_output_indirect_branch if
11387 needed.
11388 (ix86_handle_fndecl_attribute): Handle indirect_branch.
11389 (ix86_attribute_table): Add indirect_branch.
11390 * config/i386/i386.h (machine_function): Add indirect_branch_type
11391 and has_local_indirect_jump.
11392 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
11393 to true.
11394 (tablejump): Likewise.
11395 (*indirect_jump): Use ix86_output_indirect_jmp.
11396 (*tablejump_1): Likewise.
11397 (simple_return_indirect_internal): Likewise.
11398 * config/i386/i386.opt (mindirect-branch=): New option.
11399 (indirect_branch): New.
11400 (keep): Likewise.
11401 (thunk): Likewise.
11402 (thunk-inline): Likewise.
11403 (thunk-extern): Likewise.
11404 * doc/extend.texi: Document indirect_branch function attribute.
11405 * doc/invoke.texi: Document -mindirect-branch= option.
11406
11407 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
11408
11409 PR ipa/83051
11410 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
11411
11412 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
11413
11414 * ipa-inline.c (want_inline_small_function_p): Return false if
11415 inlining has already failed with CIF_FINAL_ERROR.
11416 (update_caller_keys): Call want_inline_small_function_p before
11417 can_inline_edge_p.
11418 (update_callee_keys): Likewise.
11419
11420 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
11421
11422 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
11423 New function.
11424 (rs6000_quadword_masked_address_p): Likewise.
11425 (quad_aligned_load_p): Likewise.
11426 (quad_aligned_store_p): Likewise.
11427 (const_load_sequence_p): Add comment to describe the outer-most loop.
11428 (mimic_memory_attributes_and_flags): New function.
11429 (rs6000_gen_stvx): Likewise.
11430 (replace_swapped_aligned_store): Likewise.
11431 (rs6000_gen_lvx): Likewise.
11432 (replace_swapped_aligned_load): Likewise.
11433 (replace_swapped_load_constant): Capitalize argument name in
11434 comment describing this function.
11435 (rs6000_analyze_swaps): Add a third pass to search for vector loads
11436 and stores that access quad-word aligned addresses and replace
11437 with stvx or lvx instructions when appropriate.
11438 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
11439 New function prototype.
11440 (rs6000_quadword_masked_address_p): Likewise.
11441 (rs6000_gen_lvx): Likewise.
11442 (rs6000_gen_stvx): Likewise.
11443 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
11444 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
11445 when memory address is aligned.
11446 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
11447 this split to select lvx instruction when memory address is aligned.
11448 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
11449 instruction when memory address is aligned.
11450 (*vsx_le_perm_load_v16qi): Likewise.
11451 (four unnamed splitters): Modify to select the stvx instruction
11452 when memory is aligned.
11453
11454 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
11455
11456 * predict.c (determine_unlikely_bbs): Handle correctly BBs
11457 which appears in the queue multiple times.
11458
11459 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11460 Alan Hayward <alan.hayward@arm.com>
11461 David Sherwood <david.sherwood@arm.com>
11462
11463 * tree-vectorizer.h (vec_lower_bound): New structure.
11464 (_loop_vec_info): Add check_nonzero and lower_bounds.
11465 (LOOP_VINFO_CHECK_NONZERO): New macro.
11466 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
11467 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
11468 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
11469 fields. Make seg_len the distance travelled, not including the
11470 access size.
11471 (dr_direction_indicator): Declare.
11472 (dr_zero_step_indicator): Likewise.
11473 (dr_known_forward_stride_p): Likewise.
11474 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
11475 tree-ssanames.h.
11476 (runtime_alias_check_p): Allow runtime alias checks with
11477 variable strides.
11478 (operator ==): Compare access_size and align.
11479 (prune_runtime_alias_test_list): Rework for new distinction between
11480 the access_size and seg_len.
11481 (create_intersect_range_checks_index): Likewise. Cope with polynomial
11482 segment lengths.
11483 (get_segment_min_max): New function.
11484 (create_intersect_range_checks): Use it.
11485 (dr_step_indicator): New function.
11486 (dr_direction_indicator): Likewise.
11487 (dr_zero_step_indicator): Likewise.
11488 (dr_known_forward_stride_p): Likewise.
11489 * tree-loop-distribution.c (data_ref_segment_size): Return
11490 DR_STEP * (niters - 1).
11491 (compute_alias_check_pairs): Update call to the dr_with_seg_len
11492 constructor.
11493 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
11494 (vect_preserves_scalar_order_p): New function, split out from...
11495 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
11496 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
11497 (vect_vfa_access_size): New function.
11498 (vect_vfa_align): Likewise.
11499 (vect_compile_time_alias): Take access_size_a and access_b arguments.
11500 (dump_lower_bound): New function.
11501 (vect_check_lower_bound): Likewise.
11502 (vect_small_gap_p): Likewise.
11503 (vectorizable_with_step_bound_p): Likewise.
11504 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
11505 depencies if the vectorization factor is 1. Convert the checks
11506 for nonzero steps into checks on the bounds of DR_STEP. Try using
11507 a bunds check for variable steps if the minimum required step is
11508 relatively small. Update calls to the dr_with_seg_len
11509 constructor and to vect_compile_time_alias.
11510 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
11511 function.
11512 (vect_loop_versioning): Call it.
11513 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
11514 when retrying.
11515 (vect_estimate_min_profitable_iters): Account for any bounds checks.
11516
11517 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11518 Alan Hayward <alan.hayward@arm.com>
11519 David Sherwood <david.sherwood@arm.com>
11520
11521 * doc/sourcebuild.texi (vect_scatter_store): Document.
11522 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
11523 optabs.
11524 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
11525 Document.
11526 * genopinit.c (main): Add supports_vec_scatter_store and
11527 supports_vec_scatter_store_cached to target_optabs.
11528 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
11529 IFN_MASK_SCATTER_STORE.
11530 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
11531 functions.
11532 * internal-fn.h (internal_store_fn_p): Declare.
11533 (internal_fn_stored_value_index): Likewise.
11534 * internal-fn.c (scatter_store_direct): New macro.
11535 (expand_scatter_store_optab_fn): New function.
11536 (direct_scatter_store_optab_supported_p): New macro.
11537 (internal_store_fn_p): New function.
11538 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
11539 IFN_MASK_SCATTER_STORE.
11540 (internal_fn_mask_index): Likewise.
11541 (internal_fn_stored_value_index): New function.
11542 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
11543 for scatter stores.
11544 * optabs-query.h (supports_vec_scatter_store_p): Declare.
11545 * optabs-query.c (supports_vec_scatter_store_p): New function.
11546 * tree-vectorizer.h (vect_get_store_rhs): Declare.
11547 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
11548 true for scatter stores.
11549 (vect_gather_scatter_fn_p): Handle scatter stores too.
11550 (vect_check_gather_scatter): Consider using scatter stores if
11551 supports_vec_scatter_store_p.
11552 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
11553 scatter stores too.
11554 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
11555 internal_fn_stored_value_index.
11556 (check_load_store_masking): Handle scatter stores too.
11557 (vect_get_store_rhs): Make public.
11558 (vectorizable_call): Use internal_store_fn_p.
11559 (vectorizable_store): Handle scatter store internal functions.
11560 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
11561 when deciding whether the end of the group has been reached.
11562 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
11563 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
11564 (mask_scatter_store<mode>): New insns.
11565
11566 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11567 Alan Hayward <alan.hayward@arm.com>
11568 David Sherwood <david.sherwood@arm.com>
11569
11570 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
11571 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
11572 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
11573 function.
11574 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
11575 Use vect_truncate_gather_scatter_offset if we can't treat the
11576 operation as a normal gather load or scatter store.
11577 (get_group_load_store_type): Take the gather_scatter_info
11578 as argument. Try using a gather load or scatter store for
11579 single-element groups.
11580 (get_load_store_type): Update calls to get_group_load_store_type
11581 and vect_use_strided_gather_scatters_p.
11582
11583 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11584 Alan Hayward <alan.hayward@arm.com>
11585 David Sherwood <david.sherwood@arm.com>
11586
11587 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
11588 optional tree argument.
11589 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
11590 null target hooks.
11591 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
11592 but continue to use the current value as a fallback.
11593 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
11594 to compare the updates.
11595 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
11596 (get_load_store_type): Use it when handling a strided access.
11597 (vect_get_strided_load_store_ops): New function.
11598 (vect_get_data_ptr_increment): Likewise.
11599 (vectorizable_load): Handle strided gather loads. Always pass
11600 a step to vect_create_data_ref_ptr and bump_vector_ptr.
11601
11602 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11603 Alan Hayward <alan.hayward@arm.com>
11604 David Sherwood <david.sherwood@arm.com>
11605
11606 * doc/md.texi (gather_load@var{m}): Document.
11607 (mask_gather_load@var{m}): Likewise.
11608 * genopinit.c (main): Add supports_vec_gather_load and
11609 supports_vec_gather_load_cached to target_optabs.
11610 * optabs-tree.c (init_tree_optimization_optabs): Use
11611 ggc_cleared_alloc to allocate target_optabs.
11612 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
11613 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
11614 functions.
11615 * internal-fn.h (internal_load_fn_p): Declare.
11616 (internal_gather_scatter_fn_p): Likewise.
11617 (internal_fn_mask_index): Likewise.
11618 (internal_gather_scatter_fn_supported_p): Likewise.
11619 * internal-fn.c (gather_load_direct): New macro.
11620 (expand_gather_load_optab_fn): New function.
11621 (direct_gather_load_optab_supported_p): New macro.
11622 (direct_internal_fn_optab): New function.
11623 (internal_load_fn_p): Likewise.
11624 (internal_gather_scatter_fn_p): Likewise.
11625 (internal_fn_mask_index): Likewise.
11626 (internal_gather_scatter_fn_supported_p): Likewise.
11627 * optabs-query.c (supports_at_least_one_mode_p): New function.
11628 (supports_vec_gather_load_p): Likewise.
11629 * optabs-query.h (supports_vec_gather_load_p): Declare.
11630 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
11631 and memory_type field.
11632 (NUM_PATTERNS): Bump to 15.
11633 * tree-vect-data-refs.c: Include internal-fn.h.
11634 (vect_gather_scatter_fn_p): New function.
11635 (vect_describe_gather_scatter_call): Likewise.
11636 (vect_check_gather_scatter): Try using internal functions for
11637 gather loads. Recognize existing calls to a gather load function.
11638 (vect_analyze_data_refs): Consider using gather loads if
11639 supports_vec_gather_load_p.
11640 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
11641 (vect_get_gather_scatter_offset_type): Likewise.
11642 (vect_convert_mask_for_vectype): Likewise.
11643 (vect_add_conversion_to_patterm): Likewise.
11644 (vect_try_gather_scatter_pattern): Likewise.
11645 (vect_recog_gather_scatter_pattern): New pattern recognizer.
11646 (vect_vect_recog_func_ptrs): Add it.
11647 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
11648 internal_fn_mask_index and internal_gather_scatter_fn_p.
11649 (check_load_store_masking): Take the gather_scatter_info as an
11650 argument and handle gather loads.
11651 (vect_get_gather_scatter_ops): New function.
11652 (vectorizable_call): Check internal_load_fn_p.
11653 (vectorizable_load): Likewise. Handle gather load internal
11654 functions.
11655 (vectorizable_store): Update call to check_load_store_masking.
11656 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
11657 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
11658 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
11659 (aarch64_gather_scale_operand_d): New predicates.
11660 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
11661 (mask_gather_load<mode>): New insns.
11662
11663 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11664 Alan Hayward <alan.hayward@arm.com>
11665 David Sherwood <david.sherwood@arm.com>
11666
11667 * optabs.def (fold_left_plus_optab): New optab.
11668 * doc/md.texi (fold_left_plus_@var{m}): Document.
11669 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
11670 * internal-fn.c (fold_left_direct): Define.
11671 (expand_fold_left_optab_fn): Likewise.
11672 (direct_fold_left_optab_supported_p): Likewise.
11673 * fold-const-call.c (fold_const_fold_left): New function.
11674 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
11675 * tree-parloops.c (valid_reduction_p): New function.
11676 (gather_scalar_reductions): Use it.
11677 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
11678 (vect_finish_replace_stmt): Declare.
11679 * tree-vect-loop.c (fold_left_reduction_fn): New function.
11680 (needs_fold_left_reduction_p): New function, split out from...
11681 (vect_is_simple_reduction): ...here. Accept reductions that
11682 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
11683 (vect_force_simple_reduction): Also store the reduction type in
11684 the assignment's STMT_VINFO_REDUC_TYPE.
11685 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
11686 (merge_with_identity): New function.
11687 (vect_expand_fold_left): Likewise.
11688 (vectorize_fold_left_reduction): Likewise.
11689 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
11690 scalar phi in place for it. Check for target support and reject
11691 cases that would reassociate the operation. Defer the transform
11692 phase to vectorize_fold_left_reduction.
11693 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
11694 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
11695 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
11696
11697 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11698
11699 * tree-if-conv.c (predicate_mem_writes): Remove redundant
11700 call to ifc_temp_var.
11701
11702 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11703 Alan Hayward <alan.hayward@arm.com>
11704 David Sherwood <david.sherwood@arm.com>
11705
11706 * target.def (legitimize_address_displacement): Take the original
11707 offset as a poly_int.
11708 * targhooks.h (default_legitimize_address_displacement): Update
11709 accordingly.
11710 * targhooks.c (default_legitimize_address_displacement): Likewise.
11711 * doc/tm.texi: Regenerate.
11712 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
11713 as an argument, moving assert of ad->disp == ad->disp_term to...
11714 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
11715 Try calling targetm.legitimize_address_displacement before expanding
11716 the address rather than afterwards, and adjust for the new interface.
11717 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
11718 Match the new hook interface. Handle SVE addresses.
11719 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
11720 new hook interface.
11721
11722 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11723
11724 * Makefile.in (OBJS): Add early-remat.o.
11725 * target.def (select_early_remat_modes): New hook.
11726 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
11727 * doc/tm.texi: Regenerate.
11728 * targhooks.h (default_select_early_remat_modes): Declare.
11729 * targhooks.c (default_select_early_remat_modes): New function.
11730 * timevar.def (TV_EARLY_REMAT): New timevar.
11731 * passes.def (pass_early_remat): New pass.
11732 * tree-pass.h (make_pass_early_remat): Declare.
11733 * early-remat.c: New file.
11734 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
11735 function.
11736 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
11737
11738 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11739 Alan Hayward <alan.hayward@arm.com>
11740 David Sherwood <david.sherwood@arm.com>
11741
11742 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
11743 vfm1 with a bound_epilog parameter.
11744 (vect_do_peeling): Update calls accordingly, and move the prologue
11745 call earlier in the function. Treat the base bound_epilog as 0 for
11746 fully-masked loops and retain vf - 1 for other loops. Add 1 to
11747 this base when peeling for gaps.
11748 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
11749 with fully-masked loops.
11750 (vect_estimate_min_profitable_iters): Handle the single peeled
11751 iteration in that case.
11752
11753 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11754 Alan Hayward <alan.hayward@arm.com>
11755 David Sherwood <david.sherwood@arm.com>
11756
11757 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
11758 single-element interleaving even if the size is not a power of 2.
11759 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
11760 accesses for single-element interleaving if the group size is
11761 not a power of 2.
11762
11763 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11764 Alan Hayward <alan.hayward@arm.com>
11765 David Sherwood <david.sherwood@arm.com>
11766
11767 * doc/md.texi (fold_extract_last_@var{m}): Document.
11768 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
11769 * optabs.def (fold_extract_last_optab): New optab.
11770 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
11771 * internal-fn.c (fold_extract_direct): New macro.
11772 (expand_fold_extract_optab_fn): Likewise.
11773 (direct_fold_extract_optab_supported_p): Likewise.
11774 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
11775 * tree-vect-loop.c (vect_model_reduction_cost): Handle
11776 EXTRACT_LAST_REDUCTION.
11777 (get_initial_def_for_reduction): Do not create an initial vector
11778 for EXTRACT_LAST_REDUCTION reductions.
11779 (vectorizable_reduction): Leave the scalar phi in place for
11780 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
11781 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
11782 epilogue code for EXTRACT_LAST_REDUCTION and defer the
11783 transform phase to vectorizable_condition.
11784 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
11785 split out from...
11786 (vect_finish_stmt_generation): ...here.
11787 (vect_finish_replace_stmt): New function.
11788 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
11789 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
11790 pattern.
11791 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
11792
11793 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11794 Alan Hayward <alan.hayward@arm.com>
11795 David Sherwood <david.sherwood@arm.com>
11796
11797 * doc/md.texi (extract_last_@var{m}): Document.
11798 * optabs.def (extract_last_optab): New optab.
11799 * internal-fn.def (EXTRACT_LAST): New internal function.
11800 * internal-fn.c (cond_unary_direct): New macro.
11801 (expand_cond_unary_optab_fn): Likewise.
11802 (direct_cond_unary_optab_supported_p): Likewise.
11803 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
11804 loops using EXTRACT_LAST.
11805 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
11806 (extract_last_<mode>): ...this optab.
11807 (vec_extract<mode><Vel>): Update accordingly.
11808
11809 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11810 Alan Hayward <alan.hayward@arm.com>
11811 David Sherwood <david.sherwood@arm.com>
11812
11813 * target.def (empty_mask_is_expensive): New hook.
11814 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
11815 * doc/tm.texi: Regenerate.
11816 * targhooks.h (default_empty_mask_is_expensive): Declare.
11817 * targhooks.c (default_empty_mask_is_expensive): New function.
11818 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
11819 if the target says that empty masks are expensive.
11820 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
11821 New function.
11822 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
11823
11824 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11825 Alan Hayward <alan.hayward@arm.com>
11826 David Sherwood <david.sherwood@arm.com>
11827
11828 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
11829 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
11830 (vect_use_loop_mask_for_alignment_p): New function.
11831 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
11832 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
11833 niters_skip argument. Make sure that the first niters_skip elements
11834 of the first iteration are inactive.
11835 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
11836 Update call to vect_set_loop_masks_directly.
11837 (get_misalign_in_elems): New function, split out from...
11838 (vect_gen_prolog_loop_niters): ...here.
11839 (vect_update_init_of_dr): Take a code argument that specifies whether
11840 the adjustment should be added or subtracted.
11841 (vect_update_init_of_drs): Likewise.
11842 (vect_prepare_for_masked_peels): New function.
11843 (vect_do_peeling): Skip prologue peeling if we're using a mask
11844 instead. Update call to vect_update_inits_of_drs.
11845 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
11846 mask_skip_niters.
11847 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
11848 alignment. Do not include the number of peeled iterations in
11849 the minimum threshold in that case.
11850 (vectorizable_induction): Adjust the start value down by
11851 LOOP_VINFO_MASK_SKIP_NITERS iterations.
11852 (vect_transform_loop): Call vect_prepare_for_masked_peels.
11853 Take the number of skipped iterations into account when calculating
11854 the loop bounds.
11855 * tree-vect-stmts.c (vect_gen_while_not): New function.
11856
11857 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11858 Alan Hayward <alan.hayward@arm.com>
11859 David Sherwood <david.sherwood@arm.com>
11860
11861 * doc/sourcebuild.texi (vect_fully_masked): Document.
11862 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
11863 default value to 0.
11864 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
11865 split out from...
11866 (vect_analyze_loop_2): ...here. Don't check the vectorization
11867 factor against the number of loop iterations if the loop is
11868 fully-masked.
11869
11870 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11871 Alan Hayward <alan.hayward@arm.com>
11872 David Sherwood <david.sherwood@arm.com>
11873
11874 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
11875 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
11876 (dump_groups): Update accordingly.
11877 (iv_use::mem_type): New member variable.
11878 (address_p): New function.
11879 (record_use): Add a mem_type argument and initialize the new
11880 mem_type field.
11881 (record_group_use): Add a mem_type argument. Use address_p.
11882 Remove obsolete null checks of base_object. Update call to record_use.
11883 (find_interesting_uses_op): Update call to record_group_use.
11884 (find_interesting_uses_cond): Likewise.
11885 (find_interesting_uses_address): Likewise.
11886 (get_mem_type_for_internal_fn): New function.
11887 (find_address_like_use): Likewise.
11888 (find_interesting_uses_stmt): Try find_address_like_use before
11889 calling find_interesting_uses_op.
11890 (addr_offset_valid_p): Use the iv mem_type field as the type
11891 of the addressed memory.
11892 (add_autoinc_candidates): Likewise.
11893 (get_address_cost): Likewise.
11894 (split_small_address_groups_p): Use address_p.
11895 (split_address_groups): Likewise.
11896 (add_iv_candidate_for_use): Likewise.
11897 (autoinc_possible_for_pair): Likewise.
11898 (rewrite_groups): Likewise.
11899 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
11900 (determine_group_iv_cost): Update after split of USE_ADDRESS.
11901 (get_alias_ptr_type_for_ptr_address): New function.
11902 (rewrite_use_address): Rewrite address uses in calls that were
11903 identified by find_address_like_use.
11904
11905 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11906 Alan Hayward <alan.hayward@arm.com>
11907 David Sherwood <david.sherwood@arm.com>
11908
11909 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
11910 TARGET_MEM_REFs.
11911 * gimple-expr.h (is_gimple_addressable: Likewise.
11912 * gimple-expr.c (is_gimple_address): Likewise.
11913 * internal-fn.c (expand_call_mem_ref): New function.
11914 (expand_mask_load_optab_fn): Use it.
11915 (expand_mask_store_optab_fn): Likewise.
11916
11917 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11918 Alan Hayward <alan.hayward@arm.com>
11919 David Sherwood <david.sherwood@arm.com>
11920
11921 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
11922 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
11923 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
11924 (cond_umax@var{mode}): Document.
11925 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
11926 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
11927 (cond_umin_optab, cond_umax_optab): New optabs.
11928 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
11929 (COND_IOR, COND_XOR): New internal functions.
11930 * internal-fn.h (get_conditional_internal_fn): Declare.
11931 * internal-fn.c (cond_binary_direct): New macro.
11932 (expand_cond_binary_optab_fn): Likewise.
11933 (direct_cond_binary_optab_supported_p): Likewise.
11934 (get_conditional_internal_fn): New function.
11935 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
11936 Cope with reduction statements that are vectorized as calls rather
11937 than assignments.
11938 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
11939 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
11940 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
11941 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
11942 (UNSPEC_COND_EOR): New unspecs.
11943 (optab): Add mappings for them.
11944 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
11945 (sve_int_op, sve_fp_op): New int attributes.
11946
11947 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
11948 Alan Hayward <alan.hayward@arm.com>
11949 David Sherwood <david.sherwood@arm.com>
11950
11951 * optabs.def (while_ult_optab): New optab.
11952 * doc/md.texi (while_ult@var{m}@var{n}): Document.
11953 * internal-fn.def (WHILE_ULT): New internal function.
11954 * internal-fn.h (direct_internal_fn_supported_p): New override
11955 that takes two types as argument.
11956 * internal-fn.c (while_direct): New macro.
11957 (expand_while_optab_fn): New function.
11958 (convert_optab_supported_p): Likewise.
11959 (direct_while_optab_supported_p): New macro.
11960 * wide-int.h (wi::udiv_ceil): New function.
11961 * tree-vectorizer.h (rgroup_masks): New structure.
11962 (vec_loop_masks): New typedef.
11963 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
11964 and fully_masked_p.
11965 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
11966 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
11967 (vect_max_vf): New function.
11968 (slpeel_make_loop_iterate_ntimes): Delete.
11969 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
11970 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
11971 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
11972 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
11973 internal-fn.h, stor-layout.h and optabs-query.h.
11974 (vect_set_loop_mask): New function.
11975 (add_preheader_seq): Likewise.
11976 (add_header_seq): Likewise.
11977 (interleave_supported_p): Likewise.
11978 (vect_maybe_permute_loop_masks): Likewise.
11979 (vect_set_loop_masks_directly): Likewise.
11980 (vect_set_loop_condition_masked): Likewise.
11981 (vect_set_loop_condition_unmasked): New function, split out from
11982 slpeel_make_loop_iterate_ntimes.
11983 (slpeel_make_loop_iterate_ntimes): Rename to..
11984 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
11985 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
11986 (vect_do_peeling): Update call accordingly.
11987 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
11988 loops.
11989 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
11990 mask_compare_type, can_fully_mask_p and fully_masked_p.
11991 (release_vec_loop_masks): New function.
11992 (_loop_vec_info): Use it to free the loop masks.
11993 (can_produce_all_loop_masks_p): New function.
11994 (vect_get_max_nscalars_per_iter): Likewise.
11995 (vect_verify_full_masking): Likewise.
11996 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
11997 retries, and free the mask rgroups before retrying. Check loop-wide
11998 reasons for disallowing fully-masked loops. Make the final decision
11999 about whether use a fully-masked loop or not.
12000 (vect_estimate_min_profitable_iters): Do not assume that peeling
12001 for the number of iterations will be needed for fully-masked loops.
12002 (vectorizable_reduction): Disable fully-masked loops.
12003 (vectorizable_live_operation): Likewise.
12004 (vect_halve_mask_nunits): New function.
12005 (vect_double_mask_nunits): Likewise.
12006 (vect_record_loop_mask): Likewise.
12007 (vect_get_loop_mask): Likewise.
12008 (vect_transform_loop): Handle the case in which the final loop
12009 iteration might handle a partial vector. Call vect_set_loop_condition
12010 instead of slpeel_make_loop_iterate_ntimes.
12011 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
12012 (check_load_store_masking): New function.
12013 (prepare_load_store_mask): Likewise.
12014 (vectorizable_store): Handle fully-masked loops.
12015 (vectorizable_load): Likewise.
12016 (supportable_widening_operation): Use vect_halve_mask_nunits for
12017 booleans.
12018 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
12019 (vect_gen_while): New function.
12020 * config/aarch64/aarch64.md (umax<mode>3): New expander.
12021 (aarch64_uqdec<mode>): New insn.
12022
12023 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12024 Alan Hayward <alan.hayward@arm.com>
12025 David Sherwood <david.sherwood@arm.com>
12026
12027 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
12028 (reduc_xor_scal_optab): New optabs.
12029 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
12030 (reduc_xor_scal_@var{m}): Document.
12031 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
12032 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
12033 internal functions.
12034 * fold-const-call.c (fold_const_call): Handle them.
12035 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
12036 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
12037 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
12038 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
12039 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
12040 (UNSPEC_XORV): New unspecs.
12041 (optab): Add entries for them.
12042 (BITWISEV): New int iterator.
12043 (bit_reduc_op): New int attributes.
12044
12045 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12046 Alan Hayward <alan.hayward@arm.com>
12047 David Sherwood <david.sherwood@arm.com>
12048
12049 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
12050 * internal-fn.def (VEC_SHL_INSERT): New internal function.
12051 * optabs.def (vec_shl_insert_optab): New optab.
12052 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
12053 (duplicate_and_interleave): Likewise.
12054 * tree-vect-loop.c: Include internal-fn.h.
12055 (neutral_op_for_slp_reduction): New function, split out from
12056 get_initial_defs_for_reduction.
12057 (get_initial_def_for_reduction): Handle option 2 for variable-length
12058 vectors by loading the neutral value into a vector and then shifting
12059 the initial value into element 0.
12060 (get_initial_defs_for_reduction): Replace the code argument with
12061 the neutral value calculated by neutral_op_for_slp_reduction.
12062 Use gimple_build_vector for constant-length vectors.
12063 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
12064 but the first group_size elements have a neutral value.
12065 Use duplicate_and_interleave otherwise.
12066 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
12067 Update call to get_initial_defs_for_reduction. Handle SLP
12068 reductions for variable-length vectors by creating one vector
12069 result for each scalar result, with the elements associated
12070 with other scalar results stubbed out with the neutral value.
12071 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
12072 Require IFN_VEC_SHL_INSERT for double reductions on
12073 variable-length vectors, or SLP reductions that have
12074 a neutral value. Require can_duplicate_and_interleave_p
12075 support for variable-length unchained SLP reductions if there
12076 is no neutral value, such as for MIN/MAX reductions. Also require
12077 the number of vector elements to be a multiple of the number of
12078 SLP statements when doing variable-length unchained SLP reductions.
12079 Update call to vect_create_epilog_for_reduction.
12080 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
12081 and remove initial values.
12082 (duplicate_and_interleave): Make public.
12083 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
12084 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
12085
12086 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12087 Alan Hayward <alan.hayward@arm.com>
12088 David Sherwood <david.sherwood@arm.com>
12089
12090 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
12091 (can_duplicate_and_interleave_p): New function.
12092 (vect_get_and_check_slp_defs): Take the vector of statements
12093 rather than just the current one. Remove excess parentheses.
12094 Restriction rejectinon of vect_constant_def and vect_external_def
12095 for variable-length vectors to boolean types, or types for which
12096 can_duplicate_and_interleave_p is false.
12097 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
12098 (duplicate_and_interleave): New function.
12099 (vect_get_constant_vectors): Use gimple_build_vector for
12100 constant-length vectors and suitable variable-length constant
12101 vectors. Use duplicate_and_interleave for other variable-length
12102 vectors. Don't defer the update when inserting new statements.
12103
12104 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12105 Alan Hayward <alan.hayward@arm.com>
12106 David Sherwood <david.sherwood@arm.com>
12107
12108 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
12109 min_profitable_iters doesn't go negative.
12110
12111 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12112 Alan Hayward <alan.hayward@arm.com>
12113 David Sherwood <david.sherwood@arm.com>
12114
12115 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
12116 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
12117 * optabs.def (vec_mask_load_lanes_optab): New optab.
12118 (vec_mask_store_lanes_optab): Likewise.
12119 * internal-fn.def (MASK_LOAD_LANES): New internal function.
12120 (MASK_STORE_LANES): Likewise.
12121 * internal-fn.c (mask_load_lanes_direct): New macro.
12122 (mask_store_lanes_direct): Likewise.
12123 (expand_mask_load_optab_fn): Handle masked operations.
12124 (expand_mask_load_lanes_optab_fn): New macro.
12125 (expand_mask_store_optab_fn): Handle masked operations.
12126 (expand_mask_store_lanes_optab_fn): New macro.
12127 (direct_mask_load_lanes_optab_supported_p): Likewise.
12128 (direct_mask_store_lanes_optab_supported_p): Likewise.
12129 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
12130 parameter.
12131 (vect_load_lanes_supported): Likewise.
12132 * tree-vect-data-refs.c (strip_conversion): New function.
12133 (can_group_stmts_p): Likewise.
12134 (vect_analyze_data_ref_accesses): Use it instead of checking
12135 for a pair of assignments.
12136 (vect_store_lanes_supported): Take a masked_p parameter.
12137 (vect_load_lanes_supported): Likewise.
12138 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
12139 vect_store_lanes_supported and vect_load_lanes_supported.
12140 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
12141 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
12142 parameter. Don't allow gaps for masked accesses.
12143 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
12144 and vect_load_lanes_supported.
12145 (get_load_store_type): Take a masked_p parameter and update
12146 call to get_group_load_store_type.
12147 (vectorizable_store): Update call to get_load_store_type.
12148 Handle IFN_MASK_STORE_LANES.
12149 (vectorizable_load): Update call to get_load_store_type.
12150 Handle IFN_MASK_LOAD_LANES.
12151
12152 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12153 Alan Hayward <alan.hayward@arm.com>
12154 David Sherwood <david.sherwood@arm.com>
12155
12156 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
12157 modes for SVE.
12158 * config/aarch64/aarch64-protos.h
12159 (aarch64_sve_struct_memory_operand_p): Declare.
12160 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
12161 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
12162 (VPRED, vpred): Handle SVE structure modes.
12163 * config/aarch64/constraints.md (Utx): New constraint.
12164 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
12165 (aarch64_sve_struct_nonimmediate_operand): New predicates.
12166 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
12167 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
12168 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
12169 structure modes. Split into pieces after RA.
12170 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
12171 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
12172 New patterns.
12173 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
12174 SVE structure modes.
12175 (aarch64_classify_address): Likewise.
12176 (sizetochar): Move earlier in file.
12177 (aarch64_print_operand): Handle SVE register lists.
12178 (aarch64_array_mode): New function.
12179 (aarch64_sve_struct_memory_operand_p): Likewise.
12180 (TARGET_ARRAY_MODE): Redefine.
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 * target.def (array_mode): New target hook.
12187 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
12188 * doc/tm.texi: Regenerate.
12189 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
12190 * hooks.c (hook_optmode_mode_uhwi_none): New function.
12191 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
12192 targetm.array_mode.
12193 * stor-layout.c (mode_for_array): Likewise. Support polynomial
12194 type sizes.
12195
12196 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12197 Alan Hayward <alan.hayward@arm.com>
12198 David Sherwood <david.sherwood@arm.com>
12199
12200 * fold-const.c (fold_binary_loc): Check the argument types
12201 rather than the result type when testing for a vector operation.
12202
12203 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12204
12205 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
12206 * doc/tm.texi: Regenerate.
12207
12208 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12209 Alan Hayward <alan.hayward@arm.com>
12210 David Sherwood <david.sherwood@arm.com>
12211
12212 * doc/invoke.texi (-msve-vector-bits=): Document new option.
12213 (sve): Document new AArch64 extension.
12214 * doc/md.texi (w): Extend the description of the AArch64
12215 constraint to include SVE vectors.
12216 (Upl, Upa): Document new AArch64 predicate constraints.
12217 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
12218 enum.
12219 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
12220 (msve-vector-bits=): New option.
12221 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
12222 SVE when these are disabled.
12223 (sve): New extension.
12224 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
12225 modes. Adjust their number of units based on aarch64_sve_vg.
12226 (MAX_BITSIZE_MODE_ANY_MODE): Define.
12227 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
12228 aarch64_addr_query_type.
12229 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
12230 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
12231 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
12232 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
12233 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
12234 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
12235 (aarch64_simd_imm_zero_p): Delete.
12236 (aarch64_check_zero_based_sve_index_immediate): Declare.
12237 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
12238 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
12239 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
12240 (aarch64_sve_float_mul_immediate_p): Likewise.
12241 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
12242 rather than an rtx.
12243 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
12244 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
12245 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
12246 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
12247 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
12248 (aarch64_regmode_natural_size): Likewise.
12249 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
12250 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
12251 left one place.
12252 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
12253 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
12254 for VG and the SVE predicate registers.
12255 (V_ALIASES): Add a "z"-prefixed alias.
12256 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
12257 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
12258 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
12259 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
12260 (REG_CLASS_NAMES): Add entries for them.
12261 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
12262 and the predicate registers.
12263 (aarch64_sve_vg): Declare.
12264 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
12265 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
12266 (REGMODE_NATURAL_SIZE): Define.
12267 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
12268 SVE macros.
12269 * config/aarch64/aarch64.c: Include cfgrtl.h.
12270 (simd_immediate_info): Add a constructor for series vectors,
12271 and an associated step field.
12272 (aarch64_sve_vg): New variable.
12273 (aarch64_dbx_register_number): Handle VG and the predicate registers.
12274 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
12275 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
12276 (VEC_ANY_DATA, VEC_STRUCT): New constants.
12277 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
12278 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
12279 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
12280 (aarch64_get_mask_mode): New functions.
12281 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
12282 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
12283 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
12284 predicate modes and predicate registers. Explicitly restrict
12285 GPRs to modes of 16 bytes or smaller. Only allow FP registers
12286 to store a vector mode if it is recognized by
12287 aarch64_classify_vector_mode.
12288 (aarch64_regmode_natural_size): New function.
12289 (aarch64_hard_regno_caller_save_mode): Return the original mode
12290 for predicates.
12291 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
12292 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
12293 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
12294 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
12295 functions.
12296 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
12297 does not overlap dest if the function is frame-related. Handle
12298 SVE constants.
12299 (aarch64_split_add_offset): New function.
12300 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
12301 them aarch64_add_offset.
12302 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
12303 and update call to aarch64_sub_sp.
12304 (aarch64_add_cfa_expression): New function.
12305 (aarch64_expand_prologue): Pass extra temporary registers to the
12306 functions above. Handle the case in which we need to emit new
12307 DW_CFA_expressions for registers that were originally saved
12308 relative to the stack pointer, but now have to be expressed
12309 relative to the frame pointer.
12310 (aarch64_output_mi_thunk): Pass extra temporary registers to the
12311 functions above.
12312 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
12313 IP0 and IP1 values for SVE frames.
12314 (aarch64_expand_vec_series): New function.
12315 (aarch64_expand_sve_widened_duplicate): Likewise.
12316 (aarch64_expand_sve_const_vector): Likewise.
12317 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
12318 Handle SVE constants. Use emit_move_insn to move a force_const_mem
12319 into the register, rather than emitting a SET directly.
12320 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
12321 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
12322 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
12323 (offset_9bit_signed_scaled_p): New functions.
12324 (aarch64_replicate_bitmask_imm): New function.
12325 (aarch64_bitmask_imm): Use it.
12326 (aarch64_cannot_force_const_mem): Reject expressions involving
12327 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
12328 (aarch64_classify_index): Handle SVE indices, by requiring
12329 a plain register index with a scale that matches the element size.
12330 (aarch64_classify_address): Handle SVE addresses. Assert that
12331 the mode of the address is VOIDmode or an integer mode.
12332 Update call to aarch64_classify_symbol.
12333 (aarch64_classify_symbolic_expression): Update call to
12334 aarch64_classify_symbol.
12335 (aarch64_const_vec_all_in_range_p): New function.
12336 (aarch64_print_vector_float_operand): Likewise.
12337 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
12338 "vN" for FP registers with SVE modes. Handle (const ...) vectors
12339 and the FP immediates 1.0 and 0.5.
12340 (aarch64_print_address_internal): Handle SVE addresses.
12341 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
12342 (aarch64_regno_regclass): Handle predicate registers.
12343 (aarch64_secondary_reload): Handle big-endian reloads of SVE
12344 data modes.
12345 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
12346 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
12347 (aarch64_convert_sve_vector_bits): New function.
12348 (aarch64_override_options): Use it to handle -msve-vector-bits=.
12349 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
12350 rather than an rtx.
12351 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
12352 Handle SVE vector and predicate modes. Accept VL-based constants
12353 that need only one temporary register, and VL offsets that require
12354 no temporary registers.
12355 (aarch64_conditional_register_usage): Mark the predicate registers
12356 as fixed if SVE isn't available.
12357 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
12358 Return true for SVE vector and predicate modes.
12359 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
12360 rather than an unsigned int. Handle SVE modes.
12361 (aarch64_preferred_simd_mode): Update call accordingly. Handle
12362 SVE modes.
12363 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
12364 if SVE is enabled.
12365 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
12366 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
12367 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
12368 (aarch64_sve_float_mul_immediate_p): New functions.
12369 (aarch64_sve_valid_immediate): New function.
12370 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
12371 Explicitly reject structure modes. Check for INDEX constants.
12372 Handle PTRUE and PFALSE constants.
12373 (aarch64_check_zero_based_sve_index_immediate): New function.
12374 (aarch64_simd_imm_zero_p): Delete.
12375 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
12376 vector modes. Accept constants in the range of CNT[BHWD].
12377 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
12378 ask for an Advanced SIMD mode.
12379 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
12380 (aarch64_simd_vector_alignment): Handle SVE predicates.
12381 (aarch64_vectorize_preferred_vector_alignment): New function.
12382 (aarch64_simd_vector_alignment_reachable): Use it instead of
12383 the vector size.
12384 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
12385 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
12386 functions.
12387 (MAX_VECT_LEN): Delete.
12388 (expand_vec_perm_d): Add a vec_flags field.
12389 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
12390 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
12391 (aarch64_evpc_ext): Don't apply a big-endian lane correction
12392 for SVE modes.
12393 (aarch64_evpc_rev): Rename to...
12394 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
12395 (aarch64_evpc_rev_global): New function.
12396 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
12397 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
12398 MAX_VECT_LEN.
12399 (aarch64_evpc_sve_tbl): New function.
12400 (aarch64_expand_vec_perm_const_1): Update after rename of
12401 aarch64_evpc_rev. Handle SVE permutes too, trying
12402 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
12403 than aarch64_evpc_tbl.
12404 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
12405 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
12406 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
12407 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
12408 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
12409 (aarch64_expand_sve_vcond): New functions.
12410 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
12411 of aarch64_vector_mode_p.
12412 (aarch64_dwarf_poly_indeterminate_value): New function.
12413 (aarch64_compute_pressure_classes): Likewise.
12414 (aarch64_can_change_mode_class): Likewise.
12415 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
12416 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
12417 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
12418 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
12419 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
12420 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
12421 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
12422 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
12423 constraints.
12424 (Dn, Dl, Dr): Accept const as well as const_vector.
12425 (Dz): Likewise. Compare against CONST0_RTX.
12426 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
12427 of "vector" where appropriate.
12428 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
12429 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
12430 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
12431 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
12432 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
12433 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
12434 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
12435 (v_int_equiv): Extend to SVE modes.
12436 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
12437 mode attributes.
12438 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
12439 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
12440 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
12441 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
12442 (SVE_COND_FP_CMP): New int iterators.
12443 (perm_hilo): Handle the new unpack unspecs.
12444 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
12445 attributes.
12446 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
12447 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
12448 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
12449 (aarch64_equality_operator, aarch64_constant_vector_operand)
12450 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
12451 (aarch64_sve_nonimmediate_operand): Likewise.
12452 (aarch64_sve_general_operand): Likewise.
12453 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
12454 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
12455 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
12456 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
12457 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
12458 (aarch64_sve_float_arith_immediate): Likewise.
12459 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
12460 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
12461 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
12462 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
12463 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
12464 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
12465 (aarch64_sve_float_arith_operand): Likewise.
12466 (aarch64_sve_float_arith_with_sub_operand): Likewise.
12467 (aarch64_sve_float_mul_operand): Likewise.
12468 (aarch64_sve_vec_perm_operand): Likewise.
12469 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
12470 (aarch64_mov_operand): Accept const_poly_int and const_vector.
12471 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
12472 as well as const_vector.
12473 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
12474 in file. Use CONST0_RTX and CONSTM1_RTX.
12475 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
12476 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
12477 Use aarch64_simd_imm_zero.
12478 * config/aarch64/aarch64-sve.md: New file.
12479 * config/aarch64/aarch64.md: Include it.
12480 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
12481 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
12482 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
12483 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
12484 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
12485 (sve): New attribute.
12486 (enabled): Disable instructions with the sve attribute unless
12487 TARGET_SVE.
12488 (movqi, movhi): Pass CONST_POLY_INT operaneds through
12489 aarch64_expand_mov_immediate.
12490 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
12491 CNT[BHSD] immediates.
12492 (movti): Split CONST_POLY_INT moves into two halves.
12493 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
12494 Split additions that need a temporary here if the destination
12495 is the stack pointer.
12496 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
12497 (*add<mode>3_poly_1): New instruction.
12498 (set_clobber_cc): New expander.
12499
12500 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12501
12502 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
12503 parameter and use it instead of GET_MODE_SIZE (innermode). Use
12504 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
12505 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
12506 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
12507 Change innermode from fixed_mode_size to machine_mode.
12508 (simplify_subreg): Update call accordingly. Handle a constant-sized
12509 subreg of a variable-length CONST_VECTOR.
12510
12511 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
12512 Alan Hayward <alan.hayward@arm.com>
12513 David Sherwood <david.sherwood@arm.com>
12514
12515 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
12516 (add_offset_to_base): New function, split out from...
12517 (create_mem_ref): ...here. When handling a scale other than 1,
12518 check first whether the address is valid without the offset.
12519 Add it into the base if so, leaving the index and scale as-is.
12520
12521 2018-01-12 Jakub Jelinek <jakub@redhat.com>
12522
12523 PR c++/83778
12524 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
12525 fold_for_warn before checking if arg2 is INTEGER_CST.
12526
12527 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
12528
12529 * config/rs6000/predicates.md (load_multiple_operation): Delete.
12530 (store_multiple_operation): Delete.
12531 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
12532 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
12533 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
12534 guarded by TARGET_STRING.
12535 (rs6000_output_load_multiple): Delete.
12536 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
12537 OPTION_MASK_STRING / TARGET_STRING handling.
12538 (print_operand) <'N', 'O'>: Add comment that these are unused now.
12539 (const rs6000_opt_masks) <"string">: Change mask to 0.
12540 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
12541 (MASK_STRING): Delete.
12542 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
12543 parts. Simplify.
12544 (load_multiple): Delete.
12545 (*ldmsi8): Delete.
12546 (*ldmsi7): Delete.
12547 (*ldmsi6): Delete.
12548 (*ldmsi5): Delete.
12549 (*ldmsi4): Delete.
12550 (*ldmsi3): Delete.
12551 (store_multiple): Delete.
12552 (*stmsi8): Delete.
12553 (*stmsi7): Delete.
12554 (*stmsi6): Delete.
12555 (*stmsi5): Delete.
12556 (*stmsi4): Delete.
12557 (*stmsi3): Delete.
12558 (movmemsi_8reg): Delete.
12559 (corresponding unnamed define_insn): Delete.
12560 (movmemsi_6reg): Delete.
12561 (corresponding unnamed define_insn): Delete.
12562 (movmemsi_4reg): Delete.
12563 (corresponding unnamed define_insn): Delete.
12564 (movmemsi_2reg): Delete.
12565 (corresponding unnamed define_insn): Delete.
12566 (movmemsi_1reg): Delete.
12567 (corresponding unnamed define_insn): Delete.
12568 * config/rs6000/rs6000.opt (mno-string): New.
12569 (mstring): Replace by deprecation warning stub.
12570 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
12571
12572 2018-01-12 Jakub Jelinek <jakub@redhat.com>
12573
12574 * regrename.c (regrename_do_replace): If replacing the same
12575 reg multiple times, try to reuse last created gen_raw_REG.
12576
12577 PR debug/81155
12578 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
12579 main to workaround a bug in GDB.
12580
12581 2018-01-12 Tom de Vries <tom@codesourcery.com>
12582
12583 PR target/83737
12584 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
12585
12586 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
12587
12588 PR rtl-optimization/80481
12589 * ira-color.c (get_cap_member): New function.
12590 (allocnos_conflict_by_live_ranges_p): Use it.
12591 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
12592 (setup_slot_coalesced_allocno_live_ranges): Ditto.
12593
12594 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
12595
12596 PR target/83628
12597 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
12598 (*saddl_se_1): Ditto.
12599 (*ssubsi_1): Ditto.
12600 (*ssubl_se_1): Ditto.
12601
12602 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
12603
12604 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
12605 rather than wi::to_widest for DR_INITs.
12606 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
12607 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
12608 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
12609 INTEGER_CSTs.
12610 (vect_analyze_group_access_1): Note that here.
12611
12612 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
12613
12614 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
12615 polynomial type sizes.
12616
12617 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
12618
12619 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
12620 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
12621 (gimple_add_tmp_var): Likewise.
12622
12623 2018-01-12 Martin Liska <mliska@suse.cz>
12624
12625 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
12626 (gimple_alloc_sizes): Likewise.
12627 (dump_gimple_statistics): Use PRIu64 in printf format.
12628 * gimple.h: Change uint64_t to int.
12629
12630 2018-01-12 Martin Liska <mliska@suse.cz>
12631
12632 * tree-core.h: Use uint64_t instead of int.
12633 * tree.c (tree_node_counts): Likewise.
12634 (tree_node_sizes): Likewise.
12635 (dump_tree_statistics): Use PRIu64 in printf format.
12636
12637 2018-01-12 Martin Liska <mliska@suse.cz>
12638
12639 * Makefile.in: As qsort_chk is implemented in vec.c, add
12640 vec.o to linkage of gencfn-macros.
12641 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
12642 passing the info to record_node_allocation_statistics.
12643 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
12644 and pass the info.
12645 * ggc-common.c (struct ggc_usage): Add operator== and use
12646 it in operator< and compare function.
12647 * mem-stats.h (struct mem_usage): Likewise.
12648 * vec.c (struct vec_usage): Remove operator< and compare
12649 function. Can be simply inherited.
12650
12651 2018-01-12 Martin Jambor <mjambor@suse.cz>
12652
12653 PR target/81616
12654 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
12655 * tree-ssa-math-opts.c: Include domwalk.h.
12656 (convert_mult_to_fma_1): New function.
12657 (fma_transformation_info): New type.
12658 (fma_deferring_state): Likewise.
12659 (cancel_fma_deferring): New function.
12660 (result_of_phi): Likewise.
12661 (last_fma_candidate_feeds_initial_phi): Likewise.
12662 (convert_mult_to_fma): Added deferring logic, split actual
12663 transformation to convert_mult_to_fma_1.
12664 (math_opts_dom_walker): New type.
12665 (math_opts_dom_walker::after_dom_children): New method, body moved
12666 here from pass_optimize_widening_mul::execute, added deferring logic
12667 bits.
12668 (pass_optimize_widening_mul::execute): Moved most of code to
12669 math_opts_dom_walker::after_dom_children.
12670 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
12671 * config/i386/i386.c (ix86_option_override_internal): Added
12672 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
12673
12674 2018-01-12 Richard Biener <rguenther@suse.de>
12675
12676 PR debug/83157
12677 * dwarf2out.c (gen_variable_die): Do not reset old_die for
12678 inline instance vars.
12679
12680 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
12681
12682 PR target/81819
12683 * config/rx/rx.c (rx_is_restricted_memory_address):
12684 Handle SUBREG case.
12685
12686 2018-01-12 Richard Biener <rguenther@suse.de>
12687
12688 PR tree-optimization/80846
12689 * target.def (split_reduction): New target hook.
12690 * targhooks.c (default_split_reduction): New function.
12691 * targhooks.h (default_split_reduction): Declare.
12692 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
12693 target requests first reduce vectors by combining low and high
12694 parts.
12695 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
12696 (get_vectype_for_scalar_type_and_size): Export.
12697 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
12698 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
12699 * doc/tm.texi: Regenerate.
12700 * config/i386/i386.c (ix86_split_reduction): Implement
12701 TARGET_VECTORIZE_SPLIT_REDUCTION.
12702
12703 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
12704
12705 PR target/83368
12706 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
12707 in PIC mode except for TARGET_VXWORKS_RTP.
12708 * config/sparc/sparc.c: Include cfgrtl.h.
12709 (TARGET_INIT_PIC_REG): Define.
12710 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
12711 (sparc_pic_register_p): New predicate.
12712 (sparc_legitimate_address_p): Use it.
12713 (sparc_legitimize_pic_address): Likewise.
12714 (sparc_delegitimize_address): Likewise.
12715 (sparc_mode_dependent_address_p): Likewise.
12716 (gen_load_pcrel_sym): Remove 4th parameter.
12717 (load_got_register): Adjust call to above. Remove obsolete stuff.
12718 (sparc_expand_prologue): Do not call load_got_register here.
12719 (sparc_flat_expand_prologue): Likewise.
12720 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
12721 (sparc_use_pseudo_pic_reg): New function.
12722 (sparc_init_pic_reg): Likewise.
12723 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
12724 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
12725
12726 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
12727
12728 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
12729 Add item for branch_cost.
12730
12731 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
12732
12733 PR rtl-optimization/83565
12734 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
12735 not extend the result to a larger mode for rotate operations.
12736 (num_sign_bit_copies1): Likewise.
12737
12738 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12739
12740 PR target/40411
12741 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
12742 -symbolic.
12743 Use values-Xc.o for -pedantic.
12744 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
12745
12746 2018-01-12 Martin Liska <mliska@suse.cz>
12747
12748 PR ipa/83054
12749 * ipa-devirt.c (final_warning_record::grow_type_warnings):
12750 New function.
12751 (possible_polymorphic_call_targets): Use it.
12752 (ipa_devirt): Likewise.
12753
12754 2018-01-12 Martin Liska <mliska@suse.cz>
12755
12756 * profile-count.h (enum profile_quality): Use 0 as invalid
12757 enum value of profile_quality.
12758
12759 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
12760
12761 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
12762 -mext-string options.
12763
12764 2018-01-12 Richard Biener <rguenther@suse.de>
12765
12766 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
12767 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
12768 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
12769 Likewise.
12770 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
12771
12772 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
12773
12774 * configure.ac (--with-long-double-format): Add support for the
12775 configuration option to change the default long double format on
12776 PowerPC systems.
12777 * config.gcc (powerpc*-linux*-*): Likewise.
12778 * configure: Regenerate.
12779 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
12780 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
12781 used without modification.
12782
12783 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
12784
12785 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
12786 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
12787 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
12788 MISC_BUILTIN_SPEC_BARRIER.
12789 (rs6000_init_builtins): Likewise.
12790 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
12791 enum value.
12792 (speculation_barrier): New define_insn.
12793 * doc/extend.texi: Document __builtin_speculation_barrier.
12794
12795 2018-01-11 Jakub Jelinek <jakub@redhat.com>
12796
12797 PR target/83203
12798 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
12799 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
12800 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
12801 iterators.
12802 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
12803 integral modes instead of "ss" and "sd".
12804 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
12805 vectors with 32-bit and 64-bit elements.
12806 (vecdupssescalarmodesuffix): New mode attribute.
12807 (vec_dup<mode>): Use it.
12808
12809 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
12810
12811 PR target/83330
12812 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
12813 frame if argument is passed on stack.
12814
12815 2018-01-11 Jakub Jelinek <jakub@redhat.com>
12816
12817 PR target/82682
12818 * ree.c (combine_reaching_defs): Optimize also
12819 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
12820 reg2=any_extend(exp); reg1=reg2;, formatting fix.
12821
12822 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
12823
12824 PR middle-end/83189
12825 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
12826
12827 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
12828
12829 PR middle-end/83718
12830 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
12831 after they are computed.
12832
12833 2018-01-11 Bin Cheng <bin.cheng@arm.com>
12834
12835 PR tree-optimization/83695
12836 * gimple-loop-linterchange.cc
12837 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
12838 reset cached scev information after interchange.
12839 (pass_linterchange::execute): Remove call to scev_reset_htab.
12840
12841 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12842
12843 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
12844 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
12845 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
12846 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
12847 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
12848 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
12849 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
12850 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
12851 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
12852 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
12853 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
12854 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
12855 (V_lane_reg): Likewise.
12856 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
12857 New define_expand.
12858 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
12859 (vfmal_lane_low<mode>_intrinsic,
12860 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
12861 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
12862 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
12863 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
12864 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
12865 vfmsl_lane_high<mode>_intrinsic): New define_insns.
12866
12867 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12868
12869 * config/arm/arm-cpus.in (fp16fml): New feature.
12870 (ALL_SIMD): Add fp16fml.
12871 (armv8.2-a): Add fp16fml as an option.
12872 (armv8.3-a): Likewise.
12873 (armv8.4-a): Add fp16fml as part of fp16.
12874 * config/arm/arm.h (TARGET_FP16FML): Define.
12875 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
12876 when appropriate.
12877 * config/arm/arm-modes.def (V2HF): Define.
12878 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
12879 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
12880 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
12881 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
12882 vfmsl_low, vfmsl_high): New set of builtins.
12883 * config/arm/iterators.md (PLUSMINUS): New code iterator.
12884 (vfml_op): New code attribute.
12885 (VFMLHALVES): New int iterator.
12886 (VFML, VFMLSEL): New mode attributes.
12887 (V_reg): Define mapping for V2HF.
12888 (V_hi, V_lo): New mode attributes.
12889 (VF_constraint): Likewise.
12890 (vfml_half, vfml_half_selector): New int attributes.
12891 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
12892 define_expand.
12893 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
12894 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
12895 New define_insn.
12896 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
12897 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
12898 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
12899 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
12900 documentation.
12901 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
12902 Document new effective target and option set.
12903
12904 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12905
12906 * config/arm/arm-cpus.in (armv8_4): New feature.
12907 (ARMv8_4a): New fgroup.
12908 (armv8.4-a): New arch.
12909 * config/arm/arm-tables.opt: Regenerate.
12910 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
12911 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
12912 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
12913 Add matching rules for -march=armv8.4-a and extensions.
12914 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
12915
12916 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
12917
12918 PR target/81821
12919 * config/rx/rx.md (BW): New mode attribute.
12920 (sync_lock_test_and_setsi): Add mode suffix to insn output.
12921
12922 2018-01-11 Richard Biener <rguenther@suse.de>
12923
12924 PR tree-optimization/83435
12925 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
12926 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
12927 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
12928
12929 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
12930 Alan Hayward <alan.hayward@arm.com>
12931 David Sherwood <david.sherwood@arm.com>
12932
12933 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
12934 field.
12935 (aarch64_classify_address): Initialize it. Track polynomial offsets.
12936 (aarch64_print_address_internal): Use it to check for a zero offset.
12937
12938 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
12939 Alan Hayward <alan.hayward@arm.com>
12940 David Sherwood <david.sherwood@arm.com>
12941
12942 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
12943 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
12944 Return a poly_int64 rather than a HOST_WIDE_INT.
12945 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
12946 rather than a HOST_WIDE_INT.
12947 * config/aarch64/aarch64.h (aarch64_frame): Protect with
12948 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
12949 hard_fp_offset, frame_size, initial_adjust, callee_offset and
12950 final_offset from HOST_WIDE_INT to poly_int64.
12951 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
12952 to_constant when getting the number of units in an Advanced SIMD
12953 mode.
12954 (aarch64_builtin_vectorized_function): Check for a constant number
12955 of units.
12956 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
12957 GET_MODE_SIZE.
12958 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
12959 attribute instead of GET_MODE_NUNITS.
12960 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
12961 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
12962 GET_MODE_SIZE for fixed-size registers.
12963 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
12964 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
12965 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
12966 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
12967 (aarch64_print_operand, aarch64_print_address_internal)
12968 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
12969 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
12970 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
12971 Handle polynomial GET_MODE_SIZE.
12972 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
12973 wider than SImode without modification.
12974 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
12975 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
12976 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
12977 passing and returning SVE modes.
12978 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
12979 rather than GEN_INT.
12980 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
12981 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
12982 (aarch64_allocate_and_probe_stack_space): Likewise.
12983 (aarch64_layout_frame): Cope with polynomial offsets.
12984 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
12985 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
12986 polynomial offsets.
12987 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
12988 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
12989 poly_int64 rather than a HOST_WIDE_INT.
12990 (aarch64_get_separate_components, aarch64_process_components)
12991 (aarch64_expand_prologue, aarch64_expand_epilogue)
12992 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
12993 (aarch64_anchor_offset): New function, split out from...
12994 (aarch64_legitimize_address): ...here.
12995 (aarch64_builtin_vectorization_cost): Handle polynomial
12996 TYPE_VECTOR_SUBPARTS.
12997 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
12998 GET_MODE_NUNITS.
12999 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
13000 number of elements from the PARALLEL rather than the mode.
13001 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
13002 rather than GET_MODE_BITSIZE.
13003 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
13004 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
13005 (aarch64_expand_vec_perm_const_1): Handle polynomial
13006 d->perm.length () and d->perm elements.
13007 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
13008 Apply to_constant to d->perm elements.
13009 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
13010 polynomial CONST_VECTOR_NUNITS.
13011 (aarch64_move_pointer): Take amount as a poly_int64 rather
13012 than an int.
13013 (aarch64_progress_pointer): Avoid temporary variable.
13014 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
13015 the mode attribute instead of GET_MODE.
13016
13017 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13018 Alan Hayward <alan.hayward@arm.com>
13019 David Sherwood <david.sherwood@arm.com>
13020
13021 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
13022 x exists before using it.
13023 (aarch64_add_constant_internal): Rename to...
13024 (aarch64_add_offset_1): ...this. Replace regnum with separate
13025 src and dest rtxes. Handle the case in which they're different,
13026 including when the offset is zero. Replace scratchreg with an rtx.
13027 Use 2 additions if there is no spare register into which we can
13028 move a 16-bit constant.
13029 (aarch64_add_constant): Delete.
13030 (aarch64_add_offset): Replace reg with separate src and dest
13031 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
13032 Use aarch64_add_offset_1.
13033 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
13034 an rtx rather than an int. Take the delta as a poly_int64
13035 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
13036 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
13037 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
13038 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
13039 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
13040 and aarch64_add_sp.
13041 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
13042 aarch64_add_constant.
13043
13044 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13045
13046 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
13047 Use scalar_float_mode.
13048
13049 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13050
13051 * config/aarch64/aarch64-simd.md
13052 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
13053 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
13054 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
13055 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
13056 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
13057 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
13058 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
13059 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
13060 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
13061 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
13062
13063 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
13064
13065 PR target/83514
13066 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
13067 targ_options->x_arm_arch_string is non NULL.
13068
13069 2018-01-11 Tamar Christina <tamar.christina@arm.com>
13070
13071 * config/aarch64/aarch64.h
13072 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
13073
13074 2018-01-11 Sudakshina Das <sudi.das@arm.com>
13075
13076 PR target/82096
13077 * expmed.c (emit_store_flag_force): Swap if const op0
13078 and change VOIDmode to mode of op0.
13079
13080 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
13081
13082 PR rtl-optimization/83761
13083 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
13084 than bytes to mode_for_size.
13085
13086 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
13087
13088 PR middle-end/83189
13089 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
13090 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
13091 profile.
13092
13093 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
13094
13095 PR middle-end/83575
13096 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
13097 when in layout mode.
13098 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
13099 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
13100 partition fixup.
13101
13102 2018-01-10 Michael Collison <michael.collison@arm.com>
13103
13104 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
13105 * config/aarch64/aarch64-option-extension.def: Add
13106 AARCH64_OPT_EXTENSION of 'fp16fml'.
13107 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
13108 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
13109 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
13110 * config/aarch64/constraints.md (Ui7): New constraint.
13111 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
13112 (VFMLA_SEL_W): Ditto.
13113 (f16quad): Ditto.
13114 (f16mac1): Ditto.
13115 (VFMLA16_LOW): New int iterator.
13116 (VFMLA16_HIGH): Ditto.
13117 (UNSPEC_FMLAL): New unspec.
13118 (UNSPEC_FMLSL): Ditto.
13119 (UNSPEC_FMLAL2): Ditto.
13120 (UNSPEC_FMLSL2): Ditto.
13121 (f16mac): New code attribute.
13122 * config/aarch64/aarch64-simd-builtins.def
13123 (aarch64_fmlal_lowv2sf): Ditto.
13124 (aarch64_fmlsl_lowv2sf): Ditto.
13125 (aarch64_fmlalq_lowv4sf): Ditto.
13126 (aarch64_fmlslq_lowv4sf): Ditto.
13127 (aarch64_fmlal_highv2sf): Ditto.
13128 (aarch64_fmlsl_highv2sf): Ditto.
13129 (aarch64_fmlalq_highv4sf): Ditto.
13130 (aarch64_fmlslq_highv4sf): Ditto.
13131 (aarch64_fmlal_lane_lowv2sf): Ditto.
13132 (aarch64_fmlsl_lane_lowv2sf): Ditto.
13133 (aarch64_fmlal_laneq_lowv2sf): Ditto.
13134 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
13135 (aarch64_fmlalq_lane_lowv4sf): Ditto.
13136 (aarch64_fmlsl_lane_lowv4sf): Ditto.
13137 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
13138 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
13139 (aarch64_fmlal_lane_highv2sf): Ditto.
13140 (aarch64_fmlsl_lane_highv2sf): Ditto.
13141 (aarch64_fmlal_laneq_highv2sf): Ditto.
13142 (aarch64_fmlsl_laneq_highv2sf): Ditto.
13143 (aarch64_fmlalq_lane_highv4sf): Ditto.
13144 (aarch64_fmlsl_lane_highv4sf): Ditto.
13145 (aarch64_fmlalq_laneq_highv4sf): Ditto.
13146 (aarch64_fmlsl_laneq_highv4sf): Ditto.
13147 * config/aarch64/aarch64-simd.md:
13148 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
13149 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
13150 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
13151 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
13152 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
13153 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
13154 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
13155 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
13156 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
13157 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
13158 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
13159 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
13160 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
13161 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
13162 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
13163 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
13164 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
13165 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
13166 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
13167 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
13168 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
13169 (vfmlsl_low_u32): Ditto.
13170 (vfmlalq_low_u32): Ditto.
13171 (vfmlslq_low_u32): Ditto.
13172 (vfmlal_high_u32): Ditto.
13173 (vfmlsl_high_u32): Ditto.
13174 (vfmlalq_high_u32): Ditto.
13175 (vfmlslq_high_u32): Ditto.
13176 (vfmlal_lane_low_u32): Ditto.
13177 (vfmlsl_lane_low_u32): Ditto.
13178 (vfmlal_laneq_low_u32): Ditto.
13179 (vfmlsl_laneq_low_u32): Ditto.
13180 (vfmlalq_lane_low_u32): Ditto.
13181 (vfmlslq_lane_low_u32): Ditto.
13182 (vfmlalq_laneq_low_u32): Ditto.
13183 (vfmlslq_laneq_low_u32): Ditto.
13184 (vfmlal_lane_high_u32): Ditto.
13185 (vfmlsl_lane_high_u32): Ditto.
13186 (vfmlal_laneq_high_u32): Ditto.
13187 (vfmlsl_laneq_high_u32): Ditto.
13188 (vfmlalq_lane_high_u32): Ditto.
13189 (vfmlslq_lane_high_u32): Ditto.
13190 (vfmlalq_laneq_high_u32): Ditto.
13191 (vfmlslq_laneq_high_u32): Ditto.
13192 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
13193 (AARCH64_FL_FOR_ARCH8_4): New.
13194 (AARCH64_ISA_F16FML): New ISA flag.
13195 (TARGET_F16FML): New feature flag for fp16fml.
13196 (doc/invoke.texi): Document new fp16fml option.
13197
13198 2018-01-10 Michael Collison <michael.collison@arm.com>
13199
13200 * config/aarch64/aarch64-builtins.c:
13201 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
13202 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
13203 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
13204 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
13205 (AARCH64_ISA_SHA3): New ISA flag.
13206 (TARGET_SHA3): New feature flag for sha3.
13207 * config/aarch64/iterators.md (sha512_op): New int attribute.
13208 (CRYPTO_SHA512): New int iterator.
13209 (UNSPEC_SHA512H): New unspec.
13210 (UNSPEC_SHA512H2): Ditto.
13211 (UNSPEC_SHA512SU0): Ditto.
13212 (UNSPEC_SHA512SU1): Ditto.
13213 * config/aarch64/aarch64-simd-builtins.def
13214 (aarch64_crypto_sha512hqv2di): New builtin.
13215 (aarch64_crypto_sha512h2qv2di): Ditto.
13216 (aarch64_crypto_sha512su0qv2di): Ditto.
13217 (aarch64_crypto_sha512su1qv2di): Ditto.
13218 (aarch64_eor3qv8hi): Ditto.
13219 (aarch64_rax1qv2di): Ditto.
13220 (aarch64_xarqv2di): Ditto.
13221 (aarch64_bcaxqv8hi): Ditto.
13222 * config/aarch64/aarch64-simd.md:
13223 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
13224 (aarch64_crypto_sha512su0qv2di): Ditto.
13225 (aarch64_crypto_sha512su1qv2di): Ditto.
13226 (aarch64_eor3qv8hi): Ditto.
13227 (aarch64_rax1qv2di): Ditto.
13228 (aarch64_xarqv2di): Ditto.
13229 (aarch64_bcaxqv8hi): Ditto.
13230 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
13231 (vsha512h2q_u64): Ditto.
13232 (vsha512su0q_u64): Ditto.
13233 (vsha512su1q_u64): Ditto.
13234 (veor3q_u16): Ditto.
13235 (vrax1q_u64): Ditto.
13236 (vxarq_u64): Ditto.
13237 (vbcaxq_u16): Ditto.
13238 * config/arm/types.md (crypto_sha512): New type attribute.
13239 (crypto_sha3): Ditto.
13240 (doc/invoke.texi): Document new sha3 option.
13241
13242 2018-01-10 Michael Collison <michael.collison@arm.com>
13243
13244 * config/aarch64/aarch64-builtins.c:
13245 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
13246 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
13247 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
13248 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
13249 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
13250 (AARCH64_ISA_SM4): New ISA flag.
13251 (TARGET_SM4): New feature flag for sm4.
13252 * config/aarch64/aarch64-simd-builtins.def
13253 (aarch64_sm3ss1qv4si): Ditto.
13254 (aarch64_sm3tt1aq4si): Ditto.
13255 (aarch64_sm3tt1bq4si): Ditto.
13256 (aarch64_sm3tt2aq4si): Ditto.
13257 (aarch64_sm3tt2bq4si): Ditto.
13258 (aarch64_sm3partw1qv4si): Ditto.
13259 (aarch64_sm3partw2qv4si): Ditto.
13260 (aarch64_sm4eqv4si): Ditto.
13261 (aarch64_sm4ekeyqv4si): Ditto.
13262 * config/aarch64/aarch64-simd.md:
13263 (aarch64_sm3ss1qv4si): Ditto.
13264 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
13265 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
13266 (aarch64_sm4eqv4si): Ditto.
13267 (aarch64_sm4ekeyqv4si): Ditto.
13268 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
13269 (sm3part_op): Ditto.
13270 (CRYPTO_SM3TT): Ditto.
13271 (CRYPTO_SM3PART): Ditto.
13272 (UNSPEC_SM3SS1): New unspec.
13273 (UNSPEC_SM3TT1A): Ditto.
13274 (UNSPEC_SM3TT1B): Ditto.
13275 (UNSPEC_SM3TT2A): Ditto.
13276 (UNSPEC_SM3TT2B): Ditto.
13277 (UNSPEC_SM3PARTW1): Ditto.
13278 (UNSPEC_SM3PARTW2): Ditto.
13279 (UNSPEC_SM4E): Ditto.
13280 (UNSPEC_SM4EKEY): Ditto.
13281 * config/aarch64/constraints.md (Ui2): New constraint.
13282 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
13283 * config/arm/types.md (crypto_sm3): New type attribute.
13284 (crypto_sm4): Ditto.
13285 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
13286 (vsm3tt1aq_u32): Ditto.
13287 (vsm3tt1bq_u32): Ditto.
13288 (vsm3tt2aq_u32): Ditto.
13289 (vsm3tt2bq_u32): Ditto.
13290 (vsm3partw1q_u32): Ditto.
13291 (vsm3partw2q_u32): Ditto.
13292 (vsm4eq_u32): Ditto.
13293 (vsm4ekeyq_u32): Ditto.
13294 (doc/invoke.texi): Document new sm4 option.
13295
13296 2018-01-10 Michael Collison <michael.collison@arm.com>
13297
13298 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
13299 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
13300 (AARCH64_FL_FOR_ARCH8_4): New.
13301 (AARCH64_FL_V8_4): New flag.
13302 (doc/invoke.texi): Document new armv8.4-a option.
13303
13304 2018-01-10 Michael Collison <michael.collison@arm.com>
13305
13306 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
13307 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
13308 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
13309 * config/aarch64/aarch64-option-extension.def: Add
13310 AARCH64_OPT_EXTENSION of 'sha2'.
13311 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
13312 (crypto): Disable sha2 and aes if crypto disabled.
13313 (crypto): Enable aes and sha2 if enabled.
13314 (simd): Disable sha2 and aes if simd disabled.
13315 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
13316 New flags.
13317 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
13318 (TARGET_SHA2): New feature flag for sha2.
13319 (TARGET_AES): New feature flag for aes.
13320 * config/aarch64/aarch64-simd.md:
13321 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
13322 conditional on TARGET_AES.
13323 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
13324 (aarch64_crypto_sha1hsi): Make pattern conditional
13325 on TARGET_SHA2.
13326 (aarch64_crypto_sha1hv4si): Ditto.
13327 (aarch64_be_crypto_sha1hv4si): Ditto.
13328 (aarch64_crypto_sha1su1v4si): Ditto.
13329 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
13330 (aarch64_crypto_sha1su0v4si): Ditto.
13331 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
13332 (aarch64_crypto_sha256su0v4si): Ditto.
13333 (aarch64_crypto_sha256su1v4si): Ditto.
13334 (doc/invoke.texi): Document new aes and sha2 options.
13335
13336 2018-01-10 Martin Sebor <msebor@redhat.com>
13337
13338 PR tree-optimization/83781
13339 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
13340 as string arrays.
13341
13342 2018-01-11 Martin Sebor <msebor@gmail.com>
13343 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
13344
13345 PR tree-optimization/83501
13346 PR tree-optimization/81703
13347
13348 * tree-ssa-strlen.c (get_string_cst): Rename...
13349 (get_string_len): ...to this. Handle global constants.
13350 (handle_char_store): Adjust.
13351
13352 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
13353 Jim Wilson <jimw@sifive.com>
13354
13355 * config/riscv/riscv-protos.h (riscv_output_return): New.
13356 * config/riscv/riscv.c (struct machine_function): New naked_p field.
13357 (riscv_attribute_table, riscv_output_return),
13358 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
13359 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
13360 (riscv_compute_frame_info): Only compute frame->mask if not a naked
13361 function.
13362 (riscv_expand_prologue): Add early return for naked function.
13363 (riscv_expand_epilogue): Likewise.
13364 (riscv_function_ok_for_sibcall): Return false for naked function.
13365 (riscv_set_current_function): New.
13366 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
13367 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
13368 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
13369 * doc/extend.texi (RISC-V Function Attributes): New.
13370
13371 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
13372
13373 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
13374 check for 128-bit long double before checking TCmode.
13375 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
13376 128-bit long doubles before checking TFmode or TCmode.
13377 (FLOAT128_IBM_P): Likewise.
13378
13379 2018-01-10 Martin Sebor <msebor@redhat.com>
13380
13381 PR tree-optimization/83671
13382 * builtins.c (c_strlen): Unconditionally return zero for the empty
13383 string.
13384 Use -Warray-bounds for warnings.
13385 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
13386 for non-constant array indices with COMPONENT_REF, arrays of
13387 arrays, and pointers to arrays.
13388 (gimple_fold_builtin_strlen): Determine and set length range for
13389 non-constant character arrays.
13390
13391 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
13392
13393 PR middle-end/81897
13394 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
13395 empty blocks.
13396
13397 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
13398
13399 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
13400
13401 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
13402
13403 PR target/83399
13404 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
13405 VECTOR_MEM_ALTIVEC_OR_VSX_P.
13406 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
13407 indexed_or_indirect_operand predicate.
13408 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
13409 (*vsx_le_perm_load_v8hi): Likewise.
13410 (*vsx_le_perm_load_v16qi): Likewise.
13411 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
13412 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
13413 (*vsx_le_perm_store_v8hi): Likewise.
13414 (*vsx_le_perm_store_v16qi): Likewise.
13415 (eight unnamed splitters): Likewise.
13416
13417 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
13418
13419 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
13420 * config/rs6000/emmintrin.h: Likewise.
13421 * config/rs6000/mmintrin.h: Likewise.
13422 * config/rs6000/xmmintrin.h: Likewise.
13423
13424 2018-01-10 David Malcolm <dmalcolm@redhat.com>
13425
13426 PR c++/43486
13427 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
13428 "public_flag".
13429 * tree.c (tree_nop_conversion): Return true for location wrapper
13430 nodes.
13431 (maybe_wrap_with_location): New function.
13432 (selftest::check_strip_nops): New function.
13433 (selftest::test_location_wrappers): New function.
13434 (selftest::tree_c_tests): Call it.
13435 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
13436 (maybe_wrap_with_location): New decl.
13437 (EXPR_LOCATION_WRAPPER_P): New macro.
13438 (location_wrapper_p): New inline function.
13439 (tree_strip_any_location_wrapper): New inline function.
13440
13441 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
13442
13443 PR target/83735
13444 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
13445 stack_realign_offset for the largest alignment of stack slot
13446 actually used.
13447 (ix86_find_max_used_stack_alignment): New function.
13448 (ix86_finalize_stack_frame_flags): Use it. Set
13449 max_used_stack_alignment if we don't realign stack.
13450 * config/i386/i386.h (machine_function): Add
13451 max_used_stack_alignment.
13452
13453 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
13454
13455 * config/arm/arm.opt (-mbranch-cost): New option.
13456 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
13457 account.
13458
13459 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
13460
13461 PR target/83629
13462 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
13463 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
13464
13465 2018-01-10 Richard Biener <rguenther@suse.de>
13466
13467 PR debug/83765
13468 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
13469 early out so it also covers the case where we have a non-NULL
13470 origin.
13471
13472 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
13473
13474 PR tree-optimization/83753
13475 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
13476 for non-strided grouped accesses if the number of elements is 1.
13477
13478 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
13479
13480 PR target/81616
13481 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
13482 * i386.h (TARGET_USE_GATHER): Define.
13483 * x86-tune.def (X86_TUNE_USE_GATHER): New.
13484
13485 2018-01-10 Martin Liska <mliska@suse.cz>
13486
13487 PR bootstrap/82831
13488 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
13489 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
13490 partitioning.
13491 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
13492 CLEANUP_NO_PARTITIONING is not set.
13493
13494 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
13495
13496 * doc/rtl.texi: Remove documentation of (const ...) wrappers
13497 for vectors, as a partial revert of r254296.
13498 * rtl.h (const_vec_p): Delete.
13499 (const_vec_duplicate_p): Don't test for vector CONSTs.
13500 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
13501 * expmed.c (make_tree): Likewise.
13502
13503 Revert:
13504 * common.md (E, F): Use CONSTANT_P instead of checking for
13505 CONST_VECTOR.
13506 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
13507 checking for CONST_VECTOR.
13508
13509 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
13510
13511 PR middle-end/83575
13512 * predict.c (force_edge_cold): Handle in more sane way edges
13513 with no prediction.
13514
13515 2018-01-09 Carl Love <cel@us.ibm.com>
13516
13517 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
13518 V4SI, V4SF types.
13519 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
13520 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
13521 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
13522 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
13523 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
13524 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
13525 * config/rs6000/rs6000-protos.h: Add extern defition for
13526 rs6000_generate_float2_double_code.
13527 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
13528 function.
13529 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
13530 (float2_v2df): Add define_expand.
13531
13532 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
13533
13534 PR target/83628
13535 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
13536 op_mode in the force_to_mode call.
13537
13538 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
13539
13540 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
13541 instead of checking each element individually.
13542 (aarch64_evpc_uzp): Likewise.
13543 (aarch64_evpc_zip): Likewise.
13544 (aarch64_evpc_ext): Likewise.
13545 (aarch64_evpc_rev): Likewise.
13546 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
13547 instead of checking each element individually. Return true without
13548 generating rtl if
13549 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
13550 whether all selected elements come from the same input, instead of
13551 checking each element individually. Remove calls to gen_rtx_REG,
13552 start_sequence and end_sequence and instead assert that no rtl is
13553 generated.
13554
13555 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
13556
13557 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
13558 order of HIGH and CONST checks.
13559
13560 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
13561
13562 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
13563 if the destination isn't an SSA_NAME.
13564
13565 2018-01-09 Richard Biener <rguenther@suse.de>
13566
13567 PR tree-optimization/83668
13568 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
13569 move prologue...
13570 (canonicalize_loop_form): ... here, renamed from ...
13571 (canonicalize_loop_closed_ssa_form): ... this and amended to
13572 swap successor edges for loop exit blocks to make us use
13573 the RPO order we need for initial schedule generation.
13574
13575 2018-01-09 Joseph Myers <joseph@codesourcery.com>
13576
13577 PR tree-optimization/64811
13578 * match.pd: When optimizing comparisons with Inf, avoid
13579 introducing or losing exceptions from comparisons with NaN.
13580
13581 2018-01-09 Martin Liska <mliska@suse.cz>
13582
13583 PR sanitizer/82517
13584 * asan.c (shadow_mem_size): Add gcc_assert.
13585
13586 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
13587
13588 Don't save registers in main().
13589
13590 PR target/83738
13591 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
13592 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
13593 * config/avr/avr.c (avr_set_current_function): Don't error if
13594 naked, OS_task or OS_main are specified at the same time.
13595 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
13596 OS_main.
13597 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
13598 attribute.
13599 * common/config/avr/avr-common.c (avr_option_optimization_table):
13600 Switch on -mmain-is-OS_task for optimizing compilations.
13601
13602 2018-01-09 Richard Biener <rguenther@suse.de>
13603
13604 PR tree-optimization/83572
13605 * graphite.c: Include cfganal.h.
13606 (graphite_transform_loops): Connect infinite loops to exit
13607 and remove fake edges at the end.
13608
13609 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
13610
13611 * ipa-inline.c (edge_badness): Revert accidental checkin.
13612
13613 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
13614
13615 PR ipa/80763
13616 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
13617 symbols; not inline clones.
13618
13619 2018-01-09 Jakub Jelinek <jakub@redhat.com>
13620
13621 PR target/83507
13622 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
13623 hard registers. Formatting fixes.
13624
13625 PR preprocessor/83722
13626 * gcc.c (try_generate_repro): Pass
13627 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
13628 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
13629 do_report_bug.
13630
13631 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
13632 Kito Cheng <kito.cheng@gmail.com>
13633
13634 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
13635 (riscv_leaf_function_p): Delete.
13636 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
13637
13638 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
13639
13640 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
13641 function.
13642 (do_ifelse): New function.
13643 (do_isel): New function.
13644 (do_sub3): New function.
13645 (do_add3): New function.
13646 (do_load_mask_compare): New function.
13647 (do_overlap_load_compare): New function.
13648 (expand_compare_loop): New function.
13649 (expand_block_compare): Call expand_compare_loop() when appropriate.
13650 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
13651 option description.
13652 (-mblock-compare-inline-loop-limit): New option.
13653
13654 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
13655
13656 PR target/83677
13657 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
13658 Reverse order of second and third operands in first alternative.
13659 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
13660 of first and second elements in UNSPEC_VPERMR vector.
13661 (altivec_expand_vec_perm_le): Likewise.
13662
13663 2018-01-08 Jeff Law <law@redhat.com>
13664
13665 PR rtl-optimizatin/81308
13666 * tree-switch-conversion.c (cfg_altered): New file scoped static.
13667 (process_switch): If group_case_labels makes a change, then set
13668 cfg_altered.
13669 (pass_convert_switch::execute): If a switch is converted, then
13670 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
13671
13672 PR rtl-optimization/81308
13673 * recog.c (split_all_insns): Conditionally cleanup the CFG after
13674 splitting insns.
13675
13676 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
13677
13678 PR target/83663 - Revert r255946
13679 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
13680 generation for cases where splatting a value is not useful.
13681 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
13682 across a vec_duplicate and a paradoxical subreg forming a vector
13683 mode to a vec_concat.
13684
13685 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13686
13687 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
13688 -march=armv8.3-a variants.
13689 * config/arm/t-multilib: Likewise.
13690 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
13691
13692 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
13693
13694 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
13695 to generate rtl.
13696 (cceq_ior_compare_complement): Give it a name so I can use it, and
13697 change boolean_or_operator predicate to boolean_operator so it can
13698 be used to generate a crand.
13699 (eqne): New code iterator.
13700 (bd/bd_neg): New code_attrs.
13701 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
13702 a single define_insn.
13703 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
13704 decrement (bdnzt/bdnzf/bdzt/bdzf).
13705 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
13706 with the new names of the branch decrement patterns, and added the
13707 names of the branch decrement conditional patterns.
13708
13709 2018-01-08 Richard Biener <rguenther@suse.de>
13710
13711 PR tree-optimization/83563
13712 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
13713 cache.
13714
13715 2018-01-08 Richard Biener <rguenther@suse.de>
13716
13717 PR middle-end/83713
13718 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
13719
13720 2018-01-08 Richard Biener <rguenther@suse.de>
13721
13722 PR tree-optimization/83685
13723 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
13724 references to abnormals.
13725
13726 2018-01-08 Richard Biener <rguenther@suse.de>
13727
13728 PR lto/83719
13729 * dwarf2out.c (output_indirect_strings): Handle empty
13730 skeleton_debug_str_hash.
13731 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
13732
13733 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
13734
13735 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
13736 (emit_store_direct): Likewise.
13737 (arc_trampoline_adjust_address): Likewise.
13738 (arc_asm_trampoline_template): New function.
13739 (arc_initialize_trampoline): Use asm_trampoline_template.
13740 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
13741 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
13742 * config/arc/arc.md (flush_icache): Delete pattern.
13743
13744 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
13745
13746 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
13747 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
13748 munaligned-access.
13749
13750 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
13751
13752 PR target/83681
13753 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
13754 by not USED_FOR_TARGET.
13755 (make_pass_resolve_sw_modes): Likewise.
13756
13757 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
13758
13759 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
13760 USED_FOR_TARGET.
13761
13762 2018-01-08 Richard Biener <rguenther@suse.de>
13763
13764 PR middle-end/83580
13765 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
13766
13767 2018-01-08 Richard Biener <rguenther@suse.de>
13768
13769 PR middle-end/83517
13770 * match.pd ((t * 2) / 2) -> t): Add missing :c.
13771
13772 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
13773
13774 PR middle-end/81897
13775 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
13776 basic blocks with a small number of successors.
13777 (convert_control_dep_chain_into_preds): Improve handling of
13778 forwarder blocks.
13779 (dump_predicates): Split apart into...
13780 (dump_pred_chain): ...here...
13781 (dump_pred_info): ...and here.
13782 (can_one_predicate_be_invalidated_p): Add debugging printfs.
13783 (can_chain_union_be_invalidated_p): Improve check for invalidation
13784 of paths.
13785 (uninit_uses_cannot_happen): Avoid unnecessary if
13786 convert_control_dep_chain_into_preds yielded nothing.
13787
13788 2018-01-06 Martin Sebor <msebor@redhat.com>
13789
13790 PR tree-optimization/83640
13791 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
13792 subtracting negative offset from size.
13793 (builtin_access::overlap): Adjust offset bounds of the access to fall
13794 within the size of the object if possible.
13795
13796 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
13797
13798 PR rtl-optimization/83699
13799 * expmed.c (extract_bit_field_1): Restrict the vector usage of
13800 extract_bit_field_as_subreg to cases in which the extracted
13801 value is also a vector.
13802
13803 * lra-constraints.c (process_alt_operands): Test for the equivalence
13804 substitutions when detecting a possible reload cycle.
13805
13806 2018-01-06 Jakub Jelinek <jakub@redhat.com>
13807
13808 PR debug/83480
13809 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
13810 by default if flag_selective_schedling{,2}. Formatting fixes.
13811
13812 PR rtl-optimization/83682
13813 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
13814 if it has non-VECTOR_MODE element mode.
13815 (vec_duplicate_p): Likewise.
13816
13817 PR middle-end/83694
13818 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
13819 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
13820
13821 2018-01-05 Jakub Jelinek <jakub@redhat.com>
13822
13823 PR target/83604
13824 * config/i386/i386-builtin.def
13825 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
13826 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
13827 Require also OPTION_MASK_ISA_AVX512F in addition to
13828 OPTION_MASK_ISA_GFNI.
13829 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
13830 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
13831 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
13832 to OPTION_MASK_ISA_GFNI.
13833 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
13834 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
13835 OPTION_MASK_ISA_AVX512BW.
13836 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
13837 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
13838 addition to OPTION_MASK_ISA_GFNI.
13839 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
13840 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
13841 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
13842 to OPTION_MASK_ISA_GFNI.
13843 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
13844 a requirement for all ISAs rather than any of them with a few
13845 exceptions.
13846 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
13847 processing.
13848 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
13849 bitmasks to be enabled with 3 exceptions, instead of requiring any
13850 enabled ISA with lots of exceptions.
13851 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
13852 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
13853 Change avx512bw in isa attribute to avx512f.
13854 * config/i386/sgxintrin.h: Add license boilerplate.
13855 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
13856 to __AVX512F__ and __AVX512VL to __AVX512VL__.
13857 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
13858 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
13859 defined.
13860 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
13861 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
13862 temporarily sse2 rather than sse if not enabled already.
13863
13864 PR target/83604
13865 * config/i386/sse.md (VI248_VLBW): Rename to ...
13866 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
13867 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
13868 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
13869 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
13870 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
13871 mode iterator instead of VI248_VLBW.
13872
13873 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
13874
13875 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
13876 (record_modified): Skip clobbers; add debug output.
13877 (param_change_prob): Use sreal frequencies.
13878
13879 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
13880
13881 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
13882 punt for user-aligned variables.
13883
13884 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
13885
13886 * tree-chrec.c (chrec_contains_symbols): Return true for
13887 POLY_INT_CST.
13888
13889 2018-01-05 Sudakshina Das <sudi.das@arm.com>
13890
13891 PR target/82439
13892 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
13893 of (x|y) == x for BICS pattern.
13894
13895 2018-01-05 Jakub Jelinek <jakub@redhat.com>
13896
13897 PR tree-optimization/83605
13898 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
13899 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
13900 can throw.
13901
13902 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
13903
13904 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
13905 * config/epiphany/rtems.h: New file.
13906
13907 2018-01-04 Jakub Jelinek <jakub@redhat.com>
13908 Uros Bizjak <ubizjak@gmail.com>
13909
13910 PR target/83554
13911 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
13912 QIreg_operand instead of register_operand predicate.
13913 * config/i386/i386.c (ix86_rop_should_change_byte_p,
13914 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
13915 comments instead of -fmitigate[-_]rop.
13916
13917 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
13918
13919 PR bootstrap/81926
13920 * cgraphunit.c (symbol_table::compile): Switch to text_section
13921 before calling assembly_start debug hook.
13922 * run-rtl-passes.c (run_rtl_passes): Likewise.
13923 Include output.h.
13924
13925 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
13926
13927 * tree-vrp.c (extract_range_from_binary_expr_1): Check
13928 range_int_cst_p rather than !symbolic_range_p before calling
13929 extract_range_from_multiplicative_op_1.
13930
13931 2018-01-04 Jeff Law <law@redhat.com>
13932
13933 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
13934 redundant test in assertion.
13935
13936 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
13937
13938 * doc/rtl.texi: Document machine_mode wrapper classes.
13939
13940 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
13941
13942 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
13943 using tree_to_uhwi.
13944
13945 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
13946
13947 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
13948 the VEC_PERM_EXPR fold to fail.
13949
13950 2018-01-04 Jakub Jelinek <jakub@redhat.com>
13951
13952 PR debug/83585
13953 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
13954 to switched_sections.
13955
13956 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
13957
13958 PR target/83680
13959 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
13960 test for d.testing.
13961
13962 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
13963
13964 PR target/83387
13965 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
13966 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
13967
13968 2018-01-04 Jakub Jelinek <jakub@redhat.com>
13969
13970 PR debug/83666
13971 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
13972 is BLKmode and bitpos not zero or mode change is needed.
13973
13974 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
13975
13976 PR target/83675
13977 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
13978 TARGET_VIS2.
13979
13980 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
13981
13982 PR target/83628
13983 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
13984 instead of MULT rtx. Update all corresponding splitters.
13985 (*saddl_se): Ditto.
13986 (*ssub<modesuffix>): Ditto.
13987 (*ssubl_se): Ditto.
13988 (*cmp_sadd_di): Update split patterns.
13989 (*cmp_sadd_si): Ditto.
13990 (*cmp_sadd_sidi): Ditto.
13991 (*cmp_ssub_di): Ditto.
13992 (*cmp_ssub_si): Ditto.
13993 (*cmp_ssub_sidi): Ditto.
13994 * config/alpha/predicates.md (const23_operand): New predicate.
13995 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
13996 Look for ASHIFT, not MULT inner operand.
13997 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
13998
13999 2018-01-04 Martin Liska <mliska@suse.cz>
14000
14001 PR gcov-profile/83669
14002 * gcov.c (output_intermediate_file): Add version to intermediate
14003 gcov file.
14004 * doc/gcov.texi: Document new field 'version' in intermediate
14005 file format. Fix location of '-k' option of gcov command.
14006
14007 2018-01-04 Martin Liska <mliska@suse.cz>
14008
14009 PR ipa/82352
14010 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
14011
14012 2018-01-04 Jakub Jelinek <jakub@redhat.com>
14013
14014 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
14015
14016 2018-01-03 Martin Sebor <msebor@redhat.com>
14017
14018 PR tree-optimization/83655
14019 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
14020 checking calls with invalid arguments.
14021
14022 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14023
14024 * tree-vect-stmts.c (vect_get_store_rhs): New function.
14025 (vectorizable_mask_load_store): Delete.
14026 (vectorizable_call): Return false for masked loads and stores.
14027 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
14028 instead of gimple_assign_rhs1.
14029 (vectorizable_load): Handle IFN_MASK_LOAD.
14030 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
14031
14032 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14033
14034 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
14035 split out from..,
14036 (vectorizable_mask_load_store): ...here.
14037 (vectorizable_load): ...and here.
14038
14039 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14040
14041 * tree-vect-stmts.c (vect_build_all_ones_mask)
14042 (vect_build_zero_merge_argument): New functions, split out from...
14043 (vectorizable_load): ...here.
14044
14045 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14046
14047 * tree-vect-stmts.c (vect_check_store_rhs): New function,
14048 split out from...
14049 (vectorizable_mask_load_store): ...here.
14050 (vectorizable_store): ...and here.
14051
14052 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14053
14054 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
14055 split out from...
14056 (vectorizable_mask_load_store): ...here.
14057
14058 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14059
14060 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
14061 (vect_model_store_cost): Take a vec_load_store_type instead of a
14062 vect_def_type.
14063 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
14064 (vect_model_store_cost): Take a vec_load_store_type instead of a
14065 vect_def_type.
14066 (vectorizable_mask_load_store): Update accordingly.
14067 (vectorizable_store): Likewise.
14068 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
14069
14070 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14071
14072 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
14073 IFN_MASK_LOAD calls here rather than...
14074 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
14075
14076 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14077 Alan Hayward <alan.hayward@arm.com>
14078 David Sherwood <david.sherwood@arm.com>
14079
14080 * expmed.c (extract_bit_field_1): For vector extracts,
14081 fall back to extract_bit_field_as_subreg if vec_extract
14082 isn't available.
14083
14084 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14085 Alan Hayward <alan.hayward@arm.com>
14086 David Sherwood <david.sherwood@arm.com>
14087
14088 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
14089 they are variable or constant sized.
14090 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
14091 slots for constant-sized data.
14092
14093 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14094 Alan Hayward <alan.hayward@arm.com>
14095 David Sherwood <david.sherwood@arm.com>
14096
14097 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
14098 handling COND_EXPRs with boolean comparisons, try to find a better
14099 basis for the mask type than the boolean itself.
14100
14101 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14102
14103 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
14104 is calculated and how it can be overridden.
14105 * genmodes.c (max_bitsize_mode_any_mode): New variable.
14106 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
14107 if defined.
14108 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
14109 if nonzero.
14110
14111 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14112 Alan Hayward <alan.hayward@arm.com>
14113 David Sherwood <david.sherwood@arm.com>
14114
14115 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
14116 Remove the mode argument.
14117 (aarch64_simd_valid_immediate): Remove the mode and inverse
14118 arguments.
14119 * config/aarch64/iterators.md (bitsize): New iterator.
14120 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
14121 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
14122 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
14123 aarch64_simd_valid_immediate.
14124 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
14125 (aarch64_reg_or_bic_imm): Likewise.
14126 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
14127 with an insn_type enum and msl with a modifier_type enum.
14128 Replace element_width with a scalar_mode. Change the shift
14129 to unsigned int. Add constructors for scalar_float_mode and
14130 scalar_int_mode elements.
14131 (aarch64_vect_float_const_representable_p): Delete.
14132 (aarch64_can_const_movi_rtx_p)
14133 (aarch64_simd_scalar_immediate_valid_for_move)
14134 (aarch64_simd_make_constant): Update call to
14135 aarch64_simd_valid_immediate.
14136 (aarch64_advsimd_valid_immediate_hs): New function.
14137 (aarch64_advsimd_valid_immediate): Likewise.
14138 (aarch64_simd_valid_immediate): Remove mode and inverse
14139 arguments. Rewrite to use the above. Use const_vec_duplicate_p
14140 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
14141 and aarch64_float_const_representable_p on the result.
14142 (aarch64_output_simd_mov_immediate): Remove mode argument.
14143 Update call to aarch64_simd_valid_immediate and use of
14144 simd_immediate_info.
14145 (aarch64_output_scalar_simd_mov_immediate): Update call
14146 accordingly.
14147
14148 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14149 Alan Hayward <alan.hayward@arm.com>
14150 David Sherwood <david.sherwood@arm.com>
14151
14152 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
14153 (mode_nunits): Likewise CONST_MODE_NUNITS.
14154 * machmode.def (ADJUST_NUNITS): Document.
14155 * genmodes.c (mode_data::need_nunits_adj): New field.
14156 (blank_mode): Update accordingly.
14157 (adj_nunits): New variable.
14158 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
14159 parameter.
14160 (emit_mode_size_inline): Set need_bytesize_adj for all modes
14161 listed in adj_nunits.
14162 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
14163 listed in adj_nunits. Don't emit case statements for such modes.
14164 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
14165 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
14166 nothing if adj_nunits is nonnull.
14167 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
14168 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
14169 (emit_mode_fbit): Update use of print_maybe_const_decl.
14170 (emit_move_size): Likewise. Treat the array as non-const
14171 if adj_nunits.
14172 (emit_mode_adjustments): Handle adj_nunits.
14173
14174 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14175
14176 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
14177 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
14178 (VECTOR_MODES): Use it.
14179 (make_vector_modes): Take the prefix as an argument.
14180
14181 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14182 Alan Hayward <alan.hayward@arm.com>
14183 David Sherwood <david.sherwood@arm.com>
14184
14185 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
14186 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
14187 for MODE_VECTOR_BOOL.
14188 * machmode.def (VECTOR_BOOL_MODE): Document.
14189 * genmodes.c (VECTOR_BOOL_MODE): New macro.
14190 (make_vector_bool_mode): New function.
14191 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
14192 MODE_VECTOR_BOOL.
14193 * lto-streamer-in.c (lto_input_mode_table): Likewise.
14194 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
14195 Likewise.
14196 * stor-layout.c (int_mode_for_mode): Likewise.
14197 * tree.c (build_vector_type_for_mode): Likewise.
14198 * varasm.c (output_constant_pool_2): Likewise.
14199 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
14200 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
14201 for MODE_VECTOR_BOOL.
14202 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
14203 of mode class checks.
14204 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
14205 instead of a list of mode class checks.
14206 (expand_vector_scalar_condition): Likewise.
14207 (type_for_widest_vector_mode): Handle BImode as an inner mode.
14208
14209 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14210 Alan Hayward <alan.hayward@arm.com>
14211 David Sherwood <david.sherwood@arm.com>
14212
14213 * machmode.h (mode_size): Change from unsigned short to
14214 poly_uint16_pod.
14215 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
14216 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
14217 or if measurement_type is not polynomial.
14218 (fixed_size_mode::includes_p): Check for constant-sized modes.
14219 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
14220 return a poly_uint16 rather than an unsigned short.
14221 (emit_mode_size): Change the type of mode_size from unsigned short
14222 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
14223 (emit_mode_adjustments): Cope with polynomial vector sizes.
14224 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
14225 for GET_MODE_SIZE.
14226 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
14227 for GET_MODE_SIZE.
14228 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
14229 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
14230 * caller-save.c (setup_save_areas): Likewise.
14231 (replace_reg_with_saved_mem): Likewise.
14232 * calls.c (emit_library_call_value_1): Likewise.
14233 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
14234 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
14235 (gen_lowpart_for_combine): Likewise.
14236 * convert.c (convert_to_integer_1): Likewise.
14237 * cse.c (equiv_constant, cse_insn): Likewise.
14238 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
14239 (cselib_subst_to_values): Likewise.
14240 * dce.c (word_dce_process_block): Likewise.
14241 * df-problems.c (df_word_lr_mark_ref): Likewise.
14242 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
14243 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
14244 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
14245 (rtl_for_decl_location): Likewise.
14246 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
14247 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
14248 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
14249 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
14250 (expand_expr_real_1): Likewise.
14251 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
14252 (pad_below): Likewise.
14253 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
14254 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
14255 * ira.c (get_subreg_tracking_sizes): Likewise.
14256 * ira-build.c (ira_create_allocno_objects): Likewise.
14257 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
14258 (ira_sort_regnos_for_alter_reg): Likewise.
14259 * ira-costs.c (record_operand_costs): Likewise.
14260 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
14261 (resolve_simple_move): Likewise.
14262 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
14263 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
14264 (lra_constraints): Likewise.
14265 (CONST_POOL_OK_P): Reject variable-sized modes.
14266 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
14267 (add_pseudo_to_slot, lra_spill): Likewise.
14268 * omp-low.c (omp_clause_aligned_alignment): Likewise.
14269 * optabs-query.c (get_best_extraction_insn): Likewise.
14270 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
14271 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
14272 (expand_mult_highpart, valid_multiword_target_p): Likewise.
14273 * recog.c (offsettable_address_addr_space_p): Likewise.
14274 * regcprop.c (maybe_mode_change): Likewise.
14275 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
14276 * regrename.c (build_def_use): Likewise.
14277 * regstat.c (dump_reg_info): Likewise.
14278 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
14279 (find_reloads, find_reloads_subreg_address): Likewise.
14280 * reload1.c (eliminate_regs_1): Likewise.
14281 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
14282 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
14283 (simplify_binary_operation_1, simplify_subreg): Likewise.
14284 * targhooks.c (default_function_arg_padding): Likewise.
14285 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
14286 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
14287 (verify_gimple_assign_ternary): Likewise.
14288 * tree-inline.c (estimate_move_cost): Likewise.
14289 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
14290 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
14291 (get_address_cost_ainc): Likewise.
14292 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
14293 (vect_supportable_dr_alignment): Likewise.
14294 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
14295 (vectorizable_reduction): Likewise.
14296 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
14297 (vectorizable_operation, vectorizable_load): Likewise.
14298 * tree.c (build_same_sized_truth_vector_type): Likewise.
14299 * valtrack.c (cleanup_auto_inc_dec): Likewise.
14300 * var-tracking.c (emit_note_insn_var_location): Likewise.
14301 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
14302 (ADDR_VEC_ALIGN): Likewise.
14303
14304 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14305 Alan Hayward <alan.hayward@arm.com>
14306 David Sherwood <david.sherwood@arm.com>
14307
14308 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
14309 unsigned short.
14310 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
14311 or if measurement_type is polynomial.
14312 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
14313 * combine.c (make_extraction): Likewise.
14314 * dse.c (find_shift_sequence): Likewise.
14315 * dwarf2out.c (mem_loc_descriptor): Likewise.
14316 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
14317 (extract_bit_field, extract_low_bits): Likewise.
14318 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
14319 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
14320 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
14321 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
14322 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
14323 * reload.c (find_reloads): Likewise.
14324 * reload1.c (alter_reg): Likewise.
14325 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
14326 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
14327 * tree-if-conv.c (predicate_mem_writes): Likewise.
14328 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
14329 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
14330 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
14331 * valtrack.c (dead_debug_insert_temp): Likewise.
14332 * varasm.c (mergeable_constant_section): Likewise.
14333 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
14334
14335 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14336 Alan Hayward <alan.hayward@arm.com>
14337 David Sherwood <david.sherwood@arm.com>
14338
14339 * expr.c (expand_assignment): Cope with polynomial mode sizes
14340 when assigning to a CONCAT.
14341
14342 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14343 Alan Hayward <alan.hayward@arm.com>
14344 David Sherwood <david.sherwood@arm.com>
14345
14346 * machmode.h (mode_precision): Change from unsigned short to
14347 poly_uint16_pod.
14348 (mode_to_precision): Return a poly_uint16 rather than an unsigned
14349 short.
14350 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
14351 or if measurement_type is not polynomial.
14352 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
14353 in which the mode is already known to be a scalar_int_mode.
14354 * genmodes.c (emit_mode_precision): Change the type of mode_precision
14355 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
14356 initializer.
14357 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
14358 for GET_MODE_PRECISION.
14359 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
14360 for GET_MODE_PRECISION.
14361 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
14362 as polynomial.
14363 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
14364 (expand_field_assignment, make_extraction): Likewise.
14365 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
14366 (get_last_value): Likewise.
14367 * convert.c (convert_to_integer_1): Likewise.
14368 * cse.c (cse_insn): Likewise.
14369 * expr.c (expand_expr_real_1): Likewise.
14370 * lra-constraints.c (simplify_operand_subreg): Likewise.
14371 * optabs-query.c (can_atomic_load_p): Likewise.
14372 * optabs.c (expand_atomic_load): Likewise.
14373 (expand_atomic_store): Likewise.
14374 * ree.c (combine_reaching_defs): Likewise.
14375 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
14376 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
14377 * tree.h (type_has_mode_precision_p): Likewise.
14378 * ubsan.c (instrument_si_overflow): Likewise.
14379
14380 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14381 Alan Hayward <alan.hayward@arm.com>
14382 David Sherwood <david.sherwood@arm.com>
14383
14384 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
14385 polynomial numbers of units.
14386 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
14387 (valid_vector_subparts_p): New function.
14388 (build_vector_type): Remove temporary shim and take the number
14389 of units as a poly_uint64 rather than an int.
14390 (build_opaque_vector_type): Take the number of units as a
14391 poly_uint64 rather than an int.
14392 * tree.c (build_vector_from_ctor): Handle polynomial
14393 TYPE_VECTOR_SUBPARTS.
14394 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
14395 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
14396 (build_vector_from_val): If the number of units is variable,
14397 use build_vec_duplicate_cst for constant operands and
14398 VEC_DUPLICATE_EXPR otherwise.
14399 (make_vector_type): Remove temporary is_constant ().
14400 (build_vector_type, build_opaque_vector_type): Take the number of
14401 units as a poly_uint64 rather than an int.
14402 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
14403 VECTOR_CST_NELTS.
14404 * cfgexpand.c (expand_debug_expr): Likewise.
14405 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
14406 (store_constructor, expand_expr_real_1): Likewise.
14407 (const_scalar_mask_from_tree): Likewise.
14408 * fold-const-call.c (fold_const_reduction): Likewise.
14409 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
14410 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
14411 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
14412 (fold_relational_const): Likewise.
14413 (native_interpret_vector): Likewise. Change the size from an
14414 int to an unsigned int.
14415 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
14416 TYPE_VECTOR_SUBPARTS.
14417 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
14418 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
14419 duplicating a non-constant operand into a variable-length vector.
14420 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
14421 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
14422 * ipa-icf.c (sem_variable::equals): Likewise.
14423 * match.pd: Likewise.
14424 * omp-simd-clone.c (simd_clone_subparts): Likewise.
14425 * print-tree.c (print_node): Likewise.
14426 * stor-layout.c (layout_type): Likewise.
14427 * targhooks.c (default_builtin_vectorization_cost): Likewise.
14428 * tree-cfg.c (verify_gimple_comparison): Likewise.
14429 (verify_gimple_assign_binary): Likewise.
14430 (verify_gimple_assign_ternary): Likewise.
14431 (verify_gimple_assign_single): Likewise.
14432 * tree-pretty-print.c (dump_generic_node): Likewise.
14433 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
14434 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
14435 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
14436 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
14437 (vect_shift_permute_load_chain): Likewise.
14438 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
14439 (expand_vector_condition, optimize_vector_constructor): Likewise.
14440 (lower_vec_perm, get_compute_type): Likewise.
14441 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
14442 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
14443 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
14444 (vect_recog_mask_conversion_pattern): Likewise.
14445 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
14446 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
14447 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
14448 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
14449 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
14450 (vectorizable_shift, vectorizable_operation, vectorizable_store)
14451 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
14452 (supportable_widening_operation): Likewise.
14453 (supportable_narrowing_operation): Likewise.
14454 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
14455 Likewise.
14456 * varasm.c (output_constant): Likewise.
14457
14458 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14459 Alan Hayward <alan.hayward@arm.com>
14460 David Sherwood <david.sherwood@arm.com>
14461
14462 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
14463 so that both the length == 3 and length != 3 cases set up their
14464 own permute vectors. Add comments explaining why we know the
14465 number of elements is constant.
14466 (vect_permute_load_chain): Likewise.
14467
14468 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14469 Alan Hayward <alan.hayward@arm.com>
14470 David Sherwood <david.sherwood@arm.com>
14471
14472 * machmode.h (mode_nunits): Change from unsigned char to
14473 poly_uint16_pod.
14474 (ONLY_FIXED_SIZE_MODES): New macro.
14475 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
14476 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
14477 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
14478 New typedefs.
14479 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
14480 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
14481 or if measurement_type is not polynomial.
14482 * genmodes.c (ZERO_COEFFS): New macro.
14483 (emit_mode_nunits_inline): Make mode_nunits_inline return a
14484 poly_uint16.
14485 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
14486 Use ZERO_COEFFS when emitting initializers.
14487 * data-streamer.h (bp_pack_poly_value): New function.
14488 (bp_unpack_poly_value): Likewise.
14489 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
14490 for GET_MODE_NUNITS.
14491 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
14492 for GET_MODE_NUNITS.
14493 * tree.c (make_vector_type): Remove temporary shim and make
14494 the real function take the number of units as a poly_uint64
14495 rather than an int.
14496 (build_vector_type_for_mode): Handle polynomial nunits.
14497 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
14498 * emit-rtl.c (const_vec_series_p_1): Likewise.
14499 (gen_rtx_CONST_VECTOR): Likewise.
14500 * fold-const.c (test_vec_duplicate_folding): Likewise.
14501 * genrecog.c (validate_pattern): Likewise.
14502 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
14503 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
14504 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
14505 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
14506 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
14507 * rtlanal.c (subreg_get_info): Likewise.
14508 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
14509 (vect_grouped_load_supported): Likewise.
14510 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
14511 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
14512 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
14513 (simplify_const_unary_operation, simplify_binary_operation_1)
14514 (simplify_const_binary_operation, simplify_ternary_operation)
14515 (test_vector_ops_duplicate, test_vector_ops): Likewise.
14516 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
14517 instead of CONST_VECTOR_NUNITS.
14518 * varasm.c (output_constant_pool_2): Likewise.
14519 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
14520 explicit-encoded elements in the XVEC for variable-length vectors.
14521
14522 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14523
14524 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
14525
14526 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14527 Alan Hayward <alan.hayward@arm.com>
14528 David Sherwood <david.sherwood@arm.com>
14529
14530 * coretypes.h (fixed_size_mode): Declare.
14531 (fixed_size_mode_pod): New typedef.
14532 * builtins.h (target_builtins::x_apply_args_mode)
14533 (target_builtins::x_apply_result_mode): Change type to
14534 fixed_size_mode_pod.
14535 * builtins.c (apply_args_size, apply_result_size, result_vector)
14536 (expand_builtin_apply_args_1, expand_builtin_apply)
14537 (expand_builtin_return): Update accordingly.
14538
14539 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14540
14541 * cse.c (hash_rtx_cb): Hash only the encoded elements.
14542 * cselib.c (cselib_hash_rtx): Likewise.
14543 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
14544 CONST_VECTOR encoding.
14545
14546 2018-01-03 Jakub Jelinek <jakub@redhat.com>
14547 Jeff Law <law@redhat.com>
14548
14549 PR target/83641
14550 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
14551 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
14552 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
14553 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
14554
14555 PR target/83641
14556 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
14557 explicitly probe *sp in a noreturn function if there were any callee
14558 register saves or frame pointer is needed.
14559
14560 2018-01-03 Jakub Jelinek <jakub@redhat.com>
14561
14562 PR debug/83621
14563 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
14564 BLKmode for ternary, binary or unary expressions.
14565
14566 PR debug/83645
14567 * var-tracking.c (delete_vta_debug_insn): New inline function.
14568 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
14569 insns from get_insns () to NULL instead of each bb separately.
14570 Use delete_vta_debug_insn. No longer static.
14571 (vt_debug_insns_local, variable_tracking_main_1): Adjust
14572 delete_vta_debug_insns callers.
14573 * rtl.h (delete_vta_debug_insns): Declare.
14574 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
14575 instead of variable_tracking_main.
14576
14577 2018-01-03 Martin Sebor <msebor@redhat.com>
14578
14579 PR tree-optimization/83603
14580 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
14581 arguments past the endof the argument list in functions declared
14582 without a prototype.
14583 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
14584 Avoid checking when arguments are null.
14585
14586 2018-01-03 Martin Sebor <msebor@redhat.com>
14587
14588 PR c/83559
14589 * doc/extend.texi (attribute const): Fix a typo.
14590 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
14591 issuing -Wsuggest-attribute for void functions.
14592
14593 2018-01-03 Martin Sebor <msebor@redhat.com>
14594
14595 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
14596 offset_int::from instead of wide_int::to_shwi.
14597 (maybe_diag_overlap): Remove assertion.
14598 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
14599 * gimple-ssa-sprintf.c (format_directive): Same.
14600 (parse_directive): Same.
14601 (sprintf_dom_walker::compute_format_length): Same.
14602 (try_substitute_return_value): Same.
14603
14604 2018-01-03 Jeff Law <law@redhat.com>
14605
14606 PR middle-end/83654
14607 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
14608 non-constant residual for zero at runtime and avoid probing in
14609 that case. Reorganize code for trailing problem to mirror handling
14610 of the residual.
14611
14612 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
14613
14614 PR tree-optimization/83501
14615 * tree-ssa-strlen.c (get_string_cst): New.
14616 (handle_char_store): Call get_string_cst.
14617
14618 2018-01-03 Martin Liska <mliska@suse.cz>
14619
14620 PR tree-optimization/83593
14621 * tree-ssa-strlen.c: Include tree-cfg.h.
14622 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
14623 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
14624 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
14625 to false.
14626 (strlen_dom_walker::before_dom_children): Call
14627 gimple_purge_dead_eh_edges. Dump tranformation with details
14628 dump flags.
14629 (strlen_dom_walker::before_dom_children): Update call by adding
14630 new argument cleanup_eh.
14631 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
14632
14633 2018-01-03 Martin Liska <mliska@suse.cz>
14634
14635 PR ipa/83549
14636 * cif-code.def (VARIADIC_THUNK): New enum value.
14637 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
14638 thunks.
14639
14640 2018-01-03 Jan Beulich <jbeulich@suse.com>
14641
14642 * sse.md (mov<mode>_internal): Tighten condition for when to use
14643 vmovdqu<ssescalarsize> for TI and OI modes.
14644
14645 2018-01-03 Jakub Jelinek <jakub@redhat.com>
14646
14647 Update copyright years.
14648
14649 2018-01-03 Martin Liska <mliska@suse.cz>
14650
14651 PR ipa/83594
14652 * ipa-visibility.c (function_and_variable_visibility): Skip
14653 functions with noipa attribure.
14654
14655 2018-01-03 Jakub Jelinek <jakub@redhat.com>
14656
14657 * gcc.c (process_command): Update copyright notice dates.
14658 * gcov-dump.c (print_version): Ditto.
14659 * gcov.c (print_version): Ditto.
14660 * gcov-tool.c (print_version): Ditto.
14661 * gengtype.c (create_file): Ditto.
14662 * doc/cpp.texi: Bump @copying's copyright year.
14663 * doc/cppinternals.texi: Ditto.
14664 * doc/gcc.texi: Ditto.
14665 * doc/gccint.texi: Ditto.
14666 * doc/gcov.texi: Ditto.
14667 * doc/install.texi: Ditto.
14668 * doc/invoke.texi: Ditto.
14669
14670 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14671
14672 * vector-builder.h (vector_builder::m_full_nelts): Change from
14673 unsigned int to poly_uint64.
14674 (vector_builder::full_nelts): Update prototype accordingly.
14675 (vector_builder::new_vector): Likewise.
14676 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
14677 (vector_builder::operator ==): Likewise.
14678 (vector_builder::finalize): Likewise.
14679 * int-vector-builder.h (int_vector_builder::int_vector_builder):
14680 Take the number of elements as a poly_uint64 rather than an
14681 unsigned int.
14682 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
14683 from unsigned int to poly_uint64.
14684 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
14685 (vec_perm_indices::new_vector): Likewise.
14686 (vec_perm_indices::length): Likewise.
14687 (vec_perm_indices::nelts_per_input): Likewise.
14688 (vec_perm_indices::input_nelts): Likewise.
14689 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
14690 number of elements per input as a poly_uint64 rather than an
14691 unsigned int. Use the original encoding for variable-length
14692 vectors, rather than clamping each individual element.
14693 For the second and subsequent elements in each pattern,
14694 clamp the step and base before clamping their sum.
14695 (vec_perm_indices::series_p): Handle polynomial element counts.
14696 (vec_perm_indices::all_in_range_p): Likewise.
14697 (vec_perm_indices_to_tree): Likewise.
14698 (vec_perm_indices_to_rtx): Likewise.
14699 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
14700 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
14701 (tree_vector_builder::new_binary_operation): Handle polynomial
14702 element counts. Return false if we need to know the number
14703 of elements at compile time.
14704 * fold-const.c (fold_vec_perm): Punt if the number of elements
14705 isn't known at compile time.
14706
14707 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14708
14709 * vec-perm-indices.h (vec_perm_builder): Change element type
14710 from HOST_WIDE_INT to poly_int64.
14711 (vec_perm_indices::element_type): Update accordingly.
14712 (vec_perm_indices::clamp): Handle polynomial element_types.
14713 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
14714 (vec_perm_indices::all_in_range_p): Likewise.
14715 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
14716 than shwi trees.
14717 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
14718 polynomial vec_perm_indices element types.
14719 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
14720 * fold-const.c (fold_vec_perm): Likewise.
14721 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
14722 * tree-vect-generic.c (lower_vec_perm): Likewise.
14723 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
14724 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
14725 element type to HOST_WIDE_INT.
14726
14727 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14728 Alan Hayward <alan.hayward@arm.com>
14729 David Sherwood <david.sherwood@arm.com>
14730
14731 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
14732 rather than an int. Use plus_constant.
14733 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
14734 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
14735
14736 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14737 Alan Hayward <alan.hayward@arm.com>
14738 David Sherwood <david.sherwood@arm.com>
14739
14740 * calls.c (emit_call_1, expand_call): Change struct_value_size from
14741 a HOST_WIDE_INT to a poly_int64.
14742
14743 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14744 Alan Hayward <alan.hayward@arm.com>
14745 David Sherwood <david.sherwood@arm.com>
14746
14747 * calls.c (load_register_parameters): Cope with polynomial
14748 mode sizes. Require a constant size for BLKmode parameters
14749 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
14750 forces a parameter to be padded at the lsb end in order to
14751 fill a complete number of words, require the parameter size
14752 to be ordered wrt UNITS_PER_WORD.
14753
14754 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14755 Alan Hayward <alan.hayward@arm.com>
14756 David Sherwood <david.sherwood@arm.com>
14757
14758 * reload1.c (spill_stack_slot_width): Change element type
14759 from unsigned int to poly_uint64_pod.
14760 (alter_reg): Treat mode sizes as polynomial.
14761
14762 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14763 Alan Hayward <alan.hayward@arm.com>
14764 David Sherwood <david.sherwood@arm.com>
14765
14766 * reload.c (complex_word_subreg_p): New function.
14767 (reload_inner_reg_of_subreg, push_reload): Use it.
14768
14769 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14770 Alan Hayward <alan.hayward@arm.com>
14771 David Sherwood <david.sherwood@arm.com>
14772
14773 * lra-constraints.c (process_alt_operands): Reject matched
14774 operands whose sizes aren't ordered.
14775 (match_reload): Refer to this check here.
14776
14777 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14778 Alan Hayward <alan.hayward@arm.com>
14779 David Sherwood <david.sherwood@arm.com>
14780
14781 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
14782 that the mode size is in the set {1, 2, 4, 8, 16}.
14783
14784 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14785 Alan Hayward <alan.hayward@arm.com>
14786 David Sherwood <david.sherwood@arm.com>
14787
14788 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
14789 Use plus_constant instead of gen_rtx_PLUS.
14790
14791 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14792 Alan Hayward <alan.hayward@arm.com>
14793 David Sherwood <david.sherwood@arm.com>
14794
14795 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
14796 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
14797 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
14798 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
14799 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
14800 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
14801 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
14802 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
14803 * config/i386/i386.c (ix86_push_rounding): ...this new function.
14804 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
14805 a poly_int64.
14806 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
14807 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
14808 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
14809 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
14810 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
14811 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
14812 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
14813 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
14814 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
14815 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
14816 function.
14817 * expr.c (emit_move_resolve_push): Treat the input and result
14818 of PUSH_ROUNDING as a poly_int64.
14819 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
14820 (emit_push_insn): Likewise.
14821 * lra-eliminations.c (mark_not_eliminable): Likewise.
14822 * recog.c (push_operand): Likewise.
14823 * reload1.c (elimination_effects): Likewise.
14824 * rtlanal.c (nonzero_bits1): Likewise.
14825 * calls.c (store_one_arg): Likewise. Require the padding to be
14826 known at compile time.
14827
14828 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14829 Alan Hayward <alan.hayward@arm.com>
14830 David Sherwood <david.sherwood@arm.com>
14831
14832 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
14833 Use plus_constant instead of gen_rtx_PLUS.
14834
14835 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14836 Alan Hayward <alan.hayward@arm.com>
14837 David Sherwood <david.sherwood@arm.com>
14838
14839 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
14840 rather than an int.
14841
14842 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14843 Alan Hayward <alan.hayward@arm.com>
14844 David Sherwood <david.sherwood@arm.com>
14845
14846 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
14847 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
14848 via stack temporaries. Treat the mode size as polynomial too.
14849
14850 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14851 Alan Hayward <alan.hayward@arm.com>
14852 David Sherwood <david.sherwood@arm.com>
14853
14854 * expr.c (expand_expr_real_2): When handling conversions involving
14855 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
14856 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
14857 as a poly_uint64 too.
14858
14859 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14860 Alan Hayward <alan.hayward@arm.com>
14861 David Sherwood <david.sherwood@arm.com>
14862
14863 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
14864
14865 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14866 Alan Hayward <alan.hayward@arm.com>
14867 David Sherwood <david.sherwood@arm.com>
14868
14869 * combine.c (can_change_dest_mode): Handle polynomial
14870 REGMODE_NATURAL_SIZE.
14871 * expmed.c (store_bit_field_1): Likewise.
14872 * expr.c (store_constructor): Likewise.
14873 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
14874 and polynomial REGMODE_NATURAL_SIZE.
14875 (gen_lowpart_common): Likewise.
14876 * reginfo.c (record_subregs_of_mode): Likewise.
14877 * rtlanal.c (read_modify_subreg_p): Likewise.
14878
14879 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14880 Alan Hayward <alan.hayward@arm.com>
14881 David Sherwood <david.sherwood@arm.com>
14882
14883 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
14884 numbers of elements.
14885
14886 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14887 Alan Hayward <alan.hayward@arm.com>
14888 David Sherwood <david.sherwood@arm.com>
14889
14890 * match.pd: Cope with polynomial numbers of vector elements.
14891
14892 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14893 Alan Hayward <alan.hayward@arm.com>
14894 David Sherwood <david.sherwood@arm.com>
14895
14896 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
14897 in a POINTER_PLUS_EXPR.
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 * omp-simd-clone.c (simd_clone_subparts): New function.
14904 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
14905 (ipa_simd_modify_function_body): Likewise.
14906
14907 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14908 Alan Hayward <alan.hayward@arm.com>
14909 David Sherwood <david.sherwood@arm.com>
14910
14911 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
14912 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
14913 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
14914 (expand_vector_condition, vector_element): Likewise.
14915 (subparts_gt): New function.
14916 (get_compute_type): Use subparts_gt.
14917 (count_type_subparts): Delete.
14918 (expand_vector_operations_1): Use subparts_gt instead of
14919 count_type_subparts.
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 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
14926 (vect_compile_time_alias): ...this new function. Do the calculation
14927 on poly_ints rather than trees.
14928 (vect_prune_runtime_alias_test_list): Update call accordingly.
14929
14930 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14931 Alan Hayward <alan.hayward@arm.com>
14932 David Sherwood <david.sherwood@arm.com>
14933
14934 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
14935 numbers of units.
14936 (vect_schedule_slp_instance): Likewise.
14937
14938 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14939 Alan Hayward <alan.hayward@arm.com>
14940 David Sherwood <david.sherwood@arm.com>
14941
14942 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
14943 constant and extern definitions for variable-length vectors.
14944 (vect_get_constant_vectors): Note that the number of units
14945 is known to be constant.
14946
14947 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14948 Alan Hayward <alan.hayward@arm.com>
14949 David Sherwood <david.sherwood@arm.com>
14950
14951 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
14952 of units as polynomial. Choose between WIDE and NARROW based
14953 on multiple_p.
14954
14955 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14956 Alan Hayward <alan.hayward@arm.com>
14957 David Sherwood <david.sherwood@arm.com>
14958
14959 * tree-vect-stmts.c (simd_clone_subparts): New function.
14960 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
14961
14962 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14963 Alan Hayward <alan.hayward@arm.com>
14964 David Sherwood <david.sherwood@arm.com>
14965
14966 * tree-vect-stmts.c (vectorizable_call): Treat the number of
14967 vectors as polynomial. Use build_index_vector for
14968 IFN_GOMP_SIMD_LANE.
14969
14970 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14971 Alan Hayward <alan.hayward@arm.com>
14972 David Sherwood <david.sherwood@arm.com>
14973
14974 * tree-vect-stmts.c (get_load_store_type): Treat the number of
14975 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
14976 for variable-length vectors.
14977 (vectorizable_mask_load_store): Treat the number of units as
14978 polynomial, asserting that it is constant if the condition has
14979 already been enforced.
14980 (vectorizable_store, vectorizable_load): Likewise.
14981
14982 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14983 Alan Hayward <alan.hayward@arm.com>
14984 David Sherwood <david.sherwood@arm.com>
14985
14986 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
14987 of units as polynomial. Punt if we can't tell at compile time
14988 which vector contains the final result.
14989
14990 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
14991 Alan Hayward <alan.hayward@arm.com>
14992 David Sherwood <david.sherwood@arm.com>
14993
14994 * tree-vect-loop.c (vectorizable_induction): Treat the number
14995 of units as polynomial. Punt on SLP inductions. Use an integer
14996 VEC_SERIES_EXPR for variable-length integer reductions. Use a
14997 cast of such a series for variable-length floating-point
14998 reductions.
14999
15000 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15001 Alan Hayward <alan.hayward@arm.com>
15002 David Sherwood <david.sherwood@arm.com>
15003
15004 * tree.h (build_index_vector): Declare.
15005 * tree.c (build_index_vector): New function.
15006 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
15007 of units as polynomial, forcibly converting it to a constant if
15008 vectorizable_reduction has already enforced the condition.
15009 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
15010 to create a {1,2,3,...} vector.
15011 (vectorizable_reduction): Treat the number of units as polynomial.
15012 Choose vectype_in based on the largest scalar element size rather
15013 than the smallest number of units. Enforce the restrictions
15014 relied on above.
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 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
15021 number of units as polynomial.
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 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
15028 * target.def (autovectorize_vector_sizes): Return the vector sizes
15029 by pointer, using vector_sizes rather than a bitmask.
15030 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
15031 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
15032 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
15033 Likewise.
15034 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
15035 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
15036 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
15037 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
15038 * omp-general.c (omp_max_vf): Likewise.
15039 * omp-low.c (omp_clause_aligned_alignment): Likewise.
15040 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
15041 * tree-vect-loop.c (vect_analyze_loop): Likewise.
15042 * tree-vect-slp.c (vect_slp_bb): Likewise.
15043 * doc/tm.texi: Regenerate.
15044 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
15045 to a poly_uint64.
15046 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
15047 the vector size as a poly_uint64 rather than an unsigned int.
15048 (current_vector_size): Change from an unsigned int to a poly_uint64.
15049 (get_vectype_for_scalar_type): Update accordingly.
15050 * tree.h (build_truth_vector_type): Take the size and number of
15051 units as a poly_uint64 rather than an unsigned int.
15052 (build_vector_type): Add a temporary overload that takes
15053 the number of units as a poly_uint64 rather than an unsigned int.
15054 * tree.c (make_vector_type): Likewise.
15055 (build_truth_vector_type): Take the number of units as a poly_uint64
15056 rather than an unsigned int.
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 * target.def (get_mask_mode): Take the number of units and length
15063 as poly_uint64s rather than unsigned ints.
15064 * targhooks.h (default_get_mask_mode): Update accordingly.
15065 * targhooks.c (default_get_mask_mode): Likewise.
15066 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
15067 * doc/tm.texi: Regenerate.
15068
15069 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15070 Alan Hayward <alan.hayward@arm.com>
15071 David Sherwood <david.sherwood@arm.com>
15072
15073 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
15074 * omp-general.c (omp_max_vf): Likewise.
15075 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
15076 (expand_omp_simd): Handle polynomial safelen.
15077 * omp-low.c (omplow_simd_context): Add a default constructor.
15078 (omplow_simd_context::max_vf): Change from int to poly_uint64.
15079 (lower_rec_simd_input_clauses): Update accordingly.
15080 (lower_rec_input_clauses): Likewise.
15081
15082 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15083 Alan Hayward <alan.hayward@arm.com>
15084 David Sherwood <david.sherwood@arm.com>
15085
15086 * tree-vectorizer.h (vect_nunits_for_cost): New function.
15087 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
15088 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
15089 (vect_analyze_slp_cost): Likewise.
15090 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
15091 (vect_model_load_cost): Likewise.
15092
15093 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15094 Alan Hayward <alan.hayward@arm.com>
15095 David Sherwood <david.sherwood@arm.com>
15096
15097 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
15098 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
15099 from an unsigned int * to a poly_uint64_pod *.
15100 (calculate_unrolling_factor): New function.
15101 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
15102
15103 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15104 Alan Hayward <alan.hayward@arm.com>
15105 David Sherwood <david.sherwood@arm.com>
15106
15107 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
15108 from an unsigned int to a poly_uint64.
15109 (_loop_vec_info::slp_unrolling_factor): Likewise.
15110 (_loop_vec_info::vectorization_factor): Change from an int
15111 to a poly_uint64.
15112 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
15113 (vect_get_num_vectors): New function.
15114 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
15115 (vect_get_num_copies): Use vect_get_num_vectors.
15116 (vect_analyze_data_ref_dependences): Change max_vf from an int *
15117 to an unsigned int *.
15118 (vect_analyze_data_refs): Change min_vf from an int * to a
15119 poly_uint64 *.
15120 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
15121 than an unsigned HOST_WIDE_INT.
15122 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
15123 (vect_analyze_data_ref_dependence): Change max_vf from an int *
15124 to an unsigned int *.
15125 (vect_analyze_data_ref_dependences): Likewise.
15126 (vect_compute_data_ref_alignment): Handle polynomial vf.
15127 (vect_enhance_data_refs_alignment): Likewise.
15128 (vect_prune_runtime_alias_test_list): Likewise.
15129 (vect_shift_permute_load_chain): Likewise.
15130 (vect_supportable_dr_alignment): Likewise.
15131 (dependence_distance_ge_vf): Take the vectorization factor as a
15132 poly_uint64 rather than an unsigned HOST_WIDE_INT.
15133 (vect_analyze_data_refs): Change min_vf from an int * to a
15134 poly_uint64 *.
15135 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
15136 vfm1 as a poly_uint64 rather than an int. Make the same change
15137 for the returned bound_scalar.
15138 (vect_gen_vector_loop_niters): Handle polynomial vf.
15139 (vect_do_peeling): Likewise. Update call to
15140 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
15141 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
15142 be constant.
15143 * tree-vect-loop.c (vect_determine_vectorization_factor)
15144 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
15145 (vect_get_known_peeling_cost): Likewise.
15146 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
15147 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
15148 (vect_transform_loop): Likewise. Use the lowest possible VF when
15149 updating the upper bounds of the loop.
15150 (vect_min_worthwhile_factor): Make static. Return an unsigned int
15151 rather than an int.
15152 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
15153 polynomial unroll factors.
15154 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
15155 (vect_make_slp_decision): Likewise.
15156 (vect_supported_load_permutation_p): Likewise, and polynomial
15157 vf too.
15158 (vect_analyze_slp_cost): Handle polynomial vf.
15159 (vect_slp_analyze_node_operations): Likewise.
15160 (vect_slp_analyze_bb_1): Likewise.
15161 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
15162 than an unsigned HOST_WIDE_INT.
15163 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
15164 (vectorizable_load): Handle polynomial vf.
15165 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
15166 a poly_uint64.
15167 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
15168
15169 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15170 Alan Hayward <alan.hayward@arm.com>
15171 David Sherwood <david.sherwood@arm.com>
15172
15173 * match.pd: Handle bit operations involving three constants
15174 and try to fold one pair.
15175
15176 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
15177
15178 * tree-vect-loop-manip.c: Include gimple-fold.h.
15179 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
15180 niters_maybe_zero parameters. Handle other cases besides a step of 1.
15181 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
15182 Add a path that uses a step of VF instead of 1, but disable it
15183 for now.
15184 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
15185 and niters_no_overflow parameters. Update calls to
15186 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
15187 Create a new SSA name if the latter choses to use a ste other
15188 than zero, and return it via niters_vector_mult_vf_var.
15189 * tree-vect-loop.c (vect_transform_loop): Update calls to
15190 vect_do_peeling, vect_gen_vector_loop_niters and
15191 slpeel_make_loop_iterate_ntimes.
15192 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
15193 (vect_gen_vector_loop_niters): Update declarations after above changes.
15194
15195 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
15196
15197 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
15198 128-bit round to integer instructions.
15199 (ceil<mode>2): Likewise.
15200 (btrunc<mode>2): Likewise.
15201 (round<mode>2): Likewise.
15202
15203 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
15204
15205 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
15206 unaligned VSX load/store on P8/P9.
15207 (expand_block_clear): Allow the use of unaligned VSX
15208 load/store on P8/P9.
15209
15210 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
15211
15212 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
15213 New function.
15214 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
15215 swap associated with both a load and a store.
15216
15217 2018-01-02 Andrew Waterman <andrew@sifive.com>
15218
15219 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
15220 * config/riscv/riscv.md (clear_cache): Use it.
15221
15222 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
15223
15224 * web.c: Remove out-of-date comment.
15225
15226 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15227
15228 * expr.c (fixup_args_size_notes): Check that any existing
15229 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
15230 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
15231 (emit_single_push_insn): ...here.
15232
15233 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15234
15235 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
15236 (const_vector_encoded_nelts): New function.
15237 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
15238 (const_vector_int_elt, const_vector_elt): Declare.
15239 * emit-rtl.c (const_vector_int_elt_1): New function.
15240 (const_vector_elt): Likewise.
15241 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
15242 of CONST_VECTOR_ELT.
15243
15244 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15245
15246 * expr.c: Include rtx-vector-builder.h.
15247 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
15248 directly on the tree encoding.
15249 (const_vector_from_tree): Likewise.
15250 * optabs.c: Include rtx-vector-builder.h.
15251 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
15252 sequence of "u" values.
15253 * vec-perm-indices.c: Include rtx-vector-builder.h.
15254 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
15255 directly on the vec_perm_indices encoding.
15256
15257 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15258
15259 * doc/rtl.texi (const_vector): Describe new encoding scheme.
15260 * Makefile.in (OBJS): Add rtx-vector-builder.o.
15261 * rtx-vector-builder.h: New file.
15262 * rtx-vector-builder.c: Likewise.
15263 * rtl.h (rtx_def::u2): Add a const_vector field.
15264 (CONST_VECTOR_NPATTERNS): New macro.
15265 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
15266 (CONST_VECTOR_DUPLICATE_P): Likewise.
15267 (CONST_VECTOR_STEPPED_P): Likewise.
15268 (CONST_VECTOR_ENCODED_ELT): Likewise.
15269 (const_vec_duplicate_p): Check for a duplicated vector encoding.
15270 (unwrap_const_vec_duplicate): Likewise.
15271 (const_vec_series_p): Check for a non-duplicated vector encoding.
15272 Say that the function only returns true for integer vectors.
15273 * emit-rtl.c: Include rtx-vector-builder.h.
15274 (gen_const_vec_duplicate_1): Delete.
15275 (gen_const_vector): Call gen_const_vec_duplicate instead of
15276 gen_const_vec_duplicate_1.
15277 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
15278 (gen_const_vec_duplicate): Use rtx_vector_builder.
15279 (gen_const_vec_series): Likewise.
15280 (gen_rtx_CONST_VECTOR): Likewise.
15281 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
15282 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
15283 Build a new vector rather than modifying a CONST_VECTOR in-place.
15284 (handle_special_swappables): Update call accordingly.
15285 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
15286 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
15287 Build a new vector rather than modifying a CONST_VECTOR in-place.
15288 (handle_special_swappables): Update call accordingly.
15289
15290 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15291
15292 * simplify-rtx.c (simplify_const_binary_operation): Use
15293 CONST_VECTOR_ELT instead of XVECEXP.
15294
15295 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15296
15297 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
15298 the selector elements to be different from the data elements
15299 if the selector is a VECTOR_CST.
15300 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
15301 ssizetype for the selector.
15302
15303 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15304
15305 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
15306 before testing each element individually.
15307 * tree-vect-generic.c (lower_vec_perm): Likewise.
15308
15309 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15310
15311 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
15312 * selftest-run-tests.c (selftest::run_tests): Call it.
15313 * vector-builder.h (vector_builder::operator ==): New function.
15314 (vector_builder::operator !=): Likewise.
15315 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
15316 (vec_perm_indices::all_from_input_p): New function.
15317 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
15318 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
15319 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
15320 instead of reading the VECTOR_CST directly. Detect whether both
15321 vector inputs are the same before constructing the vec_perm_indices,
15322 and update the number of inputs argument accordingly. Use the
15323 utility functions added above. Only construct sel2 if we need to.
15324
15325 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15326
15327 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
15328 the broadcast of the low byte.
15329 (expand_mult_highpart): Use an explicit encoding for the permutes.
15330 * optabs-query.c (can_mult_highpart_p): Likewise.
15331 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
15332 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
15333 (vectorizable_bswap): Likewise.
15334 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
15335 explicit encoding for the power-of-2 permutes.
15336 (vect_permute_store_chain): Likewise.
15337 (vect_grouped_load_supported): Likewise.
15338 (vect_permute_load_chain): Likewise.
15339
15340 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15341
15342 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
15343 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
15344 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
15345 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
15346 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
15347 (vect_gen_perm_mask_any): Likewise.
15348
15349 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15350
15351 * int-vector-builder.h: New file.
15352 * vec-perm-indices.h: Include int-vector-builder.h.
15353 (vec_perm_indices): Redefine as an int_vector_builder.
15354 (auto_vec_perm_indices): Delete.
15355 (vec_perm_builder): Redefine as a stand-alone class.
15356 (vec_perm_indices::vec_perm_indices): New function.
15357 (vec_perm_indices::clamp): Likewise.
15358 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
15359 (vec_perm_indices::new_vector): New function.
15360 (vec_perm_indices::new_expanded_vector): Update for new
15361 vec_perm_indices class.
15362 (vec_perm_indices::rotate_inputs): New function.
15363 (vec_perm_indices::all_in_range_p): Operate directly on the
15364 encoded form, without computing elided elements.
15365 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
15366 encoding. Update for new vec_perm_indices class.
15367 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
15368 the given vec_perm_builder.
15369 (expand_vec_perm_var): Update vec_perm_builder constructor.
15370 (expand_mult_highpart): Use vec_perm_builder instead of
15371 auto_vec_perm_indices.
15372 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
15373 vec_perm_indices instead of auto_vec_perm_indices. Use a single
15374 or double series encoding as appropriate.
15375 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
15376 vec_perm_indices instead of auto_vec_perm_indices.
15377 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
15378 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
15379 (vect_permute_store_chain): Likewise.
15380 (vect_grouped_load_supported): Likewise.
15381 (vect_permute_load_chain): Likewise.
15382 (vect_shift_permute_load_chain): Likewise.
15383 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
15384 (vect_transform_slp_perm_load): Likewise.
15385 (vect_schedule_slp_instance): Likewise.
15386 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
15387 (vectorizable_mask_load_store): Likewise.
15388 (vectorizable_bswap): Likewise.
15389 (vectorizable_store): Likewise.
15390 (vectorizable_load): Likewise.
15391 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
15392 vec_perm_indices instead of auto_vec_perm_indices. Use
15393 tree_to_vec_perm_builder to read the vector from a tree.
15394 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
15395 vec_perm_builder instead of a vec_perm_indices.
15396 (have_whole_vector_shift): Use vec_perm_builder and
15397 vec_perm_indices instead of auto_vec_perm_indices. Leave the
15398 truncation to calc_vec_perm_mask_for_shift.
15399 (vect_create_epilog_for_reduction): Likewise.
15400 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
15401 from auto_vec_perm_indices to vec_perm_indices.
15402 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
15403 instead of changing individual elements.
15404 (aarch64_vectorize_vec_perm_const): Use new_vector to install
15405 the vector in d.perm.
15406 * config/arm/arm.c (expand_vec_perm_d::perm): Change
15407 from auto_vec_perm_indices to vec_perm_indices.
15408 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
15409 instead of changing individual elements.
15410 (arm_vectorize_vec_perm_const): Use new_vector to install
15411 the vector in d.perm.
15412 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
15413 Update vec_perm_builder constructor.
15414 (rs6000_expand_interleave): Likewise.
15415 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
15416 (rs6000_expand_interleave): Likewise.
15417
15418 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15419
15420 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
15421 to qimode could truncate the indices.
15422 * optabs.c (expand_vec_perm_var): Likewise.
15423
15424 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15425
15426 * Makefile.in (OBJS): Add vec-perm-indices.o.
15427 * vec-perm-indices.h: New file.
15428 * vec-perm-indices.c: Likewise.
15429 * target.h (vec_perm_indices): Replace with a forward class
15430 declaration.
15431 (auto_vec_perm_indices): Move to vec-perm-indices.h.
15432 * optabs.h: Include vec-perm-indices.h.
15433 (expand_vec_perm): Delete.
15434 (selector_fits_mode_p, expand_vec_perm_var): Declare.
15435 (expand_vec_perm_const): Declare.
15436 * target.def (vec_perm_const_ok): Replace with...
15437 (vec_perm_const): ...this new hook.
15438 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
15439 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
15440 * doc/tm.texi: Regenerate.
15441 * optabs.def (vec_perm_const): Delete.
15442 * doc/md.texi (vec_perm_const): Likewise.
15443 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
15444 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
15445 expand_vec_perm for constant permutation vectors. Assert that
15446 the mode of variable permutation vectors is the integer equivalent
15447 of the mode that is being permuted.
15448 * optabs-query.h (selector_fits_mode_p): Declare.
15449 * optabs-query.c: Include vec-perm-indices.h.
15450 (selector_fits_mode_p): New function.
15451 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
15452 is defined, instead of checking whether the vec_perm_const_optab
15453 exists. Use targetm.vectorize.vec_perm_const instead of
15454 targetm.vectorize.vec_perm_const_ok. Check whether the indices
15455 fit in the vector mode before using a variable permute.
15456 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
15457 vec_perm_indices instead of an rtx.
15458 (expand_vec_perm): Replace with...
15459 (expand_vec_perm_const): ...this new function. Take the selector
15460 as a vec_perm_indices rather than an rtx. Also take the mode of
15461 the selector. Update call to shift_amt_for_vec_perm_mask.
15462 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
15463 Use vec_perm_indices::new_expanded_vector to expand the original
15464 selector into bytes. Check whether the indices fit in the vector
15465 mode before using a variable permute.
15466 (expand_vec_perm_var): Make global.
15467 (expand_mult_highpart): Use expand_vec_perm_const.
15468 * fold-const.c: Includes vec-perm-indices.h.
15469 * tree-ssa-forwprop.c: Likewise.
15470 * tree-vect-data-refs.c: Likewise.
15471 * tree-vect-generic.c: Likewise.
15472 * tree-vect-loop.c: Likewise.
15473 * tree-vect-slp.c: Likewise.
15474 * tree-vect-stmts.c: Likewise.
15475 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
15476 Delete.
15477 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
15478 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
15479 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
15480 (aarch64_vectorize_vec_perm_const): ...this new function.
15481 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
15482 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15483 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
15484 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
15485 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
15486 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15487 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
15488 into...
15489 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
15490 check for NEON modes.
15491 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
15492 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
15493 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
15494 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
15495 into...
15496 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
15497 the old VEC_PERM_CONST conditions.
15498 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
15499 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
15500 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
15501 (ia64_vectorize_vec_perm_const_ok): Merge into...
15502 (ia64_vectorize_vec_perm_const): ...this new function.
15503 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
15504 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
15505 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
15506 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
15507 * config/mips/mips.c (mips_expand_vec_perm_const)
15508 (mips_vectorize_vec_perm_const_ok): Merge into...
15509 (mips_vectorize_vec_perm_const): ...this new function.
15510 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
15511 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
15512 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
15513 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
15514 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
15515 (rs6000_expand_vec_perm_const): Delete.
15516 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
15517 Delete.
15518 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15519 (altivec_expand_vec_perm_const_le): Take each operand individually.
15520 Operate on constant selectors rather than rtxes.
15521 (altivec_expand_vec_perm_const): Likewise. Update call to
15522 altivec_expand_vec_perm_const_le.
15523 (rs6000_expand_vec_perm_const): Delete.
15524 (rs6000_vectorize_vec_perm_const_ok): Delete.
15525 (rs6000_vectorize_vec_perm_const): New function.
15526 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
15527 an element count and rtx array.
15528 (rs6000_expand_extract_even): Update call accordingly.
15529 (rs6000_expand_interleave): Likewise.
15530 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
15531 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
15532 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
15533 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
15534 (rs6000_expand_vec_perm_const): Delete.
15535 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
15536 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15537 (altivec_expand_vec_perm_const_le): Take each operand individually.
15538 Operate on constant selectors rather than rtxes.
15539 (altivec_expand_vec_perm_const): Likewise. Update call to
15540 altivec_expand_vec_perm_const_le.
15541 (rs6000_expand_vec_perm_const): Delete.
15542 (rs6000_vectorize_vec_perm_const_ok): Delete.
15543 (rs6000_vectorize_vec_perm_const): New function. Remove stray
15544 reference to the SPE evmerge intructions.
15545 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
15546 an element count and rtx array.
15547 (rs6000_expand_extract_even): Update call accordingly.
15548 (rs6000_expand_interleave): Likewise.
15549 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
15550 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
15551 new function.
15552 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
15553
15554 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15555
15556 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
15557 vector mode and that that mode matches the mode of the data
15558 being permuted.
15559 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
15560 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
15561 directly using expand_vec_perm_1 when forcing selectors into
15562 registers.
15563 (expand_vec_perm_var): New function, split out from expand_vec_perm.
15564
15565 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15566
15567 * optabs-query.h (can_vec_perm_p): Delete.
15568 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
15569 * optabs-query.c (can_vec_perm_p): Split into...
15570 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
15571 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
15572 particular selector is valid.
15573 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
15574 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
15575 (vect_grouped_load_supported): Likewise.
15576 (vect_shift_permute_load_chain): Likewise.
15577 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
15578 (vect_transform_slp_perm_load): Likewise.
15579 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
15580 (vectorizable_bswap): Likewise.
15581 (vect_gen_perm_mask_checked): Likewise.
15582 * fold-const.c (fold_ternary_loc): Likewise. Don't take
15583 implementations of variable permutation vectors into account
15584 when deciding which selector to use.
15585 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
15586 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
15587 with a false third argument.
15588 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
15589 to test whether the constant selector is valid and can_vec_perm_var_p
15590 to test whether a variable selector is valid.
15591
15592 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15593
15594 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
15595 * optabs-query.c (can_vec_perm_p): Likewise.
15596 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
15597 instead of vec_perm_indices.
15598 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
15599 (vect_gen_perm_mask_checked): Likewise,
15600 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
15601 (vect_gen_perm_mask_checked): Likewise,
15602
15603 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
15604
15605 * optabs-query.h (qimode_for_vec_perm): Declare.
15606 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
15607 (qimode_for_vec_perm): ...this new function.
15608 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
15609
15610 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
15611
15612 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
15613 does not have a conditional at the top.
15614
15615 2018-01-02 Richard Biener <rguenther@suse.de>
15616
15617 * ipa-inline.c (big_speedup_p): Fix expression.
15618
15619 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
15620
15621 PR target/81616
15622 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
15623 for generic 4->6.
15624
15625 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
15626
15627 PR target/81616
15628 Generic tuning.
15629 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
15630 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
15631 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
15632 cond_taken_branch_cost 3->4.
15633
15634 2018-01-01 Jakub Jelinek <jakub@redhat.com>
15635
15636 PR tree-optimization/83581
15637 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
15638 TODO_cleanup_cfg if any changes have been made.
15639
15640 PR middle-end/83608
15641 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
15642 convert_modes if target mode has the right side, but different mode
15643 class.
15644
15645 PR middle-end/83609
15646 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
15647 last argument when extracting from CONCAT. If either from_real or
15648 from_imag is NULL, use expansion through memory. If result is not
15649 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
15650 the parts directly to inner mode, if even that fails, use expansion
15651 through memory.
15652
15653 PR middle-end/83623
15654 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
15655 check for bswap in mode rather than HImode and use that in expand_unop
15656 too.
15657 \f
15658 Copyright (C) 2018 Free Software Foundation, Inc.
15659
15660 Copying and distribution of this file, with or without modification,
15661 are permitted in any medium without royalty provided the copyright
15662 notice and this notice are preserved.
This page took 0.725851 seconds and 6 git commands to generate.