1 2018-10-01 Carl Love <cel@us.ibm.com>
4 * config/rs6000/rs6000-builtin.def (__builtin_mffsl): New.
5 (__builtin_mtfsb0): New.
6 (__builtin_mtfsb1): New.
7 ( __builtin_set_fpscr_rn): New.
8 (__builtin_set_fpscr_drn): New.
9 * config/rs6000/rs6000.c (rs6000_expand_mtfsb_builtin): Add.
10 (rs6000_expand_set_fpscr_rn_builtin): Add.
11 (rs6000_expand_set_fpscr_drn_builtin): Add.
12 (rs6000_expand_builtin): Add case statement entries for
13 RS6000_BUILTIN_MTFSB0, RS6000_BUILTIN_MTFSB1,
14 RS6000_BUILTIN_SET_FPSCR_RN, RS6000_BUILTIN_SET_FPSCR_DRN,
16 (rs6000_init_builtins): Add ftype initialization and def_builtin
17 calls for __builtin_mffsl, __builtin_mtfsb0, __builtin_mtfsb1,
18 __builtin_set_fpscr_rn, __builtin_set_fpscr_drn.
19 * config/rs6000.md (rs6000_mtfsb0, rs6000_mtfsb1, rs6000_mffscrn,
20 rs6000_mffscdrn): Add define_insn.
21 (rs6000_set_fpscr_rn, rs6000_set_fpscr_drn): Add define_expand.
22 * doc/extend.texi: Add documentation for the builtins.
24 2018-10-01 Richard Biener <rguenther@suse.de>
26 PR tree-optimization/87465
27 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
28 causing branch miscounts.
30 2018-10-01 Tamar Christina <tamar.christina@arm.com>
32 * common/config/aarch64/aarch64-common.c (TARGET_OPTION_DEFAULT_PARAM,
33 aarch64_option_default_param): New.
35 (TARGET_OPTION_VALIDATE_PARAM, aarch64_option_validate_param): New.
36 * config/aarch64/aarch64.c (aarch64_override_options_internal): Simplify
37 stack-clash protection validation code.
39 2018-10-01 Tamar Christina <tamar.christina@arm.com>
41 * params.c (validate_param): New.
43 (set_param_value): Refactor param validation into validate_param.
44 (diagnostic.h): Include.
45 * diagnostic.h (diagnostic_ready_p): New.
47 2018-10-01 Tamar Christina <tamar.christina@arm.com>
49 * params.c (set_param_value):
50 Add index of parameter being validated.
51 * common/common-target.def (option_validate_param): New.
52 * common/common-targhooks.h (default_option_validate_param): New.
53 * common/common-targhooks.c (default_option_validate_param): New.
54 * doc/tm.texi.in (TARGET_OPTION_VALIDATE_PARAM): New.
55 * doc/tm.texi: Regenerate.
57 2018-10-01 Tamar Christina <tamar.christina@arm.com>
60 * config/aarch64/aarch64.c (aarch64_override_options_internal):
61 Add validation for stack-clash parameters and set defaults.
63 2018-10-01 Tamar Christina <tamar.christina@arm.com>
66 * configure.ac: Add stack-clash-protection-guard-size.
67 * doc/install.texi: Document it.
68 * config.in (DEFAULT_STK_CLASH_GUARD_SIZE): New.
69 * params.def: Update comment for guard-size.
70 (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE,
71 PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Update description.
72 * configure: Regenerate.
74 2018-10-01 Tamar Christina <tamar.christina@arm.com>
77 * config/aarch64/aarch64.h (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS,
78 STACK_DYNAMIC_OFFSET): New.
79 * config/aarch64/aarch64.c (aarch64_layout_frame):
80 Update outgoing args size.
81 (aarch64_stack_clash_protection_alloca_probe_range,
82 TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
84 2018-10-01 Tamar Christina <tamar.christina@arm.com>
87 * explow.c (anti_adjust_stack_and_probe_stack_clash): Support custom
89 * target.def (stack_clash_protection_alloca_probe_range): New.
90 (stack_clash_protection_final_dynamic_probe): Remove.
91 * targhooks.h (default_stack_clash_protection_alloca_probe_range) New.
92 (default_stack_clash_protection_final_dynamic_probe): Remove.
93 * targhooks.c: Likewise.
94 * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
95 (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE): Remove.
96 * doc/tm.texi: Regenerate.
98 2018-10-01 Tamar Christina <tamar.christina@arm.com>
101 * config/aarch64/aarch64-protos.h (aarch64_output_probe_sve_stack_clash): New.
102 * config/aarch64/aarch64.c (aarch64_output_probe_sve_stack_clash,
103 aarch64_clamp_to_uimm12_shift): New.
104 (aarch64_allocate_and_probe_stack_space): Add SVE specific section.
105 * config/aarch64/aarch64.md (probe_sve_stack_clash): New.
107 2018-10-01 Tamar Christina <tamar.christina@arm.com>
110 * config/aarch64/aarch64.c (aarch64_layout_frame): Add assert.
112 2018-10-01 Jeff Law <law@redhat.com>
113 Richard Sandiford <richard.sandiford@linaro.org>
114 Tamar Christina <tamar.christina@arm.com>
117 * config/aarch64/aarch64.md
118 (probe_stack_range): Add k (SP) constraint.
119 * config/aarch64/aarch64.h (STACK_CLASH_CALLER_GUARD,
120 STACK_CLASH_MAX_UNROLL_PAGES): New.
121 * config/aarch64/aarch64.c (aarch64_output_probe_stack_range): Emit
122 stack probes for stack clash.
123 (aarch64_allocate_and_probe_stack_space): New.
124 (aarch64_expand_prologue): Use it.
125 (aarch64_expand_epilogue): Likewise and update IP regs re-use criteria.
126 (aarch64_sub_sp): Add emit_move_imm optional param.
128 2018-10-01 MCC CS <deswurstes@users.noreply.github.com>
130 PR tree-optimization/87261
131 * match.pd: Remove trailing whitespace.
132 Add (x & y) | ~(x | y) -> ~(x ^ y),
133 (~x | y) ^ (x ^ y) -> x | ~y and (x ^ y) | ~(x | y) -> ~(x & y)
135 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
137 * config/arc/arc.md (*add_n): Clean up pattern, update instruction
139 (ashlsi3_insn): Update instruction constraints.
140 (ashrsi3_insn): Likewise.
142 (add_shift): Likewise.
143 * config/arc/constraints.md (Csz): New 32 bit constraint. It
144 avoids placing in the limm field small constants which, otherwise,
145 could end into a small instruction.
147 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
149 * config/arc/arc.md (maddsidi4_split): Don't use dmac if the
150 destination register is not odd-even.
151 (umaddsidi4_split): Likewise.
153 2018-10-01 Richard Biener <rguenther@suse.de>
155 * tree-inline.c (expand_call_inline): Store origin of fn
156 in BLOCK_ABSTRACT_ORIGIN for the inline BLOCK.
157 * tree.c (block_ultimate_origin): Simplify and do some
160 2018-09-30 Uros Bizjak <ubizjak@gmail.com>
162 * config/i386/mmx.md (EMMS): New int iterator.
163 (emms): New int attribute.
164 (mmx_<emms>): Macroize insn from *mmx_emms and *mmx_femms using
165 EMMS int iterator. Explicitly declare clobbers.
166 (mmx_emms): Remove expander.
168 * config/i386/predicates.md (emms_operation): Remove predicate.
169 (vzeroall_pattern): New predicate.
170 (vzeroupper_pattern): Rename from vzeroupper_operation.
171 * config/i386/i386.c (ix86_avx_u128_mode_after): Use
172 vzeroupper_pattern and vzeroall_pattern predicates.
174 2018-09-30 Peter Bergner <bergner@linux.ibm.com>
176 PR rtl-optimization/86939
177 * ira-lives.c (make_hard_regno_born): Rename from this...
178 (make_hard_regno_live): ... to this. Remove update to conflict
179 information. Update function comment.
180 (make_hard_regno_dead): Add conflict information update. Update
182 (make_object_born): Rename from this...
183 (make_object_live): ... to this. Remove update to conflict information.
184 Update function comment.
185 (make_object_dead): Add conflict information update. Update function
187 (mark_pseudo_regno_live): Call make_object_live.
188 (mark_pseudo_regno_subword_live): Likewise.
189 (mark_hard_reg_dead): Update function comment.
190 (mark_hard_reg_live): Call make_hard_regno_live.
191 (process_bb_node_lives): Likewise.
192 * lra-lives.c (make_hard_regno_born): Rename from this...
193 (make_hard_regno_live): ... to this. Remove update to conflict
194 information. Remove now uneeded check_pic_pseudo_p argument.
195 Update function comment.
196 (make_hard_regno_dead): Add check_pic_pseudo_p argument and add update
197 to conflict information. Update function comment.
198 (mark_pseudo_live): Remove update to conflict information. Update
200 (mark_pseudo_dead): Add conflict information update.
201 (mark_regno_live): Call make_hard_regno_live.
202 (mark_regno_dead): Call make_hard_regno_dead with new arguement.
203 (process_bb_lives): Call make_hard_regno_live and make_hard_regno_dead.
205 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
208 * config/i386/i386.c (construct_container): Use TImode for
209 BLKmode values in 2 integer registers.
211 2018-09-29 Jeff Law <law@redhat.com>
213 * builtins.c (unterminated_array): Pass in c_strlen_data * to
214 c_strlen rather than just a tree *.
215 (c_strlen): Change NONSTR argument to a c_strlen_data pointer.
216 Update recursive calls appropriately. If caller did not provide a
217 suitable data pointer, create a local one. When a non-terminated
218 string is discovered, bubble up information about the string via the
219 c_strlen_data object.
220 * builtins.h (c_strlen): Update prototype.
221 (c_strlen_data): New structure.
222 * gimple-fold.c (get_range_strlen): Update calls to c_strlen.
223 For a type 2 call, if c_strlen indicates a non-terminated string
224 use the length of the non-terminated string.
225 (gimple_fold_builtin_stpcpy): Update calls to c_strlen.
227 2018-09-29 Jakub Jelinek <jakub@redhat.com>
230 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
231 __m512d type for __A argument rather than __m512.
233 2018-09-28 John David Anglin <danglin@gcc.gnu.org>
235 * match.pd (simple_comparison): Don't optimize if either operand is
236 a function pointer when target needs function pointer canonicalization.
238 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
240 * config/rs6000/driver-rs6000.c (asm_names): Adjust the entries for
241 power5 .. power9 to remove indirection.
242 * config/rs6000/rs6000.h (ASM_CPU_POWER5_SPEC, ASM_CPU_POWER6_SPEC,
243 ASM_CPU_POWER7_SPEC, ASM_CPU_POWER8_SPEC, ASM_CPU_POWER9_SPEC,
244 ASM_CPU_476_SPEC): Delete.
245 (ASM_CPU_SPEC): Adjust.
246 (EXTRA_SPECS): Delete asm_cpu_power5, asm_cpu_power6, asm_cpu_power7,
247 asm_cpu_power8, asm_cpu_power9, asm_cpu_476.
249 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
251 * config.in: Delete HAVE_AS_DCI.
252 * config/powerpcspe/powerpcspe.h: Treat HAVE_AS_DCI as always true.
253 * config/rs6000/rs6000.h: Ditto.
254 * configure.ac: Delete HAVE_AS_DCI.
255 * configure: Regenerate.
257 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
259 * config.in (HAVE_AS_LWSYNC): Delete.
260 * config/powerpcspe/powerpcspe.h (TARGET_LWSYNC_INSTRUCTION): Delete.
261 * config/powerpcspe/sync.md (*lwsync): Always generate lwsync, never
263 * config/rs6000/rs6000.h (TARGET_LWSYNC_INSTRUCTION): Delete.
264 * config/rs6000/sync.md (*lwsync): Always generate lwsync, never do it
266 * configure.ac: Delete HAVE_AS_LWSYNC.
267 * configure: Regenerate.
269 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
270 Pierre-Marie de Rodat <derodat@adacore.com>
272 * calls.c (expand_call): Try to do a tail call for thunks at -O0 too.
273 * cgraph.h (struct cgraph_thunk_info): Add indirect_offset.
274 (cgraph_node::create_thunk): Add indirect_offset parameter.
275 (thunk_adjust): Likewise.
276 * cgraph.c (cgraph_node::create_thunk): Add indirect_offset parameter
277 and initialize the corresponding field with it.
278 (cgraph_node::dump): Dump indirect_offset field.
279 * cgraphclones.c (duplicate_thunk_for_node): Deal with indirect_offset.
280 * cgraphunit.c (cgraph_node::analyze): Be prepared for external thunks.
281 (thunk_adjust): Add indirect_offset parameter and deal with it.
282 (cgraph_node::expand_thunk): Deal with the indirect_offset field and
283 pass it to thunk_adjust. Do not call the target hook if it's non-zero
284 or if the thunk is external or local. Fix formatting. Do not chain
285 the RESULT_DECL to BLOCK_VARS. Pass the static chain to the target,
286 if any, in the GIMPLE representation.
287 * ipa-icf.c (sem_function::equals_wpa): Deal with indirect_offset.
288 * lto-cgraph.c (lto_output_node): Write indirect_offset field.
289 (input_node): Read indirect_offset field.
290 * tree-inline.c (expand_call_inline): Pass indirect_offset field in the
291 call to thunk_adjust.
292 * tree-nested.c (struct nesting_info): Add thunk_p field.
293 (create_nesting_tree): Set it.
294 (convert_all_function_calls): Copy static chain from targets to thunks.
295 (finalize_nesting_tree_1): Return early for thunks.
296 (unnest_nesting_tree_1): Do not finalize thunks.
297 (gimplify_all_functions): Do not gimplify thunks.
299 2018-09-28 David Malcolm <dmalcolm@redhat.com>
301 * opt-suggestions.c (option_proposer::build_option_suggestions):
302 Release "option_values".
304 2018-09-28 David Malcolm <dmalcolm@redhat.com>
306 * coverage.c (get_coverage_counts): Convert problem-reporting dump
307 messages from MSG_OPTIMIZED_LOCATIONS to MSG_MISSED_OPTIMIZATION.
308 * dumpfile.c (kind_as_string): New function.
309 (dump_loc): Rather than a hardcoded prefix of "note: ", use
310 kind_as_string to vary the prefix based on dump_kind.
311 (selftest::test_capture_of_dump_calls): Update for above.
313 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
315 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
316 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
318 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
320 * config/i386/i386.h (CC_REGNO): Remove FPSR_REG.
321 * config/i386/i386.c (ix86_fixed_condition_code_regs): Use
322 INVALID_REGNUM instead of FPSR_REG.
323 (ix86_md_asm_adjust): Do not clobber FPSR_REG.
324 * config/i386/i386.md: Update comment of FP compares.
325 (fldenv): Do not clobber FPSR_REG.
327 2018-09-28 Richard Biener <rguenther@suse.de>
329 * tree.h (BLOCK_ORIGIN): New.
330 * omp-expand.c (grid_expand_target_grid_body): Assign
331 BLOCK_ORIGIN to BLOCK_ABSTRACT_ORIGIN.
332 * tree-inline.c (remap_block): Likewise.
333 * auto-profile.c (get_function_decl_from_block): Simplify
334 by eliding the BLOCK_ABSTRACT_ORIGIN chasing.
335 * langhooks.c (lhd_print_error_function): Likewise.
336 * optinfo-emit-json.cc (optrecord_json_writer::inlining_chain_to):
338 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
339 * tree.c (block_nonartificial_location): Likewise.
340 (block_ultimate_origin): Likewise.
341 * tree-pretty-print.c (percent_K_format): Likewise. Remove
342 no longer needed LTO case.
344 2018-09-28 Andrew Stubbs <ams@codesourcery.com>
345 Jan Hubicka <jh@suse.cz>
346 Martin Jambor <mjambor@suse.cz>
348 * simplify-rtx.c (simplify_merge_mask): New function.
349 (simplify_ternary_operation): Use it, also see if VEC_MERGEs with the
350 same masks are used in op1 or op2.
351 (test_vec_merge): New function.
352 (test_vector_ops): Call test_vec_merge.
354 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
356 * config/sparc/sparc-protos.h (sparc_branch_cost): Declare.
357 * config/sparc/sparc.h (BRANCH_COST): Call sparc_branch_cost.
358 * config/sparc/sparc.c (struct processor_costs): Add branch_cost field.
359 (cypress_costs): Set it.
360 (supersparc_costs): Likewise.
361 (hypersparc_costs): Likewise.
362 (leon_cost): Likewise.
363 (leon3_costs): Likewise.
364 (sparclet_costs): Likewise.
365 (ultrasparc_costs): Likewise.
366 (ultrasparc_costs): Likewise.
367 (niagara_costs): Likewise.
368 (niagara2_costs): Likewise.
369 (niagara3_costs): Likewise.
370 (niagara4_costs): Likewise.
371 (niagara7_costs): Likewise.
372 (m8_costs): Likewise.
373 (TARGET_CAN_FOLLOW_JUMP): Define.
374 (pass_work_around_errata::gate): Minor tweak.
375 (sparc_option_override): Remove MASK_FSMULD mask for V7 processors.
376 Do not set both MASK_VIS4 and MASK_VIS4B for M8 processor.
377 Automaitcally clear MASK_FSMULD mask for V7 processors.
378 (sparc_can_follow_jump): New static function.
379 (output_ubranch): Deal with CROSSING_JUMP_P.
380 (sparc_use_sched_lookahead): Rewrite using switch statement.
381 (sparc_issue_rate): Reorder.
382 (sparc_branch_cost): New function.
384 2018-09-27 Martin Sebor <msebor@redhat.com>
386 * tree.h (tree_to_shwi): Add attribute nonnull and pure.
387 (tree_to_poly_int64, tree_to_uhwi, tree_to_poly_uint64): Same.
388 (int_fits_type_p): Same.
390 2018-09-27 Uros Bizjak <ubizjak@gmail.com>
392 * config/i386/i386.md (FPCR_REG): Remove.
393 (UNSPEC_FLDCW): Remove.
394 (x86_fnstcw_1): Use (const_int 0) instead of FPCR_REG.
395 (x86_fldcw_1): Remove insn pattern.
396 (fnstenv): Do not clobber FPCR_REG.
398 * config/i386/i386.h (FIXED_REGISTERS) Remove fpsr register.
399 (CALL_USED_REGISTERS): Ditto.
400 (REG_ALLOC_ORDER): Ditto.
401 (REG_CLASS_CONTENTS): Ditto.
402 (HI_REGISTER_NAMES): Ditto.
403 (ADDITIONAL_REGISTER_NAMES): Use defines instead
404 of numerical constants.
405 * config/i386/i386.c (regclass_map): Remove fpsr register.
406 (dbx_register_map): Ditto.
407 (dbx64_register_map): Ditto.
408 (svr4_dbx_register_map): Ditto.
409 (print_reg): Do not handle FPCR_REG.
411 2018-09-27 Segher Boessenkool <segher@kernel.crashing.org>
414 * config.in (HAVE_AS_CMPB, HAVE_AS_DFP, HAVE_AS_FPRND, HAVE_AS_MFPGPR,
415 HAVE_AS_POPCNTB, HAVE_AS_POPCNTD, HAVE_AS_POWER8, HAVE_AS_POWER9):
416 Delete, always treat as true.
417 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
418 Ditto. Simplify remaining code.
419 * config/powerpcspe/powerpcspe.h: Ditto.
420 * config/rs6000/rs6000.c (rs6000_option_override_internal): Ditto.
421 Simplify remaining code.
422 (rs6000_expand_builtin): Ditto.
423 * config/rs6000/rs6000.h: Ditto.
424 * configure.ac: Ditto.
425 * configure: Regenerate.
427 2018-09-27 Martin Liska <mliska@suse.cz>
429 * coverage.c (get_coverage_counts): Revert the formatting
430 of missing profile opt info.
432 2018-09-27 Richard Biener <rguenther@suse.de>
436 * dwarf2out.c (set_block_origin_self): Do not mark outermost
437 block as we do not output that.
438 (gen_inlined_subroutine_die): Elide the originally outermost
439 block, matching what we do for concrete instances.
440 (decls_for_scope): Add parameter specifying whether to recurse
443 2018-09-27 Andrew Stubbs <ams@codesourcery.com>
444 Tom de Vries <tom@codesourcery.com>
448 * expmed.c (emit_cstore): Fix handling of result_mode == BImode and
449 STORE_FLAG_VALUE == 1.
451 2018-09-27 Andreas Krebbel <krebbel@linux.ibm.com>
453 * config/s390/s390.md (PPA_TX_ABORT, PPA_OOO_BARRIER): New
454 constant definitions.
455 ("tx_assist"): Replace magic number with PPA_TX_ABORT.
456 ("*ppa"): Enable pattern also for -march=zEC12 -mno-htm.
457 ("speculation_barrier"): New expander definition.
459 2018-09-26 Indu Bhagat <indu.bhagat@oracle.com>
461 PR gcov-profile/86957
462 * common.opt: New warning option -Wmissing-profile.
463 * coverage.c (get_coverage_counts): Add warning for missing .gcda file.
464 * doc/invoke.texi: Document -Wmissing-profile.
466 2018-09-26 Jim Wilson <jimw@sifive.com>
468 * config/riscv/riscv.md (subsi3_extended2): Add J constraint.
469 (negdi2, negsi2, negsi2_extended, negsi2_extended2): New.
471 2018-09-26 Martin Sebor <msebor@redhat.com>
473 * tree.c (zerop): Change return type to bool.
474 (integer_zerop, integer_onep, integer_each_onep): Same.
475 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
476 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
477 (real_onep, real_minus_onep, chain_index): Same.
478 (print_type_hash_statistics, type_list_equal): Same.
479 * tree.h (zerop): Same.
480 (zerop, integer_zerop, integer_onep, integer_each_onep): Same.
481 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
482 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
483 (real_onep, real_minus_onep, chain_index): Same.
484 (print_type_hash_statistics, type_list_equal): Same.
486 2018-09-26 Jim Wilson <jimw@sifive.com>
488 * config/riscv/riscv.h (FUNCTION_ARG_REGNO_P): Fix comment.
490 2018-09-26 Jakub Jelinek <jakub@redhat.com>
493 * config/i386/i386.c: Include debug.h and dwarf2out.h.
494 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
497 2018-09-25 Andrew Stubbs <ams@codesourcery.com>
499 * builtins.c (get_builtin_sync_mem): Force address mode conversion.
501 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
503 * config/i386/i386.h (enum reg_class): Remove FP_TOP_SSE_REGS
504 and FP_SECOND_SSE_REGS.
505 (REG_CLASS_NAMES): Ditto.
506 (REG_CLASS_CONTENTS): Ditto.
507 * config/i386/i386.c (ix86_preferred_reload_class) Do not handle
508 FP_TOP_SSE_REGS and FP_SECOND_SSE_REGS classes.
509 (ix86_preferred_output_reload_class): Ditto.
510 * config/i386/i386.md (fix_trunc<mode>_i387_fisttp): Change "=&1f"
511 clobber constraint to "=&f".
512 (fix_truncdi_i387): Ditto.
514 (fistdi2_<rounding>): Ditto.
515 (fpremxf4_i387): Change "=u" constraint to "=f".
516 (fprem1xf4_i387): Ditto.
518 (fptanxf4_i387): Ditto.
519 (fxtractxf3_i387): Ditto.
520 (fscalexf4_i387): Ditto.
521 (atan2xf3): Change "u" constraint to "f".
522 (fyl2xxf3_i387): Ditto.
523 (fyl2xp1xf3_i387): Ditto.
525 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
528 * config/i386/i386.h (NUM_MODES_FOR_MODE_SWITCHING): Update
529 for removed I387_MASK_PM entity.
532 2018-09-26 Jeff Law <law@redhat.com>
534 2018-09-26 Alexey Neyman <stilor@att.net>
536 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
537 headers are no longer pulled in by <isl/val.h>.
539 2018-09-26 Richard Biener <rguenther@suse.de>
542 * dwarf2out.c (gen_lexical_block_die): Do not equate inline
543 or concrete instance DIE to the tree. Create abstract origin
544 attributes also for concrete instances.
546 2018-09-26 Alexey Neyman <stilor@att.net>
548 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
549 headers are no longer pulled in by <isl/val.h>.
551 2018-09-26 Matthew Malcomson <matthew.malcomson@arm.com>
553 * config/arm/arm.c (arm_split_compare_and_swap, arm_split_atomic_op):
554 Use new helper functions.
555 * config/arm/sync.md (atomic_load<mode>, atomic_store<mode>):
556 Use new helper functions.
557 * config/arm/aarch-common-protos.h (aarch_mm_needs_acquire,
558 aarch_mm_needs_release): New declarations.
559 * config/arm/aarch-common.c (aarch_mm_needs_acquire,
560 aarch_mm_needs_release): New.
562 2018-09-26 Eric Botcazou <ebotcazou@adacore.com>
564 * config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
565 (arm32_output_mi_thunk): Deal with long calls.
567 2018-09-26 Richard Biener <rguenther@suse.de>
571 * tree-inline.c (expand_call_inline): When the location
572 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
573 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
574 the inserted BLOCK to make inlined_function_outer_scope_p
576 * dwarf2out.c (add_call_src_coords_attributes): Do not add
577 coords for reserved locations.
579 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
581 * config/rs6000/rs6000.md (*movcc_internal1): Use set_attr_alternative.
582 (*call_indirect_nonlocal_sysv<mode>): Ditto.
583 (*call_value_indirect_nonlocal_sysv<mode>): Ditto.
584 (*sibcall_nonlocal_sysv<mode>): Ditto.
585 (*sibcall_value_nonlocal_sysv<mode>): Ditto.
586 (<bd>_<mode>): Ditto.
587 (<bd>tf_<mode>): Ditto.
589 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
591 * config/rs6000/altivec.md (*altivec_mov<mode>): Write the output
592 control string as a list of templates instead of as C code.
593 (*altivec_movti): Ditto.
594 * config/rs6000/darwin.md (movdf_low_di): Ditto.
596 2018-09-25 Jim Wilson <jimw@sifive.com>
598 * config/riscv/riscv.c (riscv_split_symbol): Mark auipc label as weak
599 when target symbol is weak.
601 2018-09-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
604 * builtins.c (unterminated_array): Simplify.
605 * expr.c (string_constant): Handle SSA_NAME. Add more exceptions
606 where pointer arithmetic is safe.
608 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
611 * config/rs6000/altivec.md (altivec_vspltb): Use
612 const_0_to_15_operand instead of u5bit_cint_operand.
613 (*altivec_vspltb_internal): Ditto.
614 (altivec_vspltb_direct): Ditto.
615 (altivec_vsplth): Use const_0_to_7_operand instead of
617 (*altivec_vsplth_internal): Ditto.
618 (altivec_vsplth_direct): Ditto.
619 (altivec_vspltw): Use const_0_to_3_operand instead of
621 (*altivec_vspltw_internal): Ditto.
622 (altivec_vspltw_direct): Ditto.
623 (altivec_vspltsf): Ditto.
624 (*altivec_vspltsf_internal): Ditto.
625 * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Handle the
626 various splats with the proper size immediate. Reorder the various
627 cases by ascending size of immediate, and put all such together.
629 2018-09-25 Richard Biener <rguenther@suse.de>
632 * dwarf2out.c (add_AT_external_die_ref): Remove now redundant
634 (maybe_create_die_with_external_ref): Do not create
635 DW_TAG_imported_unit here.
636 (add_abstract_origin_attribute): Handle external BLOCK refs.
637 (dwarf2out_abstract_function): Simplify LTO case.
638 (dwarf2out_early_finish): Create DW_TAG_imported_unit explicitely
639 rather than using maybe_create_die_with_external_ref.
641 2018-09-25 Uros Bizjak <ubizjak@gmail.com>
644 * config/i386/i386.md (frndintxf2_mask_pm): Remove.
645 (frndintxf2_mask_pm_i387): Ditto.
646 (nearbyintxf2): Rewrite expander pattern to match rintxf2.
647 Enable for !flag_trapping_math.
648 (nearbyint<mode>2): Enable x87 modes for !flag_trapping_math.
649 Enable SSE modes for TARGET_SSE4_1 and expand them with round insn.
650 Change operand 1 predicate to nonimmediate_operand.
651 (attr "i387_cw"): Remove mask_pm.
652 * config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_CW_MASK_PM.
653 (enum ix86_entity): Remove I387_MASK_PM.
654 * config/i386/i386.c (ix86_i387_mode_needed): Do not
656 (ix86_mode_needed): Ditto.
657 (ix86_mode_after): Ditto.
658 (ix86_mode_entry): Ditto.
659 (ix86_mode_exit): Ditto.
660 (emit_i387_cw_initialization): Do not handle I387_CW_MASK_PM.
662 2018-09-25 Jakub Jelinek <jakub@redhat.com>
664 * vr-values.c (vr_values::vr_values): Initialize to_remove_edges and
665 to_update_switch_stmts to vNULL instead of calling create on them
668 2018-09-25 Richard Biener <rguenther@suse.de>
670 PR tree-optimization/87402
671 * tree-ssa-sccvn.c (SSA_VISITED): Remove unused function.
672 (visit_phi): Re-instantiate handling of supposed to be VARYING
673 but non-VARYING backedge value.
675 2018-09-25 Richard Biener <rguenther@suse.de>
678 * dwarf2out.c (struct sym_off_pair): New.
679 (external_die_map): New global.
680 (lookup_decl_die): When in LTO create DIEs lazily from the
682 (lookup_block_die): New function, create DIEs lazily in LTO.
683 (equate_block_to_die): New function.
684 (dwarf2out_die_ref_for_decl): During WPA get the association
685 from the external DIE map.
686 (dwarf2out_register_external_die): Record mapping into the
688 (maybe_create_die_with_external_ref): New function split out from
689 DIE generation part of old dwarf2out_register_external_die.
690 (add_abstract_origin_attribute): Do not return the DIE. When
691 in LTO reference externals directly.
692 (dwarf2out_abstract_function): When in LTO ignore calls for
693 decls with external DIEs (already present abstract instances).
694 (gen_call_site_die): Adjust.
695 (add_high_low_attributes): Likewise.
696 (gen_lexical_block_die): Likewise.
697 (gen_inlined_subroutine_die): Likewie.
698 (gen_block_die): Likewise.
699 (dwarf2out_inline_entry): Likewise.
700 (dwarf2out_early_finish): In LTRANS phase create DW_TAG_imported_unit
703 2018-09-25 Martin Liska <mliska@suse.cz>
705 * ipa-fnsummary.c (estimate_node_size_and_time): Scale by two
706 integers and not by a float value.
708 2018-09-25 Martin Liska <mliska@suse.cz>
711 * dbgcnt.c (dbg_cnt_process_single_pair): Return false
713 * dumpfile.c (dump_enable_all): Remove extra parenthesis.
714 * gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
715 * godump.c (go_format_type): Remove extra parenthesis.
717 2018-09-25 Martin Liska <mliska@suse.cz>
719 * alias.c (set_dest_equal_p): Remove unused function.
720 * config/i386/i386.c (def_builtin_pure2): Likewise.
721 * diagnostic-show-locus.c (class layout): Remove
723 (layout::layout): Likewise here.
724 * dump-context.h (class temp_dump_context): Likewise.
725 * dwarf2out.c (add_AT_fde_ref): Remove unused function.
726 (add_AT_loclistsptr): Likewise.
727 (add_AT_offset): Likewise.
728 (get_AT_hi_pc): Likewise.
729 (is_comdat_die): Likewise.
730 (type_is_enum): Likewise.
732 (add_AT_vms_delta): Likewise.
733 (is_class_die): Likewise.
734 * edit-context.c (class line_event): Remove unused field.
735 * graphite-sese-to-poly.c (tree_int_to_gmp): Remove
737 * ipa-cp.c (ipa_get_vr_lat): Likewise.
738 * lra-constraints.c (ok_for_index_p_nonstrict): Likewise.
739 (ok_for_base_p_nonstrict): Likewise.
740 * tree-chrec.c (is_not_constant_evolution): Likewise.
741 (chrec_fold_poly_cst): Likewise.
742 * tree-if-conv.c (has_pred_critical_p): Likewise.
743 * tree-ssa-coalesce.c (print_exprs): Likewise.
744 * tree-ssa-pre.c (bitmap_set_contains_expr): Likewise.
745 * tree-ssa-uninit.c (is_and_or_or_p): Likewise.
746 * tree-vrp.c (value_ranges_intersect_p): Likewise.
747 (value_range_nonnegative_p): Likewise.
749 2018-09-25 Martin Liska <mliska@suse.cz>
751 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
752 Do not handle "GNU Pascal".
753 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
755 * config/sparc/sparc.c (sparc_pass_by_reference): Remove Pascal
756 from documentation. Likewise.
757 * dbxout.c (dbxout_range_type): Likewise.
758 * doc/cpp.texi: Likewise.
759 * doc/extend.texi: Likewise.
760 * doc/frontends.texi: Likewise.
761 * doc/invoke.texi: Remove Pascal entry.
762 * tree.def (CLEANUP_POINT_EXPR): Likewise.
763 * doc/rtl.texi (MODE_FUNCTION): Remove not used entry.
765 2018-09-25 Martin Liska <mliska@suse.cz>
768 * doc/invoke.texi: Document all parameters and remove default
771 2018-09-25 Ilya Leoshkevich <iii@linux.ibm.com>
774 * rtl.c (rtx_code_size): Take into account that EQ_ATTR_ALT
775 contains HOST_WIDE_INTs when computing its size.
777 2018-09-24 Jim Wilson <jimw@sifive.com>
780 * config/riscv/riscv.h (STACK_BOUNDARY): Test riscv_abi == ABI_ILP32E
782 (ABI_STACK_BOUNDARY, MAX_ARGS_IN_REGISTERS): Likewise.
784 2018-09-24 Andrew Pinski <apinski@marvell.com>
786 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
787 access prev before checking it for NULLness in the
788 AARCH64_FUSE_CMP_BRANCH case.
790 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
793 * config/i386/i386.c (rest_of_insert_endbranch): Set
794 endbr_queued_at_entrance to true and don't insert ENDBR if
795 x86_function_profiler will be called.
796 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
798 * config/i386/i386.h (machine_function): Add
799 endbr_queued_at_entrance.
801 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
803 * genattrtab.c (mk_attr_alt): Use alternative_mask.
804 (attr_rtx_1): Adjust caching to match the new EQ_ATTR_ALT field
806 (check_attr_test): Use alternative_mask.
807 (get_attr_value): Likewise.
808 (compute_alternative_mask): Use alternative_mask and XWINT.
809 (make_alternative_compare): Use alternative_mask.
810 (attr_alt_subset_p): Use XWINT.
811 (attr_alt_subset_of_compl_p): Likewise.
812 (attr_alt_intersection): Use alternative_mask and XWINT.
813 (attr_alt_union): Likewise.
814 (attr_alt_complement): Use HOST_WIDE_INT and XWINT.
815 (mk_attr_alt): Use alternative_mask and HOST_WIDE_INT.
816 (simplify_test_exp): Use alternative_mask and XWINT.
817 (write_test_expr): Use alternative_mask and XWINT, adjust bit
818 number calculation to support 64 bits. Generate code that
820 (main): Use alternative_mask.
821 * rtl.def (EQ_ATTR_ALT): Change field types from ii to ww.
823 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
826 * config/s390/s390.c (s390_emit_epilogue): Do not use PARALLEL
827 RETURN+USE when returning via %r14.
829 2018-09-24 Martin Liska <mliska@suse.cz>
831 * gcov.c (output_lines): Print colorization legend
832 for both flag_use_colors and flag_use_hotness_colors.
835 2018-09-24 Martin Liska <mliska@suse.cz>
837 * coverage.c (get_coverage_counts): Use warning_at
838 with current_function_decl location. Use %qD in warning
841 2018-09-24 Martin Liska <mliska@suse.cz>
843 * memory-block.h (memory_block_pool::release): Annotate with
844 valgrind that the memory is not accessible.
846 2018-09-24 Martin Liska <mliska@suse.cz>
849 * asan.c: Make asan_handled_variables extern.
851 * cfgexpand.c (expand_stack_vars): Make sure
852 a representative is unpoison if another
853 variable in the partition is handled by
854 use-after-scope sanitization.
856 2018-09-24 Richard Biener <rguenther@suse.de>
858 PR tree-optimization/63155
859 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
860 the worklist when the edge of the respective argument isn't
863 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
865 * config/i386/i386.h (enum reg_class): Rename MASK_REGS to
866 ALL_MASK_REGS and MASK_EVEX_REGS to MASK_REGS.
867 (MASK_CLASS_P): Update for rename.
868 (MAYBE_MASK_CLASS_P): Ditto.
869 (REG_CLASS_NAMES): Update.
870 (REG_CLASS_CONTENT): Update.
871 * config/i386/i386.c (regclass_map): Update for MASK_REG
872 and ALL_MASK_REGS rename.
873 * config/i386/constraints.md (Yk): Update for rename.
876 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
878 * config/i386/i386.h (enum reg_class): Remove
879 EVEX_SSE_REGS and MOD4_SSE_REGS.
880 (REG_CLASS_NAMES): Update.
881 (REG_CLASS_CONTENT): Update.
882 * config/i386/i386.c (regclass_map): Declare AVX-512 SSE
883 registers as ALL_SSE_REGS.
884 (ix86_additional_allocno_class_p): Remove.
885 (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Remove.
886 (ix86_register_priority): Lower priority of EVEX SSE registers.
887 Use IN_RANGE macro where appropriate.
888 (ix86_hard_regno_mode_ok): Merge AVX-5124FMAPS and
889 AVX-5124VNNIW checks.
890 (ix86_modes_tieable_p): Tie 512-bit SSE modes.
891 * config/i386/sse.md (avx5124fmaddps_4fmaddps)
892 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddps_maskz)
893 (avx5124fmaddps_4fmaddss, avx5124fmaddps_4fmaddss_mask)
894 (avx5124fmaddps_4fmaddss_maskz, avx5124fmaddps_4fnmaddps)
895 (avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddps_maskz)
896 (avx5124fmaddps_4fnmaddss, avx5124fmaddps_4fnmaddss_mask)
897 (avx5124fmaddps_4fnmaddss_maskz, avx5124vnniw_vp4dpwssd)
898 (avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssd_maskz)
899 (avx5124vnniw_vp4dpwssds, avx5124vnniw_vp4dpwssds_mask)
900 (avx5124vnniw_vp4dpwssds_maskz): Use "v" instead of "Yh" constraint.
901 * config/i386/constraints.md (Yh): Remove.
903 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
905 * config/i386/i386.c (regclass_map): Declare integer REX registers
908 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
910 * doc/service.texi (Service): Switch the fsf.org link to https.
912 2018-09-22 Chung-Ju Wu <jasonwucj@gmail.com>
915 * config/nds32/nds32.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
916 Define to speculation_safe_value_not_needed.
918 2018-09-21 Florian Weimer <fweimer@redhat.com>
921 * doc/extend.texi (Common Function Attributes): Mention that
922 noreturn suppresses tail call optimization.
924 2018-09-21 Jeff Law <law@redhat.com>
926 * gimple-ssa-evrp.c (evrp_dom_walker::cleanup): Call
927 vr_values::cleanup_edges_and_switches.
928 * tree-vrp.c (to_remove_edges, to_update_switch_stmts): Moved into
930 (identify_jump_threads): Remove EDGE_IGNORE handling.
931 (execute_vrp): Move handling of to_remove_edges and
932 to_update_switch_stmts into vr_values class member functions.
933 * tree-vrp.h (switch_update, to_remove_edges): Remove declarations.
934 (to_update_switch_stmts): Likewise.
935 * vr-values.c: Include cfghooks.h.
936 (vr_values::vr_values): Initialize to_remove_edges and
937 to_update_switch_stmts.
938 (vr_values::~vr_values): Verify to_remove_edges and
939 to_update_switch_stmts are empty.
940 (vr_values::simplify_switch_using_ranges): Set EDGE_IGNORE as needed.
941 (vr_values::cleanup_edges_and_switches): New member function.
942 * vr-values.h (vr_values): Add cleanup_edges_and_switches member
943 function. Add new data members.
945 2018-09-21 David Malcolm <dmalcolm@redhat.com>
947 PR tree-optimization/87309
948 * dumpfile.c (dump_context::begin_scope): Filter the dump_loc
949 calls with pflags and alt_flags.
950 (selftest::test_capture_of_dump_calls): Add test of interaction of
951 MSG_OPTIMIZED_LOCATIONS with AUTO_DUMP_SCOPE.
953 2018-09-21 Olivier Hainque <hainque@adacore.com>
955 * config.gcc: Factorize and comment inclusion of vxworks-dummy.h.
957 2018-09-21 Olivier Hainque <hainque@adacore.com>
959 * config/vxworks.h (CLEAR_INSN_CACHE): #define to 1.
961 2018-09-21 Olivier Hainque <hainque@adacore.com>
963 * config/vxworks.h (VXWORKS_LIBGCC_SPEC): Remove -lc_internal.
964 Merge block comment with the one ahead of VXWORKS_LIBS_RTP. Then:
965 (VXWORKS_LIBS_RTP): Minor reordering.
967 2018-09-21 Olivier Hainque <hainque@adacore.com>
969 * config/vxworks.h (STARTFILE_PREFIX_SPEC): Define.
970 (VXWORKS_LIBS_DIR_RTP): Remove definition and use.
972 2018-09-21 Olivier Hainque <hainque@adacore.com>
974 * config/vxworks.h (SIZE_TYPE): Account for TARGET_VXWORKS64.
975 (PTRDIFF_TYPE): Likewise.
977 2018-09-21 Olivier Hainque <hainque@adacore.com>
979 * config.gcc: Enforce def of TARGET_VXWORKS64 to 1 from
980 triplet, similar to support for VxWorks7.
981 * config/vxworks-dummy.h: Provide a default definition
982 of TARGET_VXWORKS64 to 0.
984 2018-09-21 Olivier Hainque <hainque@adacore.com>
986 * config/vxworks.h (TARGET_VXWORKS7): Move default definition ...
987 * config/vxworks-dummy.h: here.
989 2018-09-21 Olivier Hainque <hainque@adacore.com>
991 * config.gcc: Prepend vxworks-dummy.h to tm_file for powerpc*
993 2018-09-21 Shaokun Zhang <zhangshaokun@hisilicon.com>
994 Bo Zhou <zbo.zhou@hisilicon.com>
996 * config/aarch64/aarch64-cores.def (tsv110): New CPU.
997 * config/aarch64/aarch64-tune.md: Regenerated.
998 * doc/invoke.texi (AArch64 Options/-mtune): Add "tsv110".
999 * config/aarch64/aarch64.c (tsv110_tunings): New tuning table.
1000 * config/aarch64/aarch64-cost-tables.h: Add "tsv110" extra costs.
1002 2018-09-21 Andrew Stubbs <ams@codesourcery.com>
1003 Julian Brown <julian@codesourcery.com>
1005 * builtins.c (get_builtin_sync_mem): Handle address spaces.
1007 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
1009 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
1010 if the call takes a static chain.
1012 2018-09-21 Martin Liska <mliska@suse.cz>
1014 * auto-profile.c (autofdo_source_profile::read): Do not
1016 (read_profile): Do not add working sets.
1017 (read_autofdo_file): Remove sum_all.
1018 (afdo_callsite_hot_enough_for_early_inline): Remove const
1020 * coverage.c (struct counts_entry): Remove gcov_summary.
1021 (read_counts_file): Read new GCOV_TAG_OBJECT_SUMMARY,
1022 do not support GCOV_TAG_PROGRAM_SUMMARY.
1023 (get_coverage_counts): Remove summary and expected
1025 * coverage.h (get_coverage_counts): Likewise.
1026 * doc/gcov-dump.texi: Remove -w option.
1027 * gcov-dump.c (dump_working_sets): Remove.
1028 (main): Do not support '-w' option.
1029 (print_usage): Likewise.
1030 (tag_summary): Likewise.
1031 * gcov-io.c (gcov_write_summary): Do not dump
1033 (gcov_read_summary): Likewise.
1034 (gcov_histo_index): Remove.
1035 (gcov_histogram_merge): Likewise.
1036 (compute_working_sets): Likewise.
1037 * gcov-io.h (GCOV_TAG_OBJECT_SUMMARY): Mark
1039 (GCOV_TAG_PROGRAM_SUMMARY): Mark it obsolete.
1040 (GCOV_TAG_SUMMARY_LENGTH): Adjust.
1041 (GCOV_HISTOGRAM_SIZE): Remove.
1042 (GCOV_HISTOGRAM_BITVECTOR_SIZE): Likewise.
1043 (struct gcov_summary): Simplify rapidly just
1044 to runs and sum_max fields.
1045 (gcov_histo_index): Remove.
1046 (NUM_GCOV_WORKING_SETS): Likewise.
1047 (compute_working_sets): Likewise.
1048 * gcov-tool.c (print_overlap_usage_message): Remove
1049 trailing empty line.
1050 * gcov.c (read_count_file): Read GCOV_TAG_OBJECT_SUMMARY.
1051 (output_lines): Remove program related line.
1052 * ipa-profile.c (ipa_profile): Do not consider GCOV histogram.
1053 * lto-cgraph.c (output_profile_summary): Do not stream GCOV
1055 (input_profile_summary): Do not read it.
1056 (merge_profile_summaries): And do not merge it.
1057 (input_symtab): Do not call removed function.
1058 * modulo-sched.c (sms_schedule): Do not print sum_max.
1059 * params.def (HOT_BB_COUNT_FRACTION): Reincarnate param that was
1060 removed when histogram method was invented.
1061 (HOT_BB_COUNT_WS_PERMILLE): Mention that it's used only in LTO
1063 * postreload-gcse.c (eliminate_partially_redundant_load): Fix
1065 * predict.c (get_hot_bb_threshold): Use HOT_BB_COUNT_FRACTION
1066 and dump selected value.
1067 * profile.c (add_working_set): Remove.
1068 (get_working_sets): Likewise.
1069 (find_working_set): Likewise.
1070 (get_exec_counts): Do not work with working sets.
1071 (read_profile_edge_counts): Do not inform as sum_max is removed.
1072 (compute_branch_probabilities): Likewise.
1073 (compute_value_histograms): Remove argument for call of
1074 get_coverage_counts.
1075 * profile.h: Do not make gcov_summary const.
1077 2018-09-21 Monk Chiang <sh.chiang04@gmail.com>
1079 * config.gcc (nds32*-*-*): Set TARGET_DEFAULT_TLSDESC_TRAMPOLINE=0.
1081 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
1083 PR tree-optimization/86990
1084 * gimple-ssa-store-merging.c (imm_store_chain_info:coalesce_immediate):
1085 Check that the entire merged store group is made of constants only for
1088 2018-09-20 Allan Sandfeld Jensen <allan.jensen@qt.io>
1090 * gcc.c (LINK_COMMAND_SPEC): Handle -r like -nostdlib.
1091 (VTABLE_VERIFICATION_SPEC): Likewise.
1092 (SANITIZER_EARLY_SPEC): Likewise.
1093 (SANITIZER_SPEC): Likewise.
1094 * config/darwin.h (LINK_COMMAND_SPEC): Likewise.
1095 * doc/invoke.texi (Link Options): Document -r.
1097 2018-09-20 Richard Biener <rguenther@suse.de>
1100 * gimplify.c (gimplify_expr): Retain alignment of
1101 addressable lvalue in dereference.
1103 2018-09-20 Alexandre Oliva <aoliva@redhat.com>
1106 * configure.ac: Check for .loc is_stmt support.
1107 * configure, config.in: Rebuilt.
1108 * dwarf2out.c (dwarf2out_source_line): Skip is_stmt
1111 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
1113 * config/rs6000/rs6000.opt (misel=no, misel=yes): Delete.
1114 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -misel=yes and
1117 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
1119 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
1121 * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete
1124 2018-09-20 Marek Polacek <polacek@redhat.com>
1126 * doc/invoke.texi: Add -Wno-init-list-lifetime to C++ Language Options.
1128 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
1130 PR tree-optimization/87288
1131 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
1132 into account when determining PEELING_FOR_NITERS.
1134 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
1136 PR tree-optimization/86877
1137 * tree-vect-loop.c (vect_analyze_loop_2): Call
1138 vect_verify_datarefs_alignment.
1140 2018-09-19 Marek Polacek <polacek@redhat.com>
1142 * doc/invoke.texi: Document -Wclass-conversion.
1144 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
1146 * config/pa/pa.c (pa_adjust_priority): Delete.
1147 (TARGET_SCHED_ADJUST_PRIORITY): Delete define.
1149 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
1150 (atomic_storehi): Likewise.
1151 (atomic_storesi): Likewise.
1152 (atomic_loaddi): Restore compare and swap exchange loop code.
1154 2018-09-19 Segher Boessenkool <segher@kernel.crashing.org>
1156 PR rtl-optimization/86902
1157 * combine.c (try_combine): When changing the CC mode used, don't change
1158 an unrelated mode in other_insn to that new CC mode.
1160 2018-09-19 David Malcolm <dmalcolm@redhat.com>
1162 * tree-data-ref.c (runtime_alias_check_p): Use formatted printing
1163 with %T in place of calls to dump_generic_expr.
1164 (prune_runtime_alias_test_list): Likewise.
1165 (create_runtime_alias_checks): Likewise.
1166 * tree-vect-data-refs.c (vect_check_nonzero_value): Likewise.
1167 (vect_analyze_data_ref_dependence): Likewise.
1168 (vect_slp_analyze_data_ref_dependence): Likewise.
1169 (vect_record_base_alignment): Likewise. Use %G in place of call
1170 to dump_gimple_stmt.
1171 (vect_compute_data_ref_alignment): Likewise.
1172 (verify_data_ref_alignment): Likewise.
1173 (vect_find_same_alignment_drs): Likewise.
1174 (vect_analyze_group_access_1): Likewise.
1175 (vect_analyze_data_ref_accesses): Likewise.
1176 (dependence_distance_ge_vf): Likewise.
1177 (dump_lower_bound): Likewise.
1178 (vect_prune_runtime_alias_test_list): Likewise.
1179 (vect_find_stmt_data_reference): Likewise.
1180 (vect_analyze_data_refs): Likewise.
1181 (vect_create_addr_base_for_vector_ref): Likewise.
1182 (vect_create_data_ref_ptr): Likewise.
1183 * tree-vect-loop-manip.c (vect_set_loop_condition): Likewise.
1184 (vect_can_advance_ivs_p): Likewise.
1185 (vect_update_ivs_after_vectorizer): Likewise.
1186 (vect_gen_prolog_loop_niters): Likewise.
1187 (vect_prepare_for_masked_peels): Likewise.
1188 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
1189 (vect_determine_vectorization_factor): Likewise.
1190 (vect_is_simple_iv_evolution): Likewise.
1191 (vect_analyze_scalar_cycles_1): Likewise.
1192 (vect_analyze_loop_operations): Likewise.
1193 (report_vect_op): Likewise.
1194 (vect_is_slp_reduction): Likewise.
1195 (check_reduction_path): Likewise.
1196 (vect_is_simple_reduction): Likewise.
1197 (vect_create_epilog_for_reduction): Likewise.
1198 (vect_finalize_reduction:): Likewise.
1199 (vectorizable_induction): Likewise.
1200 (vect_transform_loop_stmt): Likewise.
1201 (vect_transform_loop): Likewise.
1202 (optimize_mask_stores): Likewise.
1203 * tree-vect-patterns.c (vect_pattern_detected): Likewise.
1204 (vect_split_statement): Likewise.
1205 (vect_recog_over_widening_pattern): Likewise.
1206 (vect_recog_average_pattern): Likewise.
1207 (vect_determine_min_output_precision_1): Likewise.
1208 (vect_determine_precisions_from_range): Likewise.
1209 (vect_determine_precisions_from_users): Likewise.
1210 (vect_mark_pattern_stmts): Likewise.
1211 (vect_pattern_recog_1): Likewise.
1212 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
1213 (vect_record_max_nunits): Likewise.
1214 (vect_build_slp_tree_1): Likewise.
1215 (vect_build_slp_tree_2): Likewise.
1216 (vect_print_slp_tree): Likewise.
1217 (vect_analyze_slp_instance): Likewise.
1218 (vect_detect_hybrid_slp_stmts): Likewise.
1219 (vect_detect_hybrid_slp_1): Likewise.
1220 (vect_slp_analyze_operations): Likewise.
1221 (vect_slp_analyze_bb_1): Likewise.
1222 (vect_transform_slp_perm_load): Likewise.
1223 (vect_schedule_slp_instance): Likewise.
1224 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
1225 (vect_mark_stmts_to_be_vectorized): Likewise.
1226 (vect_init_vector_1): Likewise.
1227 (vect_get_vec_def_for_operand): Likewise.
1228 (vect_finish_stmt_generation_1): Likewise.
1229 (vect_check_load_store_mask): Likewise.
1230 (vectorizable_call): Likewise.
1231 (vectorizable_conversion): Likewise.
1232 (vectorizable_operation): Likewise.
1233 (vectorizable_load): Likewise.
1234 (vect_analyze_stmt): Likewise.
1235 (vect_is_simple_use): Likewise.
1236 (vect_get_vector_types_for_stmt): Likewise.
1237 (vect_get_mask_type_for_stmt): Likewise.
1238 * tree-vectorizer.c (increase_alignment): Likewise.
1240 2018-09-19 Andrew Stubbs <ams@codesourcery.com>
1242 * doc/rtl.texi: Adjust vec_select description.
1243 * simplify-rtx.c (simplify_binary_operation_1): Allow VEC_SELECT to use
1244 non-constant selectors.
1246 2018-09-19 Matthew Malcomson <matthew.malcomson@arm.com>
1248 * config/aarch64/aarch64-protos.h
1249 (aarch64_offset_9bit_signed_unscaled_p): New declaration.
1250 * config/aarch64/aarch64.md (arches): New "rcpc8_4" attribute value.
1251 (arch_enabled): Add check for "rcpc8_4" attribute value of "arch".
1252 * config/aarch64/aarch64.h (AARCH64_FL_RCPC8_4): New bitfield.
1253 (AARCH64_FL_FOR_ARCH8_4): Include AARCH64_FL_RCPC8_4.
1254 (AARCH64_FL_PROFILE): Move index so flags are ordered.
1255 (AARCH64_ISA_RCPC8_4): New flag.
1256 * config/aarch64/aarch64.c (offset_9bit_signed_unscaled_p): Renamed
1257 to aarch64_offset_9bit_signed_unscaled_p.
1258 * config/aarch64/atomics.md (atomic_store<mode>): Allow offset
1260 * config/aarch64/constraints.md (Ust): New constraint.
1261 * config/aarch64/predicates.md.
1262 (aarch64_9bit_offset_memory_operand): New predicate.
1263 (aarch64_rcpc_memory_operand): New predicate.
1265 2018-09-19 Eric Botcazou <ebotcazou@adacore.com>
1267 PR rtl-optimization/87361
1268 * rtlanal.c (nonzero_bits1): Revert accidental change.
1270 2018-09-19 Richard Biener <rguenther@suse.de>
1272 PR tree-optimization/87349
1273 PR tree-optimization/87342
1274 * tree-ssa-sccvn.c (do_rpo_vn): Iterate max_rpo computation.
1276 2018-09-18 Marek Polacek <polacek@redhat.com>
1278 P1064R0 - Allowing Virtual Function Calls in Constant Expressions
1279 * gimple-fold.c (gimple_get_virt_method_for_vtable): Adjust assert.
1281 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
1283 * config/rs6000/rs6000.md: Remove old "Cygnus sibcall" comment.
1285 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
1287 PR rtl-optimization/86882
1288 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
1290 2018-09-18 Uros Bizjak <ubizjak@gmail.com>
1292 * config/i386/i386.md (*<code>extend<mode>xf2): Macroize insn from
1293 *<code>extendsfxf2 and *<code>extenddfxf2 using MODEF mode iterator.
1295 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
1298 * doc/invoke.texi (Link Options): Fix formatting and grammar.
1300 2018-09-18 Richard Biener <rguenther@suse.de>
1303 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
1304 (compute_samebase_partition_bases): Likewise.
1305 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
1306 (gimple_can_coalesce_p): Simplify.
1308 2018-09-18 Hans-Peter Nilsson <hp@bitrange.com>
1310 Handle a library implementation of ffs calling __builtin_ffs.
1311 * config/mmix/mmix.c (TARGET_INIT_LIBFUNCS): Override with...
1312 (mmix_init_libfuncs): New function: make __builtin_ffs expand
1315 2018-09-17 David Malcolm <dmalcolm@redhat.com>
1317 * diagnostic-show-locus.c (class layout_range): Add field
1319 (layout_range::layout_range): Add "original_idx" param and use it
1320 to initialize new field.
1321 (make_range): Use 0 for original_idx.
1322 (layout::layout): Pass in index to calls to
1323 maybe_add_location_range.
1324 (layout::maybe_add_location_range): Add param "original_idx" and
1325 pass it on to layout_range.
1326 (layout::print_any_labels): Pass on range->m_original_idx to
1328 (gcc_rich_location::add_location_if_nearby): Use 0 for
1330 * gcc-rich-location.h (text_range_label::get_text): Update for new
1332 (range_label_for_type_mismatch::get_text): Likewise.
1334 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
1336 * config/i386/i386.c (ix86_emit_i387_log1p): Emit fldln2 earlier.
1338 2018-09-17 David Malcolm <dmalcolm@redhat.com>
1340 * gimple-ssa-sprintf.c (fmtwarn): Update for introduction of
1341 format_string_diagnostic_t.
1342 (fmtwarn_n): Likewise.
1343 * substring-locations.c
1344 (format_string_diagnostic_t::format_string_diagnostic_t) New ctor.
1345 (format_warning_n_va): Convert to...
1346 (format_string_diagnostic_t::emit_warning_n_va): ...this.
1347 (format_warning_va): Convert to...
1348 (format_string_diagnostic_t::emit_warning_va): ...this.
1349 (format_warning_at_substring): Convert to...
1350 (format_string_diagnostic_t::emit_warning): ...this.
1351 (format_warning_at_substring_n): Convert to...
1352 (format_string_diagnostic_t::emit_warning_n): ...this.
1353 * substring-locations.h (class format_string_diagnostic_t): New
1355 (format_warning_va): Convert to
1356 format_string_diagnostic_t::emit_warning_va.
1357 (format_warning_n_va): Convert to
1358 format_string_diagnostic_t::emit_warning_n_va.
1359 (format_warning_at_substring): Convert to
1360 format_string_diagnostic_t::emit_warning.
1361 (format_warning_at_substring_n): Convert to
1362 format_string_diagnostic_t::emit_warning_n.
1364 2018-09-17 Cesar Philippidis <cesar@codesourcery.com>
1365 Bernd Schmidt <bernds_cb1@t-online.de>
1367 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with
1370 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
1372 * config/i386/i386.md (truncxf<mode>2_i387_noop_unspec): Change
1373 operand 0 predicate to nonimmediate operand.
1374 (rint<mode>2_frndint): Remove insn pattern.
1375 (rint<mode>2): Change operand 1 predicate to general_operand.
1376 Extend operand 1 to XFmode and generate rintxf2 insn.
1377 (frndintxf2_<rounding>): Rename from frndint<mode>2_<rounding>.
1378 Do not use X87MODEF mode macro.
1379 (frndintxf2_<rounding>_i387): Rename from
1380 frndint<mode>2_<rounding>_i387. Do not use X87MODEF mode macro.
1381 (<rounding_insn><mode>2): For non-SSE modes, extend operand 1
1382 to XFmode and generate significandxf3 insn.
1384 2018-09-17 Richard Biener <rguenther@suse.de>
1386 PR tree-optimization/87328
1387 * tree-ssa-sccvn.c (process_bb): Remove assertion about not
1388 visiting unexecutable backedges when not iterating.
1389 (do_rpo_vn): Mark all edges not executable even when not
1392 2018-09-17 Martin Jambor <mjambor@suse.cz>
1395 * doc/invoke.texi (Warning Options): Likewise.
1397 2018-09-17 Richard Biener <rguenther@suse.de>
1399 PR tree-optimization/87301
1400 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup): Properly
1401 clean EH info from leftover copy assignments.
1403 2018-09-17 Martin Liska <mliska@suse.cz>
1405 PR gcov-profile/85871
1406 * gcov.c (output_intermediate_file): Fix out of bounds
1409 2018-09-17 Vineet Gupta <vgupta@synopsys.com>
1411 * config/arc/arc.c: Object attributes for core4 not reflected
1413 * config/arc/arc.h: Don't restrict DBNZ to core3 (core4 includes
1416 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
1418 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
1420 2018-09-17 Martin Liska <mliska@suse.cz>
1422 * doc/gcov.texi: Document new option --use-hotness-colors.
1423 * gcov.c (struct source_info): Declare new field.
1424 (source_info::source_info): Set default for maximum_count.
1425 (print_usage): Add new -q option.
1426 (process_args): Process it.
1427 (accumulate_line_info): Save src->maximum_count.
1428 (output_line_beginning): Make color line number if
1429 flag_use_hotness_colors is set.
1430 (output_line_details): Pass default argument value.
1431 (output_lines): Pass src->maximum_count.
1433 2018-09-17 Martin Liska <mliska@suse.cz>
1435 * common/config/i386/i386-common.c (ix86_get_valid_option_values):
1436 Use processor_names table.
1437 * config/i386/i386.c (ix86_default_align): Use
1438 processor_cost_table for alignment values.
1439 (ix86_option_override_internal): Use processor_names.
1440 (ix86_function_specific_print): Likewise.
1441 * config/i386/i386.h (struct processor_costs):
1442 Add alignment values.
1443 (struct ptt): Remove and replace with const char *.
1444 * config/i386/x86-tune-costs.h (struct processor_costs):
1445 Declare default alignments for all costs.
1447 2018-09-17 Aldy Hernandez <aldyh@redhat.com>
1449 * tree-vrp.c (extract_range_from_unary_expr): Do not special case
1450 symbolics or VR_VARYING ranges for ABS_EXPR.
1451 * wide-int-range.cc (wide_int_range_abs): Return positive numbers
1452 when range will wrap.
1454 2018-09-15 Eric Botcazou <ebotcazou@adacore.com>
1457 * cfgexpand.c (expand_gimple_basic_block): Be prepared for a BARRIER
1458 before and after a JUMP_TABLE_DATA.
1460 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
1463 * dojump.c (do_compare_and_jump): Canonicalize function pointers
1464 when one operand is a function pointer. Use POINTER_TYPE_P and
1465 FUNC_OR_METHOD_TYPE_P.
1466 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
1467 * fold-const.c (build_range_check): Likewise.
1468 * match.pd (simple_comparison): Likewise.
1470 2018-09-14 David Malcolm <dmalcolm@redhat.com>
1473 * spellcheck.c (get_edit_distance_cutoff): New function.
1474 (selftest::test_edit_distance_unit_test_oneway): Rename to...
1475 (selftest::test_get_edit_distance_one_way): ...this.
1476 (selftest::test_get_edit_distance_unit): Rename to...
1477 (selftest::test_get_edit_distance_both_ways): ...this.
1478 (selftest::test_edit_distances): Move tests to this new function,
1479 and test some more pairs of strings. Update for above renaming.
1480 (selftest::get_old_cutoff): New function.
1481 (selftest::test_get_edit_distance_cutoff): New function.
1482 (selftest::assert_suggested_for): New function.
1483 (ASSERT_SUGGESTED_FOR): New macro.
1484 (selftest::assert_not_suggested_for): New function.
1485 (ASSERT_NOT_SUGGESTED_FOR): New macro.
1486 (selftest::test_suggestions): New function.
1487 (selftest::spellcheck_c_tests): Move test_get_edit_distance_unit
1488 tests to selftest::test_edit_distances and call it. Add calls to
1489 selftest::test_get_edit_distance_cutoff and
1490 selftest::test_suggestions.
1491 * spellcheck.h (get_edit_distance_cutoff): New function declaration.
1492 (best_match::consider): Replace hard-coded cutoff calculation with
1494 (best_match::get_cutoff): New declaration.
1495 (best_match::get_best_meaningful_candidate): Likewise.
1497 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
1499 * builtins.c (fold_builtin_strlen): Remove TODO comment.
1501 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
1504 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
1506 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
1507 terminated string literal.
1509 2018-09-14 Martin Sebor <msebor@redhat.com>
1511 * builtins.c (unterminated_array): Handle ARRAY_REF.
1512 (expand_builtin_stpcpy_1): Detect unterminated char arrays.
1513 * builtins.h (unterminated_array): Declare extern.
1514 * gimple-fold.c (gimple_fold_builtin_stpcpy): Detect unterminated
1516 (gimple_fold_builtin_sprintf): Propagate NO_WARNING to transformed
1519 2018-09-14 Martin Sebor <msebor@redhat.com>
1520 Jeff Law <law@redhat.com>
1522 * builtins.c (unterminated_array): New.
1523 (expand_builtin_strcpy): Adjust.
1524 (expand_builtin_strcpy_args): Detect unterminated arrays.
1525 * gimple-fold.c (get_maxval_strlen): Add argument. Detect
1526 unterminated arrays.
1527 * gimple-fold.h (get_maxval_strlen): Add argument.
1528 (gimple_fold_builtin_strcpy): Detec unterminated arrays.
1530 * gimple-fold.c (get_range_strlen): Add argument.
1531 (get_maxval_strlen): Adjust.
1532 * gimple-fold.h (get_range_strlen): Add argument.
1534 2018-09-14 Wei Xiao <wei3.xiao@intel.com>
1536 * config/i386/movdirintrin.h: Fix copyright year.
1538 2018-09-14 Uros Bizjak <ubizjak@gmail.com>
1540 * reg-stack.c: Include regs.h.
1541 (replace_reg): Assert that mode is MODE_FLOAT or MODE_COMPLEX_FLOAT.
1542 (emit_pop_insn): Default pop insn mode to the reg_raw_mode of
1543 FIRST_STACK_REG, not DFmode.
1544 (emit_swap_insn): Default swap insn mode to the reg_raw_mode of
1545 FIRST_STACK_REG, not XFmode. Explicitly construct swap RTX.
1546 (change stack): Default register mode to the reg_raw_mode of
1547 FIRST_STACK_REG, not DFmode.
1548 * config/i386/i386.md (*swap<mode>): Remove insn pattern.
1549 (*swapxf): Rename from swapxf.
1551 2018-09-14 Carl Love <cel@us.ibm.com>
1553 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
1554 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
1556 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
1559 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
1562 2018-09-14 Sam Tebbs <sam.tebbs@arm.com>
1565 * config/aarch64/aarch64.md (*aarch64_bfxilsi_uxtw): Define.
1567 2018-09-14 Jason Merrill <jason@redhat.com>
1569 Fix --enable-gather-detailed-mem-stats.
1570 * hash-table.c (hash_table_usage): Change from variable to function.
1571 * hash-table.h: Adjust.
1572 * Makefile.in: Add missing dependencies on hash-table.h.
1574 2018-09-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1576 PR tree-optimization/87259
1578 (pass_cse_reciprocals::execute): Run optimize_recip_sqrt after
1579 execute_cse_reciprocals_1 has tried transforming.
1581 2018-09-14 Aldy Hernandez <aldyh@redhat.com>
1583 * tree-vrp.c (extract_range_from_binary_expr_1): Normalize
1584 VR_VARYING for PLUS/MINUS_EXPR.
1586 2018-09-14 Ilya Leoshkevich <iii@linux.ibm.com>
1588 * config/s390/s390-passes.def (INSERT_PASS_BEFORE): Improve
1591 2018-09-14 Richard Biener <rguenther@suse.de>
1594 * tree-ssa-coalesce.c (ssa_conflicts_merge): Remove conflict
1595 bits for the merged partition.
1597 2018-09-13 Martin Sebor <msebor@redhat.com>
1598 Bernd Edlinger <bernd.edlinger@hotmail.de>
1600 * builtins.h (c_srlen): Add argument.
1601 * builtins.c (warn_string_no_nul): New function.
1602 (c_strlen): Add argument and use it. Update recursive calls.
1603 Pass DECL argument to string_constant to get info on non
1604 terminated strings. Update *NONSTR as needed.
1605 (fold_builtin_strlen): Add argument to calls to c_strlen.
1606 Warn for unterminated arrays.
1607 (warn_string_no_null): Add prototype.
1608 * expr.c (string_constant): Update arguments. Update recursive
1609 calls appropriately. Detect missing NUL terminator and outermost
1610 declaration its missing in.
1611 Improve checks for arrays with nonzero lower bound or elements
1612 that are not a single byte. Simplify offset computation.
1613 Simplify checks for non-NUL terminated strings.
1614 * gimple-fold.c (get_range_strlen): Add argument to c_strlen call.
1615 * gimple-ssa-sprintf.c (get_string_length): Remove unnecessary code.
1617 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
1619 * builtins.c (c_strlen): Handle not zero terminated STRING_CSTs
1621 * fold-const.c (c_getstr): Fix function comment. Remove unused third
1622 argument. Fix range checks.
1623 * fold-const.h (c_getstr): Adjust protoype.
1624 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid folding when
1625 string is constant but contains no NUL byte.
1627 * expr.c (string_constant): Adjust function comment.
1628 Remove bogus check for zero termination.
1630 * fold-const.c (c_getstr): Clamp STRING_LENGTH to STRING_SIZE.
1632 * varasm.c (compare_constant): Compare type size of STRING_CSTs.
1633 (get_constant_size): Don't make STRING_CSTs larger than they are.
1634 (check_string_literal): New check function for STRING_CSTs.
1635 (output_constant): Use it.
1637 2018-09-13 Eric Botcazou <ebotcazou@adacore.com>
1640 * config/visium/visium.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define.
1642 2018-09-13 Richard Biener <rguenther@suse.de>
1644 PR tree-optimization/87263
1645 * tree-ssa-sccvn.c (visit_phi): Revert some earlier changes.
1646 (struct unwind_state): Add max_rpo field.
1647 (do_rpo_vn): Allow up-to-date loop state to be used when not iterating.
1648 Compute max_rpo, the max RPO number a block can be backwards reached
1649 from. Re-write non-iterating mode to a RPO ordered worklist approach,
1650 separating it from the iterating mode.
1652 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
1654 * haifa-sched.c (rank_for_schedule): Schedule by INSN_COST.
1655 (rfs_decision): New scheduling decision.
1657 2018-09-13 Richard Biener <rguenther@suse.de>
1660 * tree-ssa-sccvn.c (vn_nary_op_insert_into): Fix assert.
1661 (vn_nary_op_insert_pieces_predicated): Do not write useless
1662 valid_dominated_by_p entry outside of the allocated storage.
1664 2018-09-13 Omar Sandoval <osandov@osandov.com>
1665 Tom de Vries <tdevries@suse.de>
1668 * dwarf2out.c (is_c): New function.
1669 (add_subscript_info): Add DW_AT_count of 0 for C zero-length arrays.
1671 2018-09-13 Sam Tebbs <sam.tebbs@arm.com>
1674 * config/aarch64/aarch64.md (*aarch64_bfxil):
1676 * config/aarch64/constraints.md (Ulc): Define.
1677 * config/aarch64/aarch64-protos.h (aarch64_high_bits_all_ones_p):
1679 * config/aarch64/aarch64.c (aarch64_high_bits_all_ones_p):
1682 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
1684 * config/aarch64/aarch64.h (TARGET_COMPUTE_FRAME_LAYOUT): Define.
1685 * config/aarch64/aarch64.c (aarch64_expand_prologue): Remove
1686 aarch64_layout_frame call.
1687 (aarch64_expand_epilogue): Likewise.
1688 (aarch64_initial_elimination_offset): Likewise.
1689 (aarch64_get_separate_components): Likewise.
1690 (aarch64_use_return_insn_p): Likewise.
1691 (aarch64_layout_frame): Remove unneeded check.
1693 2018-09-13 Jakub Jelinek <jakub@redhat.com>
1695 * configure.ac: Only append
1696 " : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" to
1697 gcc_config_arguments if it was never reconfigured or last reconfigure
1698 was with different arguments.
1699 * configure: Regenerated.
1701 2018-09-13 Jakub Jelinek <jakub@redhat.com>
1702 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1705 * expr.c (maybe_optimize_pow2p_mod_cmp): New function.
1706 (maybe_optimize_mod_cmp): Use it if integer_pow2p treeop1.
1708 2018-09-13 Jakub Jelinek <jakub@redhat.com>
1710 PR tree-optimization/87287
1711 * fold-const.c (fold_binary_loc) <case EQ_EXPR>: Move signed modulo
1712 X % C == 0 to X % (unsigned) C == 0 optimization to ...
1713 * match.pd (X % C == 0): ... here. New optimization.
1715 2018-09-12 Jakub Jelinek <jakub@redhat.com>
1718 * expr.h (maybe_optimize_mod_cmp): Declare.
1719 * expr.c (mod_inv): New function.
1720 (maybe_optimize_mod_cmp): New function.
1721 (do_store_flag): Use it.
1722 * cfgexpand.c (expand_gimple_cond): Likewise.
1724 2018-09-09 Cesar Philippidis <cesar@codesourcery.com>
1725 Julian Brown <julian@codesourcery.com>
1728 * gimplify.c (gimplify_scan_omp_clauses): Set
1729 target_firstprivatize_array_bases in OpenACC parallel and kernels
1730 region contexts. Remove GOMP_MAP_FIRSTPRIVATE_REFERENCE clauses from
1731 OpenACC data regions.
1733 2018-09-12 Uros Bizjak <ubizjak@gmail.com>
1735 * config/i386/i386.md (sqrt_extend<mode>xf3_i387): Remove.
1736 (sqrt<mode>2): Extend operand 1 to XFmode and generate sqrtxf3 insn.
1738 2018-09-12 Richard Biener <rguenther@suse.de>
1740 PR tree-optimization/87280
1741 * tree-ssa-sccvn.c (process_bb): Handle the case of executable
1742 edge but unreachable target.
1743 (do_rpo_vn): For conservatively handling a PHI only mark
1744 the backedge executable but not the block reachable.
1746 2018-09-12 Richard Biener <rguenther@suse.de>
1748 PR tree-optimization/87266
1749 * tree-ssa-sccvn.c (do_rpo_vn): Always iterate to not yet
1752 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
1754 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
1756 ("trunc<BFP:mode><DFP_ALL:mode>2")
1757 ("trunc<DFP_ALL:mode><BFP:mode>2")
1758 ("extend<BFP:mode><DFP_ALL:mode>2")
1759 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
1760 according to the target operand type.
1762 2018-09-12 Jakub Jelinek <jakub@redhat.com>
1763 Andreas Krebbel <krebbel@linux.ibm.com>
1765 PR tree-optimization/86844
1766 * gimple-ssa-store-merging.c
1767 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
1768 there are any overlapping stores in between them, make sure they are
1769 also coalesced or we give up completely.
1771 2018-09-12 Jakub Jelinek <jakub@redhat.com>
1774 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
1775 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
1777 2018-09-12 Tom de Vries <tdevries@suse.de>
1779 * common.opt (gdescribe-dies): Add option.
1780 * dwarf2out.c (add_name_and_src_coords_attributes): Add description
1781 attribute for artifical and nameless decls.
1782 (dwarf2out_register_external_die): Add description attribute to
1783 external reference die.
1784 (add_desc_attribute): New functions.
1785 (gen_subprogram_die): Add description attribute to
1786 DW_TAG_call_site_parameter.
1787 * tree-pretty-print.c (print_generic_expr_to_str): New function.
1788 * tree-pretty-print.h (print_generic_expr_to_str): Declare.
1789 * doc/invoke.texi (@item Debugging Options): Add -gdescribe-dies and
1791 (@item -gdescribe-dies): Add.
1793 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
1795 * tree-vrp.c (vrp_shift_undefined_p): Remove.
1796 (extract_range_from_binary_expr_1: Call
1797 wide_int_range_shift_undefined_p instead of vrp_shift_undefined_p.
1798 * wide-int-range.h (wide_int_range_shift_undefined_p): Do not
1801 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
1803 * gimple-ssa-warn-alloca.c
1804 (alloca_type_and_limit::alloca_type_and_limit): Initialize limit
1805 field for ALLOCA_BOUND_*_LARGE.
1807 2018-09-11 Nathan Sidwell <nathan@acm.org>
1809 * gcc.c (load_specs, execute, run_attempt): Use %qs not '%s'.
1811 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
1813 * reg-stack.c (subst_asm_stack_regs): Call replace_reg also
1814 for clobbers. Remove obsolete comment.
1816 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
1818 * config/i386/i386.md (define_attr "type"): Remove mpxmov, mpxmk,
1819 mpxchk, mpxld and mpxst types.
1820 (define_attr length_immediate): Remove all processing of mpx types.
1821 (define_attr prefix_0f): Ditto.
1822 (define_attr memory): Ditto.
1824 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
1826 * config/i386/i386.md (fyl2x_extend<mode>xf3_i387): Remove.
1827 (log<mode>2): Change operand 1 predicate to general_operand.
1828 Extend operand 1 to XFmode and generate logxf3 insn.
1829 (log10<mode>2): Change operand 1 predicate to general_operand.
1830 Extend operand 1 to XFmode and generate log10xf3 insn.
1831 (log2<mode>2): Change operand 1 predicate to general_operand.
1832 Extend operand 1 to XFmode and generate log2xf3 insn.
1833 (fyl2xp1_extend<mode>xf3_i387): Remove.
1834 (log1p<mode>2): Change operand 1 predicate to general_operand.
1835 Extend operand 1 to XFmode and generate log1pxf3 insn.
1836 (fxtract_extend<mode>xf3_i387): Remove.
1837 (logb<mode>2): Change operand 1 predicate to general_operand.
1838 Extend operand 1 to XFmode and generate logbxf3 insn.
1839 (ilogb<mode>2): Change operand 1 predicate to general_operand.
1840 Extend operand 1 to XFmode and generate fxtractxf3_i387 insn.
1841 (significand<mode>2): Change operand 1 predicate to general_operand.
1842 Extend operand 1 to XFmode and generate significandxf3 insn.
1844 2018-09-11 Nathan Sidwell <nathan@acm.org>
1846 * gcc.c (perror_with_name, pfatal_with_name): Delete.
1847 (load_specs): Use fatal_error.
1848 (DELETE_IF_ORDINARY, process_command): Use error.
1849 (execute, run_attempt): Use fatal_error.
1851 2018-09-11 Andrew Stubbs <ams@codesourcery.com>
1853 * diagnostic-core.h (sorry_at): New prototype.
1854 * diagnostic.c (sorry_at): New function.
1856 2018-09-11 Aldy Hernandez <aldyh@redhat.com>
1858 * tree-vrp.c (extract_range_from_binary_expr_1): Treat all divisions
1859 by zero as VR_UNDEFINED.
1861 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
1863 * config/i386/i386.md (<sincos>xf2): Rename from *<sincos>xf2_i387.
1864 (*<sincos>_extend<mode>xf2_i387): Remove insn pattern.
1865 (<sincos>mode2): New expander.
1866 (sincos_extend<mode>xf3_i387): Remove insn pattern.
1867 (sincos -> sin, cos splitters): Remove splitter patterns.
1868 (sincos<mode>3): Change operand 2 predicate to general_operand.
1869 Extend operand 2 to XFmode and generate sincosxf3 insn.
1870 (fptanxf4_i387): Change mode of operands 0 and 3 to SFmode.
1871 Change operand 3 predicate to const1_operand.
1872 (fptan_extend<mode>xf4_i387): Remove insn pattern.
1873 (tanxf2): Update operands in the call to fptanxf4_i387.
1874 (tan<mode>2): Change operand 1 predicate to general_operand.
1875 Extend operand 1 to XFmode and generate tanxf3 insn.
1876 (atan2xf3): Rename from *fpatanxf3_i387.
1877 (fpatan_extend<mode>xf3_i387): Remove insn pattern.
1878 (atan2xf3): Remove expander.
1879 (atan2<mode<3): Change operand 1 and 2 predicates to general_operand.
1880 Extend operands 1 and 2 to XFmode and generate atan2xf3 insn.
1881 (atan<mode>2): Change operand 1 predicate to general_operand.
1882 Extend operand 1 to XFmode and generate atanxf3 insn.
1884 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
1886 * config/i386/i386.md (x87/SSE constant load splitter): Use
1887 memory_operand instead of nonimmediate_operand for input operand
1890 2018-09-09 Uros Bizjak <ubizjak@gmail.com>
1892 * config/i386/i386.md (float partial SSE register stall splitter): Move
1893 splitter near its instruction pattern.
1894 (float_extend partial SSE register stall splitter): Ditto.
1895 (float_truncate partial SSE register stall splitter): Ditto.
1897 2018-09-09 Hans-Peter Nilsson <hp@bitrange.com>
1900 * config/mmix/mmix.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
1901 to speculation_safe_value_not_needed.
1904 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
1905 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
1906 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
1907 leaf_function_p, instead use has_hard_reg_initial_val.
1909 2018-09-09 Nathan Sidwell <nathan@acm.org>
1911 * gcc.h (pfatal_with_name): Don't declare here.
1912 * gcc.c (pfatal_with_name): Make static.
1914 2018-09-09 Xianmiao Qu <xianmiao_qu@c-sky.com>
1916 * config/csky/csky.md (*cskyv2_adddi3, *cskyv2_subdi3): Add
1919 2018-09-08 John David Anglin <danglin@gcc.gnu.org>
1921 PR rtl-optimization/85458
1922 * sel-sched.c (sel_target_adjust_priority): Allow backend adjust
1923 priority hook to reduce the priority of EXPR.
1925 2018-09-07 Uros Bizjak <ubizjak@gmail.com>
1927 * config/i386/i386.md (float<SWI48x:mode><MODEF:mode>2) Enable
1928 DImode for x87 on 32bit targets. Conditionally disable x87 modes
1929 with X87_ENABLE_FLOAT. Remove preparation code.
1930 (*float<SWI48:mode><MODEF:mode>2): Rename from
1931 *float<SWI48:mode><MODEF:mode>2_mixed. Handle x87, SSE and mixed
1932 math using "enabled" attribute.
1933 (*floatdi<MODEF:mode>2_i387): Rename from
1934 *float<SWI48x:mode><MODEF:mode>2_i387. Handle only DImode and
1935 enable for 32bit targets only.
1936 (floatdi<X87MODEF:mode>2_i387_with_xmm pre-reload splitter): New
1938 (floatdi<X87MODEF:mode>2_i387_with_xmm): Use register_operand
1939 as operand 1 predicate. Rewrite as define_insn_and_split.
1940 (floatdi<X87MODEF:mode>2_i387_with_xmm memory input splitter): Remove.
1942 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
1944 * reg-stack.c (get_true_reg) <case FLOAT_TRUNCATE>: Reorder
1945 to fallthru to FLOAT case.
1947 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
1950 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
1951 around folding of vec_sl to handle out of range shift values.
1953 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
1955 * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Remove.
1956 Update callers to gen_fix_trunc<mode>_i387_fisttp
1957 (fix_trunc<mode>_i387_fisttp): Change operand 0 predicate to
1958 nonimmediate_operand.
1959 (fix_trunc<mode>_i387_fisttp_with_temp): Remove insn pattern
1960 and corresponding splitters.
1961 (*fix_trunc<mode>_i387_1): Always expand with fix_trunc<mode>_i387.
1962 (fix_truncdi_i387): Change operand 0 predicate to nonimmediate_operand.
1963 (fix_truncdi_i387_with_temp): Remove insn pattern
1964 and corresponding splitters.
1965 (fix_trunc<mode>_i387): Change operand 0 predicate to
1966 nonimmediate_operand.
1967 (fix_trunc<mode>_i387_with_temp): Remove insn pattern
1968 and corresponding splitters.
1969 (*fistdi2_1): Remove.
1971 (fistdi2_with_temp): Remove insn pattern and corresponding splitters.
1972 (lrintxfdi2): Remove expander. Reimplement as define_insn.
1973 (*fist<mode>2_1): Remove.
1974 (fist<mode>2): Ditto.
1975 (fist<mode>2_with_temp): Remove insn pattern and corresponding
1977 (lrintxf<mode>2): Remove expander. Reimplement as define_insn.
1978 (*fist<mode>2_<rounding>_1): Always expand with fist<mode>2_<rounding>.
1979 (fistdi2_<rounding>): Change operand 0 predicate to
1980 nonimmediate_operand.
1981 (fistdi2_<rounding>_with_temp): Remove insn pattern
1982 and corresponding splitters.
1983 (fist<mode>2_<rounding>): Change operand 0 predicate to
1984 nonimmediate_operand.
1985 (fist<mode>2_<rounding>_with_temp): Remove insn pattern
1986 and corresponding splitters.
1988 (*fixuns_trunc<mode>si2_avx512f_zext): Depend on TARGET_SSE_MATH.
1990 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
1992 * varasm.c (output_constructor_regular_field): Check TYPE_SIZE_UNIT of
1995 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
1997 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
1998 early gimple folding of vec_splat().
1999 * tree-vect-generic.c: Remove static from tree_vec_extract() definition.
2000 * gimple-fold.h: Add an extern define for tree_vec_extract().
2002 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
2004 * config/rs6000/rs6000.c (fold_mergehl_helper): Add types_compatible_p
2005 wrappers around TREE_TYPE comparisons.
2007 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
2010 * config/s390/predicates.md: Add nonsym_memory_operand.
2011 * config/s390/s390.c (s390_legitimize_cs_operand): If operand
2012 contains a SYMBOL_REF, load it into an intermediate pseudo.
2013 (s390_emit_compare_and_swap): Legitimize operand.
2014 * config/s390/s390.md: Use the new nonsym_memory_operand
2015 with UNSPECV_CAS patterns.
2017 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
2020 * config/s390/s390-passes.def: New file.
2021 * config/s390/s390-protos.h (class rtl_opt_pass): Add forward
2023 (make_pass_s390_early_mach): Add declaration.
2024 * config/s390/s390.c (make_pass_s390_early_mach):
2025 (s390_option_override): Remove dynamic registration.
2026 * config/s390/t-s390: Add s390-passes.def.
2028 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
2030 * config/s390/s390.c (s390_decompose_constant_pool_ref):
2031 Remove UNSPEC_LTREL_BASE check.
2032 (annotate_constant_pool_refs): Likewise.
2033 (find_constant_pool_ref): Likewise.
2034 (find_ltrel_base): Removed.
2035 (replace_ltrel_base): Removed.
2036 (s390_mainpool_finish): Remove replace_ltrel_base call.
2037 (s390_chunkify_start): Remove pending LTREL_BASE logic.
2038 (s390_chunkify_finish): Remove replace_ltrel_base call.
2039 * config/s390/s390.md: Remove UNSPEC_LTREL_BASE.
2041 2018-09-06 Hans-Peter Nilsson <hp@axis.com>
2044 * config/cris/cris.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
2045 to speculation_safe_value_not_needed.
2047 2018-09-05 Cesar Philippidis <cesar@codesourcery.com>
2048 Bernd Schmidt <bernds_cb1@t-online.de>
2050 * config/nvptx/nvptx-opts.h: New file.
2051 * config/nvptx/nvptx.c (nvptx_file_start): Print the correct .target.
2052 * config/nvptx/nvptx.h: Include "nvptx-opts.h".
2054 (TARGET_SM35): New macro.
2055 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with the
2057 * config/nvptx/nvptx.opt (ptx_isa, sm_30, sm_35): New enum and its
2059 (misa=): New option.
2060 * doc/invoke.texi (Nvidia PTX Options): Document -misa.
2062 2018-09-05 Uros Bizjak <ubizjak@gmail.com>
2064 * config/i386/i386.md (truncdfsf2): Remove expander.
2065 (truncdfsf2_with_temp): Ditto.
2066 (truncxf<mode>2): Ditto.
2067 (*truncdfsf_fast_mixed): Remove insn pattern.
2068 (*truncdfsf_fast_i387): Ditto.
2069 (*truncdfsf_mixed): Ditto.
2070 (*truncdfsf_i387): Ditto.
2071 (*truncdfsf2_i387_1): Ditto.
2072 (*truncxfsf2_mixed): Ditto.
2073 (*truncxfdf2_mixed): Ditto.
2074 (*truncxf<mode>2_i387_noop): Ditto. Update callers
2075 to call gen_truncxf<mode>2 instead.
2076 (*truncxf<mode>2_i387): Remove.
2077 (reg->reg splitters): Remove splitter pattern.
2078 (reg->mem splitters): Ditto.
2080 (truncdfsf2): New insn pattern.
2081 (truncxf<mode>2): Ditto.
2083 2018-09-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2085 * tree-ssa-math-opts.c (is_mult_by): New function.
2086 (is_square_of): Use the above.
2087 (optimize_recip_sqrt): New function.
2088 (pass_cse_reciprocals::execute): Use the above.
2090 2018-09-05 Richard Biener <rguenther@suse.de>
2093 * tree-ssa-sccvn.c (rpo_elim::eliminate_push_avail): Make sure
2094 to zero-init the emplaced vec.
2096 2018-09-05 Martin Liska <mliska@suse.cz>
2098 PR tree-optimization/87205
2099 * tree-switch-conversion.c (pass_lower_switch::execute):
2100 Group cases for switch statements.
2102 2018-09-05 Richard Biener <rguenther@suse.de>
2104 PR tree-optimization/87217
2105 * tree-ssa-sccvn.c (vuse_valueize): New.
2106 (vn_reference_lookup_pieces): Use it.
2107 (vn_reference_lookup): Likewise.
2109 2018-09-05 Nathan Sidwell <nathan@acm.org>
2112 * stor-layout.c (place_field): Scan forwards to check last
2113 bitfield when ms_bitfield_placement is in effect.
2115 2018-09-05 Richard Biener <rguenther@suse.de>
2118 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
2121 2018-09-05 Siddhesh Poyarekar <siddhesh@sourceware.org>
2122 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
2124 * config/aarch64/falkor-tag-collision-avoidance.c: New file.
2125 * config.gcc (extra_objs): Build it.
2126 * config/aarch64/t-aarch64 (falkor-tag-collision-avoidance.o):
2128 * config/aarch64/aarch64-passes.def
2129 (pass_tag_collision_avoidance): New pass.
2130 * config/aarch64/aarch64.c (qdf24xx_tunings): Add
2131 AARCH64_EXTRA_TUNE_RENAME_LOAD_REGS to tuning_flags.
2132 (aarch64_classify_address): Remove static qualifier.
2133 (aarch64_address_info, aarch64_address_type): Move to...
2134 * config/aarch64/aarch64-protos.h: ... here.
2135 (make_pass_tag_collision_avoidance): New function.
2136 * config/aarch64/aarch64-tuning-flags.def (rename_load_regs):
2139 2018-09-05 Martin Liska <mliska@suse.cz>
2141 * doc/gcov.texi: Update documentation of humar
2143 * gcov.c (format_count): Print one decimal place, it provides
2144 more fine number of situations like '1G' vs. '1.4G'.
2146 2018-09-05 Martin Liska <mliska@suse.cz>
2149 * config/rs6000/rs6000.opt: Mark the option as Deprecated.
2150 * optc-gen.awk: Allow 'Var' for Deprecated options in order
2151 to generate a MASK value.
2153 2018-09-04 H.J. Lu <hongjiu.lu@intel.com>
2156 * dwarf2out.c (based_loc_descr): Allow hard frame pointer even
2157 if frame pointer isn't used.
2158 (compute_frame_pointer_to_fb_displacement): Likewise.
2160 2018-09-04 Jakub Jelinek <jakub@redhat.com>
2163 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
2164 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
2165 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
2166 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
2167 and OPTION_MASK_ISA_XSAVEC_UNSET.
2169 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
2171 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
2172 XOR operations in NAND case.
2174 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
2176 * wide-int-range.cc (wide_int_range_convert): New.
2177 * wide-int-range.h (wide_int_range_convert): New.
2178 * tree-vrp.c (extract_range_from_unary_expr): Abstract wide int
2179 code into wide_int_range_convert.
2180 (extract_range_into_wide_ints): Do not munge anti range constants
2181 into the entire domain. Just return the range back.
2183 2018-09-04 Martin Liska <mliska@suse.cz>
2185 * genmatch.c (output_line_directive): Add new argument
2187 (dt_simplify::gen_1): Encapsulate dump within __builtin_expect.
2189 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
2191 * doc/invoke.texi (Option Summary): Add whitespace.
2193 * doc/invoke.texi (Option Summary): Add -Waligned-new.
2195 2018-09-04 Richard Biener <rguenther@suse.de>
2197 PR tree-optimization/87211
2198 * tree-ssa-sccvn.c (visit_phi): When value-numbering to a
2199 backedge value we're supposed to treat as VARYING also number
2200 the PHI to VARYING in case it got a different value-number already.
2202 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
2204 * tree-vrp.c (vrp_can_optimize_bit_op): Remove.
2205 (extract_range_from_binary_expr_1): Do not call
2206 vrp_can_optimize_bit_op.
2207 * wide-int-range.cc (wide_int_range_can_optimize_bit_op): Make
2209 (wide_int_range_get_mask_and_bounds): New.
2210 (wide_int_range_optimize_bit_op): New.
2211 (wide_int_range_bit_ior): Call wide_int_range_optimize_bit_op.
2212 (wide_int_range_bit_and): Same.
2213 * wide-int-range.h (wide_int_range_can_optimize_bit_op): Remove.
2214 (wide_int_range_optimize_bit_op): New.
2215 (wide_int_range_get_mask_and_bounds): New.
2217 2018-09-04 Richard Biener <rguenther@suse.de>
2219 PR tree-optimization/87176
2220 * tree-ssa-sccvn.c (visit_phi): Remove redundant allsame
2221 variable. When value-numbering a virtual PHI node make sure
2222 to not value-number to the backedge value.
2224 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
2226 * doc/extend.texi (Long Long, Hex Floats): Document support for
2227 long long and hex floats in more recent versions of ISO C++.
2229 2018-09-03 Richard Biener <rguenther@suse.de>
2231 PR tree-optimization/87177
2232 * tree-ssa-sccvn.c (vuse_ssa_val): Revert previous change, keep
2235 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
2237 * bb-reorder.c (edge_order): Convert to C-qsort-style
2238 tri-state comparator.
2239 (reorder_basic_blocks_simple): Change std::stable_sort to
2242 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
2244 * tree-loop-distribution.c (offset_cmp): Convert to C-qsort-style
2245 tri-state comparator.
2246 (fuse_memset_builtins): Change std::stable_sort to gcc_stablesort.
2248 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
2250 * sort.cc (struct sort_ctx): New field 'nlim'. Use it...
2251 (mergesort): ... here as maximum count for using netsort.
2252 (gcc_qsort): Set nlim to 3 if stable sort is requested.
2253 (gcc_stablesort): New.
2254 * system.h (gcc_stablesort): Declare.
2256 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
2258 * sort.cc (gcc_qsort) [CHECKING_P]: Call qsort_chk.
2259 * system.h (qsort): Always redirect to gcc_qsort. Update comment.
2260 * vec.c (qsort_chk): Do not call gcc_qsort. Update comment.
2262 2018-09-03 Segher Boessenkool <segher@kernel.crashing.org>
2264 * config/rs6000/rs6000.md (*mov<mode>_hardfloat32): Remove %U from the
2265 lxsdx and stxsdx alternatives.
2266 (*mov<mode>_hardfloat64): Ditto.
2267 * config/rs6000/vsx.md (*vsx_extract_<mode>_store): Ditto.
2269 2018-09-03 Richard Biener <rguenther@suse.de>
2271 PR tree-optimization/87200
2272 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Valueize a
2275 2018-09-03 Martin Liska <mliska@suse.cz>
2277 PR tree-optimization/87201
2278 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
2279 Fix parenthesis in an expression.
2281 2018-09-03 Richard Biener <rguenther@suse.de>
2283 PR tree-optimization/87197
2284 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Mark the new def
2285 visited. CSE the VN_INFO hashtable lookup.
2287 PR tree-optimization/87169
2288 * tree-ssa-sccvn.c (do_rpo_vn): When marking loops for not
2289 iterating make sure there's no extra backedges from irreducible
2290 regions feeding the header. Mark the destination block
2293 2018-09-03 Martin Liska <mliska@suse.cz>
2296 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES.
2297 * common/common-targhooks.c (default_get_valid_option_values):
2299 * common/common-targhooks.h (default_get_valid_option_values):
2301 * common/config/i386/i386-common.c: Move processor_target_table
2303 (ix86_get_valid_option_values): New function.
2304 (TARGET_GET_VALID_OPTION_VALUES): New macro.
2305 * config/i386/i386.c (struct ptt): Move to i386-common.c.
2306 (PTA_*): Move all defined masks into i386-common.c.
2307 (ix86_function_specific_restore): Use new processor_cost_table.
2308 * config/i386/i386.h (struct ptt): Moved from i386.c.
2309 (struct pta): Likewise.
2310 * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES.
2311 * doc/tm.texi.in: Likewise.
2312 * opt-suggestions.c (option_proposer::suggest_option):
2313 Pass prefix to build_option_suggestions.
2314 (option_proposer::get_completions): Likewise.
2315 (option_proposer::build_option_suggestions): Use the new target
2317 * opts.c (struct option_help_tuple): New struct.
2318 (print_filtered_help): Use the new target hook.
2320 2018-09-03 Martin Liska <mliska@suse.cz>
2323 * predict.c (set_even_probabilities): Add likely_edges
2324 argument and handle cases where we have precisely one
2326 (combine_predictions_for_bb): Catch also likely_edges.
2327 (tree_predict_by_opcode): Handle gswitch statements.
2328 * tree-cfg.h (find_case_label_for_value): New declaration.
2329 (find_taken_edge_switch_expr): Likewise.
2330 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
2331 Find pivot in decision tree based on probabily, not by number of
2334 2018-09-02 Gerald Pfeifer <gerald@pfeifer.com>
2336 * doc/standards.texi (Standards): Update Objective-C reference.
2338 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
2340 * doc/install.texi (Prerequisites): Update link for MPC.
2342 2018-09-01 Michael Matz <matz@suse.de>
2344 PR tree-optimization/87074
2345 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
2346 PHIs for outer-loop uses.
2348 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
2350 * doc/generic.texi (OpenMP): Adjust link to openmp.org.
2351 * doc/invoke.texi (C Dialect Options): Ditto.
2353 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
2355 * doc/install.texi (Prerequisites): Adjust link mpfr.org.
2357 2018-08-31 Richard Biener <rguenther@suse.de>
2359 PR tree-optimization/87168
2360 * tree-ssa-sccvn.c (SSA_VAL): Add visited output parameter.
2361 (rpo_elim::eliminate_avail): When OP was not visited it must
2364 2018-08-31 David Malcolm <dmalcolm@redhat.com>
2366 * tree-vrp.c (copy_value_range): Convert param "from" from
2367 "value_range *" to "const value_range *".
2368 (range_is_null): Likewise for param "vr".
2369 (range_int_cst_p): Likewise.
2370 (range_int_cst_singleton_p): Likewise.
2371 (symbolic_range_p): Likewise.
2372 (value_ranges_intersect_p): Likewise for both params.
2373 (value_range_nonnegative_p): Likewise for param "vr".
2374 (value_range_constant_singleton): Likewise.
2375 (vrp_set_zero_nonzero_bits): Likewise for param "ar".
2376 (extract_range_into_wide_ints): Likewise for param "vr".
2377 (extract_range_from_multiplicative_op): Likewise for params "vr0"
2379 (vrp_can_optimize_bit_op): Likewise.
2380 (extract_range_from_binary_expr_1): Likewise for params "vr0_" and
2382 (extract_range_from_unary_expr): Likewise.
2383 (debug_value_range): Likewise for param "vr".
2384 (value_range::dump): Add "const" qualifier.
2385 (vrp_prop::check_array_ref): Convert local "vr" from
2386 "value_range *" to "const value_range *".
2387 (vrp_prop::check_mem_ref): Likewise.
2388 (vrp_prop::visit_stmt): Likewise for local "old_vr".
2389 (vrp_intersect_ranges_1): Likewise for param "vr_1".
2390 (vrp_intersect_ranges): Likewise.
2391 (simplify_stmt_for_jump_threading): Likewise for local "vr".
2392 (vrp_prop::vrp_finalize): Likewise.
2393 * tree-vrp.h (value_range::dump): Add "const" qualifier.
2394 (vrp_intersect_ranges): Add "const" qualifier to params as above.
2395 (extract_range_from_unary_expr): Likewise.
2396 (value_range_constant_singleton): Likewise.
2397 (symbolic_range_p): Likewise.
2398 (copy_value_range): Likewise.
2399 (extract_range_from_binary_expr_1): Likewise.
2400 (range_int_cst_p): Likewise.
2401 (vrp_set_zero_nonzero_bits): Likewise.
2402 (range_int_cst_singleton_p): Likewise.
2404 2018-08-31 Vlad Lazar <vlad.lazar@arm.com>
2406 * config/aarch64/arm_neon.h (vabsd_s64): New.
2407 (vnegd_s64): Likewise.
2409 2018-08-31 Martin Jambor <mjambor@suse.cz>
2411 * ipa-cp.c (estimate_local_effects): Replace wrong MAX with MIN.
2413 2018-08-31 Martin Liska <mliska@suse.cz>
2415 * ipa-icf.c (sem_item::add_type): Use
2416 sem_item::m_type_hash_cache.
2417 * ipa-icf.h: Move the cache from sem_item_optimizer
2420 2018-08-31 Nathan Sidwell <nathan@acm.org>
2422 * doc/extend.texi (Backwards Compatibility): Remove implicit
2423 extern C leeway of () being (...).
2425 2018-08-31 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2427 * ipa-inline.c (can_inline_edge_by_limits_p): Fix typos in comment.
2429 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
2433 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
2435 2018-08-31 Jakub Jelinek <jakub@redhat.com>
2438 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
2439 gen_int_mode. Formatting fixes.
2441 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
2443 * target.def (custom_function_descriptors): Improve documentation.
2444 * doc/tm.texi.in (Trampolines): Expand discussion of function
2445 descriptors and move TARGET_CUSTOM_FUNCTION_DESCRIPTORS to the
2446 beginning of the section.
2447 * doc/tm.texi: Regenerated.
2449 2018-08-30 Jose E. Marchesi <jose.marchesi@oracle.com>
2451 * cfg.h (class auto_edge_flag): Spell out the template-id of the
2452 base class in the initializer list. This is a workaround for
2453 building with older GCC.
2454 (class auto_bb_flag): Likewise.
2456 2018-08-30 Aaron Sawdey <acsawdey@linux.ibm.com>
2458 * config/rs6000/altivec.md (altivec_eq<mode>): Remove star.
2459 (altivec_vcmpequ<VI_char>_p): Remove star.
2460 * config/rs6000/rs6000-string.c (do_load_for_compare): Support
2462 (expand_strncmp_vec_sequence): New function.
2463 (emit_final_str_compare_vec): New function.
2464 (expand_strn_compare): Add support for vector strncmp.
2465 * config/rs6000/rs6000.opt (-mstring-compare-inline-limit): Change
2466 length specification to bytes.
2467 * config/rs6000/vsx.md (vsx_ld_elemrev_v16qi_internal): Remove star.
2468 (vcmpnezb_p): New pattern.
2469 * doc/invoke.texi (RS/6000 and PowerPC Options): Update documentation
2470 for option -mstring-compare-inline-limit.
2472 2018-08-30 Thiago Macieira <thiago.macieira@intel.com>
2474 * config/i386/i386.c (PTA_WESTMERE): Remove PTA_AES.
2475 (PTA_SKYLAKE): Add PTA_AES.
2476 (PTA_GOLDMONT): Likewise.
2478 2018-08-29 Jan Hubicka <jh@suse.cz>
2481 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
2482 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
2484 2018-08-29 Jan Hubicka <jh@suse.cz>
2486 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not follow
2488 (hash_tree): Do not visit TYPE_STUB_DECL.
2489 * tree-streamer-out.c (write_ts_type_common_tree_pointers): Do not
2490 stream TYPE_STUB_DECL.
2491 * tree-streamer-in.c (lto_input_ts_type_common_tree_pointers): Likewise.
2492 * ipa-utils.h (type_with_linkage_p): Do not rely on TYPE_STUB_DECL
2493 after free_lang_data.
2494 (type_in_anonymous_namespace_p): Likewise.
2496 2018-08-29 Jan Hubicka <jh@suse.cz>
2498 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
2499 comment that it has to be even number.
2500 (class sreal): Change m_sig type to int32_t.
2501 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
2502 int64_t for temporary calculations.
2503 (sreal_verify_basics): Drop one bit from minimum and maximum.
2505 2018-08-30 Richard Biener <rguenther@suse.de>
2507 PR tree-optimization/87147
2508 * tree-ssa-sccvn.c (SSA_VISITED): New function.
2509 (visit_phi): When the degenerate result is from the backedge and
2510 we didn't visit its definition yet drop to VARYING.
2511 (do_rpo_vn): Properly mark blocks with incoming backedges as executable.
2513 2018-08-29 Jan Hubicka <jh@suse.cz>
2515 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not walk
2517 (hash_tree): Likewise.
2519 2018-08-29 Jan Hubicka <jh@suse.cz>
2521 * tree.c (find_decls_types_r): Walk also TYPE_NEXT_PTR_TO
2522 and TYPE_NEXT_REF_TO.
2524 2018-08-29 Jan Hubicka <jh@suse.cz>
2526 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
2527 comment that it has to be even number.
2528 (class sreal): Change m_sig type to int32_t.
2529 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
2530 int64_t for temporary calculations.
2531 (sreal_verify_basics): Drop one bit from minimum and maximum.
2533 2018-08-30 Tamar Christina <tamar.christina@arm.com>
2535 * config/aarch64/aarch64.c (aarch64_expand_movmem): Set TImode max.
2537 2018-08-30 Vlad Lazar <vlad.lazar@arm.com>
2540 * expmed.c (canonicalize_comparison): Use wi::sub instead of wi::add
2541 if to_add is negative.
2543 2018-08-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
2546 * builtins.c (c_strlen): Improve range checks.
2548 2018-08-29 Martin Sebor <msebor@redhat.com>
2549 Jeff Law <law@redhat.com>
2551 PR tree-optimization/86714
2552 PR tree-optimization/86711
2553 * builtins.c (c_strlen): Add arguments to call to string_constant.
2554 * expr.c (string_constant): Add argument. Detect missing nul
2555 terminator and outermost declaration it's missing in.
2556 * expr.h (string_constant): Add argument.
2557 * fold-const.c (read_from_constant_string): Add arguments to call to
2559 (c_getstr): Likewise.
2560 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
2562 * tree-ssa-strlen.c (get_stridx): Likewise.
2564 2018-08-29 Jan Hubicka <jh@suse.cz>
2566 * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers):
2567 Do not stream DECL_VINDEX.
2568 * tree-streamer-out.c (write_ts_function_decl_tree_pointers): Likewise.
2569 * tree.c (free_lang_data_in_decl): Clear DECL_VINDEX.
2570 (decl_function_context): Use DECL_VIRTUAL_P rather than DECL_VINDEX.
2572 2018-08-29 Richard Biener <rguenther@suse.de>
2574 * tree-ssa-sccvn.c (vuse_ssa_val): Return NULL for unvisited
2575 virtual operands that are not default defs to honor region
2577 (rpo_vn_valueize): Remove ineffective code here.
2579 2018-08-29 Richard Biener <rguenther@suse.de>
2581 PR tree-optimization/87132
2582 * tree-ssa-alias.c (get_continuation_for_phi): Do not translate
2583 when skipping defs reachable over backedges.
2585 2018-08-29 Richard Biener <rguenther@suse.de>
2587 * tree-core.h: Document use of deprecated_flag in SSA_NAME.
2588 * tree.h (SSA_NAME_POINTS_TO_READONLY_MEMORY): Define.
2589 * tree-into-ssa.c (pass_build_ssa::execute): Initialize
2590 function parameters SSA_NAME_POINTS_TO_READONLY_MEMORY from fnspec.
2591 * tree-ssa-sccvn.c (const_parms, init_const_parms): Remove.
2592 (vn_reference_lookup_3): Remove use of const_parms.
2593 (free_rpo_vn): Do not free const_parms.
2594 (do_rpo_vn): Do not call init_const_parms.
2595 * tree-ssa-alias.c (refs_may_alias_p_1): Honor
2596 SSA_NAME_POINTS_TO_READONLY_MEMORY.
2597 (call_may_clobber_ref_p_1): Likewise.
2599 2018-08-29 Alexander Monakov <amonakov@ispras.ru>
2602 * invoke.texi (Optimization Options): List -ftree-scev-cprop.
2604 (-ftree-scev-cprop): Document.
2606 2018-08-29 Jan Hubicka <jh@suse.cz>
2608 * sreal.h (normalize, normalize_up, normalize_down): Add new_sig/new_exp
2610 (sreal constructor): Update.
2611 * sreal.c (sreal:operator+, sreal:operator-, sreal:operator*,
2612 sreal:operator/): Update.
2614 2018-08-29 Martin Liska <mliska@suse.cz>
2616 * tree-switch-conversion.c (switch_conversion::expand):
2617 Strenghten assumption about gswitch statements.
2619 2018-08-29 Richard Biener <rguenther@suse.de>
2621 PR tree-optimization/87117
2622 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
2623 re-value-number released SSA VDEFs.
2625 2018-08-29 Richard Biener <rguenther@suse.de>
2627 PR tree-optimization/87126
2628 * tree-ssa-sccvn.c (vn_reference_insert): Remove assert.
2630 2018-08-28 Jim Wilson <jimw@sifive.com>
2632 * config/riscv/pic.md: Rewrite.
2633 * config/riscv/riscv.c (riscv_address_insns): Return cost of 3 for
2635 * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Delete.
2636 (SOFTF, default_load, softload, softstore): New.
2638 2018-08-28 Jeff Law <law@redhat.com>
2640 * fold-const.c (fold_binary_loc): Remove recently added assert.
2642 2018-08-28 Joern Rennecke <joern.rennecke@riscy-ip.com>
2644 * genpreds.c (write_predicate_subfunction): Also add ATTRIBUTE_UNUSED
2645 to OP parmeter of generated function.
2647 2018-08-28 MCC CS <deswurstes@users.noreply.github.com>
2649 PR tree-optimization/87009
2650 * match.pd: Add boolean optimizations.
2652 2018-08-28 Martin Sebor <msebor@redhat.com>
2655 * calls.c (alloc_max_size): Treat HOST_WIDE_INT special.
2656 * gimple-ssa-warn-alloca.c (adjusted_warn_limit): New function.
2657 (pass_walloca::gate): Use it.
2658 (alloca_call_type): Same.
2659 (pass_walloca::execute): Same.
2660 * stor-layout.c (layout_decl): Treat HOST_WIDE_INT special.
2662 2018-08-28 David Malcolm <dmalcolm@redhat.com>
2664 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): Change version check on
2665 GCC_VERSION for usage of "__gcc_dump_printf__" format from
2668 2018-08-28 Richard Biener <rguenther@suse.de>
2670 PR tree-optimization/87124
2671 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Guard against
2672 constants before looking up avail.
2674 2018-08-28 Jakub Jelinek <jakub@redhat.com>
2677 * calls.c (maybe_warn_nonstring_arg): Punt early if
2678 warn_stringop_overflow is zero. Don't call get_range_strlen
2679 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
2680 Swap comparison operands to have constants on rhs. Only use
2681 lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
2682 increment lenrng[0].
2684 2018-08-28 Richard Sandiford <richard.sandiford@arm.com>
2686 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Fix unguarded
2687 use of tree_to_shwi. Remove duplicated test for the size being
2688 a whole number of bytes.
2690 2018-08-28 Richard Biener <rguenther@suse.de>
2692 PR tree-optimization/87117
2693 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup):
2694 Handle removed stmt without LHS (GIMPLE_NOP).
2696 2018-08-28 Richard Biener <rguenther@suse.de>
2698 PR tree-optimization/87117
2699 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Exclude
2700 void which is is_gimple_reg_type by checking for COMPLETE_TYPE_P.
2702 2018-08-28 Richard Biener <rguenther@suse.de>
2704 PR tree-optimization/87117
2705 * tree-ssa-pre.c (compute_avail): Do not make expressions
2706 with predicated values available.
2707 (get_expr_value_id): Assert we do not run into predicated value
2710 2018-08-28 Richard Biener <rguenther@suse.de>
2712 PR tree-optimization/87117
2713 * tree-ssa-operands.c (add_stmt_operand): STRING_CST may
2714 get virtual operands.
2715 (get_expr_operands): Handle STRING_CST like other decls.
2717 2018-08-28 Martin Liska <mliska@suse.cz>
2719 * tree.h: Update documentation of fndecl_built_in_p
2723 2018-08-27 Jeff Law <law@redhat.com>
2724 PR tree-optimization/87110
2725 * tree-ssa-dse.c (compute_trims): Handle non-constant
2728 2018-08-27 Martin Sebor <msebor@redhat.com>
2730 PR tree-optimization/86914
2731 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
2733 2018-08-27 Martin Sebor <msebor@redhat.com>
2735 PR tree-optimization/87112
2736 * builtins.c (expand_builtin_strnlen): Convert c_strlen result to
2737 the type of the bound argument.
2739 2018-08-27 Jeff Law <law@redhat.com>
2741 * tree-ssa-dse.c (compute_trims): Handle case where the reference's
2742 type does not have a TYPE_SIZE_UNIT.
2744 2018-08-27 Steve Ellcey <sellcey@cavium.com>
2746 * config/aarch64/aarch64-speculation.cc: Replace include of cfg.h
2747 with include of backend.h.
2749 2018-08-27 Richard Biener <rguenther@suse.de>
2751 PR tree-optimization/86927
2752 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
2753 use const cond reduction code.
2755 2018-08-27 Alexander Monakov <amonakov@ispras.ru>
2757 PR tree-optimization/85758
2758 * match.pd ((X & Y) ^ Y): Add :s qualifier to inner expression.
2760 2018-08-27 David Malcolm <dmalcolm@redhat.com>
2763 * diagnostic-show-locus.c (class layout_range): Update for
2764 conversion of show_caret_p to a tri-state.
2765 (layout_range::layout_range): Likewise.
2766 (make_range): Likewise.
2767 (layout::maybe_add_location_range): Likewise.
2768 (layout::should_print_annotation_line_p): Don't show annotation
2769 lines for ranges that are SHOW_LINES_WITHOUT_RANGE.
2770 (layout::get_state_at_point): Update for conversion of
2771 show_caret_p to a tri-state. Bail out early for
2772 SHOW_LINES_WITHOUT_RANGE, so that such ranges don't affect
2773 underlining or source colorization.
2774 (gcc_rich_location::add_location_if_nearby): Update for conversion
2775 of show_caret_p to a tri-state.
2776 (selftest::test_one_liner_multiple_carets_and_ranges): Likewise.
2777 (selftest::test_one_liner_fixit_replace_equal_secondary_range):
2779 (selftest::test_one_liner_labels): Likewise.
2780 * gcc-rich-location.c (gcc_rich_location::add_expr): Update for
2781 conversion of show_caret_p to a tri-state.
2782 * pretty-print.c (text_info::set_location): Likewise.
2783 * pretty-print.h (text_info::set_location): Likewise.
2784 * substring-locations.c (format_warning_n_va): Likewise.
2785 * tree-diagnostic.c (default_tree_printer): Likewise.
2786 * tree-pretty-print.c (newline_and_indent): Likewise.
2788 2018-08-27 David Malcolm <dmalcolm@redhat.com>
2791 * diagnostic-show-locus.c (get_line_span_for_fixit_hint): Show the
2792 line above for line-insertion fix-it hints.
2793 (selftest::test_fixit_insert_containing_newline): Update the
2794 expected results, and add a test with line-numbering enabled.
2796 2018-08-27 Martin Liska <mliska@suse.cz>
2799 * sanopt.c (sanitize_rewrite_addressable_params): Ignore
2800 params with DECL_HAS_VALUE_EXPR_P.
2802 2018-08-27 Martin Liska <mliska@suse.cz>
2804 * config/i386/i386.c (ix86_expand_set_or_movmem): Dump
2805 selected expansion strategy.
2807 2018-08-27 Martin Liska <mliska@suse.cz>
2809 * builtins.h (is_builtin_fn): Remove and fndecl_built_in_p.
2810 * builtins.c (is_builtin_fn): Likewise.
2811 * attribs.c (diag_attr_exclusions): Use new function
2812 fndecl_built_in_p and remove check for FUNCTION_DECL if
2814 (builtin_mathfn_code): Likewise.
2815 (fold_builtin_expect): Likewise.
2816 (fold_call_expr): Likewise.
2817 (fold_builtin_call_array): Likewise.
2818 (fold_call_stmt): Likewise.
2819 (set_builtin_user_assembler_name): Likewise.
2820 (is_simple_builtin): Likewise.
2821 * calls.c (gimple_alloca_call_p): Likewise.
2822 (maybe_warn_nonstring_arg): Likewise.
2823 * cfgexpand.c (expand_call_stmt): Likewise.
2824 * cgraph.c (cgraph_update_edges_for_call_stmt_node): Likewise.
2825 (cgraph_edge::verify_corresponds_to_fndecl): Likewise.
2826 (cgraph_node::verify_node): Likewise.
2827 * cgraphclones.c (build_function_decl_skip_args): Likewise.
2828 (cgraph_node::create_clone): Likewise.
2829 * config/arm/arm.c (arm_insert_attributes): Likewise.
2830 * config/i386/i386.c (ix86_gimple_fold_builtin): Likewise.
2831 * dse.c (scan_insn): Likewise.
2832 * expr.c (expand_expr_real_1): Likewise.
2833 * fold-const.c (operand_equal_p): Likewise.
2834 (fold_binary_loc): Likewise.
2835 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
2836 * gimple-low.c (lower_stmt): Likewise.
2837 * gimple-pretty-print.c (dump_gimple_call): Likewise.
2838 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
2840 * gimple.c (gimple_build_call_from_tree): Likewise.
2841 (gimple_call_builtin_p): Likewise.
2842 (gimple_call_combined_fn): Likewise.
2843 * gimplify.c (gimplify_call_expr): Likewise.
2844 (gimple_boolify): Likewise.
2845 (gimplify_modify_expr): Likewise.
2846 (gimplify_addr_expr): Likewise.
2847 * hsa-gen.c (gen_hsa_insns_for_call): Likewise.
2848 * ipa-cp.c (determine_versionability): Likewise.
2849 * ipa-fnsummary.c (compute_fn_summary): Likewise.
2850 * ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
2851 * ipa-split.c (visit_bb): Likewise.
2852 (split_function): Likewise.
2853 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
2854 * lto-cgraph.c (input_node): Likewise.
2855 * lto-streamer-out.c (write_symbol): Likewise.
2856 * omp-low.c (setjmp_or_longjmp_p): Likewise.
2857 (lower_omp_1): Likewise.
2858 * predict.c (strip_predict_hints): Likewise.
2859 * print-tree.c (print_node): Likewise.
2860 * symtab.c (symtab_node::output_to_lto_symbol_table_p): Likewise.
2861 * trans-mem.c (is_tm_irrevocable): Likewise.
2862 (is_tm_load): Likewise.
2863 (is_tm_simple_load): Likewise.
2864 (is_tm_store): Likewise.
2865 (is_tm_simple_store): Likewise.
2866 (is_tm_abort): Likewise.
2867 (tm_region_init_1): Likewise.
2868 * tree-call-cdce.c (gen_shrink_wrap_conditions): Likewise.
2869 * tree-cfg.c (verify_gimple_call): Likewise.
2870 (move_stmt_r): Likewise.
2871 (stmt_can_terminate_bb_p): Likewise.
2872 * tree-eh.c (lower_eh_constructs_2): Likewise.
2873 * tree-if-conv.c (if_convertible_stmt_p): Likewise.
2874 * tree-inline.c (remap_gimple_stmt): Likewise.
2875 (copy_bb): Likewise.
2876 (estimate_num_insns): Likewise.
2877 (fold_marked_statements): Likewise.
2878 * tree-sra.c (scan_function): Likewise.
2879 * tree-ssa-ccp.c (surely_varying_stmt_p): Likewise.
2880 (optimize_stack_restore): Likewise.
2881 (pass_fold_builtins::execute): Likewise.
2882 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
2883 (mark_all_reaching_defs_necessary_1): Likewise.
2884 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Likewise.
2885 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
2886 (pass_forwprop::execute): Likewise.
2887 * tree-ssa-loop-im.c (stmt_cost): Likewise.
2888 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
2889 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Likewise.
2890 * tree-ssa-strlen.c (get_string_length): Likewise.
2891 * tree-ssa-structalias.c (handle_lhs_call): Likewise.
2892 (find_func_aliases_for_call): Likewise.
2893 * tree-ssa-ter.c (find_replaceable_in_bb): Likewise.
2894 * tree-stdarg.c (optimize_va_list_gpr_fpr_size): Likewise.
2895 * tree-tailcall.c (find_tail_calls): Likewise.
2896 * tree.c (need_assembler_name_p): Likewise.
2897 (free_lang_data_in_decl): Likewise.
2898 (get_call_combined_fn): Likewise.
2899 * ubsan.c (is_ubsan_builtin_p): Likewise.
2900 * varasm.c (incorporeal_function_p): Likewise.
2901 * tree.h (DECL_BUILT_IN): Remove and replace with
2903 (DECL_BUILT_IN_P): Transfort to fndecl_built_in_p.
2904 (fndecl_built_in_p): New.
2906 2018-08-27 Martin Liska <mliska@suse.cz>
2908 PR tree-optimization/86847
2909 * tree-switch-conversion.c (switch_decision_tree::dump_case_nodes):
2910 Dump also subtree probability.
2911 (switch_decision_tree::do_jump_if_equal): New function.
2912 (switch_decision_tree::emit_case_nodes): Handle special
2913 situations in balanced tree that can be emitted much simpler.
2914 Fix calculation of probabilities that happen in tree expansion.
2915 * tree-switch-conversion.h (struct cluster): Add
2917 (struct simple_cluster): Likewise.
2918 (struct case_tree_node): Add new function has_child.
2919 (do_jump_if_equal): New.
2921 2018-08-27 Martin Liska <mliska@suse.cz>
2923 * tree-switch-conversion.c (bit_test_cluster::find_bit_tests):
2924 Add new argument to bit_test_cluster constructor.
2925 (bit_test_cluster::emit): Set bits really number of values
2927 (bit_test_cluster::hoist_edge_and_branch_if_true): Add
2928 probability argument.
2929 * tree-switch-conversion.h (struct bit_test_cluster):
2930 Add m_handles_entire_switch.
2932 2018-08-27 Martin Liska <mliska@suse.cz>
2934 PR tree-optimization/86702
2935 * tree-switch-conversion.c (jump_table_cluster::emit):
2936 Make probabilities even for values in jump table
2937 according to number of cases handled.
2938 (switch_decision_tree::compute_cases_per_edge): Pass
2939 argument to reset_out_edges_aux function.
2940 (switch_decision_tree::analyze_switch_statement): Likewise.
2941 * tree-switch-conversion.h (switch_decision_tree::reset_out_edges_aux):
2944 2018-08-27 Martin Liska <mliska@suse.cz>
2946 * cfgexpand.c (expand_asm_stmt): Use label_to_block and pass
2947 cfun argument explicitly.
2948 * gimple-pretty-print.c (dump_gimple_switch): Likewise.
2949 * hsa-gen.c (gen_hsa_insns_for_switch_stmt): Use new
2950 function gimple_switch_default_bb.
2951 (convert_switch_statements):
2953 * ipa-fnsummary.c (set_switch_stmt_execution_predicate):
2954 * stmt.c (label_to_block_fn): Use label_to_block and pass
2955 cfun argument explicitly and use gimple_switch_label_bb.
2956 (expand_case): Likewise.
2957 * tree-cfg.c (lower_phi_internal_fn): Use label_to_block and pass
2958 cfun argument explicitly. Likewise.
2959 (make_edges_bb): Likewise.
2960 (make_cond_expr_edges): Likewise.
2961 (get_cases_for_edge): Likewise.
2962 (make_gimple_switch_edges): Likewise.
2963 (label_to_block_fn): Likewise.
2964 (label_to_block): Likewise.
2965 (make_goto_expr_edges): Likewise.
2966 (make_gimple_asm_edges): Likewise.
2967 (main_block_label): Likewise.
2968 (group_case_labels_stmt): Likewise.
2969 (find_taken_edge_computed_goto): Likewise.
2970 (find_taken_edge_switch_expr): Likewise.
2971 (gimple_verify_flow_info): Likewise.
2972 (gimple_redirect_edge_and_branch): Likewise.
2973 (gimple_switch_label_bb): New function.
2974 (gimple_switch_default_bb): Likewise.
2975 (gimple_switch_edge): Likewise.
2976 (gimple_switch_default_edge): Likewise.
2977 * tree-cfg.h (label_to_block_fn): Remove and replace ...
2978 (label_to_block): ... with this.
2979 (gimple_switch_label_bb): New.
2980 (gimple_switch_default_bb): Likewise.
2981 (gimple_switch_edge): Likewise.
2982 (gimple_switch_default_edge): Likewise.
2983 * tree-cfgcleanup.c (convert_single_case_switch): Use
2984 new gimple functions and pass new argument to label_to_block.
2985 (cleanup_control_flow_bb):
2986 * tree-eh.c (make_eh_dispatch_edges): Use label_to_block and pass
2987 cfun argument explicitly.
2988 (make_eh_edges): Likewise.
2989 (redirect_eh_dispatch_edge): Likewise.
2990 (lower_resx): Likewise.
2991 (lower_eh_dispatch): Likewise.
2992 (maybe_remove_unreachable_handlers): Likewise.
2993 (unsplit_eh): Likewise.
2994 (cleanup_empty_eh): Likewise.
2995 (verify_eh_edges): Likewise.
2996 (verify_eh_dispatch_edge): Likewise.
2997 * tree-ssa-dom.c (record_edge_info): Likewise.
2998 * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): Likewise.
2999 * tree-ssa-threadedge.c (thread_around_empty_blocks): Likewise.
3000 (thread_through_normal_block): Likewise.
3001 * tree-ssa-uncprop.c (associate_equivalences_with_edges): Likewise.
3002 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds):
3003 * tree-switch-conversion.c (switch_conversion::collect): Use new
3005 (switch_conversion::check_final_bb): Likewise.
3006 (switch_conversion::gather_default_values): Pass new argument
3008 (switch_conversion::build_constructors): Likewise.
3009 (switch_decision_tree::compute_cases_per_edge): Use new
3010 gimple_switch_edge function.
3011 (switch_decision_tree::analyze_switch_statement): Pass new argument
3013 (switch_decision_tree::try_switch_expansion): Use
3014 gimple_switch_default_edge.
3015 * tree-vrp.c (find_switch_asserts): Pass new argument
3017 * vr-values.c (vr_values::vrp_visit_switch_stmt): Likewise.
3018 (vr_values::simplify_switch_using_ranges): Likewise.
3020 2018-08-27 Richard Biener <rguenther@suse.de>
3022 * cfganal.h (rev_post_order_and_mark_dfs_back_seme): Declare.
3023 * cfganal.c (rev_post_order_and_mark_dfs_back_seme): New function.
3025 * tree-ssa-sccvn.h (struct vn_pval): New structure.
3026 (struct vn_nary_op_s): Add unwind_to member. Add
3027 predicated_values flag and put result into a union together
3028 with a linked list of vn_pval.
3029 (struct vn_ssa_aux): Add name member to make maintaining
3030 a map of SSA name to vn_ssa_aux possible. Remove no longer
3031 needed info, dfsnum, low, visited, on_sccstack, use_processed
3032 and range_info_anti_range_p members.
3033 (run_scc_vn, vn_eliminate, free_scc_vn, vn_valueize): Remove.
3034 (do_rpo_vn, run_rpo_vn, eliminate_with_rpo_vn, free_rpo_vn):
3036 (vn_valueize): New global.
3037 (vn_context_bb): Likewise.
3038 (VN_INFO_RANGE_INFO, VN_INFO_ANTI_RANGE_P, VN_INFO_RANGE_TYPE,
3039 VN_INFO_PTR_INFO): Remove.
3040 * tree-ssa-sccvn.c: ... (rewrite)
3041 (pass_fre::execute): For -O2+ initialize loops and run
3042 RPO VN in optimistic mode (iterating). For -O1 and -Og
3043 run RPO VN in non-optimistic mode.
3044 * params.def (PARAM_SCCVN_MAX_SCC_SIZE): Remove.
3045 (PARAM_RPO_VN_MAX_LOOP_DEPTH): Add.
3046 * doc/invoke.texi (sccvn-max-scc-size): Remove.
3047 (rpo-vn-max-loop-depth): Document.
3048 * tree-ssa-alias.c (walk_non_aliased_vuses): Stop walking
3049 when valuezing the VUSE signals we walked out of the region.
3050 * tree-ssa-pre.c (phi_translate_1): Ignore predicated values.
3051 (phi_translate): Set VN context block to use for availability
3053 (compute_avail): Likewise.
3054 (pre_valueize): New function.
3055 (pass_pre::execute): Adjust to the RPO VN API.
3057 * tree-ssa-loop-ivcanon.c: Include tree-ssa-sccvn.h.
3058 (propagate_constants_for_unrolling): Remove.
3059 (tree_unroll_loops_completely): Perform value-numbering
3060 on the unrolled bodies loop parent.
3062 2018-08-27 Richard Biener <rguenther@suse.de>
3064 * tree-ssa-pre.c (compute_antic): Re-use inverted postorder
3065 for partial antic compute.
3067 2018-08-27 Jakub Jelinek <jakub@redhat.com>
3069 PR rtl-optimization/87065
3070 * combine.c (simplify_if_then_else): Formatting fix.
3071 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
3073 (known_cond): Don't return const_true_rtx for vector modes. Use
3074 CONST0_RTX instead of const0_rtx. Formatting fixes.
3076 2018-08-27 Martin Liska <mliska@suse.cz>
3078 PR gcov-profile/87069
3079 * gcov.c (process_file): Record files already processed
3080 and warn about a file being processed multiple times.
3082 2018-08-27 Martin Liska <mliska@suse.cz>
3085 * config/aarch64/aarch64.c (aarch64_override_options_internal):
3086 Set default values for x_aarch64_*_string strings.
3087 * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}==
3088 prefix. For -mabi do not print '=ABI' in help and use
3089 <option_value> format for -msve-vector-bits and -moverride
3092 2018-08-26 Jeff Law <law@redhat.com>
3094 * config/mips/frame-header-opt.c: Include "backend.h" rather than
3097 2018-08-26 Marek Polacek <polacek@redhat.com>
3099 PR c++/87029, Implement -Wredundant-move.
3100 * doc/invoke.texi: Document -Wredundant-move.
3102 2018-08-25 Martin Sebor <msebor@redhat.com>
3104 PR tree-optimization/87059
3105 * builtins.c (expand_builtin_strncmp): Convert MIN_EXPR operand
3106 to the same type as the other.
3107 * fold-const.c (fold_binary_loc): Assert expectation.
3109 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
3111 * config/darwin.c (machopic_legitimize_pic_address): Clean up
3112 extraneous parentheses, dead code section and formatting.
3114 2018-08-24 David Malcolm <dmalcolm@redhat.com>
3117 * diagnostic-show-locus.c (layout::layout): Ensure the margin is
3118 wide enough for jumps in the line-numbering to be visible.
3119 (layout::print_gap_in_line_numbering): New member function.
3120 (layout::calculate_line_spans): When using line numbering, merge
3121 line spans that are only 1 line apart.
3122 (diagnostic_show_locus): When printing line numbers, show gaps in
3123 line numbering directly, rather than printing headers.
3124 (selftest::test_diagnostic_show_locus_fixit_lines): Add test of
3125 line-numbering with multiple line spans.
3126 (selftest::test_fixit_insert_containing_newline_2): Add test of
3127 line-numbering, in which the spans are close enough to be merged.
3129 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
3131 * gimple-ssa-evrp-analyze.c (set_ssa_range_info): Pass value_range
3132 to range_includes_zero_p. Do not special case VR_ANTI_RANGE.
3133 * tree-vrp.c (range_is_nonnull): Remove.
3134 (range_includes_zero_p): Accept value_range instead of min/max.
3135 (extract_range_from_binary_expr_1): Do not early bail on
3137 Use range_includes_zero_p instead of range_is_nonnull.
3138 (extract_range_from_unary_expr): Use range_includes_zero_p instead
3139 of range_is_nonnull.
3140 (vrp_meet_1): Pass value_range to range_includes_zero_p. Do not
3141 special case VR_ANTI_RANGE.
3142 (vrp_finalize): Same.
3143 * tree-vrp.h (range_includes_zero_p): Pass value_range as argument
3145 (range_is_nonnull): Remove.
3146 * vr-values.c (vrp_stmt_computes_nonzero): Use
3147 range_includes_zero_p instead of range_is_nonnull.
3148 (extract_range_basic): Pass value_range to range_includes_zero_p
3149 instead of range_is_nonnull.
3151 2018-08-24 Uros Bizjak <ubizjak@gmail.com>
3153 * emit-rtl.c (init_emit_once): Do not emit MODE_POINTER_BOUNDS RTXes.
3154 * emit-rtl.h (rtl_data): Remove return_bnd.
3155 * explow.c (trunc_int_for_mode): Do not handle POINTER_BOUNDS_MODE_P.
3156 * function.c (diddle_return_value): Do not handle crtl->return_bnd.
3157 * genmodes.c (complete_mode): Do not handle MODE_POINTER_BOUNDS.
3158 (POINTER_BOUNDS_MODE): Remove definition.
3159 (make_pointer_bounds_mode): Remove.
3160 (get_mode_class): Do not handle MODE_POINTER_BOUNDS.
3161 * machmode.h (POINTER_BOUNDS_MODE_P): Remove definition.
3162 (scalare_mode::includes_p): Do not handle MODE_POINTER_BOUNDS.
3163 * mode-classes.def: Do not define MODE_POINTER_BOUNDS.
3164 * stor-layout.c (int_mode_for_mode): Do not handle MODE_POINTER_BOUNDS.
3165 * tree-core.h (enum tree_index): Remove TI_POINTER_BOUNDS_TYPE.
3166 * varasm.c (output_constant_pool_2): Do not handle MODE_POINTER_BOUNDS.
3168 * config/i386/i386-modes.def (BND32, BND64): Remove.
3169 * config/i386/i386.c (dbx_register_map): Remove bound registers.
3170 (dbx64_register_map): Ditto.
3171 (svr4_dbx_register_map): Ditto.
3172 (indirect_thunk_bnd_needed): Remove.
3173 (indirect_thunks_bnd_used): Ditto.
3174 (indirect_return_bnd_needed): Ditto.
3175 (indirect_return_via_cx_bnd): Ditto.
3176 (enum indirect_thunk_prefix): Remove indirect_thunk_prefix_bnd.
3177 (indirect_thunk_name): Remove handling of indirect_thunk_prefix_bnd.
3178 (output_indirect_thunk): Ditto. Remove need_prefix argument.
3179 (output_indirect_thunk_function): Remove handling of
3180 indirect_return_bnd_needed, indirect_return_via_cx_bnd,
3181 indirect_thunk_bnd_needed and indirect_thunks_bnd_used variables.
3182 (ix86_save_reg): Remove handling of crtl->return_bnd.
3183 (ix86_legitimate_constant_p): Remove handling of POINTER_BOUNDS_MODE_P.
3184 (ix86_print_operand_address_as): Remove handling of UNSPEC_BNDMK_ADDR
3185 and UNSPEC_BNDLX_ADDR.
3186 (ix86_output_indirect_branch_via_reg): Remove handling of
3187 indirect_thunk_prefix_bnd.
3188 (ix86_output_indirect_branch_via_push): Ditto.
3189 (ix86_output_function_return): Ditto.
3190 (ix86_output_indirect_function_return): Ditto.
3191 (avoid_func_arg_motion): Do not handle UNSPEC_BNDSTX.
3192 * config/i386/i386.h (FIXED_REGISTERS): Remove bound registers.
3193 (CALL_USED_REGISTERS): Ditto.
3194 (REG_ALLOC_ORDER): Update for removal of bound registers.
3195 (HI_REGISTER_NAMES): Ditto.
3196 * config/i386/i386.md (UNSPEC_BNDMK, UNSPEC_BNDMK_ADDR, UNSPEC_BNDSTX)
3197 (UNSPEC_BNDLDX, UNSPEC_BNDLDX_ADDR, UNSPEC_BNDCL, UNSPEC_BNDCU)
3198 (UNSPEC_BNDCN, UNSPEC_MPX_FENCE): Remove.
3199 (BND0_REG, BND1_REG, BND2_REG, BND3_REG): Remove
3200 (FIRST_PSEUDO_REG): Update.
3201 (BND): Remove mode iterator.
3202 * config/i386/predicates.md (bnd_mem_operator): Remove.
3204 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
3206 * tree-vect-stmts.c (vectorizable_bswap): Handle variable-length
3209 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
3211 * tree-vect-slp.c (vect_transform_slp_perm_load): Separate out
3212 the case in which the permute needs only a single element and
3213 repeats for every vector of the result. Extend that case to
3214 handle variable-length vectors.
3215 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
3217 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
3220 * dwarf2out.c (save_macinfo_strings): Call set_indirect_string
3221 on DW_MACINFO_start_file for -gsplit-dwarf -g3.
3223 2018-08-24 Richard Biener <rguenther@suse.de>
3225 * cfg.h (struct control_flow_graph): Add edge_flags_allocated and
3226 bb_flags_allocated members.
3227 (auto_flag): New RAII class for allocating flags.
3228 (auto_edge_flag): New RAII class for allocating edge flags.
3229 (auto_bb_flag): New RAII class for allocating bb flags.
3230 * cfgloop.c (verify_loop_structure): Allocate temporary edge
3232 * cfganal.c (dfs_enumerate_from): Remove use of visited sbitmap
3233 in favor of temporarily allocated BB flag.
3234 * hsa-brig.c: Re-order includes.
3235 * hsa-dump.c: Likewise.
3236 * hsa-regalloc.c: Likewise.
3237 * print-rtl.c: Likewise.
3238 * profile-count.c: Likewise.
3240 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
3243 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
3246 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
3249 * wide-int-range.cc (wide_int_range_div): Do not ignore result
3250 from wide_int_range_multiplicative_op.
3252 2018-08-23 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
3254 * tree-vect-data-refs.c (vect_grouped_store_supported): Fix typo
3257 2018-08-23 Giuliano Belinassi <giuliano.belinassi@usp.br>
3259 * genmatch.c (parser::parse_operation): Fix typo 'exapnded'
3262 2018-08-23 Alexander Monakov <amonakov@ispras.ru>
3264 * tree-scalar-evolution.c (final_value_replacement_loop): Dump
3265 full GENERIC expression used for replacement.
3267 2018-08-23 Aldy Hernandez <aldyh@redhat.com>
3269 * tree-vrp.c (abs_extent_range): Remove.
3270 (extract_range_into_wide_ints): Pass wide ints by reference.
3271 (extract_range_from_binary_expr_1): Rewrite the *DIV_EXPR code.
3272 Pass wide ints by reference in all calls to
3273 extract_range_into_wide_ints.
3274 * wide-int-range.cc (wide_int_range_div): New.
3275 * wide-int-range.h (wide_int_range_div): New.
3276 (wide_int_range_includes_zero_p): New.
3277 (wide_int_range_zero_p): New.
3279 2018-08-23 Matthew Malcomson <matthew.malcomson@arm.com>
3281 * config/aarch64/aarch64.md (arches): New enum.
3282 (arch): New enum attr.
3283 (arch_enabled): New attr.
3284 (enabled): Now uses arch_enabled only.
3285 (simd, sve, fp16): Removed attribute.
3286 (fp): Attr now defined in terms of 'arch'.
3287 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64, *movti_aarch64,
3288 *movhf_aarch64, <optab><fcvt_target><GPF:mode>2,
3289 <FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3,
3290 <FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Merge 'fp' and 'simd'
3291 attributes into 'arch'.
3292 (*movsf_aarch64, *movdf_aarch64, *movtf_aarch64, *add<mode>3_aarch64,
3293 subdi3, neg<mode>2, <optab><mode>3, one_cmpl<mode>2,
3294 *<NLOGICAL:optab>_one_cmpl<mode>3, *xor_one_cmpl<mode>3,
3295 *aarch64_ashl_sisd_or_int_<mode>3, *aarch64_lshr_sisd_or_int_<mode>3,
3296 *aarch64_ashr_sisd_or_int_<mode>3, *aarch64_sisd_ushl): Convert use of
3297 'simd' attribute into 'arch'.
3298 (load_pair_sw_<SX:mode><SX2:mode>, load_pair_dw_<DX:mode><DX2:mode>,
3299 store_pair_sw_<SX:mode><SX2:mode>, store_pair_dw_<DX:mode><DX2:mode>):
3300 Convert use of 'fp' attribute to 'arch'.
3301 * config/aarch64/aarch64-simd.md (move_lo_quad_internal_<mode>,
3302 move_lo_quad_internal_<mode>): (different modes) Merge 'fp' and 'simd'
3304 (move_lo_quad_internal_be_<mode>, move_lo_quad_internal_be_<mode>):
3305 (different modes) Merge 'fp' and 'simd' into 'arch'.
3306 (*aarch64_combinez<mode>, *aarch64_combinez_be<mode>): Merge 'fp' and
3309 2018-08-23 Segher Boessenkool <segher@kernel.crashing.org>
3311 PR rtl-optimization/87026
3312 * expmed.c (canonicalize_comparison): If we can no longer create
3313 pseudoregisters, don't.
3315 2018-08-23 Richard Earnshaw <rearnsha@arm.com>
3318 * config/arm/arm-protos.h (arm_emit_speculation_barrier): New
3320 * config/arm/arm.c (speculation_barrier_libfunc): New static
3322 (arm_init_libfuncs): Initialize it.
3323 (arm_emit_speculation_barrier): New function.
3324 * config/arm/arm.md (speculation_barrier): Call
3325 arm_emit_speculation_barrier for architectures that do not have
3327 (speculation_barrier_insn): Only match on Armv7 or later.
3329 2018-08-23 Richard Biener <rguenther@suse.de>
3332 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
3335 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
3337 * config/aarch64/aarch64.c (aarch64_evpc_sve_tbl): Fix handling
3338 of single-vector TBLs.
3339 (aarch64_vectorize_vec_perm_const): Set one_vector_p when only
3342 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
3345 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
3346 aarch64_evpc_tbl guard.
3348 2018-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
3350 * tree-ssa-dse.c (compute_trims): Avoid folding away undefined
3353 2018-08-22 Martin Sebor <msebor@redhat.com>
3356 * tree-pretty-print.c (pretty_print_string): Add argument.
3357 (dump_generic_node): Call to pretty_print_string with string size.
3359 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
3361 PR rtl-optimization/86771
3362 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
3363 of two SETs into those two SETs, one to be placed at i2, if that SETs
3364 destination is modified between i2 and i3.
3366 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
3368 PR tree-optimization/86725
3369 * tree-vect-loop.c (vect_inner_phi_in_double_reduction_p): New
3371 (vect_analyze_scalar_cycles_1): Check it.
3373 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
3375 PR tree-optimization/86725
3376 * tree-vect-loop.c (vect_is_simple_reduction): When treating
3377 an outer loop phi as a double reduction, make sure that the
3378 single user of the phi result is an inner loop phi.
3380 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
3382 * tree-vect-data-refs.c (vect_analyze_group_access_1): Convert
3383 grouped stores with gaps to a strided group.
3385 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
3387 * tree-vect-stmts.c (get_group_load_store_type)
3388 (get_load_store_type): Only test STMT_VINFO_STRIDED_P for the
3389 first statement in a group.
3391 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
3393 * config/darwin.h (LINK_COMMAND_SPEC_A): Sync LTO options with
3394 the sequence used in gcc/gcc.c.
3396 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
3399 * gcc-ar.c (main): Don’t try to invoke the plug-in if we’re not
3402 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
3404 * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Adjust to use the
3405 Darwin10-specific unwinder-shim.
3406 * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Remove.
3407 * config/rs6000/darwin.h (DARWIN_CRT1_SPEC, DARWIN_DYLIB1_SPEC):
3408 New to cater for Darwin10 Rosetta.
3410 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
3412 * config/i386/i386.c (ix86_output_addr_diff_elt): Move the MACH-O
3413 specific test before the one for HAVE_AS_GOTOFF_IN_DATA.
3415 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
3420 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
3421 (dwarf2out_switch_text_section): Generate a local label for the
3422 second function sub-section and apply it as the second FDE start
3424 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
3425 second sub-section start.
3427 2018-08-22 Richard Biener <rguenther@suse.de>
3429 PR tree-optimization/86988
3430 * tree-vrp.c (vrp_prop::check_mem_ref): Bail out on VLAs.
3432 2018-08-22 Richard Biener <rguenther@suse.de>
3434 PR tree-optimization/86945
3435 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
3437 2018-08-22 Alexandre Oliva <oliva@adacore.com>
3439 * config/rs6000/rs6000.c (SMALL_DATA_RELOC, SMALL_DATA_REG): Add
3440 a comment about how uses of r2 for .sdata2 come about.
3442 2018-08-22 Alexandre Oliva <aoliva@redhat.com>
3444 * tree-ssa-reassoc.c (is_reassociable_op): Fix cut&pasto.
3446 2018-08-21 Marek Polacek <polacek@redhat.com>
3448 PR c++/86981, Implement -Wpessimizing-move.
3449 * doc/invoke.texi: Document -Wpessimizing-move.
3451 2018-08-21 Jan Hubicka <jh@suse.cz>
3453 * tree.c (find_decls_types_r): Do not check for redundant typedefs.
3454 * tree.h (is_redundant_typedef): Remove.
3455 * dwarf2out.c (is_redundant_typedef): Turn into static function.
3457 2018-08-21 Jan Hubicka <jh@suse.cz>
3459 * tree.c (free_lang_data_in_decl): Remove types from DECL_CONTEXT
3462 2018-08-21 Tamar Christina <tamar.christina@arm.com>
3464 * expmed.c (extract_low_bits): Reject invalid subregs early.
3466 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
3469 * tree-ssa-strlen.c (adjust_last_stmt): Avoid folding away undefined
3472 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
3474 * config/vxworks.h: Guard vxworks_asm_out_constructor and
3475 vxworks_asm_out_destructor by !HAVE_INITFINI_ARRAY_SUPPORT
3476 * config/vxworks.c: Likewise.
3478 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
3480 * config/vxworks.c: Set targetm.have_ctors_dtors
3481 if HAVE_INITFINI_ARRAY_SUPPORT.
3482 * config/vxworks.h: Set SUPPORTS_INIT_PRIORITY
3483 if HAVE_INITFINI_ARRAY_SUPPORT.
3485 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
3487 * config/vxworks.h: Add $(WIND_BASE)/target/h/wrn/coreip to
3488 default search path for VxWorks < 7.
3490 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
3492 * gimple-ssa-sprintf.c (decl_constant_value): Remove.
3493 (get_format_string): Refer to c_getstr.
3495 2018-08-21 Tom de Vries <tdevries@suse.de>
3497 * cgraph.h (debuginfo_early_init, debuginfo_init, debuginfo_fini)
3498 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
3499 (debuginfo_early_stop): Declare.
3500 * cgraphunit.c (debuginfo_early_init, debuginfo_init, debuginfo_fini)
3501 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
3502 (debuginfo_early_stop): New function.
3503 (symbol_table::finalize_compilation_unit): Call debuginfo_early_start
3504 and debuginfo_early_stop.
3505 * dwarf2out.c (dwarf2out_finish, dwarf2out_early_finish): Dump dwarf.
3506 * toplev.c (compile_file): Call debuginfo_start and debuginfo_stop.
3507 (general_init): Call debuginfo_early_init.
3508 (finalize): Call debuginfo_fini.
3509 (do_compile): Call debuginfo_init.
3510 * doc/invoke.texi (@gccoptlist): Add -fdump-debug and
3512 (@item -fdump-debug, @item -fdump-earlydebug): Add.
3514 2018-08-21 Tom de Vries <tdevries@suse.de>
3516 * dwarf2out.c (print_dw_val, print_loc_descr, print_die): Handle
3517 flag_dump_noaddr and flag_dump_unnumbered.
3519 2018-08-21 Aldy Hernandez <aldyh@redhat.com>
3521 * wide-int-range.cc (wide_int_range_abs): New.
3522 (wide_int_range_order_set): Rename from wide_int_range_min_max.
3523 * wide-int-range.h (wide_int_range_abs): New.
3524 (wide_int_range_min_max): New.
3525 * tree-vrp.c (extract_range_from_unary_expr): Rewrite ABS_EXPR
3526 case to call wide_int_range_abs.
3527 Rewrite MIN/MAX_EXPR to call wide_int_range_min_max.
3528 (extract_range_from_abs_expr): Delete.
3530 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
3533 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
3534 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
3537 2018-08-20 Nathan Sidwell <nathan@acm.org>
3538 Jeff Law <law@redhat.com>
3540 * config/s390/s390-c (s390_macro_to_expand): Use cpp_macro_p.
3541 * config/spu/spu-c.c (spu_macro_to_expand): Likewise.
3543 2018-08-20 David Malcolm <dmalcolm@redhat.com>
3546 * attribs.c (diag_attr_exclusions): Add auto_diagnostic_group instance.
3547 (decl_attributes): Likewise.
3548 * calls.c (maybe_warn_nonstring_arg): Add auto_diagnostic_group
3550 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
3551 * diagnostic-core.h (class auto_diagnostic_group): New class.
3552 * diagnostic.c (diagnostic_initialize): Initialize the new fields.
3553 (diagnostic_report_diagnostic): Handle the first diagnostics within
3555 (emit_diagnostic): Add auto_diagnostic_group instance.
3557 (inform_n): Likewise.
3558 (warning): Likewise.
3559 (warning_at): Likewise.
3560 (warning_n): Likewise.
3561 (pedwarn): Likewise.
3562 (permerror): Likewise.
3564 (error_n): Likewise.
3565 (error_at): Likewise.
3567 (fatal_error): Likewise.
3568 (internal_error): Likewise.
3569 (internal_error_no_backtrace): Likewise.
3570 (auto_diagnostic_group::auto_diagnostic_group): New ctor.
3571 (auto_diagnostic_group::~auto_diagnostic_group): New dtor.
3572 * diagnostic.h (struct diagnostic_context): Add fields
3573 "diagnostic_group_nesting_depth",
3574 "diagnostic_group_emission_count", "begin_group_cb",
3576 * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior):
3577 Add auto_diagnostic_group instance(s).
3578 (find_explicit_erroneous_behavior): Likewise.
3579 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Likewise.
3580 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Likewise.
3581 * gimplify.c (warn_implicit_fallthrough_r): Likewise.
3582 (gimplify_va_arg_expr): Likewise.
3583 * hsa-gen.c (HSA_SORRY_ATV): Likewise.
3584 (HSA_SORRY_AT): Likewise.
3585 * ipa-devirt.c (compare_virtual_tables): Likewise.
3586 (warn_odr): Likewise.
3587 * multiple_target.c (expand_target_clones): Likewise.
3588 * opts-common.c (cmdline_handle_error): Likewise.
3589 * reginfo.c (globalize_reg): Likewise.
3590 * substring-locations.c (format_warning_n_va): Likewise.
3591 * tree-inline.c (expand_call_inline): Likewise.
3592 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Likewise.
3593 * tree-ssa-loop-niter.c
3594 (do_warn_aggressive_loop_optimizations): Likewise.
3595 * tree-ssa-uninit.c (warn_uninit): Likewise.
3596 * tree.c (warn_deprecated_use): Likewise.
3598 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
3601 * config/i386/i386.md (eh_return): Always update EH return
3602 address in word_mode.
3604 2018-08-20 Chung-Lin Tang <cltang@codesourcery.com>
3606 * targhooks.c (std_gimplify_va_arg_expr): Properly handle case of when
3607 TARGET_SPLIT_COMPLEX_ARG is defined.
3609 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
3611 * expr.c (store_field): Change gcc_assert to gcc_checking_assert.
3613 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
3616 * expr.c (expand_assignment): Assert that bitpos is positive.
3617 (store_field): Likewise
3618 (expand_expr_real_1): Make sure that bitpos is positive.
3619 * config/alpha/alpha.h (CONSTANT_ADDRESS_P): Avoid signed
3622 2018-08-20 Nathan Sidwell <nathan@acm.org>
3624 * Makefile.in (CPP_ID_DATA_H): Delete.
3625 (CPP_INTERNAL_H): Don't add it.
3626 (GTFILES): Replace CPP_ID_DATA_H with CPPLIB_H.
3627 * gengtype.c (open_base_files): Replace cpp-id-data.h with cpplib.h
3629 2018-08-20 Richard Biener <rguenther@suse.de>
3631 PR tree-optimization/78655
3632 * tree-vrp.c (extract_range_from_binary_expr_1): Make
3633 pointer + offset nonnull if either operand is nonnull work.
3635 2018-08-20 Tom de Vries <tdevries@suse.de>
3637 * dwarf2out.c (add_scalar_info): Don't add reference to existing die
3638 unless the referenced die describes the added property using
3639 DW_AT_location or DW_AT_const_value. Fall back to exprloc case.
3640 Otherwise, add a DW_AT_location to the referenced die.
3642 2018-08-19 Uros Bizjak <ubizjak@gmail.com>
3645 * config/i386/i386.c (ix86_rtx_costs) [case SET]: Check source for
3646 register_operand when calling ix86_set_reg_reg_cost.
3647 [case CONST_INT, case CONST, case LABEL_REF, case SYMBOL_REF]:
3648 Set *total to 0 for operands that satisfy x86_64_immediate_operand
3649 predicate and to 1 otherwise.
3651 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
3653 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
3654 emit a diagnostic that it is not supported and reset the option.
3655 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
3656 supported and consume the option. (ASM_FINAL_SPEC): New.
3658 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
3660 * doc/md.texi (Patterns): Use @ref instead of @xref in the middle of
3663 2018-08-17 Sandra Loosemore <sandra@codesourcery.com>
3665 C-SKY port: Documentation
3667 * doc/extend.texi (C-SKY Function Attributes): New section.
3668 * doc/invoke.texi (Option Summary): Add C-SKY options.
3669 (C-SKY Options): New section.
3670 * doc/md.texi (Machine Constraints): Document C-SKY constraints.
3672 2018-08-17 Jojo <jijie_rong@c-sky.com>
3673 Huibin Wang <huibin_wang@c-sky.com>
3674 Sandra Loosemore <sandra@codesourcery.com>
3675 Chung-Lin Tang <cltang@codesourcery.com>
3677 C-SKY port: Backend implementation
3679 * config/csky/*: New.
3680 * common/config/csky/*: New.
3682 2018-08-17 Jojo <jijie_rong@c-sky.com>
3683 Huibin Wang <huibin_wang@c-sky.com>
3684 Sandra Loosemore <sandra@codesourcery.com>
3685 Chung-Lin Tang <cltang@codesourcery.com>
3686 Andrew Jenner <andrew@codesourcery.com>
3688 C-SKY port: Configury
3690 * config.gcc (csky-*-*): New.
3691 * configure.ac: Add csky to targets for dwarf2 debug_line support.
3692 * configure: Regenerated.
3694 2018-08-17 David Malcolm <dmalcolm@redhat.com>
3696 * dump-context.h: Include "dumpfile.h".
3697 (dump_context::dump_printf_va): Convert final param from va_list
3698 to va_list *. Convert from ATTRIBUTE_PRINTF to
3699 ATTRIBUTE_GCC_DUMP_PRINTF.
3700 (dump_context::dump_printf_loc_va): Likewise.
3701 * dumpfile.c: Include "stringpool.h".
3702 (make_item_for_dump_printf_va): Delete.
3703 (make_item_for_dump_printf): Delete.
3704 (class dump_pretty_printer): New class.
3705 (dump_pretty_printer::dump_pretty_printer): New ctor.
3706 (dump_pretty_printer::emit_items): New member function.
3707 (dump_pretty_printer::emit_any_pending_textual_chunks): New member
3709 (dump_pretty_printer::emit_item): New member function.
3710 (dump_pretty_printer::stash_item): New member function.
3711 (dump_pretty_printer::format_decoder_cb): New member function.
3712 (dump_pretty_printer::decode_format): New member function.
3713 (dump_context::dump_printf_va): Reimplement in terms of
3714 dump_pretty_printer.
3715 (dump_context::dump_printf_loc_va): Convert final param from va_list
3717 (dump_context::begin_scope): Reimplement call to
3718 make_item_for_dump_printf.
3719 (dump_printf): Update for change to dump_printf_va.
3720 (dump_printf_loc): Likewise.
3721 (selftest::test_capture_of_dump_calls): Convert "stmt" from
3722 greturn * to gimple *. Add a test_decl. Add tests of dump_printf
3723 with %T, %E, and %G.
3724 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): New macro.
3725 (dump_printf): Replace ATTRIBUTE_PRINTF_2 with
3726 ATTRIBUTE_GCC_DUMP_PRINTF (2, 3).
3727 (dump_printf_loc): Replace ATTRIBUTE_PRINTF_3 with
3728 ATTRIBUTE_GCC_DUMP_PRINTF (3, 0).
3729 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Convert
3730 use of HOST_WIDE_INT_PRINT_DEC on unsigned HOST_WIDE_INT "count"
3731 within a dump_printf_loc call to "%wu".
3732 (vector_alignment_reachable_p): Merge two dump_printf[_loc] calls,
3733 converting a use of HOST_WIDE_INT_PRINT_DEC to "%wd". Add a
3734 missing space after "=".
3735 * tree-vect-loop.c (vect_analyze_loop_2) Within a dump_printf
3736 call, convert use of HOST_WIDE_INT_PRINT_DEC to "%wd".
3737 * tree-vect-slp.c (vect_slp_bb): Within a dump_printf_loc call,
3738 convert use of HOST_WIDE_INT_PRINT_UNSIGNED to "%wu".
3739 * tree-vectorizer.c (try_vectorize_loop_1): Likewise. Remove
3740 duplicate "vectorized" from message.
3742 2018-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
3744 * config/arm/arm-builtins.c (arm_init_simd_builtin_types): Clear
3745 polyNxK_t element's TYPE_STRING_FLAG.
3747 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
3749 * config/rs6000/rs6000.md (*cbranch, *creturn): Name these patterns
3750 (they were unnamed before). Fix comments.
3752 2018-08-17 Nathan Sidwell <nathan@acm.org>
3754 * cppbuiltin.c: Include "cpplib.h", not "cpp-id-data.h".
3756 2018-08-17 Richard Biener <rguenther@suse.de>
3758 PR tree-optimization/86841
3759 * wide-int-range.cc (wide_int_range_lshift): Use to_uhwi.
3761 2018-08-17 Martin Liska <mliska@suse.cz>
3763 * common.opt: Remove Warn, Init and Report for options with
3764 Ignore/Deprecated flag. Warning is done automatically for
3766 * config/i386/i386.opt: Likewise.
3767 * config/ia64/ia64.opt: Likewise.
3768 * config/rs6000/rs6000.opt: Likewise.
3769 * cppbuiltin.c (define_builtin_macros_for_compilation_flags):
3770 Remove usage of flag_check_pointer_bounds.
3771 * lto-wrapper.c (merge_and_complain): Do not handle
3772 OPT_fcheck_pointer_bounds.
3773 (append_compiler_options): Likewise.
3774 * opt-functions.awk: Do not handle Deprecated.
3775 * optc-gen.awk: Check that Var, Report and Init are not
3776 used for an option with Ignore/Deprecated flag.
3777 * opts-common.c (decode_cmdline_option): Do not report
3779 (read_cmdline_option): Report warning for OPT_SPECIAL_deprecated
3781 * opts.h (struct cl_option): Remove cl_deprecated flag.
3782 (CL_ERR_DEPRECATED): Remove error enum value.
3784 2018-08-17 Richard Biener <rguenther@suse.de>
3787 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
3788 across a va-arg-pack using call adjust its return value accordingly.
3790 2018-08-16 Martin Sebor <msebor@redhat.com>
3792 PR tree-optimization/86853
3793 * gimple-ssa-sprintf.c (struct format_result): Rename member.
3794 (struct fmtresult): Add member and initialize it in ctors.
3795 (format_character): Handle %C. Extend range to NUL. Set MAYFAIL.
3796 (format_string): Handle %S the same as %ls. Set MAYFAIL.
3797 (format_directive): Set POSUNDER4K when MAYFAIL is set.
3798 (parse_directive): Handle %C same as %c.
3799 (sprintf_dom_walker::compute_format_length): Adjust.
3800 (is_call_safe): Adjust.
3802 2018-08-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
3804 * builtins.c (c_strlen): Add new parameter eltsize. Use it
3805 for determining how to count the elements.
3806 * builtins.h (c_strlen): Adjust prototype.
3807 * expr.c (string_constant): Add new parameter mem_size.
3808 Set *mem_size appropriately.
3809 * expr.h (string_constant): Adjust protoype.
3810 * gimple-fold.c (get_range_strlen): Add new parameter eltsize.
3811 * gimple-fold.h (get_range_strlen): Adjust prototype.
3812 * gimple-ssa-sprintf.c (get_string_length): Add new parameter eltsize.
3813 (format_string): Call get_string_length with eltsize.
3815 2018-08-16 David Malcolm <dmalcolm@redhat.com>
3817 * diagnostic.c (default_diagnostic_start_span_fn): Call pp_string
3818 to emit the span, rather than setting it as the prefix.
3820 2018-08-16 David Malcolm <dmalcolm@redhat.com>
3822 * diagnostic-show-locus.c (layout::start_annotation_line): Add
3823 "margin_char" parameter, defaulting to space. Use it in place
3824 of pp_space for the initial part of the margin.
3825 (layout::print_leading_fixits): Use '+' when filling the margin
3826 of line-insertion fix-it hints.
3828 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
3830 * config/rs6000/rs6000.md (two unnamed define_insn and define_split):
3833 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
3835 * config/rs6000/altivec.md: Don't set length attribute to the default
3837 * config/rs6000/darwin.md: Ditto.
3838 * config/rs6000/dfp.md: Ditto.
3839 * config/rs6000/htm.md: Ditto.
3840 * config/rs6000/rs6000.md: Ditto.
3841 * config/rs6000/sync.md: Ditto.
3842 * config/rs6000/vsx.md: Ditto.
3844 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
3846 * config/rs6000/altivec.md: Don't set length attribute to the default
3847 value, for branch instructions.
3848 * config/rs6000/darwin.md: Ditto.
3849 * config/rs6000/rs6000.md: Ditto.
3851 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
3853 * config/rs6000/rs6000.md (length): Always define as const_int 4.
3854 (unnamed conditional branch define_insn): Set length to 4 or 8
3855 depending on offset.
3856 (<bd>_<mode>): Similar, for alternative 0.
3857 (<bd>tf_<mode>): Ditto.
3859 2018-08-16 Tamar Christina <tamar.christina@arm.com>
3861 * expr.c (copy_blkmode_to_reg): Perform larger copies when safe.
3863 2018-08-16 Matthew Malcomson <matthew.malcomson@arm.com>
3865 * doc/rtl.texi: Replace old RTX class names with new names.
3868 2018-08-16 Vlad Lazar <vlad.lazar@arm.com>
3870 * expmed.h (canonicalize_comparison): New declaration.
3871 * expmed.c (canonicalize_comparison, equivalent_cmp_code): New function.
3872 * expmed.c (emit_store_flag_1): Add call to canonicalize_comparison.
3873 * optabs.c (prepare_cmp_insn): Likewise.
3874 * rtl.h (unsigned_condition_p): New function which checks if a
3875 comparison operator is unsigned.
3877 2018-08-16 Nathan Sidwell <nathan@acm.org>
3879 * config/rs6000/rs6000-c.c (rs6000_macro_to_expend): Use cpp_macro_p.
3880 * config/powerpcspc/powerpcspe-c.c (rs6000_macro_to_expend): Likewise.
3882 2018-08-16 Tamar Christina <tamar.christina@arm.com>
3885 * config/arm/arm.c (arm_can_change_mode_class): Disallow subreg.
3886 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
3887 (mov<mov>): ..this and enable unconditionally.
3889 2018-08-16 Tamar Christina <tamar.christina@arm.com>
3891 * config/arm/neon.md (*neon_mov<mode>): Remove reg-to-reg alternative.
3893 2018-08-16 Sam Tebbs <sam.tebbs@arm.com>
3895 * config/aarch64/aarch64.opt (mlow-precision-recip-sqrt)
3896 (mlow-precision-sqrt, mlow-precision-div, mverbose-cost-dump): Replace
3897 "Common" with "Target".
3899 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
3901 * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
3902 * doc/invoke.texi (mmitigate-rop): Remove.
3903 * config/i386/i386.c: Do not include "regrename.h".
3904 (ix86_rop_should_change_byte_p, reg_encoded_number)
3905 (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
3907 (ix86_reorg): Remove call to ix86_mitigate_rop.
3908 * config/i386/i386.md (attr "modrm_class"): Remove.
3909 (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor)
3910 (x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
3911 (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
3913 2018-08-15 Will Schmidt <will_schmidt@vnet.ibm.com>
3915 * config/rs6000/rs600.c (rs6000_gimple_fold_builtin): Add entries to
3916 allow folding of mergeh() and mergel() for the float and double types.
3917 (fold_mergehl_helper): Rework to handle building a permute tree
3920 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
3922 * config/i386/i386.c (expand_vec_perm_movs): Enable V4SFmode
3925 2018-08-15 David Malcolm <dmalcolm@redhat.com>
3927 * common.opt (fdiagnostics-show-labels): New option.
3928 * diagnostic-show-locus.c (class layout_range): Add field
3930 (class layout): Add field "m_show_labels_p".
3931 (layout_range::layout_range): Add param "label" and use it to
3933 (make_range): Pass in NULL for new "label" param of layout_range's
3935 (layout::layout): Initialize m_show_labels_p.
3936 (layout::maybe_add_location_range): Pass in loc_range->m_label
3937 when constructing layout_range instances.
3938 (struct line_label): New struct.
3939 (layout::print_any_labels): New member function.
3940 (layout::print_line): Call it if label-printing is enabled.
3941 (selftest::test_one_liner_labels): New test.
3942 (selftest::test_diagnostic_show_locus_one_liner): Call it.
3943 * diagnostic.c (diagnostic_initialize): Initialize
3944 context->show_labels_p.
3945 * diagnostic.h (struct diagnostic_context): Add field
3947 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
3948 -fno-diagnostics-show-labels.
3949 * dwarf2out.c (gen_producer_string): Add
3950 OPT_fdiagnostics_show_labels to the ignored options.
3951 * gcc-rich-location.c (gcc_rich_location::add_expr): Add "label"
3953 (gcc_rich_location::maybe_add_expr): Likewise.
3954 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location): Add
3955 label" param, defaulting to NULL.
3956 (gcc_rich_location::add_expr): Add "label" param.
3957 (gcc_rich_location::maybe_add_expr): Likewise.
3958 (class text_range_label): New class.
3959 (class range_label_for_type_mismatch): New class.
3960 * gimple-ssa-sprintf.c (fmtwarn): Pass NULL for new label params
3961 of format_warning_va.
3962 (fmtwarn_n): Likewise for new params of format_warning_n_va.
3963 * lto-wrapper.c (merge_and_complain): Add
3964 OPT_fdiagnostics_show_labels to the "pick one setting" options.
3965 (append_compiler_options): Likewise to the dropped options.
3966 (append_diag_options): Likewise to the passed-on options.
3967 * opts.c (common_handle_option): Handle the new option.
3968 * selftest-diagnostic.c
3969 (test_diagnostic_context::test_diagnostic_context): Enable
3971 * substring-locations.c: Include "gcc-rich-location.h".
3972 (format_warning_n_va): Add "fmt_label" and "param_label" params
3973 and use them as appropriate.
3974 (format_warning_va): Add "fmt_label" and "param_label" params,
3975 passing them on to format_warning_n_va.
3976 (format_warning_at_substring): Likewise.
3977 (format_warning_at_substring_n): Likewise.
3978 * substring-locations.h (format_warning_va): Add "fmt_label" and
3979 "param_label" params.
3980 (format_warning_n_va): Likewise.
3981 (format_warning_at_substring): Likewise.
3982 (format_warning_at_substring_n): Likewise.
3983 * toplev.c (general_init): Initialize global_dc->show_labels_p.
3985 2018-08-15 Qing Zhao <qing.zhao@oracle.com>
3988 * builtins.c (expand_builtin_memcmp): Do not expand the call
3989 when overflow is detected.
3991 2018-08-15 Martin Sebor <msebor@redhat.com>
3993 PR tree-optimization/71625
3994 * config/aarch64/aarch64-builtins.c
3995 (aarch64_init_simd_builtin_types): Clear Poly8_t's TYPE_STRING_FLAG.
3997 2018-08-15 Ilya Leoshkevich <iii@linux.ibm.com>
3999 * config/s390/s390.c (s390_reorg): Remove loop.
4001 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
4004 (darwin_function_switched_text_sections): Delete.
4005 * gcc/config/darwin.h
4006 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
4008 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
4011 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
4012 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
4013 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
4015 2018-08-15 Martin Liska <mliska@suse.cz>
4017 PR tree-optimization/86925
4018 * predict.c (expr_expected_value_1): When taking
4019 later predictor, assign also probability.
4020 Use fold_build2_initializer_loc in order to fold
4021 the expression in -frounding-math.
4023 2018-08-14 Allan Sandfeld Jensen <allan.jensen@qt.io>
4025 * config/i386/i386.c (expand_vec_perm_movs): New method matching movs
4027 (expand_vec_perm_1): Try the new method.
4029 2018-08-14 Ilya Leoshkevich <iii@linux.ibm.com>
4032 * lra-lives.c (remove_some_program_points_and_update_live_ranges):
4033 Check whether lra_live_max_point is 0 before dividing.
4035 2018-08-14 Martin Sebor <msebor@redhat.com>
4037 PR tree-optimization/86650
4038 * tree-vrp.c (vrp_prop::check_array_ref): Print an inform message.
4039 (vrp_prop::check_mem_ref): Same.
4041 2018-08-13 Liu Hao <lh_mouse@126.com>
4043 * pretty-print.c (eat_esc_sequence): Swap the foreground and
4044 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
4045 and clear it thereafter, as it only works for DBCS.
4047 2018-08-13 Liu Hao <lh_mouse@126.com>
4049 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
4050 handle returned by _get_osf_handle().
4052 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
4054 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support
4055 for folding vec_perm.
4057 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
4059 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin):
4060 Add support for gimple-folding of vec_pack() and vec_unpack()
4063 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
4065 * config/rs6000/rs6000.c (rs6000_builtin_valid_without_lhs): Add
4066 vec_xst variants to the list.
4067 (rs6000_gimple_fold_builtin): Add support for folding unaligned
4068 vector loads and stores.
4070 2018-08-13 David Edelsohn <dje.gcc@gmail.com>
4072 * config.gcc (rs6000-ibm-aix4.x): Delete.
4073 (rs6000-ibm-aix5.1): Delete.
4074 (rs6000-ibm-aix5.2): Delete.
4075 (rs6000-ibm-aix5.3): Delete.
4076 * config/rs6000/aix43.h: Delete.
4077 * config/rs6000/aix51.h: Delete.
4078 * config/rs6000/aix52.h: Delete.
4079 * config/rs6000/t-aix43: Delete.
4081 2018-08-13 Ilya Leoshkevich <iii@linux.ibm.com>
4083 * config/s390/s390.c (s390_decompose_constant_pool_ref):
4085 (s390_decompose_address): Factor out constant pool ref
4088 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
4090 * config/nds32/nds32-predicates.c
4091 (nds32_can_use_bclr_p): Change return type as bool.
4092 (nds32_can_use_bset_p): Ditto.
4093 (nds32_can_use_btgl_p): Ditto.
4094 (nds32_can_use_bitci_p): Ditto.
4095 * config/nds32/nds32-protos.h
4096 (nds32_can_use_bclr_p): Change declaration.
4097 (nds32_can_use_bset_p): Ditto.
4098 (nds32_can_use_btgl_p): Ditto.
4099 (nds32_can_use_bitci_p): Ditto.
4101 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
4103 * config/nds32/nds32.c (nds32_expand_prologue, nds32_expand_epilogue):
4104 Support -msched-prolog-epilog option.
4105 * config/nds32/nds32.opt (msched-prolog-epilog): New option.
4107 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
4109 * common/config/nds32/nds32-common.c
4110 (nds32_option_optimization_table): Enalbe -malways-align.
4112 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
4114 * config.gcc (nds32*): Add nds32_isr.h and nds32_init.inc in
4116 * common/config/nds32/nds32-common.c (nds32_handle_option): Handle
4117 OPT_misr_secure_ case.
4118 * config/nds32/nds32-isr.c: Implementation of backward compatibility.
4119 * config/nds32/nds32-protos.h (nds32_isr_function_critical_p): New.
4120 * config/nds32/nds32.c (nds32_attribute_table): Add critical and
4122 * config/nds32/nds32.h (nds32_isr_nested_type): Add NDS32_CRITICAL.
4123 (nds32_isr_info): New field security_level.
4124 (TARGET_ISR_VECTOR_SIZE_4_BYTE): New macro.
4125 * config/nds32/nds32.md (return_internal): Consider critical attribute.
4126 * config/nds32/nds32.opt (misr-secure): New option.
4127 * config/nds32/nds32_init.inc: New file.
4128 * config/nds32/nds32_isr.h: New file.
4130 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
4132 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
4133 Update comment for atomic instructions.
4134 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
4135 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
4137 (atomic_loaddi): Revise fence expansion to only emit fence prior to
4138 load for __ATOMIC_SEQ_CST model.
4139 (atomic_loaddi_1): Remove float register target.
4140 (atomic_storedi): Handle CONST_INT values.
4141 (atomic_storedi_1): Remove float register source. Add special case
4143 (memory_barrier): New expander and insn.
4145 2018-08-11 Jakub Jelinek <jakub@redhat.com>
4147 PR tree-optimization/86835
4148 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
4149 new_stmt after def_gsi, make sure to insert new_square_stmt after
4150 that stmt, not 2 stmts before it.
4152 2018-08-10 Alexander Monakov <amonakov@ispras.ru>
4155 * config/i386/i386.md (<s>mul<mode>3_highpart): Use DWIH mode iterator
4158 2018-08-10 Martin Liska <mliska@suse.cz>
4161 * builtin-types.def (BT_FN_LONG_LONG_LONG_DOUBLE): Add new
4163 * builtins.c (expand_builtin_expect_with_probability):
4165 (expand_builtin_expect_with_probability): New function.
4166 (build_builtin_expect_predicate): Add new argumnet probability
4167 for BUILT_IN_EXPECT_WITH_PROBABILITY.
4168 (fold_builtin_expect):
4171 * builtins.def (BUILT_IN_EXPECT_WITH_PROBABILITY):
4172 * builtins.h (fold_builtin_expect): Set new argument.
4173 * doc/extend.texi: Document __builtin_expect_with_probability.
4174 * doc/invoke.texi: Likewise.
4175 * gimple-fold.c (gimple_fold_call): Pass new argument.
4176 * ipa-fnsummary.c (find_foldable_builtin_expect): Handle
4177 also BUILT_IN_EXPECT_WITH_PROBABILITY.
4178 * predict.c (get_predictor_value): New function.
4179 (expr_expected_value): Add new argument probability. Assume
4180 that predictor and probability are always non-null.
4181 (expr_expected_value_1): Likewise. For __builtin_expect and
4182 __builtin_expect_with_probability set probability. Handle
4183 combination in binary expressions.
4184 (tree_predict_by_opcode): Simplify code by simply calling
4185 get_predictor_value.
4186 (pass_strip_predict_hints::execute): Add handling of
4187 BUILT_IN_EXPECT_WITH_PROBABILITY.
4188 * predict.def (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Add
4190 * tree.h (DECL_BUILT_IN_P): New function.
4192 2018-08-10 Martin Liska <mliska@suse.cz>
4194 PR tree-optimization/85799
4195 * passes.def: Add argument for pass_strip_predict_hints.
4196 * predict.c (class pass_strip_predict_hints): Add new argument
4198 (strip_predictor_early): New function.
4199 (pass_strip_predict_hints::execute): Call the function to
4201 (strip_predict_hints): New function.
4202 * predict.def: Fix comment.
4204 2018-08-10 Thomas Preud'homme <thomas.preudhomme@linaro.org>
4206 * Makefile.in: Clarify which tm.texi to copy over to assert the
4207 right to grant a GFDL license for all.
4209 2018-08-09 Jeff Law <law@redhat.com>
4211 * config/m68k/m68k.c (m68k_adjust_decorated_operand): Remove
4214 2018-08-09 Andreas Schwab <schwab@linux-m68k.org>
4216 * config/m68k/m68k-protos.h (m68k_final_prescan_insn): Remove
4219 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
4221 * tree-vect-loop.c (vectorizable_reduction): Allow inner-loop
4222 reductions for variable-length vectors.
4224 2018-08-09 David Malcolm <dmalcolm@redhat.com>
4227 * common.opt (fdiagnostics-show-line-numbers): New option.
4228 * diagnostic-show-locus.c (class layout): Add fields
4229 "m_show_line_numbers_p" and "m_linenum_width";
4230 (num_digits): New function.
4231 (test_num_digits): New function.
4232 (layout::layout): Initialize new fields. Update m_x_offset
4233 logic to handle any left margin.
4234 (layout::print_source_line): Print line number when requested.
4235 (layout::start_annotation_line): New member function.
4236 (layout::print_annotation_line): Call it.
4237 (layout::print_leading_fixits): Likewise.
4238 (layout::print_trailing_fixits): Likewise. Update calls to
4239 move_to_column for new parameter.
4240 (layout::get_x_bound_for_row): Add "add_left_margin" param and use
4241 it to potentially call start_annotation_line.
4242 (layout::show_ruler): Call start_annotation_line.
4243 (selftest::test_line_numbers_multiline_range): New selftest.
4244 (selftest::diagnostic_show_locus_c_tests): Call test_num_digits
4245 and selftest::test_line_numbers_multiline_range.
4246 * diagnostic.c (diagnostic_initialize): Initialize
4247 show_line_numbers_p.
4248 * diagnostic.h (struct diagnostic_context): Add field
4249 "show_line_numbers_p".
4250 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
4251 -fno-diagnostics-show-line-numbers.
4252 * dwarf2out.c (gen_producer_string): Add
4253 OPT_fdiagnostics_show_line_numbers to the ignored options.
4254 * lto-wrapper.c (merge_and_complain): Likewise to the "pick
4255 one setting" options.
4256 (append_compiler_options): Likewise to the dropped options.
4257 (append_diag_options): Likewise to the passed-on options.
4258 * opts.c (common_handle_option): Handle the new option.
4259 * toplev.c (general_init): Set up global_dc->show_line_numbers_p.
4261 2018-08-09 Kelvin Nilsen <kelvin@gcc.gnu.org>
4263 * doc/extend.texi (PowerPC AltiVec Built-in Functions Available on
4264 ISA 2.07): Correct spelling of bcdsub to be __builtin_bcdsub. Add
4265 third argument of type "const signed char" to descriptions of
4266 __builtin_bcdadd, __builtin_bcdadd_lt, __builtin_bcdadd_eq,
4267 __builtin_bcdadd_gt, __builtin_bcdadd_ov, __builtin_bcdsub,
4268 __builtin_bcdsub_lt, __builtin_bcdsub_eq, __builtin_bcdsub_gt,
4269 __builtin_bcdsub_ov functions.
4271 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
4273 PR tree-optimization/86858
4274 * tree-vect-loop.c (vect_is_simple_reduction): Restore
4275 flow_bb_inside_loop_p calls.
4277 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
4279 PR tree-optimization/86871
4280 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
4281 instead of gimple_assign_lhs.
4283 2018-08-09 Richard Earnshaw <rearnsha@arm.com>
4286 * config/aarch64/aarch64.md (add<mode>3_carryinC_zero): Add missing
4287 register constraint to operand 0.
4288 (add<mode>3_carryinC): Likewise.
4289 (add<mode>3_carryinV_zero, add<mode>3_carryinV): Likewise.
4291 2018-08-09 Martin Liska <mliska@suse.cz>
4294 * common.opt: Remove extra line.
4296 2018-08-09 Martin Liska <mliska@suse.cz>
4298 * params.def (PARAM_ALIGN_LOOP_ITERATIONS): Remove double dots
4299 at the end of a line, make first letter capital and end up
4300 a sentence with a dot.
4301 (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): Likewise.
4302 (PARAM_LOOP_BLOCK_TILE_SIZE): Likewise.
4303 (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Likewise.
4304 (PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP): Likewise.
4305 (PARAM_MAX_ISL_OPERATIONS): Likewise.
4306 (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): Likewise.
4307 (PARAM_PROFILE_FUNC_INTERNAL_ID): Likewise.
4308 (PARAM_INDIR_CALL_TOPN_PROFILE): Likewise.
4309 (PARAM_SLP_MAX_INSNS_IN_BB): Likewise.
4310 (PARAM_IPA_CP_EVAL_THRESHOLD): Likewise.
4311 (PARAM_IPA_CP_RECURSION_PENALTY): Likewise.
4312 (PARAM_IPA_CP_SINGLE_CALL_PENALTY): Likewise.
4313 (PARAM_IPA_CP_LOOP_HINT_BONUS): Likewise.
4314 (PARAM_IPA_CP_ARRAY_INDEX_HINT_BONUS): Likewise.
4315 (PARAM_TREE_REASSOC_WIDTH): Likewise.
4316 (PARAM_HSA_GEN_DEBUG_STORES): Likewise.
4317 (PARAM_MAX_SPECULATIVE_DEVIRT_MAYDEFS): Likewise.
4318 (PARAM_MAX_VRP_SWITCH_ASSERTIONS): Likewise.
4320 2018-08-09 Andreas Krebbel <krebbel@linux.ibm.com>
4323 * config/s390/s390.c (s390_option_override_internal): Reduce the
4324 stack-clash-protection-probe-interval param if it would be too big
4327 2018-08-08 Andreas Schwab <schwab@linux-m68k.org>
4330 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Don't define.
4331 * config/m68k/m68k.c (handle_move_double): Don't call
4332 m68k_final_prescan_insn.
4333 (m68k_adjust_decorated_operand): Renamed from
4334 m68k_final_prescan_insn, remove first and third operand and
4336 (print_operand): Call it.
4337 (print_operand_address): Call it.
4339 2018-08-08 Nathan Sidwell <nathan@acm.org>
4341 * diagnostic.c (diagnostic_report_current_module): Use
4342 linemap_included_from & linemap_included_from_linemap.
4344 2018-08-08 Hongbo Zhang <hongbo.zhang@linaro.org>
4346 * config/aarch64/aarch64-cores.def: Add phecda core.
4347 * config/aarch64/aarch64-tune.md: Regenerate.
4348 * doc/invoke.texi: Add phecda core.
4350 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
4353 * config/s390/constraints.md ("NxHD0", "NxSD0"): New constraint
4355 * config/s390/s390.md ("movti"): Add more alternatives for
4356 constant to GPR copies.
4358 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
4360 * config/s390/s390.c: Fix whitespace damage throughout the file.
4361 * config/s390/s390.h: Likewise.
4362 * config/s390/tpf.h: Likewise.
4364 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
4366 * config/s390/s390.c (s390_loadrelative_operand_p):
4367 Remove TARGET_CPU_ZARCH usages.
4368 (s390_rtx_costs): Likewise.
4369 (s390_legitimate_constant_p): Likewise.
4370 (s390_cannot_force_const_mem): Likewise.
4371 (legitimate_reload_constant_p): Likewise.
4372 (s390_preferred_reload_class): Likewise.
4373 (legitimize_pic_address): Likewise.
4374 (legitimize_tls_address): Likewise.
4375 (s390_split_branches): Removed.
4376 (s390_add_execute): Removed.
4377 (s390_dump_pool): Remove TARGET_CPU_ZARCH usages.
4378 (s390_mainpool_start): Likewise.
4379 (s390_mainpool_finish): Likewise.
4380 (s390_mainpool_cancel): Removed.
4381 (s390_chunkify_start): Remove TARGET_CPU_ZARCH usages.
4382 (s390_chunkify_cancel): Likewise.
4383 (s390_return_addr_rtx): Likewise.
4384 (s390_register_info): Remove split_branches_pending_p uages.
4385 (s390_optimize_register_info): Likewise.
4386 (s390_init_frame_layout): Remove TARGET_CPU_ZARCH and
4387 split_branches_pending_p usages.
4388 (s390_can_eliminate): Remove TARGET_CPU_ZARCH usages.
4389 (s390_load_got): Likewise.
4390 (s390_expand_split_stack_prologue): Likewise.
4391 (output_asm_nops): Likewise.
4392 (s390_function_profiler): Likewise.
4393 (s390_emit_call): Likewise.
4394 (s390_conditional_register_usage): Likewise.
4395 (s390_optimize_prologue): Likewise.
4396 (s390_reorg): Remove TARGET_CPU_ZARCH and
4397 split_branches_pending_p usages.
4398 (s390_option_override_internal): Remove TARGET_CPU_ZARCH
4400 (s390_output_indirect_thunk_function): Likewise.
4401 * config/s390/s390.h (TARGET_CPU_ZARCH): Removed.
4402 (TARGET_CPU_ZARCH_P): Removed.
4403 (struct machine_function): Remove split_branches_pending_p.
4404 * config/s390/s390.md: Remove TARGET_CPU_ZARCH usages.
4406 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
4408 * common/config/s390/s390-common.c (processor_flags_table):
4410 * config.gcc: Remove with_arch/with_tune support.
4411 * config/s390/2064.md: Remove cpu attribute comparisons.
4412 * config/s390/driver-native.c (s390_host_detect_local_cpu):
4414 * config/s390/linux.h (ASM_SPEC):
4415 Remove -march support.
4416 * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal):
4417 Use a table to get an arch level.
4418 * config/s390/s390-opts.h (enum processor_type):
4420 * config/s390/s390.c
4421 (processor_table): Remove entries, add arch_level values.
4422 (s390_issue_rate): Remove cases.
4423 (s390_option_override): Adjust
4424 s390_option_override_internal() call.
4425 (s390_option_override_internal): Remove deprecation warning.
4426 (s390_valid_target_attribute_tree): Adjust
4427 s390_option_override_internal() call.
4428 * config/s390/s390.h (struct s390_processor):
4429 Share with s390-c.c, add arch_level field.
4430 * config/s390/s390.md:
4431 Remove occurrences in cpu attribute.
4432 * config/s390/s390.opt: Remove -march/-mtune support.
4433 * config/s390/tpf.h (ASM_SPEC): Remove -march support.
4434 * doc/invoke.texi: Remove deprecation warning.
4436 2018-08-08 Luis Machado <luis.machado@linaro.org>
4438 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static
4440 (qdf24xx_tunings): Set vector cost structure to
4441 qdf24xx_vector_cost.
4443 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
4444 <register_sextend>: Set to 3.
4446 2018-08-07 Richard Sandiford <richard.sandiford@arm.com>
4449 * config/aarch64/iterators.md (FRECP, frecp_suffix): Delete.
4450 * config/aarch64/aarch64-simd.md
4451 (aarch64_frecp<FRECP:frecp_suffix><mode>): Fold FRECPE into...
4452 (@aarch64_frecpe<mode>): ...here and the move FRECPX to...
4453 (aarch64_frecpx<mode>): ...this new pattern.
4454 * config/aarch64/aarch64-simd-builtins.def: Remove comment
4455 about aarch64_frecp<FRECP:frecp_suffix><mode>.
4457 2018-08-07 Martin Liska <mliska@suse.cz>
4460 * predict.c (expr_expected_value_1): Handle DECL_IS_MALLOC,
4461 BUILT_IN_REALLOC and DECL_IS_OPERATOR_NEW.
4462 * predict.def (PRED_MALLOC_NONNULL): New predictor.
4463 * doc/extend.texi: Document that malloc attribute adds
4466 2018-08-06 John David Anglin <danglin@gcc.gnu.org>
4469 * config/pa/pa.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4470 Define to speculation_safe_value_not_needed.
4472 2018-08-06 Jeff Law <law@redhat.com>
4474 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Pass down
4475 the vr_values instance to cprop_into_stmt.
4476 (cprop_into_stmt): Pass vr_values instance down to cprop_operand.
4477 (cprop_operand): Also query EVRP to determine if OP is a constant.
4479 2018-08-06 Nathan Sidwell <nathan@acm.org>
4481 * diagnostic.c (diagnostic_report_current_module): Reroll
4482 included-at loop. Translate text.
4484 2018-08-06 David Malcolm <dmalcolm@redhat.com>
4486 * function-tests.c (selftest::test_expansion_to_rtl): Call
4487 free_after_compilation.
4489 2018-08-06 Alan Hayward <alan.hayward@arm.com>
4491 * config/aarch64/aarch64.md: Add clobber highs to tls_desc.
4493 2018-08-06 Andreas Krebbel <krebbel@linux.ibm.com>
4495 * config/s390/s390.c (s390_loop_unroll_adjust): Prevent small
4496 loops with memory block operations from getting unrolled.
4498 2018-08-06 Ulrich Weigand <uweigand@de.ibm.com>
4501 * config/spu/spu.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4502 Define to speculation_safe_value_not_needed.
4504 2018-08-06 Jeff Law <law@redhat.com>
4506 * reload1.c (forget_old_reloads_1): Adjust CLOBBER_HIGH
4509 2018-08-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
4512 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
4513 with all enabled __intN types.
4515 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
4517 2018-08-06 Alan Hayward <alan.hayward@arm.com>
4519 * alias.c (record_set): Check for clobber high.
4520 * cfgexpand.c (expand_gimple_stmt): Likewise.
4521 * combine-stack-adj.c (single_set_for_csa): Likewise.
4522 * combine.c (find_single_use_1): Likewise.
4523 (set_nonzero_bits_and_sign_copies): Likewise.
4524 (get_combine_src_dest): Likewise.
4525 (is_parallel_of_n_reg_sets): Likewise.
4526 (try_combine): Likewise.
4527 (record_dead_and_set_regs_1): Likewise.
4528 (reg_dead_at_p_1): Likewise.
4529 (reg_dead_at_p): Likewise.
4530 * dce.c (deletable_insn_p): Likewise.
4531 (mark_nonreg_stores_1): Likewise.
4532 (mark_nonreg_stores_2): Likewise.
4533 * df-scan.c (df_find_hard_reg_defs): Likewise.
4534 (df_uses_record): Likewise.
4535 (df_get_call_refs): Likewise.
4536 * dwarf2out.c (mem_loc_descriptor): Likewise.
4537 * haifa-sched.c (haifa_classify_rtx): Likewise.
4538 * ira-build.c (create_insn_allocnos): Likewise.
4539 * ira-costs.c (scan_one_insn): Likewise.
4540 * ira.c (equiv_init_movable_p): Likewise.
4541 (rtx_moveable_p): Likewise.
4542 (interesting_dest_for_shprep): Likewise.
4543 * jump.c (mark_jump_label_1): Likewise.
4544 * postreload-gcse.c (record_opr_changes): Likewise.
4545 * postreload.c (reload_cse_simplify): Likewise.
4546 (struct reg_use): Add source expr.
4547 (reload_combine): Check for clobber high.
4548 (reload_combine_note_use): Likewise.
4549 (reload_cse_move2add): Likewise.
4550 (move2add_note_store): Likewise.
4551 * print-rtl.c (print_pattern): Likewise.
4552 * recog.c (decode_asm_operands): Likewise.
4553 (store_data_bypass_p): Likewise.
4554 (if_test_bypass_p): Likewise.
4555 * regcprop.c (kill_clobbered_value): Likewise.
4556 (kill_set_value): Likewise.
4557 * reginfo.c (reg_scan_mark_refs): Likewise.
4558 * reload1.c (maybe_fix_stack_asms): Likewise.
4559 (eliminate_regs_1): Likewise.
4560 (elimination_effects): Likewise.
4561 (mark_not_eliminable): Likewise.
4562 (scan_paradoxical_subregs): Likewise.
4563 (forget_old_reloads_1): Likewise.
4564 * reorg.c (find_end_label): Likewise.
4565 (try_merge_delay_insns): Likewise.
4566 (redundant_insn): Likewise.
4567 (own_thread_p): Likewise.
4568 (fill_simple_delay_slots): Likewise.
4569 (fill_slots_from_thread): Likewise.
4570 (dbr_schedule): Likewise.
4571 * resource.c (update_live_status): Likewise.
4572 (mark_referenced_resources): Likewise.
4573 (mark_set_resources): Likewise.
4574 * rtl.c (copy_rtx): Likewise.
4575 * rtlanal.c (reg_referenced_p): Likewise.
4576 (single_set_2): Likewise.
4577 (noop_move_p): Likewise.
4578 (note_stores): Likewise.
4579 * sched-deps.c (sched_analyze_reg): Likewise.
4580 (sched_analyze_insn): Likewise.
4582 2018-08-06 Alan Hayward <alan.hayward@arm.com>
4584 * cse.c (invalidate_reg): New function extracted from...
4585 (invalidate): ...here.
4586 (canonicalize_insn): Check for clobber high.
4587 (invalidate_from_clobbers): invalidate clobber highs.
4588 (invalidate_from_sets_and_clobbers): Likewise.
4589 (count_reg_usage): Check for clobber high.
4590 (insn_live_p): Likewise.
4591 * cselib.c (cselib_expand_value_rtx_1):Likewise.
4592 (cselib_invalidate_regno): Check for clobber in setter.
4593 (cselib_invalidate_rtx): Pass through setter.
4594 (cselib_invalidate_rtx_note_stores):
4595 (cselib_process_insn): Check for clobber high.
4596 * cselib.h (cselib_invalidate_rtx): Add operand.
4598 2018-08-06 Alan Hayward <alan.hayward@arm.com>
4600 * lra-eliminations.c (lra_eliminate_regs_1): Check for clobber high.
4601 (mark_not_eliminable): Likewise.
4602 * lra-int.h (struct lra_insn_reg): Add clobber high marker.
4603 * lra-lives.c (process_bb_lives): Check for clobber high.
4604 * lra.c (new_insn_reg): Remember clobber highs.
4605 (collect_non_operand_hard_regs): Check for clobber high.
4606 (lra_set_insn_recog_data): Likewise.
4607 (add_regs_to_insn_regno_info): Likewise.
4608 (lra_update_insn_regno_info): Likewise.
4610 2018-08-06 Alan Hayward <alan.hayward@arm.com>
4612 * rtl.h (reg_is_clobbered_by_clobber_high): Add declarations.
4613 * rtlanal.c (reg_is_clobbered_by_clobber_high): Add function.
4615 2018-08-06 Alan Hayward <alan.hayward@arm.com>
4617 * emit-rtl.c (verify_rtx_sharing): Check for CLOBBER_HIGH.
4618 (copy_insn_1): Likewise.
4619 (gen_hard_reg_clobber_high): New gen function.
4620 * genconfig.c (walk_insn_part): Check for CLOBBER_HIGH.
4621 * genemit.c (gen_exp): Likewise.
4622 (gen_emit_seq): Pass through info.
4623 (gen_insn): Check for CLOBBER_HIGH.
4624 (gen_expand): Pass through info.
4625 (gen_split): Likewise.
4626 (output_add_clobbers): Likewise.
4627 * genrecog.c (validate_pattern): Check for CLOBBER_HIGH.
4628 (remove_clobbers): Likewise.
4629 * rtl.h (gen_hard_reg_clobber_high): New declaration.
4631 2018-08-06 Alan Hayward <alan.hayward@arm.com>
4633 * doc/rtl.texi (clobber_high): Add.
4634 (parallel): Add in clobber high
4635 * rtl.c (rtl_check_failed_code3): Add function.
4636 * rtl.def (CLOBBER_HIGH): Add expression.
4637 * rtl.h (RTL_CHECKC3): Add macro.
4638 (rtl_check_failed_code3): Add declaration.
4639 (XC3EXP): Add macro.
4641 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
4644 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
4645 cfun->machine->max_used_stack_alignment if needed.
4647 2018-08-04 Martin Sebor <msebor@redhat.com>
4649 PR tree-optimization/86571
4650 * gimple-ssa-sprintf.c (format_floating): Extend upper bound of
4653 2018-08-03 Sandra Loosemore <sandra@codesourcery.com>
4656 * config/nios2/nios2.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4659 2018-08-03 Jeff Law <law@redhat.com>
4662 * config/mn10300/mn10300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4663 Define to speculation_safe_value_not_needed.
4665 2018-08-03 David Malcolm <dmalcolm@redhat.com>
4667 * doc/gcov.texi (-x): Remove duplicate "to".
4668 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
4669 (-Wif-not-aligned): Remove duplicate "is".
4670 (-flto): Remove duplicate "the".
4671 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
4672 duplicate "v5.00.b".
4673 (MSP430 Options): Remove duplicate "and" from the description
4674 of "-mgprel-sec=regexp".
4675 (x86 Options): Remove duplicate copies of "vmldLog102" and
4676 vmlsLog104 from description of "-mveclibabi=type".
4678 2018-08-03 Richard Sandiford <richard.sandiford@arm.com>
4680 * internal-fn.h (first_commutative_argument): Declare.
4681 * internal-fn.c (first_commutative_argument): New function.
4682 * tree-vect-slp.c (vect_get_and_check_slp_defs): Remove extra
4683 restrictions for pattern statements. Use first_commutative_argument
4684 to look for commutative operands in calls to internal functions.
4686 2018-08-03 Aldy Hernandez <aldyh@redhat.com>
4688 * Makefile.in (wide-int-range.o): New.
4689 * tree-vrp.c: Move all the wide_int_* functions to...
4690 * wide-int-range.cc: ...here.
4691 * tree-vrp.h: Move all the wide_int_* prototypes to...
4692 * wide-int-range.h: ...here.
4694 2018-08-03 Tom de Vries <tdevries@suse.de>
4696 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): Return
4698 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Remove define.
4699 * except.c (output_function_exception_table): Do early exit if
4700 targetm_common.except_unwind_info (&global_options) == UI_NONE.
4702 2018-08-03 Martin Liska <mliska@suse.cz>
4704 * predict.c (dump_prediction): Change to 2 digits
4707 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
4709 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
4711 (falkor_am_1_gtov_gtov): ... a new insn reservation.
4713 2018-07-19 Ilya Leoshkevich <iii@linux.ibm.com>
4715 * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Replace > with >=.
4716 * df-problems.c (df_remove_dead_eq_notes): Replace > with >=.
4717 * dwarf2out.c (mem_loc_descriptor): Replace > with >=.
4718 * lra-constraints.c (spill_hard_reg_in_range): Replace <= with <.
4719 * lra-remat.c (call_used_input_regno_present_p): Replace <= with <.
4721 2018-08-02 David Malcolm <dmalcolm@redhat.com>
4723 * diagnostic-show-locus.c (diagnostic_show_locus): Use
4724 pp_take_prefix when saving the existing prefix.
4725 * diagnostic.c (diagnostic_append_note): Likewise.
4726 * langhooks.c (lhd_print_error_function): Likewise.
4727 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
4728 param's type. Free the existing prefix.
4729 (pp_take_prefix): New function.
4730 (pretty_printer::pretty_printer): Drop the prefix parameter.
4731 Rename the length parameter to match the comment.
4732 (pretty_printer::~pretty_printer): Free the prefix.
4733 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
4735 (struct pretty_printer): Drop the "const" from "prefix" field's
4736 type and clarify memory management.
4737 (pp_set_prefix): Drop the "const" from the 2nd param.
4738 (pp_take_prefix): New decl.
4740 2018-08-02 Aaron Sawdey <acsawdey@linux.ibm.com>
4742 * config/rs6000/rs6000-string.c (select_block_compare_mode): Move test
4743 for word_mode_ok here instead of passing as argument.
4744 (expand_block_compare): Change select_block_compare_mode() call.
4745 (expand_strncmp_gpr_sequence): New function.
4746 (expand_strn_compare): Make use of expand_strncmp_gpr_sequence.
4748 2018-08-02 Jeff Law <law@redhat.com>
4751 * config/m68k/m68k.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4752 Define to speculation_safe_value_not_needed.
4755 * config/h8300/h8300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4756 Define to speculation_safe_value_not_needed.
4758 2018-08-02 Tom de Vries <tdevries@suse.de>
4761 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): New
4762 function. Return UI_TARGET unconditionally.
4763 (TARGET_EXCEPT_UNWIND_INFO): Redefine to nvptx_except_unwind_info.
4764 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Emit commented out '.byte'.
4766 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
4768 * genemit.c (print_overload_test): Fix typo.
4770 2018-08-02 Richard Biener <rguenther@suse.de>
4772 PR tree-optimization/86816
4773 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
4774 which checks for value availability before querying it.
4775 (gvn_uses_equal): Use it.
4776 (same_succ_hash): Likewise.
4777 (gimple_equal_p): Likewise.
4779 2018-08-02 Nick Clifton <nickc@redhat.com>
4782 * config/stormy16/stormy16.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4783 Define to speculation_safe_value_not_needed.
4786 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4787 Define to speculation_safe_value_not_needed.
4790 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4791 Define to speculation_safe_value_not_needed.
4794 * config/rx/rx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4795 Define to speculation_safe_value_not_needed.
4798 * config/msp430/msp430.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4799 Define to speculation_safe_value_not_needed.
4802 * config/mcore/mcore.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4803 Define to speculation_safe_value_not_needed.
4806 * config/m32r/m32r.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4807 Define to speculation_safe_value_not_needed.
4810 * config/iq2000/iq2000.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
4811 Define to speculation_safe_value_not_needed.
4814 * config/frv/frv.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
4815 speculation_safe_value_not_needed.
4818 * config/fr30/fr30.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
4819 to speculation_safe_value_not_needed.
4821 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
4823 * doc/md.texi: Expand the documentation of instruction names
4824 to mention port-local uses. Document '@' in pattern names.
4825 * read-md.h (overloaded_instance, overloaded_name): New structs.
4827 (md_reader::handle_overloaded_name): New member function.
4828 (md_reader::get_overloads): Likewise.
4829 (md_reader::m_first_overload): New member variable.
4830 (md_reader::m_next_overload_ptr): Likewise.
4831 (md_reader::m_overloads_htab): Likewise.
4832 * read-md.c (md_reader::md_reader): Initialize m_first_overload,
4833 m_next_overload_ptr and m_overloads_htab.
4834 * read-rtl.c (iterator_group): Add "type" and "get_c_token" fields.
4835 (get_mode_token, get_code_token, get_int_token): New functions.
4836 (map_attr_string): Add an optional argument that passes back
4837 the associated iterator.
4838 (overloaded_name_hash, overloaded_name_eq_p, named_rtx_p):
4839 (md_reader::handle_overloaded_name, add_overload_instance): New
4841 (apply_iterators): Handle '@' names. Report an error if '@'
4842 is used without iterators.
4843 (initialize_iterators): Initialize the new iterator_group fields.
4844 * genopinit.c (handle_overloaded_code_for)
4845 (handle_overloaded_gen): New functions.
4846 (main): Use them to print declarations of maybe_code_for_* and
4847 maybe_gen_* functions, and inline definitions of code_for_* and gen_*.
4848 * genemit.c (print_overload_arguments, print_overload_test)
4849 (handle_overloaded_code_for, handle_overloaded_gen): New functions.
4850 (main): Use it to print definitions of maybe_code_for_* and
4851 maybe_gen_* functions.
4852 * config/aarch64/aarch64.c (aarch64_split_128bit_move): Use
4853 gen_aarch64_mov{low,high}_di and gen_aarch64_movdi_{low,high}
4854 instead of explicit mode checks.
4855 (aarch64_split_simd_combine): Likewise gen_aarch64_simd_combine.
4856 (aarch64_split_simd_move): Likewise gen_aarch64_split_simd_mov.
4857 (aarch64_emit_load_exclusive): Likewise gen_aarch64_load_exclusive.
4858 (aarch64_emit_store_exclusive): Likewise gen_aarch64_store_exclusive.
4859 (aarch64_expand_compare_and_swap): Likewise
4860 gen_aarch64_compare_and_swap and gen_aarch64_compare_and_swap_lse
4861 (aarch64_gen_atomic_cas): Likewise gen_aarch64_atomic_cas.
4862 (aarch64_emit_atomic_swap): Likewise gen_aarch64_atomic_swp.
4863 (aarch64_constant_pool_reload_icode): Delete.
4864 (aarch64_secondary_reload): Use code_for_aarch64_reload_movcp
4865 instead of aarch64_constant_pool_reload_icode. Use
4866 code_for_aarch64_reload_mov instead of explicit mode checks.
4867 (rsqrte_type, get_rsqrte_type, rsqrts_type, get_rsqrts_type): Delete.
4868 (aarch64_emit_approx_sqrt): Use gen_aarch64_rsqrte instead of
4869 get_rsqrte_type and gen_aarch64_rsqrts instead of gen_rqrts_type.
4870 (recpe_type, get_recpe_type, recps_type, get_recps_type): Delete.
4871 (aarch64_emit_approx_div): Use gen_aarch64_frecpe instead of
4872 get_recpe_type and gen_aarch64_frecps instead of get_recps_type.
4873 (aarch64_atomic_load_op_code): Delete.
4874 (aarch64_emit_atomic_load_op): Likewise.
4875 (aarch64_gen_atomic_ldop): Use UNSPECV_ATOMIC_* instead of
4876 aarch64_atomic_load_op_code. Use gen_aarch64_atomic_load
4877 instead of aarch64_emit_atomic_load_op.
4878 * config/aarch64/aarch64.md (aarch64_reload_movcp<GPF_TF:mode><P:mode>)
4879 (aarch64_reload_movcp<VALL:mode><P:mode>, aarch64_reload_mov<mode>)
4880 (aarch64_movdi_<mode>low, aarch64_movdi_<mode>high)
4881 (aarch64_mov<mode>high_di, aarch64_mov<mode>low_di): Add a '@'
4882 character before the pattern name.
4883 * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
4884 (aarch64_rsqrte<mode>, aarch64_rsqrts<mode>)
4885 (aarch64_simd_combine<mode>, aarch64_frecpe<mode>)
4886 (aarch64_frecps<mode>): Likewise.
4887 * config/aarch64/atomics.md (atomic_compare_and_swap<mode>)
4888 (aarch64_compare_and_swap<mode>, aarch64_compare_and_swap<mode>_lse)
4889 (aarch64_load_exclusive<mode>, aarch64_store_exclusive<mode>)
4890 (aarch64_atomic_swp<mode>, aarch64_atomic_cas<mode>)
4891 (aarch64_atomic_load<atomic_ldop><mode>): Likewise.
4893 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
4895 * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
4896 Allow HFmode constants if TARGET_FP_F16INST.
4898 2018-08-02 Jackson Woodruff <jackson.woodruff@arm.com>
4901 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp):
4902 No longer check last store for clobber of address register.
4904 2018-08-02 Martin Liska <mliska@suse.cz>
4906 PR gcov-profile/86817
4907 * gcov.c (process_all_functions): New function.
4909 (process_file): Move functions processing to
4910 process_all_functions.
4912 2018-08-02 David Malcolm <dmalcolm@redhat.com>
4914 * dumpfile.c (dump_user_location_t::dump_user_location_t): Add
4915 "const" to the "gimple *" and "rtx_insn *" parameters.
4916 * dumpfile.h (dump_user_location_t::dump_user_location_t):
4918 (dump_location_t::dump_location_t): Likewise.
4920 2018-08-01 Martin Sebor <msebor@redhat.com>
4922 PR tree-optimization/86650
4923 * gimple-pretty-print.c (percent_G_format): Accept a "gimple *"
4924 rather than a "gcall *". Directly pass the data of interest
4925 to percent_K_format, rather than building a temporary CALL_EXPR
4927 * gimple-fold.c (gimple_fold_builtin_strncpy): Adjust.
4928 (gimple_fold_builtin_strncat): Adjust.
4929 * gimple-ssa-warn-restrict.h (check_bounds_or_overlap): Replace
4930 gcall* argument with gimple*.
4931 * gimple-ssa-warn-restrict.c (check_call): Same.
4932 (wrestrict_dom_walker::before_dom_children): Same.
4933 (builtin_access::builtin_access): Same.
4934 (check_bounds_or_overlap): Same
4935 (maybe_diag_overlap): Same.
4936 (maybe_diag_offset_bounds): Same.
4937 * tree-diagnostic.c (default_tree_printer): Move usage of
4938 EXPR_LOCATION (t) and TREE_BLOCK (t) from within percent_K_format
4940 * tree-pretty-print.c (percent_K_format): Add argument.
4941 * tree-pretty-print.h: Add argument.
4942 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Adjust.
4943 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Adjust.
4944 (maybe_diag_stxncpy_trunc): Same.
4945 (handle_builtin_stxncpy): Same.
4946 (handle_builtin_strcat): Same.
4948 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
4950 * match.pd: Optimise pointer range checks.
4952 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
4954 PR tree-optimization/86758
4955 * tree-vect-stmts.c (vectorizable_simd_clone_call): Don't try
4956 to remove pattern statements.
4958 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
4960 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Use the
4961 result of dfs_enumerate_from when constructing stmt_vec_infos,
4962 instead of additionally calling get_loop_body.
4964 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
4966 * tree-vectorizer.h (vect_create_data_ref_ptr): Remove inv_p
4968 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
4969 When creating an iv, assert that the step is not known to be zero.
4970 (vect_setup_realignment): Update call accordingly.
4971 * tree-vect-stmts.c (vectorizable_store): Likewise.
4972 (vectorizable_load): Likewise. Handle VMAT_INVARIANT separately.
4974 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
4976 * tree-vectorizer.h (vect_stmt_to_vectorize): New function.
4977 * tree-vect-loop.c (vect_update_vf_for_slp): Use it.
4978 (vectorizable_reduction): Likewise.
4979 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
4980 (vect_detect_hybrid_slp_stmts): Likewise.
4981 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
4983 2018-08-01 Aldy Hernandez <aldyh@redhat.com>
4985 * tree-vrp (zero_nonzero_bits_from_bounds): Rename to...
4986 (wide_int_set_zero_nonzero_bits): ...this.
4987 (zero_nonzero_bits_from_vr): Rename to...
4988 (vrp_set_zero_nonzero_bits): ...this.
4989 (extract_range_from_multiplicative_op_1): Abstract wide int
4991 (wide_int_range_multiplicative_op): ...here.
4992 (extract_range_from_binary_expr_1): Extract wide int binary
4993 operations into their own functions.
4994 (wide_int_range_lshift): New.
4995 (wide_int_range_can_optimize_bit_op): New.
4996 (wide_int_range_shift_undefined_p): New.
4997 (wide_int_range_bit_xor): New.
4998 (wide_int_range_bit_ior): New.
4999 (wide_int_range_bit_and): New.
5000 (wide_int_range_trunc_mod): New.
5001 (extract_range_into_wide_ints): New.
5002 (vrp_shift_undefined_p): New.
5003 (extract_range_from_multiplicative_op): New.
5004 (vrp_can_optimize_bit_op): New.
5005 * tree-vrp.h (value_range::dump): New.
5006 (wide_int_range_multiplicative_op): New.
5007 (wide_int_range_lshift):New.
5008 (wide_int_range_shift_undefined_p): New.
5009 (wide_int_range_bit_xor): New.
5010 (wide_int_range_bit_ior): New.
5011 (wide_int_range_bit_and): New.
5012 (wide_int_range_trunc_mod): New.
5013 (zero_nonzero_bits_from_bounds): Rename to...
5014 (wide_int_set_zero_nonzero_bits): ...this.
5015 (zero_nonzero_bits_from_vr): Rename to...
5016 (vrp_set_zero_nonzero_bits): ...this.
5017 (range_easy_mask_min_max): Rename to...
5018 (wide_int_range_can_optimize_bit_op): this.
5019 * vr-values.c (simplify_bit_ops_using_ranges): Rename
5020 zero_nonzero_bits_from_vr into vrp_set_zero_nonzero_bits.
5022 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
5024 * tree-vectorizer.h (vect_orig_stmt): New function.
5025 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Use it.
5026 * tree-vect-loop.c (vect_model_reduction_cost): Likewise.
5027 (vect_create_epilog_for_reduction): Likewise.
5028 (vectorizable_live_operation): Likewise.
5029 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
5030 (vect_detect_hybrid_slp_stmts, vect_schedule_slp): Likewise.
5031 * tree-vect-stmts.c (vectorizable_call): Likewise.
5032 (vectorizable_simd_clone_call, vect_remove_stores): Likewise.
5034 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
5036 * tree-vectorizer.h (vect_transform_stmt): Remove grouped_store
5038 * tree-vect-stmts.c (vect_transform_stmt): Likewise.
5039 * tree-vect-loop.c (vect_transform_loop_stmt): Update call accordingly.
5040 (vect_transform_loop): Likewise.
5041 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
5043 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
5045 * tree-vectorizer.h (vect_schedule_slp): Return void.
5046 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
5047 (vect_schedule_slp): Likewise.
5049 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
5051 * tree-vect-loop.c (vect_transform_loop_stmt): Remove slp_scheduled
5053 (vect_transform_loop): Update calls accordingly. Schedule SLP
5054 instances before the main loop, if any exist.
5056 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
5058 PR tree-optimization/86749
5059 * tree-vect-patterns.c (vect_determine_min_output_precision_1):
5060 If the lhs is used in a COND_EXPR, check that it is being used
5061 as the "then" or "else" value.
5063 2018-08-01 Tom de Vries <tdevries@suse.de>
5066 * config/nvptx/nvptx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
5067 speculation_safe_value_not_needed.
5069 2018-08-01 Richard Biener <rguenther@suse.de>
5071 * tree-ssa-sccvn.c (visit_phi): Compare invariant addresses
5074 2018-08-01 Martin Liska <mliska@suse.cz>
5076 * value-prof.c (gimple_divmod_fixed_value_transform): Unify
5077 format how successful transformation is dumped.
5078 (gimple_mod_pow2_value_transform): Likewise.
5079 (gimple_mod_subtract_transform): Likewise.
5080 (gimple_stringops_transform): Likewise.
5082 2018-08-01 Martin Liska <mliska@suse.cz>
5085 * value-prof.c (interesting_stringop_to_profile_p):
5086 Simplify the code and add BUILT_IN_MEMMOVE.
5087 (gimple_stringops_transform): Likewise.
5089 2018-08-01 Sam Tebbs <sam.tebbs@arm.com>
5091 * config/aarch64/aarch64-simd.md
5092 (*aarch64_get_lane_zero_extendsi<mode>): Rename to...
5093 (*aarch64_get_lane_zero_extend<GPI:mode><VDQQH:mode>): ... This and
5094 use GPI iterator instead of SI mode.
5096 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
5098 * config/rs6000/rs6000.md (speculation_barrier): Renamed from
5099 rs6000_speculation_barrier.
5100 * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
5101 new barrier pattern name.
5103 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
5105 * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
5106 (speculation_barrier): New insn.
5108 2018-08-01 Richard Biener <rguenther@suse.de>
5111 * graphite.h: Include isl/id.h and isl/space.h to allow build
5114 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
5117 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
5118 mode for COFF targets.
5119 * defaults.h (TARGET_COFF): Define.
5120 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
5121 TARGET_COFF): Define.
5122 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
5123 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
5124 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
5126 2018-07-31 Alexandre Oliva <oliva@adacore.com>
5128 * gimple-streamer-in.c (input_bb): Restore BB discriminator.
5129 * gimple-streamer-out.c (output_bb): Save it.
5130 * lto-streamer-in.c (input_struct_function_base): Restore
5131 instance discriminator if available. Create map on demand.
5132 * lto-streamer-out.c (output_struct_function_base): Save it if
5134 * final.c (decl_to_instance_map): Document LTO strategy.
5136 2018-07-31 Alexandre Oliva <oliva@adacore.com>
5137 Olivier Hainque <hainque@adacore.com>
5139 * debug.h (decl_to_instance_map_t): New type.
5140 (decl_to_instance_map): Declare.
5141 (maybe_create_decl_to_instance_map): New inline function.
5142 * final.c (bb_discriminator, last_bb_discriminator): New statics,
5143 to track basic block discriminators.
5144 (final_start_function_1): Initialize them.
5145 (final_scan_insn_1): On NOTE_INSN_BASIC_BLOCK, track
5147 (decl_to_instance_map): New variable.
5148 (map_decl_to_instance, maybe_set_discriminator): New functions.
5149 (notice_source_line): Set discriminator.
5151 2018-07-31 Ian Lance Taylor <iant@golang.org>
5153 * targhooks.c (default_have_speculation_safe_value): Add
5156 2018-07-31 David Malcolm <dmalcolm@redhat.com>
5158 * dump-context.h: Include "pretty-print.h".
5159 (dump_context::refresh_dumps_are_enabled): New decl.
5160 (dump_context::emit_item): New decl.
5161 (class dump_context): Add fields "m_test_pp" and
5163 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
5164 (temp_dump_context::get_dumped_text): New decl.
5165 (class temp_dump_context): Add field "m_pp".
5166 * dumpfile.c (refresh_dumps_are_enabled): Convert to...
5167 (dump_context::refresh_dumps_are_enabled): ...and add a test for
5169 (set_dump_file): Update for above change.
5170 (set_alt_dump_file): Likewise.
5171 (dump_loc): New overload, taking a pretty_printer *.
5172 (dump_context::dump_loc): Call end_any_optinfo. Dump the location
5173 to any test pretty-printer.
5174 (make_item_for_dump_gimple_stmt): New function, adapted from
5175 optinfo::add_gimple_stmt.
5176 (dump_context::dump_gimple_stmt): Call it, and use the result,
5177 eliminating the direct usage of dump_file and alt_dump_file in
5178 favor of indirectly using them via emit_item.
5179 (make_item_for_dump_gimple_expr): New function, adapted from
5180 optinfo::add_gimple_expr.
5181 (dump_context::dump_gimple_expr): Call it, and use the result,
5182 eliminating the direct usage of dump_file and alt_dump_file in
5183 favor of indirectly using them via emit_item.
5184 (make_item_for_dump_generic_expr): New function, adapted from
5186 (dump_context::dump_generic_expr): Call it, and use the result,
5187 eliminating the direct usage of dump_file and alt_dump_file in
5188 favor of indirectly using them via emit_item.
5189 (make_item_for_dump_printf_va): New function, adapted from
5190 optinfo::add_printf_va.
5191 (make_item_for_dump_printf): New function.
5192 (dump_context::dump_printf_va): Call make_item_for_dump_printf_va,
5193 and use the result, eliminating the direct usage of dump_file and
5194 alt_dump_file in favor of indirectly using them via emit_item.
5195 (make_item_for_dump_dec): New function.
5196 (dump_context::dump_dec): Call it, and use the result,
5197 eliminating the direct usage of dump_file and alt_dump_file in
5198 favor of indirectly using them via emit_item.
5199 (make_item_for_dump_symtab_node): New function, adapted from
5200 optinfo::add_symtab_node.
5201 (dump_context::dump_symtab_node): Call it, and use the result,
5202 eliminating the direct usage of dump_file and alt_dump_file in
5203 favor of indirectly using them via emit_item.
5204 (dump_context::begin_scope): Reimplement, avoiding direct usage
5205 of dump_file and alt_dump_file in favor of indirectly using them
5207 (dump_context::emit_item): New member function.
5208 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
5209 Set up test pretty-printer on the underlying context. Call
5210 refresh_dumps_are_enabled.
5211 (temp_dump_context::~temp_dump_context): Call
5212 refresh_dumps_are_enabled.
5213 (temp_dump_context::get_dumped_text): New member function.
5214 (selftest::verify_dumped_text): New function.
5215 (ASSERT_DUMPED_TEXT_EQ): New macro.
5216 (selftest::test_capture_of_dump_calls): Run all tests twice, with
5217 and then without optinfo enabled. Add uses of
5218 ASSERT_DUMPED_TEXT_EQ to all tests. Add test of nested scopes.
5219 * dumpfile.h: Update comment for the dump_* API.
5220 * optinfo-emit-json.cc
5221 (selftest::test_building_json_from_dump_calls): Update for new
5222 param for temp_dump_context ctor.
5223 * optinfo.cc (optinfo_item::optinfo_item): Remove "owned" param
5224 and "m_owned" field.
5225 (optinfo_item::~optinfo_item): Likewise.
5226 (optinfo::add_item): New member function.
5227 (optinfo::emit): Update comment.
5228 (optinfo::add_string): Delete.
5229 (optinfo::add_printf): Delete.
5230 (optinfo::add_printf_va): Delete.
5231 (optinfo::add_gimple_stmt): Delete.
5232 (optinfo::add_gimple_expr): Delete.
5233 (optinfo::add_tree): Delete.
5234 (optinfo::add_symtab_node): Delete.
5235 (optinfo::add_dec): Delete.
5236 * optinfo.h (class dump_context): New forward decl.
5237 (optinfo::add_item): New decl.
5238 (optinfo::add_string): Delete.
5239 (optinfo::add_printf): Delete.
5240 (optinfo::add_printf_va): Delete.
5241 (optinfo::add_gimple_stmt): Delete.
5242 (optinfo::add_gimple_expr): Delete.
5243 (optinfo::add_tree): Delete.
5244 (optinfo::add_symtab_node): Delete.
5245 (optinfo::add_dec): Delete.
5246 (optinfo::add_poly_int): Delete.
5247 (optinfo_item::optinfo_item): Remove "owned" param.
5248 (class optinfo_item): Remove field "m_owned".
5250 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
5253 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
5254 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
5255 requested variable alignment.
5256 (expand_one_ssa_partition): Likewise.
5257 (expand_one_var): Likewise.
5259 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5261 * config/pdp11/pdp11.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
5262 to speculation_safe_value_not_needed.
5264 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5266 * targhooks.h (speculation_safe_value_not_needed): New prototype.
5267 * targhooks.c (speculation_safe_value_not_needed): New function.
5268 * target.def (have_speculation_safe_value): Update documentation.
5269 * doc/tm.texi: Regenerated.
5271 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5273 * config/aarch64/iterators.md (ALLI_TI): New iterator.
5274 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>): New
5276 (despeculate_copy<ALLI:mode>_insn): New insn.
5277 (despeculate_copyti_insn): New insn.
5278 (despeculate_simple<ALLI:mode>): New insn
5279 (despeculate_simpleti): New insn.
5280 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): New
5282 (TARGET_SPECULATION_SAFE_VALUE): Redefine to
5283 aarch64_speculation_safe_value.
5284 (aarch64_print_operand): Handle const0_rtx in modifier 'H'.
5286 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5288 * config/aarch64/aarch64-speculation.cc: New file.
5289 * config/aarch64/aarch64-passes.def (pass_track_speculation): Add
5290 before pass_reorder_blocks.
5291 * config/aarch64/aarch64-protos.h (make_pass_track_speculation): Add
5293 * config/aarch64/aarch64.c (aarch64_conditional_register_usage): Fix
5294 X14 and X15 when tracking speculation.
5295 * config/aarch64/aarch64.md (register name constants): Add
5296 SPECULATION_TRACKER_REGNUM and SPECULATION_SCRATCH_REGNUM.
5297 (unspec): Add UNSPEC_SPECULATION_TRACKER.
5298 (speculation_barrier): New insn attribute.
5299 (cmp<mode>): Allow SP in comparisons.
5300 (speculation_tracker): New insn.
5301 (speculation_barrier): Add speculation_barrier attribute.
5302 * config/aarch64/t-aarch64: Add make rule for aarch64-speculation.o.
5303 * config.gcc (aarch64*-*-*): Add aarch64-speculation.o to extra_objs.
5304 * doc/invoke.texi (AArch64 Options): Document -mtrack-speculation.
5306 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5308 * config/aarch64/aarch64.md (cb<optab><mode>1): Disable when
5309 aarch64_track_speculation is true.
5310 (tb<optab><mode>1): Likewise.
5311 * config/aarch64/aarch64.c (aarch64_split_compare_regs): Do not
5312 generate CB[N]Z when tracking speculation.
5313 (aarch64_split_compare_and_swap): Likewise.
5314 (aarch64_split_atomic_op): Likewise.
5316 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5318 * config/aarch64/aarch64.opt (mtrack-speculation): New target option.
5320 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5322 * config/aarch64.md (unspecv): Add UNSPECV_SPECULAION_BARRIER.
5323 (speculation_barrier): New insn.
5325 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5327 * config/arm/unspecs.md (unspecv): Add VUNSPEC_SPECULATION_BARRIER.
5328 * config/arm/arm.md (speculation_barrier): New expand.
5329 (speculation_barrier_insn): New pattern.
5331 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
5333 * builtin-types.def (BT_FN_PTR_PTR_VAR): New function type.
5334 (BT_FN_I1_I1_VAR, BT_FN_I2_I2_VAR, BT_FN_I4_I4_VAR): Likewise.
5335 (BT_FN_I8_I8_VAR, BT_FN_I16_I16_VAR): Likewise.
5336 * builtin-attrs.def (ATTR_NOVOPS_NOTHROW_LEAF_LIST): New attribute
5338 * builtins.def (BUILT_IN_SPECULATION_SAFE_VALUE_N): New builtin.
5339 (BUILT_IN_SPECULATION_SAFE_VALUE_PTR): New internal builtin.
5340 (BUILT_IN_SPECULATION_SAFE_VALUE_1): Likewise.
5341 (BUILT_IN_SPECULATION_SAFE_VALUE_2): Likewise.
5342 (BUILT_IN_SPECULATION_SAFE_VALUE_4): Likewise.
5343 (BUILT_IN_SPECULATION_SAFE_VALUE_8): Likewise.
5344 (BUILT_IN_SPECULATION_SAFE_VALUE_16): Likewise.
5345 * builtins.c (expand_speculation_safe_value): New function.
5346 (expand_builtin): Call it.
5347 * doc/cpp.texi: Document predefine __HAVE_SPECULATION_SAFE_VALUE.
5348 * doc/extend.texi: Document __builtin_speculation_safe_value.
5349 * doc/md.texi: Document "speculation_barrier" pattern.
5350 * doc/tm.texi.in: Pull in TARGET_SPECULATION_SAFE_VALUE and
5351 TARGET_HAVE_SPECULATION_SAFE_VALUE.
5352 * doc/tm.texi: Regenerated.
5353 * target.def (have_speculation_safe_value, speculation_safe_value): New
5355 * targhooks.c (default_have_speculation_safe_value): New function.
5356 (default_speculation_safe_value): New function.
5357 * targhooks.h (default_have_speculation_safe_value): Add prototype.
5358 (default_speculation_safe_value): Add prototype.
5360 2018-07-31 David Malcolm <dmalcolm@redhat.com>
5362 * dump-context.h (dump_context::dump_loc): New decl.
5363 * dumpfile.c (dump_context::dump_loc): New member function.
5364 (dump_context::dump_gimple_stmt_loc): Reimplement using dump_loc
5365 and dump_gimple_stmt.
5366 (dump_context::dump_gimple_expr_loc): Likewise, using
5368 (dump_context::dump_generic_expr_loc): Likewise, using
5370 (dump_context::dump_printf_loc_va): Likewise, using
5372 (dump_context::begin_scope): Explicitly using the global function
5373 "dump_loc", rather than the member function.
5375 2018-07-31 Martin Sebor <msebor@redhat.com>
5377 PR tree-optimization/86741
5378 * tree-vrp.c (vrp_prop::check_mem_ref): Avoid incomplete types.
5380 2018-07-31 Andreas Krebbel <krebbel@linux.ibm.com>
5382 * config/s390/s390.c (s390_expand_setmem): Make the unrolling to
5383 depend on whether prefetch instructions will be emitted or not.
5384 Use TARGET_SETMEM_PFD for checking whether prefetch instructions
5385 will be emitted or not.
5386 * config/s390/s390.h (TARGET_SETMEM_PREFETCH_DISTANCE)
5387 (TARGET_SETMEM_PFD): New macros.
5389 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5391 * tree-vectorizer.h (stmt_vec_info): Turn back into a typedef.
5392 (NULL_STMT_VEC_INFO): Delete.
5393 (stmt_vec_info::operator*): Likewise.
5394 (stmt_vec_info::operator gimple *): Likewise.
5395 * tree-vect-loop.c (vectorizable_reduction): Use NULL instead
5396 of NULL_STMT_VEC_INFO.
5397 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
5398 (vect_reassociating_reduction_p): Likewise.
5399 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
5400 (vectorizable_store): Likewise.
5401 * tree-vectorizer.c (vec_info::set_vinfo_for_stmt): Likewise.
5402 (vec_info::free_stmt_vec_infos): Likewise.
5404 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5406 * tree-vectorizer.h (vect_stmt_in_region_p): Delete.
5407 * tree-vectorizer.c (vect_stmt_in_region_p): Likewise.
5409 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5411 * tree-vectorizer.h (vec_info::new_vinfo_for_stmt)
5412 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
5413 (vec_info::free_stmt_vec_info): New private member functions.
5414 (set_stmt_vec_info_vec, free_stmt_vec_infos, vinfo_for_stmt)
5415 (set_vinfo_for_stmt, new_stmt_vec_info, free_stmt_vec_info): Delete.
5416 * tree-parloops.c (gather_scalar_reductions): Remove calls to
5417 set_stmt_vec_info_vec and free_stmt_vec_infos.
5418 * tree-vect-loop.c (_loop_vec_info): Remove call to
5419 set_stmt_vec_info_vec.
5420 * tree-vect-stmts.c (new_stmt_vec_info, set_stmt_vec_info_vec)
5421 (free_stmt_vec_infos, free_stmt_vec_info): Delete in favor of...
5422 * tree-vectorizer.c (vec_info::new_stmt_vec_info)
5423 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
5424 (vec_info::free_stmt_vec_info): ...these new functions. Remove
5425 assignments in {vec_info::,}new_stmt_vec_info that are redundant
5426 with the clearing in the xcalloc.
5427 (stmt_vec_info_vec): Delete.
5428 (vec_info::vec_info): Don't call set_stmt_vec_info_vec.
5429 (vectorize_loops): Likewise.
5430 (vec_info::~vec_info): Remove argument from call to
5431 free_stmt_vec_infos.
5432 (vec_info::add_stmt): Remove vinfo argument from call to
5435 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5437 * tree-vectorizer.h (free_stmt_vec_info): Take a stmt_vec_info
5438 rather than a gimple stmt.
5439 * tree-vect-stmts.c (free_stmt_vec_info): Likewise. Don't free
5440 information for pattern statements when passed the original
5441 statement; instead wait to be passed the pattern statement itself.
5442 Don't call set_vinfo_for_stmt here.
5443 (free_stmt_vec_infos): Update call to free_stmt_vec_info.
5444 * tree-vect-loop.c (_loop_vec_info::~loop_vec_info): Don't free
5445 stmt_vec_infos here.
5446 * tree-vect-slp.c (_bb_vec_info::~bb_vec_info): Likewise.
5447 * tree-vectorizer.c (vec_info::remove_stmt): Nullify the statement's
5448 stmt_vec_infos entry.
5450 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5452 * tree-vectorizer.h (vec_info::replace_stmt): Declare.
5453 * tree-vectorizer.c (vec_info::replace_stmt): New function.
5454 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Use it.
5455 * tree-vect-stmts.c (vectorizable_call): Likewise.
5456 (vectorizable_simd_clone_call): Likewise.
5458 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5460 * tree-vectorizer.h (vec_info::remove_stmt): Declare.
5461 * tree-vectorizer.c (vec_info::remove_stmt): New function.
5462 * tree-vect-loop-manip.c (vect_set_loop_condition): Use it.
5463 * tree-vect-loop.c (vect_transform_loop): Likewise.
5464 * tree-vect-slp.c (vect_schedule_slp): Likewise.
5465 * tree-vect-stmts.c (vect_remove_stores): Likewise.
5467 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5469 * tree-vectorizer.h (vec_info::lookup_dr): New member function.
5470 (vect_dr_stmt): Delete.
5471 * tree-vectorizer.c (vec_info::lookup_dr): New function.
5472 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Use it instead
5474 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
5475 (vect_analyze_data_ref_dependence, vect_record_base_alignments)
5476 (vect_verify_datarefs_alignment, vect_peeling_supportable)
5477 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
5478 (vect_analyze_data_refs): Likewise.
5479 (vect_slp_analyze_data_ref_dependence): Likewise. Take a vec_info
5481 (vect_find_same_alignment_drs): Likewise.
5482 (vect_slp_analyze_node_dependences): Update calls accordingly.
5483 (vect_analyze_data_refs_alignment): Likewise. Use vec_info::lookup_dr
5484 instead of DR_VECT_AUX.
5485 (vect_get_peeling_costs_all_drs): Take a loop_vec_info instead
5486 of a vector data references. Use vec_info::lookup_dr instead of
5488 (vect_peeling_hash_get_lowest_cost): Update calls accordingly.
5489 (vect_enhance_data_refs_alignment): Likewise. Use vec_info::lookup_dr
5490 instead of DR_VECT_AUX.
5492 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5494 * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
5496 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
5498 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
5499 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
5500 (vect_gen_prolog_loop_niters): Likewise.
5502 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5504 * tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
5505 (DR_TARGET_ALIGNMENT, aligned_access_p, known_alignment_for_access_p)
5506 (vect_known_alignment_in_bytes, vect_dr_behavior)
5507 (vect_get_scalar_dr_size): Take references as dr_vec_infos
5508 instead of data_references. Update calls to other routines for
5509 which the same change has been made.
5510 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Take
5511 dr_vec_infos instead of stmt_vec_infos.
5512 (vect_analyze_data_ref_dependence): Update call accordingly.
5513 (vect_slp_analyze_data_ref_dependence)
5514 (vect_record_base_alignments): Use DR_VECT_AUX.
5515 (vect_calculate_target_alignment, vect_compute_data_ref_alignment)
5516 (vect_update_misalignment_for_peel, verify_data_ref_alignment)
5517 (vector_alignment_reachable_p, vect_get_data_access_cost)
5518 (vect_peeling_supportable, vect_analyze_group_access_1)
5519 (vect_analyze_group_access, vect_analyze_data_ref_access)
5520 (vect_vfa_segment_size, vect_vfa_access_size, vect_vfa_align)
5521 (vect_compile_time_alias, vect_small_gap_p)
5522 (vectorizable_with_step_bound_p, vect_duplicate_ssa_name_ptr_info):
5523 (vect_supportable_dr_alignment): Take references as dr_vec_infos
5524 instead of data_references. Update calls to other routines for
5525 which the same change has been made.
5526 (vect_verify_datarefs_alignment, vect_get_peeling_costs_all_drs)
5527 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
5528 (vect_slp_analyze_and_verify_node_alignment)
5529 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
5530 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
5531 (vect_setup_realignment): Use dr_vec_infos. Update calls after
5533 (_vect_peel_info::dr): Replace with...
5534 (_vect_peel_info::dr_info): ...this new field.
5535 (vect_peeling_hash_get_most_frequent)
5536 (vect_peeling_hash_choose_best_peeling): Update accordingly.
5537 (vect_peeling_hash_get_lowest_cost):
5538 (vect_enhance_data_refs_alignment): Likewise. Update calls to other
5539 routines for which the same change has been made.
5540 (vect_peeling_hash_insert): Likewise. Take a dr_vec_info instead of a
5542 * tree-vect-loop-manip.c (get_misalign_in_elems)
5543 (vect_gen_prolog_loop_niters): Use dr_vec_infos. Update calls after
5545 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
5546 * tree-vect-stmts.c (vect_get_store_cost, vect_get_load_cost)
5547 (vect_truncate_gather_scatter_offset, compare_step_with_zero)
5548 (get_group_load_store_type, get_negative_load_store_type)
5549 (vect_get_data_ptr_increment, vectorizable_store)
5550 (vectorizable_load): Likewise.
5551 (ensure_base_align): Take a dr_vec_info instead of a data_reference.
5552 Update calls to other routines for which the same change has been made.
5554 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5556 * tree-vectorizer.h (vec_info::move_dr): New member function.
5557 (dataref_aux): Rename to...
5558 (dr_vec_info): ...this and add "dr" and "stmt" fields.
5559 (_stmt_vec_info::dr_aux): Update accordingly.
5560 (_stmt_vec_info::data_ref_info): Delete.
5561 (STMT_VINFO_GROUPED_ACCESS, DR_GROUP_FIRST_ELEMENT)
5562 (DR_GROUP_NEXT_ELEMENT, DR_GROUP_SIZE, DR_GROUP_STORE_COUNT)
5563 (DR_GROUP_GAP, DR_GROUP_SAME_DR_STMT, REDUC_GROUP_FIRST_ELEMENT):
5564 (REDUC_GROUP_NEXT_ELEMENT, REDUC_GROUP_SIZE): Use dr_aux.dr instead
5566 (STMT_VINFO_DATA_REF): Likewise. Turn into an lvalue.
5567 (STMT_VINFO_DR_INFO): New macro.
5568 (DR_VECT_AUX): Use STMT_VINFO_DR_INKFO and vect_dr_stmt.
5569 (set_dr_misalignment): Update after rename of dataref_aux.
5570 (vect_dr_stmt): Move earlier in file. Return dr_aux.stmt.
5571 * tree-vect-stmts.c (new_stmt_vec_info): Remove redundant
5572 initialization of STMT_VINFO_DATA_REF.
5573 * tree-vectorizer.c (vec_info::move_dr): New function.
5574 * tree-vect-patterns.c (vect_recog_bool_pattern)
5575 (vect_recog_mask_conversion_pattern)
5576 (vect_recog_gather_scatter_pattern): Use it.
5577 * tree-vect-data-refs.c (vect_analyze_data_refs): Initialize
5578 the "dr" and "stmt" fields of dr_vec_info instead of
5579 STMT_VINFO_DATA_REF.
5581 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5583 * tree-vectorizer.h (_stmt_vec_info::pattern_stmt_p): New field.
5584 (is_pattern_stmt_p): Use it.
5585 * tree-vect-patterns.c (vect_init_pattern_stmt): Set pattern_stmt_p
5586 on pattern statements.
5588 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5590 * tree-vect-patterns.c (vect_mark_pattern_stmts): Take the
5591 original stmt as a stmt_vec_info rather than a gimple stmt.
5592 (vect_pattern_recog_1): Take the statement directly as a
5593 stmt_vec_info, rather than via a gimple_stmt_iterator.
5594 Update call to vect_mark_pattern_stmts.
5595 (vect_pattern_recog): Update calls accordingly.
5597 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5599 * tree-vectorizer.h (vect_get_vec_defs_for_stmt_copy)
5600 (vect_get_vec_def_for_stmt_copy): Take a vec_info rather than
5601 a vect_def_type for the first argument.
5602 * tree-vect-stmts.c (vect_get_vec_defs_for_stmt_copy): Likewise.
5603 (vect_get_vec_def_for_stmt_copy): Likewise. Return the original
5604 operand if it isn't defined by a vectorized statement.
5605 (vect_build_gather_load_calls): Remove the mask_dt argument and
5606 update calls to vect_get_vec_def_for_stmt_copy.
5607 (vectorizable_bswap): Likewise the dt argument.
5608 (vectorizable_call): Update calls to vectorizable_bswap and
5609 vect_get_vec_def_for_stmt_copy.
5610 (vectorizable_simd_clone_call, vectorizable_assignment)
5611 (vectorizable_shift, vectorizable_operation, vectorizable_condition)
5612 (vectorizable_comparison): Update calls to
5613 vect_get_vec_def_for_stmt_copy.
5614 (vectorizable_store): Likewise. Remove now-unnecessary calls to
5616 (vect_get_loop_based_defs): Remove dt argument and update call
5617 to vect_get_vec_def_for_stmt_copy.
5618 (vectorizable_conversion): Update calls to vect_get_loop_based_defs
5619 and vect_get_vec_def_for_stmt_copy.
5620 (vectorizable_load): Update calls to vect_build_gather_load_calls
5621 and vect_get_vec_def_for_stmt_copy.
5622 * tree-vect-loop.c (vect_create_epilog_for_reduction)
5623 (vectorizable_reduction, vectorizable_live_operation): Update calls
5624 to vect_get_vec_def_for_stmt_copy.
5626 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5628 * tree-vect-data-refs.c (vect_record_base_alignment): Replace vec_info
5629 and gimple stmt arguments with a stmt_vec_info.
5630 (vect_record_base_alignments): Update calls accordingly.
5631 * tree-vect-slp.c (vect_record_max_nunits): Replace vec_info
5632 and gimple stmt arguments with a stmt_vec_info.
5633 (vect_build_slp_tree_1): Remove vinfo argument and update call
5634 to vect_record_max_nunits.
5635 (vect_build_slp_tree_2): Update calls to vect_build_slp_tree_1
5636 and vect_record_max_nunits.
5638 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5640 * tree-vectorizer.h (nested_in_vect_loop_p): Move further down
5641 file and take a stmt_vec_info instead of a gimple stmt.
5642 (supportable_widening_operation, vect_finish_replace_stmt)
5643 (vect_finish_stmt_generation, vect_get_store_rhs)
5644 (vect_get_vec_def_for_operand_1, vect_get_vec_def_for_operand)
5645 (vect_get_vec_defs, vect_init_vector, vect_transform_stmt)
5646 (vect_remove_stores, vect_analyze_stmt, vectorizable_condition)
5647 (vect_get_smallest_scalar_type, vect_check_gather_scatter)
5648 (vect_create_data_ref_ptr, bump_vector_ptr)
5649 (vect_permute_store_chain, vect_setup_realignment)
5650 (vect_transform_grouped_load, vect_record_grouped_load_vectors)
5651 (vect_create_addr_base_for_vector_ref, vectorizable_live_operation)
5652 (vectorizable_reduction, vectorizable_induction)
5653 (get_initial_def_for_reduction, is_simple_and_all_uses_invariant)
5654 (vect_get_place_in_interleaving_chain): Take stmt_vec_infos rather
5655 than gimple stmts as arguments.
5656 * tree-vect-data-refs.c (vect_get_smallest_scalar_type)
5657 (vect_preserves_scalar_order_p, vect_slp_analyze_node_dependences)
5658 (can_group_stmts_p, vect_check_gather_scatter)
5659 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
5660 (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment)
5661 (vect_permute_load_chain, vect_shift_permute_load_chain)
5662 (vect_transform_grouped_load)
5663 (vect_record_grouped_load_vectors): Likewise.
5664 * tree-vect-loop.c (vect_fixup_reduc_chain)
5665 (get_initial_def_for_reduction, vect_create_epilog_for_reduction)
5666 (vectorize_fold_left_reduction, is_nonwrapping_integer_induction)
5667 (vectorizable_reduction, vectorizable_induction)
5668 (vectorizable_live_operation, vect_loop_kill_debug_uses): Likewise.
5669 * tree-vect-patterns.c (type_conversion_p, adjust_bool_stmts)
5670 (vect_get_load_store_mask): Likewise.
5671 * tree-vect-slp.c (vect_get_place_in_interleaving_chain)
5672 (vect_analyze_slp_instance, vect_mask_constant_operand_p): Likewise.
5673 * tree-vect-stmts.c (vect_mark_relevant)
5674 (is_simple_and_all_uses_invariant)
5675 (exist_non_indexing_operands_for_use_p, process_use)
5676 (vect_init_vector_1, vect_init_vector, vect_get_vec_def_for_operand_1)
5677 (vect_get_vec_def_for_operand, vect_get_vec_defs)
5678 (vect_finish_stmt_generation_1, vect_finish_replace_stmt)
5679 (vect_finish_stmt_generation, vect_truncate_gather_scatter_offset)
5680 (compare_step_with_zero, vect_get_store_rhs, get_group_load_store_type)
5681 (get_negative_load_store_type, get_load_store_type)
5682 (vect_check_load_store_mask, vect_check_store_rhs)
5683 (vect_build_gather_load_calls, vect_get_strided_load_store_ops)
5684 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
5685 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
5686 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
5687 (get_group_alias_ptr_type, vectorizable_store, hoist_defs_of_uses)
5688 (vectorizable_load, vectorizable_condition, vectorizable_comparison)
5689 (vect_analyze_stmt, vect_transform_stmt, vect_remove_stores)
5690 (supportable_widening_operation): Likewise.
5692 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5694 * tree-vect-data-refs.c (vect_describe_gather_scatter_call): Take
5695 a stmt_vec_info instead of a gcall.
5696 (vect_check_gather_scatter): Update call accordingly.
5697 * tree-vect-loop-manip.c (iv_phi_p): Take a stmt_vec_info instead
5699 (vect_can_advance_ivs_p, vect_update_ivs_after_vectorizer)
5700 (slpeel_update_phi_nodes_for_loops):): Update calls accordingly.
5701 * tree-vect-loop.c (vect_transform_loop_stmt): Take a stmt_vec_info
5702 instead of a gimple stmt.
5703 (vect_transform_loop): Update calls accordingly.
5704 * tree-vect-slp.c (vect_split_slp_store_group): Take and return
5705 stmt_vec_infos instead of gimple stmts.
5706 (vect_analyze_slp_instance): Update use accordingly.
5707 * tree-vect-stmts.c (read_vector_array, write_vector_array)
5708 (vect_clobber_variable, vect_stmt_relevant_p, permute_vec_elements)
5709 (vect_use_strided_gather_scatters_p, vect_build_all_ones_mask)
5710 (vect_build_zero_merge_argument, vect_get_gather_scatter_ops)
5711 (vect_gen_widened_results_half, vect_get_loop_based_defs)
5712 (vect_create_vectorized_promotion_stmts, can_vectorize_live_stmts):
5713 Take a stmt_vec_info instead of a gimple stmt and pass stmt_vec_infos
5714 down to subroutines.
5716 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5718 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Change the type
5719 of the worklist from a vector of gimple stmts to a vector of
5721 * tree-vect-stmts.c (vect_mark_relevant, process_use)
5722 (vect_mark_stmts_to_be_vectorized): Likewise
5724 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5726 * tree-vect-loop.c (vect_analyze_loop_operations): Look up the
5727 statement before passing it to vect_analyze_stmt.
5728 (vect_create_epilog_for_reduction): Use a stmt_vec_info to walk
5729 the chain of phi vector definitions. Track the exit phi via its
5731 (vectorizable_reduction): Set cond_stmt_vinfo directly from the
5732 STMT_VINFO_REDUC_DEF.
5733 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Use
5734 stmt_vec_infos to handle the statement chains.
5735 (vect_get_slp_defs): Record the first statement in the node
5736 using a stmt_vec_info.
5737 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Look up
5738 statements here and pass their stmt_vec_info down to subroutines.
5739 (vect_init_vector_1): Hoist call to vinfo_for_stmt and pass it
5740 down to vect_finish_stmt_generation.
5741 (vect_init_vector, vect_get_vec_defs, vect_finish_replace_stmt)
5742 (vect_finish_stmt_generation): Call vinfo_for_stmt and pass
5743 stmt_vec_infos to subroutines.
5744 (vect_remove_stores): Use stmt_vec_infos to handle the statement
5747 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5749 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences):
5750 (vect_check_gather_scatter, vect_create_data_ref_ptr, bump_vector_ptr)
5751 (vect_permute_store_chain, vect_setup_realignment)
5752 (vect_permute_load_chain, vect_shift_permute_load_chain)
5753 (vect_transform_grouped_load): Use stmt_vec_info rather than gimple
5754 stmts internally, and when passing values to other vectorizer routines.
5755 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
5756 * tree-vect-loop.c (vect_analyze_scalar_cycles_1)
5757 (vect_analyze_loop_operations, get_initial_def_for_reduction)
5758 (vect_create_epilog_for_reduction, vectorize_fold_left_reduction)
5759 (vectorizable_reduction, vectorizable_induction)
5760 (vectorizable_live_operation, vect_transform_loop_stmt)
5761 (vect_transform_loop): Likewise.
5762 * tree-vect-patterns.c (vect_reassociating_reduction_p)
5763 (vect_recog_widen_op_pattern, vect_recog_mixed_size_cond_pattern)
5764 (vect_recog_bool_pattern, vect_recog_gather_scatter_pattern): Likewise.
5765 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
5766 (vect_slp_analyze_node_operations_1): Likewise.
5767 * tree-vect-stmts.c (vect_mark_relevant, process_use)
5768 (exist_non_indexing_operands_for_use_p, vect_init_vector_1)
5769 (vect_mark_stmts_to_be_vectorized, vect_get_vec_def_for_operand)
5770 (vect_finish_stmt_generation_1, get_group_load_store_type)
5771 (get_load_store_type, vect_build_gather_load_calls)
5772 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
5773 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
5774 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
5775 (vectorizable_store, vectorizable_load, vectorizable_condition)
5776 (vectorizable_comparison, vect_analyze_stmt, vect_transform_stmt)
5777 (supportable_widening_operation): Likewise.
5778 (vect_get_vector_types_for_stmt): Likewise.
5779 * tree-vectorizer.h (vect_dr_behavior): Likewise.
5781 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5783 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
5784 (vect_slp_analyze_node_dependences, vect_analyze_data_ref_accesses)
5785 (vect_permute_store_chain, vect_permute_load_chain)
5786 (vect_shift_permute_load_chain, vect_transform_grouped_load): Avoid
5787 repeated stmt_vec_info lookups.
5788 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
5789 (vect_update_ivs_after_vectorizer): Likewise.
5790 * tree-vect-loop.c (vect_is_simple_reduction): Likewise.
5791 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
5792 * tree-vect-patterns.c (adjust_bool_stmts): Likewise.
5793 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
5794 (vect_bb_slp_scalar_cost): Likewise.
5795 * tree-vect-stmts.c (get_group_alias_ptr_type): Likewise.
5797 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5799 * tree-vect-data-refs.c (vect_check_gather_scatter): Pass the
5800 gcall rather than the generic gimple stmt to gimple_call_internal_fn.
5801 (vect_get_smallest_scalar_type, can_group_stmts_p): Use dyn_cast
5802 to get gassigns and gcalls, rather than operating on generc gimple
5804 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p)
5805 (vect_mark_stmts_to_be_vectorized, vectorizable_store)
5806 (vectorizable_load, vect_analyze_stmt): Likewise.
5807 * tree-vect-loop.c (vectorizable_reduction): Likewise gphi.
5809 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5811 * tree-vectorizer.h (get_earlier_stmt, get_later_stmt): Take and
5812 return stmt_vec_infos rather than gimple stmts. Do not accept
5814 (vect_find_last_scalar_stmt_in_slp): Return a stmt_vec_info instead
5816 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
5817 Update use of get_later_stmt.
5818 (vect_get_constant_vectors): Update call accordingly.
5819 (vect_schedule_slp_instance): Likewise
5820 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Likewise.
5821 (vect_slp_analyze_instance_dependence): Likewise.
5822 (vect_preserves_scalar_order_p): Update use of get_earlier_stmt.
5824 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5826 * tree-vectorizer.h (stmt_info_for_cost::stmt): Replace with...
5827 (stmt_info_for_cost::stmt_info): ...this new field.
5828 (add_stmt_costs): Update accordingly.
5829 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
5830 (vect_get_known_peeling_cost): Likewise.
5831 (vect_estimate_min_profitable_iters): Likewise.
5832 * tree-vect-stmts.c (record_stmt_cost): Likewise.
5834 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5836 * tree-vectorizer.h (_loop_vec_info::may_misalign_stmts): Change
5837 from an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
5838 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
5840 * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
5842 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5844 * tree-vectorizer.h (_stmt_vec_info::same_dr_stmt): Change from
5845 a gimple stmt to a stmt_vec_info.
5846 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
5848 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5850 * tree-vectorizer.h (vec_info::grouped_stores): Change from
5851 an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
5852 (_loop_vec_info::reduction_chains): Likewise.
5853 * tree-vect-loop.c (vect_fixup_scalar_cycles_with_patterns): Update
5855 * tree-vect-slp.c (vect_analyze_slp): Likewise.
5857 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5859 * tree-vectorizer.h (_stmt_vec_info::first_element): Change from
5860 a gimple stmt to a stmt_vec_info.
5861 (_stmt_vec_info::next_element): Likewise.
5862 * tree-vect-data-refs.c (vect_update_misalignment_for_peel)
5863 (vect_slp_analyze_and_verify_node_alignment)
5864 (vect_analyze_group_access_1, vect_analyze_group_access)
5865 (vect_small_gap_p, vect_prune_runtime_alias_test_list)
5866 (vect_create_data_ref_ptr, vect_record_grouped_load_vectors)
5867 (vect_supportable_dr_alignment): Update accordingly.
5868 * tree-vect-loop.c (vect_fixup_reduc_chain): Likewise.
5869 (vect_fixup_scalar_cycles_with_patterns, vect_is_slp_reduction)
5870 (vect_is_simple_reduction, vectorizable_reduction): Likewise.
5871 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
5872 * tree-vect-slp.c (vect_build_slp_tree_1)
5873 (vect_attempt_slp_rearrange_stmts, vect_supported_load_permutation_p)
5874 (vect_split_slp_store_group, vect_analyze_slp_instance)
5875 (vect_analyze_slp, vect_transform_slp_perm_load): Likewise.
5876 * tree-vect-stmts.c (vect_model_store_cost, vect_model_load_cost)
5877 (get_group_load_store_type, get_load_store_type)
5878 (get_group_alias_ptr_type, vectorizable_store, vectorizable_load)
5879 (vect_transform_stmt, vect_remove_stores): Likewise.
5881 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5883 * tree-vectorizer.h (vect_dr_stmt): Return a stmt_vec_info rather
5885 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
5886 (vect_slp_analyze_data_ref_dependence, vect_record_base_alignments)
5887 (vect_calculate_target_alignmentm, vect_compute_data_ref_alignment)
5888 (vect_update_misalignment_for_peel, vect_verify_datarefs_alignment)
5889 (vector_alignment_reachable_p, vect_get_data_access_cost)
5890 (vect_get_peeling_costs_all_drs, vect_peeling_hash_get_lowest_cost)
5891 (vect_peeling_supportable, vect_enhance_data_refs_alignment)
5892 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
5893 (vect_analyze_group_access_1, vect_analyze_group_access)
5894 (vect_analyze_data_ref_access, vect_analyze_data_ref_accesses)
5895 (vect_vfa_access_size, vect_small_gap_p, vect_analyze_data_refs)
5896 (vect_supportable_dr_alignment): Remove vinfo_for_stmt from the
5897 result of vect_dr_stmt and use the stmt_vec_info instead of
5898 the associated gimple stmt.
5899 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
5900 (vect_gen_prolog_loop_niters): Likewise.
5901 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
5903 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5905 * tree-vectorizer.h (_slp_tree::stmts): Change from a vec<gimple *>
5906 to a vec<stmt_vec_info>.
5907 * tree-vect-slp.c (vect_free_slp_tree): Update accordingly.
5908 (vect_create_new_slp_node): Take a vec<gimple *> instead of a
5910 (_slp_oprnd_info::def_stmts): Change from a vec<gimple *>
5911 to a vec<stmt_vec_info>.
5912 (bst_traits::value_type, bst_traits::value_type): Likewise.
5913 (bst_traits::hash): Update accordingly.
5914 (vect_get_and_check_slp_defs): Change the stmts parameter from
5915 a vec<gimple *> to a vec<stmt_vec_info>.
5916 (vect_two_operations_perm_ok_p, vect_build_slp_tree_1): Likewise.
5917 (vect_build_slp_tree): Likewise.
5918 (vect_build_slp_tree_2): Likewise. Update uses of
5919 SLP_TREE_SCALAR_STMTS.
5920 (vect_print_slp_tree): Update uses of SLP_TREE_SCALAR_STMTS.
5921 (vect_mark_slp_stmts, vect_mark_slp_stmts_relevant)
5922 (vect_slp_rearrange_stmts, vect_attempt_slp_rearrange_stmts)
5923 (vect_supported_load_permutation_p, vect_find_last_scalar_stmt_in_slp)
5924 (vect_detect_hybrid_slp_stmts, vect_slp_analyze_node_operations_1)
5925 (vect_slp_analyze_node_operations, vect_slp_analyze_operations)
5926 (vect_bb_slp_scalar_cost, vect_slp_analyze_bb_1)
5927 (vect_get_constant_vectors, vect_get_slp_defs)
5928 (vect_transform_slp_perm_load, vect_schedule_slp_instance)
5929 (vect_remove_slp_scalar_calls, vect_schedule_slp): Likewise.
5930 (vect_analyze_slp_instance): Build up a vec of stmt_vec_infos
5931 instead of gimple stmts.
5932 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Change
5933 the stores parameter for a vec<gimple *> to a vec<stmt_vec_info>.
5934 (vect_slp_analyze_instance_dependence): Update uses of
5935 SLP_TREE_SCALAR_STMTS.
5936 (vect_slp_analyze_and_verify_node_alignment): Likewise.
5937 (vect_slp_analyze_and_verify_instance_alignment): Likewise.
5938 * tree-vect-loop.c (neutral_op_for_slp_reduction): Likewise.
5939 (get_initial_defs_for_reduction): Likewise.
5940 (vect_create_epilog_for_reduction): Likewise.
5941 (vectorize_fold_left_reduction): Likewise.
5942 * tree-vect-stmts.c (vect_prologue_cost_for_slp_op): Likewise.
5943 (vect_model_simple_cost, vectorizable_shift, vectorizable_load)
5944 (can_vectorize_live_stmts): Likewise.
5946 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5948 * tree-vectorizer.h (_loop_vec_info::reductions): Change from an
5949 auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
5950 (vect_force_simple_reduction): Take and return stmt_vec_infos rather
5952 * tree-parloops.c (valid_reduction_p): Take a stmt_vec_info instead
5954 (gather_scalar_reductions): Update after above interface changes.
5955 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
5956 (vect_is_simple_reduction): Take and return stmt_vec_infos rather
5958 (vect_force_simple_reduction): Likewise.
5959 * tree-vect-patterns.c (vect_pattern_recog_1): Update use of
5960 LOOP_VINFO_REDUCTIONS.
5961 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
5963 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5965 * tree-vectorizer.h (_stmt_vec_info::reduc_def): Change from
5966 a gimple stmt to a stmt_vec_info.
5967 * tree-vect-loop.c (vect_active_double_reduction_p)
5968 (vect_force_simple_reduction, vectorizable_reduction): Update
5971 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5973 * tree-vectorizer.h (_slp_tree::vec_stmts): Change from a
5974 vec<gimple *> to a vec<stmt_vec_info>.
5975 * tree-vect-loop.c (vect_create_epilog_for_reduction): Change
5976 the reduction_phis argument from a vec<gimple *> to a
5978 (vectorizable_reduction): Likewise the phis local variable that
5979 is passed to vect_create_epilog_for_reduction. Update for new type
5980 of SLP_TREE_VEC_STMTS.
5981 (vectorizable_induction): Update for new type of SLP_TREE_VEC_STMTS.
5982 (vectorizable_live_operation): Likewise.
5983 * tree-vect-slp.c (vect_get_slp_vect_defs): Likewise.
5984 (vect_transform_slp_perm_load, vect_schedule_slp_instance): Likewise.
5986 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
5988 * tree-vectorizer.h (_stmt_vec_info::vectorized_stmt): Change from
5989 a gimple stmt to a stmt_vec_info.
5990 (vectorizable_condition, vectorizable_live_operation)
5991 (vectorizable_reduction, vectorizable_induction): Pass back the
5992 vectorized statement as a stmt_vec_info.
5993 * tree-vect-data-refs.c (vect_record_grouped_load_vectors): Update
5994 use of STMT_VINFO_VEC_STMT.
5995 * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise,
5996 accumulating the inner phis that feed the STMT_VINFO_VEC_STMT
5997 as stmt_vec_infos rather than gimple stmts.
5998 (vectorize_fold_left_reduction): Change vec_stmt from a gimple stmt
6000 (vectorizable_live_operation): Likewise.
6001 (vectorizable_reduction, vectorizable_induction): Likewise,
6002 updating use of STMT_VINFO_VEC_STMT.
6003 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Update use
6004 of STMT_VINFO_VEC_STMT.
6005 (vect_build_gather_load_calls, vectorizable_bswap, vectorizable_call)
6006 (vectorizable_simd_clone_call, vectorizable_conversion)
6007 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
6008 (vectorizable_store, vectorizable_load, vectorizable_condition)
6009 (vectorizable_comparison, can_vectorize_live_stmts): Change vec_stmt
6010 from a gimple stmt to a stmt_vec_info.
6011 (vect_transform_stmt): Update use of STMT_VINFO_VEC_STMT. Pass a
6012 pointer to a stmt_vec_info to the vectorizable_* routines.
6014 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6016 * tree-vectorizer.h (_stmt_vec_info::related_stmt): Change from
6017 a gimple stmt to a stmt_vec_info.
6018 (is_pattern_stmt_p): Update accordingly.
6019 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Likewise.
6020 (vect_record_grouped_load_vectors): Likewise.
6021 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
6022 (vect_fixup_reduc_chain, vect_update_vf_for_slp): Likewise.
6023 (vect_model_reduction_cost): Likewise.
6024 (vect_create_epilog_for_reduction): Likewise.
6025 (vectorizable_reduction, vectorizable_induction): Likewise.
6026 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
6027 Return the stmt_vec_info for the pattern statement.
6028 (vect_set_pattern_stmt): Update use of STMT_VINFO_RELATED_STMT.
6029 (vect_split_statement, vect_mark_pattern_stmts): Likewise.
6030 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
6031 (vect_detect_hybrid_slp, vect_get_slp_defs): Likewise.
6032 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
6033 (vect_get_vec_def_for_operand_1, vectorizable_call): Likewise.
6034 (vectorizable_simd_clone_call, vect_analyze_stmt, new_stmt_vec_info)
6035 (free_stmt_vec_info, vect_is_simple_use): Likewise.
6037 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6039 * tree-vectorizer.h (vect_finish_replace_stmt): Return a stmt_vec_info
6040 (vect_finish_stmt_generation): Likewise.
6041 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
6042 (vect_finish_replace_stmt, vect_finish_stmt_generation): Likewise.
6043 (vect_build_gather_load_calls): Use the return value of the above
6044 functions instead of a separate call to vinfo_for_stmt. Use narrow
6045 scopes for the input gimple stmt and wider scopes for the associated
6046 stmt_vec_info. Use vec_info::lookup_def when setting these
6047 stmt_vec_infos from an SSA_NAME definition.
6048 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
6049 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
6050 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
6051 (vectorizable_store, vectorizable_load, vectorizable_condition)
6052 (vectorizable_comparison): Likewise.
6053 * tree-vect-loop.c (vectorize_fold_left_reduction): Likewise.
6054 (vectorizable_reduction): Likewise.
6056 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6058 * tree-vectorizer.h (vect_is_simple_use): Add an optional
6059 stmt_vec_info * parameter before the optional gimple **.
6060 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
6061 (process_use, vect_get_vec_def_for_operand_1): Update callers.
6062 (vect_get_vec_def_for_operand, vectorizable_shift): Likewise.
6063 * tree-vect-loop.c (vectorizable_reduction): Likewise.
6064 (vectorizable_live_operation): Likewise.
6065 * tree-vect-patterns.c (type_conversion_p): Likewise.
6066 (vect_look_through_possible_promotion): Likewise.
6067 (vect_recog_rotate_pattern): Likewise.
6068 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
6070 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6072 * tree-vectorizer.h (stmt_vec_info): Temporarily change from
6073 a typedef to a wrapper class.
6074 (NULL_STMT_VEC_INFO): New macro.
6075 (vec_info::stmt_infos): Change to vec<stmt_vec_info>.
6076 (stmt_vec_info::operator*): New function.
6077 (stmt_vec_info::operator gimple *): Likewise.
6078 (set_vinfo_for_stmt): Use NULL_STMT_VEC_INFO.
6079 (add_stmt_costs): Likewise.
6080 * tree-vect-loop-manip.c (iv_phi_p): Likewise.
6081 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
6082 (vect_get_known_peeling_cost): Likewise.
6083 (vect_estimate_min_profitable_iters): Likewise.
6084 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
6085 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Likewise.
6086 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
6087 (vectorizable_store, free_stmt_vec_infos): Likewise.
6088 (new_stmt_vec_info): Change return type of xcalloc to
6091 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6093 * tree-vectorizer.h (vec_info::lookup_single_use): Declare.
6094 * tree-vectorizer.c (vec_info::lookup_single_use): New function.
6095 * tree-vect-loop.c (vectorizable_reduction): Use it instead of
6096 a single_imm_use-based sequence.
6097 * tree-vect-stmts.c (supportable_widening_operation): Likewise.
6099 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6101 * tree-vectorizer.h (vec_info::lookup_def): Declare.
6102 * tree-vectorizer.c (vec_info::lookup_def): New function.
6103 * tree-vect-patterns.c (vect_get_internal_def): Use it.
6104 (vect_widened_op_tree): Likewise.
6105 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
6106 * tree-vect-loop.c (vect_analyze_loop_operations): Likewise.
6107 (vectorizable_reduction): Likewise.
6108 (vect_valid_reduction_input_p): Take a stmt_vec_info instead
6110 (vect_is_slp_reduction): Update calls accordingly. Use
6111 vec_info::lookup_def.
6112 (vect_is_simple_reduction): Likewise
6113 * tree-vect-slp.c (vect_detect_hybrid_slp_1): Use vec_info::lookup_def.
6115 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6117 * tree-vectorizer.h (vec_info::lookup_stmt): Declare.
6118 * tree-vectorizer.c (vec_info::lookup_stmt): New function.
6119 * tree-vect-loop.c (vect_determine_vf_for_stmt): Use it instead
6121 (vect_determine_vectorization_factor, vect_analyze_scalar_cycles_1)
6122 (vect_compute_single_scalar_iteration_cost, vect_analyze_loop_form)
6123 (vect_update_vf_for_slp, vect_analyze_loop_operations)
6124 (vect_is_slp_reduction, vectorizable_induction)
6125 (vect_transform_loop_stmt, vect_transform_loop): Likewise.
6126 * tree-vect-patterns.c (vect_init_pattern_stmt):
6127 (vect_determine_min_output_precision_1, vect_determine_precisions)
6128 (vect_pattern_recog): Likewise.
6129 * tree-vect-stmts.c (vect_analyze_stmt, vect_transform_stmt): Likewise.
6130 * config/powerpcspe/powerpcspe.c (rs6000_density_test): Likewise.
6131 * config/rs6000/rs6000.c (rs6000_density_test): Likewise.
6132 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
6133 (vect_detect_hybrid_slp_1, vect_detect_hybrid_slp_2)
6134 (vect_detect_hybrid_slp): Likewise. Change the walk_stmt_info
6135 info field from a loop to a loop_vec_info.
6137 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6139 * tree-vectorizer.h (stmt_vec_info): Move typedef earlier in file.
6140 (vec_info::add_stmt): Declare.
6141 * tree-vectorizer.c (vec_info::add_stmt): New function.
6142 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Use it.
6143 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Likewise.
6144 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
6145 (vectorizable_induction): Likewise.
6146 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Likewise.
6147 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
6148 (vectorizable_simd_clone_call, vectorizable_store): Likewise.
6149 (vectorizable_load): Likewise.
6150 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
6151 (vect_recog_bool_pattern, vect_recog_mask_conversion_pattern)
6152 (vect_recog_gather_scatter_pattern): Likewise.
6153 (append_pattern_def_seq): Likewise. Remove a check that is
6154 performed by add_stmt itself.
6156 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6158 * tree-vect-loop.c (vectorizable_reduction): Fix an instance in
6159 which make_ssa_name was called with new_stmt before new_stmt
6162 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6164 * tree-vect-loop.c (vect_valid_reduction_input_p): New function,
6166 (vect_is_slp_reduction): ...here...
6167 (vect_is_simple_reduction): ...and here. Remove repetition of tests
6168 that are already known to be false.
6170 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6172 * tree-vectorizer.h (vect_free_slp_instance): Add a final_p parameter.
6173 * tree-vect-slp.c (vect_free_slp_tree): Likewise. Don't update
6174 STMT_VINFO_NUM_SLP_USES when it's true.
6175 (vect_free_slp_instance): Add a final_p parameter and pass it to
6177 (vect_build_slp_tree_2): Update call to vect_free_slp_instance.
6178 (vect_analyze_slp_instance): Likewise.
6179 (vect_slp_analyze_operations): Likewise.
6180 (vect_slp_analyze_bb_1): Likewise.
6181 * tree-vectorizer.c (vec_info): Likewise.
6182 * tree-vect-loop.c (vect_transform_loop): Likewise.
6184 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6186 * tree-vect-loop.c (vectorizable_reduction): Assert that the
6187 function is not called for second and subsequent members of
6190 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
6192 * tree-vect-loop.c (get_initial_def_for_reduction): Move special
6193 cases for nested loops from here to ...
6194 (vect_create_epilog_for_reduction): ...here. Only call
6195 vect_is_simple_use for inner-loop reductions.
6197 2018-07-31 Martin Liska <mliska@suse.cz>
6199 PR gcov-profile/85338
6200 PR gcov-profile/85350
6201 PR gcov-profile/85372
6202 * profile.c (struct location_triplet): New.
6203 (struct location_triplet_hash): Likewise.
6204 (output_location): Do not output a BB that
6205 is already recorded for a line.
6206 (branch_prob): Use streamed_locations.
6208 2018-07-31 Martin Liska <mliska@suse.cz>
6210 PR gcov-profile/85370
6211 * coverage.c (coverage_begin_function): Do not mark target
6212 clones as artificial functions.
6214 2018-07-31 Martin Liska <mliska@suse.cz>
6216 PR gcov-profile/83813
6217 PR gcov-profile/84758
6218 PR gcov-profile/85217
6219 PR gcov-profile/85332
6220 * profile.c (branch_prob): Do not record GOTO expressions
6221 for GIMPLE statements which locations are already streamed.
6223 2018-07-31 Olivier Hainque <hainque@adacore.com>
6225 * gcc.c (handle_spec_function): Accept a soft_matched_part
6226 argument, as do_spec_1. Pass it down to ...
6227 (eval_spec_function): Accept a soft_matched_part argument,
6228 and pass it down to ...
6229 (do_spec_2): Accept a soft_matched_part argument, and pass
6230 it down to do_spec_1.
6231 (do_spec_1): Pass soft_matched_part to handle_spec_function.
6232 (handle_braces): Update call to handle_spec_function.
6233 (driver::set_up_specs): Update calls to do_spec_2.
6234 (compare_debug_dump_opt_spec_function): Likewise.
6235 (compare_debug_self_opt_spec_function): Likewise.
6237 2018-07-31 Olivier Hainque <hainque@adacore.com>
6239 * common.opt (nolibc): New option.
6240 * doc/invoke.texi (Link Options): Document it.
6241 * gcc.c (LINK_GCC_C_SEQUENCE_SPEC): Honor nolibc.
6242 * config/alpha/linux.h: Likewise.
6243 * config/arc/elf.h: Likewise.
6244 * config/arm/uclinux-elf.h: Likewise.
6245 * config/arm/unknown-elf.h: Likewise.
6246 * config/avr/avrlibc.h: Likewise.
6247 * config/bfin/bfin.h: Likewise.
6248 * config/bfin/linux.h: Likewise.
6249 * config/bfin/uclinux.h: Likewise.
6250 * config/darwin.h: Likewise.
6251 * config/darwin10.h: Likewise.
6252 * config/darwin12.h: Likewise.
6253 * config/gnu-user.h: Likewise.
6254 * config/lm32/uclinux-elf.h: Likewise.
6255 * config/pa/pa-hpux11.h: Likewise.
6256 * config/pa/pa64-hpux.h: Likewise.
6257 * config/sparc/sparc.h: Likewise.
6259 2018-07-31 Olivier Hainque <hainque@adacore.com>
6261 * gcc.c (getenv_spec_function): Prepend '/' to value for allowed
6262 undefined variables.
6264 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
6267 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
6270 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
6272 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
6273 terminated string literal.
6275 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
6277 PR rtl-optimization/85160
6278 * combine.c (is_just_move): New function.
6279 (try_combine): Allow combining two instructions into two if neither of
6280 the original instructions was a move.
6282 2018-07-30 Alexander Monakov <amonakov@ispras.ru>
6285 * doc/extend.texi (Global Register Variables): Discourage use of type
6287 (Local Register Variables): Likewise.
6289 2018-07-30 Richard Sandiford <richard.sandiford@arm.com>
6291 PR tree-optimization/86506
6292 * hwint.h (ceil_log2): Resync with hwint.c implementation.
6294 2018-07-30 Ilya Leoshkevich <iii@linux.ibm.com>
6297 * lra-constraints.c (spill_hard_reg_in_range): When selecting the
6298 hard_regno, make sure no insn between `from` and `to` clobbers it.
6300 2018-07-30 Cesar Philippidis <cesar@codesourcery.com>
6301 Tom de Vries <tdevries@suse.de>
6303 * config/nvptx/nvptx.c (PTX_GANG_DEFAULT): Rename to ...
6304 (PTX_DEFAULT_RUNTIME_DIM): ... this.
6305 (nvptx_goacc_validate_dims): Set default worker and gang dims to
6306 PTX_DEFAULT_RUNTIME_DIM.
6307 (nvptx_dim_limit): Ignore GOMP_DIM_WORKER.
6309 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
6311 * config/pa/pa.c (pa_output_addr_vec): Align address table.
6312 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
6313 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
6315 2018-07-27 Michael Meissner <meissner@linux.ibm.com>
6317 * config/rs6000/constraints.md (wG constraint): Delete, no longer
6319 * config/rs6000/predicates.md (p9_fusion_reg_operand): Rename
6320 predicate to reflect toc fusion has been deleted.
6321 (toc_fusion_mem_raw): Delete, no longer used.
6322 (toc_fusion_mem_wrapped): Likewise.
6323 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete toc
6325 * config/rs6000/rs6000-protos.h (fusion_wrap_memory_address):
6326 Delete, no longer used.
6327 * config/rs6000/rs6000.c (struct rs6000_reg_addr): Delete fields
6328 meant to be used for toc fusion.
6329 (rs6000_debug_print_mode): Delete toc fusion debugging.
6330 (rs6000_debug_reg_global): Likewise.
6331 (rs6000_init_hard_regno_mode_ok): Delete setting up fields for toc
6332 fusion and secondary reload support that were never used.
6333 (rs6000_option_override_internal): Delete TOC fusion, that was only
6334 partially defined, and it did not work unless you also used the
6336 (rs6000_legitimate_address_p): Delete TOC fusion support.
6337 (rs6000_opt_masks): Likewise.
6338 (fusion_wrap_memory_address): Delete function, no longer used.
6339 (fusion_split_address); Delete TOC fusion support.
6340 * config/rs6000/rs6000.h (TARGET_TOC_FUSION_INT): Delete, no
6341 longer used with toc fusion being deleted.
6342 (TARGET_TOC_FUSION_FP): Likewise.
6343 * config/rs6000/rs6000.md (UNSPEC_FUSION_ADDIS): Delete TOC fusion
6345 (toc fusion spliter): Delete TOC fusion support.
6346 (toc_fusionload_<mode>): Likewise.
6347 (toc_fusionload_di): Likewise.
6348 (fusion_gpr_load_<mode>): Delete generator function, this insn no
6349 longer needs to be named. Rename predicate to delete TOC fusion.
6350 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
6351 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
6352 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
6353 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
6354 (p9 fusion peephole2s): Rename predicate to delete TOC fusion.
6356 2018-07-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
6358 * doc/extend.texi (Basic PowerPC Built-in Functions Available on
6359 ISA 2.05): Replace __uint128_t with __uint128 and __int128_t with
6360 __int128 in built-in function prototypes.
6361 (PowerPC AltiVec Built-in Functions on ISA 2.07): Likewise.
6362 (PowerPC AltiVec Built-in Functions on ISA 3.0): Likewise.
6364 2018-07-27 Martin Sebor <msebor@redhat.com>
6366 PR tree-optimization/86696
6367 * tree-ssa-strlen.c (get_min_string_length): Handle all integer
6368 types, including enums.
6369 (handle_char_store): Be prepared for the above function to fail.
6371 2018-07-26 Qing Zhao <qing.zhao@oracle.com>
6373 * builtins.c (inline_expand_builtin_string_cmp): Disable inlining
6374 when optimization level is lower than 2 or optimize for size.
6376 2018-07-26 Martin Sebor <msebor@redhat.com>
6378 PR tree-optimization/86043
6379 PR tree-optimization/86042
6380 * tree-ssa-strlen.c (handle_builtin_memcpy): Handle strict overlaps.
6381 (get_string_cst_length): Rename...
6382 (get_min_string_length): ...to this. Add argument.
6383 (handle_char_store): Extend to handle multi-character stores by
6385 * tree.c (initializer_zerop): Use new argument. Handle MEM_REF.
6386 * tree.h (initializer_zerop): Add argument.
6388 2018-07-26 Jakub Jelinek <jakub@redhat.com>
6391 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
6392 declare target to variables if they have always,{to,from,tofrom} map
6395 2018-07-26 Martin Liska <mliska@suse.cz>
6398 * lto-wrapper.c: Add linker_output as prefix
6399 for ltrans_output_file.
6401 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
6403 PR rtl-optimization/85805
6404 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
6405 value for hard registers if that was written in the same mode.
6407 2018-07-26 Martin Liska <mliska@suse.cz>
6409 PR gcov-profile/86536
6410 * gcov.c (format_gcov): Use printf format %.*f directly
6411 and do not handle special values.
6413 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
6415 * common/config/arc/arc-common.c (arc_option_optimization_table):
6416 Update default optimizations for size.
6418 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
6420 * config/arc/arc.md (movsf_insn): Add short instruction selection.
6421 * config/arc/constraints.md (CfZ): New constraint.
6422 * config/arc/fpu.md (addssf3_fpu): Use CfZ constraint.
6423 (subsf3_fpu): Likewise.
6424 (cmpsf_fpu): Likewise.
6425 (cmpsf_fpu_uneq): Likewise.
6427 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
6429 * config/arc/arc.c (compact_memory_operand_p): Check for uncached
6431 (arc_is_uncached_mem_p): uncached applies to both the variable and
6434 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
6436 * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Add additional
6439 2018-07-25 David Malcolm <dmalcolm@redhat.com>
6441 * optinfo-emit-json.cc (class optrecord_json_writer): Convert
6442 field "m_scopes" from vec to auto_vec.
6444 2018-07-25 Martin Liska <mliska@suse.cz>
6446 * config/powerpcspe/powerpcspe-protos.h (rs6000_loop_align): Fix
6449 2018-07-25 Richard Biener <rguenther@suse.de>
6452 * dwarf2out.c (dwarf2out_decl): Do not handle nested functions
6453 special wrt context_die late.
6454 (gen_subprogram_die): Re-use DIEs in local scope.
6456 2018-07-25 Richard Sandiford <richard.sandiford@arm.com>
6458 PR tree-optimization/86644
6459 * hwint.c (ceil_log2): Fix comment. Return 0 for 0.
6461 2018-07-25 Martin Liska <mliska@suse.cz>
6464 * dumpfile.c: And excluded values with TDF_ALL_VALUES.
6465 * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
6467 2018-07-25 Martin Liska <mliska@suse.cz>
6470 * params.def: Explain ASan abbreviation and provide
6471 a documentation link.
6473 2018-07-24 Martin Sebor <msebor@redhat.com>
6475 PR tree-optimization/86622
6476 PR tree-optimization/86532
6477 * builtins.h (string_length): Declare.
6478 * builtins.c (c_strlen): Correct handling of non-constant offsets.
6479 (check_access): Be prepared for non-constant length ranges.
6480 (string_length): Make extern.
6481 * expr.c (string_constant): Only handle the minor non-constant
6482 array index. Use string_constant to compute the length of
6483 a generic string constant.
6485 2018-07-24 Richard Sandiford <richard.sandiford@arm.com>
6487 PR tree-optimization/86618
6488 * tree-vect-stmts.c (vectorizable_call): Don't take the address
6489 of LOOP_VINFO_MASKS (loop_vinfo) when loop_vinfo is null.
6491 2018-07-24 David Malcolm <dmalcolm@redhat.com>
6493 PR tree-optimization/86636
6494 * json.cc (json::object::set): Fix comment. Add assertions.
6495 (json::array::append): Move here from json.h. Add comment and an
6497 (json::string::string): Likewise.
6498 * json.h (json::array::append): Move to json.cc.
6499 (json::string::string): Likewise.
6500 * optinfo-emit-json.cc
6501 (optrecord_json_writer::impl_location_to_json): Assert that we
6502 aren't attempting to write out UNKNOWN_LOCATION, or an ad-hoc
6503 wrapper around it. Expand the location once, rather than three
6505 (optrecord_json_writer::inlining_chain_to_json): Fix the check for
6506 UNKNOWN_LOCATION, to use LOCATION_LOCUS to look through ad-hoc
6508 (optrecord_json_writer::optinfo_to_json): Likewise, in four
6509 places. Fix some overlong lines.
6511 2018-07-24 Matthew Malcomson <matthew.malcomson@arm.com>
6513 * config/aarch64/aarch64-simd.md
6514 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>): Split into...
6515 (aarch64_<ANY_EXTEND:su>subw<mode>): ... This...
6516 (aarch64_<ANY_EXTEND:su>addw<mode>): ... And this.
6517 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>_internal): Split into...
6518 (aarch64_<ANY_EXTEND:su>subw<mode>_internal): ... This...
6519 (aarch64_<ANY_EXTEND:su>addw<mode>_internal): ... And this.
6520 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>_internal): Split into...
6521 (aarch64_<ANY_EXTEND:su>subw2<mode>_internal): ... This...
6522 (aarch64_<ANY_EXTEND:su>addw2<mode>_internal): ... And this.
6524 2018-07-24 Jakub Jelinek <jakub@redhat.com>
6527 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
6528 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
6529 and abs_d == d, do the power of two handling if profitable.
6531 2018-07-24 Richard Biener <rguenther@suse.de>
6533 * match.pd: Add BIT_FIELD_REF canonicalizations.
6535 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
6538 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
6540 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
6542 * gimple-fold.c (gimple_fold_builtin_printf): Don't create a not NUL
6543 terminated STRING_CST object.
6545 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
6547 hsa-dump.c (dump_hsa_symbol): Avoid out of scope access to buf.
6549 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
6551 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Adjust.
6552 * config/rs6000/rs6000-protos.h (rs6000_split_v4si_init): Delete.
6553 * config/rs6000/rs6000.c (rs6000_expand_vector_init): Always force
6554 the elements into a register.
6555 (rs6000_split_v4si_init_di_reg): Delete.
6556 (rs6000_split_v4si_init): Delete.
6557 * config/rs6000/vsx.md (unspec): Delete UNSPEC_VSX_VEC_INIT.
6558 (vsx_init_v4si): Rewrite as a define_expand.
6560 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
6562 * config/rs6000/rs6000.md (splitters for rldimi and rlwimi with the
6563 zero_extend argument from memory): New.
6565 2018-07-22 Martin Sebor <msebor@redhat.com>
6568 * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Avoid
6569 diagnosing calls with unknown arguments unless -Walloca-larger-than
6570 is restricted to less than PTRDIFF_MAX bytes.
6572 2018-07-22 Gerald Pfeifer <gerald@pfeifer.com>
6574 * doc/gcov.texi (Invoking Gcov): Editorial changes.
6576 2018-07-20 David Malcolm <dmalcolm@redhat.com>
6578 * pretty-print.c (text_info::set_location): Remove redundant
6579 "line_table" parameter from call to rich_location::set_range.
6581 2018-07-20 Martin Sebor <msebor@redhat.com>
6584 * builtins.c (expand_builtin_alloca): Adjust.
6585 * calls.c (alloc_max_size): Simplify.
6586 * cgraphunit.c (cgraph_node::expand): Adjust.
6587 * common.opt (larger_than_size, warn_frame_larger_than): Remove
6589 (frame_larger_than_size): Same.
6590 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Change options
6591 to take a HOST_WIDE_INT argument and accept a byte-size suffix.
6593 * doc/invoke.texi (GCC Command Options): Document option arguments.
6594 Explain byte-size arguments and suffixes.
6595 (-Wvla-larger-than, -Wno-alloc-size-larger-than): Update.
6596 (-Wno-alloca-larger-than, -Wno-vla-larger-than): Same.
6597 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Same.
6598 * doc/options.texi (UInteger): Expand.
6599 (Host_Wide_Int, ByteSize): Document new properties.
6600 * final.c (final_start_function_1): Include sizes in an error message.
6601 * function.c (frame_offset_overflow): Same.
6602 * gimple-ssa-warn-alloca.c (pass_walloca::gate): Adjust.
6603 (alloca_call_type_by_arg): Change function argument to HOST_WIDE_INT.
6604 Diagnose unbounded alloca calls only for limits of less than
6606 (alloca_call_type): Adjust. Diagnose possibly out-of-bounds alloca
6607 calls and VLA size only for limits of less than PTRDIFF_MAX. Same
6609 (pass_walloca::execute): Adjust. Diagnose alloca calls in loops
6610 only for limits of less than PTRDIFF_MAX.
6611 * langhooks-def.h (lhd_handle_option): Change function argument
6613 * langhooks.c (lhd_handle_option): Same.
6614 * langhooks.h (handle_option): Same.
6615 * opt-functions.awk (switch_bit_fields): Handle Host_Wide_Int and
6617 (var_type, var_type_struct): Same.
6618 (var_set): Handle ByteSize flag.
6619 * optc-gen.awk: Add comments to output to ease debugging. Make
6620 use of HOST_WIDE_INT where appropriate.
6621 * opts-gen-save.awk: Use %lx to format unsigned long.
6622 * opth-gen.awk: Change function argument to HOST_WIDE_INT.
6623 * opts-common.c (integral_argument): Return HOST_WIDE_INT and add
6624 arguments. Parse bytes-size suffixes.
6625 (enum_arg_to_value): Change function argument to HOST_WIDE_INT.
6626 (enum_value_to_arg): Same.
6627 (decode_cmdline_option): Handle cl_host_wide_int. Adjust.
6628 (handle_option): Adjust.
6629 (generate_option): Change function argument to HOST_WIDE_INT.
6630 (cmdline_handle_error): Adjust.
6631 (read_cmdline_option): Change function argument to HOST_WIDE_INT.
6632 (set_option): Change function argument to HOST_WIDE_INT.
6633 (option_enabled): Handle cl_host_wide_int.
6634 (get_option_state): Handle CLVC_SIZE.
6635 (control_warning_option): Same.
6636 * opts.c (common_handle_option): Change function argument to
6637 HOST_WIDE_INT. Remove handling of OPT_Walloca_larger_than_ and
6638 OPT_Wvla_larger_than_.
6639 * opts.h (enum cl_var_type): Add an enumerator.
6640 * stor-layout.c (layout_decl): Print a more meaningful warning.
6641 * toplev.c (output_stack_usage): Adjust.
6643 2018-07-20 Qing Zhao <qing.zhao@oracle.com>
6645 * builtins.c (expand_builtin_memcmp): Delete the last parameter for
6646 call to inline_expand_builtin_string_cmp.
6647 (expand_builtin_strcmp): Likewise.
6648 (expand_builtin_strncmp): Likewise.
6649 (inline_string_cmp): Delete the last parameter, change char_type_node
6650 to unsigned_char_type_node for strcmp/strncmp, add conversions to the
6652 (inline_expand_builtin_string_cmp): Delete the last parameter, give up
6653 the inlining expansion on target where the type of the call has same or
6654 narrower precision than unsigned char.
6656 2018-07-20 David Malcolm <dmalcolm@redhat.com>
6658 * Makefile.in (OBJS): Add json.o and optinfo-emit-json.o.
6659 (CFLAGS-optinfo-emit-json.o): Define TARGET_NAME.
6660 * common.opt (fsave-optimization-record): New option.
6661 * coretypes.h (struct kv_pair): Move here from dumpfile.c.
6662 * doc/invoke.texi (-fsave-optimization-record): New option.
6663 * dumpfile.c: Include "optinfo-emit-json.h".
6664 (struct kv_pair): Move to coretypes.h.
6665 (optgroup_options): Make non-static.
6666 (dump_context::end_scope): Call
6667 optimization_records_maybe_pop_dump_scope.
6668 * dumpfile.h (optgroup_options): New decl.
6669 * json.cc: New file.
6671 * optinfo-emit-json.cc: New file.
6672 * optinfo-emit-json.h: New file.
6673 * optinfo.cc: Include "optinfo-emit-json.h".
6674 (optinfo::emit): Call optimization_records_maybe_record_optinfo.
6675 (optinfo_enabled_p): Check optimization_records_enabled_p.
6676 (optinfo_wants_inlining_info_p): Likewise.
6677 * optinfo.h: Update comment.
6678 * profile-count.c (profile_quality_as_string): New function.
6679 * profile-count.h (profile_quality_as_string): New decl.
6680 (profile_count::quality): New accessor.
6681 * selftest-run-tests.c (selftest::run_tests): Call json_cc_tests
6682 and optinfo_emit_json_cc_tests.
6683 * selftest.h (selftest::json_cc_tests): New decl.
6684 (selftest::optinfo_emit_json_cc_tests): New decl.
6685 * toplev.c: Include "optinfo-emit-json.h".
6686 (compile_file): Call optimization_records_finish.
6687 (do_compile): Call optimization_records_start.
6688 * tree-ssa-live.c: Include optinfo.h.
6689 (remove_unused_scope_block_p): Retain inlining information if
6690 optinfo_wants_inlining_info_p returns true.
6692 2018-07-20 Richard Biener <rguenther@suse.de>
6695 * dwarf2out.c (dwarf2out_die_ref_for_decl): Test in_lto_p
6696 to cover -flto-partition=none.
6698 2018-07-20 Martin Liska <mliska@suse.cz>
6700 * tree.h (DECL_LOCATION_RANGE): Remove unused macro.
6701 (get_decl_source_range): Remove unused function.
6703 2018-07-20 Richard Biener <rguenther@suse.de>
6705 * tree-ssa-sccvn.h (struct vn_nary_op_s): Add next member.
6706 (struct vn_phi_s): Likewise.
6707 (struct vn_reference_s): Likewise.
6708 * tree-ssa-sccvn.c (vn_nary_op_hasher::equal): Add shortcut
6709 for searching the slot of an entry known to be in the hash itself.
6710 (vn_phi_hasher::equal): Likewise.
6711 (vn_reference_hasher::equal): Likewise.
6712 (last_inserted_ref, last_inserted_phi, last_inserted_nary): New
6714 (optimistic_info, current_info): Remove, keeping only valid_info.
6715 (vn_reference_lookup_1): Remove fallback lookup.
6716 (vn_reference_lookup_2): Likewise.
6717 (vn_nary_op_lookup_1): Likewise.
6718 (vn_phi_lookup): Likewise.
6719 (vn_nary_build_or_lookup_1): Make sure to not chain the built
6721 (vn_reference_insert): Adjust, chain the inserted hash element
6722 at last_inserted_ref.
6723 (vn_reference_insert_pieces): Likewise.
6724 (visit_reference_op_call): Likewise.
6725 (vn_nary_op_insert_into): Chain the inserted hash element at
6727 (vn_nary_op_insert_pieces): Adjust.
6728 (vn_nary_op_insert): Likewise.
6729 (vn_nary_op_insert_stmt): Likewise.
6730 (vn_phi_insert): Adjust, chain the inserted hash element at
6732 (process_scc): Remove clearing and copying the optimistic
6733 table. Instead remove elements inserted during an optimistic
6734 iteration from the single table we maintain.
6735 (init_scc_vn): Adjust.
6736 (free_scc_vn): Likewise.
6737 (sccvn_dom_walker::record_cond): Likewise.
6738 (sccvn_dom_walker::after_dom_children): Likewise.
6740 2018-07-19 Martin Sebor <msebor@redhat.com>
6742 PR tree-optimization/84047
6743 PR tree-optimization/83776
6744 * tree-vrp.c (vrp_prop::check_mem_ref): New function.
6745 (check_array_bounds): Call it.
6747 2018-07-19 Martin Sebor <msebor@redhat.com>
6749 * align.h (align_flags): Use member initialization.
6751 2018-07-19 David Malcolm <dmalcolm@redhat.com>
6753 * Makefile.in (OBJS): Add optinfo.o.
6754 * coretypes.h (class symtab_node): New forward decl.
6755 (struct cgraph_node): New forward decl.
6756 (class varpool_node): New forward decl.
6757 * dump-context.h: New file.
6758 * dumpfile.c: Include "optinfo.h", "dump-context.h", "cgraph.h",
6760 (refresh_dumps_are_enabled): Use optinfo_enabled_p.
6761 (set_dump_file): Call dumpfile_ensure_any_optinfo_are_flushed.
6762 (set_alt_dump_file): Likewise.
6763 (dump_context::~dump_context): New dtor.
6764 (dump_gimple_stmt): Move implementation to...
6765 (dump_context::dump_gimple_stmt): ...this new member function.
6766 Add the stmt to any pending optinfo, creating one if need be.
6767 (dump_gimple_stmt_loc): Move implementation to...
6768 (dump_context::dump_gimple_stmt_loc): ...this new member function.
6769 Start a new optinfo and add the stmt to it.
6770 (dump_gimple_expr): Move implementation to...
6771 (dump_context::dump_gimple_expr): ...this new member function.
6772 Add the stmt to any pending optinfo, creating one if need be.
6773 (dump_gimple_expr_loc): Move implementation to...
6774 (dump_context::dump_gimple_expr_loc): ...this new member function.
6775 Start a new optinfo and add the stmt to it.
6776 (dump_generic_expr): Move implementation to...
6777 (dump_context::dump_generic_expr): ...this new member function.
6778 Add the tree to any pending optinfo, creating one if need be.
6779 (dump_generic_expr_loc): Move implementation to...
6780 (dump_context::dump_generic_expr_loc): ...this new member
6781 function. Add the tree to any pending optinfo, creating one if
6783 (dump_printf): Move implementation to...
6784 (dump_context::dump_printf_va): ...this new member function. Add
6785 the text to any pending optinfo, creating one if need be.
6786 (dump_printf_loc): Move implementation to...
6787 (dump_context::dump_printf_loc_va): ...this new member function.
6788 Start a new optinfo and add the stmt to it.
6789 (dump_dec): Move implementation to...
6790 (dump_context::dump_dec): ...this new member function. Add the
6791 value to any pending optinfo, creating one if need be.
6792 (dump_context::dump_symtab_node): New member function.
6793 (dump_context::get_scope_depth): New member function.
6794 (dump_context::begin_scope): New member function.
6795 (dump_context::end_scope): New member function.
6796 (dump_context::ensure_pending_optinfo): New member function.
6797 (dump_context::begin_next_optinfo): New member function.
6798 (dump_context::end_any_optinfo): New member function.
6799 (dump_context::s_current): New global.
6800 (dump_context::s_default): New global.
6801 (dump_scope_depth): Delete global.
6802 (dumpfile_ensure_any_optinfo_are_flushed): New function.
6803 (dump_symtab_node): New function.
6804 (get_dump_scope_depth): Reimplement in terms of dump_context.
6805 (dump_begin_scope): Likewise.
6806 (dump_end_scope): Likewise.
6807 (selftest::temp_dump_context::temp_dump_context): New ctor.
6808 (selftest::temp_dump_context::~temp_dump_context): New dtor.
6809 (selftest::verify_item): New function.
6810 (ASSERT_IS_TEXT): New macro.
6811 (ASSERT_IS_TREE): New macro.
6812 (ASSERT_IS_GIMPLE): New macro.
6813 (selftest::test_capture_of_dump_calls): New test.
6814 (selftest::dumpfile_c_tests): Call it.
6815 * dumpfile.h (dump_printf, dump_printf_loc, dump_basic_block)
6816 (dump_generic_expr_loc, dump_generic_expr, dump_gimple_stmt_loc)
6817 (dump_gimple_stmt, dump_dec): Gather these related decls and add a
6818 descriptive comment.
6819 (dump_function, print_combine_total_stats, enable_rtl_dump_file)
6820 (dump_node, dump_bb): Move these unrelated decls.
6821 (class dump_manager): Add leading comment.
6822 * optinfo.cc: New file.
6823 * optinfo.h: New file.
6825 2018-07-19 Michael Collison <michael.collison@arm.com>
6826 Richard Henderson <rth@redhat.com>
6828 * config/aarch64/aarch64.md (subv<GPI>4, usubv<GPI>4): New patterns.
6829 (subti): Handle op1 zero.
6830 (subvti4, usub4ti4): New.
6831 (*sub<GPI>3_compare1_imm): New.
6832 (sub<GPI>3_carryinCV): New.
6833 (*sub<GPI>3_carryinCV_z1_z2, *sub<GPI>3_carryinCV_z1): New.
6834 (*sub<GPI>3_carryinCV_z2, *sub<GPI>3_carryinCV): New.
6836 2018-07-19 Michael Collison <michael.collison@arm.com>
6837 Richard Henderson <rth@redhat.com>
6839 * config/aarch64/aarch64.md: (addv<GPI>4, uaddv<GPI>4): New.
6840 (addti3): Create simpler code if low part is already known to be 0.
6841 (addvti4, uaddvti4): New.
6842 (*add<GPI>3_compareC_cconly_imm): New.
6843 (*add<GPI>3_compareC_cconly): New.
6844 (*add<GPI>3_compareC_imm): New.
6845 (*add<GPI>3_compareC): Rename from add<GPI>3_compare1; do not
6846 handle constants within this pattern..
6847 (*add<GPI>3_compareV_cconly_imm): New.
6848 (*add<GPI>3_compareV_cconly): New.
6849 (*add<GPI>3_compareV_imm): New.
6850 (add<GPI>3_compareV): New.
6851 (add<GPI>3_carryinC, add<GPI>3_carryinV): New.
6852 (*add<GPI>3_carryinC_zero, *add<GPI>3_carryinV_zero): New.
6853 (*add<GPI>3_carryinC, *add<GPI>3_carryinV): New.
6854 ((*add<GPI>3_compareC_cconly_imm): Replace 'ne' operator
6855 with 'comparison' operator.
6856 (*add<GPI>3_compareV_cconly_imm): Ditto.
6857 (*add<GPI>3_compareV_cconly): Ditto.
6858 (*add<GPI>3_compareV_imm): Ditto.
6859 (add<GPI>3_compareV): Ditto.
6860 (add<mode>3_carryinC): Ditto.
6861 (*add<mode>3_carryinC_zero): Ditto.
6862 (*add<mode>3_carryinC): Ditto.
6863 (add<mode>3_carryinV): Ditto.
6864 (*add<mode>3_carryinV_zero): Ditto.
6865 (*add<mode>3_carryinV): Ditto.
6867 2018-07-19 Michael Collison <michael.collison@arm.com>
6868 Richard Henderson <rth@redhat.com>
6870 * config/aarch64/aarch64-modes.def (CC_V): New.
6871 * config/aarch64/aarch64-protos.h
6872 (aarch64_addti_scratch_regs): Declare
6873 (aarch64_subvti_scratch_regs): Declare.
6874 (aarch64_expand_subvti): Declare.
6875 (aarch64_gen_unlikely_cbranch): Declare
6876 * config/aarch64/aarch64.c (aarch64_select_cc_mode): Test
6877 for signed overflow using CC_Vmode.
6878 (aarch64_get_condition_code_1): Handle CC_Vmode.
6879 (aarch64_gen_unlikely_cbranch): New function.
6880 (aarch64_addti_scratch_regs): New function.
6881 (aarch64_subvti_scratch_regs): New function.
6882 (aarch64_expand_subvti): New function.
6884 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
6886 * config/aarch64/aarch64-option-extensions.def: New entry for profile
6888 * config/aarch64/aarch64.h (AARCH64_FL_PROFILE): New.
6889 * doc/invoke.texi (aarch64-feature-modifiers): New entry for profile
6892 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
6895 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
6896 address check not strict.
6898 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
6900 * config/aarch64/aarch64-simd.md (aarch64_simd_mov<VQ:mode>): Replace
6902 (store_pair_lanes<mode>): Likewise.
6903 * config/aarch64/aarch64-protos.h (aarch64_addr_query_type): Add new
6904 enum value 'ADDR_QUERY_LDP_STP_N'.
6905 * config/aarch64/aarch64.c (aarch64_addr_query_type): Likewise.
6906 (aarch64_print_address_internal): Add declaration.
6907 (aarch64_print_ldpstp_address): Remove.
6908 (aarch64_classify_address): Adapt mode for 'ADDR_QUERY_LDP_STP_N'.
6909 (aarch64_print_operand): Change printing of 'y'.
6910 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Use
6911 new enum value 'ADDR_QUERY_LDP_STP_N', don't hardcode mode and use
6912 'true' rather than '1'.
6913 * config/aarch64/constraints.md (Uml): Likewise.
6914 (Uml): Rename to Umn.
6917 2018-07-19 Richard Biener <rguenther@suse.de>
6919 * tree-ssa-sccvn.h (struct vn_phi_s): Make phiargs member
6921 * tree-ssa-sccvn.c: Remove alloc-pool.h use.
6922 (vn_phi_hasher): Derive from nofree_ptr_hash and remove remove method.
6923 (vn_reference_hasher): Likewise.
6924 (struct vn_tables_s): Remove obstack and alloc-pool members.
6925 (vn_tables_obstack, vn_tables_insert_obstack): New global obstacks.
6926 (vn_nary_build_or_lookup_1): Manually build in vn_tables_insert_obstack.
6927 (vn_reference_insert): Allocate from obstack instead of from alloc-pool.
6928 (vn_reference_insert_pieces): Likewise.
6929 (alloc_vn_nary_op_noinit): Adjust.
6930 (vn_nary_op_insert_stmt): Allocate phiargs in-place.
6931 (vn_phi_eq): Adjust.
6932 (shared_lookup_phiargs): Remove.
6933 (vn_phi_lookup): Allocate temporary vn_phi_s on the stack.
6934 (vn_phi_insert): Allocate from obstack instead of from alloc-pool.
6935 (visit_reference_op_call): Likewise.
6936 (copy_nary, copy_phi, copy_reference): Remove.
6937 (process_scc): Rewind the obstack when iterating. Do not
6938 copy the elements to valid_info but just move them from one
6939 hashtable to the other.
6940 (allocate_vn_table): Adjust.
6941 (free_vn_table): Likewise.
6942 (init_scc_vn): Likewise.
6943 (free_scc_vn): Likewise.
6945 2018-07-19 H.J. Lu <hongjiu.lu@intel.com>
6948 * config/i386/i386.c (rest_of_insert_endbranch): Lookup
6949 indirect_return as function type attribute.
6950 (ix86_attribute_table): Change indirect_return to function
6952 * doc/extend.texi: Update indirect_return attribute.
6954 2018-07-19 Aldy Hernandez <aldyh@redhat.com>
6956 * wide-int.h (widest2_int): New.
6957 * gimple-fold.c (arith_overflowed_p): Use it.
6958 * tree.h (widest2_int_cst): New.
6959 * tree-vrp.c (wide_int_binop_overflow): Rename from
6960 vrp_int_const_binop.
6961 Rewrite to work on trees.
6962 (extract_range_from_multiplicative_op_1): Abstract code to...
6963 (wide_int_range_min_max): ...here.
6964 (wide_int_range_cross_product): ...and here.
6965 (extract_range_from_binary_expr_1): Abstract overflow code to...
6966 (wide_int_range_mult_wrapping): ...here.
6967 * tree-vrp.h (wide_int_range_cross_product): New.
6968 (wide_int_range_mult_wrapping): New.
6970 2018-07-19 Andrew Senkevich <andrew.senkevich@intel.com>
6971 Julia Koval <julia.koval@intel.com>
6973 * config/i386/x86-tune-costs.h (skylake_memcpy,
6974 skylake_memset): Replace rep_prefix with unrolling for size 512.
6976 2018-07-18 Kugan Vivekanandarajah <kuganv@linaro.org>
6979 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): Handle
6980 comparision with EQ_EXPR in last stmt.
6982 2018-07-18 Kelvin Nilsen <kelvin@gcc.gnu.org>
6984 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Rename
6985 this subsection to "PowerPC AltiVec/VSX Built-in Functions".
6986 (PowerPC AltiVec/VSX Built-in Functions): New name for subsection
6987 previously known as "PowerPC AltiVec Built-in Functions". Move
6988 some material to new subsubsections "PowerPC AltiVec Built-in
6989 Functions on ISA 2.06" and "PowerPC AltiVec Built-in Functions on
6991 (PowerPC Altivec Built-in Functions on ISA 2.05): New subsubsection.
6992 (PowerPC Altivec Built-in Functions on ISA 2.06): Likewise.
6993 (PowerPC Altivec Built-in Functions on ISA 2.07): Likewise.
6994 (PowerPC Altivec Built-in Functions on ISA 3.0): Likewise.
6996 2018-07-18 Richard Biener <rguenther@suse.de>
6998 PR tree-optimization/86557
6999 * tree-vect-patterns.c (vect_recog_divmod_pattern): Also handle
7002 2018-07-18 Ilya Leoshkevich <iii@linux.ibm.com>
7004 * config/s390/s390.c (s390_function_profiler): Generate CFI.
7006 2018-07-17 Jeff Law <law@redhat.com>
7008 * config/arm/arm.c (get_label_padding): Update for recent
7009 changes to label_to_alignment.
7011 PR tree-optimization/86010
7012 * tree-ssa-dse.c (compute_trims): Fix typo/thinko.
7014 * config/mips/mips.c (vr4130_align_insns): Update for recent
7015 changes to label_to_alignment.
7017 * config/frv/frv.c (frv_label_align): Update for recent changes
7018 to label_to_alignment.
7020 * config/nios2/nios2.c (nios2_label_align): Update for recent
7021 changes which dropped ALIGN_LABELS_LOG.
7023 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
7025 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
7026 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
7028 2018-07-17 Claudiu Zissulescu <claziss@synopsys.com>
7030 * config/arc/arc.c (arc_label_align): Use align_labels instead of
7031 deprecated align_labels_log.
7033 2018-07-17 Richard Biener <rguenther@suse.de>
7036 * dwarf2out.c (init_sections_and_labels): Always generate
7037 a debug_line_str_section for early LTO debug.
7038 (dwarf2out_finish): Reset debug_line_str_hash output early.
7039 Bump counter for extra dwarf5 .debug_loc labels to not conflict
7041 (dwarf2out_early_finish): Output debug_line_str.
7043 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
7045 * config/s390/s390.c (preferred_la_operand_p): Do not use LA with
7046 index register on z196 or later.
7048 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
7050 * config/s390/s390.c (s390_default_align): Set default function
7052 (s390_override_options_after_change): Call s390_default align.
7053 (s390_option_override_internal): Call s390_default_align.
7054 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define.
7056 2018-07-17 Jakub Jelinek <jakub@redhat.com>
7059 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
7060 to _looptemp_ clauses, other than the first two.
7062 2018-07-17 Martin Liska <mliska@suse.cz>
7064 * opts.c: Do not enable OPT_falign_* for -Os.
7066 2018-07-17 Martin Liska <mliska@suse.cz>
7068 * align.h (MAX_CODE_ALIGN): New.
7069 (MAX_CODE_ALIGN_VALUE): New.
7070 * common/config/i386/i386-common.c (ix86_handle_option):
7071 (MAX_CODE_ALIGN): Moved to align.h.
7072 * final.c (MAX_CODE_ALIGN): Likewise.
7073 * opts.c (parse_and_check_align_values):
7074 (MAX_CODE_ALIGN): Likewise.
7075 (MAX_CODE_ALIGN_VALUE): Likewise.
7077 2018-07-17 Martin Liska <mliska@suse.cz>
7079 * config/i386/att.h (ASM_OUTPUT_ALIGN): Fix spacing
7080 in order to fulfil coding style.
7081 * config/i386/cygming.h (ASM_OUTPUT_ALIGN): Likewise.
7082 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
7083 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
7084 * config/iq2000/iq2000.h (ASM_OUTPUT_ALIGN): Likewise.
7085 * config/pa/pa.h (ASM_OUTPUT_ALIGN): Likewise.
7086 * config/sparc/sol2.h (ASM_OUTPUT_ALIGN_WITH_NOP): Likewise.
7087 * config/sparc/sparc.h (ASM_OUTPUT_ALIGN): Likewise.
7088 * config/visium/visium.h (ASM_OUTPUT_ALIGN): Likewise.
7089 (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
7091 2018-07-17 Martin Liska <mliska@suse.cz>
7093 * align.h: New file.
7094 * config/alpha/alpha.c (alpha_align_insns_1): Use align_functions
7096 * config/i386/i386.c (ix86_avoid_jump_mispredicts): Use new return type
7097 align_flags of label_to_alignment.
7098 * config/m32r/m32r.h (LOOP_ALIGN): Wrap returned values into
7100 * config/m68k/m68k.c: Do not use removed align_labels_value and
7102 * config/nds32/nds32.h (JUMP_ALIGN): Wrap result into align_flags class.
7103 (LOOP_ALIGN): Likewise.
7104 (LABEL_ALIGN): Likewise.
7105 * config/powerpcspe/powerpcspe.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
7106 Remove not used macro.
7107 (rs6000_loop_align): Change return type to align_flags.
7108 (rs6000_loop_align_max_skip): Remove.
7109 * config/rs6000/rs6000-protos.h (rs6000_loop_align):
7110 Change return type to align_flags.
7111 * config/rs6000/rs6000.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
7112 Remove not used macro.
7113 (rs6000_loop_align): Change return type to align_flags.
7114 (rs6000_loop_align_max_skip): Remove.
7115 * config/rx/rx.h (JUMP_ALIGN): Wrap integer values
7116 * config/rx/rx-protos.h (rx_align_for_label): Make it
7118 * config/rx/rx.c (rx_align_for_label): Change return type
7120 (rx_max_skip_for_label): Remove TARGET_ASM_*_ALIGN_MAX_SKIP
7122 into align_flags class.
7123 (LABEL_ALIGN): Likewise.
7124 (LOOP_ALIGN): Likewise.
7125 * config/s390/s390.c (s390_label_align): Use align_flags
7127 (s390_asm_output_function_label): Likewise.
7128 * config/sh/sh.c (sh_override_options_after_change):
7129 Use align_flags class directly without macros.
7130 (find_barrier): Likewise.
7131 (barrier_align): Likewise.
7132 (sh_loop_align): Likewise.
7133 * config/spu/spu.c (spu_option_override):
7134 Use align_flags_tuple::get_value instead of removed macros.
7135 (spu_sched_init): Likewise.
7136 * config/spu/spu.h (GTY): Likewise.
7137 * config/visium/visium.c (visium_option_override):
7138 Set "8" as default secondary alignment.
7139 * config/visium/visium.h (SUBALIGN_LOG): Define to 3
7140 in order to guarantee secondary alignment of 8.
7141 * coretypes.h: Include align.h header file.
7142 * doc/tm.texi: Remove TARGET_ASM_JUMP_ALIGN_MAX_SKIP,
7143 TARGET_ASM_LOOP_ALIGN_MAX_SKIP, TARGET_ASM_LABEL_ALIGN_MAX_SKIP
7144 and TARGET_ASM_LABEL_ALIGN_AFTER_BARRIER_MAX_SKIP macros.
7145 * doc/tm.texi.in: Likewise.
7146 * final.c (struct label_alignment): Remove not used structure.
7147 (LABEL_ALIGN): Change type to align_flags.
7148 (LOOP_ALIGN): Likewise.
7149 (JUMP_ALIGN): Likewise.
7150 (default_loop_align_max_skip): Remove.
7151 (default_label_align_max_skip): Likewise.
7152 (default_jump_align_max_skip): Likewise.
7153 (default_label_align_after_barrier_max_skip):
7154 (LABEL_TO_ALIGNMENT): Change to access label_align vector.
7155 (LABEL_TO_MAX_SKIP): Remove.
7156 (label_to_alignment): Return align_flags type instead of integer.
7157 (label_to_max_skip): Remove.
7158 (align_fuzz): Use align_flags type.
7159 (compute_alignments): Use align_flags type and use align_flags::max
7160 to combine multiple alignments.
7161 (grow_label_align): Grow vec instead of C array.
7162 (update_alignments): Assign just LABEL_TO_ALIGNMENT.
7163 (shorten_branches): Use align_flags type and use align_flags::max
7164 to combine multiple alignments.
7165 (final_scan_insn_1): Remove usage of secondary alignment that comes
7166 from label alignment, but instead use proper secondary alignment
7167 which is computed in grow_label_align.
7168 * flags.h (struct align_flags_tuple): Move to align.h.
7169 (struct align_flags): Likewise.
7170 (state_align_loops): Rename to align_loops.
7171 (state_align_jumps): Rename to align_jumps.
7172 (state_align_labels): Rename to align_labels.
7173 (state_align_functions): Rename to align_functions.
7174 (align_loops_log): Remove.
7175 (align_jumps_log): Remove.
7176 (align_labels_log): Remove.
7177 (align_functions_log): Remove.
7178 (align_loops_max_skip): Remove.
7179 (align_jumps_max_skip): Remove.
7180 (align_labels_max_skip): Remove.
7181 (align_functions_max_skip): Remove.
7182 (align_loops_value): Remove.
7183 (align_jumps_value): Remove.
7184 (align_labels_value): Remove.
7185 (align_functions_value): Remove.
7186 * output.h (label_to_alignment): Change return type to align_flags.
7187 (label_to_max_skip): Remove.
7188 * target.def: Remove loop_align_max_skip, label_align_max_skip,
7189 jump_align_max_skip macros.
7190 * targhooks.h (default_loop_align_max_skip): Remove.
7191 (default_label_align_max_skip): Likewise.
7192 (default_jump_align_max_skip): Likewise.
7193 (default_label_align_after_barrier_max_skip): Remove.
7194 * toplev.c (read_log_maxskip): Use ::normalize function.
7195 (parse_N_M): Remove not used argument and also call ::normalize.
7196 (parse_alignment_opts): Do not pass unused arguments.
7197 * varasm.c (assemble_start_function): Use directly align_functions
7198 instead of removed macros.
7199 * system.h: Do not poison removed macros.
7201 2018-07-17 Jakub Jelinek <jakub@redhat.com>
7204 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
7205 and cond temporaries don't have reference type if iterator has
7206 pointer type. For init use &for_pre_body instead of pre_p if
7207 for_pre_body is non-empty.
7209 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
7211 * config/rs6000/rs6000.md (trunc<mode>sf2): Expand truncates of
7212 double-double modes to SFmode directly directly.
7213 (trunc<mode>sf2_fprs): Delete.
7215 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
7217 * config/rs6000/rs6000.c (init_float128_ibm): Use the correct names
7218 for conversions between IFmode and the decimal floating point modes.
7219 (init_float128_ieee): Use the correct names for conversions between
7220 KFmode and the decimal floating point modes.
7222 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
7224 * config/rs6000/rs6000.c (init_float128_ibm): Use more correct names
7225 for the conversions between TDmode and IFmode.
7226 (init_float128_ieee): Use more correct names for the conversions
7227 between TDmode and KFmode.
7229 2018-07-16 Jakub Jelinek <jakub@redhat.com>
7231 PR tree-optimization/86526
7232 * builtins.c (expand_builtin_memcmp): Formatting fixes.
7233 (inline_expand_builtin_string_cmp): Likewise.
7234 (inline_string_cmp): Likewise. Use c_readstr instead of
7235 builtin_memcpy_read_str. Add unit_mode temporary.
7237 2018-07-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
7240 * builtins.c (check_access): Bail out if range[0] is no INTEGER_CST.
7241 * expr.c (string_constant): Fix the element size of ARRAY_TYPE.
7243 2018-07-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
7245 * doc/extend.texi (PowerPC AltiVec Built-in Functions):
7246 Alphabetize prototypes of built-in functions, separating out
7247 built-in functions that are listed in this section but should be
7248 described elsewhere.
7250 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
7253 * expmed.c (emit_store_flag): Do not emit setcc followed by a
7254 conditional move when trapping comparison was split to a
7255 non-trapping one (and vice versa).
7257 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
7259 * config/s390/s390.c (s390_function_profiler): Generate nops
7260 instead of profiler call sequences.
7261 * config/s390/s390.opt: Add the new option.
7263 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
7265 * config/s390/s390.c (s390_function_profiler): Generate
7266 __mcount_loc section.
7267 * config/s390/s390.opt: Add the new option.
7269 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
7271 * common.opt: Add the new warning.
7272 * config/s390/s390.c (s390_function_profiler): Emit "brasl
7273 %r0,__fentry__" when -mfentry is specified.
7274 (s390_option_override_internal): Disallow -mfentry for 31-bit
7276 * config/s390/s390.opt: Add the new option.
7278 2018-07-16 Richard Biener <rguenther@suse.de>
7281 * dwarf2out.c (dwarf2out_register_external_die): Assign DIE parents
7282 for function-local FUNCTION_DECL and RESULT_DECL immediately.
7284 2018-07-16 Martin Liska <mliska@suse.cz>
7287 * ipa-pure-const.c (malloc_candidate_p): Revert ::get
7290 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
7292 * config/arc/arcHS.md: Update ARCHS scheduling rules.
7294 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
7296 * config/arc/arc-arch.h (arc_tune_attr): Add new tune parameters
7298 * config/arc/arc-cpus.def (hs4x): New cpu.
7300 * config/arc/arc-tables.opt: Regenerate.
7301 * config/arc/arc.c (arc_sched_issue_rate): New function.
7302 (TARGET_SCHED_ISSUE_RATE): Define.
7303 (TARGET_SCHED_EXPOSED_PIPELINE): Likewise.
7304 * config/arc/arc.md (attr type): Add fpu_fuse, fpu_sdiv, fpu_ddiv,
7306 (attr tune): Add ARCHS4x tune values.
7307 (attr tune_dspmpy): Define.
7308 (*tst): Correct instruction type.
7309 * config/arc/arcHS.md: Don't use this automaton for ARCHS4x cpus.
7310 * config/arc/arcHS4x.md: New file.
7311 * config/arc/fpu.md: Update instruction type attributes.
7312 * config/arc/t-multilib: Regenerate.
7314 2018-07-16 Tom de Vries <tdevries@suse.de>
7317 * var-tracking.c (vt_initialize): Fix pre_dec handling.
7319 2018-07-16 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
7321 * config/aarch64/atomics.md (aarch64_store_execlusive<mode>): Add
7324 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
7326 PR tree-optimization/86514
7327 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
7328 conversion to a boolean type from a type with greater precision.
7330 2018-07-16 Tom de Vries <tdevries@suse.de>
7332 * var-tracking.c (vt_initialize): Print adjusted insn slim if
7333 dump_flags request TDF_SLIM.
7335 2018-07-16 Aldy Hernandez <aldyh@redhat.com>
7337 * fold-const.c (int_const_binop_1): Abstract...
7338 (wide_int_binop): ...wide int code here.
7339 (poly_int_binop): ...poly int code here.
7340 Abstract the rest of int_const_binop_1 into int_const_binop.
7341 * fold-const.h (wide_int_binop): New.
7342 * tree-vrp.c (vrp_int_const_binop): Call wide_int_binop.
7343 Remove useless PLUS/MINUS_EXPR case.
7344 (zero_nonzero_bits_from_vr): Move wide int code...
7345 (zero_nonzero_bits_from_bounds): ...here.
7346 (extract_range_from_binary_expr_1): Move mask optimization code...
7347 (range_easy_mask_min_max): ...here.
7348 * tree-vrp.h (zero_nonzero_bits_from_bounds): New.
7349 (range_easy_mask_min_max): New.
7351 2018-07-15 Jeff Law <law@redhat.com>
7354 * config/sh/sh.c (output_mi_thunk): Remove dead conditional
7357 2018-07-14 Jim Wilson <jimw@sifive.com>
7359 * config/riscv/linux.h (TARGET_ASM_FILE_END): New.
7361 2018-07-14 Paul Koning <ni1d@arrl.net>
7363 * config/pdp11/pdp11.c (pdp11_rtx_costs): Bugfixes.
7365 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
7367 * lto-streamer-out.c (copy_function_or_variable): Dump info about
7370 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
7371 Steve Munroe <munroesj52@gmail.com>
7373 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
7374 (_mm_andnot_si128): Likewise.
7375 (_mm_or_si128): Likewise.
7376 (_mm_xor_si128): Likewise.
7378 2018-07-13 Qing Zhao <qing.zhao@oracle.com>
7381 * builtins.c (expand_builtin_memcmp): Inline the calls first
7382 when result_eq is false.
7383 (expand_builtin_strcmp): Inline the calls first.
7384 (expand_builtin_strncmp): Likewise.
7385 (inline_string_cmp): New routine. Expand a string compare
7386 call by using a sequence of char comparison.
7387 (inline_expand_builtin_string_cmp): New routine. Inline expansion
7388 a call to str(n)cmp/memcmp.
7389 * doc/invoke.texi (--param builtin-string-cmp-inline-length):
7391 * params.def (BUILTIN_STRING_CMP_INLINE_LENGTH): New.
7393 2018-07-13 Richard Earnshaw <rearnsha@arm.com>
7395 * config/arm/driver-arm.c: Include arm-native.h.
7396 (host_detect_local_cpu): Use auto-generated data tables.
7397 (vendors, arm_cpu_table): Delete. Move part information to ...
7398 * config/arm/arm-cpus.in: ... here.
7399 * config/arm/parsecpu.awk (gen_native): New function.
7400 (vendor, part): New CPU fields.
7401 (END): Add support for building the native CPU detection tables.
7402 * config/arm/t-arm (arm-native.h): Add build rule.
7403 (driver-arm.o): Add dependency on arm-native.h.
7405 2018-07-13 Richard Biener <rguenther@suse.de>
7408 * match.pd (addr1 - addr2): Allow either of the operand to
7411 2018-07-13 Tom de Vries <tdevries@suse.de>
7413 * tree-inline.c (remap_ssa_name): Save and reuse debug exprs generated
7416 2018-07-13 Jackson Woodruff <jackson.woodruff@arm.com>
7418 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp): Use
7419 arrays instead of numbered variables.
7421 2018-07-13 Eric Botcazou <ebotcazou@adacore.com>
7423 * config/sparc/sparc-protos.h (sparc_compute_frame_size): Delete.
7424 * config/sparc/sparc.c (sparc_compute_frame_size): Make static.
7426 2018-07-13 Richard Biener <rguenther@suse.de>
7429 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
7430 instead of get_context_die.
7432 2018-07-13 Kugan Vivekanandarajah <kuganv@linaro.org>
7433 Richard Biener <rguenther@suse.de>
7436 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Check
7437 that the loop latch destination where phi is defined.
7439 2018-07-12 Kito Cheng <kito.cheng@gmail.com>
7441 * config/riscv/riscv.c (enum riscv_privilege_levels): Add UNKNOWN_MODE.
7442 (riscv_expand_epilogue): Add assertion to check interrupt mode.
7443 (riscv_set_current_function): Extract getting interrupt type to new
7445 (riscv_get_interrupt_type): New function.
7446 (riscv_merge_decl_attributes): New function, checking interrupt type is
7448 (TARGET_MERGE_DECL_ATTRIBUTES): Define.
7450 2018-07-12 Paul Koning <ni1d@arrl.net>
7452 * config/pdp11/pdp11.c (pdp11_output_def): Fix typo in .set
7455 2018-07-12 Paul Koning <ni1d@arrl.net>
7457 * doc/rtl.texi (REG_NONNEG): Remove decrement and branch until
7458 zero reference, add doloop_end instead.
7459 * doc/md.texi (decrement_and_branch_until_zero): Remove.
7460 (Looping patterns): Remove decrement_and_branch_until_zero. Add
7461 detail for doloop_end.
7463 2018-07-12 Martin Sebor <msebor@redhat.com>
7466 * attribs.c (decl_attributes): Reject conflicting attributes before
7467 calling attribute handlers.
7469 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
7471 * dumpfile.c (gcc::dump_manager::get_dump_file_name): Add PART
7473 (gcc::dump_manager::get_dump_file_name): likewise.
7474 (dump_begin): Likewise.
7475 * dumpfile.h (dump_begin): Update prototype.
7476 (gcc::dump_manager::get_dump_file_name,
7477 gcc::dump_manager::get_dump_file_name): Update prototype.
7479 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
7481 * internal-fn.h (vectorizable_internal_fn_p): New function.
7482 * tree-vect-slp.c (compatible_calls_p): Likewise.
7483 (vect_build_slp_tree_1): Remove nops argument. Handle calls
7484 to internal functions.
7485 (vect_build_slp_tree_2): Update call to vect_build_slp_tree_1.
7487 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
7489 * fold-const.h (inverse_conditions_p): Declare.
7490 * fold-const.c (inverse_conditions_p): New function.
7491 * match.pd: Use inverse_conditions_p. Add folds of view_converts
7492 that test the inverse condition of a conditional internal function.
7493 * internal-fn.h (vectorized_internal_fn_supported_p): Declare.
7494 * internal-fn.c (internal_fn_mask_index): Handle conditional
7496 (vectorized_internal_fn_supported_p): New function.
7497 * tree-if-conv.c: Include internal-fn.h and fold-const.h.
7498 (any_pred_load_store): Replace with...
7499 (need_to_predicate): ...this new variable.
7500 (redundant_ssa_names): New variable.
7501 (ifcvt_can_use_mask_load_store): Move initial checks to...
7502 (ifcvt_can_predicate): ...this new function. Handle tree codes
7503 for which a conditional internal function exists.
7504 (if_convertible_gimple_assign_stmt_p): Use ifcvt_can_predicate
7505 instead of ifcvt_can_use_mask_load_store. Update after variable
7507 (predicate_load_or_store): New function, split out from
7508 predicate_mem_writes.
7509 (check_redundant_cond_expr): New function.
7510 (value_available_p): Likewise.
7511 (predicate_rhs_code): Likewise.
7512 (predicate_mem_writes): Rename to...
7513 (predicate_statements): ...this. Use predicate_load_or_store
7514 and predicate_rhs_code.
7515 (combine_blocks, tree_if_conversion): Update after above name changes.
7516 (ifcvt_local_dce): Handle redundant_ssa_names.
7517 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): Handle
7518 general conditional functions.
7519 * tree-vect-stmts.c (vectorizable_call): Likewise.
7521 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
7522 Alan Hayward <alan.hayward@arm.com>
7523 David Sherwood <david.sherwood@arm.com>
7525 * internal-fn.h (can_interpret_as_conditional_op_p): Declare.
7526 * internal-fn.c (can_interpret_as_conditional_op_p): New function.
7527 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Handle conditional
7528 plus and minus and convert them into IFN_COND_FMA-based sequences.
7529 (convert_mult_to_fma): Handle conditional plus and minus.
7531 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
7533 * doc/md.texi (cond_fma, cond_fms, cond_fnma, cond_fnms): Document.
7534 * optabs.def (cond_fma_optab, cond_fms_optab, cond_fnma_optab)
7535 (cond_fnms_optab): New optabs.
7536 * internal-fn.def (COND_FMA, COND_FMS, COND_FNMA, COND_FNMS): New
7538 (FMA): Use DEF_INTERNAL_FLT_FN rather than DEF_INTERNAL_FLT_FLOATN_FN.
7539 * internal-fn.h (get_conditional_internal_fn): Declare.
7540 (get_unconditional_internal_fn): Likewise.
7541 * internal-fn.c (cond_ternary_direct): New macro.
7542 (expand_cond_ternary_optab_fn): Likewise.
7543 (direct_cond_ternary_optab_supported_p): Likewise.
7544 (FOR_EACH_COND_FN_PAIR): Likewise.
7545 (get_conditional_internal_fn): New function.
7546 (get_unconditional_internal_fn): Likewise.
7547 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 5.
7548 (gimple_match_op::gimple_match_op): Add a new overload for 5
7550 (gimple_match_op::set_op): Likewise.
7551 (gimple_resimplify5): Declare.
7552 * genmatch.c (decision_tree::gen): Generate simplifications for
7554 * gimple-match-head.c (gimple_simplify): Define an overload for
7555 5 operands. Handle calls with 5 arguments in the top-level overload.
7556 (convert_conditional_op): Handle conversions from unconditional
7557 internal functions to conditional ones.
7558 (gimple_resimplify5): New function.
7559 (build_call_internal): Pass a fifth operand.
7560 (maybe_push_res_to_seq): Likewise.
7561 (try_conditional_simplification): Try converting conditional
7562 internal functions to unconditional internal functions.
7563 Handle 3-operand unconditional forms.
7564 * match.pd (UNCOND_TERNARY, COND_TERNARY): Operator lists.
7565 Define ternary equivalents of the current rules for binary conditional
7567 * config/aarch64/aarch64.c (aarch64_preferred_else_value): Handle
7569 * config/aarch64/iterators.md (UNSPEC_COND_FMLA, UNSPEC_COND_FMLS)
7570 (UNSPEC_COND_FNMLA, UNSPEC_COND_FNMLS): New unspecs.
7571 (optab): Handle them.
7572 (SVE_COND_FP_TERNARY): New int iterator.
7573 (sve_fmla_op, sve_fmad_op): New int attributes.
7574 * config/aarch64/aarch64-sve.md (cond_<optab><mode>)
7575 (*cond_<optab><mode>_2, *cond_<optab><mode_4)
7576 (*cond_<optab><mode>_any): New SVE_COND_FP_TERNARY patterns.
7578 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
7580 * target.def (preferred_else_value): New target hook.
7581 * doc/tm.texi.in (TARGET_PREFERRED_ELSE_VALUE): New hook.
7582 * doc/tm.texi: Regenerate.
7583 * targhooks.h (default_preferred_else_value): Declare.
7584 * targhooks.c (default_preferred_else_value): New function.
7585 * internal-fn.h (conditional_internal_fn_code): Declare.
7586 * internal-fn.c (FOR_EACH_CODE_MAPPING): New macro.
7587 (get_conditional_internal_fn): Use it.
7588 (conditional_internal_fn_code): New function.
7589 * gimple-match.h (gimple_match_cond): New struct.
7590 (gimple_match_op): Add a cond member function.
7591 (gimple_match_op::gimple_match_op): Update all forms to take a
7593 * genmatch.c (expr::gen_transform): Use the same condition as res_op
7594 for the suboperation, but don't specify a particular else_value.
7595 * tree-ssa-sccvn.c (vn_nary_simplify, vn_reference_lookup_3)
7596 (visit_nary_op, visit_reference_op_load): Pass
7597 gimple_match_cond::UNCOND to the gimple_match_op constructor.
7598 * gimple-match-head.c: Include tree-eh.h
7599 (convert_conditional_op): New function.
7600 (maybe_resimplify_conditional_op): Likewise.
7601 (gimple_resimplify1): Call maybe_resimplify_conditional_op.
7602 (gimple_resimplify2): Likewise.
7603 (gimple_resimplify3): Likewise.
7604 (gimple_resimplify4): Likewise.
7605 (maybe_push_res_to_seq): Return null for conditional operations.
7606 (try_conditional_simplification): New function.
7607 (gimple_simplify): Call it. Pass conditions to the gimple_match_op
7609 * match.pd: Fold VEC_COND_EXPRs of an IFN_COND_* call to a new
7611 * config/aarch64/aarch64.c (aarch64_preferred_else_value): New
7613 (TARGET_PREFERRED_ELSE_VALUE): Redefine.
7615 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
7617 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
7619 (hash_tree): Do not hash DECL_FCONTEXT
7620 * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
7621 Do not stream DECL_FCONTEXT.
7622 * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
7623 * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
7625 2018-07-12 Richard Biener <rguenther@suse.de>
7628 * dwarf2out.c (gen_block_die): Only output blocks when they have
7629 at least one !DECL_IGNORED_P variable.
7631 2018-07-12 Richard Biener <rguenther@suse.de>
7634 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
7635 Remove -mieee-fp handling.
7637 2018-07-12 Richard Biener <rguenther@suse.de>
7639 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Remove bogus
7640 left-over from last patch.
7642 2018-07-12 Jakub Jelinek <jakub@redhat.com>
7644 PR tree-optimization/86492
7645 * gimple-ssa-store-merging.c
7646 (imm_store_chain_info::coalesce_immediate_stores): Call
7647 check_no_overlap even for the merge_overlapping case. Formatting fix.
7649 2018-07-12 Richard Biener <rguenther@suse.de>
7652 * fold-const.c (fold_binary_op_with_conditional_arg): Do not
7653 move possibly trapping operations into the conditional.
7655 2018-07-12 Richard Biener <rguenther@suse.de>
7657 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
7658 (vn_lookup_simplify_result): Remove recursion limit applied
7660 (vn_nary_build_or_lookup_1): Adjust.
7661 (try_to_simplify): Likewise.
7662 * gimple-match-head.c (gimple_resimplify1): Instead apply one
7664 (gimple_resimplify2): Likewise.
7665 (gimple_resimplify3): Likewise.
7666 (gimple_resimplify4): Likewise.
7668 2018-07-11 Jakub Jelinek <jakub@redhat.com>
7670 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
7671 Use __mmask64 type instead of __mmask8 for __M argument.
7672 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
7673 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
7675 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
7676 __mmask16 for __M argument.
7677 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
7678 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
7679 to __mmask16 instead of __mmask8.
7680 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
7681 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
7682 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
7683 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
7684 instead of __mmask16 for __U argument.
7685 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
7686 __mmask16 instead of __mmask8 for __U argument.
7687 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
7689 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
7691 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
7693 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
7695 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
7697 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
7699 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
7701 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
7703 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
7705 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
7707 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
7708 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
7709 return type as well as __M argument type and all casts from __mmask8
7711 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
7712 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
7713 return type as well as __M argument type and all casts from __mmask8
7715 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
7716 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
7717 return type as well as __M argument type and all casts from __mmask8
7719 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
7720 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
7721 return type as well as __M argument type and all casts from __mmask8
7723 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
7724 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
7727 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
7729 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
7730 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
7733 2018-07-11 Paul Koning <ni1d@arrl.net>
7735 * doc/md.texi (define_subst): Document how multiple occurrences of
7736 the same argument in the replacement pattern are handled.
7738 2018-07-11 Paul Koning <ni1d@arrl.net>
7740 * doc/extend.texi (Common Variable Attributes): Move "mode" into
7742 (Common Type Attributes): Add "mode" attribute.
7744 2018-07-11 Jan Hubicka <hubicka@ucw.cz>
7746 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not
7747 stream DECL_ORIGINAL_TYPE.
7748 (DFS::DFS_write_tree_body): Drop hack handling local external decls.
7749 (hash_tree): Do not walk DECL_ORIGINAL_TYPE.
7750 * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
7751 Do not walk original type.
7752 * tree-streamer-out.c (streamer_write_chain): Drop hack handling
7754 (write_ts_decl_non_common_tree_pointers): Do not stream
7756 * tree.c (free_lang_data_in_decl): Clear DECL_ORIGINAL_TYPE.
7757 (find_decls_types_r): Do not walk DEC_ORIGINAL_TYPE.
7759 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
7761 * tree-ssa-threadupdate.c (thread_through_all_blocks): Do not jump
7762 thread twice from the same starting edge.
7764 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
7766 * vr-values.c (gimple_stmt_nonzero_p): Abstract common code to...
7767 * gimple.c (gimple_call_nonnull_result_p): ...here...
7768 (gimple_call_nonnull_arg): ...and here.
7769 * gimple.h (gimple_call_nonnull_result_p): New.
7770 (gimple_call_nonnull_arg): New.
7772 2018-07-11 Richard Earnshaw <rearnsha@arm.com>
7774 * config/arm/arm-cpus.in: Move information from fpu field of each
7775 cpu definition to the isa field.
7776 * config/arm/parsecpu.awk (fpu): Delete match rule.
7777 (gen_comm_data): Don't add bits from the CPU's FPU entry.
7779 2018-07-11 Richard Biener <rguenther@suse.de>
7782 * dwarf2out.c (init_sections_and_labels): Use
7783 output_asm_line_debug_info consistently.
7784 (dwarf2out_early_finish): Likewise.
7785 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
7788 2018-07-11 Richard Biener <rguenther@suse.de>
7790 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1):
7791 Rework father_bb setting in a way to avoid propagating constants
7792 multiple times on a loop body.
7794 2018-07-10 Mark Wielaard <mark@klomp.org>
7797 * dwarf2out.c (output_macinfo_op): Fix dwarf_FORM typo in gcc_assert.
7799 2018-07-10 Richard Biener <rguenther@suse.de>
7801 * hash-map.h (hash_map::iterator::operator*): Return
7802 references to key and value.
7804 2018-07-10 Jakub Jelinek <jakub@redhat.com>
7807 * gimplify.c (find_combined_omp_for): Add DATA argument, in addition
7808 to finding the inner OMP_FOR/OMP_SIMD stmt find non-trivial wrappers,
7809 BLOCKs with BLOCK_VARs, OMP_PARALLEL in between, OMP_FOR in between.
7810 (gimplify_omp_for): For composite loops, move outer
7811 OMP_{DISTRIBUTE,TASKLOOP,FOR,PARALLEL} right around innermost
7812 OMP_FOR/OMP_SIMD if there are any non-trivial wrappers. For class
7813 iterators add any needed clauses. Allow OMP_FOR_ORIG_DECLS to contain
7814 TREE_LIST for both the original class iterator and the "last" helper
7815 var. Gimplify OMP_FOR_PRE_BODY before the outermost composite
7816 loop, remember has_decl_expr from outer composite loops for the
7817 innermost OMP_SIMD in TREE_PRIVATE bit on OMP_FOR_INIT.
7819 2018-07-09 Martin Sebor <msebor@redhat.com>
7823 * builtins.c (c_strlen): Avoid out-of-bounds warnings when
7824 accessing implicitly initialized array elements.
7825 * expr.c (string_constant): Handle string initializers of
7826 character arrays within aggregates.
7827 * gimple-fold.c (fold_array_ctor_reference): Add argument.
7828 Store element offset. As a special case, handle zero size.
7829 (fold_nonarray_ctor_reference): Same.
7830 (fold_ctor_reference): Add argument. Store subobject offset.
7831 * gimple-fold.h (fold_ctor_reference): Add argument.
7833 2018-07-09 Paul Koning <ni1d@arrl.net>
7835 * config/pdp11/pdp11.c (pdp11_addr_cost): New function.
7836 (pdp11_insn_cost): New function.
7837 (pdp11_md_asm_adjust): New function.
7838 (TARGET_INVALID_WITHIN_DOLOOP): Define.
7839 (pdp11_rtx_costs): Update to match machine better.
7840 (output_addr_const_pdp11): Correct format mismatch warnings.
7841 * config/pdp11/pdp11.h (SLOW_BYTE_ACCESS): Correct definition.
7842 * config/pdp11/pdp11.md: General change to add base_cost and/or
7843 length attributes for use by new pdp11_insn_cost function.
7844 (MIN_BRANCH): Correct definition.
7846 (doloop_end): Use standard pattern name for looping pattern.
7847 (doloop_end_nocc): New.
7848 (movsf): Add another constraint alternative.
7849 (zero_extendqihi2): Add constraint alternatives for not in place
7851 (zero_extendhisi2): Remove.
7852 (shift patterns): Add CC handling variants.
7856 (define_peephole2): New peephole to recognize mov that sets CC for
7859 2018-07-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7861 * config/sparc/sparc.c (sparc_fold_builtin) <SPARC_BUILTIN_PDIST,
7862 SPARC_BUILTIN_PDISTN>: Adapt for signature change of wi::neg,
7865 2018-07-09 Jakub Jelinek <jakub@redhat.com>
7868 * real.c (real_nextafter): Return true if result is denormal.
7870 2018-07-09 Martin Liska <mliska@suse.cz>
7872 * common.opt: Add back wrongly removed attribute.
7874 2018-07-09 Richard Biener <rguenther@suse.de>
7877 * dwarf2out.c (gen_block_die): For an early generated DIE
7878 always output high/low PC attributes.
7880 2018-07-09 Tom de Vries <tdevries@suse.de>
7882 * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
7883 * tree-inline.c (remap_ssa_name): Handle default def ssa_name mapping
7884 onto VAR_DECL with abstract origin.
7886 2018-07-07 Jim Wilson <jimw@sifive.com>
7888 * config/riscv/riscv.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): New.
7890 2018-07-07 Tom de Vries <tdevries@suse.de>
7892 * tree-dfa.c (dump_enumerated_decls): Handle cfun->cfg == NULL.
7894 2018-07-07 Aldy Hernandez <aldyh@redhat.com>
7896 * tree-vrp.c (vrp_int_const_binop): Change overflow type to
7898 (combine_bound): Use wide-int overflow calculation instead of
7900 * calls.c (maybe_warn_alloc_args_overflow): Change overflow type to
7902 * fold-const.c (int_const_binop_2): Same.
7903 (extract_muldiv_1): Same.
7904 (fold_div_compare): Same.
7905 (fold_abs_const): Same.
7907 * poly-int.h (add): Same.
7911 * predict.c (predict_iv_comparison): Same.
7912 * profile-count.c (slow_safe_scale_64bit): Same.
7913 * simplify-rtx.c (simplify_const_binary_operation): Same.
7914 * tree-chrec.c (tree_fold_binomial): Same.
7915 * tree-data-ref.c (split_constant_offset_1): Same.
7916 * tree-if-conv.c (idx_within_array_bound): Same.
7917 * tree-scalar-evolution.c (iv_can_overflow_p): Same.
7918 * tree-ssa-phiopt.c (minmax_replacement): Same.
7919 * tree-vect-loop.c (is_nonwrapping_integer_induction): Same.
7920 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Same.
7921 * vr-values.c (vr_values::adjust_range_with_scev): Same.
7922 * wide-int.cc (wi::add_large): Same.
7923 (wi::mul_internal): Same.
7924 (wi::sub_large): Same.
7925 (wi::divmod_internal): Same.
7926 * wide-int.h: Change overflow type to overflow_type for neg, add,
7927 mul, smul, umul, div_trunc, div_floor, div_ceil, div_round,
7928 mod_trunc, mod_ceil, mod_round, add_large, sub_large,
7929 mul_internal, divmod_internal.
7930 (overflow_type): New enum.
7931 (accumulate_overflow): New.
7933 2018-07-06 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
7935 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): New.
7936 (tree_ssa_phiopt_worker): Call cond_removal_in_popcount_pattern.
7938 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
7940 * tree-ssa-loop-niter.c (number_of_iterations_popcount): If popcount
7941 argument is checked for zero before entering loop, avoid checking again.
7943 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
7945 * gimplify.h (generic_expr_could_trap_p): Set as global function.
7946 * gimplify.h (generic_expr_could_trap_p): Likwise.
7947 * tree-scalar-evolution.c (expression_expensive_p): Handle COND_EXPR.
7949 2018-07-06 Jakub Jelinek <jakub@redhat.com>
7951 PR tree-optimization/86401
7952 * fold-const.c (fold_binary_loc) <case BIT_AND_EXPR>: Move the
7953 ((A & N) + B) & M -> (A + B) & M etc. optimization into ...
7954 (fold_bit_and_mask): ... here. New helper function for match.pd.
7955 * fold-const.h (fold_bit_and_mask): Declare.
7956 * match.pd (((A & N) + B) & M -> (A + B) & M): New optimization.
7958 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
7961 * target.def (translate_mode_attribute): New hook.
7962 * targhooks.h (default_translate_mode_attribute): Declare.
7963 * targhooks.c (default_translate_mode_attribute): New function.
7964 * doc/tm.texi.in (TARGET_TRANSLATE_MODE_ATTRIBUTE): New hook.
7965 * doc/tm.texi: Regenerate.
7966 * config/rs6000/rs6000.c (TARGET_TRANSLATE_MODE_ATTRIBUTE): Define.
7967 (rs6000_translate_mode_attribute): New function.
7969 2018-07-06 Paul Koning <ni1d@arrl.net>
7971 * doc/md.texi (define_split): Document DONE and FAIL.
7972 (define_peephole2): Ditto.
7974 2018-07-05 Jeff Law <law@redhat.com>
7976 PR tree-optimization/86010
7977 * tree-ssa-dse.c (compute_trims): More aggressively trim at
7978 both the head and tail of mem* and str* calls.
7980 2018-07-05 Jim Wilson <jimw@sifive.com>
7982 * config.gcc (riscv*-*-*): When setting xlen, handle riscv-*.
7984 2018-07-05 Indu Bhagat <indu.bhagat@oracle.com>
7986 * config/aarch64/aarch64-simd.md: correct flags text for
7987 MIN_EXPR replacement.
7989 2018-07-05 James Clarke <jrtc27@jrtc27.com>
7991 * configure: Regenerated.
7993 2018-07-05 Carl Love <cel@us.ibm.com>
7995 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
7996 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
7997 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
7998 VSX_BUILTIN_DOUBLEL_V4SF.
8000 2018-07-05 Martin Sebor <msebor@redhat.com>
8003 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
8004 than its domain to compute its the upper bound of a char array.
8006 2018-07-05 Nathan Sidwell <nathan@acm.org>
8008 Replace NO_IMPLICIT_EXTERN_C with SYSTEM_IMPLICIT_EXTERN_C.
8009 * doc/cpp.texi: Update comment.
8010 * doc/tm.texi: Rebuilt.
8011 * doc/tm.texi.in (NO_IMPLICIT_EXTERN_C): Replace with ...
8012 (SYSTEM_IMPLICIT_EXTERN_C): ... this, opposite sense.
8013 * doc/extend.texi (Backwards Compatibility): Clarify it is system
8014 headers affected by extern "C".
8015 * system.h: Poison NO_IMPLICIT_EXTERN_C.
8016 * config/alpha/alpha.h, config/arm/uclinux-elf.h,
8017 config/bfin/elf.h, config/cris/cris.h, config/darwin.h,
8018 config/dragonfly.h, config/freebsd.h, config/gnu-user.h,
8019 config/i386/cygming.h, config/i386/djgpp.h, config/i386/nto.h,
8020 config/ia64/hpux.h, config/lm32/lm32.h, config/lm32/uclinux-elf.h,
8021 config/lynx.h, config/mips/elf.h, config/mmix/mmix.h,
8022 config/netbsd.h, config/pa/pa-hpux.h, config/powerpcspe/sysv4.h,
8023 config/riscv/elf.h, config/rs6000/sysv4.h, config/rtems.h,
8024 config/s390/tpf.h, config/sh/newlib.h, config/sol2.h,
8025 config/sparc/openbsd64.h, config/sparc/sp-elf.h,
8026 config/sparc/sp64-elf.h, config/spu/spu.h,
8027 config/stormy16/stormy16.h, config/v850/v850.h,
8028 config/visium/visium.h, config/vx-common.h, config/xtensa/elf.h: Don't
8029 define NO_IMPLICIT_EXTERN_C.
8030 * config/rs6000/aix.h: Set SYSTEM_IMPLICIT_EXTERN_C.
8032 2018-07-05 Tamar Christina <tamar.christina@arm.com>
8035 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
8036 instead of GET_MODE_SIZE when comparing Units.
8038 2018-07-05 Tamar Christina <tamar.christina@arm.com>
8041 * rtlanal.c (set_noop_p): Constrain on mode change,
8042 include hard-reg-set.h
8044 2018-07-05 Tamar Christina <tamar.christina@arm.com>
8046 * config/aarch64/aarch64.c (aarch64_expand_movmem): Fix mode size.
8048 2018-07-05 Jakub Jelinek <jakub@redhat.com>
8051 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
8054 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
8056 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
8058 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
8061 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
8063 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
8065 2018-07-04 Eric Botcazou <ebotcazou@adacore.com>
8068 * expmed.c (choose_multiplier): Fix incorrect comparison with mask.
8070 2018-07-04 Aldy Hernandez <aldyh@redhat.com>
8072 * tree-vrp.c (extract_range_from_binary_expr_1): Initialize
8073 neg_*_op* variables.
8075 2018-07-04 Martin Liska <mliska@suse.cz>
8077 * tree-switch-conversion.c: Define
8078 max_ratio_for_speed and max_ratio_for_size constants.
8080 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
8081 Martin Liska <mliska@suse.cz>
8086 * common.opt: Rename align options with 'str_' prefix.
8087 * common/config/i386/i386-common.c (set_malign_value): New
8089 (ix86_handle_option): Use it to set -falign-* options/
8090 * config/aarch64/aarch64-protos.h (struct tune_params): Change
8091 type from int to string.
8092 * config/aarch64/aarch64.c: Update default values from int
8094 * config/alpha/alpha.c (alpha_override_options_after_change):
8096 * config/arm/arm.c (arm_override_options_after_change_1): Likewise.
8097 * config/i386/dragonfly.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
8098 max skip conditionally.
8099 * config/i386/freebsd.h (SUBALIGN_LOG): New.
8100 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
8101 max skip conditionally.
8102 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
8103 max skip conditionally.
8104 * config/i386/gnu-user.h (SUBALIGN_LOG): New.
8105 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
8106 max skip conditionally.
8107 * config/i386/i386.c (struct ptt): Change type from int to
8109 (ix86_default_align): Set default values.
8110 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Print
8111 max skip conditionally.
8112 * config/i386/iamcu.h (SUBALIGN_LOG): New.
8113 (ASM_OUTPUT_MAX_SKIP_ALIGN):
8114 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN):
8115 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
8116 max skip conditionally.
8117 * config/i386/openbsdelf.h (SUBALIGN_LOG): New.
8118 (ASM_OUTPUT_MAX_SKIP_ALIGN) Print max skip conditionally.:
8119 * config/i386/x86-64.h (SUBALIGN_LOG): New.
8120 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
8121 max skip conditionally.
8122 (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
8123 * config/ia64/ia64.c (ia64_option_override): Set default values
8124 for alignment options.
8125 * config/m68k/m68k.c: Handle new str_align_* options.
8126 * config/mips/mips.c (mips_set_compression_mode): Change
8128 (mips_option_override): Set default values for options.
8129 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
8131 * config/rs6000/rs6000.c (rs6000_option_override_internal):
8133 * config/rx/rx.c (rx_option_override): Likewise.
8134 * config/rx/rx.h (JUMP_ALIGN): Use align_jumps_log.
8135 (LABEL_ALIGN): Use align_labels_log.
8136 (LOOP_ALIGN): Use align_loops_align.
8137 * config/s390/s390.c (s390_asm_output_function_label): Use new
8139 * config/sh/sh.c (sh_override_options_after_change):
8140 Change type of constants.
8141 * config/spu/spu.c (spu_sched_init): Likewise.
8142 * config/sparc/sparc.c (sparc_option_override): Set default
8144 * config/visium/visium.c (visium_option_override): Likewise.
8145 * config/visium/visium.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Do not
8146 emit p2align format with last argument if it's not needed.
8147 * doc/invoke.texi: Document extended format of -falign-*.
8148 * final.c: Use align_labels alignment.
8149 * flags.h (struct target_flag_state): Change type to use
8151 (struct align_flags_tuple): New.
8152 (struct align_flags): Likewise.
8153 (align_loops_log): Redefine macro to use new types.
8154 (align_loops_max_skip): Redefine macro to use new types.
8155 (align_jumps_log): Redefine macro to use new types.
8156 (align_jumps_max_skip): Redefine macro to use new types.
8157 (align_labels_log): Redefine macro to use new types.
8158 (align_labels_max_skip): Redefine macro to use new types.
8159 (align_functions_log): Redefine macro to use new types.
8160 (align_loops): Redefine macro to use new types.
8161 (align_jumps): Redefine macro to use new types.
8162 (align_labels): Redefine macro to use new types.
8163 (align_functions): Redefine macro to use new types.
8164 (align_functions_max_skip): Redefine macro to use new types.
8165 (align_loops_value): New macro.
8166 (align_jumps_value): New macro.
8167 (align_labels_value): New macro.
8168 (align_functions_value): New macro.
8169 * function.c (invoke_set_current_function_hook): Propagate
8170 alignment values from flags to global variables default in
8172 * ipa-icf.c (sem_function::equals_wpa): Use
8173 cl_optimization_option_eq instead of memcmp.
8174 * lto-streamer.h (cl_optimization_stream_out): Support streaming
8176 (cl_optimization_stream_in): Likewise.
8177 * optc-save-gen.awk: Support strings in cl_optimization.
8178 * opth-gen.awk: Likewise.
8179 * opts.c (finish_options): Remove error checking of invalid
8181 (MAX_CODE_ALIGN): Remove.
8182 (MAX_CODE_ALIGN_VALUE): Likewise.
8183 (parse_and_check_align_values): New function.
8184 (check_alignment_argument): Likewise.
8185 (common_handle_option): Use check_alignment_argument.
8186 * opts.h (parse_and_check_align_values): Declare.
8187 * toplev.c (init_alignments): Remove.
8188 (read_log_maxskip): New.
8189 (parse_N_M): Likewise.
8190 (parse_alignment_opts): Likewise.
8191 (backend_init_target): Remove usage of init_alignments.
8192 * toplev.h (parse_alignment_opts): Declare.
8193 * tree-streamer-in.c (streamer_read_tree_bitfields): Add new
8195 * tree-streamer-out.c (streamer_write_tree_bitfields): Likewise.
8196 * tree.c (cl_option_hasher::equal): New.
8197 * varasm.c: Use new global macros.
8199 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
8201 * config/i386/dragonfly.h: (ASM_OUTPUT_MAX_SKIP_ALIGN):
8202 Use a simpler align directive also if MAXSKIP = ALIGN-1.
8203 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8204 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8205 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8206 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
8207 * config/i386/freebsd.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove "If N
8208 is large, do at least 8 byte alignment" code. Add SUBALIGN_LOG
8209 define. Use a simpler align directive also if MAXSKIP = ALIGN-1.
8210 * config/i386/gnu-user.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8211 * config/i386/iamcu.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8212 * config/i386/openbsdelf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8213 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
8215 2018-07-04 Martin Liska <mliska@suse.cz>
8216 Jonathan Wakely <jwakely@redhat.com>
8218 * coverage.c: Use correct type.
8219 * doc/invoke.texi: Language correction.
8221 2018-07-03 H.J. Lu <hongjiu.lu@intel.com>
8224 * config/i386/i386.c (rest_of_insert_endbranch): Also generate
8225 ENDBRANCH for non-tail call which may return via indirect branch.
8226 * doc/extend.texi: Document indirect_return attribute.
8228 2018-07-03 Martin Sebor <msebor@redhat.com>
8230 PR tree-optimization/86274
8231 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
8233 (format_floating): Correct handling of infinities and NaNs.
8235 2018-07-03 Martin Sebor <msebor@redhat.com>
8237 * print-tree.c (print_real_cst): New function.
8238 (print_node_brief): Call it.
8239 (print_node): Ditto.
8241 2018-07-03 Jeff Law <law@redhat.com>
8243 * config/h8300/h8300.md (logical<mode>3_sn, logical<mode>3): Merge
8244 into a single pattern.
8246 * config/h8300/h8300.md (ors code_iterator): New.
8247 (bsetqi_msx, bnotqi_msx patterns and splitters): Consolidate into
8248 a single pattern and single splitter.
8249 (bsethi_msx, bnothi_msx patterns): Consolidate into a single pattern.
8250 (iorqi3_1, xorqi3_1): Likewise.
8251 (iorqi3, xorqi3 expanders): Similarly.
8253 * config/h8300/h8300.md (movmd_internal_normal): Consolidated with
8254 (movmd_internal) into a single pattern using the P mode iterator.
8255 (movmd splitters): Similarly.
8256 (stpcpy_internal_normal, stpcpy_internal): Similarly for thes patterns.
8257 (movsd splitters): Similarly.
8259 * config/h8300/h8300.c (h8300_insn_length_from_table): Consolidate
8260 ADDB, ADDW and ADDL into a single ADD attribute which selects the
8261 right table based on the size of the operand.
8262 * config/h8300/h8300.md (length_table): Corresponding changes. All
8263 references to "addb", "addw" and "addl" changed to "add".
8264 (btst patterns): Merge two variants into a single pattern.
8265 (tstqi, tsthi): Likewise.
8266 (addhi3_incdec, addsi3_incdec): Likewise.
8267 (subhi3_h8300hs, subsi3_h8300hs): Likewise.
8268 (mulhi3, mulsi3): Likewise.
8269 (udivhi3, udivsi3): Likewise.
8270 (divhi3, divsi3): Likewise.
8271 (andorqi3, andorhi3, andorsi3): Likewise.
8273 2018-07-03 Uros Bizjak <ubizjak@gmail.com>
8276 * config/i386/sse.md (uavg<mode>3_ceil): New expander.
8277 (<sse2_avx2>_uavg<mode>3<mask_name>): Simplify expander.
8279 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
8281 PR tree-optimization/85694
8282 * config/aarch64/iterators.md (HADD, RHADD): New int iterators.
8283 (u): Handle UNSPEC_SHADD, UNSPEC_UHADD, UNSPEC_SRHADD and
8285 * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor)
8286 (<u>avg<mode>3_ceil): New patterns.
8288 2018-07-03 David Malcolm <dmalcolm@redhat.com>
8290 * gcc.dg/vect/slp-perm-1.c: Remove "note: " prefix from
8291 scan-tree-dump directive.
8292 * gcc.dg/vect/slp-perm-2.c: Likewise.
8293 * gcc.dg/vect/slp-perm-3.c: Likewise.
8294 * gcc.dg/vect/slp-perm-5.c: Likewise.
8295 * gcc.dg/vect/slp-perm-6.c: Likewise.
8296 * gcc.dg/vect/slp-perm-7.c: Likewise.
8297 * gcc.dg/vect/slp-perm-8.c: Likewise.
8299 2018-07-03 Marek Polacek <polacek@redhat.com>
8302 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
8304 2018-07-03 Richard Biener <rguenther@suse.de>
8307 * tree-ssa-structalias.c (find_func_clobbers): Properly
8308 handle indirect calls.
8310 2018-07-03 Jeff Law <law@redhat.com>
8312 * config/h8300/h8300.md (HSI, QHSI, QHSIF): New mode iterators.
8313 (shifts): New code iterator.
8314 (movqi, movhi, movsi, movsf expanders): Consolidate into a single
8315 expander. Fix HImode handling on H8/SX.
8316 (addqi3, addhi3, addsi3 expanders): Consolidate into a single expander.
8317 (subqi3, subhi3, subsi3 expanders): Likewise.
8318 (andqi3, andhi3, andsi3 expanders): Likewise.
8319 (iorqi3, iorhi3, iorsi3 expanders): Likewise.
8320 (xorqi3, xorhi3, xorsi3 expanders): Likewise.
8321 (negqi2, neghi2, negsi2, negsf2 expanders): Likewise.
8322 (one_cmplqi2, one_cmplhi2, one_cmplsi2): Likewise.
8323 (zero_extendqihi2, zero_extendqisi2): Likewise.
8324 (extendqihi2, extendqisi2): Likewise.
8325 (rotlqi3, rotlhi3, rotlsi3): Likewise.
8326 (neghi2_h8300, negsi2_h8300): Likewise for these patterns.
8327 (rotlqi3_1, rotlhi3_1): Likewise.
8328 (logicalhi3_sn, logicalsi3_sn): Likewise.
8329 (logicalhi3, logicalsi3): Likewise.
8331 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
8333 * tree-vect-patterns.c (vect_recog_rotate_pattern)
8334 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
8335 (vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast)
8336 (adjust_bool_pattern, vect_recog_bool_pattern): Pass the vector
8337 type to append_pattern_def_seq instead of creating a stmt_vec_info
8339 (build_mask_conversion): Likewise. Remove vinfo argument.
8340 (vect_add_conversion_to_patterm): Likewise, renaming to...
8341 (vect_add_conversion_to_pattern): ...this.
8342 (vect_recog_mask_conversion_pattern): Update call to
8343 build_mask_conversion. Pass the vector type to
8344 append_pattern_def_seq here too.
8345 (vect_recog_gather_scatter_pattern): Update call to
8346 vect_add_conversion_to_pattern.
8348 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
8350 * tree-vect-patterns.c (new_pattern_def_seq): Delete.
8351 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
8352 (vect_recog_widen_op_pattern, vect_recog_over_widening_pattern)
8353 (vect_recog_rotate_pattern, vect_synth_mult_by_constant): Don't set
8354 STMT_VINFO_PATTERN_DEF_SEQ to null here.
8355 (vect_recog_pow_pattern, vect_recog_vector_vector_shift_pattern)
8356 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern): Use
8357 append_pattern_def_seq instead of new_pattern_def_seq.
8358 (vect_recog_divmod_pattern): Do both of the above.
8359 (vect_pattern_recog_1): Assert that STMT_VINO_PATTERN_DEF_SEQ
8362 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
8364 * tree-vect-patterns.c (vect_recog_dot_prod_pattern):
8365 (vect_recog_sad_pattern, vect_recog_widen_op_pattern)
8366 (vect_recog_widen_mult_pattern, vect_recog_pow_pattern):
8367 (vect_recog_widen_sum_pattern, vect_recog_over_widening_pattern)
8368 (vect_recog_average_pattern, vect_recog_cast_forwprop_pattern)
8369 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
8370 (vect_recog_vector_vector_shift_pattern, vect_synth_mult_by_constant)
8371 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
8372 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
8373 (vect_recog_mask_conversion_pattern): Replace vec<gimple *>
8374 parameter with a single stmt_vec_info.
8375 (vect_recog_func_ptr): Likewise.
8376 (vect_recog_gather_scatter_pattern): Likewise, folding in...
8377 (vect_try_gather_scatter_pattern): ...this.
8378 (vect_pattern_recog_1): Remove stmts_to_replace and just pass
8379 the stmt_vec_info of the statement to be matched. Don't clear
8380 STMT_VINFO_RELATED_STMT.
8381 (vect_pattern_recog): Update call accordingly.
8383 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
8385 PR tree-optimization/85694
8386 * doc/md.texi (avgM3_floor, uavgM3_floor, avgM3_ceil)
8387 (uavgM3_ceil): Document new optabs.
8388 * doc/sourcebuild.texi (vect_avg_qi): Document new target selector.
8389 * internal-fn.def (IFN_AVG_FLOOR, IFN_AVG_CEIL): New internal
8391 * optabs.def (savg_floor_optab, uavg_floor_optab, savg_ceil_optab)
8392 (savg_ceil_optab): New optabs.
8393 * tree-vect-patterns.c (vect_recog_average_pattern): New function.
8394 (vect_vect_recog_func_ptrs): Add it.
8395 * tree-vect-stmts.c (vectorizable_call): Get the type of the zero
8396 constant directly from the associated lhs.
8398 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
8400 * tree-vect-patterns.c (vect_split_statement): New function.
8401 (vect_convert_input): Use it to try to split an existing cast.
8403 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
8405 * poly-int.h (print_hex): New function.
8406 * dumpfile.h (dump_dec, dump_hex): Declare.
8407 * dumpfile.c (dump_dec, dump_hex): New poly_wide_int functions.
8408 * tree-vectorizer.h (_stmt_vec_info): Add min_output_precision,
8409 min_input_precision, operation_precision and operation_sign.
8410 * tree-vect-patterns.c (vect_get_range_info): New function.
8411 (vect_same_loop_or_bb_p, vect_single_imm_use)
8412 (vect_operation_fits_smaller_type): Delete.
8413 (vect_look_through_possible_promotion): Add an optional
8414 single_use_p parameter.
8415 (vect_recog_over_widening_pattern): Rewrite to use new
8416 stmt_vec_info infomration. Handle one operation at a time.
8417 (vect_recog_cast_forwprop_pattern, vect_narrowable_type_p)
8418 (vect_truncatable_operation_p, vect_set_operation_type)
8419 (vect_set_min_input_precision): New functions.
8420 (vect_determine_min_output_precision_1): Likewise.
8421 (vect_determine_min_output_precision): Likewise.
8422 (vect_determine_precisions_from_range): Likewise.
8423 (vect_determine_precisions_from_users): Likewise.
8424 (vect_determine_stmt_precisions, vect_determine_precisions): Likewise.
8425 (vect_vect_recog_func_ptrs): Put over_widening first.
8427 (vect_pattern_recog): Call vect_determine_precisions.
8429 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
8431 * tree-vect-patterns.c (vect_mark_pattern_stmts): Remove pattern
8432 statements that have been replaced by further pattern statements.
8433 (vect_pattern_recog_1): Clear STMT_VINFO_PATTERN_DEF_SEQ on failure.
8435 2018-07-03 Richard Biener <rguenther@suse.de>
8437 * tree-vect-stmts.c (vect_is_simple_use): Consolidate dumping,
8438 always set *dt. Dump vectype in vectype overload.
8439 * dumpfile.h (dump_gimple_expr): New function.
8440 (dump_gimple_expr_loc): Likewise.
8441 * dumpfile.c (dump_gimple_expr): New function.
8442 (dump_gimple_expr_loc): Likewise.
8444 2018-07-02 Jeff Law <law@redhat.com>
8446 * config/h8300/h8300.md (movqi_h8300, movqi_h8300hs): Consolidate
8447 the H8/300, H8/300H and H8/S variants into a single pattern.
8448 (movhi_h8300, movqi_h8300hs): Similarly.
8449 (pushqi_h8300hs, pushhi_h8300hs): Consolidate into a single pattern.
8450 (QHI mode iterator): New.
8452 * config/h8300/h8300.md: Remove trailing whitespace.
8454 2018-07-02 Jim Wilson <jimw@sifive.com>
8456 * config/riscv/riscv.c (riscv_expand_epilogue): Use emit_jump_insn
8457 instead of emit_insn for interrupt returns.
8458 * config/riscv/riscv.md (riscv_met): Add (return) to rtl.
8459 (riscv_sret, riscv_uret): Likewise.
8461 2018-07-02 David Malcolm <dmalcolm@redhat.com>
8463 * pretty-print.c (selftest::test_pp_format): Move save and restore
8464 of quotes to class auto_fix_quotes, and add an instance.
8465 * selftest.c: Include "intl.h".
8466 (selftest::auto_fix_quotes::auto_fix_quotes): New ctor.
8467 (selftest::auto_fix_quotes::~auto_fix_quotes): New dtor.
8468 * selftest.h (selftest::auto_fix_quotes): New class.
8470 2018-07-02 Richard Henderson <richard.henderson@linaro.org>
8472 * config/aarch64/aarch64-protos.h, config/aarch64/aarch64.c
8473 (aarch64_sve_prepare_conditional_op): Remove.
8474 * config/aarch64/aarch64-sve.md (cond_<SVE_INT_BINARY><SVE_I>):
8475 Allow aarch64_simd_reg_or_zero as select operand; remove
8476 the aarch64_sve_prepare_conditional_op call.
8477 (cond_<SVE_INT_BINARY_SD><SVE_SDI>): Likewise.
8478 (cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
8479 (*cond_<SVE_INT_BINARY><SVE_I>_z): New pattern.
8480 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_z): New pattern.
8481 (*cond_<SVE_COND_FP_BINARY><SVE_F>_z): New pattern.
8482 (*cond_<SVE_INT_BINARY><SVE_I>_any): New pattern.
8483 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_any): New pattern.
8484 (*cond_<SVE_COND_FP_BINARY><SVE_F>_any): New pattern
8485 and a splitters to match all of the *_any patterns.
8486 * config/aarch64/predicates.md (aarch64_sve_any_binary_operator): New.
8488 * config/aarch64/iterators.md (SVE_INT_BINARY_REV): Remove.
8489 (SVE_COND_FP_BINARY_REV): Remove.
8490 (sve_int_op_rev, sve_fp_op_rev): New.
8491 * config/aarch64/aarch64-sve.md (*cond_<SVE_INT_BINARY><SVE_I>_0): New.
8492 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_0): New.
8493 (*cond_<SVE_COND_FP_BINARY><SVE_F>_0): New.
8494 (*cond_<SVE_INT_BINARY><SVE_I>_2): Rename, add movprfx alternative.
8495 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_2): Similarly.
8496 (*cond_<SVE_COND_FP_BINARY><SVE_F>_2): Similarly.
8497 (*cond_<SVE_INT_BINARY><SVE_I>_3): Similarly; use sve_int_op_rev.
8498 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_3): Similarly.
8499 (*cond_<SVE_COND_FP_BINARY><SVE_F>_3): Similarly; use sve_fp_op_rev.
8501 * config/aarch64/aarch64-sve.md (cond_<SVE_COND_FP_BINARY><SVE_F>):
8502 Remove match_dup 1 from the inner unspec.
8503 (*cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
8505 * config/aarch64/aarch64.md (movprfx): New attr.
8506 (length): Default movprfx to 8.
8507 * config/aarch64/aarch64-sve.md (*mul<SVE_I>3): Add movprfx alt.
8508 (*madd<SVE_I>, *msub<SVE_I): Likewise.
8509 (*<su>mul<SVE_I>3_highpart): Likewise.
8510 (*<SVE_INT_BINARY_SD><SVE_SDI>3): Likewise.
8511 (*v<ASHIFT><SVE_I>3): Likewise.
8512 (*<su><MAXMIN><SVE_I>3): Likewise.
8513 (*<su><MAXMIN><SVE_F>3): Likewise.
8514 (*fma<SVE_F>4, *fnma<SVE_F>4): Likewise.
8515 (*fms<SVE_F>4, *fnms<SVE_F>4): Likewise.
8516 (*div<SVE_F>4): Likewise.
8518 2018-07-02 Richard Sandiford <richard.sandiford@arm.com>
8520 * tree-vect-patterns.c (vect_recog_widen_shift_pattern): Fix typo
8523 2018-07-02 Richard Biener <rguenther@suse.de>
8525 PR tree-optimization/86363
8526 * tree-ssa-sccvn.c (vn_reference_lookup_3): Check the
8527 memset argument refers to a non-variable address.
8529 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
8531 * tree-vrp.c (extract_range_from_binary_expr_1): Abstract a lot of the
8532 {PLUS,MINUS}_EXPR code to...
8533 (adjust_symbolic_bound): ...here,
8534 (combine_bound): ...here,
8535 (set_value_range_with_overflow): ...and here.
8537 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
8539 * tree-vrp.c (extract_range_from_unary_expr): Abstract ABS_EXPR
8541 (extract_range_from_abs_expr): ...here.
8543 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
8545 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
8546 -fno-omit-frame-pointer when not optimizing.
8548 2018-07-02 Martin Liska <mliska@suse.cz>
8551 * ipa-pure-const.c (malloc_candidate_p): Revert usage of ::get.
8552 (propagate_nothrow): Likewise.
8554 2018-07-02 Martin Liska <mliska@suse.cz>
8557 * ipa-inline.c (early_inliner): Revert wrongly added ::get call.
8559 2018-07-02 David Malcolm <dmalcolm@redhat.com>
8561 * dumpfile.c (dump_generic_expr_loc): Undo removal of this
8562 function in r262149, changing "loc" param from source_location to
8563 const dump_location_t &.
8564 * dumpfile.h (dump_generic_expr_loc): Undo removal of this
8565 declaration, as above.
8567 2018-07-01 Paul Koning <ni1d@arrl.net>
8569 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
8570 -munit-asm, -mgnu-asm, -mdec-asm.
8571 * config/pdp11/pdp11-protos.h (pdp11_gen_int_label): New.
8572 (pdp11_output_labelref): New.
8573 (pdp11_output_def): New.
8574 (pdp11_output_addr_vec_elt): New.
8575 * config/pdp11/pdp11.c: Use tab between opcode and operands. Use
8576 %# and %@ format codes.
8577 (pdp11_option_override): New.
8578 (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Define.
8579 (pdp11_output_ident): New.
8580 (pdp11_asm_named_section): New.
8581 (pdp11_asm_init_sections): New.
8582 (pdp11_file_start): New.
8583 (pdp11_file_end): New.
8584 (output_ascii): Use .ascii/.asciz for -mdec-asm.
8585 (pdp11_asm_print_operand): Update %# and %$ for -mdec-asm. Add
8586 %o, like %c but octal.
8587 (pdp11_option_override): New.
8588 * config/pdp11/pdp11.h (TEXT_SECTION_ASM_OP): Update for
8590 (DATA_SECTION_ASM_OP): Ditto.
8591 (READONLY_DATA_SECTION_ASM_OP): New.
8592 (IS_ASM_LOGICAL_LINE_SEPARATOR): New.
8593 (ASM_GENERATE_INTERNAL_LABEL): Use new function.
8594 (ASM_OUTPUT_LABELREF): Ditto.
8595 (ASM_OUTPUT_DEF): Ditto.
8596 (ASM_OUTPUT_EXTERNAL): New.
8597 (ASM_OUTPUT_SOURCE_FILENAME): New.
8598 (ASM_OUTPUT_ADDR_VEC_ELT): Use new function.
8599 (ASM_OUTPUT_SKIP): Update for -mdec-asm.
8600 * config/pdp11/pdp11.md: Use tab between opcode and operands. Use
8601 %# and %@ format codes.
8602 * config/pdp11/pdp11.opt (mgnu-asm): New.
8603 (mdec-asm): Conflicts with -mgnu-asm and -munix-asm.
8604 (munix-asm): Conflicts with -mdec-asm and -mgnu-asm.
8605 * doc/invoke.txt (PDP-11 Options): Add -mgnu-asm.
8607 2018-07-01 Aldy Hernandez <aldyh@redhat.com>
8609 * tree-ssa-threadupdate.c (mark_threaded_blocks): Avoid
8610 dereferencing path[] beyond its length.
8612 (debug_all_paths): New.
8613 (rewire_first_differing_edge): New.
8614 (adjust_paths_after_duplication): New.
8615 (duplicate_thread_path): Call adjust_paths_after_duplication.
8617 (thread_through_all_blocks): Add new argument to
8618 duplicate_thread_path.
8620 2018-06-30 Jim Wilson <jimw@sifive.com>
8622 * config/riscv/predicates.md (p2m1_shift_operand): New.
8623 (high_mask_shift_operand): New.
8624 * config/riscv/riscv.md (lshrsi3_zero_extend_3+1): New combiner
8625 pattern using p2m1_shift_operand.
8626 (lshsi3_zero_extend_3+2): New combiner pattern using
8627 high_mask_shift_operand.
8629 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
8631 * tree-vect-patterns.c (vect_get_external_def_edge): New function,
8633 (vect_recog_rotate_pattern): ...here.
8634 (vect_convert_input): Try to insert casts of invariants in the
8636 * tree-vect-loop-manip.c (vect_loop_versioning): Don't require the
8637 preheader to be empty.
8639 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
8641 * tree-vect-patterns.c (append_pattern_def_seq): Take an optional
8642 vector type. If given, install it in the new statement's
8644 (vect_element_precision): New function.
8645 (vect_unpromoted_value): New struct.
8646 (vect_unpromoted_value::vect_unpromoted_value): New function.
8647 (vect_unpromoted_value::set_op): Likewise.
8648 (vect_look_through_possible_promotion): Likewise.
8649 (vect_joust_widened_integer, vect_joust_widened_type): Likewise.
8650 (vect_widened_op_tree, vect_convert_input): Likewise.
8651 (vect_convert_inputs, vect_convert_output): Likewise.
8652 (vect_recog_dot_prod_pattern): Use vect_look_through_possible_promotion
8653 to handle the optional cast of the multiplication result and
8654 vect_widened_op_tree to detect the widened multiplication itself.
8655 Do not require the input and output of promotion casts to have
8656 the same sign, but base the signedness of the operation on the
8657 input rather than the result. If the pattern includes two
8658 promotions, check that those promotions have the same sign.
8659 Do not restrict the MULT_EXPR handling to a double-width result;
8660 handle quadruple-width results and wider. Use vect_convert_inputs
8661 to convert the inputs to the common type.
8662 (vect_recog_sad_pattern): Use vect_look_through_possible_promotion
8663 to handle the optional cast of the ABS result. Also allow a sign
8664 change or a sign extension between the ABS and MINUS.
8665 Use vect_widened_op_tree to detect the widened subtraction and use
8666 vect_convert_inputs to convert the inputs to the common type.
8667 (vect_handle_widen_op_by_const): Delete.
8668 (vect_recog_widen_op_pattern): New function.
8669 (vect_recog_widen_mult_pattern): Use it.
8670 (vect_recog_widen_shift_pattern): Likewise.
8671 (vect_recog_widen_sum_pattern): Use
8672 vect_look_through_possible_promotion to handle the promoted
8675 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
8677 * gimple-iterator.c (gsi_for_stmt): Add a new overload that takes
8678 the containing gimple_seq *.
8679 * gimple-iterator.h (gsi_for_stmt): Declare it.
8680 * tree-vect-patterns.c (vect_recog_dot_prod_pattern)
8681 (vect_recog_sad_pattern, vect_recog_widen_sum_pattern)
8682 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
8683 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
8684 (vect_recog_mask_conversion_pattern): Remove STMT_VINFO_IN_PATTERN_P
8686 (vect_init_pattern_stmt, vect_set_pattern_stmt): New functions,
8688 (vect_mark_pattern_stmts): ...here. Handle cases in which the
8689 statement being replaced is part of an existing pattern
8690 definition sequence, inserting the new pattern statements before
8692 (vect_pattern_recog_1): Don't return a bool. If the statement
8693 is already part of a pattern, instead apply pattern matching
8694 to the pattern definition statements. Don't clear the
8695 STMT_VINFO_RELATED_STMT if is_pattern_stmt_p.
8696 (vect_pattern_recog): Don't break after the first match;
8697 continue processing the pattern definition statements instead.
8698 Don't bail out for STMT_VINFO_IN_PATTERN_P here.
8700 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
8702 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
8703 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
8704 (vect_recog_widen_sum_pattern): Use it.
8706 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
8708 * tree-vect-loop.c (vectorizable_reduction): Assert that the
8709 phi is not a pattern statement and has not been replaced by
8710 a pattern statement.
8711 * tree-vect-patterns.c (type_conversion_p): Don't check
8712 STMT_VINFO_IN_PATTERN_P.
8713 (vect_recog_vector_vector_shift_pattern): Likewise.
8714 (vect_recog_dot_prod_pattern): Expect vect_is_simple_use to return
8715 the pattern statement rather than the original statement; check
8716 directly for a WIDEN_MULT_EXPR here.
8717 * tree-vect-slp.c (vect_get_and_check_slp_defs): Expect
8718 vect_is_simple_use to return the pattern statement rather
8719 than the original statement; use is_pattern_stmt_p to check
8720 for such a pattern statement.
8721 * tree-vect-stmts.c (process_use): Expect vect_is_simple_use
8722 to return the pattern statement rather than the original statement;
8723 don't do the same transformation here.
8724 (vect_is_simple_use): If the defining statement has been replaced
8725 by a pattern statement, return the pattern statement instead.
8726 Remove the corresponding (local) transformation from the vectype
8729 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
8731 * tree-vectorizer.h (vect_is_simple_use): Move the gimple ** to the
8732 end and default to null.
8733 * tree-vect-loop.c (vect_create_epilog_for_reduction)
8734 (vectorizable_reduction): Update calls accordingly, dropping the
8735 gimple ** argument if the passed-back statement isn't needed.
8736 * tree-vect-patterns.c (vect_get_internal_def, type_conversion_p)
8737 (vect_recog_rotate_pattern): Likewise.
8738 (vect_recog_mask_conversion_pattern): Likewise.
8739 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
8740 (vect_mask_constant_operand_p): Likewise.
8741 * tree-vect-stmts.c (is_simple_and_all_uses_invariant, process_use):
8742 (vect_model_simple_cost, vect_get_vec_def_for_operand): Likewise.
8743 (get_group_load_store_type, get_load_store_type): Likewise.
8744 (vect_check_load_store_mask, vect_check_store_rhs): Likewise.
8745 (vectorizable_call, vectorizable_simd_clone_call): Likewise.
8746 (vectorizable_conversion, vectorizable_assignment): Likewise.
8747 (vectorizable_shift, vectorizable_operation): Likewise.
8748 (vectorizable_store, vect_is_simple_cond): Likewise.
8749 (vectorizable_condition, vectorizable_comparison): Likewise.
8750 (get_same_sized_vectype, vect_get_mask_type_for_stmt): Likewise.
8751 (vect_is_simple_use): Rename the def_stmt argument to def_stmt_out
8752 and move it to the end. Cope with null def_stmt_outs.
8754 2018-06-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
8756 * Makefile.in (FLAGS_TO_PASS): Add RANLIB_FOR_TARGET.
8758 2018-06-29 Jeff Law <law@redhat.com>
8760 * config/v850/v850.c (v850_legitimate_address_p): Handle large
8761 displacements for TARGET_V850E2V3 and newer.
8762 (TARGET_LRA_P): Remove. Defaults to LRA now.
8763 * config/v850/v850.md (sign23byte_load): Remove.
8764 (unsign23byte_load, sign23hword_load, unsign23hword_load): Likewise.
8765 (23word_load, 23byte_store, 23hword_store, 23word_store): Likewise.
8767 2018-06-29 Martin Liska <mliska@suse.cz>
8770 * coverage.c (coverage_init): Mangle full path name.
8771 * doc/invoke.texi: Document the change.
8772 * gcov-io.c (mangle_path): New.
8773 * gcov-io.h (mangle_path): Likewise.
8774 * gcov.c (mangle_name): Use mangle_path for path mangling.
8776 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
8778 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
8779 if starting source register is not even.
8781 2018-06-29 Martin Liska <mliska@suse.cz>
8783 PR tree-optimization/86263
8784 * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
8785 Make edge redirection.
8787 2018-06-29 David Malcolm <dmalcolm@redhat.com>
8789 * dumpfile.c (dump_loc): Add indentation based on scope depth.
8790 (dump_scope_depth): New variable.
8791 (get_dump_scope_depth): New function.
8792 (dump_begin_scope): New function.
8793 (dump_end_scope): New function.
8794 * dumpfile.h (get_dump_scope_depth): New declaration.
8795 (dump_begin_scope): New declaration.
8796 (dump_end_scope): New declaration.
8797 (class auto_dump_scope): New class.
8798 (AUTO_DUMP_SCOPE): New macro.
8799 * tree-vectorizer.h (DUMP_VECT_SCOPE): Reimplement in terms of
8802 2018-06-29 Richard Biener <rguenther@suse.de>
8804 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Assert
8805 compute_all_dependences succeeds.
8806 * tree-vect-loop.c (vect_get_datarefs_in_loop): Fail early if we
8807 exceed --param loop-max-datarefs-for-datadeps.
8809 2018-06-29 Jakub Jelinek <jakub@redhat.com>
8811 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
8813 2018-06-28 Uros Bizjak <ubizjak@gmail.com>
8816 * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): Use
8817 alternative 0 in preferred_for_speed attribute.
8819 2018-06-28 Paul Koning <ni1d@arrl.net>
8821 * config/pdp11/pdp11-protos.h (pdp11_shift_length): New function.
8822 * config/pdp11/pdp11.c (pdp11_shift_length): New function.
8823 * config/pdp11/pdp11.h (ADJUST_INSN_LENGTH): Remove.
8824 * config/pdp11/pdp11.md: Correct "length" attribute calculation
8825 for shift insn patterns.
8827 2018-06-28 David Malcolm <dmalcolm@redhat.com>
8829 * cgraph.c (cgraph_node::get_body): Replace assignments to
8830 "dump_file" with calls to set_dump_file.
8831 * dumpfile.c (alt_dump_file): Make static, and group with...
8832 (alt_flags): ...this definition.
8833 (dumps_are_enabled): New variable.
8834 (refresh_dumps_are_enabled): New function.
8835 (set_dump_file): New function.
8836 (set_alt_dump_file): New function.
8837 (gcc::dump_manager::dump_start): Replace assignments to
8838 "dump_file" and "alt_dump_file" with calls to set_dump_file and
8840 (gcc::dump_manager::dump_finish): Likewise.
8841 * dumpfile.h (alt_dump_file): Delete decl.
8842 (dumps_are_enabled): New variable decl.
8843 (set_dump_file): New function decl.
8844 (dump_enabled_p): Rewrite in terms of new "dumps_are_enabled"
8846 * tree-nested.c (lower_nested_functions): Replace assignments to
8847 "dump_file" with calls to set_dump_file.
8849 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
8851 * tree-cfg.c (verify_gimple_in_cfg): Call verify_location on the
8852 goto_locus of each outgoing edge of each basic block.
8854 2018-06-28 Richard Biener <rguenther@suse.de>
8856 * dwarf2out.c (decl_scope_table): Remove.
8857 (push_decl_scope): Likewise.
8858 (pop_decl_scope): Likewise.
8859 (gen_type_die_for_member): Do not call push/pop_decl_scope.
8860 (gen_struct_or_union_type_die): Likewise.
8861 (gen_tagged_type_die): Likewise.
8862 (dwarf2out_init): Do not initialize decl_scope_table.
8863 (dwarf2out_c_finalize): Do not free it.
8865 2018-06-28 Richard Biener <rguenther@suse.de>
8867 * dwarf2out.c (gen_subprogram_die): Use is_unit_die when
8868 deciding whether to not re-use a DIE.
8870 2018-06-28 Richard Biener <rguenther@suse.de>
8872 * dwarf2out.c (gen_subprogram_die): Always re-use DIEs with an
8873 DW_AT_abstract_origin attribute.
8875 2018-06-28 Martin Liska <mliska@suse.cz>
8877 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
8878 Use newly introduced constants.
8879 * tree-switch-conversion.h (struct jump_table_cluster):
8880 Define max_ratio_for_size and max_ratio_for_speed.
8882 2018-06-28 Martin Liska <mliska@suse.cz>
8884 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
8885 Add new checking assert to catch invalid state.
8886 (jump_table_cluster::can_be_handled): Handle single case
8888 (jump_table_cluster::is_beneficial): Bail out for such case.
8889 (bit_test_cluster::find_bit_tests):
8890 Add new checking assert to catch invalid state.
8891 (bit_test_cluster::can_be_handled): Handle single case
8893 (bit_test_cluster::is_beneficial): Bail out for such case.
8894 (switch_decision_tree::analyze_switch_statement):
8897 2018-06-28 Martin Liska <mliska@suse.cz>
8899 * common.opt: Introduce -completion option.
8900 * gcc.c (driver_handle_option): Handle it.
8901 (driver::main): Print completions if completion
8903 * opt-suggestions.c (option_proposer::get_completions):
8905 (option_proposer::suggest_completion): Likewise.
8906 (option_proposer::find_param_completions): Likewise.
8907 (verify_autocompletions): Likewise.
8908 (test_completion_valid_options): Likewise.
8909 (test_completion_valid_params): Likewise.
8910 (in_completion_p): Likewise.
8911 (empty_completion_p): Likewise.
8912 (test_completion_partial_match): Likewise.
8913 (test_completion_garbage): Likewise.
8914 (opt_proposer_c_tests): Likewise.
8915 * opt-suggestions.h: Declare new functions.
8916 * opts.c (common_handle_option): Handle OPT__completion_.
8917 * selftest-run-tests.c (selftest::run_tests): Add
8918 opt_proposer_c_tests.
8919 * selftest.c (assert_str_startswith): New.
8920 * selftest.h (assert_str_startswith): Likewise.
8921 (opt_proposer_c_tests): New.
8922 (ASSERT_STR_STARTSWITH): Likewise.
8924 2018-06-28 Martin Liska <mliska@suse.cz>
8926 * Makefile.in: Add opt-suggestions.o.
8927 * gcc-main.c: Include opt-suggestions.h.
8928 * gcc.c (driver::driver): Likewise.
8929 (driver::~driver): Remove m_option_suggestions.
8930 (driver::build_option_suggestions): Moved to option_proposer.
8931 (driver::suggest_option): Likewise.
8932 (driver::handle_unrecognized_options): Use option_proposer.
8933 * gcc.h (class driver): Add new memver m_option_proposer.
8934 * opt-suggestions.c: New file.
8935 * opt-suggestions.h: New file.
8937 2018-06-28 Martin Liska <mliska@suse.cz>
8939 * vec.h (class auto_string_vec): New (moved from auto_argvec).
8940 (auto_string_vec::~auto_string_vec): Likewise.
8942 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
8944 * tree-inline.h (struct copy_body_data): Move remapping_type_depth and
8945 prevent_decl_creation_for_types fields up and add reset_location field.
8946 * tree-inline.c (remap_gimple_stmt): Force input_location on the new
8947 statement if id->reset_location is true.
8948 (copy_edges_for_bb): Do not set goto_locus on the new edges if
8949 id->reset_location is true.
8950 (copy_phis_for_bb): Force input_location on the arguments if
8951 id->reset_location is true.
8952 (expand_call_inline): Set id->reset_location if DECL_IGNORED_P
8953 is set on the function to be inlined.
8955 2018-06-27 Stephan Bergmann <sbergman@redhat.com>
8957 * doc/invoke.texi (Debugging Options): Add -gsplit-dwarf.
8959 2018-06-27 Dimitar Dimitrov <dimitar@dinux.eu>
8961 * lra-eliminations.c (update_reg_eliminate): Mark all spanning hard
8962 registers for Pmode.
8963 * lra-lives.c (check_pseudos_live_through_calls): Mark all spanning
8964 hard registers for the clobbered pseudo.
8966 2018-06-27 Paul Koning <ni1d@arrl.net>
8968 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
8969 mutually exclusive options.
8970 * config/pdp11/constraints.md (h): New constraint.
8971 (O): Update definition to match shift code generation.
8972 (D): New constraint.
8973 * config/pdp11/pdp11-modes.def (CCNZ): Define mode.
8975 * config/pdp11/pdp11-protos.h (int_no_side_effect_operand): New
8977 (output_jump): Change arguments.
8978 (pdp11_fixed_cc_regs): New function.
8979 (pdp11_cc_mode): Ditto.
8980 (pdp11_expand_shift): Ditto.
8981 (pdp11_assemble_shift): Ditto.
8982 (pdp11_small_shift): Ditto.
8983 (pdp11_branch_cost): Remove.
8984 * config/pdp11/pdp11.c (pdp11_assemble_integer): Remove comments
8986 (pdp11_register_move_cost): Update for CC registers.
8987 (pdp11_rtx_costs): Add case for LSHIFTRT.
8988 (pdp11_output_jump): Add CCNZ mode conditional branches.
8989 (notice_update_cc_on_set): Remove.
8990 (pdp11_cc_mode): New function.
8991 (simple_memory_operand): Correct pre/post decrement case.
8992 (no_side_effect_operand): New function.
8993 (pdp11_regno_reg_class): Add CC_REGS class.
8994 (pdp11_fixed_cc_regs): New function.
8995 (pdp11_small_shift): New function.
8996 (pdp11_expand_shift): New function to expand shift insns.
8997 (pdp11_assemble_shift): New function to output shifts.
8998 (pdp11_branch_cost): Remove.
8999 (pdp11_modes_tieable_p): Make QI/HI modes tieable.
9000 * config/pdp11/pdp11.h (SIZE_TYPE): Ensure 16-bit type.
9001 (WCHAR_TYPE): Ditto.
9002 (PTRDIFF_TYPE): Ditto.
9003 (ADJUST_INSN_LENGTH): New macro.
9004 (FIXED_REGISTERS): Add CC registers.
9005 (CALL_USED_REGISTERS): Ditto.
9007 (REG_CLASS_NAMES): Ditto.
9008 (REG_CLASS_CONTENTS): Ditto.
9009 (SELECT_CC_MODE): Use new function.
9010 (TARGET_FLAGS_REGNUM): New macro.
9011 (TARGET_FIXED_CONDITION_CODE_REGS): Ditto.
9012 (cc0_reg_rtx): Remove.
9013 (CC_STATUS_MDEP): Remove.
9014 (CC_STATUS_MDEFP_INIT): Remove.
9015 (CC_IN_FPU): Remove.
9016 (NOTICE_UPDATE_CC): Remove.
9017 (REGISTER_NAMES): Add CC registers.
9018 (BRANCH_COST): Change to constant 1.
9019 * config/pdp11/pdp11.md: Rewrite for CCmode condition code
9021 * config/pdp11/pdp11.opt (mbcopy): Remove.
9022 (mbcopy-builtin): Remove.
9023 (mbranch-cheap): Remove.
9024 (mbranch-expensive): Remove.
9025 * config/pdp11/predicates.md (expand_shift_operand): Update to
9026 match shift code generation.
9027 (ccnz_operator): New predicate.
9028 * doc/invoke.texi (PDP-11 Options): Remove deleted options
9029 -mbcopy, -mbcopy-builtin, -mbranch-cheap, -mbranch-expensive.
9030 Remove non-existent option -mabshi, -mno-abshi. Document mutually
9032 * doc/md.texi (PDP-11): Document new D and h constraints. Update
9033 description of O constraint.
9035 2018-06-27 Jeff Law <law@redhat.com>
9036 Austin Law <austinklaw@gmail.com>
9038 * config/v850/v850.md (addsi3_set_flags): New pattern.
9039 (subsi3_set_flags, negsi2_set_flags, andsi3_set_flags): Likewise.
9040 (iorsi3_set_flags, xorsi3_set_flags, one_cmplsi2_set_flags): Likewise.
9041 (zero_extendhisi2_v850_set_flags): Likewise.
9042 (zero_extendqisi2_v850_set_flags): Likewise.
9043 (ashlsi3_set_flags, ashlsi3_v850e2_set_flags): Likewise.
9044 (lshrsi3_set_flags, lshrsi3_v850e2_set_flags): Likewise.
9045 (ashrsi3_set_flags, ashrsi3_v850e2_set_flags): Likewise.
9047 * config/v850/v850-protos.h (notice_update_cc): Remove.
9048 * config/v850/v850.c (v850_compare_op0, v850_compare_op1): Remove.
9049 (v850_print_operand): Handle 'D' and "d".
9050 (v850_select_cc_mode): Remove ATTRIBUTE_UNUSED for last argument.
9051 Add handling of arithmetic/logical operations compared against zero.
9052 (v850_gen_float_compare): Remove ATTRIBUTE_UNUSED for last argument.
9053 Do not look at v850_compare_op, instead get mode from last argument.
9054 (v850_gen_compare): Remove
9055 (increment_stack): Use addsi3_clobber_flags to avoid splitting failure
9056 after reload for prologue insns.
9057 (expand_prologue): Account for CLOBBER of CC_REGNUM in various
9059 (construct_save_jarl): Likewise.
9060 (TARGET_FLAGS_REGNUM): Define.
9061 * config/v850/v850.h (v850_compare_op0, v850_compare_op1): Remove.
9062 (NOTICE_UPDATE_CC): Remove.
9063 * config/v850/v850.md (v850_tst1): Use (reg:CCZ CC_REGNUM) rather
9064 than cc0. Conditionalize on reload_completed.
9065 (cmpsi_insn, setfcc_insn): Likewise.
9066 (tst1 splitter): Turn into define_and_split which sets the flags
9068 (cstoresi4, cbranchsf4, cbranchdf4, cbranchsi4_insn): Likewise.
9069 (cbranchsi4, branch_normal, branch_invert): Do not expose cc0 here.
9070 (cstoresf4, cstoredf4): Clobber the flags.
9071 (cmpsi, cmpsf, cmpdf): Remove expanders.
9072 (setf_insn): Remove pattern.
9073 (addsi3): Turn into define_and_split which clobbers the flags after
9074 reload and a suitable pattern (addsi3_clobber_flags) for use after
9076 (subsi3, negsi2, andsi3, iorsi3, xorsi3, one_cmplsi2) Likewise.
9077 (ashlsi3, ashlsi3_v850e2, lshrsi3, lsh4si3_v850e2): Likewise.
9078 (ashrsi3, ashrsi3_v850e2): Likewise.
9079 (bins): Clobber the flags.
9080 (movsicc_normal_cc, movsicc_normal, movsicc_tst1): Likewise.
9081 (movsicc_tst1_revesed, sasf, swap and rotate patterns): Likewise.
9082 (fix_loop_counter, call_internal_short, call_internal_long): Likewise.
9083 (call_value_internal_short, call_value_internal_long): Likewise.
9084 (callt_save_interrupt, callt_return_interrupt): Likewise.
9085 (save_interrupt, return_interrupt): Likewise.
9086 (callt_save_all_interrupt, save_all_interrupt): Likewise.
9087 (_save_all_interrupt, callt_restore_all_interrupt): Likewise.
9088 (restore_all_interrupt, _restore_all_interrupt): Likewise.
9089 (All FP comparisons): Only allow after reload has completed.
9091 (divh, divhu): Tweak output template.
9092 (branch_z_normal, branch_z_invert): Remove
9093 (branch_nz_normal, branch_nz_invert): Likewise.
9094 (extendhisi_insn, extendqisi_insn): Do not clobber flags.
9096 * config/v850/v850-modes.def (CCZ, CCNZ): Add new modes.
9097 * config/v850/v850.c (notice_update_cc): Remove.
9098 * config/v850/v850.h (CC_OVERFLOW_UNUSABLE): Remove
9099 (CC_NO_CARRY): Likewise.
9100 (NOTICE_UPDATE_CC): Define to nothing.
9101 * config/v850/v850.md: Remove block comment on cc0 handling
9102 Remove "cc" attribute from all patterns. Remove cc_status handling
9103 from all patterns. Minor formatting fixes.
9105 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
9107 * config/aarch64/aarch64-cores.def (cortex-a76): New entry.
9108 (cortex-a76.cortex-a55): Likewise.
9109 * config/aarch64/aarch64-tune.md: Regenerate.
9110 * doc/invoke.texi (AArch64 Options): Document cortex-a76 and
9111 cortex-a76.cortex-a55.
9113 2018-06-27 Jeff Law <law@redhat.com>
9115 * config/v850/t-v850 (MULTILIB_OPTIONS): Remove 8byte-align.
9116 (MULTILIB_DIRNAMES): Similarly.
9118 2018-06-27 Eric Botcazou <ebotcazou@adacore.com>
9120 * gimple.h (gimple_return_retbnd): Delete.
9121 (gimple_return_set_retbnd): Likewise.
9122 * cgraphunit.c (cgraph_node::expand_thunk): Remove call to
9123 gimple_return_set_retbnd.
9124 * gimple-pretty-print.c (dump_gimple_return): Remove call to
9125 gimple_return_retbnd and adjust.
9126 * tree-inline.h (struct copy_body_data): Remove retbnd field.
9127 * tree-inline.c (remap_gimple_stmt): Remove handling of retbnd.
9128 Explicitly return NULL in a couple more cases. Move assertion
9129 on debug statements and remove unreachable code.
9130 (reset_debug_binding): Do not test id->retbnd.
9131 (expand_call_inline): Do not set it.
9133 2018-06-27 Rasmus Villemoes <rv@rasmusvillemoes.dk>
9135 * configure.ac: Add --disable-gcov option.
9136 * configure: Regenerate.
9137 * Makefile.in: Honour @enable_gcov@.
9138 * doc/install.texi: Document --disable-gcov.
9140 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
9142 * config/arm/arm-cpus.in (cortex-a76): New entry.
9143 (cortex-a76.cortex-a55): Likewise.
9144 * config/arm/arm-tables.opt: Regenerate.
9145 * config/arm/arm-tune.md: Likewise.
9146 * config/arm/driver-arm.c (arm_cpu_table): Add Cortex-A76 entry.
9147 * doc/invoke.texi (ARM Options): Document cortex-a76 and
9148 cortex-a76.cortex-a55.
9150 2018-06-27 Tamar Christina <tamar.christina@arm.com>
9153 * config/aarch64/aarch64.md (*movhf_aarch64): Add dup v0.4h pattern.
9155 2018-06-27 Siddhesh Poyarekar <siddhesh@sourceware.org>
9157 * config/aarch64/aarch64.h (CALL_USE_REGISTERS): Fix obsolete
9159 (EPILOGUE_USES): Likewise.
9161 2018-06-26 Eric Botcazou <ebotcazou@adacore.com>
9163 * tree-inline.c (remap_location): New function extracted from...
9164 (copy_edges_for_bb): Add ID parameter. Remap goto_locus.
9165 (copy_phis_for_bb): ...here. Call remap_location.
9166 (copy_cfg_body): Adjust call to copy_edges_for_bb.
9168 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
9170 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
9171 unaligned vsx for 16B memset.
9173 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
9176 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
9177 ieee128_float_type_node to long_double_type_node unless
9178 TARGET_LONG_DOUBLE_128 is set.
9180 2018-06-26 David Malcolm <dmalcolm@redhat.com>
9182 * cfgloop.c (get_loop_location): Convert return type from
9183 location_t to dump_user_location_t, replacing INSN_LOCATION lookups
9184 by implicit construction from rtx_insn *, and using
9185 dump_user_location_t::from_function_decl for the fallback case.
9186 * cfgloop.h (get_loop_location): Convert return type from
9187 location_t to dump_user_location_t.
9188 * cgraphunit.c (walk_polymorphic_call_targets): Update call to
9189 dump_printf_loc to pass in a dump_location_t rather than a
9190 location_t, via the gimple stmt.
9191 * coverage.c (get_coverage_counts): Update calls to
9192 dump_printf_loc to pass in dump_location_t rather than a
9194 * doc/optinfo.texi (Dump types): Convert example of
9195 dump_printf_loc from taking "locus" to taking "insn". Update
9196 description of the "_loc" calls to cover dump_location_t.
9197 * dumpfile.c: Include "backend.h", "gimple.h", "rtl.h", and
9199 (dump_user_location_t::dump_user_location_t): New constructors,
9200 from gimple *stmt and rtx_insn *.
9201 (dump_user_location_t::from_function_decl): New function.
9202 (dump_loc): Make static.
9203 (dump_gimple_stmt_loc): Convert param "loc" from location_t to
9204 const dump_location_t &.
9205 (dump_generic_expr_loc): Delete.
9206 (dump_printf_loc): Convert param "loc" from location_t to
9207 const dump_location_t &.
9208 (selftest::test_impl_location): New function.
9209 (selftest::dumpfile_c_tests): New function.
9210 * dumpfile.h: Include "profile-count.h".
9211 (class dump_user_location_t): New class.
9212 (struct dump_impl_location_t): New struct.
9213 (class dump_location_t): New class.
9214 (dump_printf_loc): Convert 2nd param from source_location to
9215 const dump_location_t &.
9216 (dump_generic_expr_loc): Delete.
9217 (dump_gimple_stmt_loc): Convert 2nd param from source_location to
9218 const dump_location_t &.
9219 * gimple-fold.c (fold_gimple_assign): Update call to
9220 dump_printf_loc to pass in a dump_location_t rather than a
9221 location_t, via the gimple stmt.
9222 (gimple_fold_call): Likewise.
9223 * gimple-loop-interchange.cc
9224 (loop_cand::analyze_iloop_reduction_var): Update for change to
9225 check_reduction_path.
9226 (tree_loop_interchange::interchange): Update for change to
9228 * graphite-isl-ast-to-gimple.c (scop_to_isl_ast): Update for
9229 change in return-type of find_loop_location.
9230 (graphite_regenerate_ast_isl): Likewise.
9231 * graphite-optimize-isl.c (optimize_isl): Likewise.
9232 * graphite.c (graphite_transform_loops): Likewise.
9233 * ipa-devirt.c (ipa_devirt): Update call to dump_printf_loc to
9234 pass in a dump_location_t rather than a location_t, via the
9236 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
9237 * ipa.c (walk_polymorphic_call_targets): Likewise.
9238 * loop-unroll.c (report_unroll): Convert "locus" param from
9239 location_t to dump_location_t.
9240 (decide_unrolling): Update for change to get_loop_location's
9242 * omp-grid.c (struct grid_prop): Convert field "target_loc" from
9243 location_t to dump_user_location_t.
9244 (grid_find_single_omp_among_assignments_1): Updates calls to
9245 dump_printf_loc to pass in a dump_location_t rather than a
9246 location_t, via the gimple stmt.
9247 (grid_parallel_clauses_gridifiable): Convert "tloc" from
9248 location_t to dump_location_t. Updates calls to dump_printf_loc
9249 to pass in a dump_location_t rather than a location_t, via the
9251 (grid_inner_loop_gridifiable_p): Likewise.
9252 (grid_dist_follows_simple_pattern): Likewise.
9253 (grid_gfor_follows_tiling_pattern): Likewise.
9254 (grid_target_follows_gridifiable_pattern): Likewise.
9255 (grid_attempt_target_gridification): Convert initialization
9256 of local "grid" from memset to zero-initialization; FIXME: does
9257 this require C++11? Update call to dump_printf_loc to pass in a
9258 optinfo_location rather than a location_t, via the gimple stmt.
9259 * profile.c (read_profile_edge_counts): Updates call to
9260 dump_printf_loc to pass in a dump_location_t rather than a
9262 (compute_branch_probabilities): Likewise.
9263 * selftest-run-tests.c (selftest::run_tests): Call
9265 * selftest.h (dumpfile_c_tests): New decl.
9266 * tree-loop-distribution.c (pass_loop_distribution::execute):
9267 Update for change in return type of find_loop_location.
9268 * tree-parloops.c (parallelize_loops): Likewise.
9269 * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Convert
9270 "locus" from location_t to dump_user_location_t.
9271 (canonicalize_loop_induction_variables): Likewise.
9272 * tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_loop): Update
9273 for change in return type of find_loop_location.
9274 * tree-ssa-loop-niter.c (number_of_iterations_exit): Update call
9275 to dump_printf_loc to pass in a dump_location_t rather than a
9276 location_t, via the stmt.
9277 * tree-ssa-sccvn.c (eliminate_dom_walker::before_dom_children):
9279 * tree-vect-loop-manip.c (find_loop_location): Convert return
9280 type from source_location to dump_user_location_t.
9281 (vect_do_peeling): Update for above change.
9282 (vect_loop_versioning): Update for change in type of
9284 * tree-vect-loop.c (check_reduction_path): Convert "loc" param
9285 from location_t to dump_user_location_t.
9286 (vect_estimate_min_profitable_iters): Update for change in type
9288 * tree-vect-slp.c (vect_print_slp_tree): Convert param "loc" from
9289 location_t to dump_location_t.
9290 (vect_slp_bb): Update for change in type of vect_location.
9291 * tree-vectorizer.c (vect_location): Convert from source_location
9292 to dump_user_location_t.
9293 (try_vectorize_loop_1): Update for change in vect_location's type.
9294 (vectorize_loops): Likewise.
9295 (increase_alignment): Likewise.
9296 * tree-vectorizer.h (vect_location): Convert from source_location
9297 to dump_user_location_t.
9298 (find_loop_location): Convert return type from source_location to
9299 dump_user_location_t.
9300 (check_reduction_path): Convert 1st param from location_t to
9301 dump_user_location_t.
9302 * value-prof.c (check_counter): Update call to dump_printf_loc to
9303 pass in a dump_user_location_t rather than a location_t; update
9304 call to error_at for change in type of "locus".
9305 (check_ic_target): Update call to dump_printf_loc to
9306 pass in a dump_user_location_t rather than a location_t, via the
9309 2018-06-26 Robin Dapp <rdapp@linux.vnet.ibm.com>
9311 * config/s390/s390.h (enum processor_flags): Do not use
9312 default tune parameter when -march was specified.
9314 2018-06-26 Jakub Jelinek <jakub@redhat.com>
9317 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
9318 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
9321 2018-06-26 Richard Biener <rguenther@suse.de>
9323 PR tree-optimization/86287
9325 * tree-vect-loop.c (vect_transform_loop_stmt): Fix read-after-free.
9326 (vect_analyze_loop): Initialize n_stmts.
9328 2018-06-26 Richard Biener <rguenther@suse.de>
9331 * fold-const.c (fold_convertible_p): Pointer extension
9334 2018-06-26 Alexandre Oliva <aoliva@redhat.com>
9337 * dwarf2out.c (loc_list_has_views): Adjust comments.
9338 (dw_loc_list): Split single cross-partition range with
9341 2018-06-25 Jeff Law <law@redhat.com>
9343 * common/config/v850/v850-common.c (TARGET_DEFAULT_TARGET_FLAGS): Turn
9344 on -mbig-switch by default.
9346 * config/v850/predicates.md (const_float_1_operand): Fix match_code
9348 (const_float_0_operand): Remove unused predicate.
9349 * config/v850/v850.md (define_constants): Remove UNSPEC_LOOP.
9350 (define_c_enum unspec): Add LOOP, RCP and RSQRT constants.
9351 (recipsf2): New expander. Original pattern now called
9353 (recipdf2, recipdf2_insn): Similarly.
9354 (rsqrtsf2, rsqrtsf2_insn): Similarly
9355 (rsqrtdf2, rsqrtdf2_insn): Similarly
9357 2018-06-26 Gerald Pfeifer <gerald@pfeifer.com>
9359 * ginclude/stddef.h: Remove an obsolete comment on FreeBSD 5.
9360 Simplify logic for FreeBSD (twice).
9362 2018-06-25 Martin Sebor <msebor@redhat.com>
9364 PR tree-optimization/86204
9365 * tree-ssa-strlen.c (handle_builtin_strlen): Avoid storing
9366 a strnlen result if it's less than the length of the string.
9368 2018-06-25 Martin Sebor <msebor@redhat.com>
9370 PR tree-optimization/85700
9371 * gimple-fold.c (gimple_fold_builtin_strncat): Adjust comment.
9372 * tree-ssa-strlen.c (is_strlen_related_p): Handle integer subtraction.
9373 (maybe_diag_stxncpy_trunc): Distinguish strncat from strncpy.
9375 2018-06-25 Martin Sebor <msebor@redhat.com>
9377 * doc/extend.texi (Zero-length arrays): Update and clarify.
9379 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
9381 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
9382 added IEEE/IBM long double multilib support on PowerPC little
9383 endian Linux systems.
9384 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
9385 (MULTILIB_DEFAULTS): Likewise.
9386 * config/rs6000/rs6000.c (rs6000_option_override_internal):
9388 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
9389 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
9390 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
9392 2018-06-25 Alexander Monakov <amonakov@ispras.ru>
9395 * sort.cc (REORDER_23): Avoid memcpy with same destination and source.
9396 (REORDER_45): Likewise.
9398 2018-06-25 Jeff Law <law@redhat.com>
9400 * config/v850/v850.md (divmodhi4): Make sure to sign extend the
9401 dividend to 32 bits. Adjust length.
9402 (udivmodhi4): Cleanup output template. Fix length.
9404 2018-06-25 Carl Love <cel@us.ibm.com>
9406 * config/rs6000/vsx.md: Change word selector to prefered location.
9408 2018-06-25 Richard Biener <rguenther@suse.de>
9410 PR tree-optimization/86304
9411 * tree-vectorizer.c (vectorize_loops): Walk over new possibly
9412 epilogue-if-converted loops as well.
9414 2018-06-25 Jan Hubicka <hubicka@ucw.cz>
9416 * lto-section-out.c (lto_begin_section): Do not print section
9417 name for noaddr and unnumbered dumps.
9419 2018-06-25 Richard Biener <rguenther@suse.de>
9421 * tree-vectorizer.h (struct vec_info_shared): New structure
9422 with parts split out from struct vec_info and loop_nest from
9423 struct _loop_vec_info.
9424 (struct vec_info): Adjust accordingly.
9425 (struct _loop_vec_info): Likewise.
9426 (LOOP_VINFO_LOOP_NEST): Adjust.
9427 (LOOP_VINFO_DATAREFS): Likewise.
9428 (LOOP_VINFO_DDRS): Likewise.
9429 (struct _bb_vec_info): Likewise.
9430 (BB_VINFO_DATAREFS): Likewise.
9431 (BB_VINFO_DDRS): Likewise.
9432 (struct _stmt_vec_info): Add dr_aux member.
9433 (DR_VECT_AUX): Adjust to refer to member of DR_STMTs vinfo.
9434 (DR_MISALIGNMENT_UNINITIALIZED): New.
9435 (set_dr_misalignment): Adjust.
9436 (dr_misalignment): Assert misalign isn't DR_MISALIGNMENT_UNINITIALIZED.
9437 (vect_analyze_loop): Adjust prototype.
9438 (vect_analyze_loop_form): Likewise.
9439 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
9440 Compute dependences lazily.
9441 (vect_record_base_alignments): Use shared datarefs/ddrs.
9442 (vect_verify_datarefs_alignment): Likewise.
9443 (vect_analyze_data_refs_alignment): Likewise.
9444 (vect_analyze_data_ref_accesses): Likewise.
9445 (vect_analyze_data_refs): Likewise.
9446 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Add
9447 constructor parameter for shared part.
9448 (vect_analyze_loop_form): Pass in shared part and adjust.
9449 (vect_analyze_loop_2): Pass in storage for the number of
9450 stmts. Move loop nest finding to the caller. Compute
9452 (vect_analyze_loop): Pass in shared part.
9453 (vect_transform_loop): Verify shared datarefs are unchanged.
9454 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Add
9455 constructor parameter for shared part.
9456 (vect_slp_analyze_bb_1): Pass in shared part and adjust.
9457 (vect_slp_bb): Verify shared datarefs are unchanged before
9459 * tree-vect-stmts.c (ensure_base_align): Adjust for DR_AUX
9461 (new_stmt_vec_info): Initialize DR_AUX misalignment to
9462 DR_MISALIGNMENT_UNINITIALIZED.
9463 * tree-vectorizer.c (vec_info::vec_info): Add constructor
9464 parameter for shared part.
9465 (vec_info::~vec_info): Adjust.
9466 (vec_info_shared::vec_info_shared): New.
9467 (vec_info_shared::~vec_info_shared): Likewise.
9468 (vec_info_shared::save_datarefs): Likewise.
9469 (vec_info_shared::check_datarefs): Likewise.
9470 (try_vectorize_loop_1): Construct shared part live for analyses
9471 of a single loop for multiple vector sizes.
9472 * tree-parloops.c (gather_scalar_reductions): Adjust.
9474 2018-06-25 Richard Biener <rguenther@suse.de>
9476 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
9477 DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
9478 (vect_analyze_data_refs): Remove similar code from here and
9479 simplify accordingly.
9481 2018-06-25 Richard Biener <rguenther@suse.de>
9483 * tree-vect-data-refs.c (vect_check_gather_scatter): Fail
9484 for reverse storage order accesses rather than asserting
9485 they cannot happen here.
9487 2018-06-25 Tom de Vries <tdevries@suse.de>
9490 * config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
9491 Use data16 instead of .byte for insn prefix.
9493 2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
9496 * parser.c (make_char_string_pack): Pass this literal chars
9497 through cpp_interpret_string.
9498 (cp_parser_userdef_numeric_literal): Check the result of
9499 make_char_string_pack.
9501 2018-06-24 Maya Rashish <coypu@sdf.org>
9503 * ginclude/stddef.h: Simplify conditions around avoiding
9504 re-definition of __size_t.
9506 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
9508 * lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
9509 unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
9511 2018-06-22 Maya Rashish <coypu@sdf.org>
9513 * doc/invoke.texi (mno-fancy-math-387): Update for changes
9514 made to OpenBSD and NetBSD through the years.
9516 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
9518 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
9519 behavior of vec_pack (vector double, vector double) to match
9520 behavior of vec_float2 (vector double, vector double).
9522 2018-06-22 Olivier Hainque <hainque@adacore.com>
9524 * gimplify.c (gimplify_function_tree): Prevent creation
9525 of a trampoline for the address of the current function
9526 passed to entry/exit instrumentation hooks.
9528 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
9531 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
9534 2018-06-22 Martin Liska <mliska@suse.cz>
9536 PR tree-optimization/86263
9537 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
9538 Bail out if is_enabled is false.
9539 * tree-switch-conversion.h (jump_table_cluster::is_enabled):
9541 (jump_table_cluster::is_enabled): New function.
9543 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
9545 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
9546 BINFO_BASE_ACCESSES and BINFO_VPTR_FIELD.
9547 * tree-streamer-in.c (streamer_read_tree_bitfields): Likewise.
9548 (lto_input_ts_binfo_tree_pointers): Likewise.
9549 * tree-streamer-out.c (streamer_write_tree_bitfields,
9550 write_ts_binfo_tree_pointers): Likewise.
9551 * tree.c (free_lang_data_in_binfo): Clear BINFO_VPTR_FIELD.
9553 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
9555 * tree.c (free_lang_data_in_type): Free all TYPE_VFIELDs.
9557 2018-06-22 Martin Liska <mliska@suse.cz>
9559 * symbol-summary.h (get): Make it pure and inline move
9560 functionality from ::get function.
9561 (get): Remove and inline into ::get and ::get_create.
9562 (get_create): Move code from ::get function.
9564 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9567 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
9568 -x assembler-with-cpp.
9570 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
9572 * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define
9573 _FILE_OFFSET_BITS=64 for C++.
9575 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
9577 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
9578 conversion insn that shows up when pr85657-3.c is compiled using
9579 IEEE 128-bit long double.
9580 (neg<mode>2_internal): Use the correct mode to check whether the
9581 mode is IBM extended.
9582 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
9583 multiply and divide external functions from being created more
9586 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
9588 * cfgrtl.c (fixup_reorder_chain): Do not emit NOPs in DECL_IGNORED_P
9590 (rtl_merge_blocks): Likewise. Do not emit a NOP if the location of
9591 the edge can be forwarded.
9592 (cfg_layout_merge_blocks): Likewise.
9594 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
9596 * except.c (finish_eh_generation): Commit edge insertions only after
9597 the EH edges have been redirected from post-landing to landing pads.
9599 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
9601 * tree-nested.c (get_frame_type): Use create_tmp_var_raw instead of
9602 create_tmp_var_for to create the FRAME decl.
9603 (finalize_nesting_tree_1): Do not unchain the FRAME decl.
9605 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
9607 * tree-inline.c (copy_edges_for_bb): Minor tweak.
9608 (maybe_move_debug_stmts_to_successors): Also reset the locus of the
9609 debug statement when resetting its value.
9610 (expand_call_inline): Copy the locus of the call onto the assignment
9611 of the return value, if any. Use local variable in more cases.
9613 2018-06-21 Martin Liska <mliska@suse.cz>
9615 * ipa-pure-const.c (propagate_nothrow): Use
9616 funct_state_summaries->get.
9617 (dump_malloc_lattice): Likewise.
9618 (propagate_malloc): Likewise.
9620 2018-06-21 Richard Biener <rguenther@suse.de>
9622 * lto-streamer-out.c (DFS::DFS_write_tree_body): Update outdated
9623 comment. Follow BLOCK_ABSTRACT_ORIGIN unconditionally.
9624 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Update
9626 * tree-streamer-out.c (write_ts_block_tree_pointers): Stream
9627 BLOCK_ABSTRACT_ORIGIN unconditionally.
9629 2018-06-21 David Malcolm <dmalcolm@redhat.com>
9631 * ipa-cp.c (ipcp_driver): Set edge_clone_summaries to NULL after
9633 * ipa-reference.c (ipa_reference_c_finalize): Delete
9634 ipa_ref_opt_sum_summaries and set it to NULL.
9636 2018-06-21 Tom de Vries <tdevries@suse.de>
9638 PR tree-optimization/85859
9639 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
9640 test with comment from bb_no_side_effects_p.
9642 2018-06-21 Richard Biener <rguenther@suse.de>
9644 PR tree-optimization/86232
9645 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Adjust
9646 max for constant niter.
9648 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
9650 * config/aarch64/aarch64-simd.md
9651 (*aarch64_crypto_aes<aes_op>v16qi_xor_combine): New.
9653 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
9655 * config/aarch64/aarch64-simd.md (aarch64_crypto_aes<aes_op>v16qi):
9656 Make opernads of the unspec commutative.
9658 2018-06-21 Richard Biener <rguenther@suse.de>
9660 * tree-data-ref.c (dr_step_indicator): Handle NULL DR_STEP.
9661 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
9662 Avoid calling vect_mark_for_runtime_alias_test with gathers or scatters.
9663 (vect_analyze_data_ref_dependence): Re-order checks to deal with
9665 (vect_record_base_alignments): Do not record base alignment
9666 for gathers or scatters.
9667 (vect_compute_data_ref_alignment): Drop return value that is always
9668 true. Bail out early for gathers or scatters.
9669 (vect_enhance_data_refs_alignment): Bail out early for gathers
9671 (vect_find_same_alignment_drs): Likewise.
9672 (vect_analyze_data_refs_alignment): Remove dead code.
9673 (vect_slp_analyze_and_verify_node_alignment): Likewise.
9674 (vect_analyze_data_refs): For possible gathers or scatters do
9675 not create an alternate DR, just check their possible validity
9676 and mark them. Adjust DECL_NONALIASED handling to not rely
9678 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Do not
9679 update inits of gathers or scatters.
9680 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern):
9681 Also copy gather/scatter flag to pattern vinfo.
9683 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
9685 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
9686 behavior of vec_packsu (vector unsigned long long, vector unsigned
9687 long long) to match behavior of vec_packs with same signature.
9689 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
9690 Thomas Schwinge <thomas@codesourcery.com>
9691 Cesar Philippidis <cesar@codesourcery.com>
9693 * gimplify.c (gimplify_scan_omp_clauses): Add support for
9694 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
9695 (gimplify_adjust_omp_clauses): Likewise.
9696 (gimplify_oacc_declare_1): Add support for GOMP_MAP_RELEASE, remove
9697 support for GOMP_MAP_FORCE_{ALLOC,TO,FROM,TOFROM}.
9698 (gimplify_omp_target_update): Update handling of acc update and
9700 * omp-low.c (install_var_field): Remove unused parameter
9701 base_pointers_restrict.
9702 (scan_sharing_clauses): Remove base_pointers_restrict parameter.
9703 Update call to install_var_field. Handle OMP_CLAUSE_{IF_PRESENT,
9705 (omp_target_base_pointers_restrict_p): Delete.
9706 (scan_omp_target): Update call to scan_sharing_clauses.
9707 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_{IF_PRESENT,
9709 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
9710 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
9711 (convert_local_omp_clauses): Likewise.
9712 * tree-pretty-print.c (dump_omp_clause): Likewise.
9713 * tree.c (omp_clause_num_ops): Add entries for OMP_CLAUSE_{IF_PRESENT,
9715 (omp_clause_code_name): Likewise.
9717 2018-06-20 Jakub Jelinek <jakub@redhat.com>
9720 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
9723 PR tree-optimization/86231
9724 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
9725 anti-range don't overwrite *vr0min before using it to compute *vr0max.
9727 2018-06-20 Tom de Vries <tdevries@suse.de>
9729 PR tree-optimization/86097
9730 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Also convert *nit to
9731 iv type if signedness of iv type is not the same as that of *nit.
9733 2018-06-20 Jakub Jelinek <jakub@redhat.com>
9735 * cfgrtl.c (rtl_verify_edges): Formatting fix. If bb->preds has any
9736 EDGE_EH edges, verify they are all EDGE_EH.
9738 2018-06-20 Maya Rashish <coypu@sdf.org>
9740 * ginclude/stddef.h: Limit #include <machine/ansi.h> to NetBSD.
9742 2018-06-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
9744 * config/aarch64/aarch64-tuning-flags.def (no_ldp_stp_qregs): New.
9745 * config/aarch64/aarch64.c (xgene1_tunings): Add
9746 AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS to tune_flags.
9747 (aarch64_mode_valid_for_sched_fusion_p):
9748 Allow 16-byte modes.
9749 (aarch64_classify_address): Allow 16-byte modes for load_store_pair_p.
9750 * config/aarch64/aarch64-ldpstp.md: Add peepholes for LDP STP of
9752 * config/aarch64/aarch64-simd.md (load_pair<VQ:mode><VQ2:mode>):
9754 (vec_store_pair<VQ:mode><VQ2:mode>): Likewise.
9755 * config/aarch64/iterators.md (VQ2): New mode iterator.
9757 2018-06-20 Martin Liska <mliska@suse.cz>
9759 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
9760 Change default ratio from 10 to 8.
9762 2018-06-20 Martin Liska <mliska@suse.cz>
9764 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
9766 (bit_test_cluster::find_bit_tests): Likewise.
9767 (switch_decision_tree::analyze_switch_statement): Find clusters.
9768 * tree-switch-conversion.h (struct jump_table_cluster): Document
9771 2018-06-20 Martin Liska <mliska@suse.cz>
9773 * tree-switch-conversion.c (switch_conversion::collect):
9774 Record m_uniq property.
9775 (switch_conversion::expand): Bail out for special conditions.
9776 (group_cluster::~group_cluster): New.
9777 (group_cluster::group_cluster): Likewise.
9778 (group_cluster::dump): Likewise.
9779 (jump_table_cluster::emit): New.
9780 (switch_decision_tree::fix_phi_operands_for_edges): New.
9781 (struct case_node): Remove struct.
9782 (jump_table_cluster::can_be_handled): New.
9783 (case_values_threshold): Moved to header.
9784 (reset_out_edges_aux): Likewise.
9785 (jump_table_cluster::is_beneficial): New.
9786 (bit_test_cluster::can_be_handled): Likewise.
9787 (add_case_node): Remove.
9788 (bit_test_cluster::is_beneficial): New.
9789 (case_bit_test::cmp): New.
9790 (bit_test_cluster::emit): New.
9791 (expand_switch_as_decision_tree_p): Remove.
9792 (bit_test_cluster::hoist_edge_and_branch_if_true): New.
9793 (fix_phi_operands_for_edge): Likewise.
9794 (switch_decision_tree::analyze_switch_statement): New.
9795 (compute_cases_per_edge): Move ...
9796 (switch_decision_tree::compute_cases_per_edge): ... here.
9797 (try_switch_expansion): Likewise.
9798 (switch_decision_tree::try_switch_expansion): Likewise.
9799 (record_phi_operand_mapping): Likewise.
9800 (switch_decision_tree::record_phi_operand_mapping): Likewise.
9801 (emit_case_decision_tree): Likewise.
9802 (switch_decision_tree::emit): Likewise.
9803 (balance_case_nodes): Likewise.
9804 (switch_decision_tree::balance_case_nodes): Likewise.
9805 (dump_case_nodes): Likewise.
9806 (switch_decision_tree::dump_case_nodes): Likewise.
9807 (emit_jump): Likewise.
9808 (switch_decision_tree::emit_jump): Likewise.
9809 (emit_cmp_and_jump_insns): Likewise.
9810 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
9811 (emit_case_nodes): Likewise.
9812 (switch_decision_tree::emit_case_nodes): Likewise.
9813 (conditional_probability): Remove.
9814 * tree-switch-conversion.h (enum cluster_type): New.
9816 (struct cluster): Likewise.
9817 (cluster::cluster): Likewise.
9818 (struct simple_cluster): Likewise.
9819 (simple_cluster::simple_cluster): Likewise.
9820 (struct group_cluster): Likewise.
9821 (struct jump_table_cluster): Likewise.
9822 (struct bit_test_cluster): Likewise.
9823 (struct min_cluster_item): Likewise.
9824 (struct case_tree_node): Likewise.
9825 (case_tree_node::case_tree_node): Likewise.
9826 (jump_table_cluster::case_values_threshold): Likewise.
9827 (struct case_bit_test): Likewise.
9828 (struct switch_decision_tree): Likewise.
9829 (struct switch_conversion): Likewise.
9830 (switch_decision_tree::reset_out_edges_aux): Likewise.
9832 2018-06-20 Martin Liska <mliska@suse.cz>
9834 * tree-switch-conversion.c (MAX_CASE_BIT_TESTS): Remove.
9835 (hoist_edge_and_branch_if_true): Likewise.
9836 (expand_switch_using_bit_tests_p): Likewise.
9837 (struct case_bit_test): Likewise.
9838 (case_bit_test_cmp): Likewise.
9839 (emit_case_bit_tests): Likewise.
9840 (switch_conversion::switch_conversion): New class.
9841 (struct switch_conv_info): Remove old struct.
9842 (collect_switch_conv_info): More to ...
9843 (switch_conversion::collect): ... this.
9844 (check_range): Likewise.
9845 (switch_conversion::check_range): Likewise.
9846 (check_all_empty_except_final): Likewise.
9847 (switch_conversion::check_all_empty_except_final): Likewise.
9848 (check_final_bb): Likewise.
9849 (switch_conversion::check_final_bb): Likewise.
9850 (create_temp_arrays): Likewise.
9851 (switch_conversion::create_temp_arrays): Likewise.
9852 (free_temp_arrays): Likewise.
9853 (gather_default_values): Likewise.
9854 (switch_conversion::gather_default_values): Likewise.
9855 (build_constructors): Likewise.
9856 (switch_conversion::build_constructors): Likewise.
9857 (constructor_contains_same_values_p): Likewise.
9858 (switch_conversion::contains_same_values_p): Likewise.
9859 (array_value_type): Likewise.
9860 (switch_conversion::array_value_type): Likewise.
9861 (build_one_array): Likewise.
9862 (switch_conversion::build_one_array): Likewise.
9863 (build_arrays): Likewise.
9864 (switch_conversion::build_arrays): Likewise.
9865 (gen_def_assigns): Likewise.
9866 (switch_conversion::gen_def_assigns): Likewise.
9867 (prune_bbs): Likewise.
9868 (switch_conversion::prune_bbs): Likewise.
9869 (fix_phi_nodes): Likewise.
9870 (switch_conversion::fix_phi_nodes): Likewise.
9871 (gen_inbound_check): Likewise.
9872 (switch_conversion::gen_inbound_check): Likewise.
9873 (process_switch): Use the newly created class.
9874 (switch_conversion::expand): New.
9875 (switch_conversion::~switch_conversion): New.
9876 * tree-switch-conversion.h: New file.
9878 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
9880 * tree-vectorizer.h (NUM_PATTERNS, vect_recog_func_ptr): Move to
9881 tree-vect-patterns.c.
9882 * tree-vect-patterns.c (vect_supportable_direct_optab_p): New function.
9883 (vect_recog_dot_prod_pattern): Use it. Remove the type_in argument.
9884 (vect_recog_sad_pattern): Likewise.
9885 (vect_recog_widen_sum_pattern): Likewise.
9886 (vect_recog_pow_pattern): Likewise. Check for a null vectype.
9887 (vect_recog_widen_shift_pattern): Remove the type_in argument.
9888 (vect_recog_rotate_pattern): Likewise.
9889 (vect_recog_mult_pattern): Likewise.
9890 (vect_recog_vector_vector_shift_pattern): Likewise.
9891 (vect_recog_divmod_pattern): Likewise.
9892 (vect_recog_mixed_size_cond_pattern): Likewise.
9893 (vect_recog_bool_pattern): Likewise.
9894 (vect_recog_mask_conversion_pattern): Likewise.
9895 (vect_try_gather_scatter_pattern): Likewise.
9896 (vect_recog_widen_mult_pattern): Likewise. Check for a null vectype.
9897 (vect_recog_over_widening_pattern): Likewise.
9898 (vect_recog_gather_scatter_pattern): Likewise.
9899 (vect_recog_func_ptr): Move from tree-vectorizer.h
9900 (vect_vect_recog_func_ptrs): Move further down the file.
9901 (vect_recog_func): Likewise. Remove the third argument.
9902 (NUM_PATTERNS): Define based on vect_vect_recog_func_ptrs.
9903 (vect_pattern_recog_1): Expect the pattern function to do any
9904 necessary target tests. Also expect it to provide a vector type.
9905 Remove the type_in handling.
9907 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
9909 * tree-vect-patterns.c (vect_pattern_detected): New function.
9910 (vect_recog_dot_prod_patternm, vect_recog_sad_pattern)
9911 (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern)
9912 (vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern
9913 (vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern)
9914 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
9915 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
9916 (vect_recog_mask_conversion_pattern)
9917 (vect_try_gather_scatter_pattern): Likewise.
9919 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
9921 * tree-vect-patterns.c (vect_get_internal_def): New function.
9922 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
9923 (vect_recog_vector_vector_shift_pattern, check_bool_pattern)
9924 (search_type_for_mask_1): Use it.
9926 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
9928 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
9929 redundant WIDEN_SUM_EXPR handling.
9930 (vect_recog_sad_pattern): Likewise.
9932 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
9934 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
9935 redundant check that the types of a PLUS_EXPR or MULT_EXPR agree.
9936 (vect_recog_sad_pattern): Likewise PLUS_EXPR, ABS_EXPR and MINUS_EXPR.
9937 (vect_recog_widen_mult_pattern): Likewise MULT_EXPR.
9938 (vect_recog_widen_sum_pattern): Likewise PLUS_EXPR.
9940 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
9942 * tree-vect-stmts.c (vectorizable_call): Make sure that we
9943 use the stmt_vec_info of the original bb statement for the
9944 new zero assignment, even if the call is part of a pattern.
9946 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
9948 * tree-vectorizer.h (_stmt_vec_info): Note above pattern_def_seq
9949 that the sequence is attached to the original statement rather
9950 than the pattern statement.
9951 * tree-vect-loop.c (vect_determine_vf_for_stmt): Take the
9952 PATTERN_DEF_SEQ from the original statement rather than
9953 the main pattern statement.
9954 * tree-vect-stmts.c (free_stmt_vec_info): Likewise.
9955 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
9956 (vect_mark_pattern_stmts): Don't copy the PATTERN_DEF_SEQ.
9958 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
9960 * tree-vect-stmts.c (vect_analyze_stmt): Move the handling of pattern
9961 definition statements before the early exit for statements that aren't
9963 * tree-vect-loop.c (vect_transform_loop_stmt): New function,
9965 (vect_transform_loop): ...here. Process pattern definition
9966 statements without first checking whether the main pattern
9967 statement is live or relevant.
9969 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
9971 * tree-cfgcleanup.c (tree_forwarder_block_p): Do not return false at
9972 -O0 if the locus represent UNKNOWN_LOCATION but have different values.
9974 2018-06-19 Aaron Sawdey <acsawdey@linux.ibm.com>
9976 * config/rs6000/rs6000-string.c (select_block_compare_mode): Check
9977 TARGET_EFFICIENT_OVERLAPPING_UNALIGNED here instead of in caller.
9978 (do_and3, do_and3_mask, do_compb3, do_rotl3): New functions.
9979 (expand_block_compare): Change select_block_compare_mode call.
9980 (expand_strncmp_align_check): Use new functions, fix comment.
9981 (emit_final_str_compare_gpr): New function.
9982 (expand_strn_compare): Refactor and clean up code.
9983 * config/rs6000/vsx.md (vsx_mov<mode>_64bit): Remove *.
9985 2018-06-19 Tony Reix <tony.reix@atos.com>
9986 Damien Bergamini <damien.bergamini@atos.com>
9987 David Edelsohn <dje.gcc@gmail.com>
9989 * collect2.c (static_obj): New variable.
9990 (static_libs): New variable.
9991 (is_in_list): Uncomment declaration.
9992 (main): Track AIX libraries linked statically.
9993 (is_in_list): Uncomment definition.
9994 (scan_prog_file): Don't add AIX shared libraries initializer
9995 to constructor list if linking statically.
9997 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
9999 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
10001 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
10003 2018-06-19 Jan Hubicka <hubicka@ucw.cz>
10005 * tree.c (find_decls_types_r): Remove all non-VAR_DECLs from
10008 2018-06-19 Martin Liska <mliska@suse.cz>
10010 * config/i386/i386.c (ix86_can_inline_p): Do not use
10011 ipa_fn_summaries::get_create.
10012 * ipa-cp.c (ipcp_cloning_candidate_p): Replace get_create with
10014 (devirtualization_time_bonus): Likewise.
10015 (ipcp_propagate_stage): Likewise.
10016 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
10017 (edge_set_predicate): Likewise.
10018 (evaluate_conditions_for_known_args): Likewise.
10019 (evaluate_properties_for_edge): Likewise.
10020 (ipa_call_summary::reset): Tranform to ...
10021 (ipa_call_summary::~ipa_call_summary): ... this.
10022 (ipa_fn_summary::reset): Transform to ...
10023 (ipa_fn_summary::~ipa_fn_summary): ... this.
10024 (ipa_fn_summary_t::remove): Rename to ...
10025 (ipa_fn_summary_t::remove_callees): ... this.
10026 (ipa_fn_summary_t::duplicate): Use placement new
10027 instead of memory copy.
10028 (ipa_call_summary_t::duplicate): Likewise.
10029 (ipa_call_summary_t::remove): Remove.
10030 (dump_ipa_call_summary): Change get_create to get.
10031 (ipa_dump_fn_summary): Dump only when summary exists.
10032 (analyze_function_body): Use symbol_summary::get instead
10034 (compute_fn_summary): Likewise.
10035 (estimate_edge_devirt_benefit): Likewise.
10036 (estimate_edge_size_and_time): Likewise.
10037 (inline_update_callee_summaries): Likewise.
10038 (remap_edge_change_prob): Likewise.
10039 (remap_edge_summaries): Likewise.
10040 (ipa_merge_fn_summary_after_inlining): Likewise.
10041 (write_ipa_call_summary): Likewise.
10042 (ipa_fn_summary_write): Likewise.
10043 (ipa_free_fn_summary): Likewise.
10044 * ipa-fnsummary.h (struct GTY): Add new ctor and copy ctor.
10045 (struct ipa_call_summary): Likewise.
10046 * ipa-icf.c (sem_function::merge): Use symbol_summary::get instead
10048 * ipa-inline-analysis.c (do_estimate_edge_time): Likewise.
10049 (estimate_size_after_inlining): Likewise.
10050 (estimate_growth): Likewise.
10051 (growth_likely_positive): Likewise.
10052 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
10053 (inline_call): Likewise.
10054 * ipa-inline.c (caller_growth_limits): Likewise.
10055 (can_inline_edge_p): Likewise.
10056 (can_inline_edge_by_limits_p): Likewise.
10057 (compute_uninlined_call_time): Likewise.
10058 (compute_inlined_call_time): Likewise.
10059 (want_inline_small_function_p): Likewise.
10060 (edge_badness): Likewise.
10061 (update_caller_keys): Likewise.
10062 (update_callee_keys): Likewise.
10063 (inline_small_functions): Likewise.
10064 (inline_to_all_callers_1): Likewise.
10065 (dump_overall_stats): Likewise.
10066 (early_inline_small_functions): Likewise.
10067 (early_inliner): Likewise.
10068 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
10069 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
10070 * ipa-pure-const.c (malloc_candidate_p): Likewise.
10071 * ipa-split.c (execute_split_functions): Likewise.
10072 * symbol-summary.h: Likewise.
10073 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
10075 2018-06-19 Richard Biener <rguenther@suse.de>
10077 * tree-vectorizer.c (try_vectorize_loop_1): Split out of ...
10078 (vectorize_loops): ... here. Fix dbgcnt handling.
10079 (try_vectorize_loop): Wrap try_vectorize_loop_1.
10081 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
10084 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
10085 ieee128 argument takes up only one (vector) register, not two (floating
10088 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
10090 * gimplify.c (gimplify_init_constructor): Really never clear for an
10091 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
10093 2018-06-19 Richard Biener <rguenther@suse.de>
10095 PR tree-optimization/86179
10096 * tree-vect-patterns.c (vect_pattern_recog_1): Clean up
10097 after failed recognition.
10099 2018-06-18 Martin Sebor <msebor@redhat.com>
10101 PR middle-end/85602
10102 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
10103 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
10104 Handle integer subtraction.
10105 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
10106 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
10108 2018-06-18 David Malcolm <dmalcolm@redhat.com>
10110 * config/frv/frv-protos.h (frv_ifcvt_modify_insn): Strengthen 3rd
10111 param from rtx to rtx_insn *.
10112 * config/frv/frv.c (frv_ifcvt_add_insn): Likewise for "insn"
10114 (frv_ifcvt_modify_insn): Likwise.
10115 (frv_ifcvt_modify_final): Likwise for local "existing_insn",
10116 adding an as_a <rtx_insn *> cast. Likewise for local "insn".
10117 * config/mips/mips.c (r10k_insert_cache_barriers): Add an
10118 as_a <rtx_insn *> cast to local "unprotected_region" once
10119 it's been established that it's not NULL or pc_rtx.
10120 * config/nds32/nds32-relax-opt.c (nds32_group_insns): Strengthen
10121 param "sethi" from rtx to rtx_insn *.
10122 (nds32_group_float_insns): Likewise for param "insn".
10123 * config/vax/vax-protos.h (vax_output_int_add): Likewise for 1st
10125 (vax_output_int_subtract): Likewise.
10126 * config/vax/vax.c (vax_output_int_add): Likewise for param
10128 (vax_output_int_subtract): Likewise.
10129 * emit-rtl.c (set_insn_deleted): Likewise, removing cast.
10130 (emit_pattern_after): Likewise for param "after".
10131 (emit_insn_after): Likewise.
10132 (emit_jump_insn_after): Likewise.
10133 (emit_call_insn_after): Likewise.
10134 (emit_debug_insn_after): Likewise.
10135 (emit_pattern_before): Likewise for param "before".
10136 (emit_insn_before): Likewise.
10137 (emit_jump_insn_before): Likewise.
10138 * final.c (get_insn_template): Likewise for param "insn", removing
10140 * output.h (get_insn_template): Likewise for 2nd param.
10141 * rtl.h (emit_insn_before): Likewise.
10142 (emit_jump_insn_before): Likewise.
10143 (emit_debug_insn_before_noloc): Likewise.
10144 (emit_insn_after): Likewise.
10145 (emit_jump_insn_after): Likewise.
10146 (emit_call_insn_after): Likewise.
10147 (emit_debug_insn_after): Likewise.
10148 (set_insn_deleted): Likewise for param.
10150 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
10153 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
10154 floating point modes, so that IFmode is numerically greater than
10155 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
10156 to declare the ordering. This prevents IFmode from being
10157 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
10158 machine. Include rs6000-modes.h to share the fractional values
10159 between genmodes* and the rest of the compiler.
10160 (IFmode): Likewise.
10161 (KFmode): Likewise.
10162 (TFmode): Likewise.
10163 * config/rs6000/rs6000-modes.h: New file.
10164 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
10165 meaning of rs6000_long_double_size so that 126..128 selects an
10166 appropriate 128-bit floating point type.
10167 (rs6000_option_override_internal): Likewise.
10168 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
10169 (TARGET_LONG_DOUBLE_128): Change the meaning of
10170 rs6000_long_double_size so that 126..128 selects an appropriate
10171 128-bit floating point type.
10172 (LONG_DOUBLE_TYPE_SIZE): Update comment.
10173 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
10174 source and destination to match the standard usage.
10175 (truncifkf2): Likewise.
10176 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
10177 ISA 2.07 to use an explicit clobber, instead of passing in a
10179 (copysign<mode>3_soft): Likewise.
10181 2018-06-18 David Malcolm <dmalcolm@redhat.com>
10183 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
10184 Replace dump_printf_loc call with DUMP_VECT_SCOPE.
10185 (vect_slp_analyze_instance_dependence): Likewise.
10186 (vect_enhance_data_refs_alignment): Likewise.
10187 (vect_analyze_data_refs_alignment): Likewise.
10188 (vect_slp_analyze_and_verify_instance_alignment
10189 (vect_analyze_data_ref_accesses): Likewise.
10190 (vect_prune_runtime_alias_test_list): Likewise.
10191 (vect_analyze_data_refs): Likewise.
10192 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Likewise.
10193 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
10194 (vect_analyze_scalar_cycles_1): Likewise.
10195 (vect_get_loop_niters): Likewise.
10196 (vect_analyze_loop_form_1): Likewise.
10197 (vect_update_vf_for_slp): Likewise.
10198 (vect_analyze_loop_operations): Likewise.
10199 (vect_analyze_loop): Likewise.
10200 (vectorizable_induction): Likewise.
10201 (vect_transform_loop): Likewise.
10202 * tree-vect-patterns.c (vect_pattern_recog): Likewise.
10203 * tree-vect-slp.c (vect_analyze_slp): Likewise.
10204 (vect_make_slp_decision): Likewise.
10205 (vect_detect_hybrid_slp): Likewise.
10206 (vect_slp_analyze_operations): Likewise.
10207 (vect_slp_bb): Likewise.
10208 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise.
10209 (vectorizable_bswap): Likewise.
10210 (vectorizable_call): Likewise.
10211 (vectorizable_simd_clone_call): Likewise.
10212 (vectorizable_conversion): Likewise.
10213 (vectorizable_assignment): Likewise.
10214 (vectorizable_shift): Likewise.
10215 (vectorizable_operation): Likewise.
10216 * tree-vectorizer.h (DUMP_VECT_SCOPE): New macro.
10218 2018-06-18 Martin Sebor <msebor@redhat.com>
10220 PR tree-optimization/81384
10221 * builtin-types.def (BT_FN_SIZE_CONST_STRING_SIZE): New.
10222 * builtins.c (expand_builtin_strnlen): New function.
10223 (expand_builtin): Call it.
10224 (fold_builtin_n): Avoid setting TREE_NO_WARNING.
10225 * builtins.def (BUILT_IN_STRNLEN): New.
10226 * calls.c (maybe_warn_nonstring_arg): Handle BUILT_IN_STRNLEN.
10227 Warn for bounds in excess of maximum object size.
10228 * tree-ssa-strlen.c (maybe_set_strlen_range): Return tree representing
10229 single-value ranges. Handle strnlen.
10230 (handle_builtin_strlen): Handle strnlen.
10231 (strlen_check_and_optimize_stmt): Same.
10232 * doc/extend.texi (Other Builtins): Document strnlen.
10234 2018-06-18 Maya Rashish <coypu@sdf.org>
10236 * config/alpha/openbsd.h (TARGET_DEFAULT): Define.
10237 (LINK_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
10238 (INTMAX_TYPE, UINTMAX_TYPE, WINT_TYPE): Likewise.
10240 * config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Move from
10242 * config/alpha/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Here.
10244 2018-06-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
10246 * tree.c (escaped_string::escape): Replace cast to char * by
10247 const_cast<char *> (unescaped).
10249 2018-06-18 Nick Clifton <nickc@redhat.com>
10252 * tree.c (escaped_string): New class. Converts an unescaped
10253 string into its escaped equivalent.
10254 (warn_deprecated_use): Use the new class to convert the
10255 deprecation message, if present.
10256 (test_escaped_strings): New self test.
10257 (test_c_tests): Add test_escaped_strings.
10258 * doc/extend.texi (deprecated): Add a note that the
10259 deprecation message is affected by the -fmessage-length
10260 option, and that control characters will be escaped.
10261 (#pragma GCC error): Document this pragma.
10262 (#pragma GCC warning): Likewise.
10263 * doc/invoke.texi (-fmessage-length): Document this option's
10264 effect on the #warning and #error preprocessor directives and
10265 the deprecated attribute.
10267 2018-06-18 Eric Botcazou <ebotcazou@adacore.com>
10269 * tree.c (decl_value_expr_lookup): Revert latest change.
10270 (decl_value_expr_insert): Likewise.
10272 2018-06-17 Eric Botcazou <ebotcazou@adacore.com>
10274 * gimplify.c (nonlocal_vlas): Delete.
10275 (nonlocal_vla_vars): Likewise.
10276 (gimplify_var_or_parm_decl): Do not add debug VAR_DECLs for non-local
10278 (gimplify_body): Do not create and destroy nonlocal_vlas.
10279 * tree-nested.c: Include diagnostic.h.
10280 (use_pointer_in_frame): Tweak.
10281 (lookup_field_for_decl): Add assertion and declare the transformation.
10282 (convert_nonlocal_reference_op) <PARM_DECL>: Rework and issue an
10283 internal error when the reference is in a wrong context. Do not
10284 create a debug decl by default.
10285 (note_nonlocal_block_vlas): Delete.
10286 (convert_nonlocal_reference_stmt) <GIMPLE_BIND>: Do not call it.
10287 (convert_local_reference_op) <PARM_DECL>: Skip the frame decl. Do not
10288 create a debug decl by default.
10289 (convert_gimple_call) <GIMPLE_CALL>: Issue an internal error when the
10290 call is in a wrong context.
10291 (fixup_vla_decls): New function.
10292 (finalize_nesting_tree_1): Adjust comment. Call fixup_vla_decls if no
10293 debug variables were created.
10294 * tree.c (decl_value_expr_lookup): Add checking assertion.
10295 (decl_value_expr_insert): Likewise.
10297 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
10299 PR middle-end/82479
10300 * ipa-fnsummary.c (will_be_nonconstant_expr_predicate): Handle CALL_EXPR.
10301 * tree-scalar-evolution.c (interpret_expr): Likewise.
10302 (expression_expensive_p): Likewise.
10303 * tree-ssa-loop-ivopts.c (contains_abnormal_ssa_name_p): Likewise.
10304 * tree-ssa-loop-niter.c (number_of_iterations_popcount): New.
10305 (number_of_iterations_exit_assumptions): Use number_of_iterations_popcount.
10306 (ssa_defined_by_minus_one_stmt_p): New.
10308 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
10310 PR middle-end/64946
10311 * cfgexpand.c (expand_debug_expr): Hande ABSU_EXPR.
10312 * config/i386/i386.c (ix86_add_stmt_cost): Likewise.
10313 * dojump.c (do_jump): Likewise.
10314 * expr.c (expand_expr_real_2): Check operand type's sign.
10315 * fold-const.c (const_unop): Handle ABSU_EXPR.
10316 (fold_abs_const): Likewise.
10317 * gimple-pretty-print.c (dump_unary_rhs): Likewise.
10318 * gimple-ssa-backprop.c (backprop::process_assign_use): Likesie.
10319 (strip_sign_op_1): Likesise.
10320 * match.pd: Add new pattern to generate ABSU_EXPR.
10321 * optabs-tree.c (optab_for_tree_code): Handle ABSU_EXPR.
10322 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
10323 * tree-eh.c (operation_could_trap_helper_p): Likewise.
10324 * tree-inline.c (estimate_operator_cost): Likewise.
10325 * tree-pretty-print.c (dump_generic_node): Likewise.
10326 * tree-vect-patterns.c (vect_recog_sad_pattern): Likewise.
10327 * tree.def (ABSU_EXPR): New.
10329 2018-06-16 Jakub Jelinek <jakub@redhat.com>
10331 PR middle-end/86095
10332 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
10333 documented as preserved for backward compatibility only.
10334 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
10336 PR rtl-optimization/86108
10337 * bb-reorder.c (create_forwarder_block): Renamed to ...
10338 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
10339 jump from new landing pad to the second part.
10340 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
10343 2018-06-15 Jakub Jelinek <jakub@redhat.com>
10345 PR middle-end/85878
10346 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
10347 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
10348 Only call store_expr for halves if the mode is the same.
10350 PR middle-end/86123
10351 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
10352 Fix up comment formatting.
10354 2018-06-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
10356 * typed-splay-tree.h (typed_splay_tree::remove): New function.
10357 (typed_splay_tree::closure,
10358 typed_splay_tree::inner_foreach_fn, typed_splay_tree::m_inner): Deleted.
10359 (typed_splay_tree::typed_splay_tree,
10360 typed_splay_tree::operator =): Declared private.
10361 (typed_splay_tree::splay_tree_key, typed_splay_tree::splay_tree_value,
10362 typed_splay_tree::splay_tree_node_s, typed_splay_tree::KDEL,
10363 typed_splay_tree::VDEL, typed_splay_tree::splay_tree_delete_helper,
10364 typed_splay_tree::rotate_left, typed_splay_tree::rotate_right,
10365 typed_splay_tree::splay_tree_splay,
10366 typed_splay_tree::splay_tree_foreach_helper,
10367 typed_splay_tree::splay_tree_insert,
10368 typed_splay_tree::splay_tree_remove,
10369 typed_splay_tree::splay_tree_lookup,
10370 typed_splay_tree::splay_tree_predecessor,
10371 typed_splay_tree::splay_tree_successor,
10372 typed_splay_tree::splay_tree_min,
10373 typed_splay_tree::splay_tree_max): Took over from splay-tree.c/.h.
10374 (typed_splay_tree::root, typed_splay_tree::comp,
10375 typed_splay_tree::delete_key,
10376 typed_splay_tree::delete_value): New data members.
10377 * typed-splay-tree.c (selftest::test_str_to_int): Add a test for
10378 typed_splay_tree::remove.
10380 2018-06-15 Matthew Fortune <matthew.fortune@mips.com>
10382 * config/mips/mips.h (ASM_SPEC): Pass through -mcrc, -mno-crc,
10383 -mginv and -mno-ginv to the assembler.
10384 * config/mips/mips.opt (-mcrc): New option.
10385 (-mginv): Likewise.
10386 * doc/invoke.text (-mcrc): Document.
10387 (-mginv): Likewise.
10389 2018-06-15 Nick Clifton <nickc@redhat.com>
10392 * tree.c (escaped_string): New class. Converts an unescaped
10393 string into its escaped equivalent.
10394 (warn_deprecated_use): Use the new class to convert the
10395 deprecation message, if present.
10396 (test_escaped_strings): New self test.
10397 (test_c_tests): Add test_escaped_strings.
10398 * doc/extend.texi (deprecated): Add a note that the
10399 deprecation message is affected by the -fmessage-length
10400 option, and that control characters will be escaped.
10401 (#pragma GCC error): Document this pragma.
10402 (#pragma GCC warning): Likewise.
10403 * doc/invoke.texi (-fmessage-length): Document this option's
10404 effect on the #warning and #error preprocessor directives and
10405 the deprecated attribute.
10407 2018-06-15 Richard Biener <rguenther@suse.de>
10409 * tree-vect-slp.c (vect_slp_bb): Dump MSG_OPTIMIZED_LOCATIONS
10410 here, also noting vector size used.
10411 * tree-vectorizer.c (vectorize_loops): Adjust. Note vector
10412 size used in MSG_OPTIMIZED_LOCATIONS dump.
10413 (pass_slp_vectorize::execute): Adjust.
10415 2018-06-15 Claudiu Zissulescu <claziss@synopsys.com>
10418 * config/arc/arc.c (arc_return_address_register): Fix
10421 2018-06-15 Richard Biener <rguenther@suse.de>
10423 PR middle-end/86159
10424 * tree-cfg.c (gimplify_build3): Do not strip sign conversions,
10425 leave useless conversion stripping to force_gimple_operand_gsi.
10426 (gimplify_build2): Likewise.
10427 (gimplify_build1): Likewise.
10429 2018-06-15 Richard Biener <rguenther@suse.de>
10431 PR middle-end/86076
10432 * tree-cfg.c (move_stmt_op): unshare invariant addresses
10433 before adjusting their block.
10435 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
10437 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
10438 multilibs for *-*-rtems*.
10439 * config/riscv/t-rtems: New file.
10441 2018-06-14 Jakub Jelinek <jakub@redhat.com>
10443 PR middle-end/86122
10444 * match.pd ((A +- CST1) +- CST2): Punt if last resort
10445 unsigned_type_for returns NULL.
10448 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
10449 subregs of multi-word pseudos unless the float mode has word size.
10451 2018-06-14 Richard Biener <rguenther@suse.de>
10453 PR middle-end/86139
10454 * tree-vect-generic.c (build_word_mode_vector_type): Remove
10455 duplicate and harmful type_hash_canon.
10456 * tree.c (type_hash_canon): Assert we didn't find ourselves.
10458 2018-06-14 Richard Biener <rguenther@suse.de>
10461 * tree-ssa-struct-alias.c (create_variable_info_for): Handle
10464 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
10466 * config/rtems.h (STDINT_LONG32): Define.
10468 2018-06-13 Matthew Fortune <matthew.fortune@mips.com>
10469 Prachi Godbole <prachi.godbole@imgtec.com>
10471 * config/mips/mips-cpus.def: Define P6600.
10472 * config/mips/mips-tables.opt: Regenerate.
10473 * config/mips/mips.c (mips_ucbranch_type): New enum.
10474 (mips_rtx_cost_data): Add support for P6600.
10475 (mips_issue_rate): Likewise.
10476 (mips_multipass_dfa_lookahead): Likewise.
10477 (mips_avoid_hazard): Likewise.
10478 (mips_reorg_process_insns): Likewise.
10479 (mips_classify_branch_p6600): New function.
10480 * config/mips/mips.h (TUNE_P6600): New define.
10481 (MIPS_ISA_LEVEL_SPEC): Infer mips64r6 from p6600.
10482 (ENABLE_LD_ST_PAIRS): Enable load/store bonding for p6600.
10483 * config/mips/mips.md: Include p6600.md.
10484 (processor): Add p6600.
10485 * config/mips/p6600.md: New file.
10486 * doc/invoke.texi: Add p6600 to supported architectures.
10488 2018-06-13 Martin Sebor <msebor@redhat.com>
10490 PR tree-optimization/86114
10491 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
10493 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
10495 2018-06-13 Richard Biener <rguenther@suse.de>
10497 * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern):
10498 Properly set vector type of the intermediate stmt.
10499 * tree-vect-stmts.c (vectorizable_operation): The destination
10500 var always has vectype_out type.
10502 2018-06-13 Jeff Law <law@redhat.com>
10504 * config/rl78/rl78.c (move_elim_pass): Use TDF_NONE rather than
10505 integer 0 for argument to print_rtl_with_bb.
10506 (rl78_reorg): Likewise.
10508 2018-06-13 David Malcolm <dmalcolm@redhat.com>
10510 * config/arc/arc.c (hwloop_optimize): Strengthen local "end_label"
10511 from rtx to rtx_insn *.
10512 * config/bfin/bfin.c (hwloop_optimize): Likewise for local
10514 (add_sched_insns_for_speculation): Likewise for local "target",
10515 converting usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
10516 * config/c6x/c6x.c (reorg_split_calls): Strengthen param "call_labels"
10517 from rtx_insn ** to rtx_code_label **.
10518 (reorg_emit_nops): Likewise.
10519 (c6x_reorg): Likewise for local "call_labels".
10520 * config/sh/sh-protos.h (get_dest_uid): Strengthen 1st param from
10522 * config/sh/sh.c (dump_table): Strengthen local "lab" from rtx to
10523 rtx_code_label *, adding safe_as_a <rtx_code_label *> casts to
10524 the loops over LABEL_REFS.
10525 (fixup_addr_diff_vecs): Add as_a <rtx_insn *> to usage of
10527 (barrier_align): Convert usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
10528 (get_dest_uid): Strengthen param "label" from rtx to rtx_insn *.
10529 (split_branches): Strengthen local "olabel" from rtx to
10530 rtx_insn *, adding a safe_as_a cast.
10531 * emit-rtl.c (next_real_insn): Strengthen param from "rtx"
10533 (add_insn_after): Likewise for first two params.
10534 (add_insn_before): Likewise.
10535 (remove_insn): Likewise for param.
10536 (emit_pattern_before_noloc): Likewise for second and third params.
10537 (emit_jump_insn_before_noloc): Convert NULL_RTX to NULL.
10538 (emit_call_insn_before_noloc): Likewise.
10539 (emit_debug_insn_before_noloc): Strengthen "before" param from "rtx"
10541 (emit_barrier_before): Likewise.
10542 (emit_label_before): Strengthen "label" param from "rtx" to
10543 "rtx_code_label *". Strengthen "before" param from "rtx" to
10545 (emit_insn_after_1): Strengthen "after" param from "rtx" to
10547 (emit_pattern_after_noloc): Likewise.
10548 (emit_insn_after_noloc): Likewise.
10549 (emit_jump_insn_after_noloc): Likewise.
10550 (emit_call_insn_after_noloc): Likewise.
10551 (emit_debug_insn_after_noloc): Likewise.
10552 (emit_barrier_after): Likewise.
10553 (emit_label_after): Likewise for both params.
10554 (emit_pattern_after_setloc): Likewise for "after" param. Convert
10555 "loc" param from "int" to "location_t".
10556 (emit_insn_after_setloc): Likewise.
10557 (emit_jump_insn_after_setloc): Likewise.
10558 (emit_call_insn_after_setloc): Likewise.
10559 (emit_debug_insn_after_setloc): Likewise.
10560 (emit_pattern_before_setloc): Likewise for "before" param. Convert
10561 "loc" param from "int" to "location_t".
10562 (emit_pattern_before): Convert NULL_RTX to NULL.
10563 (emit_insn_before_setloc): Convert "loc" param from "int" to
10565 (emit_jump_insn_before_setloc): Likewise.
10566 (emit_call_insn_before_setloc): Likewise.
10567 (emit_debug_insn_before_setloc): Strengthen "before" param from rtx to
10568 rtx_insn *. Convert "loc" param from "int" to "location_t".
10569 * rtl.h (emit_insn_before_setloc, emit_jump_insn_before_setloc,
10570 emit_call_insn_before_setloc, emit_debug_insn_before_setloc):
10571 Convert 3rd param from "int" to "location_t".
10572 (emit_barrier_before, emit_barrier_after, next_real_insn):
10573 Strengthen param from rtx to rtx_insn *.
10574 (emit_label_before): Strengthen 1st param from "rtx" to
10575 "rtx_code_label *". Strengthen 2nd param from "rtx" to
10577 (emit_insn_after_noloc, emit_jump_insn_after_noloc,
10578 emit_call_insn_after_noloc, emit_debug_insn_after_noloc):
10579 Strengthen 2nd param from "rtx" to "rtx_insn *".
10580 (emit_insn_after_setloc, emit_jump_insn_after_setloc)
10581 emit_call_insn_after_setloc, emit_debug_insn_after_setloc):
10582 Likewise. Convert 3rd param from "int" to "location_t".
10583 (emit_label_after): Strengthen 1st param from "rtx" to
10584 "rtx_code_label *".
10585 (next_real_insn, remove_insn): Strengthen param from "rtx" to
10587 (add_insn_before, add_insn_after): Strengthen 1st and 2nd params
10588 from "rtx" to "rtx_insn *".
10590 2018-06-13 Jan Hubicka <hubicka@gcc.gnu.org>
10592 * cgraph.c (cgraph_node::get_untransformed_body): Dump function
10593 bodies streamed in with -Q.
10594 * dumpfile.c (dump_files): Add lto-stream-out dump file.
10595 * dumpfile.h (tree_dump_index): Add lto_stream_out.
10596 * gimple-streamer-out.c: Include gimple-pretty-print.h
10597 (output_bb): Dump stmts streamed.
10598 * lto-section-out.c: Include print-tree.h
10599 (lto_begin_section): Dump sections created.
10600 (lto_output_decl_index): Dump decl encoded.
10601 * lto-streamer-out.c: Include print-tree.h
10602 (create_output_block): Dump output block created.
10603 (DFS::DFS_write_tree_body): Dump DFS SCCs streamed.
10604 (output_function): Dump function output.
10605 (output_constructor): Dump constructor streamed.
10606 (write_global_stream): Output indexes encoded.
10607 (produce_asm_for_decls): Dump streams encoded.
10608 * lto-streamer.c (streamer_dump_file): New global var.
10609 * lto-streamer.h (streamer_dump_file): Declare.
10610 * passes.c (ipa_write_summaries): Initialize streamer dump.
10611 * varpool.c (varpool_node::get_constructor): Dump constructors streamed
10614 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
10617 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
10618 offsets for register save directives. Emit a second batch of save
10619 directives, if need be, when the function accesses prior frames.
10621 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
10623 * config/arc/fpu.md (fmasf4): Force operand to register.
10624 (fnmasf4): Likewise.
10626 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
10628 * config/arc/arc-protos.h (arc_pad_return): Remove.
10629 * config/arc/arc.c (machine_function): Remove force_short_suffix
10631 (arc_print_operand): Adjust printing of '&'.
10632 (arc_verify_short): Remove conditional printing of short suffix.
10633 (arc_final_prescan_insn): Remove reference to size_reason.
10634 (pad_return): New function.
10635 (arc_reorg): Call pad_return.
10636 (arc_pad_return): Remove.
10637 (arc_init_machine_status): Remove reference to force_short_suffix.
10638 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
10639 (attr length): When attribute iscompact is true force to 2
10640 regardless; in the case of maybe check if we want to force the
10641 instruction to have 4 bytes length.
10642 (nopv): Change it to generate 4 byte long nop as well.
10643 (blockage): New pattern.
10644 (simple_return): Remove call to arc_pad_return.
10645 (p_return_i): Likewise.
10647 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
10649 * config/arc/elf.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
10651 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
10653 * config/arc/builtins.def (SYNC): SYNC instruction is valid on all
10656 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
10658 * config/arc/arc.c (atomic_exchangesi): EX instruction is default
10659 for ARC700 and ARCv2.
10661 2018-06-13 Chenghua Xu <paul.hua.gm@gmail.com>
10664 * config/mips/loongson.md (vec_setv4hi): Gen_lowpart for
10665 operands[2] instead of operands[1].
10668 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
10670 * lra-constraints.c (simplify_operand_subreg): In the paradoxical
10671 case, check whether the outer register overlaps an unallocatable
10672 register, not just whether it fits the required class.
10674 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
10676 * poly-int.h (can_div_trunc_p): Add new overload in which all values
10678 * alias.c (get_addr): Extend CONST_INT handling to poly_int_rtx_p.
10679 (memrefs_conflict_p): Likewise.
10680 (init_alias_analysis): Likewise.
10681 * cfgexpand.c (expand_debug_expr): Likewise.
10682 * combine.c (combine_simplify_rtx, force_int_to_mode): Likewise.
10683 * cse.c (fold_rtx): Likewise.
10684 * explow.c (adjust_stack, anti_adjust_stack): Likewise.
10685 * expr.c (emit_block_move_hints): Likewise.
10686 (clear_storage_hints, push_block, emit_push_insn): Likewise.
10687 (store_expr_with_bounds, reduce_to_bit_field_precision): Likewise.
10688 (emit_group_load_1): Use rtx_to_poly_int64 for group offsets.
10689 (emit_group_store): Likewise.
10690 (find_args_size_adjust): Use strip_offset. Use rtx_to_poly_int64
10691 to read the PRE/POST_MODIFY increment.
10692 * calls.c (store_one_arg): Use strip_offset.
10693 * rtlanal.c (rtx_addr_can_trap_p_1): Extend CONST_INT handling to
10695 (set_noop_p): Use rtx_to_poly_int64 for the elements selected
10697 * simplify-rtx.c (avoid_constant_pool_reference): Use strip_offset.
10698 (simplify_binary_operation_1): Extend CONST_INT handling to
10700 * var-tracking.c (compute_cfa_pointer): Take a poly_int64 rather
10701 than a HOST_WIDE_INT.
10702 (hard_frame_pointer_adjustment): Change from HOST_WIDE_INT to
10704 (adjust_mems, add_stores): Update accodingly.
10705 (vt_canonicalize_addr): Track polynomial offsets.
10706 (emit_note_insn_var_location): Likewise.
10707 (vt_add_function_parameter): Likewise.
10708 (vt_initialize): Likewise.
10710 2018-06-12 Jeff Law <law@redhat.com>
10712 * config.gcc (alpha*-*-freebsd*): Remove.
10713 * config/alpha/freebsd.h: Remove.
10715 2018-06-12 David Malcolm <dmalcolm@redhat.com>
10718 * spellcheck-tree.c (levenshtein_distance): Rename to...
10719 (get_edit_distance): ...this, and update for underlying renaming.
10720 * spellcheck-tree.h (levenshtein_distance): Rename to...
10721 (get_edit_distance): ...this.
10722 * spellcheck.c (levenshtein_distance): Rename to...
10723 (get_edit_distance): ...this. Convert from Levenshtein distance
10724 to Damerau-Levenshtein distance by supporting transpositions of
10725 adjacent characters. Rename "v1" to "v_next" and "v0" to
10727 (selftest::levenshtein_distance_unit_test_oneway): Rename to...
10728 (selftest::test_edit_distance_unit_test_oneway): ...this, and
10729 update for underlying renaming.
10730 (selftest::levenshtein_distance_unit_test): Rename to...
10731 (selftest::test_get_edit_distance_unit): ...this, and update for
10732 underlying renaming.
10733 (selftest::test_find_closest_string): Add example from PR 69968
10734 where transposition helps
10735 (selftest::test_metric_conditions): Update for renaming.
10736 (selftest::test_metric_conditions): Likewise.
10737 (selftest::spellcheck_c_tests): Likewise.
10738 * spellcheck.h (levenshtein_distance): Rename both overloads to...
10739 (get_edit_distance): ...this.
10740 (best_match::consider): Update for renaming.
10742 2018-06-12 Martin Sebor <msebor@redhat.com>
10744 PR tree-optimization/85259
10745 * builtins.c (compute_objsize): Handle constant offsets.
10746 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return
10747 true iff a warning has been issued.
10748 * gimple.h (gimple_nonartificial_location): New function.
10749 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Call
10750 gimple_nonartificial_location and handle -Wno-system-headers.
10751 (handle_builtin_stxncpy): Same.
10753 2018-06-12 Martin Sebor <msebor@redhat.com>
10756 * fold-const.c (operand_equal_p): Handle SAVE_EXPR.
10758 2018-06-12 Will Schmidt <will_schmidt@vnet.ibm.com>
10760 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
10761 BUILTIN_VEC_XST entries for pointer to double and long long.
10763 2018-06-12 H.J. Lu <hongjiu.lu@intel.com>
10766 * config/i386/gnu-user.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
10768 * config/i386/gnu-user64.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
10771 2018-06-12 Martin Liska <mliska@suse.cz>
10773 * doc/options.texi: Document IntegerRange.
10775 2018-06-12 Martin Liska <mliska@suse.cz>
10777 * config/i386/i386.opt: Make MPX-related options as Deprecated.
10778 * opt-functions.awk: Handle Deprecated flag.
10779 * opts-common.c (decode_cmdline_option): Handle cl_deprecated
10781 (read_cmdline_option): Report warning for a deprecated option.
10782 * opts.h (struct cl_option): Add new field cl_deprecated.
10783 (CL_ERR_DEPRECATED): New.
10785 2018-06-12 Martin Liska <mliska@suse.cz>
10787 * doc/options.texi: Document Deprecated option flag.
10789 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
10791 * config/arc/arc-arch.h (arc_extras): New enum.
10792 (arc_cpu_t):Add field extra.
10793 (arc_cpu_types): Consider the extras.
10794 * config/arc/arc-cpus.def: Add extras info.
10795 * config/arc/arc-opts.h (processor_type): Consider extra field.
10796 * config/arc/arc.c (arc_override_options): Handle extra field.
10798 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
10800 * config/arc/arc-arch.h: Update ARC_OPTX macro.
10801 * config/arc/arc-options.def (ARC_OPTX): Introduce a new doc
10803 * config/arc/arc.c (arc_init): Update pic warning.
10804 (irq_range): Update irq range parsing warnings.
10805 (arc_override_options): Update various warning messages.
10806 (arc_handle_aux_attribute): Likewise.
10808 2018-06-12 Robert Suchanek <robert.suchanek@mips.com>
10810 * config/mips/i6400.md (i6400_fpu_fadd): Remove frint.
10812 2018-06-12 Jozef Lawrynowicz <jozef.l@mittosystems.com>
10814 * doc/sourcebuild.texi: Document usage of line number 0 in verify
10815 compiler messages directives.
10817 2018-06-12 Matthew Fortune <mfortune@gmail.com>
10819 * config/mips/mips-cpus.def: New MIPS_CPU for i6500.
10820 * config/mips/mips-tables.opt: Regenerate.
10821 * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Mark i6500 as
10823 * doc/invoke.texi: Document -march=i6500.
10825 2018-06-12 Prachi Godbole <prachi.godbole@imgtec.com>
10827 * config/mips/i6400.md (i6400_gpmuldiv): Remove cpu_unit.
10828 (i6400_gpmul): Add cpu_unit.
10829 (i6400_gpdiv): Likewise.
10830 (i6400_msa_add_d): Update reservations.
10831 (i6400_msa_int_add) Likewise.
10832 (i6400_msa_short_logic3) Likewise.
10833 (i6400_msa_short_logic2) Likewise.
10834 (i6400_msa_short_logic) Likewise.
10835 (i6400_msa_move) Likewise.
10836 (i6400_msa_cmp) Likewise.
10837 (i6400_msa_short_float2) Likewise.
10838 (i6400_msa_div_d) Likewise.
10839 (i6400_msa_long_logic1) Likewise.
10840 (i6400_msa_long_logic2) Likewise.
10841 (i6400_msa_mult) Likewise.
10842 (i6400_msa_long_float2) Likewise.
10843 (i6400_msa_long_float4) Likewise.
10844 (i6400_msa_long_float5) Likewise.
10845 (i6400_msa_long_float8) Likewise.
10846 (i6400_fpu_fadd): Include frint type.
10847 (i6400_fpu_store): New define_insn_reservation.
10848 (i6400_fpu_load): Likewise.
10849 (i6400_fpu_move): Likewise.
10850 (i6400_fpu_fcmp): Likewise.
10851 (i6400_fpu_fmadd): Likewise.
10852 (i6400_int_mult): Include imul3nc type and update reservation.
10853 (i6400_int_div): Include idiv3 type and update reservation.
10854 (i6400_int_load): Update to check type not move_type.
10855 (i6400_int_store): Likewise.
10856 (i6400_int_prefetch): Set zero latency.
10858 2018-06-12 Eric Botcazou <ebotcazou@adacore.com>
10860 * gcc.c: Document new %@{...} sequence.
10861 (LINK_COMMAND_SPEC): Use it for the -L switches.
10862 (cpp_unique_options): Use it for the -I switches.
10863 (at_file_argbuf): New global variable.
10864 (in_at_file): Likewise.
10865 (alloc_args): Create at_file_argbuf.
10866 (clear_args): Truncate at_file_argbuf.
10867 (store_arg): If in_at_file, push the argument onto at_file_argbuf.
10868 (open_at_file): New function.
10869 (close_at_file): Likewise.
10870 (create_at_file): Delete.
10871 (do_spec_1) <'i'>: Use open_at_file/close_at_file.
10874 (validate_switches_from_spec): Deal with %@{...} sequence.
10875 (validate_switches): Likewise.
10876 (driver::finalize): Call clear_args.
10878 2018-06-11 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
10880 * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0.
10882 2018-06-11 Martin Sebor <msebor@redhat.com>
10884 * doc/invoke.texi (-Wall): List -Wc++17-compat.
10885 (Wno-class-memaccess): Add @opindex.
10886 (Wno-templates, Wno-multiple-inheritance): Same.
10887 (Wno-virtual-inheritance, Wno-namespaces): Same.
10888 (Wno-pedantic, Wno-chkp, Wcoverage-mismatch): Same.
10889 (Wno-format-overflow, Wno-format-truncation): Same.
10890 (Wno-unused-local-typedefs, Walloc-size-larger-than): Same.
10891 (Wno-alloc-size-larger-than, Wframe-larger-than): Same
10892 (Wno-stack-usage, Wno-c++-compat, Wno-c++11-compat): Same.
10893 (Wno-c++14-compat, Wno-c++17-compat, Wno-openmp-simd): Same.
10894 (Wno-unsuffixed-float-constants, Wno-addr-space-convert): Same.
10895 (Wno-misspelled-isr): Same.
10897 2018-06-11 Martin Sebor <msebor@redhat.com>
10899 * PR tree-optimization/86083
10900 * tree-ssa-strlen.c (handle_char_store): Use tree_expr_nonzero_p.
10902 2018-06-11 Zhouyi Zhou <zhouzhouyi@gmail.com>
10904 * tree-eh.c (lower_eh_constructs_2): Add a comma to comment.
10906 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
10909 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
10910 on the correct operand.
10911 (*movdi_internal64): Ditto.
10913 2018-06-11 Martin Liska <mliska@suse.cz>
10915 PR tree-optimization/86089
10916 * tree-ssa-strlen.c (get_string_length): Move back removed hunk.
10918 2018-06-11 Julia Koval <julia.koval@intel.com>
10920 * config/i386/vaesintrin.h (_mm_aesdec_epi128, _mm_aesdeclast_epi128)
10921 _mm_aesenc_epi128, _mm_aesenclast_epi128: Remove.
10922 * config/i386/vpclmulqdqintrin.h (_mm_clmulepi64_epi128): Remove.
10924 2018-06-11 Olivier Hainque <hainque@adacore.com>
10926 * dwarf2out.c (gen_compile_unit_die): Fallout to DW_LANG_Ada83
10927 for Ada with strict dwarf2.
10929 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
10932 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
10935 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
10937 * dumpfile.c (FIRST_ME_AUTO_NUMBERED_DUMP): Bump to 4.
10939 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
10941 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
10944 2018-06-08 Martin Liska <mliska@suse.cz>
10946 * tree-cfg.h (debug_function): Fix argument type to match
10949 2018-06-08 Martin Liska <mliska@suse.cz>
10951 * config/powerpcspe/powerpcspe.c (rs6000_xcoff_visibility):
10952 Remove usage of MPX-related (and removed) fields.
10953 * config/rs6000/rs6000.c (rs6000_xcoff_visibility): Likewise.
10955 2018-06-08 David Malcolm <dmalcolm@redhat.com>
10957 * cfg.c (debug): Use TDF_NONE rather than 0.
10958 * cfghooks.c (debug): Likewise.
10959 * dumpfile.c (DUMP_FILE_INFO): Likewise; also for OPTGROUP.
10960 (struct dump_option_value_info): Convert to...
10961 (struct kv_pair): ...this template type.
10962 (dump_options): Convert to kv_pair<dump_flags_t>; use TDF_NONE
10964 (optinfo_verbosity_options): Likewise.
10965 (optgroup_options): Convert to kv_pair<optgroup_flags_t>; use
10967 (gcc::dump_manager::dump_register): Use optgroup_flags_t rather
10968 than int for "optgroup_flags" param.
10969 (dump_generic_expr_loc): Use dump_flags_t rather than int for
10971 (dump_dec): Likewise.
10972 (dump_finish): Use TDF_NONE rather than 0.
10973 (gcc::dump_manager::opt_info_enable_passes): Use optgroup_flags_t
10974 rather than int for "optgroup_flags" param. Use TDF_NONE rather
10975 than 0. Update for change to option_ptr.
10976 (opt_info_switch_p_1): Convert "optgroup_flags" param from int *
10977 to optgroup_flags_t *. Use TDF_NONE and OPTGROUP_NONE rather than
10978 0. Update for changes to optinfo_verbosity_options and
10980 (opt_info_switch_p): Convert optgroup_flags from int to
10982 (dump_basic_block): Use dump_flags_t rather than int
10983 for "dump_kind" param.
10984 * dumpfile.h (TDF_ADDRESS, TDF_SLIM, TDF_RAW, TDF_DETAILS,
10985 TDF_STATS, TDF_BLOCKS, TDF_VOPS, TDF_LINENO, TDF_UID)
10986 TDF_STMTADDR, TDF_GRAPH, TDF_MEMSYMS, TDF_RHS_ONLY, TDF_ASMNAME,
10987 TDF_EH, TDF_NOUID, TDF_ALIAS, TDF_ENUMERATE_LOCALS, TDF_CSELIB,
10988 TDF_SCEV, TDF_GIMPLE, TDF_FOLDING, MSG_OPTIMIZED_LOCATIONS,
10989 MSG_MISSED_OPTIMIZATION, MSG_NOTE, MSG_ALL, TDF_COMPARE_DEBUG,
10990 TDF_NONE): Convert from macros to...
10991 (enum dump_flag): ...this new enum.
10992 (dump_flags_t): Update to use enum.
10993 (operator|, operator&, operator~, operator|=, operator&=):
10994 Implement for dump_flags_t.
10995 (OPTGROUP_NONE, OPTGROUP_IPA, OPTGROUP_LOOP, OPTGROUP_INLINE,
10996 OPTGROUP_OMP, OPTGROUP_VEC, OPTGROUP_OTHER, OPTGROUP_ALL):
10997 Convert from macros to...
10998 (enum optgroup_flag): ...this new enum.
10999 (optgroup_flags_t): New typedef.
11000 (operator|, operator|=): Implement for optgroup_flags_t.
11001 (struct dump_file_info): Convert field "alt_flags" to
11002 dump_flags_t. Convert field "optgroup_flags" to
11004 (dump_basic_block): Use dump_flags_t rather than int for param.
11005 (dump_generic_expr_loc): Likewise.
11006 (dump_dec): Likewise.
11007 (dump_register): Convert param "optgroup_flags" to
11009 (opt_info_enable_passes): Likewise.
11010 * early-remat.c (early_remat::dump_edge_list): Use TDF_NONE rather
11012 * gimple-pretty-print.c (debug): Likewise.
11013 * gimple-ssa-store-merging.c (bswap_replace): Likewise.
11014 (merged_store_group::apply_stores): Likewise.
11015 * gimple-ssa-strength-reduction.c (insert_initializers): Likewise.
11016 * gimple.c (verify_gimple_pp): Likewise.
11017 * graphite-poly.c (print_pbb_body): Likewise.
11018 * passes.c (pass_manager::register_one_dump_file): Convert
11019 local "optgroup_flags" to optgroup_flags_t.
11020 * print-tree.c (print_node): Use TDF_NONE rather than 0.
11022 (debug_body): Likewise.
11023 * tree-pass.h (struct pass_data): Convert field "optgroup_flags"
11024 to optgroup_flags_t.
11025 * tree-pretty-print.c (print_struct_decl): Use TDF_NONE rather
11027 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Likewise.
11028 (convert_mult_to_fma): Likewise.
11029 * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
11030 * tree-ssa-sccvn.c (vn_eliminate): Likewise.
11031 * tree-vect-data-refs.c (dump_lower_bound): Convert param
11032 "dump_kind" to dump_flags_t.
11034 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
11036 * config/rs6000/rs6000.c (min, max): Delete.
11038 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
11040 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete mention of
11041 -mabi=spe and -mabi=no-spe.
11043 2018-06-08 Martin Liska <mliska@suse.cz>
11045 * ipa-pure-const.c (propagate_pure_const): Use ::get at places
11046 where we expect an existing summary.
11048 2018-06-08 Martin Liska <mliska@suse.cz>
11050 * ipa-inline-analysis.c (simple_edge_hints): Use ::get method.
11051 * ipa-inline.h (estimate_edge_growth): Likewise.
11053 2018-06-08 Martin Liska <mliska@suse.cz>
11055 * cgraph.c (function_version_hasher::hash): Use
11056 cgraph_node::get_uid ().
11057 (function_version_hasher::equal):
11058 * cgraph.h (cgraph_node::get_uid): New method.
11059 * ipa-inline.c (update_caller_keys): Use
11060 cgraph_node::get_uid ().
11061 (update_callee_keys): Likewise.
11062 * ipa-utils.c (searchc): Likewise.
11063 (ipa_reduced_postorder): Likewise.
11064 * lto-cgraph.c (input_node): Likewise.
11065 * passes.c (is_pass_explicitly_enabled_or_disabled): Likewise.
11066 * symbol-summary.h (symtab_insertion): Likewise.
11067 (symtab_removal): Likewise.
11068 (symtab_duplication): Likewise.
11069 * tree-pretty-print.c (dump_function_header): Likewise.
11070 * tree-sra.c (convert_callers_for_node): Likewise.
11072 2018-06-08 Martin Liska <mliska@suse.cz>
11074 * cgraph.c (symbol_table::create_edge): Always assign a new
11076 (symbol_table::free_edge): Do not recycle numbers.
11077 * cgraph.h (cgraph_edge::get): New method.
11078 * symbol-summary.h (symtab_removal): Use it.
11079 (symtab_duplication): Likewise.
11080 (call_summary::hashable_uid): Remove.
11082 2018-06-08 Martin Liska <mliska@suse.cz>
11084 * ipa-inline-analysis.c (inline_edge_removal_hook): Remove.
11085 (initialize_growth_caches): Remove.
11086 (free_growth_caches): Likewise.
11087 (do_estimate_edge_time): Use edge_growth_cache.
11088 (do_estimate_edge_size): Likewise.
11089 (do_estimate_edge_hints): Likewise.
11090 * ipa-inline.c (reset_edge_caches): Likewise.
11091 (recursive_inlining): Likewise.
11092 (inline_small_functions): Likewise.
11093 * ipa-inline.h (initialize_growth_caches): Remove.
11094 (estimate_edge_size): Likewise.
11095 (estimate_edge_time): Likewise.
11096 (estimate_edge_hints): Likewise.
11097 (reset_edge_growth_cache): Likewise.
11098 * symbol-summary.h (call_summary::remove): New method.
11100 2018-06-08 Martin Liska <mliska@suse.cz>
11102 * ipa-cp.c (class edge_clone_summary): New summary.
11103 (grow_edge_clone_vectors): Remove.
11104 (ipcp_edge_duplication_hook): Remove.
11105 (class edge_clone_summary_t): New call_summary class.
11106 (ipcp_edge_removal_hook): Remove.
11107 (edge_clone_summary_t::duplicate): New function.
11108 (get_next_cgraph_edge_clone): Use edge_clone_summaries.
11109 (create_specialized_node): Likewise.
11110 (ipcp_driver): Initialize edge_clone_summaries and do not
11113 2018-06-08 Martin Liska <mliska@suse.cz>
11115 * symbol-summary.h (get): New function.
11116 (call_summary::m_initialize_when_cloning): New class member.
11118 2018-06-08 Martin Liska <mliska@suse.cz>
11120 * cgraph.c (cgraph_node::remove): Do not recycle uid.
11121 * cgraph.h (symbol_table::release_symbol): Do not pass uid.
11122 (symbol_table::allocate_cgraph_symbol): Do not set uid.
11123 * passes.c (uid_hash_t): Record removed_nodes by their uids.
11124 (remove_cgraph_node_from_order): Use the removed_nodes set.
11125 (do_per_function_toporder): Likwise.
11126 * symbol-summary.h (symtab_insertion): Use cgraph_node::uid
11127 instead of summary_uid.
11128 (symtab_removal): Likewise.
11129 (symtab_duplication): Likewise.
11131 2018-06-08 Martin Liska <mliska@suse.cz>
11133 * ipa-cp.c (ipcp_store_bits_results): Use
11134 ipcp_transformation_sum.
11135 (ipcp_store_vr_results): Likewise.
11136 * ipa-prop.c (ipcp_grow_transformations_if_necessary): Renamed
11138 (ipcp_transformation_initialize): ... this.
11139 (ipa_set_node_agg_value_chain):
11140 (ipa_node_params_t::duplicate): Use ipcp_transformation_sum.
11141 (write_ipcp_transformation_info): Likewise.
11142 (read_ipcp_transformation_info): Likewise.
11143 (ipcp_update_bits): Likewise.
11144 (ipcp_update_vr): Likewise.
11145 (ipcp_transform_function): Likewise.
11146 * ipa-prop.h: Rename ipcp_transformation_summary to
11147 ipcp_transformation.
11148 (class ipcp_transformation_t): New function summary.
11149 (ipcp_get_transformation_summary): Use ipcp_transformation_sum.
11150 (ipa_get_agg_replacements_for_node): Likewise.
11152 2018-06-08 Martin Liska <mliska@suse.cz>
11154 * ipa-pure-const.c (struct funct_state_d): Do it class instead
11156 (class funct_state_summary_t): New function_summary class.
11157 (has_function_state): Remove.
11158 (get_function_state): Likewise.
11159 (set_function_state): Likewise.
11160 (add_new_function): Likewise.
11161 (funct_state_summary_t::insert): New function.
11162 (duplicate_node_data): Remove.
11163 (remove_node_data): Remove.
11164 (funct_state_summary_t::duplicate): New function.
11165 (register_hooks): Create new funct_state_summaries.
11166 (pure_const_generate_summary): Use it.
11167 (pure_const_write_summary): Likewise.
11168 (pure_const_read_summary): Likewise.
11169 (propagate_pure_const): Likewise.
11170 (propagate_nothrow): Likewise.
11171 (dump_malloc_lattice): Likewise.
11172 (propagate_malloc): Likewise.
11173 (execute): Do not register hooks, just remove summary
11175 (pass_ipa_pure_const::pass_ipa_pure_const): Simplify
11178 2018-06-08 Martin Liska <mliska@suse.cz>
11180 * ipa-reference.c (remove_node_data): Remove.
11181 (duplicate_node_data): Likewise.
11182 (class ipa_ref_var_info_summary_t): New class.
11183 (class ipa_ref_opt_summary_t): Likewise.
11184 (get_reference_vars_info): Use ipa_ref_var_info_summaries.
11185 (get_reference_optimization_summary): Use
11186 ipa_ref_opt_sum_summaries.
11187 (set_reference_vars_info): Remove.
11188 (set_reference_optimization_summary): Likewise.
11189 (ipa_init): Create summaries.
11190 (init_function_info): Use function summary.
11191 (ipa_ref_opt_summary_t::duplicate): New function.
11192 (ipa_ref_opt_summary_t::remove): New function.
11193 (get_read_write_all_from_node): Fix GNU coding style.
11194 (propagate): Use function summary.
11195 (write_node_summary_p): Fix GNU coding style.
11196 (stream_out_bitmap): Likewise.
11197 (ipa_reference_read_optimization_summary): Use function summary.
11198 (ipa_reference_c_finalize): Do not release hooks.
11200 2018-06-08 Martin Liska <mliska@suse.cz>
11202 * ipa-fnsummary.c (dump_ipa_call_summary): Use ::get method.
11203 (analyze_function_body): Extract multiple calls of get_create.
11204 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
11205 * ipa-inline.c (recursive_inlining): Use ::get method.
11206 * ipa-inline.h (estimate_edge_growth): Likewise.
11208 2018-06-08 Martin Liska <mliska@suse.cz>
11210 * hsa-common.h (enum hsa_function_kind): Rename HSA_NONE to
11212 (hsa_function_summary::hsa_function_summary): Use the new enum
11214 (hsa_gpu_implementation_p): Use hsa_summaries::get.
11215 * hsa-gen.c (hsa_get_host_function): Likewise.
11216 (get_brig_function_name): Likewise.
11217 * ipa-hsa.c (process_hsa_functions): Likewise.
11218 (ipa_hsa_write_summary): Likewise.
11219 * symbol-summary.h (symtab_duplication): Use ::get function/
11220 (get): New function.
11222 2018-06-08 Martin Liska <mliska@suse.cz>
11224 * config/i386/i386.c (ix86_can_inline_p): Use get_create instead
11226 * hsa-common.c (hsa_summary_t::link_functions): Likewise.
11227 (hsa_register_kernel): Likewise.
11228 * hsa-common.h (hsa_gpu_implementation_p): Likewise.
11229 * hsa-gen.c (hsa_get_host_function): Likewise.
11230 (get_brig_function_name): Likewise.
11231 (generate_hsa): Likewise.
11232 (pass_gen_hsail::execute): Likewise.
11233 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
11234 (devirtualization_time_bonus): Likewise.
11235 (ipcp_propagate_stage): Likewise.
11236 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
11237 (edge_set_predicate): Likewise.
11238 (evaluate_conditions_for_known_args): Likewise.
11239 (evaluate_properties_for_edge): Likewise.
11240 (ipa_fn_summary::reset): Likewise.
11241 (ipa_fn_summary_t::duplicate): Likewise.
11242 (dump_ipa_call_summary): Likewise.
11243 (ipa_dump_fn_summary): Likewise.
11244 (analyze_function_body): Likewise.
11245 (compute_fn_summary): Likewise.
11246 (estimate_edge_devirt_benefit): Likewise.
11247 (estimate_edge_size_and_time): Likewise.
11248 (estimate_calls_size_and_time): Likewise.
11249 (estimate_node_size_and_time): Likewise.
11250 (inline_update_callee_summaries): Likewise.
11251 (remap_edge_change_prob): Likewise.
11252 (remap_edge_summaries): Likewise.
11253 (ipa_merge_fn_summary_after_inlining): Likewise.
11254 (ipa_update_overall_fn_summary): Likewise.
11255 (read_ipa_call_summary): Likewise.
11256 (inline_read_section): Likewise.
11257 (write_ipa_call_summary): Likewise.
11258 (ipa_fn_summary_write): Likewise.
11259 (ipa_free_fn_summary): Likewise.
11260 * ipa-hsa.c (process_hsa_functions): Likewise.
11261 (ipa_hsa_write_summary): Likewise.
11262 (ipa_hsa_read_section): Likewise.
11263 * ipa-icf.c (sem_function::merge): Likewise.
11264 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
11265 (do_estimate_edge_time): Likewise.
11266 (estimate_size_after_inlining): Likewise.
11267 (estimate_growth): Likewise.
11268 (growth_likely_positive): Likewise.
11269 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
11270 (inline_call): Likewise.
11271 * ipa-inline.c (caller_growth_limits): Likewise.
11272 (can_inline_edge_p): Likewise.
11273 (can_inline_edge_by_limits_p): Likewise.
11274 (compute_uninlined_call_time): Likewise.
11275 (compute_inlined_call_time): Likewise.
11276 (want_inline_small_function_p): Likewise.
11277 (edge_badness): Likewise.
11278 (update_caller_keys): Likewise.
11279 (update_callee_keys): Likewise.
11280 (recursive_inlining): Likewise.
11281 (inline_small_functions): Likewise.
11282 (inline_to_all_callers_1): Likewise.
11283 (dump_overall_stats): Likewise.
11284 (early_inline_small_functions): Likewise.
11285 (early_inliner): Likewise.
11286 * ipa-inline.h (estimate_edge_growth): Likewise.
11287 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
11288 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
11289 * ipa-prop.h (IPA_NODE_REF): Likewise.
11290 (IPA_EDGE_REF): Likewise.
11291 * ipa-pure-const.c (malloc_candidate_p): Likewise.
11292 (propagate_malloc): Likewise.
11293 * ipa-split.c (execute_split_functions): Likewise.
11294 * symbol-summary.h: Rename get to get_create.
11296 (get_create): Likewise.
11297 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
11299 2018-06-08 Martin Liska <mliska@suse.cz>
11301 * symbol-summary.h (release): Move definition out of class
11303 (symtab_removal): Likewise.
11304 (symtab_duplication): Likewise.
11306 2018-06-08 Martin Liska <mliska@suse.cz>
11308 * symbol-summary.h (function_summary): Move constructor
11309 implementation out of class declaration.
11310 (release): Likewise.
11311 (symtab_insertion): Likewise.
11312 (symtab_removal): Likewise.
11313 (symtab_duplication): Likewise.
11316 2018-06-08 Martin Liska <mliska@suse.cz>
11318 * Makefile.in: Remove support for MPX (macros, related functions,
11319 fields in cgraph_node, ...).
11320 * builtin-types.def (BT_BND): Likewise.
11321 (BT_FN_BND_CONST_PTR): Likewise.
11322 (BT_FN_CONST_PTR_BND): Likewise.
11323 (BT_FN_VOID_PTR_BND): Likewise.
11324 (BT_FN_BND_CONST_PTR_SIZE): Likewise.
11325 (BT_FN_VOID_CONST_PTR_BND_CONST_PTR): Likewise.
11326 * builtins.c (expand_builtin_memcpy_with_bounds): Likewise.
11327 (expand_builtin_mempcpy_with_bounds): Likewise.
11328 (expand_builtin_memset_with_bounds): Likewise.
11329 (expand_builtin_memset_args): Likewise.
11330 (std_expand_builtin_va_start): Likewise.
11331 (expand_builtin): Likewise.
11332 (expand_builtin_with_bounds): Likewise.
11333 * builtins.def (DEF_BUILTIN_CHKP): Likewise.
11334 (DEF_LIB_BUILTIN_CHKP): Likewise.
11335 (DEF_EXT_LIB_BUILTIN_CHKP): Likewise.
11336 (DEF_CHKP_BUILTIN): Likewise.
11337 (BUILT_IN_MEMCPY): Likewise.
11338 (BUILT_IN_MEMMOVE): Likewise.
11339 (BUILT_IN_MEMPCPY): Likewise.
11340 (BUILT_IN_MEMSET): Likewise.
11341 (BUILT_IN_STPCPY): Likewise.
11342 (BUILT_IN_STRCAT): Likewise.
11343 (BUILT_IN_STRCHR): Likewise.
11344 (BUILT_IN_STRCPY): Likewise.
11345 (BUILT_IN_STRLEN): Likewise.
11346 (BUILT_IN_MEMCPY_CHK): Likewise.
11347 (BUILT_IN_MEMMOVE_CHK): Likewise.
11348 (BUILT_IN_MEMPCPY_CHK): Likewise.
11349 (BUILT_IN_MEMSET_CHK): Likewise.
11350 (BUILT_IN_STPCPY_CHK): Likewise.
11351 (BUILT_IN_STRCAT_CHK): Likewise.
11352 (BUILT_IN_STRCPY_CHK): Likewise.
11353 * calls.c (store_bounds): Likewise.
11354 (emit_call_1): Likewise.
11355 (special_function_p): Likewise.
11356 (maybe_warn_nonstring_arg): Likewise.
11357 (initialize_argument_information): Likewise.
11358 (finalize_must_preallocate): Likewise.
11359 (compute_argument_addresses): Likewise.
11360 (expand_call): Likewise.
11361 * cfgexpand.c (expand_call_stmt): Likewise.
11362 (expand_return): Likewise.
11363 (expand_gimple_stmt_1): Likewise.
11364 (pass_expand::execute): Likewise.
11365 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
11366 (cgraph_node::remove): Likewise.
11367 (cgraph_node::dump): Likewise.
11368 (cgraph_node::verify_node): Likewise.
11369 * cgraph.h (chkp_function_instrumented_p): Likewise.
11370 (symtab_node::get_alias_target): Likewise.
11371 (cgraph_node::can_remove_if_no_direct_calls_and_refs_p): Likewise.
11372 (cgraph_local_p): Likewise.
11373 * cgraphbuild.c (cgraph_edge::rebuild_edges): Likewise.
11374 (cgraph_edge::rebuild_references): Likewise.
11375 * cgraphunit.c (varpool_node::finalize_decl): Likewise.
11376 (walk_polymorphic_call_targets): Likewise.
11377 (cgraph_node::expand_thunk): Likewise.
11378 (symbol_table::output_weakrefs): Likewise.
11379 * common/config/i386/i386-common.c (OPTION_MASK_ISA2_GENERAL_REGS_ONLY_UNSET): Likewise.
11380 (ix86_handle_option): Likewise.
11381 * config/i386/constraints.md: Likewise.
11382 * config/i386/i386-builtin-types.def (BND): Likewise.
11386 * config/i386/i386-builtin.def (BDESC_END): Likewise.
11387 (BDESC_FIRST): Likewise.
11389 * config/i386/i386-c.c (ix86_target_macros_internal): Likewise.
11390 * config/i386/i386-protos.h (ix86_bnd_prefixed_insn_p): Likewise.
11391 * config/i386/i386.c (enum reg_class): Likewise.
11392 (ix86_target_string): Likewise.
11393 (ix86_option_override_internal): Likewise.
11394 (ix86_conditional_register_usage): Likewise.
11395 (ix86_valid_target_attribute_inner_p): Likewise.
11396 (ix86_set_indirect_branch_type): Likewise.
11397 (ix86_set_current_function): Likewise.
11398 (ix86_function_arg_regno_p): Likewise.
11399 (init_cumulative_args): Likewise.
11400 (ix86_function_arg_advance): Likewise.
11401 (ix86_function_arg): Likewise.
11402 (ix86_pass_by_reference): Likewise.
11403 (ix86_function_value_regno_p): Likewise.
11404 (ix86_function_value_1): Likewise.
11405 (ix86_function_value_bounds): Likewise.
11406 (ix86_return_in_memory): Likewise.
11407 (ix86_setup_incoming_vararg_bounds): Likewise.
11408 (ix86_va_start): Likewise.
11409 (indirect_thunk_need_prefix): Likewise.
11410 (print_reg): Likewise.
11411 (ix86_print_operand): Likewise.
11412 (ix86_expand_call): Likewise.
11413 (ix86_output_function_return): Likewise.
11414 (reg_encoded_number): Likewise.
11415 (BDESC_VERIFYS): Likewise.
11416 (ix86_init_mpx_builtins): Likewise.
11417 (ix86_init_builtins): Likewise.
11418 (ix86_emit_cmove): Likewise.
11419 (ix86_emit_move_max): Likewise.
11420 (ix86_expand_builtin): Likewise.
11421 (ix86_builtin_mpx_function): Likewise.
11422 (ix86_get_arg_address_for_bt): Likewise.
11423 (ix86_load_bounds): Likewise.
11424 (ix86_store_bounds): Likewise.
11425 (ix86_load_returned_bounds): Likewise.
11426 (ix86_store_returned_bounds): Likewise.
11427 (ix86_class_likely_spilled_p): Likewise.
11428 (ix86_hard_regno_mode_ok): Likewise.
11429 (x86_order_regs_for_local_alloc): Likewise.
11430 (ix86_mitigate_rop): Likewise.
11431 (ix86_bnd_prefixed_insn_p): Likewise.
11432 (ix86_mpx_bound_mode): Likewise.
11433 (ix86_make_bounds_constant): Likewise.
11434 (ix86_initialize_bounds): Likewise.
11435 (TARGET_LOAD_BOUNDS_FOR_ARG): Likewise.
11436 (TARGET_STORE_BOUNDS_FOR_ARG): Likewise.
11437 (TARGET_LOAD_RETURNED_BOUNDS): Likewise.
11438 (TARGET_STORE_RETURNED_BOUNDS): Likewise.
11439 (TARGET_CHKP_BOUND_MODE): Likewise.
11440 (TARGET_BUILTIN_CHKP_FUNCTION): Likewise.
11441 (TARGET_CHKP_FUNCTION_VALUE_BOUNDS): Likewise.
11442 (TARGET_CHKP_MAKE_BOUNDS_CONSTANT): Likewise.
11443 (TARGET_CHKP_INITIALIZE_BOUNDS): Likewise.
11444 * config/i386/i386.h (TARGET_MPX): Likewise.
11445 (TARGET_MPX_P): Likewise.
11446 (VALID_BND_REG_MODE): Likewise.
11447 (FIRST_BND_REG): Likewise.
11448 (LAST_BND_REG): Likewise.
11449 (enum reg_class): Likewise.
11450 (BND_REG_P): Likewise.
11451 (BND_REGNO_P): Likewise.
11452 (BNDmode): Likewise.
11453 (ADJUST_INSN_LENGTH): Likewise.
11454 * config/i386/i386.md: Likewise.
11455 * config/i386/i386.opt: Likewise.
11456 * config/i386/linux-common.h (LIBMPX_LIBS): Likewise.
11457 (defined): Likewise.
11458 (LINK_MPX): Likewise.
11459 (MPX_SPEC): Likewise.
11460 (LIBMPX_SPEC): Likewise.
11461 (LIBMPXWRAPPERS_SPEC): Likewise.
11462 (CHKP_SPEC): Likewise.
11463 * config/i386/predicates.md: Likewise.
11464 * dbxout.c (dbxout_type): Likewise.
11465 * doc/extend.texi: Likewise.
11466 * doc/invoke.texi: Likewise.
11467 * doc/md.texi: Likewise.
11468 * doc/tm.texi: Likewise.
11469 * doc/tm.texi.in: Likewise.
11470 * dwarf2out.c (is_base_type): Likewise.
11471 (gen_formal_types_die): Likewise.
11472 (gen_subprogram_die): Likewise.
11473 (gen_type_die_with_usage): Likewise.
11474 (gen_decl_die): Likewise.
11475 (dwarf2out_late_global_decl): Likewise.
11476 * expr.c (expand_assignment): Likewise.
11477 (emit_storent_insn): Likewise.
11478 (store_expr_with_bounds): Likewise.
11479 (store_expr): Likewise.
11480 (expand_expr_real_1): Likewise.
11481 * expr.h (store_expr_with_bounds): Likewise.
11482 * function.c (use_register_for_decl): Likewise.
11483 (struct bounds_parm_data): Likewise.
11484 (assign_parms_augmented_arg_list): Likewise.
11485 (assign_parm_find_entry_rtl): Likewise.
11486 (assign_parm_is_stack_parm): Likewise.
11487 (assign_parm_load_bounds): Likewise.
11488 (assign_bounds): Likewise.
11489 (assign_parms): Likewise.
11490 (expand_function_start): Likewise.
11491 * gcc.c (CHKP_SPEC): Likewise.
11492 * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
11493 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Likewise.
11494 (wrestrict_dom_walker::check_call): Likewise.
11495 * gimple.c (gimple_build_call_from_tree): Likewise.
11496 * gimple.h (enum gf_mask): Likewise.
11497 (gimple_call_with_bounds_p): Likewise.
11498 (gimple_call_set_with_bounds): Likewise.
11499 * gimplify.c (gimplify_init_constructor): Likewise.
11500 * ipa-cp.c (initialize_node_lattices): Likewise.
11501 (propagate_constants_across_call): Likewise.
11502 (find_more_scalar_values_for_callers_subset): Likewise.
11503 * ipa-hsa.c (process_hsa_functions): Likewise.
11504 * ipa-icf-gimple.c (func_checker::compare_gimple_call): Likewise.
11505 * ipa-icf.c (sem_function::merge): Likewise.
11506 * ipa-inline.c (early_inliner): Likewise.
11507 * ipa-pure-const.c (warn_function_noreturn): Likewise.
11508 (warn_function_cold): Likewise.
11509 (propagate_pure_const): Likewise.
11510 * ipa-ref.h (enum GTY): Likewise.
11511 * ipa-split.c (find_retbnd): Likewise.
11512 (consider_split): Likewise.
11513 (split_function): Likewise.
11514 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
11515 * ipa.c (walk_polymorphic_call_targets): Likewise.
11516 (symbol_table::remove_unreachable_nodes): Likewise.
11517 (process_references): Likewise.
11518 (cgraph_build_static_cdtor_1): Likewise.
11519 * lto-cgraph.c (lto_output_node): Likewise.
11520 (output_refs): Likewise.
11521 (compute_ltrans_boundary): Likewise.
11522 (input_overwrite_node): Likewise.
11523 (input_node): Likewise.
11524 (input_cgraph_1): Likewise.
11525 * params.def (PARAM_CHKP_MAX_CTOR_SIZE): Likewise.
11526 * passes.c (pass_manager::execute_early_local_passes): Likewise.
11527 (class pass_chkp_instrumentation_passes): Likewise.
11528 (make_pass_chkp_instrumentation_passes): Likewise.
11529 * passes.def: Likewise.
11530 * rtl.h (struct GTY): Likewise.
11531 (CALL_EXPR_WITH_BOUNDS_P): Likewise.
11532 * stor-layout.c (layout_type): Likewise.
11533 * symtab.c: Likewise.
11534 * target.def: Likewise.
11535 * targhooks.c (default_chkp_bound_type): Likewise.
11536 (default_chkp_bound_mode): Likewise.
11537 (default_builtin_chkp_function): Likewise.
11538 (default_chkp_function_value_bounds): Likewise.
11539 (default_chkp_make_bounds_constant): Likewise.
11540 (default_chkp_initialize_bounds): Likewise.
11541 * targhooks.h (default_chkp_bound_type): Likewise.
11542 (default_chkp_bound_mode): Likewise.
11543 (default_builtin_chkp_function): Likewise.
11544 (default_chkp_function_value_bounds): Likewise.
11545 (default_chkp_make_bounds_constant): Likewise.
11546 (default_chkp_initialize_bounds): Likewise.
11547 * toplev.c (compile_file): Likewise.
11548 (process_options): Likewise.
11549 * tree-core.h (DEF_BUILTIN): Likewise.
11550 (DEF_BUILTIN_CHKP): Likewise.
11551 * tree-inline.c (declare_return_variable): Likewise.
11552 (remap_gimple_stmt): Likewise.
11553 (copy_bb): Likewise.
11554 (initialize_inlined_parameters): Likewise.
11555 (expand_call_inline): Likewise.
11556 * tree-pass.h (make_pass_ipa_chkp_versioning): Likewise.
11557 (make_pass_ipa_chkp_early_produce_thunks): Likewise.
11558 (make_pass_ipa_chkp_produce_thunks): Likewise.
11559 (make_pass_chkp): Likewise.
11560 (make_pass_chkp_opt): Likewise.
11561 (make_pass_chkp_instrumentation_passes): Likewise.
11562 * tree-pretty-print.c (dump_generic_node): Likewise.
11563 * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Likewise.
11564 * tree-ssa-dce.c (propagate_necessity): Likewise.
11565 (eliminate_unnecessary_stmts): Likewise.
11566 * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
11567 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
11568 * tree-ssa-sccvn.h: Likewise.
11569 * tree-ssa-strlen.c (get_string_length): Likewise.
11570 (valid_builtin_call): Likewise.
11571 (adjust_last_stmt): Likewise.
11572 (handle_builtin_strchr): Likewise.
11573 (handle_builtin_strcpy): Likewise.
11574 (handle_builtin_stxncpy): Likewise.
11575 (handle_builtin_memcpy): Likewise.
11576 (handle_builtin_strcat): Likewise.
11577 (strlen_check_and_optimize_stmt): Likewise.
11578 * tree-stdarg.c (expand_ifn_va_arg_1): Likewise.
11579 * tree-streamer-in.c: Likewise.
11580 * tree-streamer.c (record_common_node): Likewise.
11581 * tree.c (tree_code_size): Likewise.
11582 (wide_int_to_tree_1): Likewise.
11583 (type_contains_placeholder_1): Likewise.
11584 (build_common_tree_nodes): Likewise.
11585 * tree.def (POINTER_BOUNDS_TYPE): Likewise.
11586 * tree.h (POINTER_BOUNDS_TYPE_P): Likewise.
11587 (POINTER_BOUNDS_P): Likewise.
11588 (BOUNDED_TYPE_P): Likewise.
11589 (BOUNDED_P): Likewise.
11590 (CALL_WITH_BOUNDS_P): Likewise.
11591 (pointer_bounds_type_node): Likewise.
11592 * value-prof.c (gimple_ic): Likewise.
11593 * var-tracking.c (vt_add_function_parameters): Likewise.
11594 * varasm.c (make_decl_rtl): Likewise.
11595 (assemble_start_function): Likewise.
11596 (output_constant): Likewise.
11597 (maybe_assemble_visibility): Likewise.
11598 * varpool.c (ctor_for_folding): Likewise.
11599 * chkp-builtins.def: Remove.
11600 * ipa-chkp.c: Remove.
11601 * ipa-chkp.h: Remove.
11602 * rtl-chkp.c: Remove.
11603 * rtl-chkp.h: Remove.
11604 * tree-chkp-opt.c: Remove.
11605 * tree-chkp.c: Remove.
11606 * tree-chkp.h: Remove.
11608 2018-06-07 Carl Love <cel@us.ibm.com>
11610 * config/rs6000/vsx.md (vextract_fp_from_shorth,
11611 vextract_fp_from_shortl): Add BE support.
11613 2018-06-07 Paul Koning <ni1d@arrl.net>
11615 * compare-elim.c (try_merge_compare): Don't merge compare if
11616 address contains a side effect.
11617 (try_eliminate_compare): Likewise.
11619 2018-06-07 Olga Makhotina <olga.makhotina@intel.com>
11621 * config.gcc: Support "tremont".
11622 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "tremont".
11623 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
11625 * config/i386/i386.c (m_TREMONT): Define.
11626 (processor_target_table): Add "tremont".
11627 (PTA_TREMONT): Define.
11628 (ix86_lea_outperforms): Add TARGET_TREMONT.
11629 (get_builtin_code_for_version): Handle PROCESSOR_TREMONT.
11630 (fold_builtin_cpu): Add M_INTEL_TREMONT, replace M_INTEL_GOLDMONT
11631 and M_INTEL_GOLDMONT_PLUS.
11632 (fold_builtin_cpu): Add "tremont".
11633 (ix86_add_stmt_cost): Add TARGET_TREMONT.
11634 (ix86_option_override_internal): Add "tremont".
11635 * config/i386/i386.h (processor_costs): Define TARGET_TREMONT.
11636 (processor_type): Add PROCESSOR_TREMONT.
11637 * config/i386/x86-tune.def: Add m_TREMONT.
11638 * doc/invoke.texi: Add tremont as x86 -march=/-mtune= CPU type.
11640 2018-06-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
11642 * config/msp430/msp430.c (msp430_mcu_name): Set the "i" in the
11643 symbol defined for msp430i* devices to be lower case.
11645 2018-06-07 Richard Biener <rguenther@suse.de>
11647 * graphite-sese-to-poly.c (extract_affine): Avoid unneded
11648 wrapping. Properly wrap the result of a BIT_NOT_EXPR.
11649 Properly wrap signed arithmetic if overflow wraps.
11651 2018-06-07 Jakub Jelinek <jakub@redhat.com>
11653 PR tree-optimization/69615
11654 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If rhs2 is lhs
11655 of a cast from a same precision integral SSA_NAME in a bb dominated
11656 by first_bb, retry with rhs2 set to the rhs1 of the cast. Don't emit
11657 cast to utype if rhs2 has already a compatible type.
11659 2018-06-07 Richard Biener <rguenther@suse.de>
11661 PR tree-optimization/85935
11662 * graphite-scop-detection.c (find_params_in_bb): Analyze
11663 condition operands with respect to the correct loop. Assert
11664 the analysis doesn't fail.
11666 2018-06-04 Carl Love <cel@us.ibm.com>
11668 * config/rs6000/vsx.md (first_match_index_<mode>): Calculate index
11669 using natural element order. Use gen_lshrsi3 instead of gen_ashrsi3
11670 as it is slightly cheaper.
11671 (first_match_or_eos_index_<mode>):
11672 Calculate index using natural element order.
11673 (first_match_index_<mode>):
11674 Calculate index using natural element order.
11675 (first_match_or_eos_index_<mode>):
11676 Calculate index using natural order.
11677 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
11678 for BE and LE modes.
11679 * config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
11680 P9V_BUILTIN_VCLZLSBB_V16QI.
11681 * config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
11684 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
11686 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
11687 indentation and line wrap for many prototypes. Add missing
11688 @smallexample directives around block of prototypes for vec_xl and
11691 2018-06-05 Michael Meissner <meissner@linux.ibm.com>
11693 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
11694 track if we pass or return IEEE 128-bit floating point.
11695 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
11696 C++ mangling that is compatible with GCC 8.1.
11697 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
11698 (init_cumulative_args): Note if we pass or return IEEE 128-bit
11699 floating point types.
11700 (rs6000_function_arg_advance_1): Likewise.
11701 (rs6000_mangle_type): Optionally generate mangled names that match
11702 what GCC 8.1 generated for IEEE 128-bit floating point types.
11703 (rs6000_globalize_decl_name): If we have an external function that
11704 passes or returns IEEE 128-bit types, generate a weak reference
11705 from the mangled name used in GCC 8.1 to the current mangled
11707 (rs6000_init_builtins): Make __ibm128 use the long double type if
11708 long double is IBM extended double. Make __float128 use the long
11709 double type if long double is IEEE 128-bit.
11712 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
11713 macro for __ibm128 built-in functions.
11714 (PACK_IF): Add __ibm128 pack/unpack functions.
11715 (UNPACK_IF): Likewise.
11716 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
11717 enable long double built-in functions if long double is IEEE
11718 128-bit floating point.
11719 (rs6000_invalid_builtin): Update long double built-in function
11721 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
11722 functions, adjust the built-in function to use the long double
11723 built-in function if __ibm128 and long double are the same type.
11724 * doc/extend.texi (PowerPC builtins): Update documention for
11725 __builtin_{,un}pack_longdouble. Add documentation for
11726 __builtin_{,un}pack_ibm128.
11728 2018-06-06 Jim Wilson <jimw@sifive.com>
11730 * config/riscv/riscv.c (enum riscv_privilege_levels): New.
11731 (struct machine_function): New field interrupt_mode.
11732 (riscv_handle_type_attribute): New function. Add forward declaration.
11733 (riscv_attribute_table) <interrupt>: Use riscv_handle_type_attribute.
11734 (riscv_expand_epilogue): Check interrupt_mode field.
11735 (riscv_set_current_function): Check interrupt attribute args and
11736 set interrupt_mode field.
11737 * config/riscv/riscv.md (UNSPECV_SRET, UNSPECV_URET): New.
11738 (riscv_sret, riscv_uret): New.
11739 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: Document
11740 new arguments to interrupt attribute.
11742 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
11745 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
11746 Don't handle -mcpu=power8 if -mpower9-vector is also used.
11748 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
11750 * config/rs6000/rs6000-builtin.def (VSX_BUILTIN_VEC_LD,
11751 VSX_BUILTIN_VEC_ST): Add comment to explain non-traditional uses.
11752 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
11753 several redundant entries.
11755 2018-06-06 David Malcolm <dmalcolm@redhat.com>
11757 * config/i386/i386-protos.h (ix86_expand_call): Strengthen return
11758 type from "rtx" to "rtx_insn *".
11759 * config/i386/i386.c (ix86_expand_split_stack_prologue): Likewise
11760 for local "call_insn", removing cast.
11761 (ix86_expand_call): Likewise, introducing a "call_insn" local.
11763 2018-06-06 Eric Botcazou <ebotcazou@adacore.com>
11765 PR tree-optimization/86066
11766 * gimple-ssa-store-merging.c (process_store): Do not bypass BIT_NOT_EXPR
11767 for BIT_INSERT_EXPR stores.
11769 2018-06-06 Richard Biener <rguenther@suse.de>
11771 PR tree-optimization/86062
11772 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
11773 component refs ontop
11774 of to be offsetted base.
11776 2018-06-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
11778 * config/msp430/msp430.c (msp430_attr): Allow interrupt handlers
11779 to be static and remove check on interrupt attribute name.
11781 2018-06-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
11783 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
11784 volatile qualifier from vec_lvsl and vec_lvsr argument prototypes.
11786 2018-06-05 Steve Ellcey <sellcey@cavium.com>
11789 * config/aarch64/aarch64-protos.h (aarch64_err_no_fpadvsimd): Remove
11791 * config/aarch64/aarch64-protos..c (aarch64_err_no_fpadvsimd):
11792 Remove second argument, change how error is called.
11793 (aarch64_layout_arg): Remove second argument from
11794 aarch64_err_no_fpadvsimd call.
11795 (aarch64_init_cumulative_args): Ditto.
11796 (aarch64_gimplify_va_arg_expr): Ditto.
11797 * config/aarch64/aarch64.md (mov<mode>): Ditto.
11799 2018-06-05 Uros Bizjak <ubizjak@gmail.com>
11801 * config/i386/i386.md (simple_return_indirect_internal): New expander.
11802 (*simple_return_indirect_internal<mode>): Rename from
11803 simple_return_indirect_internal. Use W mode iterator.
11804 (rstorssp): New expander.
11805 (*rstorssp<mode>): Rename from rstorssp. Use P mode iterator.
11806 (clrssbsy): New expander.
11807 (*clrssbsy<mode>): Rename from clrssbsy. Use P mode iterator.
11809 2018-06-05 Andre Vieira <andre.simoesdiasvieira@arm.com>
11811 * config/arm/arm_cmse.h (cmse_nsfptr_create): Change typeof to
11813 (cmse_check_pointed_object): Likewise.
11815 2018-06-05 Martin Liska <mliska@suse.cz>
11817 PR gcov-profile/47618
11818 * doc/invoke.texi: Document how -fprofile-dir format
11821 2018-06-05 Richard Biener <rguenther@suse.de>
11823 * tree-cfgcleanup.c (cleanup_control_flow_pre): For edge
11824 removal pretend DOM info isn't available so we do not update
11825 it and only remove edges, not dominated blocks. Actually free
11826 DOM info in case we removed something. Remove unreachable blocks.
11827 (mfb_keep_latches): Work with either DOM info or marked backedges.
11828 (cleanup_tree_cfg_noloop): Do not remove unreachable blocks
11829 first. Mark backedges if DOM info isn't available.
11830 (Re-)compute DOM info after cleanup_control_flow_pre.
11832 2018-06-05 Richard Biener <rguenther@suse.de>
11834 * tree-cfg.c (struct locus_discrim_map): Store line, not location.
11835 (locus_discrim_hasher::hash): Adjust.
11836 (locus_discrim_hasher::equal): Likewise.
11837 (next_discriminator_for_locus): Work on line directly.
11838 (same_line_p): Pass in expanded locus1 as well.
11839 (assign_discriminators): Avoid redundant location expansions.
11841 2018-06-05 Richard Biener <rguenther@suse.de>
11843 PR tree-optimization/86046
11844 * tree-ssa.c (maybe_optimize_var): Clear DECL_GIMPLE_REG_P
11845 if required after clearing TREE_ADDRESSABLE.
11847 2018-06-05 Richard Biener <rguenther@suse.de>
11849 PR tree-optimization/86047
11850 * tree-ssa-loop.c (for_each_index): Glob handling of all
11851 decls and constants and really handle all of them.
11853 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11856 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
11857 qualifier_void_pointer and qualifier_const_void_pointer.
11858 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
11859 (arm_init_builtins): Handle the above.
11860 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
11861 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
11862 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
11865 2018-06-05 Martin Liska <mliska@suse.cz>
11867 * auto-profile.c (read_autofdo_file): Do not use
11868 gcov_ctr_summary struct.
11869 (afdo_callsite_hot_enough_for_early_inline): Likewise.
11870 * coverage.c (struct counts_entry): Likewise.
11871 (read_counts_file): Read just single summary entry.
11872 (get_coverage_counts): Use gcov_summary struct.
11873 * coverage.h (get_coverage_counts): Likewise.
11874 * gcov-dump.c (dump_working_sets): Likewise.
11875 (tag_summary): Dump just single summary.
11876 * gcov-io.c (gcov_write_summary): Write just histogram
11878 (gcov_read_summary): Read just single summary.
11879 (compute_working_sets): Use gcov_summary struct.
11880 * gcov-io.h (GCOV_TAG_SUMMARY_LENGTH): Remove usage
11881 of GCOV_COUNTERS_SUMMABLE.
11882 (GCOV_COUNTERS_SUMMABLE): Remove.
11883 (GCOV_FIRST_VALUE_COUNTER): Replace with
11884 GCOV_COUNTER_V_INTERVAL.
11885 (struct gcov_ctr_summary): Remove.
11886 (struct gcov_summary): Directly use fields of former
11888 (compute_working_sets): Use gcov_summary struct.
11889 * gcov.c (read_count_file): Do not use ctrs fields.
11890 * lto-cgraph.c (merge_profile_summaries): Use gcov_summary
11892 * lto-streamer.h (struct GTY): Make profile_info gcov_summary
11894 * profile.c: Likewise.
11895 * profile.h: Likewise.
11897 2018-06-05 Martin Liska <mliska@suse.cz>
11899 PR gcov-profile/84846
11900 * gcov.c (output_lines): Print working directory only
11901 in intermediate format.
11903 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
11905 * config/s390/s390-builtin-types.def: Add void function type.
11906 * config/s390/s390-builtins.def: Use the function type for the
11909 2018-06-04 Jim Wilson <jimw@sifive.com>
11911 * config/riscv/riscv-protos.h (riscv_expand_epilogue): Change bool arg
11913 * config/riscv/riscv.c (riscv_for_each_saved_reg): New args epilogue
11914 and maybe_eh_return. Change regno to unsigned int. Use new args to
11915 handle EH_RETURN_DATA_REGNO registers properly.
11916 (riscv_expand_prologue): Pass new args to riscv_for_each_saved_reg.
11917 (riscv_expand_epilogue): Update comment. Change argument name and
11918 type. Update code to use new name and type. Pass new args to
11919 riscv_for_each_saved_reg. Only use EH_RETURN_STACKADJ_RTX when
11921 * config/riscv/riscv.md (NORMAL_RETURN): New.
11922 (SIBCALL_RETURN, EXCEPTION_RETURN): New.
11923 (epilogue, sibcall_epilogue): Update riscv_expand_epilogue arg.
11924 (eh_return): Call gen_eh_return_internal and emit barrier.
11925 (eh_return_internal): Call riscv_expand_epilogue.
11927 2018-06-04 Eric Botcazou <ebotcazou@adacore.com>
11929 * gimple-ssa-store-merging.c (struct merged_store_group): Move up
11930 bit_insertion field and declare can_be_merged_into method.
11931 (merged_store_group::can_be_merged_into): New method.
11932 (imm_store_chain_info::coalesce_immediate): Call it to decide whether
11933 consecutive non-overlapping stores can be merged. Turn MEM_REF stores
11934 into BIT_INSERT_EXPR stores if the group contains a non-MEM_REF store.
11936 2018-06-04 Richard Biener <rguenther@suse.de>
11938 PR tree-optimization/85955
11939 * builtins.c (fold_builtin_sincos): Convert pointers to
11940 destination to appropriate type before dereferencing.
11942 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
11944 * config/rs6000/rs6000.md (abs<mode>2 for FLOAT128): Handle IFmode.
11946 2018-06-04 Richard Sandiford <richard.sandiford@linaro.org>
11948 * expr.c (expand_expr_real_1): Force the operand into memory if
11949 its TYPE_MODE is BLKmode and if there is no integer mode for
11950 the number of bits being extracted.
11952 2018-06-04 Jakub Jelinek <jakub@redhat.com>
11956 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
11957 Use vptestnm rather than vptestm in (=Yc,v,C) variant.
11959 2018-06-04 Richard Biener <rguenther@suse.de>
11961 * tree-cfgcleanup.c (cleanup_tree_cfg_1): Fold into...
11962 (cleanup_tree_cfg_noloop): ... single caller. Do
11963 start_recording_case_labels later.
11965 2018-06-04 Sebastian Peryt <sebastian.peryt@intel.com>
11967 * config/i386/cldemoteintrin.h: Change define from _X86INTRIN_H_INCLUDED
11968 to _IMMINTRIN_H_INCLUDED.
11969 * config/i386/pconfigintrin.h: Ditto.
11970 * config/i386/waitpkgintrin.h: Ditto.
11971 * config/i386/immintrin.h: Add includes for sgxintrin.h,
11972 pconfigintrin.h, waitpkgintrin.h and cldemoteintrin.h.
11973 * config/i386/x86intrin.h: Remove includes for mintrin.h, xmmintrin.h,
11974 emmintrin.h, pmmintrin.h, tmmintrin.h, smmintrin.h, wmmintrin.h,
11975 bmiintrin.h, bmi2intrin.h, lzcntintrin.h, sgxintrin.h, pconfigintrin.h,
11976 waitpkgintrin.h and cldemoteintrin.h.
11978 2018-06-04 Richard Biener <rguenther@suse.de>
11980 PR tree-optimization/86038
11981 * tracer.c (find_best_successor): Check probability for
11982 being initialized, bail out if not.
11984 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
11987 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
11988 of bits to ignore when comparing architectures.
11990 2018-06-04 Jakub Jelinek <jakub@redhat.com>
11992 PR tree-optimization/69615
11993 * fold-const.c (merge_ranges): If range1 is - [x, x] and x is the
11994 maximum or minimum of the type, try to merge it also as if
11995 range1 is + [-, x - 1] or + [x + 1, -].
11998 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
12000 2018-06-03 Eric Botcazou <ebotcazou@adacore.com>
12002 PR tree-optimization/86034
12003 * gimple-ssa-store-merging.c (output_merged_store): Convert the RHS to
12004 the unsigned bitfield type in a bit insertion sequence if it does not
12005 have a larger precision than the bitfield size.
12006 (process_store): Also bypass widening conversions for BIT_INSERT_EXPR.
12008 2018-06-03 Kito Cheng <kito.cheng@gmail.com>
12010 * config/nds32/nds32-peephole2.md: Add new patterns for code size.
12012 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
12014 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3J.
12015 * config/nds32/nds32.c (nds32_option_override): Consider ARCH_V3J.
12016 * config/nds32/nds32.h (TARGET_ISA_V3): Add ARCH_V3J checking.
12017 * config/nds32/nds32.opt (march): Add enum value Value(ARCH_V3J).
12019 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
12021 * common/config/nds32/nds32-common.c (nds32_option_optimization_table):
12022 Disable -fdelete-null-pointer-checks for ELF toolchain.
12024 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
12025 Kito Cheng <kito.cheng@gmail.com>
12027 * config.gcc (nds32*): Use nds32-linux.opt and nds32-elf.opt.
12028 (nds32le-*-*, nds32be-*-*): Integrate checking process.
12029 (nds32*-*-*): Add glibc and uclibc conditions.
12030 * common/config/nds32/nds32-common.c (nds32_except_unwind_info): New.
12031 (TARGET_EXCEPT_UNWIND_INFO): Define.
12032 * config/nds32/elf.h: New file.
12033 * config/nds32/linux.h: New file.
12034 * config/nds32/nds32-elf.opt: New file.
12035 * config/nds32/nds32-linux.opt: New file.
12036 * config/nds32/nds32-fp-as-gp.c
12037 (pass_nds32_fp_as_gp::gate): Consider TARGET_LINUX_ABI.
12038 * config/nds32/nds32.c (nds32_conditional_register_usage): Consider
12040 (nds32_asm_file_end): Ditto.
12041 (nds32_print_operand): Ditto.
12042 (nds32_insert_attributes): Ditto.
12043 (nds32_init_libfuncs): New function.
12044 (TARGET_HAVE_TLS): Define.
12045 (TARGET_INIT_LIBFUNCS): Define.
12046 * config/nds32/nds32.h (TARGET_DEFAULT_RELAX): Apply different relax
12048 (TARGET_ELF): Apply different mcmodel setting.
12049 (LINK_SPEC, LIB_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): The content has
12050 been migrated into elf.h and linux.h files.
12051 * config/nds32/nds32.md (add_pc): Consider TARGET_LINUX_ABI.
12052 * config/nds32/nds32.opt (mvh): Consider TARGET_LINUX_ABI.
12053 (mcmodel): The content has been migrated into nds32-elf.opt and
12054 nds32-linux.opt files.
12055 * config/nds32/t-elf: New file.
12056 * config/nds32/t-linux: New file.
12058 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
12059 Shiva Chen <shiva0217@gmail.com>
12061 * config/nds32/constants.md (unspec_volatile_element): Add
12062 UNSPEC_VOLATILE_OMIT_FP_BEGIN and UNSPEC_VOLATILE_OMIT_FP_END.
12063 * config/nds32/nds32-fp-as-gp.c: New implementation of fp_as_gp
12065 * config/nds32/nds32-protos.h (nds32_naked_function_p): Declare.
12066 (make_pass_nds32_fp_as_gp): Declare.
12067 * config/nds32/nds32.c (nds32_register_passes): Add fp_as_gp as one
12069 (nds32_asm_function_end_prologue): Remove unused asm output.
12070 (nds32_asm_function_begin_epilogue): Remove unused asm output.
12071 (nds32_asm_file_start): Output necessary fp_as_gp information.
12072 (nds32_option_override): Adjust register usage.
12073 (nds32_expand_prologue): Consider fp_as_gp situation.
12074 (nds32_expand_prologue_v3push): Consider fp_as_gp situation.
12075 * config/nds32/nds32.md (prologue): Check fp_as_gp_p and naked_p.
12078 (simple_return): Ditto.
12079 (omit_fp_begin): Output special directive for fp_as_gp.
12080 (omit_fp_end): Output special directive for fp_as_gp.
12081 * config/nds32/nds32.opt (mfp-as-gp, mno-fp-as-gp, mforce-fp-as-gp,
12082 mforbid-fp-as-gp): New options.
12084 2018-06-01 Mark Wielaard <mark@klomp.org>
12086 * dwarf2out.c (dwarf2out_finish): Remove generation of
12087 DW_AT_loclists_base.
12089 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
12091 * gimple-ssa-store-merging.c: Include gimple-fold.h.
12092 (struct store_immediate_info): Document BIT_INSERT_EXPR stores.
12093 (struct merged_store_group): Add bit_insertion field.
12094 (dump_char_array): Use standard hexadecimal format.
12095 (merged_store_group::merged_store_group): Set bit_insertion to false.
12096 (merged_store_group::apply_stores): Use optimal buffer size. Deal
12097 with BIT_INSERT_EXPR stores. Move up code updating the mask and
12098 also print the mask in the dump file.
12099 (pass_store_merging::gate): Minor tweak.
12100 (imm_store_chain_info::coalesce_immediate): Fix wrong association
12101 of stores with groups in dump. Allow coalescing of BIT_INSERT_EXPR
12102 stores with INTEGER_CST stores.
12103 (count_multiple_uses) <BIT_INSERT_EXPR>: New case.
12104 (imm_store_chain_info::output_merged_store): Add try_bitpos variable
12105 and use it throughout. Generate bit insertion sequences if need be.
12106 (pass_store_merging::process_store): Remove redundant condition.
12107 Record stores from a SSA name to a bit-field with BIT_INSERT_EXPR.
12109 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
12111 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
12112 the 128-bit floating point types. Fix function comment.
12114 2018-06-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12116 * config/aarch64/aarch64-simd.md
12117 (aarch64_simd_vec_unpack<su>_lo_<mode>): Use UXTL and SXTL assembler
12119 (aarch64_simd_vec_unpack<su>_hi_<mode>): Use UXTL2 and SXTL2 assembler
12122 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
12124 PR tree-optimization/85989
12125 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
12127 (backprop::intersect_uses): Check it when deciding whether this
12128 is a backedge reference.
12129 (backprop::process_block): Add each phi to m_visited_phis
12130 after visiting it, then clear it at the end.
12132 2018-06-01 Richard Biener <rguenther@suse.de>
12134 * tree-vectorizer.h (vect_dr_stmt): New function.
12135 (vect_get_load_cost): Adjust.
12136 (vect_get_store_cost): Likewise.
12137 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence):
12138 Use vect_dr_stmt instead of DR_SMTT.
12139 (vect_record_base_alignments): Likewise.
12140 (vect_calculate_target_alignment): Likewise.
12141 (vect_compute_data_ref_alignment): Likewise and make static.
12142 (vect_update_misalignment_for_peel): Likewise.
12143 (vect_verify_datarefs_alignment): Likewise.
12144 (vector_alignment_reachable_p): Likewise.
12145 (vect_get_data_access_cost): Likewise. Pass down
12146 vinfo to vect_get_load_cost/vect_get_store_cost instead of DR.
12147 (vect_get_peeling_costs_all_drs): Likewise.
12148 (vect_peeling_hash_get_lowest_cost): Likewise.
12149 (vect_enhance_data_refs_alignment): Likewise.
12150 (vect_find_same_alignment_drs): Likewise.
12151 (vect_analyze_data_refs_alignment): Likewise.
12152 (vect_analyze_group_access_1): Likewise.
12153 (vect_analyze_group_access): Likewise.
12154 (vect_analyze_data_ref_access): Likewise.
12155 (vect_analyze_data_ref_accesses): Likewise.
12156 (vect_vfa_segment_size): Likewise.
12157 (vect_small_gap_p): Likewise.
12158 (vectorizable_with_step_bound_p): Likewise.
12159 (vect_prune_runtime_alias_test_list): Likewise.
12160 (vect_analyze_data_refs): Likewise.
12161 (vect_supportable_dr_alignment): Likewise.
12162 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
12163 (vect_gen_prolog_loop_niters): Likewise.
12164 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
12165 * tree-vect-patterns.c (vect_recog_bool_pattern): Do not
12167 (vect_recog_mask_conversion_pattern): Likewise.
12168 (vect_try_gather_scatter_pattern): Likewise.
12169 * tree-vect-stmts.c (vect_model_store_cost): Pass stmt_info
12170 to vect_get_store_cost.
12171 (vect_get_store_cost): Get stmt_info instead of DR.
12172 (vect_model_load_cost): Pass stmt_info to vect_get_load_cost.
12173 (vect_get_load_cost): Get stmt_info instead of DR.
12175 2018-06-01 Richard Biener <rguenther@suse.de>
12177 PR middle-end/86017
12178 * gimple-fold.c (var_decl_component_p): Also allow offsetted
12179 vars wrapped in MEM_REFs.
12181 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
12183 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
12184 Fix subreg tests so that we only return a choice between
12185 GENERAL_REGS and FP_REGS if the original classes included both.
12187 2018-06-01 Richard Biener <rguenther@suse.de>
12190 * tree-ssa-structalias.c (get_function_part_constraint):
12191 Handle NULL fi->decl.
12192 (find_func_aliases_for_call): Properly handle indirect
12193 fi from direct call.
12194 (find_func_clobbers): Likewise.
12195 (ipa_pta_execute): Likewise.
12196 (create_variable_info_for): For functions that are ifunc_resolver
12197 resolve to a varinfo that contains the result of the resolver call.
12198 (associate_varinfo_to_alias): Do not treat ifunc resolvers as
12201 2018-05-31 Michael Collison <michael.collison@arm.com>
12203 * config/aarch64/aarch64.md:
12204 (*fix_to_zero_extenddfdi2): New pattern.
12205 * gcc.target/aarch64/fix_extend1.c: New testcase.
12207 2018-05-31 Qing Zhao <qing.zhao@oracle.com>
12209 PR middle-end/78809
12210 PR middle-end/83026
12211 * builtins.c (expand_builtin): Add the handling of BUILT_IN_STRCMP_EQ
12212 and BUILT_IN_STRNCMP_EQ.
12213 * builtins.def: Add new builtins BUILT_IN_STRCMP_EQ and
12214 BUILT_IN_STRNCMP_EQ.
12215 * gimple-fold.c (gimple_fold_builtin_string_compare): Add the
12216 handling of BUILTIN_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
12217 (gimple_fold_builtin): Likewise.
12218 * tree-ssa-strlen.c (compute_string_length): New function.
12219 (determine_min_obsize): New function.
12220 (handle_builtin_string_cmp): New function to handle calls to
12221 string compare functions.
12222 (strlen_optimize_stmt): Add handling to builtin string compare
12224 * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
12225 Add the handling of BUILT_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
12226 * tree.c (build_common_builtin_nodes): Add new defines of
12227 BUILT_IN_STRNCMP_EQ and BUILT_IN_STRCMP_EQ.
12229 2018-05-31 Jakub Jelinek <jakub@redhat.com>
12232 * bb-reorder.c (pass_partition_blocks::gate): Return false for
12233 functions with naked attribute.
12235 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
12237 * config/i386/sse.md (avx_vec_concat<mode>):
12238 Substitute concat_tg_mode mode attribute with xtg_mode.
12239 (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Ditto.
12240 (concat_tg_mode): Remove mode attribute.
12242 2018-05-31 Martin Sebor <msebor@redhat.com>
12245 * calls.c (alloc_max_size): Correct a logic error/typo.
12246 Treat excessive arguments as infinite. Warn for invalid arguments.
12247 * doc/invoke.texi (-Walloc-size-larger-than): Update.
12249 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
12252 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
12253 and movx for Haswell.
12255 2018-05-31 Chung-Lin Tang <cltang@codesourcery.com>
12256 Cesar Philippidis <cesar@codesourcery.com>
12258 PR middle-end/85879
12259 * gimplify.c (gimplify_adjust_omp_clauses): Add 'remove = true'
12260 when emitting error on private/firstprivate reductions.
12261 * omp-low.c (lower_omp_target): Avoid reference-type processing
12262 on pointers for firstprivate clause.
12264 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
12266 * config/aarch64/aarch64-simd-builtins.def (ld1x3): New.
12269 * config/aarch64/aarch64-simd.md
12270 (aarch64_ld1x3<VALLDIF:mode>): New pattern.
12271 (aarch64_ld1_x3_<mode>): Likewise
12272 (aarch64_st1x2<VALLDIF:mode>): Likewise
12273 (aarch64_st1_x2_<mode>): Likewise
12274 (aarch64_st1x3<VALLDIF:mode>): Likewise
12275 (aarch64_st1_x3_<mode>): Likewise
12276 * config/aarch64/arm_neon.h (vld1_u8_x3): New function.
12277 (vld1_s8_x3): Likewise.
12278 (vld1_u16_x3): Likewise.
12279 (vld1_s16_x3): Likewise.
12280 (vld1_u32_x3): Likewise.
12281 (vld1_s32_x3): Likewise.
12282 (vld1_u64_x3): Likewise.
12283 (vld1_s64_x3): Likewise.
12284 (vld1_f16_x3): Likewise.
12285 (vld1_f32_x3): Likewise.
12286 (vld1_f64_x3): Likewise.
12287 (vld1_p8_x3): Likewise.
12288 (vld1_p16_x3): Likewise.
12289 (vld1_p64_x3): Likewise.
12290 (vld1q_u8_x3): Likewise.
12291 (vld1q_s8_x3): Likewise.
12292 (vld1q_u16_x3): Likewise.
12293 (vld1q_s16_x3): Likewise.
12294 (vld1q_u32_x3): Likewise.
12295 (vld1q_s32_x3): Likewise.
12296 (vld1q_u64_x3): Likewise.
12297 (vld1q_s64_x3): Likewise.
12298 (vld1q_f16_x3): Likewise.
12299 (vld1q_f32_x3): Likewise.
12300 (vld1q_f64_x3): Likewise.
12301 (vld1q_p8_x3): Likewise.
12302 (vld1q_p16_x3): Likewise.
12303 (vld1q_p64_x3): Likewise.
12304 (vst1_s64_x2): Likewise.
12305 (vst1_u64_x2): Likewise.
12306 (vst1_f64_x2): Likewise.
12307 (vst1_s8_x2): Likewise.
12308 (vst1_p8_x2): Likewise.
12309 (vst1_s16_x2): Likewise.
12310 (vst1_p16_x2): Likewise.
12311 (vst1_s32_x2): Likewise.
12312 (vst1_u8_x2): Likewise.
12313 (vst1_u16_x2): Likewise.
12314 (vst1_u32_x2): Likewise.
12315 (vst1_f16_x2): Likewise.
12316 (vst1_f32_x2): Likewise.
12317 (vst1_p64_x2): Likewise.
12318 (vst1q_s8_x2): Likewise.
12319 (vst1q_p8_x2): Likewise.
12320 (vst1q_s16_x2): Likewise.
12321 (vst1q_p16_x2): Likewise.
12322 (vst1q_s32_x2): Likewise.
12323 (vst1q_s64_x2): Likewise.
12324 (vst1q_u8_x2): Likewise.
12325 (vst1q_u16_x2): Likewise.
12326 (vst1q_u32_x2): Likewise.
12327 (vst1q_u64_x2): Likewise.
12328 (vst1q_f16_x2): Likewise.
12329 (vst1q_f32_x2): Likewise.
12330 (vst1q_f64_x2): Likewise.
12331 (vst1q_p64_x2): Likewise.
12332 (vst1_s64_x3): Likewise.
12333 (vst1_u64_x3): Likewise.
12334 (vst1_f64_x3): Likewise.
12335 (vst1_s8_x3): Likewise.
12336 (vst1_p8_x3): Likewise.
12337 (vst1_s16_x3): Likewise.
12338 (vst1_p16_x3): Likewise.
12339 (vst1_s32_x3): Likewise.
12340 (vst1_u8_x3): Likewise.
12341 (vst1_u16_x3): Likewise.
12342 (vst1_u32_x3): Likewise.
12343 (vst1_f16_x3): Likewise.
12344 (vst1_f32_x3): Likewise.
12345 (vst1_p64_x3): Likewise.
12346 (vst1q_s8_x3): Likewise.
12347 (vst1q_p8_x3): Likewise.
12348 (vst1q_s16_x3): Likewise.
12349 (vst1q_p16_x3): Likewise.
12350 (vst1q_s32_x3): Likewise.
12351 (vst1q_s64_x3): Likewise.
12352 (vst1q_u8_x3): Likewise.
12353 (vst1q_u16_x3): Likewise.
12354 (vst1q_u32_x3): Likewise.
12355 (vst1q_u64_x3): Likewise.
12356 (vst1q_f16_x3): Likewise.
12357 (vst1q_f32_x3): Likewise.
12358 (vst1q_f64_x3): Likewise.
12359 (vst1q_p64_x3): Likewise.
12361 2018-05-30 Jozef Lawrynowicz <jozef.l@mittosystems.com>
12363 * config/msp430/msp430.c (msp430_output_labelref): Prepend
12364 user_label_prefix to name.
12366 * tree-core.h: Update comment about the format of NAME string
12367 passed to handler in attribute_spec.
12369 * config/msp430/msp430.md: Remove erroneous subreg expression from
12370 zero_extendqisi2 insn pattern. Remove msp430x ISA restriction on
12371 zero_extend{q,h}isi2.
12373 2018-05-30 Borislav Petkov <bp@suse.de>
12375 * doc/extend.texi: Document some architecture specific
12376 constraints and sort entries.
12378 2018-05-30 Martin Sebor <msebor@redhat.com>
12380 PR middle-end/85369
12381 * builtins.c (expand_builtin_stpcpy_1): New function.
12382 (expand_builtin_stpcpy): Call it, and call maybe_warn_nonstring_arg
12383 only if the former succeeds.
12385 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
12387 * config/aarch64/aarch64-cores.def (saphira) : Add support for ARMv8.4
12390 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
12392 * doc/invoke.texi (-flinker-output): Document
12394 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
12396 * passes.c (ipa_write_summaries): Only modify statements if body
12398 * cgraphunit.c (ipa_passes): Also produce intermeidate code when
12399 incrementally linking.
12400 (ipa_passes): Likewise.
12401 * lto-cgraph.c (lto_output_node): When incrementally linking do not
12402 pass down resolution info.
12403 * common.opt (flag_incremental_link): Update info.
12404 * gcc.c (plugin specs): Turn flinker-output=* to
12405 -plugin-opt=-linker-output-known
12406 * toplev.c (compile_file): Also cut compilation when doing incremental
12408 * flag-types. (enum lto_partition_model): Add
12409 LTO_LINKER_OUTPUT_NOLTOREL.
12410 (invoke.texi): Add -flinker-output docs.
12411 * ipa.c (symbol_table::remove_unreachable_nodes): Handle LTO incremental
12412 link same way as WPA; do not stream in dead initializers.
12414 * dwarf2out.c (dwarf2out_die_ref_for_decl,
12415 darf2out_register_external_decl): Support incremental link.
12417 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
12419 * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_.
12421 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
12423 * lto-wrapper.c (debug_objcopy): Add rename parameter; pass
12424 it down to simple_object_copy_lto_debug_sections.
12425 (run_gcc): Determine incremental LTO link time and configure
12426 lto1 into non-wpa mode, disable renaming of debug sections.
12428 2018-05-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
12430 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
12431 descriptions of various incorrectly documented functions.
12433 2018-05-30 Andre Vieira <andre.simoesdiasvieira@arm.com>
12436 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
12437 address check not strict.
12439 2018-05-30 Richard Biener <rguenther@suse.de>
12441 PR tree-optimization/85964
12442 * tracer.c (better_p): Drop initialized count check, we only
12443 call the function with initialized counts now.
12444 (find_best_successor): Do find a best edge if one
12445 has uninitialized count.
12446 (find_best_predecessor): Likewise. Do BB frequency check only
12447 if count is initialized.
12449 2017-05-30 Jackson Woodruff <jackson.woodruff@arm.com>
12451 * config/aarch64/aarch64.c (aarch64_host_wide_int_compare): New.
12452 (aarch64_ldrstr_offset_compare): New.
12453 (aarch64_operands_adjust_ok_for_ldpstp): Update to consider all
12454 load/store orderings.
12455 (aarch64_gen_adjusted_ldpstp): Likewise.
12457 2018-05-30 Wilco Dijkstra <wdijkstr@arm.com>
12459 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
12460 Check for subset of GENERAL_REGS and FP_REGS.
12461 * config/aarch64/aarch64-simd.md (aarch64_get_lane): Increase cost of
12464 2018-05-30 Richard Sandiford <richard.sandiford@linaro.org>
12466 * alias.c (adjust_offset_for_component_ref): Use poly_int_tree_p
12467 and wi::to_poly_offset. Add the current offset and then check
12468 whether the sum fits, rather than using an unchecked addition of
12469 a checked term. Check for a shwi rather than a uhwi.
12470 * expr.c (get_bit_range): Use tree_to_poly_uint64.
12471 (store_constructor): Use poly_int_tree_p.
12472 (expand_expr_real_1): Likewise.
12473 * function.c (assign_temp): Likewise.
12474 * fold-const.c (const_binop): Use poly_int_tree_p and
12475 wi::to_poly_offset.
12476 (fold_indirect_ref_1): Likewise. Use multiple_p to attempt an exact
12478 * ipa-icf-gimple.c (func_checker::compare_operand): Use
12479 to_poly_offset for MEM offsets.
12480 * ipa-icf.c (sem_variable::equals): Likewise.
12481 * stor-layout.c (compute_record_mode): Use poly_int_tree_p.
12482 * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Use
12483 wi::to_poly_offset for BIT_FIELD_REF offsets.
12484 (vn_reference_maybe_forwprop_address): Use poly_int_tree_p and
12485 wi::to_poly_offset.
12486 * var-tracking.c (emit_note_insn_var_location): Use
12487 tree_to_poly_uint64.
12489 2018-05-29 Jim Wilson <jimw@sifive.com>
12491 * config/riscv/riscv.c (riscv_interrupt_type): Fix comment typo.
12493 2018-05-29 Uros Bizjak <ubizjak@gmail.com>
12496 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
12497 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
12499 (sse4_1_round<mode>2): Use nonimmediate_operand
12500 for operand 1 predicate.
12502 2018-05-29 Martin Sebor <msebor@redhat.com>
12503 Richard Biener <rguenther@suse.de>
12506 * calls.c (get_size_range): Call determine_value_range instead
12507 of get_value_range..
12508 * tree-vrp.h (determine_value_range): Declared new function.
12509 * tree-vrp.c (determine_value_range_1, determine_value_range): New.
12511 2018-05-29 Richard Biener <rguenther@suse.de>
12513 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Make
12514 sure to use non-pattern stmts for get_earlier_stmt arguments.
12515 * tree-vectorizer.h (get_earlier_stmt): Assert we do not get
12516 called on pattern stmts.
12517 (get_later_stmt): Likewise.
12519 2018-05-29 Martin Liska <mliska@suse.cz>
12521 PR gcov-profile/85759
12522 * doc/gcov.texi: Document GCOV_ERROR_FILE and GCOV_EXIT_AT_ERROR
12525 2018-05-29 Jakub Jelinek <jakub@redhat.com>
12527 * tree-cfg.c (verify_gimple_assign_unary): Add checking for
12529 (verify_gimple_assign_binary): Check TYPE_VECTOR_SUBPARTS for
12533 * tree.def (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
12534 VEC_PACK_FLOAT_EXPR): New tree codes.
12535 * tree-pretty-print.c (op_code_prio): Handle
12536 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR.
12537 (dump_generic_node): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
12538 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
12539 * tree-inline.c (estimate_operator_cost): Likewise.
12540 * gimple-pretty-print.c (dump_binary_rhs): Handle VEC_PACK_FLOAT_EXPR.
12541 * fold-const.c (const_binop): Likewise.
12542 (const_unop): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR and
12543 VEC_UNPACK_FIX_TRUNC_LO_EXPR.
12544 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
12545 (verify_gimple_assign_binary): Handle VEC_PACK_FLOAT_EXPR.
12546 * cfgexpand.c (expand_debug_expr): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
12547 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
12548 * expr.c (expand_expr_real_2): Likewise.
12549 * optabs.def (vec_packs_float_optab, vec_packu_float_optab,
12550 vec_unpack_sfix_trunc_hi_optab, vec_unpack_sfix_trunc_lo_optab,
12551 vec_unpack_ufix_trunc_hi_optab, vec_unpack_ufix_trunc_lo_optab): New
12553 * optabs.c (expand_widen_pattern_expr): For
12554 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR use
12555 sign from result type rather than operand's type.
12556 (expand_binop_directly): For vec_packu_float_optab and
12557 vec_packs_float_optab allow result type to be different from operand's
12559 * optabs-tree.c (optab_for_tree_code): Handle
12560 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
12561 VEC_PACK_FLOAT_EXPR. Formatting fixes.
12562 * tree-vect-generic.c (expand_vector_operations_1): Handle
12563 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
12564 VEC_PACK_FLOAT_EXPR.
12565 * tree-vect-stmts.c (supportable_widening_operation): Handle
12567 (supportable_narrowing_operation): Handle FLOAT_EXPR.
12568 * config/i386/i386.md (fixprefix, floatprefix): New code attributes.
12569 * config/i386/sse.md (*float<floatunssuffix>v2div2sf2): Rename to ...
12570 (float<floatunssuffix>v2div2sf2): ... this. Formatting fix.
12571 (vpckfloat_concat_mode, vpckfloat_temp_mode, vpckfloat_op_mode): New
12573 (vec_pack<floatprefix>_float_<mode>): New expander.
12574 (vunpckfixt_mode, vunpckfixt_model, vunpckfixt_extract_mode): New mode
12576 (vec_unpack_<fixprefix>fix_trunc_lo_<mode>,
12577 vec_unpack_<fixprefix>fix_trunc_hi_<mode>): New expanders.
12578 * doc/md.texi (vec_packs_float_@var{m}, vec_packu_float_@var{m},
12579 vec_unpack_sfix_trunc_hi_@var{m}, vec_unpack_sfix_trunc_lo_@var{m},
12580 vec_unpack_ufix_trunc_hi_@var{m}, vec_unpack_ufix_trunc_lo_@var{m}):
12582 * doc/generic.texi (VEC_UNPACK_FLOAT_HI_EXPR,
12583 VEC_UNPACK_FLOAT_LO_EXPR): Fix pasto in description.
12584 (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
12585 VEC_PACK_FLOAT_EXPR): Document.
12587 2018-05-29 Richard Biener <rguenther@suse.de>
12589 * tree-vectorizer.h (struct vec_info): Add stmt_vec_infos
12591 (stmt_vec_info_vec): Make pointer.
12592 (init_stmt_vec_info_vec): Remove.
12593 (free_stmt_vec_info_vec): Likewise.
12594 (set_stmt_vec_info_vec): New function.
12595 (free_stmt_vec_infos): Likewise.
12596 (vinfo_for_stmt): Adjust for stmt_vec_info_vec indirection.
12597 (set_vinfo_for_stmt): Likewise.
12598 (get_earlier_stmt): Likewise.
12599 (get_later_stmt): Likewise.
12600 * tree-vectorizer.c (stmt_vec_info_vec): Make pointer.
12601 (vec_info::vec_info): Allocate stmt_vec_infos and set the global.
12602 (vec_info::~vec_info): Free stmt_vec_infos.
12603 (vectorize_loops): Set the global stmt_vec_info_vec to NULL.
12604 Remove old init_stmt_vec_info_vec/free_stmt_vec_info_vec calls.
12605 (pass_slp_vectorize::execute): Likewise.
12606 * tree-vect-stmts.c (init_stmt_vec_info_vec): Remove.
12607 (free_stmt_vec_info_vec): Likewise.
12608 (set_stmt_vec_info_vec): New function.
12609 (free_stmt_vec_infos): Likewise.
12610 * tree-vect-loop.c (_loop_vec_info::~_loop_vec_info): Set
12611 the global stmt_vec_info_vec.
12612 * tree-parloops.c (gather_scalar_reductions): Use
12613 set_stmt_vec_info_vec/free_stmt_vec_infos and maintain a local
12616 2018-05-29 Richard Biener <rguenther@suse.de>
12618 * dominance.c (iterate_fix_dominators): Push/pop TV_DOMINANCE.
12620 2018-05-29 Martin Liska <mliska@suse.cz>
12621 David Malcolm <dmalcolm@redhat.com>
12623 * vec.c (test_reverse): New.
12624 (vec_c_tests): Add new test.
12625 * vec.h (vl_ptr>::reverse): New function.
12627 2018-05-29 Gerald Pfeifer <gerald@pfeifer.com>
12629 * config.gcc: Identify FreeBSD 3.x and 4.x as unsupported.
12631 * config/freebsd-spec.h (FBSD_LIB_SPEC): Only consider FreeBSD 5
12634 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
12636 * tree-dump.c (dump_node): Use splay_tree_delete_pointers.
12638 2018-05-28 Richard Biener <rguenther@suse.de>
12640 PR tree-optimization/85933
12641 * tree-vect-data-refs.c (vect_record_base_alignments): Only
12642 look at stmts marked as vectorizable.
12644 2018-05-28 Richard Biener <rguenther@suse.de>
12646 PR tree-optimization/85934
12647 * tree-vect-generic.c (expand_vector_operations_1): Hoist
12648 vector boolean check before scalar optimization.
12650 2018-05-28 Jakub Jelinek <jakub@redhat.com>
12652 * doc/invoke.texi (ARM Options): Use @item instead of @itemx
12655 2018-05-28 Mark Wielaard <mark@klomp.org>
12657 * dwarf2asm.c (dw2_asm_output_delta_uleb128): Add brackets around lab2
12658 if it is an expression containing a minus sign.
12660 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
12662 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
12664 2018-05-27 Paul Koning <ni1d@arrl.net>
12666 * config/pdp11/pdp11.md (truncsihi2): Remove.
12668 2018-05-27 Monk Chiang <sh.chiang04@gmail.com>
12669 Chung-Ju Wu <jasonwucj@gmail.com>
12671 * config/nds32/nds32-intrinsic.md (unaligned_storedi): Modify patterns
12673 (unaligned_store_dw): Ditto.
12674 * config/nds32/nds32-memory-manipulation.c
12675 (nds32_expand_movmemsi_loop_known_size): Refactoring implementation.
12676 (nds32_gen_dup_4_byte_to_word_value): Rename to ...
12677 (nds32_gen_dup_4_byte_to_word_value_aux): ... this.
12678 (emit_setmem_word_loop): Rename to ...
12679 (emit_setmem_doubleword_loop): ... this.
12680 (nds32_gen_dup_4_byte_to_word_value): New function.
12681 (nds32_gen_dup_8_byte_to_double_word_value): New function.
12682 (nds32_expand_setmem_loop): Refine implementation.
12683 (nds32_expand_setmem_loop_v3m): Ditto.
12684 * config/nds32/nds32-multiple.md (unaligned_store_update_base_dw): New
12687 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
12689 * config/nds32/nds32.md (bswapsi2, bswaphi2): New patterns.
12691 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
12693 * config/nds32/nds32.c (nds32_attribute_table): Add "no_prologue".
12694 (nds32_init_machine_status): Initialize machine->attr_naked_p and
12695 machine->attr_no_prologue_p.
12696 (nds32_compute_stack_frame): Check "naked" and "no_prologue" attributes.
12697 (nds32_naked_function_p): Handle "naked" and "no_prologue" attributes.
12698 (nds32_expand_epilogue): Consider attr_naked_p.
12699 (nds32_expand_epilogue_v3pop): Likewise.
12700 (nds32_can_use_return_insn): Likewise.
12701 * config/nds32/nds32.h (machine_function): Add attr_naked_p and
12702 attr_no_prologue_p fields.
12703 * config/nds32/nds32.opt (mret-in-naked-func): New option.
12705 2018-05-27 Jakub Jelinek <jakub@redhat.com>
12708 * config/i386/i386.md (fixunssuffix, floatunssuffix): New code
12710 * config/i386/sse.md
12711 (<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>):
12713 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
12715 (<floatsuffix>float<sselongvecmodelower><mode>2<mask_name><round_name>):
12717 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
12719 (*<floatsuffix>floatv2div2sf2): Rename to ...
12720 (*float<floatunssuffix>v2div2sf2): ... this.
12721 (<floatsuffix>floatv2div2sf2_mask): Rename to ...
12722 (float<floatunssuffix>v2div2sf2_mask): ... this.
12723 (*<floatsuffix>floatv2div2sf2_mask_1): Rename to ...
12724 (*float<floatunssuffix>v2div2sf2_mask_1): ... this.
12725 (<fixsuffix>fix_truncv8dfv8si2<mask_name><round_saeonly_name>): Rename
12727 (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
12729 (<fixsuffix>fix_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
12731 (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
12733 (<fixsuffix>fix_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
12735 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
12737 (<fixsuffix>fix_truncv2sfv2di2<mask_name>): Rename to ...
12738 (fix<fixunssuffix>_truncv2sfv2di2<mask_name>): ... this.
12739 (vec_pack_ufix_trunc_<mode>): Use gen_fixuns_truncv8dfv8si2 instead of
12740 gen_ufix_truncv8dfv8si2.
12741 * config/i386/i386-builtin.def (__builtin_ia32_cvttpd2uqq256_mask,
12742 __builtin_ia32_cvttpd2uqq128_mask, __builtin_ia32_cvttps2uqq256_mask,
12743 __builtin_ia32_cvttps2uqq128_mask, __builtin_ia32_cvtuqq2ps256_mask,
12744 __builtin_ia32_cvtuqq2ps128_mask, __builtin_ia32_cvtuqq2pd256_mask,
12745 __builtin_ia32_cvtuqq2pd128_mask, __builtin_ia32_cvttpd2udq512_mask,
12746 __builtin_ia32_cvtuqq2ps512_mask, __builtin_ia32_cvtuqq2pd512_mask,
12747 __builtin_ia32_cvttps2uqq512_mask, __builtin_ia32_cvttpd2uqq512_mask):
12748 Use fixuns instead ufix or floatuns instead ufloat in CODE_FOR_ names.
12750 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
12754 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
12756 2018-05-25 Jim Wilson <jimw@sifive.com>
12758 * config/riscv/riscv-protos.h (riscv_epilogue_uses): New.
12759 * config/riscv/riscv.c (struct machine_function): Add
12760 interrupt_handler_p and attribute_checked_p fields.
12761 (riscv_attribute_table): Add interrupt.
12762 (riscv_interrupt_type_p): New.
12763 (riscv_save_reg_p): Save extra regs for interrupt handler.
12764 (riscv_use_save_libcall): Return false for interrupt handler.
12765 (riscv_first_stack_step): Add forward declaration.
12766 (riscv_compute_frame_info): New local interrupt_save_t1. Set it
12767 for interrupt handler with large frame. Use it for saved reg list.
12768 (riscv_expand_prologue): Move flag_stack_usage_info support to
12769 eliminate duplication.
12770 (riscv_expand_epilogue): Generate mret for interrupt handler.
12771 (riscv_epilogue_uses): New.
12772 (riscv_can_use_return_insn): Return false for interrupt handler.
12773 (riscv_function_ok_for_sibcall): Likewise.
12774 (riscv_set_current_function): Add interrupt handler support.
12775 * config/riscv/riscv.h (EPILOGUE_USES): Call riscv_epilogue_uses.
12776 * config/riscv/riscv.md (UNSPECV_MRET): New.
12778 (riscv_frflags, riscv_fsflags): Use tab after opcode.
12780 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: New.
12782 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
12784 PR tree-optimization/85712
12785 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
12786 this candidate has already been replaced in-situ by a copy.
12788 2018-05-25 Jason Merrill <jason@redhat.com>
12790 PR c++/80485 - inline function non-zero address.
12791 * symtab.c (nonzero_address): Check DECL_COMDAT.
12793 2018-05-25 Uros Bizjak <ubizjak@gmail.com>
12796 * config/alpha/alpha.md (ashlsi3): New insn pattern.
12797 (*ashlsi_se): Rename from *ashldi_se. Define as sign
12798 extension of SImode operation. Use const123_operand predicate.
12799 (*saddsi_1): Remove.
12800 (*saddl_se_1): Ditto.
12801 (*ssubsi_1): Ditto.
12802 (*ssubl_se_1): Ditto.
12803 * config/alpha/predicates.md (const123_operand): New predicate.
12804 * config/alpha/constraints.md (P): Use IN_RANGE.
12806 2018-05-25 Richard Biener <rguenther@suse.de>
12808 * tree-ssa-alias.h (refs_may_alias_p): Add tbaa_p bool parameter,
12810 (ref_maybe_used_by_stmt_p): Likewise.
12811 (stmt_may_clobber_ref_p): Likewise.
12812 (stmt_may_clobber_ref_p_1): Likewise.
12813 * tree-ssa-alias.c (refs_may_alias_p): Add tbaa_p bool parameter
12815 (ref_maybe_used_by_stmt_p): Likewise.
12816 (stmt_may_clobber_ref_p): Likewise.
12817 (stmt_may_clobber_ref_p_1): Likewise.
12818 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Use
12819 the alias oracle to disambiguate DRs with stmts DR analysis
12821 (vect_analyze_data_refs): Do not give up on not analyzable
12822 DRs for BB vectorization. Remove code truncating the dataref
12825 2018-05-25 Jakub Jelinek <jakub@redhat.com>
12828 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
12829 Add (=Yk,v,C) variant using vptestm insn. Use TARGET_AVX512BW
12830 in test instead of TARGET_AVX512F for VI12_AVX512VL iterator.
12832 2018-05-25 Richard Biener <rguenther@suse.de>
12834 * tree-vect-data-refs.c (vect_find_stmt_data_reference): New
12835 function, combining stmt data ref gathering and fatal analysis
12837 (vect_analyze_data_refs): Remove now redudnant code and simplify.
12838 * tree-vect-loop.c (vect_get_datarefs_in_loop): Factor out from
12839 vect_analyze_loop_2 and use vect_find_stmt_data_reference.
12840 * tree-vect-slp.c (vect_slp_bb): Use vect_find_stmt_data_reference.
12841 * tree-vectorizer.h (vect_find_stmt_data_reference): Declare.
12843 2018-05-25 Bin Cheng <bin.cheng@arm.com>
12845 PR tree-optimization/85720
12846 * tree-loop-distribution.c (break_alias_scc_partitions): Don't merge
12847 SCC if all partitions are builtins.
12848 (version_loop_by_alias_check): New parameter. Generate cancelable
12849 runtime alias check if all partitions are builtins.
12850 (distribute_loop): Update call to above function.
12852 2018-05-25 Bin Cheng <bin.cheng@arm.com>
12854 * tree-outof-ssa.c (tree-ssa.h, tree-dfa.h): Include header files.
12855 (create_default_def, for_all_parms): Moved from tree-ssa-coalesce.c.
12856 (parm_default_def_partition_arg): Ditto.
12857 (set_parm_default_def_partition): Ditto.
12858 (get_parm_default_def_partitions): Ditto and make it static.
12859 (get_undefined_value_partitions): Ditto and make it static.
12860 (remove_ssa_form): Refactor call to init_var_map here.
12861 * tree-ssa-coalesce.c (build_ssa_conflict_graph): Support live range
12862 computation for loop region.
12863 (coalesce_partitions, compute_optimized_partition_bases): Ditto.
12864 (register_default_def): Delete.
12865 (for_all_parms, create_default_def): Move to tree-outof-ssa.c.
12866 (parm_default_def_partition_arg): Ditto.
12867 (set_parm_default_def_partition): Ditto.
12868 (get_parm_default_def_partitions): Ditto and make it static.
12869 (get_undefined_value_partitions): Ditto and make it static.
12870 (coalesce_with_default, coalesce_with_default): Update comment.
12871 (create_coalesce_list_for_region): New func factored out from
12872 create_outofssa_var_map.
12873 (populate_coalesce_list_for_outofssa): New func factored out from
12874 create_outofssa_var_map and coalesce_ssa_name.
12875 (create_outofssa_var_map): Delete.
12876 (coalesce_ssa_name): Refactor to support live range computation.
12877 * tree-ssa-coalesce.h (coalesce_ssa_name): Change decl.
12878 (get_parm_default_def_partitions): Delete.
12879 (get_undefined_value_partitions): Ditto.
12880 * tree-ssa-live.c (init_var_map, delete_var_map): Support live range
12881 computation for loop region.
12882 (new_tree_live_info, loe_visit_block): Ditto.
12883 (live_worklist, set_var_live_on_entry): Ditto.
12884 (calculate_live_on_exit, verify_live_on_entry): Ditto.
12885 * tree-ssa-live.h (struct _var_map): New fields.
12886 (init_var_map): Change decl.
12887 (region_contains_p): New.
12889 2018-05-25 Bin Cheng <bin.cheng@arm.com>
12891 * tree-ssa-live.h (live_merge_and_clear): Delete.
12893 2018-05-25 Richard Biener <rguenther@suse.de>
12896 * tree-dump.c (dequeue_and_dump): Remove access to removed
12897 operand 2 of a SWITCH_EXPR.
12899 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
12901 * doc/sourcebuild.texi (vect_double_cond_arith): Include
12902 multiplication and division.
12903 * doc/md.texi (cond_mul@var{m}, cond_div@var{m}, cond_mod@var{m})
12904 (cond_udiv@var{m}, cond_umod@var{m}): Document.
12905 * optabs.def (cond_smul_optab, cond_sdiv_optab, cond_smod_optab)
12906 (cond_udiv_optab, cond_umod_optab): New optabs.
12907 * internal-fn.def (IFN_COND_MUL, IFN_COND_DIV, IFN_COND_MOD)
12908 (IFN_COND_RDIV): New internal functions.
12909 * internal-fn.c (get_conditional_internal_fn): Handle TRUNC_DIV_EXPR,
12910 TRUNC_MOD_EXPR and RDIV_EXPR.
12911 * match.pd (UNCOND_BINARY, COND_BINARY): Handle them.
12912 * config/aarch64/iterators.md (UNSPEC_COND_MUL, UNSPEC_COND_DIV):
12914 (SVE_INT_BINARY): Include mult.
12915 (SVE_COND_FP_BINARY): Include UNSPEC_MUL and UNSPEC_DIV.
12916 (optab, sve_int_op): Handle mult.
12917 (optab, sve_fp_op, commutative): Handle UNSPEC_COND_MUL and
12919 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New pattern
12920 for SVE_INT_BINARY_SD.
12922 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
12924 * config/aarch64/iterators.md (SVE_INT_BINARY_SD): New code iterator.
12925 (optab, sve_int_op): Handle div and udiv.
12926 * config/aarch64/aarch64-sve.md (<optab><mode>3): New expander
12927 for SVE_INT_BINARY_SD.
12928 (*<optab><mode>3): New insn for the same.
12930 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
12932 * tree-vect-patterns.c: Include predict.h.
12933 (vect_recog_divmod_pattern): Restrict check for division support
12934 to when optimizing for size.
12936 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
12938 * doc/sourcebuild.texi (vect_double_cond_arith: Document.
12939 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 4.
12940 (gimple_match_op::gimple_match_op): Add an overload for 4 operands.
12941 (gimple_match_op::set_op): Likewise.
12942 (gimple_resimplify4): Declare.
12943 * genmatch.c (get_operand_type): Handle CFN_COND_* functions.
12944 (expr::gen_transform): Likewise.
12945 (decision_tree::gen): Generate a simplification routine for 4 operands.
12946 * gimple-match-head.c (gimple_simplify): Add an overload for
12947 4 operands. In the top-level function, handle up to 4 call
12948 arguments and call gimple_resimplify4.
12949 (gimple_resimplify4): New function.
12950 (build_call_internal): Pass a fourth operand.
12951 (maybe_push_to_seq): Likewise.
12952 * match.pd (UNCOND_BINARY, COND_BINARY): New operator lists.
12953 Fold VEC_COND_EXPRs of an operation and a default value into
12954 an IFN_COND_* function if possible.
12955 * config/aarch64/iterators.md (UNSPEC_COND_MAX, UNSPEC_COND_MIN):
12957 (SVE_COND_FP_BINARY): Include them.
12958 (optab, sve_fp_op): Handle them.
12959 (SVE_INT_BINARY_REV): New code iterator.
12960 (SVE_COND_FP_BINARY_REV): New int iterator.
12961 (commutative): New int attribute.
12962 * config/aarch64/aarch64-protos.h (aarch64_sve_prepare_conditional_op):
12964 * config/aarch64/aarch64.c (aarch64_sve_prepare_conditional_op): New
12966 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Use it.
12967 (*cond_<optab><mode>): New patterns for reversed operands.
12969 2018-05-25 Richard Biener <rguenther@suse.de>
12971 * tree-vectorizer.h (STMT_VINFO_GROUP_*, GROUP_*): Remove.
12972 (DR_GROUP_*): New, assert we have non-NULL ->data_ref_info.
12973 (REDUC_GROUP_*): New, assert we have NULL ->data_ref_info.
12974 (STMT_VINFO_GROUPED_ACCESS): Adjust.
12975 * tree-vect-data-refs.c (everywhere): Adjust users.
12976 * tree-vect-loop.c (everywhere): Likewise.
12977 * tree-vect-slp.c (everywhere): Likewise.
12978 * tree-vect-stmts.c (everywhere): Likewise.
12979 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
12981 2018-05-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12983 * configure.ac (gcc_cv_as_section_has_e): Move to common section.
12985 (gcc_cv_as_section_exclude): ... this.
12986 Try Solaris as #exclude syntax.
12987 * configure: Regenerate.
12988 * config.in: Regenerate.
12989 * config/i386/i386.c (i386_solaris_elf_named_section): Handle
12991 * config/sparc/sparc.c (sparc_solaris_elf_asm_named_section)
12992 [HAVE_GAS_SECTION_EXCLUDE]: Handle SECTION_EXCLUDE.
12994 * varasm.c (default_elf_asm_named_section): Don't check if
12995 HAVE_GAS_SECTION_EXCLUDE is defined.
12997 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
12999 * doc/md.texi: Update the documentation of the cond_* optabs
13000 to mention the new final operand. Fix GET_MODE_NUNITS call.
13001 Describe the scalar case too.
13002 * internal-fn.def (IFN_EXTRACT_LAST): Change type to fold_left.
13003 * internal-fn.c (expand_cond_unary_optab_fn): Expect 3 operands
13005 (expand_cond_binary_optab_fn): Expect 4 operands instead of 3.
13006 (get_conditional_internal_fn): Update comment.
13007 * tree-vect-loop.c (vectorizable_reduction): Pass the original
13008 accumulator value as a final argument to conditional functions.
13009 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Turn into
13010 a define_expand and add an "else" operand. Assert for now that
13011 the else operand is equal to operand 2. Use SVE_INT_BINARY and
13012 SVE_COND_FP_BINARY instead of SVE_COND_INT_OP and SVE_COND_FP_OP.
13013 (*cond_<optab><mode>): New patterns.
13014 * config/aarch64/iterators.md (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX)
13015 (UNSPEC_COND_SMIN, UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
13016 (UNSPEC_COND_EOR): Delete.
13017 (optab): Remove associated mappings.
13018 (SVE_INT_BINARY): New code iterator.
13019 (sve_int_op): Remove int attribute and add "minus" to the code
13021 (SVE_COND_INT_OP): Delete.
13022 (SVE_COND_FP_OP): Rename to...
13023 (SVE_COND_FP_BINARY): ...this.
13025 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
13027 * optabs.c (can_reuse_operands_p): New function.
13028 (maybe_legitimize_operands): Try to reuse the results for
13031 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
13033 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
13034 Add {q} suffix to insn mnemonic.
13036 2018-05-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13038 * config/msp430/msp430.c (TARGET_WARN_FUNC_RETURN): Define.
13039 (msp430_warn_func_return): New.
13041 2018-05-24 Roger Sayle <roger@nextmovesoftware.com>
13043 * fold-const.c (tree_nonzero_bits): New function.
13044 * fold-const.h (tree_nonzero_bits): Likewise.
13045 * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
13046 friends. POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.
13048 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
13052 * varasm.c (assemble_alias): Check ifunc_resolver only on
13055 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
13058 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
13059 when memory input operand is handled.
13061 2018-05-24 Luis Machado <luis.machado@linaro.org>
13063 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
13065 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
13067 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
13069 * match.pd: Delay FMA folds until after vectorization.
13071 2018-05-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
13074 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
13075 address check not strict.
13077 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
13079 * gimple-match.h (gimple_match_op): New class.
13080 (mprts_hook): Replace parameters with a gimple_match_op *.
13081 (maybe_build_generic_op): Likewise.
13082 (gimple_simplified_result_is_gimple_val): Replace parameters with
13083 a const gimple_match_op *.
13084 (gimple_simplify): Replace code_helper * and tree * parameters with
13085 a gimple_match_op * parameter.
13086 (gimple_resimplify1): Replace code_helper *, tree and tree *
13087 parameters with a gimple_match_op * parameter.
13088 (gimple_resimplify2): Likewise.
13089 (gimple_resimplify3): Likewise.
13090 (maybe_push_res_to_seq): Replace code_helper, tree and tree *
13091 parameters with a gimple_match_op * parameter.
13092 * gimple-match-head.c (gimple_simplify): Change prototypes of
13093 auto-generated functions to take a gimple_match_op * instead of
13094 separate code_helper * and tree * parameters. Make the same
13095 change in the top-level overload and update calls to the
13096 gimple_resimplify routines. Update calls to the auto-generated
13097 functions and to maybe_push_res_to_seq in the publicly-facing
13098 operation-specific gimple_simplify overloads.
13099 (gimple_match_op::MAX_NUM_OPS): Define.
13100 (gimple_resimplify1): Replace rcode and ops with a single res_op
13101 parameter. Update call to gimple_simplify.
13102 (gimple_resimplify2): Likewise.
13103 (gimple_resimplify3): Likewise.
13104 (mprts_hook): Replace parameters with a gimple_match_op *.
13105 (maybe_build_generic_op): Likewise.
13106 (build_call_internal): Replace type, nargs and ops with
13107 a gimple_match_op *.
13108 (maybe_push_res_to_seq): Replace res_code, type and ops parameters
13109 with a single gimple_match_op *. Update calls to mprts_hook,
13110 build_call_internal and gimple_simplified_result_is_gimple_val.
13111 Factor out code that is common to the tree_code and combined_fn cases.
13112 * genmatch.c (expr::gen_transform): Replace tem_code and
13113 tem_ops with a gimple_match_op called tem_op. Update calls
13114 to the gimple_resimplify functions and maybe_push_res_to_seq.
13115 (dt_simplify::gen_1): Manipulate res_op instead of res_code and
13116 res_ops. Update call to the gimple_resimplify functions.
13117 (dt_simplify::gen): Pass res_op instead of res_code and res_ops.
13118 (decision_tree::gen): Make the functions take a gimple_match_op *
13119 called res_op instead of separate res_code and res_ops parameters.
13120 Update call accordingly.
13121 * gimple-fold.c (replace_stmt_with_simplification): Replace rcode
13122 and ops with a single res_op parameter. Update calls to
13123 maybe_build_generic_op and maybe_push_res_to_seq.
13124 (fold_stmt_1): Update calls to gimple_simplify and
13125 replace_stmt_with_simplification.
13126 (gimple_fold_stmt_to_constant_1): Update calls to gimple_simplify
13127 and gimple_simplified_result_is_gimple_val.
13128 * tree-cfgcleanup.c (cleanup_control_expr_graph): Update call to
13130 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Replace parameters
13131 with a gimple_match_op *.
13132 (vn_nary_build_or_lookup): Likewise. Update call to
13133 vn_nary_build_or_lookup_1.
13134 (vn_nary_build_or_lookup_1): Replace rcode, type and ops with a
13135 gimple_match_op *. Update calls to the gimple_resimplify routines
13136 and to gimple_simplified_result_is_gimple_val.
13137 (vn_nary_simplify): Update call to vn_nary_build_or_lookup_1.
13138 Use gimple_match_op::MAX_NUM_OPS instead of a hard-coded 3.
13139 (vn_reference_lookup_3): Update call to vn_nary_build_or_lookup.
13140 (visit_nary_op): Likewise.
13141 (visit_reference_op_load): Likewise.
13143 2018-05-23 Luis Machado <luis.machado@linaro.org>
13145 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Use correct type
13146 modifier for printing the step amount.
13148 2018-05-23 Jozef Lawrynowicz <jozef.l@somniumtech.com>
13151 * tree.c (build_common_tree_nodes): Dont set TYPE_SIZE for __intN
13154 2018-05-23 Segher Boessenkool <segher@kernel.crashing.org>
13156 * doc/sourcebuild.texi (Endianness): New subsubsection.
13158 2018-05-23 Luis Machado <luis.machado@linaro.org>
13160 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
13161 <prefetch_dynamic_strides>: New const bool field.
13162 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
13163 prefetch_dynamic_strides.
13164 (exynosm1_prefetch_tune): Likewise.
13165 (thunderxt88_prefetch_tune): Likewise.
13166 (thunderx_prefetch_tune): Likewise.
13167 (thunderx2t99_prefetch_tune): Likewise.
13168 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides to
13170 (aarch64_override_options_internal): Update to set
13171 PARAM_PREFETCH_DYNAMIC_STRIDES.
13172 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
13173 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
13174 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
13175 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
13176 prefetch-dynamic-strides setting.
13178 2018-05-23 Luis Machado <luis.machado@linaro.org>
13180 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
13181 <minimum_stride>: New const int field.
13182 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
13183 minimum_stride field defaulting to -1.
13184 (exynosm1_prefetch_tune): Likewise.
13185 (thunderxt88_prefetch_tune): Likewise.
13186 (thunderx_prefetch_tune): Likewise.
13187 (thunderx2t99_prefetch_tune): Likewise.
13188 (qdf24xx_prefetch_tune) <minimum_stride>: Set to 2048.
13189 <default_opt_level>: Set to 3.
13190 (aarch64_override_options_internal): Update to set
13191 PARAM_PREFETCH_MINIMUM_STRIDE.
13192 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
13193 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
13194 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
13195 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
13196 stride is constant and is below the minimum stride threshold.
13198 2018-05-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13200 * config/arm/arm-cpus.in (mode26): Delete.
13201 (armv4): Delete mode26 reference.
13202 * config/arm/arm.c (arm_configure_build_target): Delete use of
13205 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
13207 * config/i386/i386.md (*floatuns<SWI48:mode><MODEF:mode>2_avx512):
13209 (floatunssi<mode>2): Also enable for AVX512F and TARGET_SSE_MATH.
13210 Rewrite expander pattern. Emit gen_floatunssi<mode>2_i387_with_xmm
13212 (floatunsdisf2): Rewrite expander pattern. Hanlde TARGET_AVX512F.
13213 (floatunsdidf2): Ditto.
13215 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
13217 * config/i386/i386.md (fixuns_trunc<mode>di2): New insn pattern.
13218 (fixuns_trunc<mode>si2_avx512f): Ditto.
13219 (*fixuns_trunc<mode>si2_avx512f_zext): Ditto.
13220 (fixuns_trunc<mode>si2): Also enable for AVX512F and TARGET_SSE_MATH.
13221 Emit fixuns_trunc<mode>si2_avx512f for AVX512F targets.
13223 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
13225 PR rtl-optimization/79985
13226 * df-scan.c (df_insn_refs_collect): Remove special case for
13227 global registers and asm statements.
13229 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
13231 * extend.texi (Global Register Variables): Rewrite the bullet list.
13232 Note that the register is available for allocation. Note that access
13233 via inline asm must use constraints. Add note about async-signal
13234 handlers. Remove paragraph about automagic register selection.
13236 2018-05-23 Richard Biener <rguenther@suse.de>
13238 * tree-ssa-sccvn.c (vn_reference_lookup_3): Remove restriction
13239 of fixed offset from memset VN.
13241 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
13243 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
13244 first_interp field.
13245 (alloc_cand_and_find_basis): Initialize first_interp field.
13246 (slsr_process_mul): Modify first_interp field.
13247 (slsr_process_add): Likewise.
13248 (slsr_process_cast): Modify first_interp field for each new
13250 (slsr_process_copy): Likewise.
13251 (dump_candidate): Dump first_interp field.
13252 (replace_mult_candidate): Process all interpretations, not just
13254 (replace_rhs_if_not_dup): Likewise.
13255 (replace_one_candidate): Likewise.
13257 2018-05-23 Wilco Dijkstra <wdijkstr@arm.com>
13259 * config/aarch64/aarch64.c (aarch64_use_frame_pointer):
13261 (aarch64_needs_frame_chain): New function.
13262 (aarch64_parse_override_string): Set aarch64_use_frame_pointer.
13264 2018-05-23 Sudakshina Das <sudi.das@arm.com>
13267 * common/config/aarch64/aarch64-common.c (aarch64_handle_option):
13268 Check val before adding MASK_STRICT_ALIGN to opts->x_target_flags.
13269 * config/aarch64/aarch64.opt (mstrict-align): Remove RejectNegative.
13270 * config/aarch64/aarch64.c (aarch64_attributes): Mark allow_neg
13271 as true for strict-align.
13272 (aarch64_can_inline_p): Perform checks even when callee has no
13273 attributes to check for strict alignment.
13274 * doc/extend.texi (AArch64 Function Attributes): Document
13276 * doc/invoke.texi: (AArch64 Options): Likewise.
13278 2018-05-23 Richard Sandiford <richard.sandiford@linaro.org>
13280 PR tree-optimization/85853
13281 * tree-vect-slp.c (vect_slp_analyze_node_operations): Split out
13282 the handling of the root of the node to...
13283 (vect_slp_analyze_node_operations_1): ...this new function,
13284 and run the whole thing with the child nodes' def types
13285 set according to their SLP node's def type.
13287 2018-05-23 Richard Biener <rguenther@suse.de>
13289 PR middle-end/85874
13290 * tree-data-ref.c (create_runtime_alias_checks): Defer
13291 and ignore overflow warnings.
13293 2018-05-23 Yury Gribov <tetra2005@gmail.com>
13295 PR tree-optimization/85822
13296 * tree-vrp.c (is_masked_range_test): Fix handling of negative
13299 2018-05-23 Richard Biener <rguenther@suse.de>
13301 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
13302 memset constants via native_interpret_expr.
13304 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
13307 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
13309 (cgraph_node::create_alias): Likewise.
13310 (cgraph_node::get_availability): Check ifunc_resolver instead
13311 of looking up ifunc attribute.
13312 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
13313 * varasm.c (do_assemble_alias): Likewise.
13314 (assemble_alias): Likewise.
13315 (default_binds_local_p_3): Likewise.
13316 * cgraph.h (cgraph_node): Add ifunc_resolver.
13317 (cgraph_node::only_called_directly_or_aliased_p): Return false
13318 for IFUNC resolver.
13319 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
13321 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
13322 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
13323 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
13324 instead of looking up ifunc attribute.
13326 2018-05-22 Luis Machado <luis.machado@linaro.org>
13328 * config/aarch64/aarch64.md (*ashift<mode>_extv_bfiz): New pattern.
13330 2018-05-22 Martin Sebor <msebor@redhat.com>
13332 PR middle-end/85359
13333 * builtins.c (expand_builtin_strcpy): Call maybe_warn_nonstring_arg
13334 only when expasion succeeds.
13335 (expand_builtin_strcmp): Same.
13336 (expand_builtin_strncmp): Same.
13338 2018-05-22 Martin Sebor <msebor@redhat.com>
13340 * calls.c (maybe_warn_nonstring_arg): Fix a typo in a comment.
13342 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
13343 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13345 * config/aarch64/aarch64-ldpstp.md: Replace uses of
13346 aarch64_mem_pair_operand with memory_operand and delete operand swapping
13348 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
13349 Add check for legitimate_address.
13350 (aarch64_gen_adjusted_ldpstp): Swap operands where appropriate.
13351 (aarch64_swap_ldrstr_operands): New.
13352 * config/aarch64/aarch64-protos.h (aarch64_swap_ldrstr_operands):
13355 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
13356 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13358 * config/aarch64/aarch64.md: New patterns to generate stp
13360 (store_pair_sw, store_pair_dw): New patterns to generate stp for
13361 single words and double words.
13362 (load_pair_sw, load_pair_dw): Likewise.
13363 (store_pair_sf, store_pair_df, store_pair_si, store_pair_di):
13365 (load_pair_sf, load_pair_df, load_pair_si, load_pair_di):
13367 * config/aarch64/aarch64-ldpstp.md: Modify peephole
13368 for different mode ldpstp and add peephole for merged zero stores.
13369 Likewise for loads.
13370 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
13372 (aarch64_gen_store_pair): Rename calls to match new patterns.
13373 (aarch64_gen_load_pair): Rename calls to match new patterns.
13374 * config/aarch64/aarch64-simd.md (load_pair<mode>): Rename to...
13375 (load_pair<DREG:mode><DREG2:mode>): ... This.
13376 (store_pair<mode>): Rename to...
13377 (vec_store_pair<DREG:mode><DREG2:mode>): ... This.
13378 * config/aarch64/iterators.md (DREG, DREG2, DX2, SX, SX2, DSX):
13379 New mode iterators.
13380 (V_INT_EQUIV): Handle SImode.
13381 * config/aarch64/predicates.md (aarch64_reg_zero_or_fp_zero):
13384 2018-05-22 Martin Sebor <msebor@redhat.com>
13387 * calls.c (maybe_warn_nonstring_arg): Use string length to set
13388 or ajust the presumed bound on an operation to avoid unnecessary
13391 2018-05-22 Martin Sebor <msebor@redhat.com>
13393 PR tree-optimization/85826
13394 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Avoid
13395 assuming that a DECL necesarily has a constant size.
13397 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
13399 PR middle-end/85862
13400 * internal-fn.c (expand_direct_optab_fn): Cope with a null lhs.
13402 2018-05-22 Richard Biener <rguenther@suse.de>
13404 PR tree-optimization/85834
13405 * tree-ssa-sccvn.c (vn_reference_lookup_3): Properly handle
13406 non-constant and non-zero memset arguments.
13408 2018-05-22 Martin Liska <mliska@suse.cz>
13411 * ipa-icf.c (sem_item::add_type): Do not ICE for incomplete types.
13413 2018-05-22 Richard Biener <rguenther@suse.de>
13415 PR tree-optimization/85863
13416 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
13417 comparisons when vectype is specified.
13418 (vectorizable_condition): Do not specify vectype for
13419 vect_is_simple_cond when SLP vectorizing.
13421 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
13424 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
13425 define __ibm128 as long double.
13426 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
13427 as a distinct type when IEEE 128-bit support is enabled.
13428 (init_float128_ieee): Fix up conversions between IFmode and IEEE
13429 128-bit types to use the correct functions.
13430 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
13431 convert between 128-bit floating point types that have different
13432 modes but the same representation, instead of using gen_lowpart to
13434 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
13436 (IFKF_reg): New attributes to give the register constraints for
13438 (extend<mode>tf2_internal): New insns to mark an explicit
13439 conversion between 128-bit floating point types that have a
13440 different mode but share the same representation.
13442 2018-05-21 Richard Sandiford <richard.sandiford@linaro.org>
13444 PR tree-optimization/85814
13445 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
13446 a null return from get_strinfo when unsharing the next
13447 strinfo in the chain.
13449 2018-05-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
13452 * varasm.c (weak_finish): Clean up weak_decls.
13454 2018-05-21 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13456 * config/aarch64/aarch64.md ("unspec"): Define UNSPEC_SABAL,
13457 UNSPEC_SABDL2, UNSPEC_SADALP, UNSPEC_UABAL, UNSPEC_UABDL2,
13458 UNSPEC_UADALP values.
13459 * config/aarch64/iterators.md (ABAL): New int iterator.
13462 (sur): Add mappings for the above.
13463 * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>_3):
13465 (aarch64_<sur>abal<mode>_4): Likewise.
13466 (aarch64_<sur>adalp<mode>_3): Likewise.
13467 (<sur>sadv16qi): New define_expand.
13469 2018-05-21 Alexander Nesterovskiy <alexander.nesterovskiy@intel.com>
13471 * config/i386/i386.md (*movsf_internal): AVX falsedep fix.
13472 (*movdf_internal): Ditto.
13473 (*rcpsf2_sse): Ditto.
13474 (*rsqrtsf2_sse): Ditto.
13475 (*sqrt<mode>2_sse): Ditto.
13477 2018-05-21 Tamar Christina <tamar.christina@arm.com>
13479 * config/aarch64/aarch64-simd.md (aarch64_eor3qv8hi): Change to
13481 (aarch64_bcaxqv8hi): Change to bcaxq<mode>4.
13482 * config/aarch64/aarch64-simd-builtins.def (veor3q_u8, veor3q_u32,
13483 veor3q_u64, veor3q_s8, veor3q_s16, veor3q_s32, veor3q_s64, vbcaxq_u8,
13484 vbcaxq_u32, vbcaxq_u64, vbcaxq_s8, vbcaxq_s16, vbcaxq_s32,
13486 * config/aarch64/arm_neon.h: Likewise.
13487 * config/aarch64/iterators.md (VQ_I): New.
13489 2018-05-21 Alexey Brodkin <abrodkin@synopsys.com>
13491 * config.gcc: Add arc/t-multilib-linux to tmake_file for
13493 * config/arc/t-multilib-linux: Specify MULTILIB_OPTIONS and
13496 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
13498 * config/nds32/constraints.md (S): New constraint.
13499 * config/nds32/nds32.md (call_internal): Use constraint S.
13500 (call_value_internal): Likewise.
13501 (sibcall_internal): Likewise.
13502 (sibcall_value_internal): Likewise.
13504 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
13505 Chung-Ju Wu <jasonwucj@gmail.com>
13507 * config/nds32/nds32.c (nds32_register_move_cost): Take garywolf cpu
13508 into consideration.
13510 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
13511 Chung-Ju Wu <jasonwucj@gmail.com>
13513 * config/nds32/nds32-cost.c (rtx_cost_model_t): New structure.
13514 (insn_size_16bit, insn_size_32bit): New variables for cost evaluation.
13515 (nds32_rtx_costs_impl): Simplify.
13516 (nds32_address_cost_impl): Simplify.
13517 (nds32_init_rtx_costs): New function.
13518 (nds32_rtx_costs_speed_prefer): Likewise.
13519 (nds32_rtx_costs_size_prefer): Likewise.
13520 (nds32_address_cost_speed_prefer): Likewise.
13521 (nds32_address_cost_speed_fwprop): Likewise.
13522 (nds32_address_cost_size_prefer): Likewise.
13523 * config/nds32/nds32-protos.h (nds32_init_rtx_costs): Declare.
13524 * config/nds32/nds32.c (nds32_option_override): Use
13525 nds32_init_rtx_costs function.
13527 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
13529 * config/nds32/nds32.c (nds32_asm_file_start): Output pipeline model.
13530 * config/nds32/nds32.h (TARGET_PIPELINE_N7): Define.
13531 (TARGET_PIPELINE_N8): Likewise.
13532 (TARGET_PIPELINE_N10): Likewise.
13533 (TARGET_PIPELINE_N13): Likewise.
13534 (TARGET_PIPELINE_GRAYWOLF): Likewise.
13536 2018-05-19 Monk Chiang <sh.chiang04@gmail.com>
13538 * config/nds32/nds32-fpu.md: Update copyright year.
13540 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
13542 * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
13544 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
13546 * config/nds32/nds32.c
13547 (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
13548 * config/nds32/nds32.opt (minline-asm-r15): New option.
13550 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
13552 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS): Add
13554 * config/nds32/nds32.md (abssi2): New pattern.
13556 2018-05-19 Uros Bizjak <ubizjak@gmail.com>
13558 * config/i386/i386.md (rex64namesuffix): New mode attribute.
13559 * config/i386/sse.md (sse_cvtsi2ss<rex64namesuffix><round_name>):
13560 Merge insn pattern from sse_cvtsi2ss<round_name> and
13561 sse_cvtsi2ssq<round_name> using SWI48 mode iterator.
13562 (sse_cvtss2si<rex64namesuffix><round_name>): Merge insn pattern
13563 from sse_cvtss2si<round_name> and sse_cvtss2siq<round_name>
13564 using SWI48 mode iterator.
13565 (sse_cvtss2si<rex64namesuffix>_2): Merge insn pattern from
13566 sse_cvtss2si_2 and sse_cvtss2siq_2 using SWI48 mode iterator.
13567 (sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Merge insn
13568 pattern from sse_cvttss2si<round_saeonly_name>
13569 and sse_cvttss2siq<round_saeonly_name> using SWI48 mode iterator.
13570 (avx512f_vcvtss2usi<rex64namesuffix><round_name>): Merge insn pattern
13571 from avx512f_vcvtss2usi<round_name> and avx512f_vcvtss2usiq<round_name>
13572 using SWI48 mode iterator.
13573 (avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>): Merge
13574 insn pattern from avx512f_vcvttss2usi<round_saeonly_name> and
13575 avx512f_vcvttss2usiq<round_saeonly_name> using SWI48 mode iterator.
13576 (avx512f_vcvtsd2usi<rex64namesuffix><round_name>): Merge insn pattern
13577 from avx512f_vcvtsd2usi<round_name> and avx512f_vcvtsd2usiq<round_name>
13578 using SWI48 mode iterator.
13579 (avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>): Merge
13580 insn pattern from avx512f_vcvttsd2usi<round_saeonly_name> and
13581 avx512f_vcvttsd2usiq<round_saeonly_name> using SWI48 mode iterator.
13582 (sse2_cvtsd2si<rex64namesuffix><round_name>): Merge insn pattern from
13583 sse2_cvtsd2si<round_name> and sse2_cvtsd2siq<round_name> using
13584 SWI48 mode iterator.
13585 (sse2_cvtsd2si<rex64namesuffix>_2): Merge insn pattern from
13586 sse2_cvtsd2si_2 and sse2_cvtsd2siq_2 using SWI48 mode iterator.
13587 (sse_cvttsd2si<rex64namesuffix><round_saeonly_name>): Merge insn
13588 pattern from sse_cvttsd2si<round_saeonly_name>
13589 and sse_cvttsd2siq<round_saeonly_name> using SWI48 mode iterator.
13591 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
13593 * config/nds32/nds32-md-auxiliary.c
13594 (nds32_valid_smw_lwm_base_p): Refine.
13595 (nds32_output_smw_single_word): Refine.
13596 (nds32_output_smw_double_word): New.
13597 * config/nds32/nds32-protos.h (nds32_output_smw_double_word): New.
13599 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
13601 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Refine.
13602 (nds32_output_stack_pop): Refine.
13603 (nds32_expand_unaligned_load): Refine.
13604 (nds32_expand_unaligned_store): Refine.
13606 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
13607 Chung-Ju Wu <jasonwucj@gmail.com>
13609 * config/nds32/constants.md: Add TP_REGNUM constant.
13610 (unspec_element): Add UNSPEC_GOTINIT, UNSPEC_GOT, UNSPEC_GOTOFF,
13611 UNSPEC_PLT, UNSPEC_TLSGD, UNSPEC_TLSLD, UNSPEC_TLSIE, UNSPEC_TLSLE and
13613 * config/nds32/nds32-doubleword.md: Consider flag_pic.
13614 * config/nds32/nds32-dspext.md (mov<mode>): Expand TLS and PIC cases.
13615 * config/nds32/nds32-predicates.c (nds32_const_unspec_p): New.
13616 * config/nds32/nds32-md-auxiliary.c: Implementation that support TLS
13617 and PIC code generation.
13618 * config/nds32/nds32-protos.h: Declarations that support TLS and PIC
13620 * config/nds32/nds32-relax-opt.c: Consider TLS and PIC for relax
13622 * config/nds32/nds32.md: Support TLS and PIC.
13623 * config/nds32/nds32.c: Support TLS and PIC.
13624 * config/nds32/nds32.h (nds32_relax_insn_type): New enum type.
13625 * config/nds32/predicates.md (nds32_nonunspec_symbolic_operand): New
13628 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
13630 * config/nds32/nds32-predicates.c (const_vector_to_hwint): Use machine
13631 mode with E_ prefix.
13633 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
13634 Chung-Ju Wu <jasonwucj@gmail.com>
13636 * config/nds32/constants.md (unspec_element): Add UNSPEC_ICT.
13637 * config/nds32/nds32-md-auxiliary.c
13638 (symbolic_reference_mentioned_p): New.
13639 (nds32_legitimize_ict_address): New.
13640 (nds32_expand_ict_move): New.
13641 (nds32_indirect_call_referenced_p): New.
13642 (nds32_symbol_binds_local_p): Delete.
13643 (nds32_long_call_p): Modify.
13644 * config/nds32/nds32-opts.h (nds32_ict_model_type): New enum type.
13645 * config/nds32/nds32-protos.h
13646 (symbolic_reference_mentioned_p): Declare.
13647 (nds32_legitimize_ict_address): Declare.
13648 (nds32_expand_ict_move): Declare.
13649 (nds32_indirect_call_referenced_p): Declare.
13650 * config/nds32/nds32-relax-opt.c (nds32_ict_const_p): New.
13651 (nds32_relax_group): Use nds32_ict_const_p as condition.
13652 * config/nds32/nds32.c (nds32_attribute_table): Add "indirect_call".
13653 (nds32_asm_file_start): Output ict_model directive in asm code.
13654 (nds32_legitimate_address_p): Consider indirect call.
13655 (nds32_print_operand): Consider indirect call.
13656 (nds32_print_operand_address): Consider indirect call.
13657 (nds32_insert_attributes): Handle "indirect_call" attribute.
13658 (TARGET_LEGITIMATE_ADDRESS_P): Define.
13659 (TARGET_LEGITIMATE_CONSTANT_P): Define.
13660 (TARGET_CANNOT_FORCE_CONST_MEM): Define.
13661 (TARGET_DELEGITIMIZE_ADDRESS): Define.
13662 (TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA): Define.
13663 * config/nds32/nds32.h (SYMBOLIC_CONST_P): Define.
13664 (TARGET_ICT_MODEL_SMALL): Define.
13665 (TARGET_ICT_MODEL_LARGE): Define.
13666 * config/nds32/nds32.md (movsi): Consider ict model.
13667 (call, call_value): Consider ict model.
13668 (sibcall, sibcall_value): Consider ict model.
13669 * config/nds32/nds32.opt (mict-model): New option.
13670 * config/nds32/predicates.md (nds32_symbolic_operand): Consider ict
13673 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
13674 Monk Chiang <sh.chiang04@gmail.com>
13675 Jim Wilson <jimw@sifive.com>
13677 * common/config/riscv/riscv-common.c (riscv_parse_arch_string):
13678 Add support to parse rv32e*. Clear MASK_RVE for rv32i and rv64i.
13679 * config.gcc (riscv*-*-*): Add support for rv32e* and ilp32e.
13680 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): Define
13681 __riscv_32e when TARGET_RVE. Handle ABI_ILP32E as soft-float ABI.
13682 * config/riscv/riscv-opts.h (riscv_abi_type): Add ABI_ILP32E.
13683 * config/riscv/riscv.c (riscv_compute_frame_info): When TARGET_RVE,
13684 compute save_libcall_adjustment properly.
13685 (riscv_option_override): Call error if TARGET_RVE and not ABI_ILP32E.
13686 (riscv_conditional_register_usage): Handle TARGET_RVE and ABI_ILP32E.
13687 * config/riscv/riscv.h (UNITS_PER_FP_ARG): Handle ABI_ILP32E.
13688 (STACK_BOUNDARY, ABI_STACK_BOUNDARY): Handle TARGET_RVE.
13689 (GP_REG_LAST, MAX_ARGS_IN_REGISTERS): Likewise.
13690 (ABI_SPEC): Handle mabi=ilp32e.
13691 * config/riscv/riscv.opt (abi_type): Add ABI_ILP32E.
13692 (RVE): Add RVE mask.
13693 * doc/invoke.texi (RISC-V options) <-mabi>: Add ilp32e info.
13694 <-march>: Add rv32e as an example.
13696 2018-05-18 Marc Glisse <marc.glisse@inria.fr>
13699 * tree-ssa-structalias.c (create_variable_info_for_1): Extra argument.
13700 (intra_create_variable_infos): Handle C++ constructors.
13702 2018-05-18 Martin Liska <mliska@suse.cz>
13704 * passes.def: Remove a redundant pass.
13706 2018-05-18 Eric Botcazou <ebotcazou@adacore.com>
13709 * config/sparc/sparc.c (sparc_expand_builtin): Always initialize op[0].
13711 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13713 * config/arm/arm-cpus.in (armv3m, mode32): Delete features.
13715 (ARMv2, ARMv3, ARMv3m): Delete fgroups.
13717 (armv2, armv2a, armv3, armv3m): Delete architectures.
13718 (arm2, arm250, arm3, arm6, arm60, arm600, arm610, arm620,
13719 arm7, arm7d, arm7di, arm70, arm700, arm700i, arm710, arm720,
13720 arm710c, arm7100, arm7500, arm7500fe, arm7m, arm7dm, arm7dmi):
13722 * config/arm/arm.md (maddsidi4): Remove check for arm_arch3m.
13723 (*mulsidi3adddi): Likewise.
13724 (mulsidi3): Likewise.
13725 (*mulsidi3_nov6): Likewise.
13726 (umulsidi3): Likewise.
13727 (umulsidi3_nov6): Likewise.
13728 (umaddsidi4): Likewise.
13729 (*umulsidi3adddi): Likewise.
13730 (smulsi3_highpart): Likewise.
13731 (*smulsi3_highpart_nov6): Likewise.
13732 (umulsi3_highpart): Likewise.
13733 (*umulsi3_highpart_nov6): Likewise.
13734 * config/arm/arm.h (arm_arch3m): Delete.
13735 * config/arm/arm.c (arm_arch3m): Delete.
13736 (arm_option_override_internal): Update armv3-related comment.
13737 (arm_configure_build_target): Delete use of isa_bit_mode32.
13738 (arm_option_reconfigure_globals): Delete set of arm_ach3m.
13739 (arm_rtx_costs_internal): Delete check of arm_arch3m.
13740 * config/arm/arm-fixed.md (mulsq3): Delete check for arm_arch3m.
13741 (mulsa3): Likewise.
13742 (mulusa3): Likewise.
13743 * config/arm/arm-protos.h (arm_arch3m): Delete.
13744 * config/arm/arm-tables.opt: Regenerate.
13745 * config/arm/arm-tune.md: Likewise.
13746 * config/arm/t-arm-elf (all_early_nofp): Delete mentions of
13747 deleted architectures.
13749 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13751 * config/arm/arm-cpus.in (armv5, armv5e): Delete features.
13752 (armv5t, armv5te): New features.
13753 (ARMv5, ARMv5e): Delete fgroups.
13754 (ARMv5t, ARMv5te): Adjust for above changes.
13755 (ARMv6m): Likewise.
13756 (armv5, armv5e): Delete arches.
13757 * config/arm/arm.md (*call_reg_armv5): Use arm_arch5t instead of
13759 (*call_reg_arm): Likewise.
13760 (*call_value_reg_armv5): Likewise.
13761 (*call_value_reg_arm): Likewise.
13762 (*call_symbol): Likewise.
13763 (*call_value_symbol): Likewise.
13764 (*sibcall_insn): Likewise.
13765 (*sibcall_value_insn): Likewise.
13766 (clzsi2): Likewise.
13767 (prefetch): Likewise.
13768 (define_split and define_peephole2 dependent on arm_arch5):
13770 * config/arm/arm.h (TARGET_LDRD): Use arm_arch5te instead of
13772 (TARGET_ARM_QBIT): Likewise.
13773 (TARGET_DSP_MULTIPLY): Likewise.
13774 (enum base_architecture): Delete BASE_ARCH_5, BASE_ARCH_5E.
13775 (arm_arch5, arm_arch5e): Delete.
13776 (arm_arch5t, arm_arch5te): Declare.
13777 * config/arm/arm.c (arm_arch5, arm_arch5e): Delete.
13778 (arm_arch5t): Declare.
13779 (arm_option_reconfigure_globals): Update for the above.
13780 (arm_options_perform_arch_sanity_checks): Update comment, replace
13781 use of arm_arch5 with arm_arch5t.
13782 (use_return_insn): Likewise.
13783 (arm_emit_call_insn): Likewise.
13784 (output_return_instruction): Likewise.
13785 (arm_final_prescan_insn): Likewise.
13786 (arm_coproc_builtin_available): Likewise.
13787 * config/arm/arm-c.c (arm_cpu_builtins): Replace arm_arch5 and
13788 arm_arch5e with arm_arch5t and arm_arch5te.
13789 * config/arm/arm-protos.h (arm_arch5, arm_arch5e): Delete.
13790 (arm_arch5t, arm_arch5te): Declare.
13791 * config/arm/arm-tables.opt: Regenerate.
13792 * config/arm/t-arm-elf: Remove references to armv5, armv5e.
13793 * config/arm/t-multilib: Likewise.
13794 * config/arm/thumb1.md (*call_reg_thumb1_v5): Check arm_arch5t
13795 instead of arm_arch5.
13796 (*call_reg_thumb1): Likewise.
13797 (*call_value_reg_thumb1_v5): Likewise.
13798 (*call_value_reg_thumb1): Likewise.
13799 * config/arm/vxworks.h (TARGET_OS_CPP_BUILTINS): Remove now
13801 * doc/invoke.texi (ARM Options): Remove references to armv5, armv5e.
13803 2018-05-18 Martin Liska <mliska@suse.cz>
13805 PR gcov-profile/84846
13806 * doc/gcov.texi: Document -t option of gcov tool.
13808 2018-05-18 Martin Liska <mliska@suse.cz>
13810 PR gcov-profile/84846
13811 * gcov.c (print_usage): Add new -t option.
13812 (process_args): Handle the option.
13813 (generate_results): Use stdout as output when requested by
13816 2018-05-18 Martin Liska <mliska@suse.cz>
13818 PR gcov-profile/84846
13819 * coverage.c (coverage_init): Write PWD to .gcno file.
13820 * doc/gcov.texi: Document how working directory is printed.
13821 * gcov-dump.c (dump_gcov_file): Print PWD.
13822 * gcov.c (output_intermediate_file): Likewise.
13823 (read_graph_file): Read PWD string.
13824 (output_lines): Print PWD.
13826 2018-05-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
13828 PR middle-end/85817
13829 * ipa-pure-const.c (malloc_candidate_p): Remove the check integer_zerop
13830 for retval and return false if all args to phi are zero.
13832 2018-05-18 Richard Biener <rguenther@suse.de>
13834 * gimple-ssa-evrp.c (class evrp_folder): Add simplify_stmt_using_ranges
13836 (evrp_dom_walker::before_dom_children): Call it.
13838 2018-05-18 Richard Biener <rguenther@suse.de>
13840 * tree-dfa.c (get_ref_base_and_extent): Use range-info to refine
13841 results when processing array refs with variable index.
13843 2018-05-18 Toon Moene <toon@moene.org>
13845 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
13846 directly after that of -floop-interchange. Indicate that both
13847 options are enabled by default when specifying -O3.
13849 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
13851 * config/aarch64/aarch64-simd.md (vec_set<mode>): Use VALL_F16 mode
13852 iterator. Delete separate integer-mode vec_set<mode> expander.
13853 (aarch64_simd_vec_setv2di): Delete.
13854 (vec_setv2di): Delete.
13855 (aarch64_simd_vec_set<mode>): Delete all other patterns with that name.
13856 Use VALL_F16 mode iterator. Add LD1 alternative and use vwcore for
13857 the "w, r" alternative.
13859 2018-05-18 Martin Liska <mliska@suse.cz>
13861 * passes.def: Add pass_lower_switch and pass_lower_switch_O0.
13862 * tree-pass.h (make_pass_lower_switch_O0): New function.
13863 * tree-switch-conversion.c (node_has_low_bound): Remove.
13864 (node_has_high_bound): Likewise.
13865 (node_is_bounded): Likewise.
13866 (class pass_lower_switch): Make it a template type and create
13868 (pass_lower_switch::execute): Add template argument.
13869 (make_pass_lower_switch): New function.
13870 (make_pass_lower_switch_O0): New function.
13871 (do_jump_if_equal): Remove.
13872 (emit_case_nodes): Simplify to just handle all 3 cases and leave
13873 all the hard work to tree optimization passes.
13875 2018-05-18 Martin Liska <mliska@suse.cz>
13877 * dbgcnt.c (limit_low): Renamed from limit.
13878 (limit_high): New variable.
13879 (dbg_cnt_is_enabled): Check for upper limit.
13880 (dbg_cnt): Adjust dumping.
13881 (dbg_cnt_set_limit_by_index): Add new argument for high
13883 (dbg_cnt_set_limit_by_name): Likewise.
13884 (dbg_cnt_process_single_pair): Parse new format.
13885 (dbg_cnt_process_opt): Use strtok.
13886 (dbg_cnt_list_all_counters): Remove 'value' and add
13888 * doc/invoke.texi: Document changes.
13890 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
13892 * doc/sourcebuild.texi (scalar_all_fma): Document.
13893 * tree.def (FMA_EXPR): Delete.
13894 * internal-fn.def (FMA, FMS, FNMA, FNMS): New internal functions.
13895 * internal-fn.c (ternary_direct): New macro.
13896 (expand_ternary_optab_fn): Likewise.
13897 (direct_ternary_optab_supported_p): Likewise.
13898 * Makefile.in (build/genmatch.o): Depend on case-fn-macros.h.
13899 * builtins.c (fold_builtin_fma): Delete.
13900 (fold_builtin_3): Don't call it.
13901 * cfgexpand.c (expand_debug_expr): Remove FMA_EXPR handling.
13902 * expr.c (expand_expr_real_2): Likewise.
13903 * fold-const.c (operand_equal_p): Likewise.
13904 (fold_ternary_loc): Likewise.
13905 * gimple-pretty-print.c (dump_ternary_rhs): Likewise.
13906 * gimple.c (DEFTREECODE): Likewise.
13907 * gimplify.c (gimplify_expr): Likewise.
13908 * optabs-tree.c (optab_for_tree_code): Likewise.
13909 * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
13910 * tree-eh.c (operation_could_trap_p): Likewise.
13911 (stmt_could_throw_1_p): Likewise.
13912 * tree-inline.c (estimate_operator_cost): Likewise.
13913 * tree-pretty-print.c (dump_generic_node): Likewise.
13914 (op_code_prio): Likewise.
13915 * tree-ssa-loop-im.c (stmt_cost): Likewise.
13916 * tree-ssa-operands.c (get_expr_operands): Likewise.
13917 * tree.c (commutative_ternary_tree_code, add_expr): Likewise.
13918 * fold-const-call.h (fold_fma): Delete.
13919 * fold-const-call.c (fold_const_call_ssss): Handle CFN_FMS,
13920 CFN_FNMA and CFN_FNMS.
13921 (fold_fma): Delete.
13922 * genmatch.c (combined_fn): New enum.
13923 (commutative_ternary_tree_code): Remove FMA_EXPR handling.
13924 (commutative_op): New function.
13925 (commutate): Use it. Handle more than 2 operands.
13926 (dt_operand::gen_gimple_expr): Use commutative_op.
13927 (parser::parse_expr): Allow :c to be used with non-binary
13928 operators if the commutative operand is known.
13929 * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Handle
13930 CFN_FMS, CFN_FNMA and CFN_FNMS.
13931 (backprop::process_assign_use): Remove FMA_EXPR handling.
13932 * hsa-gen.c (gen_hsa_insns_for_operation_assignment): Likewise.
13933 (gen_hsa_fma): New function.
13934 (gen_hsa_insn_for_internal_fn_call): Use it for IFN_FMA, IFN_FMS,
13935 IFN_FNMA and IFN_FNMS.
13936 * match.pd: Add folds for IFN_FMS, IFN_FNMA and IFN_FNMS.
13937 * gimple-fold.h (follow_all_ssa_edges): Declare.
13938 * gimple-fold.c (follow_all_ssa_edges): New function.
13939 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Use the
13940 gimple_build interface and use follow_all_ssa_edges to fold the result.
13941 (convert_mult_to_fma): Use direct_internal_fn_suppoerted_p
13942 instead of checking for optabs directly.
13943 * config/i386/i386.c (ix86_add_stmt_cost): Recognize FMAs as calls
13944 rather than FMA_EXPRs.
13945 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Create a
13946 call to IFN_FMA instead of an FMA_EXPR.
13948 2018-05-17 Jim Wilson <jimw@sifive.com>
13950 * expr.c (do_tablejump): When converting index to Pmode, if we have a
13951 sign extended promoted subreg, and the range does not have the sign bit
13952 set, then do a sign extend.
13954 * config/riscv/riscv.c (riscv_extend_comparands): In unsigned QImode
13955 test, check for sign extended subreg and/or constant operands, and
13956 do a sign extend in that case.
13958 2018-05-17 Steve Ellcey <sellcey@cavium.com>
13960 * config/aarch64/thunderx2t99.md (thunderx2t99_ls_both): Delete.
13961 (thunderx2t99_multiple): Delete psuedo-units from used cpus.
13963 (thunderx2t99_alu_shift): Remove alu_shift_reg, alus_shift_reg.
13964 Change logics_shift_reg to logics_shift_imm.
13965 (thunderx2t99_fp_loadpair_basic): Delete.
13966 (thunderx2t99_fp_storepair_basic): Delete.
13967 (thunderx2t99_asimd_int): Add neon_sub and neon_sub_q types.
13968 (thunderx2t99_asimd_polynomial): Delete.
13969 (thunderx2t99_asimd_fp_simple): Add neon_fp_mul_s_scalar_q
13970 and neon_fp_mul_d_scalar_q.
13971 (thunderx2t99_asimd_fp_conv): Add *int_to_fp* types.
13972 (thunderx2t99_asimd_misc): Delete neon_dup and neon_dup_q.
13973 (thunderx2t99_asimd_recip_step): Add missing *sqrt* types.
13974 (thunderx2t99_asimd_lut): Add missing tbl types.
13975 (thunderx2t99_asimd_ext): Delete.
13976 (thunderx2t99_asimd_load1_1_mult): Delete.
13977 (thunderx2t99_asimd_load1_2_mult): Delete.
13978 (thunderx2t99_asimd_load1_ldp): New.
13979 (thunderx2t99_asimd_load1): New.
13980 (thunderx2t99_asimd_load2): Add missing *load2* types.
13981 (thunderx2t99_asimd_load3): New.
13982 (thunderx2t99_asimd_load4): New.
13983 (thunderx2t99_asimd_store1_1_mult): Delete.
13984 (thunderx2t99_asimd_store1_2_mult): Delete.
13985 (thunderx2t99_asimd_store2_mult): Delete.
13986 (thunderx2t99_asimd_store2_onelane): Delete.
13987 (thunderx2t99_asimd_store_stp): New.
13988 (thunderx2t99_asimd_store1): New.
13989 (thunderx2t99_asimd_store2): New.
13990 (thunderx2t99_asimd_store3): New.
13991 (thunderx2t99_asimd_store4): New.
13993 2018-05-17 Jerome Lambourg <lambourg@adacore.com>
13995 * config/arm/arm_cmse.h (cmse_nsfptr_create, cmse_is_nsfptr): Remove
13996 #include <stdint.h>. Replace intptr_t with __INTPTR_TYPE__.
13998 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
13999 Segher Boessenkool <segher@kernel.crashing.org>
14002 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest
14005 2018-05-17 Richard Biener <rguenther@suse.de>
14007 * tree-ssa-dse.c (dse_classify_store): Fix iterator increment
14008 for pruning loop and prune defs feeding only already visited PHIs.
14010 2018-05-17 Richard Biener <rguenther@suse.de>
14012 * tree-ssa-sccvn.c (vn_reference_lookup_3): Improve memset handling.
14014 2018-05-17 Bin Cheng <bin.cheng@arm.com>
14015 Richard Biener <rguenther@suse.de>
14017 PR tree-optimization/85793
14018 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
14019 for VMAT_ELEMENTWISE.
14021 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
14023 * internal-fn.h (lookup_internal_fn): Declare
14024 * internal-fn.c (lookup_internal_fn): New function.
14025 * gimple.c (gimple_build_call_from_tree): Handle calls to
14026 internal functions.
14027 * gimple-pretty-print.c (dump_gimple_call): Print "." before
14028 internal function names.
14029 * tree-pretty-print.c (dump_generic_node): Likewise.
14030 * tree-ssa-scopedtables.c (expr_hash_elt::print): Likewise.
14032 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
14034 * gimple-fold.h (gimple_build): Make the function forms take
14035 combined_fn rather than built_in_function.
14036 (gimple_simplify): Likewise.
14037 * gimple-match-head.c (gimple_simplify): Likewise.
14038 * gimple-fold.c (gimple_build): Likewise.
14039 * tree-vect-loop.c (get_initial_def_for_reduction): Use gimple_build
14040 rather than gimple_build_call_internal.
14041 (get_initial_defs_for_reduction): Likewise.
14042 (vect_create_epilog_for_reduction): Likewise.
14043 (vectorizable_live_operation): Likewise.
14045 2018-05-17 Martin Liska <mliska@suse.cz>
14047 * gimple-ssa-sprintf.c (format_directive): Do not use
14048 space in between 'G_' and '('.
14050 2018-05-17 Jakub Jelinek <jakub@redhat.com>
14053 * config/i386/i386.c (ix86_fold_builtin): Handle masked shifts
14054 even if the mask is not all ones.
14057 * config/i386/i386.c (ix86_fold_builtin): Fold shift builtins by
14059 (ix86_gimple_fold_builtin): Likewise.
14062 * config/i386/i386.c: Include tree-vector-builder.h.
14063 (ix86_vector_shift_count): New function.
14064 (ix86_fold_builtin): Fold shift builtins by scalar count.
14065 (ix86_gimple_fold_builtin): Likewise.
14067 * config/i386/avx512fintrin.h (_mm512_set_epi16, _mm512_set_epi8,
14068 _mm512_setzero): New intrinsics.
14070 2018-05-17 James Greenhalgh <james.greenhalgh@arm.com>
14071 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
14073 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify
14074 code generation for cases where splatting a value is not useful.
14075 * simplify-rtx.c (simplify_ternary_operation): Simplify
14076 vec_merge across a vec_duplicate and a paradoxical subreg forming
14077 a vector mode to a vec_concat.
14079 2018-05-17 Olga Makhotina <olga.makhotina@intel.com>
14081 * config.gcc: Support "goldmont-plus".
14082 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
14084 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
14085 PROCESSOR_GOLDMONT_PLUS.
14086 * config/i386/i386.c (m_GOLDMONT_PLUS): Define.
14087 (processor_target_table): Add "goldmont-plus".
14088 (PTA_GOLDMONT_PLUS): Define.
14089 (ix86_lea_outperforms): Add TARGET_GOLDMONT_PLUS.
14090 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT_PLUS.
14091 (fold_builtin_cpu): Add M_INTEL_GOLDMONT_PLUS.
14092 (fold_builtin_cpu): Add "goldmont-plus".
14093 (ix86_add_stmt_cost): Add TARGET_GOLDMONT_PLUS.
14094 (ix86_option_override_internal): Add "goldmont-plus".
14095 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT_PLUS.
14096 (processor_type): Add PROCESSOR_GOLDMONT_PLUS.
14097 * config/i386/x86-tune.def: Add m_GOLDMONT_PLUS.
14098 * doc/invoke.texi: Add goldmont-plus as x86 -march=/-mtune= CPU type.
14100 2018-05-17 Richard Biener <rguenther@suse.de>
14102 PR tree-optimization/85757
14103 * tree-ssa-dse.c (dse_classify_store): Record a PHI def and
14104 remove defs that only feed that PHI from further processing.
14106 2018-05-16 Jim Wilson <jimw@sifive.com>
14108 * config/riscv/riscv.md (<optab>si3_mask, <optab>si3_mask_1): Prepend
14110 (<optab>di3_mask, <optab>di3_mask_1): Likewise.
14112 2018-05-16 Mark Wielaard <mark@klomp.org>
14114 * dwarf2out.c (count_index_strings): New function.
14115 (output_indirect_strings): Call count_index_strings and generate
14116 header for dwarf_version >= 5.
14118 2018-05-16 Mark Wielaard <mark@klomp.org>
14120 * dwarf2out.c (dwarf_FORM): New function.
14121 (set_indirect_string): Use dwarf_FORM.
14122 (reset_indirect_string): Likewise.
14123 (size_of_die): Likewise.
14124 (value_format): Likewise.
14125 (output_die): Likewise.
14126 (add_skeleton_AT_string): Likewise.
14127 (output_macinfo_op): Likewise.
14128 (index_string): Likewise.
14129 (output_index_string_offset): Likewise.
14130 (output_index_string): Likewise.
14131 (count_index_strings): Likewise.
14133 2018-05-16 Carl Love <cel@us.ibm.com>
14135 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
14136 dcbt and dcbtstt with TH=16 if operands[2] is 0 and Power 8 or newer.
14138 2018-05-16 Martin Jambor <mjambor@suse.cz>
14140 * ipa-prop.c (ipa_free_all_edge_args): Remove.
14141 * ipa-prop.h (ipa_free_all_edge_args): Likewise.
14143 2018-05-16 Wilco Dijkstra <wdijkstr@arm.com>
14145 * config/aarch64/aarch64.md (fma<mode>4): Change into expand pattern.
14146 (fnma<mode>4): Likewise.
14147 (fms<mode>4): Likewise.
14148 (fnms<mode>4): Likewise.
14149 (aarch64_fma<mode>4): Rename insn, reorder accumulator operand.
14150 (aarch64_fnma<mode>4): Likewise.
14151 (aarch64_fms<mode>4): Likewise.
14152 (aarch64_fnms<mode>4): Likewise.
14153 (aarch64_fnmadd<mode>4): Likewise.
14155 2018-05-16 Jason Merrill <jason@redhat.com>
14157 * tree.c (warn_deprecated_use): Return bool. Simplify logic.
14159 2018-05-16 Richard Biener <rguenther@suse.de>
14161 * tree-vectorizer.h (struct stmt_info_for_cost): Add where member.
14162 (dump_stmt_cost): Declare.
14163 (add_stmt_cost): Dump cost we add.
14164 (add_stmt_costs): New function.
14165 (vect_model_simple_cost, vect_model_store_cost, vect_model_load_cost):
14166 No longer exported.
14167 (vect_analyze_stmt): Adjust prototype.
14168 (vectorizable_condition): Likewise.
14169 (vectorizable_live_operation): Likewise.
14170 (vectorizable_reduction): Likewise.
14171 (vectorizable_induction): Likewise.
14172 * tree-vect-loop.c (vect_analyze_loop_operations): Create local
14173 cost vector to pass to vectorizable_ and record afterwards.
14174 (vect_model_reduction_cost): Take cost vector argument and adjust.
14175 (vect_model_induction_cost): Likewise.
14176 (vectorizable_reduction): Likewise.
14177 (vectorizable_induction): Likewise.
14178 (vectorizable_live_operation): Likewise.
14179 * tree-vect-slp.c (vect_create_new_slp_node): Initialize
14180 SLP_TREE_NUMBER_OF_VEC_STMTS.
14181 (vect_analyze_slp_cost_1): Remove.
14182 (vect_analyze_slp_cost): Likewise.
14183 (vect_slp_analyze_node_operations): Take visited args and
14184 a target cost vector. Avoid processing already visited stmt sets.
14185 (vect_slp_analyze_operations): Use a local cost vector to gather
14186 costs and register those of non-discarded instances.
14187 (vect_bb_vectorization_profitable_p): Use add_stmt_costs.
14188 (vect_schedule_slp_instance): Remove copying of
14189 SLP_TREE_NUMBER_OF_VEC_STMTS. Instead assert that it is not
14191 * tree-vect-stmts.c (record_stmt_cost): Remove path directly
14192 adding cost. Record cost entry location.
14193 (vect_prologue_cost_for_slp_op): Function to compute cost of
14194 a constant or invariant generated for SLP vect in the prologue,
14195 split out from vect_analyze_slp_cost_1.
14196 (vect_model_simple_cost): Make static. Adjust for SLP costing.
14197 (vect_model_promotion_demotion_cost): Likewise.
14198 (vect_model_store_cost): Likewise, make static.
14199 (vect_model_load_cost): Likewise.
14200 (vectorizable_bswap): Add cost vector arg and adjust.
14201 (vectorizable_call): Likewise.
14202 (vectorizable_simd_clone_call): Likewise.
14203 (vectorizable_conversion): Likewise.
14204 (vectorizable_assignment): Likewise.
14205 (vectorizable_shift): Likewise.
14206 (vectorizable_operation): Likewise.
14207 (vectorizable_store): Likewise.
14208 (vectorizable_load): Likewise.
14209 (vectorizable_condition): Likewise.
14210 (vectorizable_comparison): Likewise.
14211 (can_vectorize_live_stmts): Likewise.
14212 (vect_analyze_stmt): Likewise.
14213 (vect_transform_stmt): Adjust calls to vectorizable_*.
14214 * tree-vectorizer.c: Include gimple-pretty-print.h.
14215 (dump_stmt_cost): New function.
14217 2018-05-16 Richard Biener <rguenther@suse.de>
14219 * params.def (PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE): New param.
14220 * doc/invoke.texi (dse-max-alias-queries-per-store): Document.
14221 * tree-ssa-dse.c: Include tree-ssa-loop.h.
14222 (check_name): New callback.
14223 (dse_classify_store): Track cycles via a visited bitmap of PHI
14224 defs and simplify handling of in-loop and across loop dead stores
14225 and properly fail for loop-variant refs. Handle byte-tracking with
14226 multiple defs. Use PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE for
14229 2018-05-16 Richard Sandiford <richard.sandiford@linaro.org>
14231 * tree-vectorizer.h (vect_get_vector_types_for_stmt): Declare.
14232 (vect_get_mask_type_for_stmt): Likewise.
14233 * tree-vect-slp.c (vect_two_operations_perm_ok_p): New function,
14235 (vect_build_slp_tree_1): ...here. Use vect_get_vector_types_for_stmt
14236 to determine the statement's vector type and the vector type that
14237 should be used for calculating nunits. Deal with cases in which
14238 the type has to be deferred.
14239 (vect_slp_analyze_node_operations): Use vect_get_vector_types_for_stmt
14240 and vect_get_mask_type_for_stmt to calculate STMT_VINFO_VECTYPE.
14241 * tree-vect-loop.c (vect_determine_vf_for_stmt_1)
14242 (vect_determine_vf_for_stmt): New functions, split out from...
14243 (vect_determine_vectorization_factor): ...here.
14244 * tree-vect-stmts.c (vect_get_vector_types_for_stmt)
14245 (vect_get_mask_type_for_stmt): New functions, split out from
14246 vect_determine_vectorization_factor.
14248 2018-05-16 Richard Biener <rguenther@suse.de>
14250 * tree-cfg.c (verify_gimple_assign_ternary): Properly
14251 verify the [VEC_]COND_EXPR embedded comparison.
14253 2018-05-15 Martin Sebor <msebor@redhat.com>
14255 PR tree-optimization/85753
14256 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Handle
14257 RECORD_TYPE in addition to ARRAY_TYPE.
14259 2018-05-15 Martin Sebor <msebor@redhat.com>
14261 PR middle-end/85643
14262 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
14264 2018-05-15 Richard Biener <rguenther@suse.de>
14266 * tree-ssa-dse.c (dse_classify_store): Remove use_stmt parameter,
14267 add by_clobber_p one. Change algorithm to collect all defs
14268 representing uses we need to walk and try reducing them to
14269 a single one before failing.
14270 (dse_dom_walker::dse_optimize_stmt): Adjust.
14272 2018-05-13 Mark Wielaard <mark@klomp.org>
14274 * dwarf2out.c (dwarf_OP): Handle DW_OP_addrx and DW_OP_constx.
14275 (size_of_loc_descr): Likewise.
14276 (output_loc_operands): Likewise.
14277 (output_loc_operands_raw): Likewise.
14278 (dw_addr_op): Use dwarf_OP () for DW_OP_constx and DW_OP_addrx.
14279 (resolve_addr_in_expr): Handle DW_OP_addrx and DW_OP_constx.
14280 (hash_loc_operands): Likewise.
14281 (compare_loc_operands): Likewise.
14283 2018-05-14 Mark Wielaard <mark@klomp.org>
14285 * dwarf2out.c (count_index_addrs): New function.
14286 (dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
14288 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
14290 PR tree-optimization/83648
14291 * ipa-pure-const.c (malloc_candidate_p): Allow function with NULL
14292 return value as malloc candidate.
14294 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
14297 * ipa-pure-const.c (warn_function_malloc): Pass value of known_finite
14298 param as true in call to suggest_attribute.
14300 2018-05-14 Segher Boessenkool <segher@kernel.crashing.org>
14302 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete @itemx for
14303 -mreadonly-in-sdata.
14305 2018-05-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
14307 * config/aarch64/aarch64-simd.md (*aarch64_crypto_aese_fused):
14309 (aarch64_crypto_aesd_fused): Likewise.
14311 2018-05-14 Wilco Dijkstra <wdijkstr@arm.com>
14313 * config/aarch64/aarch64.md (mov<mode>): Remove '*' in alternatives.
14314 (movsi_aarch64): Likewise.
14315 (load_pairsi): Likewise.
14316 (load_pairdi): Likewise.
14317 (store_pairsi): Likewise.
14318 (store_pairdi): Likewise.
14319 (load_pairsf): Likewise.
14320 (load_pairdf): Likewise.
14321 (store_pairsf): Likewise.
14322 (store_pairdf): Likewise.
14323 (zero_extend): Likewise.
14324 (trunc): Swap alternatives.
14325 (fcvt_target): Add '?' to prefer w over r.
14327 2018-05-14 Jakub Jelinek <jakub@redhat.com>
14330 * config/i386/i386.md: Disallow non-commutative arithmetics in
14331 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
14332 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
14333 in the peephole2 before it.
14335 2018-05-14 Sebastian Peryt <sebastian.peryt@intel.com>
14337 * common/config/i386/i386-common.c (OPTION_MASK_ISA_CLDEMOTE_SET,
14338 OPTION_MASK_ISA_CLDEMOTE_UNSET): New defines.
14339 (ix86_handle_option): Handle -mcldemote.
14340 * config.gcc: New header.
14341 * config/i386/cldemoteintrin.h: New file.
14342 * config/i386/cpuid.h (bit_CLDEMOTE): New bit.
14343 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
14345 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
14346 OPTION_MASK_ISA_CLDEMOTE.
14347 * config/i386/i386.c (ix86_target_string): Add -mcldemote.
14348 (ix86_valid_target_attribute_inner_p): Ditto.
14349 (enum ix86_builtins): Add IX86_BUILTIN_CLDEMOTE.
14350 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_cldemote.
14351 (ix86_expand_builtin): Expand IX86_BUILTIN_CLDEMOTE.
14352 * config/i386/i386.h (TARGET_CLDEMOTE, TARGET_CLDEMOTE_P): New.
14353 * config/i386/i386.md (UNSPECV_CLDEMOTE): New.
14355 * config/i386/i386.opt: Add -mcldemote.
14356 * config/i386/x86intrin.h: New header.
14357 * doc/invoke.texi: Add -mcldemote.
14359 2018-05-14 Richard Biener <rguenther@suse.de>
14361 * doc/match-and-simplify.texi: Adjust :s documentation.
14363 2018-05-14 Alexander Monakov <amonakov@ispras.ru>
14365 * sort.cc (REORDER_23): Pass the type for the temporaries instead of
14366 intended memcpy size.
14367 (REORDER_45): Likewise.
14369 2018-05-13 Alexander Monakov <amonakov@ispras.ru>
14371 * sort.cc: New file.
14372 * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
14373 * vec.c (qsort_chk): Use gcc_qsort.
14374 * Makefile.in (OBJS-libcommon): Add sort.o.
14375 (build/sort.o): New target. Use it...
14376 (BUILD_RTL): ... here, and...
14377 (build/gencfn-macros): ... here, and...
14378 (build/genmatch): ... here.
14380 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
14381 Chung-Ju Wu <jasonwucj@gmail.com>
14383 * config.gcc (nds32*-*-*): Check that n15 is valid to --with-cpu.
14384 * config/nds32/nds32-graywolf.md: New file.
14385 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_GRAYWOLF.
14386 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n15
14388 * config/nds32/nds32-protos.h: More declarations for n15 pipeline.
14389 * config/nds32/nds32-utils.c: More implementations for n15 pipeline.
14390 * config/nds32/nds32.md (pipeline_model): Add graywolf.
14391 * config/nds32/nds32.opt (mcpu): Support n15 pipeline cpus.
14392 * config/nds32/pipelines.md: Include n15 settings.
14394 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
14395 Chung-Ju Wu <jasonwucj@gmail.com>
14397 * config.gcc (nds32*-*-*): Check that n12/n13 are valid to --with-cpu.
14398 * config/nds32/nds32-n13.md: New file.
14399 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N12 and CPU_N13.
14400 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n12/n13
14402 * config/nds32/nds32-protos.h: More declarations for n12/n13 pipeline.
14403 * config/nds32/nds32.md (pipeline_model): Add n13.
14404 * config/nds32/nds32.opt (mcpu): Support n12/n13 pipeline cpus.
14405 * config/nds32/pipelines.md: Include n13 settings.
14407 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
14408 Chung-Ju Wu <jasonwucj@gmail.com>
14410 * config.gcc (nds32*-*-*): Check that n10/d10 are valid to --with-cpu.
14411 * config/nds32/nds32-n10.md: New file.
14412 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N10.
14413 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n10
14415 * config/nds32/nds32-protos.h: More declarations for n10 pipeline.
14416 * config/nds32/nds32-utils.c: More implementations for n10 pipeline.
14417 * config/nds32/nds32.md (pipeline_model): Add n10.
14418 * config/nds32/nds32.opt (mcpu): Support n10 pipeline cpus.
14419 * config/nds32/pipelines.md: Include n10 settings.
14421 2018-05-13 Monk Chiang <sh.chiang04@gmail.com>
14422 Kito Cheng <kito.cheng@gmail.com>
14423 Chung-Ju Wu <jasonwucj@gmail.com>
14425 * config.gcc (nds32be-*-*): Handle --with-ext-dsp.
14426 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
14427 Add enum values for DSP extension instructions.
14428 * config/nds32/constraints.md (Iu06, IU06, CVp5, CVs5, CVs2, CVhi):
14430 * config/nds32/iterators.md (shifts, shiftrt, sat_plus, all_plus,
14431 sat_minus, all_minus, plus_minus, extend, sumax, sumin, sumin_max):
14432 New code iterators.
14433 (su, zs, uk, opcode, add_rsub, add_sub): New code attributes.
14434 * config/nds32/nds32-dspext.md: New file for DSP implementation.
14435 * config/nds32/nds32-intrinsic.c: Implementation of DSP extension.
14436 * config/nds32/nds32-intrinsic.md: Likewise.
14437 * config/nds32/nds32_intrinsic.h: Likewise.
14438 * config/nds32/nds32-md-auxiliary.c: Likewise.
14439 * config/nds32/nds32-memory-manipulation.c: Consider DSP extension.
14440 * config/nds32/nds32-predicates.c (const_vector_to_hwint): New.
14441 (nds32_valid_CVp5_p, nds32_valid_CVs5_p): New.
14442 (nds32_valid_CVs2_p, nds32_valid_CVhi_p): New.
14443 * config/nds32/nds32-protos.h: New declarations for DSP extension.
14444 * config/nds32/nds32-utils.c (extract_mac_non_acc_rtx): New case
14445 TYPE_DMAC in switch statement.
14446 * config/nds32/nds32.c: New checking and implementation for DSP
14447 extension instructions.
14448 * config/nds32/nds32.h: Likewise.
14449 * config/nds32/nds32.md: Likewise.
14450 * config/nds32/nds32.opt (mhw-abs, mext-dsp): New options.
14451 * config/nds32/predicates.md: Implement new predicates for DSP
14454 2018-05-11 Michael Meissner <meissner@linux.vnet.ibm.com>
14456 * config/rs6000/rs6000.md (mov<mode>_softfloat, FMOVE32):
14457 Reformat alternatives and attributes so it is easier to identify
14458 which constraints/attributes go with which instruction.
14459 (mov<mode>_hardfloat32, FMOVE64): Likewise.
14460 (mov<mode>_softfloat32, FMOVE64): Likewise.
14461 (mov<mode>_hardfloat64, FMOVE64): Likewise.
14462 (mov<mode>_softfloat64, FMOVE64): Likewise.
14464 2018-05-11 Kelvin Nilsen <kelvin@gcc.gnu.org>
14466 * doc/extend.texi (PowerPC Built-in Functions): Rename this
14468 (Basic PowerPC Built-in Functions): The new name of the
14469 subsection previously known as "PowerPC Built-in Functions".
14470 (Basic PowerPC Built-in Functions Available on all Configurations):
14472 (Basic PowerPC Built-in Functions Available on ISA 2.05): Likewise.
14473 (Basic PowerPC Built-in Functions Available on ISA 2.06): Likewise.
14474 (Basic PowerPC Built-in Functions Available on ISA 2.07): Likewise.
14475 (Basic PowerPC Built-in Functions Available on ISA 3.0): Likewise.
14477 2018-05-11 Martin Jambor <mjambor@suse.cz>
14480 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
14483 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
14486 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
14488 2018-05-11 Sebastian Peryt <sebastian.peryt@intel.com>
14490 * common/config/i386/i386-common.c (OPTION_MASK_ISA_WAITPKG_SET,
14491 OPTION_MASK_ISA_WAITPKG_UNSET): New defines.
14492 (ix86_handle_option): Handle -mwaitpkg.
14493 * config.gcc: New header.
14494 * config/i386/cpuid.h (bit_WAITPKG): New bit.
14495 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mwaitpkg.
14496 * config/i386/i386-builtin-types.def ((UINT8, UNSIGNED, UINT64)): New
14498 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
14499 OPTION_MASK_ISA_WAITPKG.
14500 * config/i386/i386.c (ix86_target_string): Add -mwaitpkg.
14501 (ix86_option_override_internal): Add PTA_WAITPKG.
14502 (ix86_valid_target_attribute_inner_p): Add -mwaitpkg.
14503 (enum ix86_builtins): Add IX86_BUILTIN_UMONITOR, IX86_BUILTIN_UMWAIT,
14504 IX86_BUILTIN_TPAUSE.
14505 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_umonitor,
14506 __builtin_ia32_umwait and __builtin_ia32_tpause.
14507 (ix86_expand_builtin): Expand IX86_BUILTIN_UMONITOR,
14508 IX86_BUILTIN_UMWAIT, IX86_BUILTIN_TPAUSE.
14509 * config/i386/i386.h (TARGET_WAITPKG, TARGET_WAITPKG_P): New.
14510 * config/i386/i386.md (UNSPECV_UMWAIT, UNSPECV_UMONITOR,
14511 UNSPECV_TPAUSE): New.
14512 (umwait, umwait_rex64, umonitor_<mode>, tpause, tpause_rex64): New.
14513 * config/i386/i386.opt: Add -mwaitpkg.
14514 * config/i386/waitpkgintrin.h: New file.
14515 * config/i386/x86intrin.h: New header.
14516 * doc/invoke.texi: Add -mwaitpkg.
14518 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
14521 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
14523 (cortex-m0): Use armv6s-m isa.
14524 (cortex-m0plus): Likewise.
14525 (cortex-m1): Likewise.
14526 (cortex-m0.small-multiply): Likewise.
14527 (cortex-m0plus.small-multiply): Likewise.
14528 (cortex-m1.small-multiply): Likewise.
14530 2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
14531 Jakub Jelinek <jakub@redhat.com>
14533 PR tree-optimization/85692
14534 * tree-ssa-forwprop.c (simplify_vector_constructor): Try two
14535 source permute as well.
14537 2018-05-11 Martin Liska <mliska@suse.cz>
14540 * doc/extend.texi: Document LLVM style format for no_sanitize
14543 2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
14545 * config/rs6000/rs6000.c (mode_supports_dq_form): Rename
14546 mode_supports_vsx_dform_quad to mode_supports_dq_form.
14547 (mode_supports_vsx_dform_quad): Likewise.
14548 (mode_supports_vmx_dform): Move these functions to be next to the
14549 other mode_supports functions.
14550 (mode_supports_dq_form): Likewise.
14551 (quad_address_p): Change calls of mode_supports_vsx_dform_quad to
14552 mode_supports_dq_form.
14553 (reg_offset_addressing_ok_p): Likewise.
14554 (offsettable_ok_by_alignment): Likewise.
14555 (rs6000_legitimate_offset_address_p): Likewise.
14556 (legitimate_lo_sum_address_p): Likewise.
14557 (rs6000_legitimize_address): Likewise.
14558 (rs6000_legitimize_reload_address): Likewise.
14559 (rs6000_secondary_reload_inner): Likewise.
14560 (rs6000_preferred_reload_class): Likewise.
14561 (rs6000_output_move_128bit): Likewise.
14563 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
14565 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
14566 Generate SImode target register for null target.
14567 <case IX86_BUILTIN_XGETBV>: Ditto.
14568 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
14569 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
14571 2018-05-10 Carl Love <cel@us.ibm.com>
14573 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
14574 dcbtt and dcbtstt if operands[2] is 0.
14576 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
14579 * config/i386/sse.md (usadv64qi): New expander.
14581 2018-05-10 Segher Boessenkool <segher@kernel.crashing.org>
14583 * config/rs6000/altivec.md (altivec_vmrghb, altivec_vmrghh,
14584 altivec_vmrghw, altivec_vmrglb, altivec_vmrglh, altivec_vmrglw): Remove
14585 -maltivec=be support.
14586 (vec_widen_umult_even_v16qi, vec_widen_smult_even_v16qi,
14587 vec_widen_umult_even_v8hi, vec_widen_smult_even_v8hi,
14588 vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
14589 vec_widen_umult_odd_v16qi, vec_widen_smult_odd_v16qi,
14590 vec_widen_umult_odd_v8hi, vec_widen_smult_odd_v8hi,
14591 vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si, altivec_vpkpx,
14592 altivec_vpks<VI_char>ss, altivec_vpks<VI_char>us,
14593 altivec_vpku<VI_char>us, altivec_vpku<VI_char>um, altivec_vsum2sws,
14594 altivec_vsumsws): Adjust.
14595 (altivec_vspltb *altivec_vspltb_internal, altivec_vsplth,
14596 *altivec_vsplth_internal, altivec_vspltw, *altivec_vspltw_internal,
14597 altivec_vspltsf, *altivec_vspltsf_internal): Remove -maltivec=be
14599 (altivec_vperm_<mode>, altivec_vperm_<mode>_uns,
14600 altivec_vupkhs<VU_char>, altivec_vupkls<VU_char>, altivec_vupkhpx,
14601 altivec_vupklpx, altivec_lvsl, altivec_lvsr): Adjust.
14602 (altivec_lve<VI_char>x): Delete expand.
14603 (*altivec_lve<VI_char>x_internal): Rename to...
14604 (altivec_lve<VI_char>x): ... this.
14605 (altivec_lvxl_<mode>): Delete expand.
14606 (*altivec_lvxl_<mode>_internal): Rename to ...
14607 (altivec_lvxl_<mode>): ... this.
14608 (altivec_stvxl_<mode>): Delete expand.
14609 (*altivec_stvxl_<mode>_internal): Rename to ...
14610 (altivec_stvxl_<mode>): ... this.
14611 (altivec_stve<VI_char>x): Delete expand.
14612 (*altivec_stve<VI_char>x_internal): Rename to ...
14613 (altivec_stve<VI_char>x): ... this.
14614 (doublee<mode>2, unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2,
14615 doubleh<mode>2, unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2,
14616 reduc_plus_scal_<mode>): Adjust.
14617 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust
14619 (rs6000_cpu_cpp_builtins): Adjust.
14620 (altivec_resolve_overloaded_builtin): Remove -maltivec=be support.
14621 * config/rs6000/rs6000-protos.h (altivec_expand_lvx_be,
14622 altivec_expand_stvx_be, altivec_expand_stvex_be): Delete.
14623 * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
14624 -maltivec=be support.
14625 (rs6000_split_vec_extract_var): Adjust.
14626 (rs6000_split_v4si_init): Adjust.
14627 (swap_selector_for_mode): Delete.
14628 (altivec_expand_lvx_be, altivec_expand_stvx_be,
14629 altivec_expand_stvex_be): Delete.
14630 (altivec_expand_lv_builtin, altivec_expand_stv_builtin): Remove
14631 -maltivec=be support.
14632 (rs6000_gimple_fold_builtin): Ditto.
14633 (rs6000_generate_float2_double_code, rs6000_generate_float2_code):
14635 * config/rs6000/rs6000.h (VECTOR_ELT_ORDER_BIG): Delete.
14636 (TARGET_DIRECT_MOVE_64BIT): Adjust.
14637 * config/rs6000/rs6000.md (split for extendsidi2 for vectors): Adjust.
14638 * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Delete.
14639 * config/rs6000/vsx.md (floate<mode>, unsfloatev2di, floato<mode>,
14640 unsfloatov2di, vsignedo_v2df, vsignede_v2df, vunsignedo_v2df,
14641 vunsignede_v2df, vsx_extract_<mode>_p9, *vsx_extract_si,
14642 *vsx_extract_<mode>_p8, *vsx_extract_si_<uns>float_df,
14643 *vsx_extract_si_<uns>float_<mode>, vsx_set_<mode>_p9, vsx_set_v4sf_p9,
14644 *vsx_insert_extract_v4sf_p9, *vsx_insert_extract_v4sf_p9_2, and an
14645 anonymous split): Adjust.
14646 (vsx_mergel_<mode>, vsx_mergeh_<mode>): Remove -maltivec=be support.
14647 (vsx_xxspltd_<mode>, extract4b, insert4b): Adjust.
14649 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
14651 * configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
14652 when --with-gxx-include-dir is also specified.
14653 * configure: Regenerate.
14655 2018-05-09 Jim Wilson <jimw@sifive.com>
14658 * config.gcc (riscv*-*-*): Handle --with-multilib-list.
14659 * config/riscv/t-withmultilib: New.
14660 * config/riscv/withmultilib.h: New.
14661 * doc/install.texi: Document RISC-V --with-multilib-list support.
14663 2018-05-09 Richard Biener <rguenther@suse.de>
14665 * tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
14667 (vect_bb_vectorization_profitable_p): Adjust. Compute
14668 actual scalar cost using the cost vector and the add_stmt_cost
14671 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
14673 PR rtl-optimization/85645
14674 * config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
14675 in the REG_CFA_REGISTER note for LR, don't leave it empty.
14677 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
14679 PR rtl-optimization/85645
14680 * shrink-wrap.c (spread_components): Return a boolean saying if
14681 anything was changed.
14682 (try_shrink_wrapping_separate): Iterate spread_components until
14683 nothing changes anymore.
14685 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
14687 PR rtl-optimization/85645
14688 * regrename.c (build_def_use): Also kill the chains that include the
14689 destination of a REG_CFA_REGISTER note.
14691 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
14693 PR rtl-optimization/85645
14694 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
14695 insn that has a REG_CFA_REGISTER note.
14697 2018-05-09 Richard Sandiford <richard.sandiford@linaro.org>
14699 * cfgexpand.c (expand_clobber): New function.
14700 (expand_gimple_stmt_1): Use it.
14701 * tree-vect-stmts.c (vect_clobber_variable): New function,
14703 (vectorizable_simd_clone_call): ...here.
14704 (vectorizable_store): Emit a clobber either side of an
14705 IFN_STORE_LANES sequence.
14706 (vectorizable_load): Emit a clobber after an IFN_LOAD_LANES sequence.
14708 2018-05-09 Tom de Vries <tom@codesourcery.com>
14711 * config/nvptx/nvptx.md (define_insn "trap", define_insn "trap_if_true")
14712 (define_insn "trap_if_false"): Add exit after trap.
14714 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
14716 PR rtl-optimization/85638
14717 * bb-reorder.c: Include common/common-target.h.
14718 (create_forwarder_block): New function extracted from...
14719 (fix_up_crossing_landing_pad): ...here. Rename into...
14720 (dw2_fix_up_crossing_landing_pad): ...this.
14721 (sjlj_fix_up_crossing_landing_pad): New function.
14722 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
14723 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
14724 from both partitions and exit the loop after one iteration.
14726 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
14729 * doc/extend.texi (PowerPC Built-in Functions): Rename this
14731 (Basic PowerPC Built-in Functions): The new name of the
14732 subsection previously known as "PowerPC Built-in Functions".
14733 (Basic PowerPC Built-in Functions Available on all Configurations):
14735 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
14737 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
14739 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
14741 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
14744 2018-05-08 Jim Wilson <jimw@sifive.com>
14746 * config/riscv/linux.h (MUSL_ABI_SUFFIX): Delete unnecessary backslash.
14747 (LD_EMUL_SUFFIX): New.
14748 (LINK_SPEC): Use it.
14750 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
14752 * doc/extend.texi (PowerPC Built-in Functions): Rename this
14754 (Basic PowerPC Built-in Functions): The new name of the
14755 subsection previously known as "PowerPC Built-in Functions".
14756 (Basic PowerPC Built-in Functions Available on all Configurations):
14758 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
14760 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
14762 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
14764 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
14767 2018-05-08 Jakub Jelinek <jakub@redhat.com>
14770 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
14771 after cmpelim optimization.
14773 2018-05-08 Olga Makhotina <olga.makhotina@intel.com>
14775 * config.gcc: Support "goldmont".
14776 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "goldmont".
14777 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
14778 PROCESSOR_GOLDMONT.
14779 * config/i386/i386.c (m_GOLDMONT): Define.
14780 (processor_target_table): Add "goldmont".
14781 (PTA_GOLDMONT): Define.
14782 (ix86_lea_outperforms): Add TARGET_GOLDMONT.
14783 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT.
14784 (fold_builtin_cpu): Add M_INTEL_GOLDMONT.
14785 (fold_builtin_cpu): Add "goldmont".
14786 (ix86_add_stmt_cost): Add TARGET_GOLDMONT.
14787 (ix86_option_override_internal): Add "goldmont".
14788 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT.
14789 (processor_type): Add PROCESSOR_GOLDMONT.
14790 * config/i386/i386.md: Add CPU "glm".
14791 * config/i386/glm.md: New file.
14792 * config/i386/x86-tune.def: Add m_GOLDMONT.
14793 * doc/invoke.texi: Add goldmont as x86 -march=/-mtune= CPU type.
14795 2018-05-08 Jakub Jelinek <jakub@redhat.com>
14798 * config/i386/i386.c (ix86_expand_sse2_abs): Handle E_V2DImode and
14800 * config/i386/sse.md (abs<mode>2): Use VI_AVX2 iterator instead of
14801 VI1248_AVX512VL_AVX512BW. Handle V2DImode and V4DImode if not
14802 TARGET_AVX512VL using ix86_expand_sse2_abs. Formatting fixes.
14805 * config/i386/i386.c (ix86_fold_builtin): Handle
14806 IX86_BUILTIN_{,P}MOVMSK{PS,PD,B}{,128,256}.
14809 * config/i386/sse.md (ssequaterinsnmode): New mode attribute.
14810 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): New pattern.
14812 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
14815 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
14816 (check_arch): Likewise.
14817 (check_fpu): Return the result rather than printing it.
14818 (end arch): Fix operator precedence.
14819 (end cpu): Likewise.
14820 (END): Print the result from check_fpu.
14822 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
14823 Alan Hayward <alan.hayward@arm.com>
14824 David Sherwood <david.sherwood@arm.com>
14826 * config/aarch64/aarch64-sve.md (*pred_cmp<cmp_op><mode>_combine)
14827 (*pred_cmp<cmp_op><mode>, *fcm<cmp_op><mode>_and_combine)
14828 (*fcmuo<mode>_and_combine, *fcm<cmp_op><mode>_and)
14829 (*fcmuo<mode>_and): New patterns.
14831 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
14833 * config/aarch64/iterators.md (UNSPEC_COND_LO, UNSPEC_COND_LS)
14834 (UNSPEC_COND_HI, UNSPEC_COND_HS, UNSPEC_COND_UO): Delete.
14835 (SVE_INT_CMP, SVE_FP_CMP): New code iterators.
14836 (cmp_op, sve_imm_con): New code attributes.
14837 (SVE_COND_INT_CMP, imm_con): Delete.
14838 (cmp_op): Remove above unspecs from int attribute.
14839 * config/aarch64/aarch64-sve.md (*vec_cmp<cmp_op>_<mode>): Rename
14841 (*cmp<cmp_op><mode>): ...this. Use UNSPEC_MERGE_PTRUE instead of
14842 comparison-specific unspecs.
14843 (*vec_cmp<cmp_op>_<mode>_ptest): Rename to...
14844 (*cmp<cmp_op><mode>_ptest): ...this and adjust likewise.
14845 (*vec_cmp<cmp_op>_<mode>_cc): Rename to...
14846 (*cmp<cmp_op><mode>_cc): ...this and adjust likewise.
14847 (*vec_fcm<cmp_op><mode>): Rename to...
14848 (*fcm<cmp_op><mode>): ...this and adjust likewise.
14849 (*vec_fcmuo<mode>): Rename to...
14850 (*fcmuo<mode>): ...this and adjust likewise.
14851 (*pred_fcm<cmp_op><mode>): New pattern.
14852 * config/aarch64/aarch64.c (aarch64_emit_unop, aarch64_emit_binop)
14853 (aarch64_emit_sve_ptrue_op, aarch64_emit_sve_ptrue_op_cc): New
14855 (aarch64_unspec_cond_code): Remove handling of LTU, GTU, LEU, GEU
14857 (aarch64_gen_unspec_cond, aarch64_emit_unspec_cond): Delete.
14858 (aarch64_emit_sve_predicated_cond): New function.
14859 (aarch64_expand_sve_vec_cmp_int): Use aarch64_emit_sve_ptrue_op_cc.
14860 (aarch64_emit_unspec_cond_or): Replace with...
14861 (aarch64_emit_sve_or_conds): ...this new function. Use
14862 aarch64_emit_sve_ptrue_op for the individual comparisons and
14863 aarch64_emit_binop to OR them together.
14864 (aarch64_emit_inverted_unspec_cond): Replace with...
14865 (aarch64_emit_sve_inverted_cond): ...this new function. Use
14866 aarch64_emit_sve_ptrue_op for the comparison and
14867 aarch64_emit_unop to invert the result.
14868 (aarch64_expand_sve_vec_cmp_float): Update after the above
14869 changes. Use aarch64_emit_sve_ptrue_op for native comparisons.
14871 2018-05-07 Nathan Sidwell <nathan@acm.org>
14873 * doc/invoke.texi (C++ Dialect Options): Remove -ffor-scope.
14874 * doc/extend.texi (Deprecated Features): Remove -fno-for-scope
14875 (Backwards Compatibility): Likewise.
14877 2018-05-07 Luis Machado <luis.machado@linaro.org>
14881 2018-05-07 Luis Machado <luis.machado@linaro.org>
14883 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
14884 <prefetch_dynamic_strides>: New const bool field.
14885 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
14886 prefetch_dynamic_strides.
14887 (exynosm1_prefetch_tune): Likewise.
14888 (thunderxt88_prefetch_tune): Likewise.
14889 (thunderx_prefetch_tune): Likewise.
14890 (thunderx2t99_prefetch_tune): Likewise.
14891 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
14893 (aarch64_override_options_internal): Update to set
14894 PARAM_PREFETCH_DYNAMIC_STRIDES.
14895 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
14896 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
14897 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
14898 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
14899 prefetch-dynamic-strides setting.
14901 2018-05-07 Luis Machado <luis.machado@linaro.org>
14903 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
14904 <minimum_stride>: New const int field.
14905 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
14906 minimum_stride field.
14907 (exynosm1_prefetch_tune): Likewise.
14908 (thunderxt88_prefetch_tune): Likewise.
14909 (thunderx_prefetch_tune): Likewise.
14910 (thunderx2t99_prefetch_tune): Likewise.
14911 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
14912 (aarch64_override_options_internal): Update to set
14913 PARAM_PREFETCH_MINIMUM_STRIDE.
14914 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
14915 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
14916 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
14917 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
14918 stride is constant and is below the minimum stride threshold.
14920 2018-05-07 Luis Machado <luis.machado@linaro.org>
14922 * config/aarch64/aarch64.c (qdf24xx_prefetch_tune) <l2_cache_size>: Set
14925 2018-05-07 Luis Machado <luis.machado@linaro.org>
14927 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
14928 <prefetch_dynamic_strides>: New const bool field.
14929 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
14930 prefetch_dynamic_strides.
14931 (exynosm1_prefetch_tune): Likewise.
14932 (thunderxt88_prefetch_tune): Likewise.
14933 (thunderx_prefetch_tune): Likewise.
14934 (thunderx2t99_prefetch_tune): Likewise.
14935 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
14937 (aarch64_override_options_internal): Update to set
14938 PARAM_PREFETCH_DYNAMIC_STRIDES.
14939 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
14940 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
14941 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
14942 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
14943 prefetch-dynamic-strides setting.
14945 2018-05-07 Luis Machado <luis.machado@linaro.org>
14947 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
14948 <minimum_stride>: New const int field.
14949 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
14950 minimum_stride field.
14951 (exynosm1_prefetch_tune): Likewise.
14952 (thunderxt88_prefetch_tune): Likewise.
14953 (thunderx_prefetch_tune): Likewise.
14954 (thunderx2t99_prefetch_tune): Likewise.
14955 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
14956 (aarch64_override_options_internal): Update to set
14957 PARAM_PREFETCH_MINIMUM_STRIDE.
14958 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
14959 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
14960 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
14961 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
14962 stride is constant and is below the minimum stride threshold.
14964 2018-05-06 Jakub Jelinek <jakub@redhat.com>
14967 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
14968 the type is addressable. Don't force op into register if it has
14971 2018-05-05 Roland McGrath <mcgrathr@google.com>
14974 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
14975 any section for which we don't know a specific type it should have,
14976 regardless of name. Previously this was done only for the exact
14977 names ".init_array", ".fini_array", and ".preinit_array".
14978 (default_elf_asm_named_section): Add comment about
14979 relationship with default_section_type_flags and SECTION_NOTYPE.
14980 (get_section): Don't consider it a type conflict if one side has
14981 SECTION_NOTYPE and the other doesn't, as long as neither has the
14982 SECTION_BSS et al used in the default_section_type_flags logic.
14984 2018-05-05 Tom de Vries <tom@codesourcery.com>
14987 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_3): Define.
14988 (workaround_barsyncs): New function.
14989 (nvptx_reorg): Use workaround_barsyncs.
14990 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
14991 (define_expand "nvptx_membar_cta"): New define_expand.
14992 (define_insn "*nvptx_membar_cta"): New insn.
14994 2018-05-04 Pekka Jääskeläinen <pekka.jaaskelainen@parmance.com>
14996 * brig-builtins.def: Add consts to ptrs etc. in BRIG builtin defs.
14997 To improve optimization opportunities.
14998 * builtin-types.def: The new needed builtin types for the above.
15000 2018-05-04 Richard Biener <rguenther@suse.de>
15002 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
15003 * gimple-ssa-store-merging.c
15004 (imm_store_chain_info::output_merged_store): Remove redundant create,
15005 release split_store vector contents on failure.
15006 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
15007 scalar stmt vector on cache hit.
15009 2018-05-04 Segher Boessenkool <segher@kernel.crashing.org>
15011 * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
15013 * config.gcc (powerpc-xilinx-eabi*): Remove.
15014 * config/rs6000/predicates.md (easy_fp_constant): Remove Xilinx FP
15016 (fusion_addis_mem_combo_load): Ditto.
15017 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove Xilinx
15019 (rs6000_cpu_cpp_builtins): Ditto.
15020 * config/rs6000/rs6000-linux.c
15021 (rs6000_linux_float_exceptions_rounding_supported_p): Ditto.
15022 * config/rs6000/rs6000-opts.h (enum fpu_type_t): Delete.
15023 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove Xilinx FP
15025 (rs6000_setup_reg_addr_masks): Ditto.
15026 (rs6000_init_hard_regno_mode_ok): Ditto.
15027 (rs6000_option_override_internal): Ditto.
15028 (legitimate_lo_sum_address_p): Ditto.
15029 (rs6000_legitimize_address): Ditto.
15030 (rs6000_legitimize_reload_address): Ditto.
15031 (rs6000_legitimate_address_p): Ditto.
15032 (abi_v4_pass_in_fpr): Ditto.
15033 (setup_incoming_varargs): Ditto.
15034 (rs6000_gimplify_va_arg): Ditto.
15035 (rs6000_split_multireg_move): Ditto.
15036 (rs6000_savres_strategy): Ditto.
15037 (rs6000_emit_prologue_components): Ditto.
15038 (rs6000_emit_epilogue_components): Ditto.
15039 (rs6000_emit_prologue): Ditto.
15040 (rs6000_emit_epilogue): Ditto.
15041 (rs6000_elf_file_end): Ditto.
15042 (rs6000_function_value): Ditto.
15043 (rs6000_libcall_value): Ditto.
15044 * config/rs6000/rs6000.h: Ditto.
15045 (TARGET_MINMAX_SF, TARGET_MINMAX_DF): Delete, merge to ...
15046 (TARGET_MINMAX): ... this. New.
15047 (TARGET_SF_FPR, TARGET_DF_FPR, TARGET_SF_INSN, TARGET_DF_INSN): Delete.
15048 * config/rs6000/rs6000.md: Remove Xilinx FP support.
15049 (*movsi_internal1_single): Delete.
15050 * config/rs6000/rs6000.opt (msingle-float, mdouble-float, msimple-fpu,
15051 mfpu=, mxilinx-fpu): Delete.
15052 * config/rs6000/singlefp.h: Delete.
15053 * config/rs6000/sysv4.h: Remove Xilinx FP support.
15054 * config/rs6000/t-rs6000: Ditto.
15055 * config/rs6000/t-xilinx: Delete.
15056 * config/rs6000/titan.md: Adjust for fp_type removal.
15057 * config/rs6000/vsx.md: Remove Xilinx FP support.
15058 (VStype_simple): Delete.
15059 (VSfptype_simple, VSfptype_mul, VSfptype_div, VSfptype_sqrt): Delete.
15060 * config/rs6000/xfpu.h: Delete.
15061 * config/rs6000/xfpu.md: Delete.
15062 * config/rs6000/xilinx.h: Delete.
15063 * config/rs6000/xilinx.opt: Delete.
15064 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove
15065 -msingle-float, -mdouble-float, -msimple-fpu, -mfpu=, and -mxilinx-fpu.
15067 2018-05-04 Tom de Vries <tom@codesourcery.com>
15070 * builtins.c (expand_builtin_goacc_parlevel_id_size): Handle null target
15073 2018-05-04 Richard Biener <rguenther@suse.de>
15075 PR middle-end/85627
15076 * tree-complex.c (update_complex_assignment): We are always in SSA form.
15077 (expand_complex_div_wide): Likewise.
15078 (expand_complex_operations_1): Likewise.
15079 (expand_complex_libcall): Preserve EH info of the original stmt.
15080 (tree_lower_complex): Handle removed blocks.
15081 * tree.c (build_common_builtin_nodes): Do not set ECF_NOTRHOW
15082 on complex multiplication and division libcall builtins.
15084 2018-05-04 Richard Biener <rguenther@suse.de>
15086 PR middle-end/85574
15087 * fold-const.c (negate_expr_p): Restrict negation of operand
15088 zero of a division to when we know that can happen without
15090 (fold_negate_expr_1): Likewise.
15092 2018-05-04 Jakub Jelinek <jakub@redhat.com>
15095 * real.h (real_nextafter): Declare.
15096 * real.c (real_nextafter): New function.
15097 * fold-const-call.c (fold_const_nextafter): New function.
15098 (fold_const_call_sss): Call it for CASE_CFN_NEXTAFTER and
15099 CASE_CFN_NEXTTOWARD.
15100 (fold_const_call_1): For CASE_CFN_NEXTTOWARD call fold_const_call_sss
15101 even when arg1_mode is different from arg0_mode.
15103 2018-05-03 Nathan Sidwell <nathan@acm.org>
15105 * doc/extend.texi (Deprecated Features): Remove
15106 -ffriend-injection.
15107 (Backwards Compatibility): Likewise.
15108 * doc/invoke.texi (C++ Language Options): Likewise.
15109 (C++ Dialect Options): Likewise.
15111 2018-05-03 Jakub Jelinek <jakub@redhat.com>
15114 * config/i386/avx512fintrin.h (_mm512_mullox_epi64,
15115 _mm512_mask_mullox_epi64): New intrinsics.
15117 2018-05-03 Tom de Vries <tom@codesourcery.com>
15120 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
15121 dump files): Add offload-tree.
15123 2018-05-03 Richard Biener <rguenther@suse.de>
15125 PR tree-optimization/85615
15126 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
15127 to loops not nested in BBs loop father to avoid creating multi-entry
15130 2018-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15132 PR tree-optimization/70291
15133 * tree-complex.c (expand_complex_libcall): Add type, inplace_p
15134 arguments. Change return type to tree. Emit libcall as a new
15135 statement rather than replacing existing one when inplace_p is true.
15136 (expand_complex_multiplication_components): New function.
15137 (expand_complex_multiplication): Expand floating-point complex
15138 multiplication using the above.
15139 (expand_complex_division): Rename inner_type parameter to type.
15140 Update expand_complex_libcall call-site.
15141 (expand_complex_operations_1): Update expand_complex_multiplication
15142 and expand_complex_division call-sites.
15144 2018-05-02 Jakub Jelinek <jakub@redhat.com>
15147 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
15148 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
15149 *<shift_insn><dwi>3_doubleword_mask_1): In condition require that
15150 the highest significant bit of the shift count mask is clear. In
15151 check whether and[sq]i3 is needed verify that all significant bits
15152 of the shift count other than the highest are set.
15154 2018-05-02 Tom de Vries <tom@codesourcery.com>
15157 * builtins.def (DEF_GOACC_BUILTIN_ONLY): Define.
15158 * omp-builtins.def (BUILT_IN_GOACC_PARLEVEL_ID)
15159 (BUILT_IN_GOACC_PARLEVEL_SIZE): New builtin.
15160 * builtins.c (expand_builtin_goacc_parlevel_id_size): New function.
15161 (expand_builtin): Call expand_builtin_goacc_parlevel_id_size.
15162 * doc/extend.texi (Other Builtins): Add __builtin_goacc_parlevel_id and
15163 __builtin_goacc_parlevel_size.
15165 2018-05-02 Richard Biener <rguenther@suse.de>
15167 PR tree-optimization/85597
15168 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
15169 do not use split vect_get_vec_defs call but call vect_get_slp_defs
15172 2018-05-02 Tom de Vries <tom@codesourcery.com>
15175 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
15176 dump files): Add ltrans-tree.
15178 2018-05-02 Tom de Vries <tom@codesourcery.com>
15181 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
15182 dump files): Add wpa-ipa.
15184 2018-05-02 Segher Boessenkool <segher@kernel.crashing.org>
15186 * config.gcc (powerpc*-*-*): Remove paired.h. Unsupport the
15187 powerpc*-*-linux*paired* target.
15188 * config/rs6000/750cl.h: Delete.
15189 * config/rs6000/paired.h: Delete.
15190 * config/rs6000/paired.md: Delete.
15191 * config/rs6000/predicates.md (easy_vector_constant): Remove paired
15193 * config/rs6000/rs6000-builtin.def: Remove paired float support.
15194 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
15195 comment. Remove paired float support.
15196 * config/rs6000/rs6000-modes.def: Remove V2SF and V2SI.
15197 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
15199 * config/rs6000/rs6000-protos.h (paired_expand_vector_init,
15200 paired_emit_vector_cond_expr, paired_expand_vector_move): Delete
15202 * config/rs6000/rs6000.c: Remove paired float support.
15203 (paired_expand_vector_init, paired_expand_vector_move,
15204 paired_emit_vector_compare, paired_emit_vector_cond_expr,
15205 (paired_expand_lv_builtin, paired_expand_stv_builtin,
15206 paired_expand_builtin, paired_expand_predicate_builtin,
15207 paired_init_builtins): Delete.
15208 * config/rs6000/rs6000.h: Remove paired float support.
15209 * config/rs6000/rs6000.md: Remove paired float support.
15210 (move_from_CR_ov_bit): Delete.
15211 * config/rs6000/rs6000.opt (mpaired): Delete.
15212 * config/rs6000/t-rs6000: Remove paired.md from MD_INCLUDES.
15213 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mpaired.
15215 2018-05-02 Richard Biener <rguenther@suse.de>
15217 PR middle-end/85567
15218 * gimplify.c (gimplify_save_expr): When in SSA form allow
15219 SAVE_EXPRs to compute to SSA vars.
15221 2018-05-02 Jakub Jelinek <jakub@redhat.com>
15224 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
15225 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
15226 *<shift_insn><dwi>3_doubleword_mask_1): If and[sq]i3 is needed, don't
15227 clobber operands[2], instead use a new pseudo. Formatting fixes.
15229 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
15231 PR tree-optimization/85586
15232 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
15233 exit early for statements in the same group if the accesses are
15236 2018-05-02 Tom de Vries <tom@codesourcery.com>
15239 * lto-wrapper.c (compile_offload_image): Add "could not find mkoffload"
15242 2018-05-01 Marc Glisse <marc.glisse@inria.fr>
15244 PR tree-optimization/85143
15245 * match.pd (A<B&A<C): Extend to BIT_IOR_EXPR.
15247 2018-05-01 Tom de Vries <tom@codesourcery.com>
15250 * config/nvptx/mkoffload.c (main): Suggest using -B in "offload compiler
15251 not found" error message.
15253 2018-05-01 Tom de Vries <tom@codesourcery.com>
15256 * vec.h (VEC_ORDERED_REMOVE_IF, VEC_ORDERED_REMOVE_IF_FROM_TO): Define.
15257 * vec.c (test_ordered_remove_if): New function.
15258 (vec_c_tests): Call test_ordered_remove_if.
15259 * dwarf2cfi.c (connect_traces): Use VEC_ORDERED_REMOVE_IF_FROM_TO.
15260 * lto-streamer-out.c (prune_offload_funcs): Use VEC_ORDERED_REMOVE_IF.
15261 * tree-vect-patterns.c (vect_pattern_recog_1): Use
15262 VEC_ORDERED_REMOVE_IF.
15264 2018-05-01 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
15266 PR tree-optimization/82665
15267 * vr-values.c (vr_values::extract_range_from_binary_expr): Handle
15268 pointer subtraction where arguments come from a memchr call.
15270 2018-05-01 Jakub Jelinek <jakub@redhat.com>
15272 * configure.ac (LD_AS_NEEDED_OPTION, LD_NO_AS_NEEDED_OPTION): Use
15273 --push-state --as-needed and --pop-state instead of --as-needed and
15274 --no-as-needed if ld supports it.
15275 * configure: Regenerated.
15278 * doc/install.texi2html: Replace _002d with - and _002a with * in
15279 generated html files using sed.
15281 2018-04-30 David Malcolm <dmalcolm@redhat.com>
15284 * gcc-rich-location.c (blank_line_before_p): New function.
15285 (use_new_line): New function.
15286 (gcc_rich_location::add_fixit_insert_formatted): New function.
15287 * gcc-rich-location.h
15288 (gcc_rich_location::add_fixit_insert_formatted): New function.
15290 2018-04-30 David Malcolm <dmalcolm@redhat.com>
15292 * selftest.c (assert_streq): Rename "expected" and "actual" to
15293 "val1" and "val2". Extend NULL-handling to cover both inputs
15294 symmetrically, while still requiring both to be non-NULL for a pass.
15295 * selftest.h (assert_streq): Rename "expected" and "actual" to
15297 (ASSERT_EQ): Likewise.
15298 (ASSERT_EQ_AT): Likewise.
15299 (ASSERT_KNOWN_EQ): Likewise.
15300 (ASSERT_KNOWN_EQ_AT): Likewise.
15301 (ASSERT_NE): Likewise.
15302 (ASSERT_MAYBE_NE): Likewise.
15303 (ASSERT_MAYBE_NE_AT): Likewise.
15304 (ASSERT_STREQ): Likewise. Clarify that both must be non-NULL for
15305 the assertion to pass.
15306 (ASSERT_STREQ_AT): Likewise.
15308 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
15310 * doc/invoke.texi (-fpie, -fPIE): Fix grammar and clarify
15311 interaction with -pie.
15313 2018-04-30 David Malcolm <dmalcolm@redhat.com>
15315 * selftest.h: Fix alphabetization of per-source-file selftest
15318 2018-04-30 Jason Merrill <jason@redhat.com>
15320 PR c++/61982 - dead stores to destroyed objects.
15321 * gimplify.c (gimplify_modify_expr): Simplify complex lvalue on LHS
15324 2018-04-30 Jason Merrill <jason@redhat.com>
15326 * tree.c (build_clobber): New.
15327 * tree.h: Declare it.
15328 * gimplify.c (gimplify_bind_expr, gimplify_target_expr): Use it.
15330 2018-04-30 David Malcolm <dmalcolm@redhat.com>
15332 * diagnostic-show-locus.c (layout::layout): Update for
15333 location_get_source_line returning a char_span.
15334 (struct char_span): Move to input.h.
15335 (struct correction): Update for fields in char_span becoming
15337 (struct source_line): Update for location_get_source_line
15338 returning a char_span.
15339 (layout::print_line): Likewise.
15340 * edit-context.c (edited_file::print_content): Likewise.
15341 (edited_file::print_diff_hunk): Likewise.
15342 (edited_file::print_run_of_changed_lines): Likewise.
15343 (edited_file::get_num_lines): Likewise.
15344 (edited_line::edited_line): Likewise.
15345 * final.c (asm_show_source): Likewise.
15346 * input.c (location_get_source_line): Convert return type
15347 from const char * to char_span, losing the final "line_len"
15349 (dump_location_info): Update for the above.
15350 (get_substring_ranges_for_loc): Likewise. Use a char_span
15351 when handling the literal within the line.
15352 (test_reading_source_line): Update for location_get_source_line
15353 returning a char_span.
15354 * input.h (class char_span): Move here from
15355 diagnostic-show-locus.c, converting from a struct to a class.
15356 Make data members private.
15357 (char_span::operator bool): New.
15358 (char_span::length): New.
15359 (char_span::get_buffer): New.
15360 (char_span::operator[]): New.
15361 (char_span::subspan): Make const.
15362 (char_span::xstrdup): New.
15363 (location_get_source_line): Convert return type from const char *
15364 to char_span, losing the final "line_size" param.
15366 2018-04-30 Jan Hubicka <jh@suse.cz>
15368 * lto-wrapper.c (ltrans_priorities): New static var.
15369 (cmp_priority): New.
15370 (run_gcc): Read priorities and if doing parallel build order
15371 the Makefile by them.
15373 2018-04-30 David Malcolm <dmalcolm@redhat.com>
15375 * input.h (builtins_location_check): Convert to a STATIC_ASSERT.
15377 2018-04-30 Richard Biener <rguenther@suse.de>
15379 * tree-cfg.c (verify_address): Remove base argument, add
15380 flag whether to check TREE_ADDRESSABLE and do that.
15381 (verify_expr): Remove.
15382 (verify_types_in_gimple_reference): Add pieces from verify_expr.
15383 (verify_gimple_assign_single): Likewise.
15384 (verify_gimple_switch): Likewise.
15385 (verify_expr_location_1): Dereference tp once. Add (disabled)
15386 piece from verify_expr.
15387 (verify_gimple_in_cfg): Do not call verify_expr on all ops.
15389 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
15391 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
15393 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
15395 * config/arc/arc-protos.h (prepare_extend_operands): Remove.
15396 (small_data_pattern): Likewise.
15397 (arc_rewrite_small_data): Likewise.
15398 * config/arc/arc.c (LEGITIMATE_SMALL_DATA_OFFSET_P): Remove.
15399 (LEGITIMATE_SMALL_DATA_ADDRESS_P): Likewise.
15400 (get_symbol_alignment): New function.
15401 (legitimate_small_data_address_p): Likewise.
15402 (legitimate_scaled_address): Update, call
15403 legitimate_small_data_address_p.
15404 (output_sdata): New static variable.
15405 (arc_print_operand): Update how we handle small data operands.
15406 (arc_print_operand_address): Likewise.
15407 (arc_legitimate_address_p): Update, use
15408 legitimate_small_data_address_p.
15409 (arc_rewrite_small_data_p): Remove.
15410 (arc_rewrite_small_data_1): Likewise.
15411 (arc_rewrite_small_data): Likewise.
15412 (small_data_pattern): Likewise.
15413 (compact_sda_memory_operand): Update to use
15414 legitimate_small_data_address_p and get_symbol_alignment.
15415 (prepare_move_operands): Don't rewite sdata pattern.
15416 (prepare_extend_operands): Remove.
15417 * config/arc/arc.md (zero_extendqihi2): Don't rewrite sdata
15419 (zero_extendqisi2): Likewise.
15420 (zero_extendhisi2): Likewise.
15421 (extendqihi2): Likewise.
15422 (extendqisi2): Likewise.
15423 (extendhisi2): Likewise.
15424 (addsi3): Likewise.
15425 (subsi3): Likewise.
15426 (andsi3): Likewise.
15427 * config/arc/constraints.md (Usd): Change it to memory constraint.
15429 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
15431 * config/arc/arc.c (arc_split_move): Allow signed 6-bit constants
15432 as source of std instructions.
15433 * config/arc/arc.md (movsi_insn): Update pattern predicate to
15434 allow 6-bit constants as source for store instructions.
15435 (movdi_insn): Update instruction pattern to allow 6-bit constants
15436 as source for store instructions.
15438 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
15440 * doc/invoke.texi (-fdebug-types-section): Fix grammar.
15442 2018-04-30 Nathan Sidwell <nathan@acm.org>
15443 Sandra Loosemore <sandra@codesourcery.com>
15445 * dumpfile.c (dump_open): Allow '-' for stdout.
15446 * doc/invoke.texi (Developer Options): Document dump filename
15447 determination early. Document stdin/stdout selection.
15449 2018-04-30 Andrew Sadek <andrew.sadek.se@gmail.com>
15451 Microblaze Target: PIC data text relative
15453 * config/microblaze/microblaze.opt: add new option -mpic-data-text-rel.
15454 * config/microblaze/microblaze-protos.h (microblaze_constant_address_p):
15456 * config/microblaze/microblaze.h (microblaze_constant_address_p):
15457 CONSTANT_ADDRESS_P definition to microblaze_constant_address_p.
15458 * config/microblaze/microblaze.c (TARGET_PIC_DATA_TEXT_REL):
15459 New addressing mode for data-text relative position indepenedent code.
15460 (microblaze_classify_unspec): add 'UNSPEC_TEXT' case ->
15461 'ADDRESS_SYMBOLIC_TXT_REL'.
15462 (microblaze_classify_address): Add handling for UNSPEC + CONST_INT.
15463 (microblaze_legitimate_pic_operand): Exclude function calls from
15464 pic operands in case of TARGET_PIC_DATA_TEXT_REL option.
15465 (microblaze_legitimize_address): Generate 'UNSPEC_TEXT' for all possible
15467 (microblaze_address_insns): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
15468 (print_operand): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
15469 (print_operand_address): Add 'ADDRESS_SYMBOLIC_TXT_REL' case + handling
15470 for 'address + offset'.
15471 (microblaze_expand_prologue): Add new function prologue call for
15473 (microblaze_asm_generate_pic_addr_dif_vec): Override new target hook
15474 'TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC' to disable address diff vector
15475 table in case of TARGET_PIC_DATA_TEXT_REL.
15476 (expand_pic_symbol_ref): Add handling for 'UNSPEC_TEXT'.
15477 * config/microblaze/microblaze.md (TARGET_PIC_DATA_TEXT_REL):
15478 Add new macros 'UNSPEC_TEXT',
15479 'UNSPEC_SET_TEXT' + add rule for setting r20 in function prologue
15480 + exclude function calls from 'UNSPEC_PLT' in case of data text
15482 * doc/tm.texi.in (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
15483 new target hook for generating address diff vector tables in case of
15485 * doc/tm.texi : Regenerate.
15486 * stmt.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Append new condition
15487 'targetm.asm_out.generate_pic_addr_diff_vec' to flag_pic in case
15488 of addr diff vector generation.
15489 * target.def (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
15490 target hook definition.
15491 * targhooks.h, targhooks.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC):
15492 Add default function for generate_pic_addr_diff_vec -> flag_pic.
15493 * doc/invoke.texi (Add new pic option): Add new microblaze pic
15494 option for data text relative.
15496 2018-04-30 Richard Biener <rguenther@suse.de>
15498 * tree-chrec.h (evolution_function_is_constant_p): Remove
15500 * tree-cfg.c (tree_node_can_be_shared): Re-order checks.
15502 2018-04-30 Richard Biener <rguenther@suse.de>
15505 * dwarf2out.c (gen_producer_string): Ignore -fchecking[=].
15507 2018-04-30 Richard Biener <rguenther@suse.de>
15509 PR tree-optimization/28364
15510 PR tree-optimization/85275
15511 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
15512 copying first exit test.
15514 2018-04-28 Mark Wielaard <mark@klomp.org>
15516 * dwarf2out.c (dwarf2out_finish): Add .debug_addr table header for
15517 dwarf_version >= 5.
15518 (dwarf_AT): Handle DW_AT_addr_base.
15519 (add_top_level_skeleton_die_attrs): Use dwarf_AT for DW_AT_addr_base.
15521 2018-04-28 Uros Bizjak <ubizjak@gmail.com>
15524 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask): New pattern.
15525 (*ashl<dwi>3_doubleword_mask_1): Ditto.
15526 (*<shift_insn><dwi>3_doubleword_mask): Ditto.
15527 (*<shift_insn><dwi>3_doubleword_mask_1): Ditto.
15529 2018-04-28 Richard Biener <rguenther@suse.de>
15531 * tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
15532 (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
15533 to reflect use. Only add interesting stmts.
15535 2018-04-27 Martin Jambor <mjambor@suse.cz>
15538 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
15539 the jump function allows for passing through aggregate values.
15541 2018-04-27 David Malcolm <dmalcolm@redhat.com>
15543 * input.h (in_system_header_at): Convert from macro to inline
15545 (from_macro_expansion_at): Likewise.
15546 (from_macro_definition_at): Likewise.
15548 2018-04-27 Jeff Law <law@redhat.com>
15550 * config.gcc: Mark tile* targets as deprecated/obsolete.
15552 2018-04-27 Richard Biener <rguenther@suse.de>
15554 * config/aarch64/aarch64.c: Simplify ap.__stack advance and
15557 2018-04-27 Richard Biener <rguenther@suse.de>
15559 * tree-cfg.c (verify_expr): Make dead code hit gcc_unreachable.
15561 2018-04-27 Uros Bizjak <ubizjak@gmail.com>
15563 * config/i386/i386.md (*movti_internal): Substitute Ye constraint
15564 with Yd constraint. Set "preferred_for_speed" attribute from
15565 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for alternatives
15566 with Yd constraint.
15567 (*movdi_internal): Ditto.
15568 (movti_interunit splitters): Remove
15569 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC from insn condition.
15570 (movdi_interunit splitters): Ditto.
15571 * config/i386/constraints.md (Ye): Remove.
15572 (Yd): Do not depend on TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC.
15574 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15577 * config/aarch64/constraints.md (Usg): Limit to 31.
15578 (Usj): Limit to 63.
15580 2018-04-27 Jakub Jelinek <jakub@redhat.com>
15582 PR tree-optimization/85529
15583 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
15584 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
15585 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
15586 zero extension or masking of the MSB bit.
15587 (optimize_range_tests): Add FIRST_BB argument, pass it through
15588 to optimize_range_tests_var_bound.
15589 (maybe_optimize_range_tests, reassociate_bb): Adjust
15590 optimize_range_tests callers.
15592 2018-04-26 Richard Biener <rguenther@suse.de>
15593 Jakub Jelinek <jakub@redhat.com>
15595 * cgraph.h (symbol_table): Just declare debug method here.
15596 * symtab.c (symbol_table::debug): Define.
15598 2018-04-26 Eric Botcazou <ebotcazou@adacore.com>
15600 * loop-invariant.c (may_assign_reg_p): Return false for frame pointer.
15602 2018-04-26 Uros Bizjak <ubizjak@gmail.com>
15604 * config/i386/i386.md ("isa" attribute): Add x64_sse2.
15605 ("enabled" attribute): Handle x64_sse2 "isa" attribute.
15606 (*movdi_internal): Substitute Yi and Yj constraint with x
15607 and Ym and Yn constraint with y constraint. Update "isa"
15608 attribute and set "preferred_for_speed" attribute from
15609 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for updated alternatives.
15610 (*movsi_internal): Ditto.
15611 (*movdf_internal): Ditto.
15612 (*movsf_internal): Ditto.
15613 (*zero_extendsidi2): Ditto.
15614 * config/i386/sse.md (vec_set<mode>_0): Ditto.
15615 (sse2_loadld): Ditto.
15616 (*vec_extract<ssevecmodelower>_0): Ditto.
15617 (*vec_extractv4si_0_zext_sse4): Ditto.
15618 (vec_concatv2di): Ditto.
15619 (*vec_dup<mode>): Ditto.
15620 * config/i386/mmx.md (*mov<mode>_internal): Ditto.
15621 * config/i386/constraints.md (Yi): Remove.
15626 2018-04-26 Nathan Sidwell <nathan@acm.org>
15628 * dumpfile.c (dump_open): New.
15629 (dump_open_alternate_stream, dump_start, dump_begin): Call it.
15630 (dump_finish): Detect stdio/stderr by value not name.
15632 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
15634 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
15636 2018-04-26 Tom de Vries <tom@codesourcery.com>
15639 * config/nvptx/nvptx.c (verify_neutering_jumps)
15640 (verify_neutering_labels): New function
15641 (nvptx_single): Use verify_neutering_jumps and verify_neutering_labels.
15643 2018-04-26 Tom de Vries <tom@codesourcery.com>
15646 * config/nvptx/nvptx.c (needs_neutering_p): New function.
15647 (nvptx_single): Use needs_neutering_p to skip over insns that do not
15650 2018-04-26 Richard Biener <rguenther@suse.de>
15651 Tom de Vries <tom@codesourcery.com>
15654 * lto-streamer-out.c (output_function): Fixup loops if required to match
15655 discovery done in the reader.
15657 2018-04-26 Richard Biener <rguenther@suse.de>
15659 PR tree-optimization/85116
15660 * tree-ssa-loop-ch.c (do_while_loop_p): A do-while loop should
15661 have a loop exit from the single latch predecessor. Remove
15662 case of header with just condition.
15663 (ch_base::copy_headers): Exclude infinite loops from any
15665 (pass_ch::execute): Record exits.
15667 2018-04-26 Richard Biener <rguenther@suse.de>
15669 * tree-vect-data-refs.c (vect_get_data_access_cost): Get
15670 prologue cost vector and pass it to vect_get_load_cost.
15671 (vect_get_peeling_costs_all_drs): Likewise.
15672 (vect_peeling_hash_get_lowest_cost): Likewise.
15673 (vect_enhance_data_refs_alignment): Likewise.
15675 2018-04-26 Richard Biener <rguenther@suse.de>
15677 PR middle-end/85450
15678 * tree-cfg.c (verify_gimple_assign_unary): Restore proper
15679 checking of integer<->pointer conversions.
15680 * omp-expand.c (expand_omp_for_static_nochunk): Avoid
15681 sign-/zero-extending pointer types.
15682 (expand_omp_for_static_chunk): Likewise.
15684 2018-03-22 Hans-Peter Nilsson <hp@axis.com>
15685 Jean Lee <xiaoyur347@gmail.com>
15687 * config/mips/mips.c (mips_asan_shadow_offset): New function.
15688 (TARGET_ASAN_SHADOW_OFFSET): Define.
15689 * config/mips/mips.h (FRAME_GROWS_DOWNWARD): Augment to also be
15690 true for -fsanitize=address.
15692 2018-04-25 Mark Wielaard <mark@klomp.org>
15694 * dwarf2out.c (file_info_cmp): Sort longer dir prefixes before
15697 2018-04-25 Jakub Jelinek <jakub@redhat.com>
15699 * config/i386/i386.md (*x86_mov<mode>cc_0_m1): Use type "alu1" rather
15700 than "alu", remove explicit "memory" and "imm_disp" attributes.
15701 (*x86_mov<mode>cc_0_m1_se, *x86_mov<mode>cc_0_m1_neg): Likewise.
15703 PR middle-end/85414
15704 * simplify-rtx.c (simplify_unary_operation_1) <case SIGN_EXTEND,
15705 case ZERO_EXTEND>: Pass SUBREG_REG (op) rather than op to
15706 gen_lowpart_no_emit.
15708 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
15711 * config/i386/i386.c (ix86_expand_builtin): Change memory
15712 operand to XI, extend p0 to Pmode.
15713 * config/i386/i386.md: Change unspec volatile and operand
15714 1 mode to XI, change operand 0 mode to P.
15716 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
15718 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
15719 GET_MODE_MASK before any checking.
15720 (nds32_can_use_bset_p): Likewise.
15721 (nds32_can_use_btgl_p): Likewise.
15723 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
15725 * config/nds32/nds32-doubleword.md: New define_split pattern for
15726 illegal register number.
15728 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
15730 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
15732 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
15734 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
15736 2018-04-25 Richard Biener <rguenther@suse.de>
15738 * lto-streamer.h (LTO_major_version): Bump to 8.
15740 2018-04-25 Jakub Jelinek <jakub@redhat.com>
15742 * BASE-VER: Set to 9.0.0.
15744 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
15746 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
15747 in __abskf2 and __powikf2.
15749 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15752 * config/aarch64/constraints.md (Usg, Usj): New constraints.
15753 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
15754 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
15755 Use the above on operand 2. Reindent.
15756 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
15758 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
15761 * common/config/i386/i386-common.c (ix86_handle_option): Don't
15763 * config/i386/i386.opt (mcet): Removed.
15764 * doc/install.texi: Remove -mcet documentation.
15765 * doc/invoke.texi: Likewise.
15767 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
15770 * doc/install.texi: Remove -mcet from bootstrap-cet.
15772 2018-04-24 Jakub Jelinek <jakub@redhat.com>
15775 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
15776 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
15780 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
15781 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
15782 containing a CONST_VECTOR.
15784 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
15786 * doc/install.texi: Update newlib dependency for nvptx.
15788 2018-04-24 Jakub Jelinek <jakub@redhat.com>
15791 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
15792 instead of INTVAL when shifting x left.
15794 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
15796 PR tree-optimization/85478
15797 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
15798 vect_grouped_store_supported for single element vectors.
15800 2018-04-24 Richard Biener <rguenther@suse.de>
15803 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
15804 load cost increase to the case of non-constant step.
15806 2018-04-24 Jakub Jelinek <jakub@redhat.com>
15809 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
15810 destination if any_malformed_asm.
15812 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
15814 PR middle-end/85496
15815 * expr.c (store_field): In the bitfield case, if the value comes from
15816 a function call and is returned in registers by means of a PARALLEL,
15817 do not change the mode of the temporary unless BLKmode and VOIDmode.
15819 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
15821 PR rtl-optimization/85423
15822 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
15823 dependencies to debug insns when the previous insn is non-debug.
15825 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
15827 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
15828 enums into a single definition.
15829 (fls): Fix predicates and printing.
15832 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
15834 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
15835 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
15836 and short u6 immediate.
15837 (check_if_valid_sleep_operand): Remove.
15838 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
15840 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
15842 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
15843 flag_always_save_lp condition.
15844 * config/nds32/nds32.opt (malways-save-lp): New option.
15846 2018-04-22 Shiva Chen <shiva0217@gmail.com>
15848 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
15849 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
15850 * config/nds32/nds32.h
15851 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
15852 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
15854 2018-04-22 Shiva Chen <shiva0217@gmail.com>
15856 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
15857 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
15859 2018-04-22 Shiva Chen <shiva0217@gmail.com>
15860 Chung-Ju Wu <jasonwucj@gmail.com>
15862 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
15864 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
15865 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
15867 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
15869 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
15871 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
15873 * config/nds32/nds32-protos.h (nds32_data_alignment,
15874 nds32_local_alignment): Declare.
15875 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
15876 nds32_local_alignment): New functions.
15877 (TARGET_CONSTANT_ALIGNMENT): Define.
15878 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
15880 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
15882 * config/nds32/nds32.c
15883 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
15884 (TARGET_MODES_TIEABLE_P): Likewise.
15886 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
15888 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
15889 level Ofast and Og.
15891 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
15892 Chung-Ju Wu <jasonwucj@gmail.com>
15894 * config/nds32/constants.md (unspec_volatile_element): Add enum values
15895 for unaligned access.
15896 * config/nds32/nds32-intrinsic.c: Implementation of expanding
15898 * config/nds32/nds32-intrinsic.md: Likewise.
15899 * config/nds32/nds32_intrinsic.h: Likewise.
15900 * config/nds32/nds32.h (nds32_builtins): Likewise.
15901 * config/nds32/nds32.opt (munaligned-access): New option.
15902 * config/nds32/nds32.c (nds32_asm_file_start): Display
15903 flag_unaligned_access status.
15905 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
15907 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
15908 -mno-relax is present.
15909 * config/riscv/linux.h (LINK_SPEC): Ditto.
15911 2018-04-20 Martin Sebor <msebor@redhat.com>
15914 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
15916 (gimple_fold_builtin_stxcpy_chk): Same.
15917 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
15919 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
15922 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
15923 __powikf2 when long double is IEEE 128-bit.
15925 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
15927 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
15928 step to make sure stack always aligned.
15930 2018-04-20 Carl Love <cel@us.ibm.com>
15933 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
15934 size check for arg0.
15936 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
15937 Tom de Vries <tom@codesourcery.com>
15940 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
15941 Emit insns for calls too.
15942 (nvptx_find_par): Always look for worker-level predecessor insn.
15943 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
15945 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
15946 (nvptx_process_pars): Propagate frames for calls.
15948 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
15951 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
15953 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
15954 (ix86_handle_option): Don't handle OPT_mibt.
15955 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
15957 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
15959 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
15960 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
15961 (ix86_target_macros): Define __CET__ with flag_cf_protection
15962 for -fcf-protection.
15963 * config/i386/i386.c (isa2_opts): Remove -mibt.
15964 * config/i386/i386.h (TARGET_IBT): Removed.
15965 (TARGET_IBT_P): Likewise.
15966 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
15967 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
15968 * config/i386/i386.opt (mcet): Update help message.
15969 (mshstk): Likewise.
15971 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
15972 -mcet as an alias for -mshstk.
15974 2018-04-20 Richard Biener <rguenther@suse.de>
15976 PR middle-end/85475
15977 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
15978 complexity by forcing a single use of the multiply operand.
15980 2018-04-20 Martin Jambor <mjambor@suse.cz>
15983 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
15984 recursion dependency to only apply to non-clones.
15986 2018-04-20 Martin Jambor <mjambor@suse.cz>
15989 * ipa-cp.c (create_specialized_node): Check that clones of
15990 self-recursive edges exist during IPA-CP.
15992 2018-04-19 Toon Moene <toon@moene.org>
15994 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
15997 2018-04-19 Jakub Jelinek <jakub@redhat.com>
15999 PR tree-optimization/85467
16000 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
16001 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
16002 VECTOR_CST element to type.
16004 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
16007 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
16008 * config/i386/i386.md (builtin_setjmp_setup): Removed.
16009 (builtin_longjmp): Likewise.
16010 (save_stack_nonlocal): New pattern.
16011 (restore_stack_nonlocal): Likewise.
16013 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
16016 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
16017 Replace ASM_OUTPUT_LABEL with fprintf.
16019 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
16022 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
16023 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
16024 * config/i386/i386-c.c (ix86_target_macros_internal): Also
16025 define __IBT__ and __SHSTK__ for -fcf-protection.
16026 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
16028 (ix86_trampoline_init): Likewise.
16029 (x86_output_mi_thunk): Likewise.
16030 (ix86_notrack_prefixed_insn_p): Likewise.
16031 (ix86_option_override_internal): Don't disallow -fcf-protection.
16032 * config/i386/i386.md (rdssp<mode>): Also enable for
16034 (incssp<mode>): Likewise.
16035 (nop_endbr): Likewise.
16036 * config/i386/i386.opt (mcet): Change help message to built-in
16039 (mshstk): Likewise.
16040 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
16041 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
16042 enable CET built-in functions.
16044 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
16046 * common/config/i386/i386-common.c
16047 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
16048 OPTION_MASK_ISA_MOVDIRI_UNSET,
16049 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
16050 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
16051 * config.gcc (movdirintrin.h): New header.
16052 * config/i386/cpuid.h (bit_MOVDIRI,
16053 bit_MOVDIR64B): New bits.
16054 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
16056 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
16057 (VOID, PVOID, PCVOID)): New function types.
16058 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
16059 __builtin_ia32_directstoreu_u64,
16060 __builtin_ia32_movdir64b): New builtins.
16061 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
16062 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
16064 (ix86_valid_target_attribute_inner_p): Ditto.
16065 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
16066 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
16067 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
16068 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
16069 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
16070 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
16071 (movdiri<mode>, movdir64b_<mode>): New.
16072 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
16073 * config/i386/immintrin.h: Include movdirintrin.h.
16074 * config/i386/movdirintrin.h: New file.
16075 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
16077 2018-04-19 Richard Biener <rguenther@suse.de>
16079 PR middle-end/85455
16080 * cfg.c (clear_bb_flags): When loop state says we have
16081 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
16083 2018-04-19 Richard Biener <rguenther@suse.de>
16085 PR tree-optimization/84737
16086 * tree-vect-data-refs.c (vect_copy_ref_info): New function
16087 copying restrict info.
16088 (vect_setup_realignment): Use it.
16089 * tree-vectorizer.h (vect_copy_ref_info): Declare.
16090 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
16091 the first DR to all generated stores.
16092 (vectorizable_load): Likewise for loads.
16094 2018-04-19 Jakub Jelinek <jakub@redhat.com>
16096 PR tree-optimization/85446
16097 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
16098 the integral and pointer types to have the same precision.
16100 * doc/install.texi: Document --disable-cet being the default and
16103 2018-04-18 Martin Liska <mliska@suse.cz>
16105 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
16108 2018-04-18 Martin Liska <mliska@suse.cz>
16111 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
16114 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
16115 arguments if they are comparable.
16117 2018-04-18 Martin Liska <mliska@suse.cz>
16120 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
16123 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
16126 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
16129 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
16130 ENDBR after calling __morestack.
16132 2018-04-18 David Malcolm <dmalcolm@redhat.com>
16135 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
16136 by using gcc_base_ver to generate a gcc_driver_version, and use
16137 it when generating GCC_DRIVER_NAME.
16138 * configure: Regenerate.
16140 2018-04-18 Jakub Jelinek <jakub@redhat.com>
16143 * config.gcc: Obsolete powerpc*-*-*spe*.
16145 2018-04-17 Jakub Jelinek <jakub@redhat.com>
16148 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
16149 (stabstr_D): Change type of unum from unsigned int to
16150 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
16153 2018-04-17 Jim Wilson <jimw@sifive.com>
16156 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
16157 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
16158 Set arg_pointer_offset after using pretend_args_size.
16160 2018-04-17 Jakub Jelinek <jakub@redhat.com>
16162 PR rtl-optimization/85431
16163 * dse.c (record_store): Ignore zero width stores.
16166 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
16167 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
16168 __builtin_stack_restore rather than after it.
16169 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
16170 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
16171 argument instead of virtual_dynamic_stack_rtx.
16173 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
16175 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
16177 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
16178 Add note to error message to explain internal mapping of overloaded
16179 built-in function name to non-overloaded built-in function name.
16180 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
16183 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
16186 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
16187 where the inputs overlap with the output.
16189 2018-04-17 Jakub Jelinek <jakub@redhat.com>
16191 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
16192 (=v, v) alternative and explicit "memory" attribute.
16193 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
16194 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
16196 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
16197 "sselog1" type instead of "sselog".
16198 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
16199 "sselog". Remove explicit "memory" attribute.
16200 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
16201 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
16203 (vec_extract_hi_v32hi): Merge all alternatives into one, use
16204 "sselog1" type instead of "sselog". Remove explicit "memory"
16206 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
16207 use "sselog1" type instead of "sselog". Remove explicit "memory"
16209 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
16210 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
16212 (vec_extract_hi_v64qi): Merge all alternatives into one, use
16213 "sselog1" type instead of "sselog". Remove explicit "memory"
16215 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
16216 use "sselog1" type instead of "sselog". Remove explicit "memory"
16220 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
16222 PR middle-end/85414
16223 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
16226 2018-04-17 Martin Jambor <mjambor@suse.cz>
16229 * ipa-cp.c (create_specialized_node): Call
16230 expand_all_artificial_thunks if necessary.
16232 2018-04-17 Martin Liska <mliska@suse.cz>
16235 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
16236 in message, remote space in between '_G' and '('.
16238 2018-04-17 Jakub Jelinek <jakub@redhat.com>
16241 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
16242 avx512f_vmcmp<mode>3<round_saeonly_name>,
16243 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
16244 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
16245 avx512f_rndscale<mode><round_saeonly_name>,
16246 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
16247 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
16248 Use %<iptr>2 instead of %2 for -masm=intel.
16249 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
16250 avx512f_vcvttss2usi<round_saeonly_name>,
16251 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
16253 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
16254 avx512f_vcvttsd2usi<round_saeonly_name>,
16255 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
16256 Use %q1 instead of %1 for -masm=intel.
16257 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
16258 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
16259 of %3 for -masm=intel.
16260 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
16262 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
16264 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
16266 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
16267 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
16269 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
16271 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
16272 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
16273 %g1 and one with %0 and %1.
16274 (avx512er_vmrcp28<mode><round_saeonly_name>,
16275 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
16276 %1 for -masm=intel.
16277 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
16278 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
16279 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
16280 of %0 and %{%4%} for -masm=intel.
16281 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
16282 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
16283 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
16284 order of %0 and %{%5%}%{z%} for -masm=intel.
16286 2018-04-17 Jan Hubicka <jh@suse.cz>
16289 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
16291 2018-04-17 Martin Liska <mliska@suse.cz>
16294 * multiple_target.c (create_dispatcher_calls): Set apostrophes
16295 for target_clone error message. Make default implementation
16296 clone to be a local declaration.
16297 (separate_attrs): Add new argument and check for an empty
16299 (expand_target_clones): Handle it.
16300 (ipa_target_clone): Make redirection just for target_clones
16303 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
16304 Tom de Vries <tom@codesourcery.com>
16306 PR middle-end/84955
16307 * omp-expand.c (expand_oacc_for): Add dummy false branch for
16308 tiled basic blocks without omp continue statements.
16310 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
16313 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
16314 vec_extract expression as having side effects to make sure it gets
16317 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
16320 * config/i386/i386.c (get_builtin_code_for_version): Check
16323 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
16326 * config.gcc: Support "skylake".
16327 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
16329 * config/i386/i386.c (m_SKYLAKE): Define.
16330 (processor_target_table): Add "skylake".
16331 (ix86_option_override_internal): Add "skylake".
16332 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
16333 PROCESSOR_CANNONLAKE.
16334 (get_builtin_code_for_version): Fix priority for
16335 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
16336 PROCESSOR_SKYLAKE-AVX512.
16337 * config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
16338 (processor_type): Add PROCESSOR_SKYLAKE.
16340 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
16341 Jason Merrill <jason@redhat.com>
16344 * convert.c (convert_to_integer_1): Use direct recursion for
16345 enumeral types and types with a precision less than the number
16346 of bits in their mode.
16348 2018-04-16 Julia Koval <julia.koval@intel.com>
16351 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
16352 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
16354 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
16357 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
16358 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
16359 and -mno-direct-move.
16361 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
16364 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
16365 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
16366 Ensure negative shifts result in {0}.
16368 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
16370 PR rtl-optimization/79916
16371 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
16372 regs (if any) to define how to gnerate SD moves when LRA is in
16375 2018-04-13 Jakub Jelinek <jakub@redhat.com>
16377 PR rtl-optimization/85393
16378 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
16379 * except.c (expand_dw2_landing_pad_for_region): Make static.
16380 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
16381 a label and unconditional jump to old_bb, rather than
16382 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
16385 PR rtl-optimization/85376
16386 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
16387 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
16388 instead of a specific value.
16390 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
16391 Bin Cheng <bin.cheng@arm.com>
16393 PR tree-optimization/82965
16394 PR tree-optimization/83991
16395 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
16396 by_profile_only parameter.
16397 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
16398 information if the loop was predicted to iterate too many times.
16399 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
16401 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
16404 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
16407 2018-04-13 Martin Liska <mliska@suse.cz>
16408 Jakub Jelinek <jakub@redhat.com>
16410 PR middle-end/81657
16411 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
16412 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
16413 * builtins.c (expand_builtin_memory_copy_args): Use
16414 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
16415 handle dest_addr == pc_rtx.
16417 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
16420 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
16421 asked to not generate direct moves.
16422 (fix_trunc<mode>si2_stfiwx): Similar.
16423 (fix_trunc<mode>si2_internal): Similar.
16425 2018-04-12 Jakub Jelinek <jakub@redhat.com>
16428 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
16429 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
16430 lookup if dest in some wider mode is known to be const0_rtx and
16431 if so, record permanent equivalence for it to be ZERO_EXTEND of
16432 the narrower mode destination.
16434 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
16436 * lto-streamer-out.c (output_function): Revert 259346.
16437 * omp-expand.c (expand_oacc_for): Likewise.
16439 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
16441 PR rtl-optimization/85354
16442 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
16443 * sel-sched.c (sel_global_init): ... here.
16445 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
16448 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
16449 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
16450 mode for PE-COFF targets.
16451 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
16452 (i386_pe_asm_lto_end): Likewise.
16453 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
16454 (TARGET_ASM_LTO_END): Likewise.
16455 * config/i386/winnt.c (saved_debug_info_level): New static variable.
16456 (i386_pe_asm_lto_start): New function.
16457 (i386_pe_asm_lto_end): Likewise.
16459 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
16460 Richard Biener <rguenther@suse.de>
16462 PR middle-end/84955
16463 * lto-streamer-out.c (output_function): Fix CFG loop state before
16465 * omp-expand.c (expand_oacc_for): Handle calls to internal
16466 functions like regular functions.
16468 2018-04-12 Richard Biener <rguenther@suse.de>
16471 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
16472 for the early LTO debug to properly generate references to it
16473 during DIE emission. Do not re-use that for the skeleton for
16475 (dwarf2out_early_finish): Likewise.
16477 2018-04-12 Jakub Jelinek <jakub@redhat.com>
16480 * config/i386/sse.md
16481 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
16482 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
16483 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
16484 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
16485 and output is a reg, avoid creating invalid lowpart subreg, but
16486 instead split into a 512-bit move. Don't split if not AVX512VL,
16487 input is xmm16+ reg and output is a mem.
16488 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
16489 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
16490 xmm16+ reg and output is a mem.
16492 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
16494 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
16495 also for flag_dwarf2_cfi_asm.
16497 2018-04-12 Jakub Jelinek <jakub@redhat.com>
16499 PR rtl-optimization/85342
16500 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
16501 a bool scalar var inside of the loop instead. Don't try to update
16502 recog_data.operand after failed apply_change_group.
16504 2018-04-12 Tom de Vries <tom@codesourcery.com>
16507 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
16508 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
16509 array with flexible array member as array without given dimension.
16510 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
16511 argument for undefined param to true.
16513 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
16516 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
16517 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
16518 from PowerPC section.
16519 * config/rs6000/sysv4.opt (mcall-): Improve help text.
16520 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
16521 help text that is too long.
16522 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
16523 help text that is too long.
16524 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
16525 help text that is too long.
16527 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
16529 * config/alpha/alpha.md (stack_probe_internal): Rename
16530 from "probe_stack". Update all callers.
16532 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
16534 PR rtl-optimization/84566
16535 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
16536 sched_macro_fuse_insns.
16538 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
16541 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
16542 (compute_block_dependences): ... from here.
16544 2018-04-11 Jakub Jelinek <jakub@redhat.com>
16546 PR tree-optimization/85331
16547 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
16548 from int to HOST_WIDE_INT.
16550 2018-04-11 Martin Jambor <mjambor@suse.cz>
16553 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
16554 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
16555 not the same as the source val.
16556 (cgraph_edge_brings_value_p): New parameter.
16557 (gather_edges_for_value): Pass destination value to
16558 cgraph_edge_brings_value_p.
16559 (perhaps_add_new_callers): Likewise.
16560 (get_info_about_necessary_edges): Likewise and exclude values brought
16561 only by self-recursive edges.
16562 (create_specialized_node): Redirect only clones of self-calling edges.
16563 (+self_recursive_pass_through_p): New function.
16564 (find_more_scalar_values_for_callers_subset): Use it.
16565 (find_aggregate_values_for_callers_subset): Likewise.
16566 (known_aggs_to_agg_replacement_list): Removed.
16567 (decide_whether_version_node): Re-calculate known constants for all
16568 remaining context clones.
16570 2018-04-11 Richard Biener <rguenther@suse.de>
16573 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
16574 from early DWARF output.
16575 (dwarf2out_early_finish): Output line info unconditionally into
16576 early DWARF and add reference to it.
16578 2018-04-11 Jakub Jelinek <jakub@redhat.com>
16581 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
16582 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
16583 other than V2DFmode using iptr mode attribute.
16584 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
16586 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
16588 PR rtl-optimization/84659
16589 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
16591 2018-04-11 Jakub Jelinek <jakub@redhat.com>
16594 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
16596 (output_loc_list): Pass address of a dummy size variable even in the
16597 locview handling loop.
16598 (index_location_lists): Add comment on why skip_loc_list_entry can't
16601 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
16604 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
16607 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
16610 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
16611 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
16612 and -mstring-compare-inline-limit.
16614 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
16617 * config/rs6000/rs6000.md (allocate_stack): Put the residual size
16618 for stack clash protection in a register whenever we need it to be in
16621 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
16623 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
16624 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
16626 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
16629 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
16631 (mlong-double-): Ditto.
16632 * config/rs6000/sysv4.opt (msdata=): Ditto.
16633 (mtls-size=): Ditto.
16635 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
16637 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
16638 erroneous entries for
16639 "vector int vec_ldl (int, long int *)", and
16640 "vector unsigned int vec_ldl (int, unsigned long int *)".
16641 Add comments and entries for
16642 "vector bool char vec_ldl (int, bool char *)",
16643 "vector bool short vec_ldl (int, bool short *)",
16644 "vector bool int vec_ldl (int, bool int *)",
16645 "vector bool long long vec_ldl (int, bool long long *)",
16646 "vector pixel vec_ldl (int, pixel *)",
16647 "vector long long vec_ldl (int, long long *)",
16648 "vector unsigned long long vec_ldl (int, unsigned long long *)".
16649 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
16650 type tree bool_long_long_type_node and correct definition of
16651 bool_V2DI_type_node to make reference to this new type tree.
16652 (rs6000_mangle_type): Replace erroneous reference to
16653 bool_long_type_node with bool_long_long_type_node.
16654 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
16655 comments to emphasize sign distinctions for char and int types and
16656 replace RS6000_BTI_bool_long constant with
16657 RS6000_BTI_bool_long_long constant. Also add comment to restrict
16658 use of RS6000_BTI_pixel.
16659 (bool_long_type_node): Remove this macro definition.
16660 (bool_long_long_type_node): New macro definition
16662 2018-04-10 Jakub Jelinek <jakub@redhat.com>
16664 PR rtl-optimization/85300
16665 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
16666 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
16667 simplify_unary_operation fails.
16669 2018-04-10 Martin Liska <mliska@suse.cz>
16671 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
16672 cgraph_edge and ipa_ref.
16674 2018-04-10 Jakub Jelinek <jakub@redhat.com>
16678 * config/i386/sse.md
16679 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
16680 computation of the VEC_MERGE selector from mask.
16681 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
16682 Fix decoding of the VEC_MERGE selector into mask.
16684 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
16686 PR tree-optimization/85286
16687 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
16689 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
16691 * final.c (final_1): Set insn_last_address as well as
16692 insn_current_address.
16694 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16697 * explow.c (emit_stack_probe): Call validize_mem on memory location
16698 before passing it to gen_probe_stack. Create address operand and
16699 legitimize it for the probe_stack_address case.
16701 2018-04-09 Jan Hubicka <jh@suse.cz>
16704 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
16705 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
16706 * tree.c (free_lang_data_in_type): Fix handling of binfos;
16708 (free_lang_data): Rebuild type inheritance graph.
16710 2018-04-09 Martin Sebor <msebor@redhat.com>
16712 * invoke.texi (-finline-small-functions): Mention other optimization
16714 (-findirect-inlining, -fpartial-inlining): Same.
16715 (-finline-functions-called-once): Same.
16716 (-freorder-blocks-and-partition): Same.
16718 2018-04-09 Jan Hubicka <jh@suse.cz>
16721 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
16722 jumps; choose last target that matches the criteria (i.e.
16723 no partition changes for non-crossing jumps).
16724 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
16725 support for redirecting crossing jumps to non-crossing.
16727 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
16729 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
16730 also for naked functions.
16732 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
16734 * config/arc/arc.md (add_shift): New pattern.
16735 (add_shift2): Likewise.
16736 (sub_shift): Likewise.
16737 (sub_shift_cmp0_noout): Likewise.
16738 (compare_si_ashiftsi): Likewise.
16739 (xbfu_cmp0_noout): New combine pattern.
16740 (xbfu_cmp0"): Likewise.
16741 (movsi_set_cc_insn): Place the predicable variant first.
16742 (commutative_binary_cmp0_noout): Remove clobber.
16743 (commutative_binary_cmp0): New pattern.
16744 (noncommutative_binary_cmp0): Likewise.
16745 (noncommutative_binary_cmp0_noout): Likewise.
16746 (noncommutative_binary_comparison_result_used): Removed.
16747 (rsub_cmp0): New pattern.
16748 (rsub_cmp0_noout): Likewise.
16749 (extzvsi): Changed, keep only meaningful variants.
16750 (SQH, SEZ): New iterators.
16751 (SQH_postfix): New mode attribute.
16752 (SEZ_prefix): New code attribute.
16753 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
16754 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
16755 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
16756 of numerical value.
16757 (noncommutative_operator): Check the availability of barrel
16760 2018-04-09 Richard Biener <rguenther@suse.de>
16762 PR tree-optimization/85284
16763 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
16764 Only use the niter constraining form of simple_iv when the exit
16765 is always executed.
16767 2018-04-09 Tom de Vries <tom@codesourcery.com>
16770 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
16771 (define_expand "*memory_barrier"): New define_expand.
16772 (define_insn "memory_barrier"): New insn.
16774 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
16776 PR rtl-optimization/80463
16777 PR rtl-optimization/83972
16778 PR rtl-optimization/83480
16780 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
16781 correct producer for the insn.
16782 (tidy_control_flow): Fixup seqnos in case of debug insns.
16784 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
16786 PR rtl-optimization/83913
16788 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
16789 different sched-times when merging exprs.
16791 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
16793 PR rtl-optimization/83962
16795 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
16796 tidy_fallthru_edge and tidy_control_flow.
16798 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
16800 PR rtl-optimization/83530
16802 * sel-sched.c (force_next_insn): New global variable.
16803 (remove_insn_for_debug): When force_next_insn is true, also leave only
16804 next insn in the ready list.
16805 (sel_sched_region): When the region wasn't scheduled, make another pass
16806 over it with force_next_insn set to 1.
16808 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
16810 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
16812 * config/nds32/constants.md (unspec_volatile_element): Add enum values
16813 for interrupt control.
16814 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
16815 functions for interrupt control.
16816 * config/nds32/nds32-intrinsic.md: Likewise.
16817 * config/nds32/nds32_intrinsic.h: Likewise.
16818 * config/nds32/nds32.h (nds32_builtins): Likewise.
16820 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
16822 * config/nds32/nds32.c (nds32_init_machine_status,
16823 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
16824 strict_aligned_p field.
16825 (nds32_expand_to_rtl_hook): New function.
16826 (TARGET_EXPAND_TO_RTL_HOOK): Define.
16827 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
16829 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
16830 Chung-Ju Wu <jasonwucj@gmail.com>
16832 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
16833 * config/nds32/nds32-n7.md: New file.
16834 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
16835 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
16837 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
16838 * config/nds32/nds32.md (pipeline_model): Add n7.
16839 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
16840 * config/nds32/pipelines.md: Include n7 settings.
16842 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
16843 Chung-Ju Wu <jasonwucj@gmail.com>
16845 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
16846 * config/nds32/nds32-e8.md: New file.
16847 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
16848 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
16850 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
16851 * config/nds32/nds32.md (pipeline_model): Add e8.
16852 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
16853 * config/nds32/pipelines.md: Include e8 settings.
16855 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
16856 Chung-Ju Wu <jasonwucj@gmail.com>
16858 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
16859 * config/nds32/nds32-n8.md: New file.
16860 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
16861 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
16863 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
16864 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
16865 * config/nds32/nds32.md (pipeline_model): Add n8.
16866 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
16867 * config/nds32/pipelines.md: Include n8 settings.
16869 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
16870 Chung-Ju Wu <jasonwucj@gmail.com>
16872 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
16873 * config/nds32/nds32-n9-2r1w.md: New file.
16874 * config/nds32/nds32-n9-3r2w.md: New file.
16875 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
16876 nds32_register_ports): New or modify for cpu n9.
16877 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
16879 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
16880 * config/nds32/nds32-utils.c: New file.
16881 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
16882 TARGET_MUL_SLOW): Define.
16883 * config/nds32/nds32.md (pipeline_model): New attribute.
16884 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
16885 New options that support cpu n9.
16886 * config/nds32/pipelines.md: Include n9 settings.
16887 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
16889 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
16891 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
16892 information if necessary.
16893 (output_cond_branch_compare_zero): Likewise.
16894 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
16895 (nds32_target_alignment): Refine for alignment.
16896 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
16897 (FUNCTION_BOUNDARY): Modify.
16898 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
16900 * config/nds32/nds32.opt (malways-align, malign-functions): New.
16902 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
16904 * config/nds32/constants.md (unspec_volatile_element): Add values for
16905 TLB operation and data prefetch.
16906 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
16907 functions for TLB operation and data prefetch.
16908 * config/nds32/nds32-intrinsic.md: Likewise.
16909 * config/nds32/nds32_intrinsic.h: Likewise.
16910 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
16911 (nds32_print_operand): Likewise.
16912 * config/nds32/nds32.h (nds32_builtins): Likewise.
16914 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
16915 Andrew Pinski <pinsika@gcc.gnu.org>
16917 PR middle-end/82976
16918 * match.pd: Use constant_boolean_node of correct type instead of
16919 boolean_true_node or boolean_false_node for simplifying
16920 pointer comparisons to zero.
16922 2018-04-07 Jakub Jelinek <jakub@redhat.com>
16924 PR tree-optimization/80021
16925 * tree.c (verify_type_variant): Make error call in verify_variant_match
16926 translatable and remove final full stop.
16928 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
16930 * config/nds32/constants.md (unspec_volatile_element): Add
16931 UNSPEC_VOLATILE_EH_RETURN.
16932 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
16933 nds32_output_stack_pop): Support dwarf exception handling process.
16934 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
16935 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
16936 exception handling process.
16937 (nds32_compute_stack_frame): Likewise.
16938 (nds32_return_addr_rtx): Likewise.
16939 (nds32_initial_elimination_offset): Likewise.
16940 (nds32_expand_prologue): Likewise.
16941 (nds32_expand_epilogue): Likewise.
16942 (nds32_dynamic_chain_address): New function.
16943 * config/nds32/nds32.h (machine_function): Add fields for dwarf
16944 exception handling.
16945 (DYNAMIC_CHAIN_ADDRESS): Define.
16946 (EH_RETURN_DATA_REGNO): Define.
16947 (EH_RETURN_STACKADJ_RTX): Define.
16948 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
16949 patterns for dwarf exception handling.
16951 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
16953 * config/nds32/nds32.h: Clean up obsolete macros.
16955 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
16957 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
16958 Add enum values for particular instructions.
16959 * config/nds32/nds32-intrinsic.c: Implementation of expanding
16960 particular intrinsic functions.
16961 * config/nds32/nds32-intrinsic.md: Likewise.
16962 * config/nds32/nds32_intrinsic.h: Likewise.
16963 * config/nds32/nds32.h (nds32_builtins): Likewise.
16964 * config/nds32/nds32.md (type): Add pbsad and pbsada.
16965 (btst, ave): New patterns for particular instructions.
16967 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
16969 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
16970 Add enum values for atomic load/store and memory sync.
16971 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
16973 * config/nds32/nds32-intrinsic.md: Likewise.
16974 * config/nds32/nds32_intrinsic.h: Likewise.
16975 * config/nds32/nds32.h (nds32_builtins): Likewise.
16977 2018-04-07 Jakub Jelinek <jakub@redhat.com>
16979 PR tree-optimization/85257
16980 * fold-const.c (native_encode_vector): If not all elts could fit
16981 and off is -1, return 0 rather than offset.
16982 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
16983 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
16984 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
16985 adjust buffer in native_interpret_expr call.
16987 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
16989 * config/nds32/constants.md (unspec_volatile_element): Add cache
16990 control enum values.
16991 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
16992 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
16993 * config/nds32/nds32.c (nds32_cctl_names): New.
16994 (nds32_print_operand): Handle cache control register names.
16995 * config/nds32/nds32.h (nds32_builtins): New enum values.
16996 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
16998 * config/nds32/nds32.md (type): Add mmu.
16999 * config/nds32/pipelines.md (simple_insn): Add mmu.
17001 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
17003 * config/nds32/nds32.md (type): Remove call.
17004 * config/nds32/pipelines.md (simple_insn): Likewise.
17006 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
17008 * config/nds32/constants.md (unspec_volatile_element): Add
17009 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
17010 UNSPEC_VOLATILE_FMFCFG.
17011 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
17012 description for fmfcfg and fmfcsr.
17013 (bdesc_1arg): Add fmtcsr.
17014 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
17015 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
17016 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
17017 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
17018 unspec_fmfcfg): New patterns.
17019 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
17020 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
17021 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
17022 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
17023 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
17024 __nds32__fmfcfg): Define.
17026 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
17028 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
17029 intrinsic register names.
17030 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
17031 intrinsic register enum values and macros.
17033 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
17035 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
17036 for load/store addressing form.
17037 (nds32_print_operand_address): Likewise.
17039 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
17042 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
17043 based on LABEL_REF. Remove useless assertion.
17044 (pic_address_needs_scratch): Fix formatting.
17045 (sparc_legitimize_pic_address): Minor tweaks.
17046 (sparc_delegitimize_address): Adjust assertion accordingly.
17047 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
17048 into symbolic_operand.
17049 (movsi_high_pic_label_ref): Likewise.
17050 (movsi_lo_sum_pic_label_ref): Likewise.
17051 (movdi_pic_label_ref): Likewise.
17052 (movdi_high_pic_label_ref): Likewise.
17053 (movdi_lo_sum_pic_label_ref): Likewise.
17055 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
17057 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
17058 custom LIB_SPEC setup.
17060 2018-04-06 Ruslan Bukin <br@bsdpad.com>
17061 Kito Cheng <kito.cheng@gmail.com>
17063 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
17064 * config/riscv/freebsd.h: New.
17066 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
17068 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
17069 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
17072 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
17073 Kito Cheng <kito.cheng@gmail.com>
17075 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
17076 nds32_output_call, nds32_symbol_binds_local_p): New functions.
17077 * config/nds32/nds32-protos.h (nds32_output_call,
17078 nds32_output_return): Declare.
17079 * config/nds32/nds32.md: Refine all the call and return patterns.
17081 2018-04-06 Jakub Jelinek <jakub@redhat.com>
17084 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
17085 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
17087 PR rtl-optimization/84872
17088 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
17089 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
17090 EDGE_CROSSING edge.
17092 2018-04-06 Tamar Christina <tamar.christina@arm.com>
17094 * expr.c (copy_blkmode_to_reg): Revert 254862.
17095 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
17097 2018-04-06 Richard Biener <rguenther@suse.de>
17099 PR middle-end/85244
17100 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
17101 after seeing a component reference with an adjacent field. Treat
17102 refs to arrays at struct end of external decls similar to
17103 refs to unconstrained commons.
17105 2018-04-06 Jakub Jelinek <jakub@redhat.com>
17108 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
17109 look through SAVE_EXPRs with non-side-effects argument. Adjust
17111 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
17114 2018-04-06 Richard Biener <rguenther@suse.de>
17116 PR middle-end/85180
17117 * alias.c (find_base_term): New wrapper around find_base_term
17118 unwinding CSELIB_VAL_PTR changes.
17119 (find_base_term): Do not restore CSELIB_VAL_PTR during the
17122 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
17124 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
17126 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
17127 constant definitions.
17128 ("nop"): lr 0,0 -> nopr r0
17129 ("nop_lr0", "nop_lr1"): New insn definitions.
17131 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
17133 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
17134 NDS32_V3PUSH_AVAILABLE_P macro.
17136 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
17137 Chung-Ju Wu <jasonwucj@gmail.com>
17139 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
17140 (nds32*-*-*): Add float and fpu_config into supported_defaults.
17141 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
17142 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
17143 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
17144 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
17145 * config/nds32/constraints.md: New constraints and checking for hard
17146 float configuration.
17147 * config/nds32/iterators.md: New mode iterator and attribute for hard
17148 float configuration.
17149 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
17151 * config/nds32/nds32-fpu.md: New file.
17152 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
17153 deal with hard float code generation.
17154 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
17156 (abi_type, float_reg_number): New enum type.
17157 * config/nds32/nds32-predicates.c: New predicates for hard float.
17158 * config/nds32/nds32-protos.h: Declare functions for hard float.
17159 * config/nds32/nds32.c: Implementation for hard float configuration.
17160 * config/nds32/nds32.h: Definitions for hard float configuration.
17161 * config/nds32/nds32.md: Include hard float machine description and
17162 modify patterns for hard float configuration.
17163 * config/nds32/nds32.opt: New options for hard float configuration.
17164 * config/nds32/predicates.md: New predicates for hard float
17167 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
17169 * common/config/nds32/nds32-common.c
17170 (nds32_option_optimization_table): Enable -mreleax-hint by default.
17172 2018-04-05 Jakub Jelinek <jakub@redhat.com>
17174 PR middle-end/85195
17175 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
17176 CONSTRUCTOR_ELT (ctor, ...)->value.
17178 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
17181 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
17183 2018-04-05 Tom de Vries <tom@codesourcery.com>
17186 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
17189 2018-04-05 Shiva Chen <shiva0217@gmail.com>
17190 Kito Cheng <kito.cheng@gmail.com>
17192 * config/nds32/constraints.md (U33): Fine-tune checking condition.
17193 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
17194 * config/nds32/nds32.h (nds32_16bit_address_type): Add
17195 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
17197 2018-04-05 Shiva Chen <shiva0217@gmail.com>
17198 Kito Cheng <kito.cheng@gmail.com>
17200 * config/nds32/constraints.md (Ufe): New memory constraint.
17201 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
17202 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
17203 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
17205 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
17206 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
17208 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
17210 * config/nds32/nds32.md: Use optimize_size in the condition for
17211 alu-shift instructions.
17213 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
17215 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
17217 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
17219 * config/nds32/nds32.md (negsi2): Refine pattern.
17221 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
17222 Chung-Ju Wu <jasonwucj@gmail.com>
17224 * config/nds32/iterators.md (shift_rotate): New code iterator.
17225 (shift): New code attribute.
17226 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
17227 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
17228 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
17229 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
17230 bit-wise operations.
17231 (andsi3, *andsi3): Ditto.
17232 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
17233 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
17234 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
17235 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
17236 nds32_ior_operand, nds32_xor_operand): New predicates.
17238 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
17240 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
17241 (addsi3, subsi3): ... this.
17243 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
17245 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
17247 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
17249 * config/nds32/nds32.md: Adjust indention.
17251 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
17253 * config/nds32/nds32.md (feature): New attribute.
17255 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
17257 * config/nds32/nds32.md (subtype): New attribute.
17259 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
17262 * config/arm/arm-builtins.c (arm_expand_builtin): Change
17263 expansion to perform a bitwise AND of the argument followed by a
17264 boolean negation of the result.
17266 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
17268 PR rtl-optimization/84878
17269 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
17270 the basic block. Assert the use reference is not artificial and that
17271 it has an associated insn.
17273 2018-04-04 Michael Matz <matz@suse.de>
17275 * builtins.c (compute_objsize): Pass correct operand
17276 to array_at_struct_end_p.
17278 2018-04-04 Richard Biener <rguenther@suse.de>
17281 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
17282 from contexts for DINFO_LEVEL_TERSE and below.
17284 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
17286 * config/nds32/nds32-doubleword.md (move_<mode>): Require
17287 resiter_operand condition.
17288 * config/nds32/nds32.md (*move<mode>): Ditto.
17290 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
17291 Monk Chiang <sh.chiang04@gmail.com>
17293 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
17295 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
17297 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
17299 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
17300 Kito Cheng <kito.cheng@gmail.com>
17302 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
17303 nds32_cond_code_str, output_cond_branch,
17304 output_cond_branch_compare_zero, nds32_expand_cbranch,
17305 nds32_expand_cstore, nds32_expand_movcc,
17306 nds32_output_cbranchsi4_equality_zero,
17307 nds32_output_cbranchsi4_equality_reg,
17308 nds32_output_cbranchsi4_equality_reg_or_const_int,
17309 nds32_output_cbranchsi4_greater_less_zero: New functions.
17310 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
17311 nds32_expand_cstore, nds32_expand_movcc,
17312 nds32_output_cbranchsi4_equality_zero,
17313 nds32_output_cbranchsi4_equality_reg,
17314 nds32_output_cbranchsi4_equality_reg_or_const_int,
17315 nds32_output_cbranchsi4_greater_less_zero): Declare.
17316 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
17317 nds32_rimm11s_operand): New predicates.
17318 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
17319 * config/nds32/nds32.md: Rewrite all the branch and conditional move
17322 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
17324 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
17325 * config/nds32/nds32.md: Ditto.
17326 * config/nds32/pipelines.md: Ditto.
17328 2018-04-04 Richard Biener <rguenther@suse.de>
17330 PR tree-optimization/85168
17331 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
17332 propagating abnormals.
17334 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
17336 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
17338 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
17339 Kito Cheng <kito.cheng@gmail.com>
17341 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
17342 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
17343 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
17344 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
17345 * config/nds32/nds32.md (sibcall_internal): New.
17346 (sibcall_register): Remove.
17347 (sibcall_immediate): Remove.
17348 (sibcall_value_internal): New.
17349 (sibcall_value_register): Remove.
17350 (sibcall_value_immediate): Remove.
17351 * config/nds32/predicates.md (nds32_general_register_operand): New.
17352 (nds32_call_address_operand): New.
17354 2018-04-03 Jakub Jelinek <jakub@redhat.com>
17356 PR rtl-optimization/85167
17357 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
17358 bb_defs if *split_p, instead preinitialize it to NULL.
17360 PR tree-optimization/85156
17361 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
17362 evaluating the argument multiple times.
17364 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
17366 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
17368 (_mm_cvtpd_ps): Likewise.
17369 (_mm_cvttpd_epi32): Likewise.
17370 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
17371 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
17372 vector, pixel, and bool following altivec.h include.
17374 2018-04-03 Martin Sebor <msebor@redhat.com>
17376 * doc/extend.texi (Common Function Attributes): Clarify.
17377 (const attribute): Likewise.
17378 (pure attribute): Likewise.
17380 2018-04-03 Jakub Jelinek <jakub@redhat.com>
17383 * config/i386/i386.c (ix86_expand_vector_set): Use
17384 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
17386 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
17388 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
17389 instructions when changing rounding bits to preserve precision bits
17390 in the x87 control word.
17392 2018-04-03 Martin Liska <mliska@suse.cz>
17394 PR tree-optimization/82491
17395 * rtl.h (strip_offset_and_add): Replace += suboffset with
17396 poly_uint64 () + suboffset.
17398 2018-03-29 Martin Liska <mliska@suse.cz>
17399 Martin Jambor <mjambor@suse.cz>
17402 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
17403 param_type is not an integral or pointer type.
17405 2018-04-03 Richard Biener <rguenther@suse.de>
17407 * sese.h (recompute_all_dominators): Remove.
17409 2018-04-02 Martin Sebor <msebor@redhat.com>
17411 * doc/invoke.texi (-Wrestrict): Fix typos.
17413 2018-04-02 Jim Wilson <jimw@sifive.com>
17415 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
17416 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
17417 (<optab>di3, <optab>si3_extend): Likewise.
17418 (<optab>si3_mask, <optab>si3_mask_1): New.
17419 (<optab>di3_mask, <optab>di3_mask_1): New.
17420 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
17421 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
17422 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
17424 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
17426 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
17429 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
17431 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
17432 (nds32_canonicalize_comparison): New function.
17434 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
17435 Kito Cheng <kito.cheng@gmail.com>
17436 Kuan-Lin Chen <kuanlinchentw@gmail.com>
17438 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
17439 * config/nds32/constants.md (unspec_volatile_element): Add
17440 UNSPEC_VOLATILE_RELAX_GROUP.
17441 * config/nds32/nds32-relax-opt.c: New file.
17442 * config/nds32/nds32-predicates.c
17443 (nds32_symbol_load_store_p): New function.
17444 * config/nds32/nds32-protos.h
17445 (nds32_symbol_load_store_p): Declare function.
17446 (make_pass_nds32_relax_opt): Declare new rtl pass function.
17447 * config/nds32/nds32.c
17448 (nds32_register_pass): New function to register pass.
17449 (nds32_register_passes): New function to register passes.
17450 * config/nds32/nds32.md (relax_group): New pattern.
17451 * config/nds32/nds32.opt (mrelax-hint): New option.
17452 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
17454 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
17456 * config/nds32/t-nds32: Modify files dependency.
17458 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
17460 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
17461 (PROFILE_HOOK): Define its implementation.
17463 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
17465 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
17466 type and 32-bit size.
17468 2018-04-01 Jakub Jelinek <jakub@redhat.com>
17470 PR middle-end/85090
17471 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
17472 (V_128_256): New mode iterator.
17473 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
17474 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
17475 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
17477 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
17478 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
17480 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
17483 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
17484 NaN inputs correctly.
17486 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
17489 * config/rs6000/vsx.md (??r): New mode attribute.
17490 (*vsx_mov<mode>_64bit): Use it.
17491 (*vsx_mov<mode>_32bit): Likewise.
17493 2018-03-30 Martin Sebor <msebor@redhat.com>
17495 PR tree-optimization/84818
17496 * builtins.c (check_access): Use warning_n.
17498 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
17501 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
17503 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
17506 2018-03-30 Julia Koval <julia.koval@intel.com>
17509 * x86-tune.def (movx, partial_reg_dependency): Enable for
17512 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
17514 PR inline-asm/84985
17515 * lra-constraints.c (process_alt_operands): Move setting
17516 this_alternative_matches below.
17518 2018-03-29 Martin Liska <mliska@suse.cz>
17521 * doc/invoke.texi: Document how LTO works with debug info.
17522 Describe auto-load support of binutils. Mention 'x86-64'
17523 as valid option value of -march option.
17525 2018-03-29 Jakub Jelinek <jakub@redhat.com>
17527 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
17530 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
17531 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
17532 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
17535 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
17538 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
17539 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
17540 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
17541 for RS6000_BTM_POWERPC64.
17542 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
17543 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
17544 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
17547 (DIVDEU): Likewise.
17549 2018-03-28 Carl Love <cel@us.ibm.com>
17552 2017-09-27 Carl Love <cel@us.ibm.com>
17554 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
17555 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
17556 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
17559 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
17561 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
17562 instead of __vector bool.
17563 (_mm_max_pu8): Likewise.
17564 (_mm_min_pi16): Likewise.
17566 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
17569 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
17570 (DIVWEUO): Likewise.
17571 (DIVDEO): Likewise.
17572 (DIVDEUO): Likewise.
17573 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
17574 DIVWEUO and DIVDEUO.
17575 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
17576 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
17577 (div_extend): Likewise.
17578 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
17580 (__builtin_divweuo): Likewise.
17581 (__builtin_divdeo): Likewise.
17582 (__builtin_divdeuo): Likewise.
17584 2018-03-28 Jakub Jelinek <jakub@redhat.com>
17587 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
17588 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
17590 PR tree-optimization/82004
17591 * gimple-match-head.c (optimize_pow_to_exp): New function.
17592 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
17593 Don't fold to exp if optimize_pow_to_exp is false.
17595 2018-03-28 Martin Liska <mliska@suse.cz>
17598 * calls.c (initialize_argument_information): Fix trailing space.
17599 * common.opt: Fix typo and provide better explanation for
17600 -fsanitize-coverage option.
17601 * config/i386/i386.opt: Fix typo.
17603 2018-03-28 Jakub Jelinek <jakub@redhat.com>
17604 Martin Liska <mliska@suse.cz>
17607 * gimplify.c (asan_poison_variable): Don't do the check for
17608 gimplify_omp_ctxp here.
17609 (gimplify_decl_expr): Do it here.
17610 (gimplify_target_expr): Likewise.
17612 2018-03-28 Martin Liska <mliska@suse.cz>
17615 * config/i386/i386.c (ix86_function_arg_advance): Do not call
17616 chkp_type_bounds_count if MPX is not enabled.
17618 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
17620 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
17622 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
17625 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
17626 function to create the function decl for complex long double
17627 multiply and divide for -mabi=ieeelongdouble.
17628 (init_float128_ieee): Call it.
17630 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
17633 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
17634 -fcf-protection=branch -mibt.
17635 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
17637 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
17640 * config/arm/arm.c (arm_valid_symbolic_address): Handle
17641 arm_word_relocations.
17643 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
17646 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
17647 extern array declarations.
17649 2018-03-27 Richard Biener <rguenther@suse.de>
17651 PR middle-end/84067
17652 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
17653 explicit single_use checks.
17655 2018-03-27 Richard Biener <rguenther@suse.de>
17657 PR tree-optimization/85082
17658 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
17661 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
17663 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
17664 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
17665 Turn on fasynchronous-unwind-tables and funwind-tables.
17667 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
17670 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
17671 (*bmi_blsr_<mode>_ccz): Ditto.
17673 2018-03-26 Tom de Vries <tom@codesourcery.com>
17675 PR tree-optimization/85063
17676 * omp-general.c (offloading_function_p): New function. Factor out
17678 * omp-offload.c (pass_omp_target_link::gate): ... here.
17679 * omp-general.h (offloading_function_p): Declare.
17680 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
17681 with attribute omp declare target for offloading functions.
17683 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
17685 PR tree-optimization/84005
17686 * tree-data-ref.h (get_base_for_alignment): Declare.
17687 * tree-data-ref.c (get_base_for_alignment_1): New function.
17688 (get_base_for_alignment): Likewise.
17689 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
17690 get_base_for_alignment to find a suitable base object, instead
17691 of always using drb->base_address.
17693 2018-03-23 Jakub Jelinek <jakub@redhat.com>
17695 PR inline-asm/85022
17696 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
17697 known size by default.
17699 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
17701 PR inline-asm/85030
17702 * lra-constraints.c (process_alt_operands): Don't match BLKmode
17703 and non BLKmode operands.
17705 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17708 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
17709 Clean up attributes.
17711 2018-03-23 Richard Biener <rguenther@suse.de>
17714 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
17715 we are going to emit early debug for LTO.
17717 2018-03-23 Jakub Jelinek <jakub@redhat.com>
17719 PR inline-asm/85034
17720 * function.c (match_asm_constraints_1): Don't optimize if input
17721 doesn't satisfy general_operand predicate for output's mode.
17723 PR inline-asm/85022
17724 * alias.c (write_dependence_p): Don't require for x_canonicalized
17725 non-VOIDmode if x has VOIDmode.
17728 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
17729 just don't try to optimize it rather than assert it never happens.
17731 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
17733 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
17734 macro expansions for definition of ST_INTERNAL_<mode> and
17735 LD_INTERNAL_<mode> builtins.
17736 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
17738 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
17740 (altivec_expand_st_builtin): Likewise.
17741 (altivec_expand_builtin): Remove calls to deleted functions.
17742 (rs6000_address_for_altivec): Delete this function.
17743 * config/rs6000/vector.md: Remove expands for
17744 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
17746 2018-03-22 Sudakshina Das <sudi.das@arm.com>
17749 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
17750 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
17751 re-computing once computed.
17752 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
17753 (arm_init_machine_status): Initialize
17754 machine->static_chain_stack_bytes.
17756 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
17759 * doc/extend.texi: Add four new prototypes for vec_ld.
17760 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
17761 definitions for more logical presentation.
17762 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
17763 entries for V1TI variants of __builtin_altivec_ld builtin.
17764 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
17765 handling of V1TI variant of LVX icode pattern.
17766 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
17767 (rs6000_gimple_fold_builtin): Likewise.
17768 (altivec_init_builtins): Add code to define
17769 __builtin_altivec_lvx_v1ti function.
17771 2018-03-22 Jakub Jelinek <jakub@redhat.com>
17773 PR inline-asm/84941
17774 * function.c (match_asm_constraints_1): Don't do the optimization
17775 if input isn't a REG, SUBREG, MEM or constant.
17777 2018-03-22 Tom de Vries <tom@codesourcery.com>
17779 PR tree-optimization/84956
17780 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
17781 bb_has_abnormal_pred.
17783 2018-03-22 Jakub Jelinek <jakub@redhat.com>
17786 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
17787 DECL_INITIAL (decl) to decl at the end.
17788 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
17789 adjust the comment.
17791 2018-03-21 Joseph Myers <joseph@codesourcery.com>
17793 * doc/extend.texi (__builtin_tgmath): Document when complex
17794 integer types are treated as _Complex _Float64.
17796 2018-03-21 Tom de Vries <tom@codesourcery.com>
17798 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
17800 2018-03-21 Jakub Jelinek <jakub@redhat.com>
17802 PR tree-optimization/84960
17803 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
17804 if it is ENTRY block, move them into single succ of ENTRY in that case.
17806 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
17808 PR tree-optimization/84811
17809 * poly-int.h (poly_span_traits): Remove the T3 parameter and
17810 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
17811 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
17812 (known_subrange_p): Update accordingly. Cast each value involved
17813 in the size comparison, rather than casting the result of the
17816 2018-03-21 Jakub Jelinek <jakub@redhat.com>
17818 PR tree-optimization/84982
17819 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
17820 by flipping the least significant bit rather than all bits from
17821 bitpos to bitpos + bitsize - 1.
17823 2018-03-21 Nathan Sidwell <nathan@acm.org>
17825 * doc/extend.texi (Deprecated Features): Remove mention of
17826 long-deleted deprecations.
17828 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
17831 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
17832 * configure: Regenerate.
17834 2018-03-21 Tom de Vries <tom@codesourcery.com>
17836 PR tree-optimization/83126
17837 * tree-parloops.c (num_phis): New function.
17838 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
17840 2018-03-21 Nathan Sidwell <nathan@acm.org>
17842 * doc/extend.texi (Deprecated Features): Update deprecated flags,
17843 mention anon-struct/union members and trailing attributes.
17845 2018-03-21 Bin Cheng <bin.cheng@arm.com>
17847 PR tree-optimization/84969
17848 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
17849 builtin memset partitions if they set different rhs values.
17851 2018-03-21 Jakub Jelinek <jakub@redhat.com>
17853 PR rtl-optimization/84989
17854 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
17855 VEC_DUPLICATE with scalar result mode.
17857 2018-03-21 Martin Liska <mliska@suse.cz>
17860 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
17861 not intended return statement.
17863 2018-03-21 Martin Liska <mliska@suse.cz>
17866 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
17867 (chkp_find_bound_slots_1): Limit number of iterations.
17869 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
17872 * Minor grammar fixes for x86 options.
17874 2018-03-20 Jakub Jelinek <jakub@redhat.com>
17877 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
17878 holding REG_CFA_RESTORE notes, instead turn them into a USE.
17880 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
17883 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
17884 (altivec_lvx_<mode>_1op): Likewise.
17885 (altivec_stvx_<mode>_2op): Likewise.
17886 (altivec_stvx_<mode>_1op): Likewise.
17887 (altivec_lvx_<VM2:mode>): New define_expand.
17888 (altivec_stvx_<VM2:mode>): Likewise.
17889 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
17890 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
17891 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
17892 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
17893 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
17894 (rs6000_gen_lvx): Likewise.
17895 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
17896 (altivec_expand_stv_builtin): Likewise.
17897 (altivec_expand_builtin): Likewise.
17898 * config/rs6000/vector.md: Likewise.
17900 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17903 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
17906 2018-03-20 Richard Biener <rguenther@suse.de>
17909 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
17910 sign-conversions as zero, fall back to standard scalar_stmt
17913 2018-03-20 Martin Liska <mliska@suse.cz>
17916 * predict.c (rebuild_frequencies): Handle case when we have
17917 PROFILE_ABSENT, but flag_guess_branch_prob is false.
17919 2018-03-20 Jakub Jelinek <jakub@redhat.com>
17922 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
17923 flag_section_anchors.
17924 * varasm.c (use_blocks_for_decl_p): Remove hack for
17925 dw2_force_const_mem.
17928 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
17930 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
17931 be created, use lowpart_subreg of operands[0] rather than operands[0]
17933 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
17934 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
17935 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
17936 and n constraint instead of aarch64_shift_imm_di and Usd.
17937 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
17938 (*aarch64_<optab>_reg_minus<mode>3): ... this.
17940 2018-03-20 Sudakshina Das <sudi.das@arm.com>
17943 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
17944 to favor GPR over NEON registers.
17945 (<shift>di3_neon): Likewise.
17947 2018-03-20 Tom de Vries <tom@codesourcery.com>
17950 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
17951 (nvptx_process_pars): Emit bar.sync asap and alap.
17953 2018-03-20 Tom de Vries <tom@codesourcery.com>
17956 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
17957 seen_label if seen_label is already set.
17959 2018-03-20 Jakub Jelinek <jakub@redhat.com>
17962 * config/i386/i386.c (fold_builtin_cpu): For features above 31
17963 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
17964 Use 1U instead of 1. Formatting fixes.
17967 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
17968 instead of TREE_TYPE (s1) for the return value.
17970 2018-03-19 Jakub Jelinek <jakub@redhat.com>
17972 PR tree-optimization/84946
17973 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
17974 bitsize + bitsize in poly_uint64 rather than poly_int64.
17977 * dwarf2asm.c: Include fold-const.c.
17978 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
17979 of decl rather than decl itself.
17981 PR rtl-optimization/84643
17982 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
17984 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
17987 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
17988 calling assemble_variable.
17990 2018-03-19 Sudakshina Das <sudi.das@arm.com>
17993 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
17994 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
17996 2018-03-19 Jim Wilson <jimw@sifive.com>
17999 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
18000 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
18001 (riscv_first_stack_step): Likewise.
18002 (riscv_option_override): Use STACK_BOUNDARY instead of
18003 MIN_STACK_BOUNDARY.
18004 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
18005 MIN_STACK_BOUNDARY.
18006 (BIGGEST_ALIGNMENT): Set to 128.
18007 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
18008 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
18011 2018-03-19 Richard Biener <rguenther@suse.de>
18013 PR tree-optimization/84933
18014 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
18015 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
18017 2018-03-19 Richard Biener <rguenther@suse.de>
18019 PR tree-optimization/84859
18020 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
18021 (cond_if_else_store_replacement): Perform sinking operation on
18022 single-store BBs regardless of MAX_STORES_TO_SINK setting.
18023 Generalize what a BB with a single eligible store is.
18025 2018-03-19 Richard Biener <rguenther@suse.de>
18027 PR tree-optimization/84929
18028 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
18029 chrec_is_positive against non-chrec arg.
18031 2018-03-19 Tamar Christina <tamar.christina@arm.com>
18034 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
18036 2018-03-18 Martin Liska <mliska@suse.cz>
18038 PR rtl-optimization/84635
18039 * regrename.c (build_def_use): Use matches_mode only when
18042 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
18044 PR tree-optimization/84913
18045 * tree-vect-loop.c (vectorizable_reduction): Don't try to
18046 vectorize chains of COND_EXPRs.
18048 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
18050 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
18052 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
18054 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
18056 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
18058 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
18060 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
18061 Kito Cheng <kito.cheng@gmail.com>
18063 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
18064 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
18065 (nds32_adjust_reg_alloc_order): New function.
18066 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
18068 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
18070 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
18071 nds32_print_operand, nds32_print_operand_address): Use
18072 HOST_WIDE_INT_PRINT_DEC instead.
18074 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
18076 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
18078 2018-03-17 Jakub Jelinek <jakub@redhat.com>
18081 * config/i386/i386.c (initial_ix86_tune_features,
18082 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
18083 unsigned long long.
18084 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
18085 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
18086 rather than 1u << ix86_tune. Formatting fix.
18087 (ix86_option_override_internal): Change ix86_arch_mask from
18088 unsigned int to unsigned HOST_WIDE_INT, initialize to
18089 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
18090 (ix86_function_specific_restore): Likewise.
18092 2018-03-16 Jakub Jelinek <jakub@redhat.com>
18095 * postreload.c (reload_combine_recognize_pattern): Perform
18096 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
18097 truncate_int_for_mode the result for the destination's mode.
18100 * hsa-gen.c (mem_type_for_type): Fix comment typo.
18101 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
18103 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
18106 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
18109 * lra-assigns.c (lra_split_hard_reg_for): Don't use
18110 regno_allocno_class_array and sorted_pseudos.
18111 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
18112 insns where regno is used.
18114 2018-03-16 Martin Liska <mliska@suse.cz>
18117 * multiple_target.c (create_dispatcher_calls): Redirect
18118 reference in the symbol table.
18120 2018-03-16 Martin Liska <mliska@suse.cz>
18123 * multiple_target.c (create_dispatcher_calls): Redirect also
18126 2018-03-16 Jakub Jelinek <jakub@redhat.com>
18130 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
18131 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
18132 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
18134 2018-03-16 Julia Koval <julia.koval@intel.com>
18136 * doc/invoke.texi (Skylake Server): Add CLWB.
18137 Cannonlake): Remove CLWB.
18139 2018-03-16 Jakub Jelinek <jakub@redhat.com>
18141 PR tree-optimization/84841
18142 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
18144 (FLOAT_ONE_CONST_TYPE): Define.
18145 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
18146 (sort_by_operand_rank): Put entries with higher constant_type last
18147 rather than first to match comments.
18149 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
18151 * config/nios2/nios2.md (movsi_internal): Fix thinko in
18154 2018-03-15 Jakub Jelinek <jakub@redhat.com>
18157 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
18158 check and use address of target always.
18160 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
18163 * config/i386/i386.c (indirect_thunk_needed): Update comments.
18164 (indirect_thunk_bnd_needed): Likewise.
18165 (indirect_thunks_used): Likewise.
18166 (indirect_thunks_bnd_used): Likewise.
18167 (indirect_return_needed): New.
18168 (indirect_return_bnd_needed): Likewise.
18169 (output_indirect_thunk_function): Add a bool argument for
18171 (output_indirect_thunk_function): Don't generate alias for
18172 function return thunk.
18173 (ix86_code_end): Call output_indirect_thunk_function to generate
18174 function return thunks.
18175 (ix86_output_function_return): Set indirect_return_bnd_needed
18176 and indirect_return_needed instead of indirect_thunk_bnd_needed
18177 and indirect_thunk_needed.
18179 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
18181 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
18182 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
18183 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
18185 2018-03-15 David Malcolm <dmalcolm@redhat.com>
18186 Paul Hua <paul.hua.gm@gmail.com>
18189 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
18191 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
18193 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
18194 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
18195 resp. SFmode cases.
18197 2018-03-15 Tamar Christina <tamar.christina@arm.com>
18200 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
18201 instead of GET_MODE_SIZE when comparing Units.
18203 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
18206 * varasm.c (hash_section): Return an unchangeble hash value
18207 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
18208 Return !aarch64_can_use_per_function_literal_pools_p ().
18210 2018-03-15 Jakub Jelinek <jakub@redhat.com>
18213 * optabs.c (emit_conditional_move): Pass address of cmode's copy
18214 rather than address of cmode as last argument to prepare_cmp_insn.
18216 2018-03-15 Julia Koval <julia.koval@intel.com>
18218 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
18219 F_AVX512VNNI, F_AVX512BITALG): New.
18221 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
18224 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
18225 insn for floating-point loads and stores.
18227 2018-03-14 Carl Love <cel@us.ibm.com>
18229 * config/rs6000/rs6000-c.c: Add macro definitions for
18230 ALTIVEC_BUILTIN_VEC_PERMXOR.
18231 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
18232 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
18233 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
18234 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
18236 * config/doc/extend.texi: Add prototypes for vec_permxor.
18238 2018-03-14 David Malcolm <dmalcolm@redhat.com>
18241 * diagnostic-show-locus.c (class layout_point): Convert m_line
18242 from int to linenum_type.
18243 (line_span::comparator): Use linenum "compare" function when
18244 comparing line numbers.
18245 (test_line_span): New function.
18246 (layout_range::contains_point): Convert param "row" from int to
18248 (layout_range::intersects_line_p): Likewise.
18249 (layout::will_show_line_p): Likewise.
18250 (layout::print_source_line): Likewise.
18251 (layout::should_print_annotation_line_p): Likewise.
18252 (layout::print_annotation_line): Likewise.
18253 (layout::print_leading_fixits): Likewise.
18254 (layout::annotation_line_showed_range_p): Likewise.
18255 (struct line_corrections): Likewise for field m_row.
18256 (line_corrections::line_corrections): Likewise for param "row".
18257 (layout::print_trailing_fixits): Likewise.
18258 (layout::get_state_at_point): Likewise.
18259 (layout::get_x_bound_for_row): Likewise.
18260 (layout::print_line): Likewise.
18261 (diagnostic_show_locus): Likewise for locals "last_line" and "row".
18262 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
18263 * input.c (selftest::test_linenum_comparisons): New function.
18264 (selftest::input_c_tests): Call it.
18265 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
18266 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
18267 * selftest.h (ASSERT_GT): New macro.
18268 (ASSERT_GT_AT): New macro.
18269 (ASSERT_LT): New macro.
18270 (ASSERT_LT_AT): New macro.
18272 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
18274 PR rtl-optimization/84780
18275 * combine.c (distribute_links): Don't make a link based on pc_rtx.
18277 2018-03-14 Martin Liska <mliska@suse.cz>
18279 * tree.c (record_node_allocation_statistics): Use
18280 get_stats_node_kind.
18281 (get_stats_node_kind): New function extracted from
18282 record_node_allocation_statistics.
18283 (free_node): Use get_stats_node_kind.
18285 2018-03-14 Richard Biener <rguenther@suse.de>
18287 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
18288 that the value-set of ANTIC_IN doesn't grow.
18291 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
18293 (BB_VISITED_WITH_VISITED_SUCCS): New define.
18294 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
18296 2018-03-14 Julia Koval <julia.koval@intel.com>
18298 * config.gcc (icelake-client, icelake-server): New.
18300 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
18301 (initial_ix86_arch_features): Ditto.
18302 (PTA_SKYLAKE): Add SGX.
18303 (PTA_ICELAKE): Remove.
18304 (PTA_ICELAKE_CLIENT): New.
18305 (PTA_ICELAKE_SERVER): New.
18306 (ix86_option_override_internal): Split up icelake on icelake client and
18308 (get_builtin_code_for_version): Ditto.
18309 (fold_builtin_cpu): Ditto.
18310 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
18311 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
18312 * config/i386/i386.h (processor_type): Ditto.
18313 * doc/invoke.texi: Ditto.
18315 2018-03-14 Jakub Jelinek <jakub@redhat.com>
18318 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
18319 INTEGER_CST offset, add it together with bitpos / 8 and
18320 sign extend based on POINTER_SIZE.
18324 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
18327 * config/i386/constraints.md (Yc): New register constraint.
18328 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
18329 Use Yc constraint for alternative 2 of operand 0. Remove
18330 preferred_for_speed attribute.
18332 2018-03-14 Richard Biener <rguenther@suse.de>
18334 PR tree-optimization/84830
18335 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
18336 with the old one to avoid oscillations.
18338 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
18341 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
18343 (assign_by_spills): Return a flag of reload assignment failure.
18344 Do not process the reload assignment failures. Do not spill other
18345 reload pseudos if they has the same reg class. Update n if
18347 (lra_assign): Add a return arg. Set up from the result of
18348 assign_by_spills call.
18349 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
18350 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
18351 usage_insns if it is not NULL.
18352 (spill_hard_reg_in_range): New function.
18353 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
18354 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
18355 function prototypes.
18356 (lra_assign): Change prototype.
18357 * lra.c (lra): Add code to deal with fails by splitting hard reg
18360 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
18362 * config/riscv/riscv.opt (mrelax): New option.
18363 * config/riscv/riscv.c (riscv_file_start): Emit ".option
18364 "norelax" when riscv_mrelax is disabled.
18365 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
18367 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
18370 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
18371 reassociation for int modes.
18373 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
18375 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
18376 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
18378 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
18379 * config/aarch64/aarch64-sve.md
18380 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
18381 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
18382 (*extend<mode><Vwide>2): Rename to...
18383 (aarch64_sve_extend<mode><Vwide>2): ...this.
18384 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
18385 renaming the old pattern to...
18386 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
18388 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
18389 define_expand, renaming the old pattern to...
18390 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
18391 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
18392 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
18393 account when deciding which SVE instruction the optab should use.
18394 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
18396 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
18398 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
18399 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
18400 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
18401 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
18402 (tlsdesc_small_<mode>): Turn a define_expand and use
18403 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
18404 (tlsdesc_small_advsimd_<mode>): ...this.
18405 (tlsdesc_small_sve_<mode>): New pattern.
18407 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
18409 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
18410 (UNSPEC_UMUL_HIGHPART): New constants.
18411 (MUL_HIGHPART): New int iteraor.
18412 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
18413 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
18415 (*<su>mul<mode>3_highpart): New define_insn.
18417 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
18420 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
18423 2018-03-13 Martin Liska <mliska@suse.cz>
18426 * (sem_item_optimizer::sem_item_optimizer): Initialize new
18428 (sem_item_optimizer::~sem_item_optimizer): Release it.
18429 (sem_item_optimizer::merge_classes): Register variable aliases.
18430 (sem_item_optimizer::fixup_pt_set): New function.
18431 (sem_item_optimizer::fixup_points_to_sets): Likewise.
18432 * ipa-icf.h: Declare new variables and functions.
18434 2018-03-13 Jakub Jelinek <jakub@redhat.com>
18436 PR middle-end/84834
18437 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
18438 integer_pow2p@2 and test integer_pow2p in condition.
18439 (A < 0 ? C : 0): Similarly for @1.
18441 PR middle-end/84831
18442 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
18443 characters starting at p contain '\0' character, don't look beyond
18447 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
18448 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
18451 * reg-stack.c (change_stack): Change update_end var from int to
18452 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
18453 also call set_block_for_insn on the newly added insns and rescan.
18456 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
18457 on the last operand.
18460 * tree.c (stabilize_reference_1): Return save_expr (e) for
18461 STATEMENT_LIST even if it doesn't have side-effects.
18463 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
18465 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
18467 2018-03-12 Renlin Li <renlin.li@arm.com>
18469 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
18470 aarch64_output_scalar_simd_mov_immediate.
18472 2018-03-12 Martin Sebor <msebor@redhat.com>
18474 PR tree-optimization/83456
18475 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
18476 for perfectly overlapping calls to memcpy.
18477 (gimple_fold_builtin_memory_chk): Same.
18478 (gimple_fold_builtin_strcpy): Handle no-warning.
18479 (gimple_fold_builtin_stxcpy_chk): Same.
18480 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
18482 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
18484 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
18485 parameter. Use it for SFmode.
18486 (rs6000_function_arg_advance_1): Adjust.
18487 (rs6000_function_arg): Adjust.
18488 (rs6000_gimplify_va_arg): Pass false for that new parameter.
18490 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
18492 PR rtl-optimization/84169
18493 PR rtl-optimization/84780
18494 * combine.c (can_combine_p): Check for a 2-insn combination whether
18495 the destination register is used between the two insns, too.
18497 2018-03-12 Richard Biener <rguenther@suse.de>
18499 PR tree-optimization/84803
18500 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
18501 for refs DR analysis didn't process.
18503 2018-03-12 Richard Biener <rguenther@suse.de>
18505 PR tree-optimization/84777
18506 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
18507 force-vectorize loops ignore whether we are optimizing for size.
18509 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
18511 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
18512 (TARGET_MD_ASM_ADJUST): Define.
18514 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
18515 Kito Cheng <kito.cheng@gmail.com>
18516 Chung-Ju Wu <jasonwucj@gmail.com>
18518 * config/nds32/nds32.c (nds32_compute_stack_frame,
18519 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
18520 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
18521 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
18522 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
18523 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
18524 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
18525 * config/nds32/nds32.md (prologue, epilogue): Use macro
18526 NDS32_V3PUSH_AVAILABLE_P to do checking.
18528 2018-03-11 Jakub Jelinek <jakub@redhat.com>
18531 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
18532 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
18533 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
18534 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
18535 addition of most attributes on !orig_type_die or the attribute not
18536 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
18538 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
18539 Chung-Ju Wu <jasonwucj@gmail.com>
18541 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
18542 __NDS32_VH__ macro.
18543 * config/nds32/nds32.opt (mvh): New option.
18545 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
18546 Chung-Ju Wu <jasonwucj@gmail.com>
18548 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
18550 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
18551 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
18554 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
18555 Chung-Ju Wu <jasonwucj@gmail.com>
18557 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
18559 * config/nds32/nds32-multiple.md (strlensi): New pattern.
18560 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
18562 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
18563 Kito Cheng <kito.cheng@gmail.com>
18564 Chung-Ju Wu <jasonwucj@gmail.com>
18566 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
18567 UNSPEC_FFMISM and UNSPEC_FLMISM.
18568 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
18569 for ffb, ffmism and flmism.
18570 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
18571 (unspec_ffmism): Ditto.
18572 (unspec_flmism): Ditto.
18573 (nds32_expand_builtin_impl): Check if string extension is available.
18574 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
18575 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
18577 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
18580 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
18583 * lra-assigns.c (assign_by_spills): Return a flag of reload
18584 assignment failure. Do not process the reload assignment
18585 failures. Do not spill other reload pseudos if they has the same
18587 (lra_assign): Add a return arg. Set up from the result of
18588 assign_by_spills call.
18589 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
18590 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
18591 usage_insns if it is not NULL.
18592 (spill_hard_reg_in_range): New function.
18593 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
18594 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
18595 function prototypes.
18596 (lra_assign): Change prototype.
18597 * lra.c (lra): Add code to deal with fails by splitting hard reg
18600 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
18603 * config/i386/i386.opt: Replace Enforcment with Enforcement.
18605 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
18608 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
18609 (dw_val_node): Add val_symbolic_view.
18610 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
18611 (symview_upper_bound): New.
18612 (new_line_info_table): Initialize symviews_since_reset.
18613 (dwarf2out_source_line): Count symviews_since_reset and set
18614 symview_upper_bound.
18615 (dw_val_equal_p): Handle symview.
18616 (add_AT_symview): New.
18617 (print_dw_val): Handle symview.
18618 (attr_checksum, attr_checksum_ordered): Likewise.
18619 (same_dw_val_p, size_of_die): Likewise.
18620 (value_format, output_die): Likewise.
18621 (add_high_low_attributes): Use add_AT_symview for entry_view.
18622 (dwarf2out_finish): Reset symview_upper_bound, clear
18625 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
18628 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
18629 Add strict argument and use it.
18630 (rs6000_split_multireg_move): Update for new strict argument.
18631 (mem_operand_gpr): Disallow all non-offsettable addresses.
18632 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
18634 2018-03-09 Jakub Jelinek <jakub@redhat.com>
18637 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
18638 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
18639 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
18642 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
18643 decl, use remap_type if we want to use the type.
18645 2018-03-09 Martin Sebor <msebor@redhat.com>
18647 PR tree-optimization/84526
18648 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
18650 (builtin_access::generic_overlap): Be prepared to handle non-array
18653 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
18655 PR rtl-optimization/84682
18656 * lra-constraints.c (process_address_1): Check is_address flag
18657 for address constraints.
18658 (process_alt_operands): Likewise.
18659 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
18660 preprocess_constraints.
18661 * recog.h (preprocess_constraints): Add oploc parameter.
18663 * recog.c (preprocess_constraints): Test address_operand for
18664 CT_ADDRESS constraints.
18666 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
18669 * lra-assigns.c (assign_by_spills): Return a flag of reload
18670 assignment failure. Do not process the reload assignment
18671 failures. Do not spill other reload pseudos if they has the same
18673 (lra_assign): Add a return arg. Set up from the result of
18674 assign_by_spills call.
18675 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
18676 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
18677 usage_insns if it is not NULL.
18678 (spill_hard_reg_in_range): New function.
18679 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
18680 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
18681 function prototypes.
18682 (lra_assign): Change prototype.
18683 * lra.c (lra): Add code to deal with fails by splitting hard reg
18686 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18689 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
18690 Accept complain bool parameter. Only emit errors if it is true.
18691 (arm_parse_cpu_option_name): Likewise.
18692 (arm_target_thumb_only): Adjust callers of the above.
18693 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
18694 prototype to take a default true bool parameter.
18695 (arm_parse_arch_option_name): Likewise.
18697 2018-03-09 David Malcolm <dmalcolm@redhat.com>
18698 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
18702 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
18703 * configure: Regenerate.
18704 * configure.ac ("linker --version-script option"): New.
18705 ("linker soname option"): New.
18707 2018-03-09 Richard Biener <rguenther@suse.de>
18709 PR tree-optimization/84775
18710 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
18711 immediate uses of predicate stmts and mark them modified.
18714 PR tree-optimization/84178
18715 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
18717 (version_loop_for_if_conversion): Delay update_ssa call.
18718 (tree_if_conversion): Delay update_ssa until after predicate
18721 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
18724 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
18725 when the function accesses prior frames.
18727 2018-03-08 Jakub Jelinek <jakub@redhat.com>
18730 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
18731 gen_llsym, otherwise call maybe_gen_llsym.
18733 PR inline-asm/84742
18734 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
18735 has ',' character inside of it.
18737 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18740 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
18741 as clobbering CC_REGNUM.
18743 2018-03-08 Richard Biener <rguenther@suse.de>
18745 PR middle-end/84552
18746 * tree-scalar-evolution.c: Include tree-into-ssa.h.
18747 (follow_copies_to_constant): Do not follow SSA names registered
18750 2018-03-08 Richard Biener <rguenther@suse.de>
18752 PR tree-optimization/84178
18753 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
18755 (version_loop_for_if_conversion): Delay update_ssa call.
18756 (tree_if_conversion): Delay update_ssa until after predicate
18759 2018-03-08 David Malcolm <dmalcolm@redhat.com>
18761 PR tree-optimization/84178
18762 * tree-if-conv.c (release_bb_predicate): Remove the
18763 the assertion that the stmts have NULL use_ops.
18764 Discard the statements, asserting that they haven't
18765 yet been added to a BB.
18767 2018-03-08 Richard Biener <rguenther@suse.de>
18769 PR tree-optimization/84746
18770 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
18771 (phi_translate): Pass in destination ANTIC_OUT set.
18772 (phi_translate_1): Likewise. For a simplified result lookup
18773 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
18774 (phi_translate_set): Adjust.
18775 (do_pre_regular_insertion): Likewise.
18776 (do_pre_partial_partial_insertion): Likewise.
18778 2018-03-08 Martin Liska <mliska@suse.cz>
18780 PR gcov-profile/84735
18781 * doc/gcov.texi: Document usage of profile files.
18782 * gcov-io.h: Document changes in the format.
18784 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
18788 * dwarf2out.c (struct dw_line_info_table): Update comments for
18790 (FORCE_RESET_NEXT_VIEW): New.
18791 (FORCE_RESETTING_VIEW_P): New.
18792 (RESETTING_VIEW_P): Check for -1 too.
18793 (ZERO_VIEW_P): Likewise.
18794 (new_line_info_table): Force-reset next view.
18795 (dwarf2out_begin_function): Likewise.
18796 (dwarf2out_source_line): Simplify zero_view_p initialization.
18797 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
18798 view directly. Omit view when omitting .loc at line 0.
18800 2018-03-08 Jakub Jelinek <jakub@redhat.com>
18802 PR tree-optimization/84740
18803 * tree-switch-conversion.c (process_switch): Call build_constructors
18804 only if info.phi_count is non-zero.
18806 PR tree-optimization/84739
18807 * tree-tailcall.c (find_tail_calls): Check call arguments against
18808 DECL_ARGUMENTS (current_function_decl) rather than
18809 DECL_ARGUMENTS (func) when checking for tail recursion.
18811 2018-03-07 Jakub Jelinek <jakub@redhat.com>
18813 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
18814 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
18815 Volker Reichelt's entry and add entries for people that perform
18816 GCC fuzzy testing and report numerous bugs.
18818 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
18821 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
18822 readonly data in sdata, if that is disabled.
18823 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
18824 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
18825 -mreadonly-in-sdata option.
18827 2018-03-07 Martin Sebor <msebor@redhat.com>
18829 PR tree-optimization/84468
18830 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
18831 basic block when looking for nul assignment.
18833 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
18836 * except.h (output_function_exception_table): Adjust prototype.
18837 * except.c (output_function_exception_table): Remove FNNAME parameter
18838 and add SECTION parameter. Ouput one part of the table at a time.
18839 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
18840 the first part of the exception table and emit unwind directives.
18841 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
18842 (i386_pe_seh_cold_init): Likewise.
18843 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
18844 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
18845 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
18846 (ix86_output_call_insn): Emit a nop in one more case for SEH.
18847 * config/i386/winnt.c: Include except.h.
18848 (struct seh_frame_state): Add reg_offset, after_prologue and
18849 in_cold_section fields.
18850 (i386_pe_seh_end_prologue): Set seh->after_prologue.
18851 (i386_pe_seh_cold_init): New function.
18852 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
18853 to seh->in_cold_section.
18854 (seh_emit_push): Record the offset of the push.
18855 (seh_emit_save): Record the offet of the save.
18856 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
18857 Test seh->after_prologue to disregard the epilogue.
18858 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
18859 (i386_pe_end_cold_function): New function.
18861 2018-03-07 Jakub Jelinek <jakub@redhat.com>
18864 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
18865 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
18868 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
18870 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
18871 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
18873 PR middle-end/84723
18874 * multiple_target.c: Include tree-inline.h and intl.h.
18875 (expand_target_clones): Diagnose and fail if node->definition and
18876 !tree_versionable_function_p (node->decl).
18878 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
18880 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
18882 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
18883 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
18884 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
18886 2018-03-06 Jakub Jelinek <jakub@redhat.com>
18889 * combine.c (try_combine): Use reg_or_subregno instead of handling
18890 just paradoxical SUBREGs and REGs.
18892 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
18894 * config/arc/arc.c (arc_finalize_pic): Remove function.
18895 (arc_must_save_register): We use single base PIC register, remove
18896 checks to save/restore the PIC register.
18897 (arc_expand_prologue): Likewise.
18898 * config/arc/arc-protos.h (arc_set_default_type_attributes):
18900 (arc_verify_short): Likewise.
18901 (arc_attr_type): Likewise.
18902 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
18903 (walk_stores): Likewise.
18904 (arc_address_cost): Make it static.
18905 (arc_verify_short): Likewise.
18906 (branch_dest): Likewise.
18907 (arc_attr_type): Likewise.
18908 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
18909 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
18910 (arc_final_prescan_insn): Remove inserting the nops due to
18911 hardware hazards. It is done in reorg step.
18912 (insn_length_variant_t): Remove.
18913 (insn_length_parameters_t): Likewise.
18914 (arc_insn_length_parameters): Likewise.
18915 (arc_get_insn_variants): Likewise.
18916 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
18918 2018-03-06 Jakub Jelinek <jakub@redhat.com>
18920 PR inline-asm/84683
18921 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
18924 PR tree-optimization/84687
18925 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
18927 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
18929 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
18931 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
18932 Rename to ppc_speculation_barrier.
18933 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
18934 __builtin_ppc_speculation_barrier.
18936 2018-03-05 Jakub Jelinek <jakub@redhat.com>
18939 * combine.c (combine_simplify_rtx): Don't try to simplify if
18940 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
18943 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
18945 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
18946 to 32 bytes when compiling for POWER9.
18948 2018-03-05 Jakub Jelinek <jakub@redhat.com>
18951 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
18952 regparm >= 3 with no arg reg available also for calls with
18953 flag_force_indirect_call. Pass decl to ix86_function_regparm.
18956 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
18958 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
18960 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
18963 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
18965 2018-03-05 Richard Biener <rguenther@suse.de>
18967 PR tree-optimization/84486
18968 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
18969 When inserting a __builtin_assume_aligned call set the LHS
18970 SSA name alignment info accordingly.
18972 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
18974 PR tree-optimization/84114
18975 * config/aarch64/aarch64.c (aarch64_reassociation_width)
18976 Avoid reassociation of FLOAT_MODE addition.
18978 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
18980 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
18981 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
18982 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
18983 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
18984 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
18985 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
18986 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
18988 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
18989 __builtin_ia32_wbinvd): New builtins.
18990 (SPECIAL_ARGS2): New.
18991 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
18992 (SPECIAL_ARGS2): New.
18993 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
18994 (ix86_valid_target_attribute_inner_p): Ditto.
18995 (ix86_init_mmx_sse_builtins): Add special_args2.
18996 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
18997 TARGET_WBNOINVD_P): New.
18998 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
18999 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
19000 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
19001 * config/i386/immintrin.h (_wbinvd): New intrinsic.
19002 * config/i386/pconfigintrin.h: New file.
19003 * config/i386/wbnoinvdintrin.h: Ditto.
19004 * config/i386/x86intrin.h: Add headers pconfigintrin.h and
19006 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
19008 2018-03-05 Richard Biener <rguenther@suse.de>
19010 PR tree-optimization/84670
19011 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
19013 (BB_VISITED_WITH_VISITED_SUCCS): New define.
19014 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
19015 (compute_antic_aux): Only assert the number of values in ANTIC_IN
19016 doesn't grow if all successors (recursively) were visited at least
19019 2018-03-05 Richard Biener <rguenther@suse.de>
19021 PR tree-optimization/84650
19022 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
19023 if executed in the loop pipeline.
19025 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
19027 * doc/configfiles.texi (Configuration Files): Move info about
19028 conditionalizing $target-protos.h to...
19029 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
19030 differs from $target-protos.h.
19032 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
19033 Chung-Ju Wu <jasonwucj@gmail.com>
19035 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
19036 * config/nds32/nds32-multiple.md (setmemsi): Define.
19037 * config/nds32/nds32-memory-manipulation.c
19038 (nds32_gen_dup_4_byte_to_word_value): New.
19039 (emit_setmem_word_loop): New.
19040 (emit_setmem_byte_loop): New.
19041 (nds32_expand_setmem_loop): New.
19042 (nds32_expand_setmem_loop_v3m): New.
19043 (nds32_expand_setmem_unroll): New.
19044 (nds32_expand_setmem): New.
19046 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
19047 Chung-Ju Wu <jasonwucj@gmail.com>
19049 * config/nds32/nds32-memory-manipulation.c
19050 (nds32_emit_load_store): New.
19051 (nds32_emit_post_inc_load_store): New.
19052 (nds32_emit_mem_move): New.
19053 (nds32_emit_mem_move_block): New.
19054 (nds32_expand_movmemsi_loop_unknown_size): New.
19055 (nds32_expand_movmemsi_loop_known_size): New.
19056 (nds32_expand_movmemsi_loop): New.
19057 (nds32_expand_movmemsi_unroll): New.
19058 (nds32_expand_movmemqi): Rename ...
19059 (nds32_expand_movmemsi): ... to this.
19060 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
19061 (movmemsi): ... to this.
19062 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
19063 (nds32_expand_movmemsi): ... to this.
19065 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
19066 Monk Chiang <sh.chiang04@gmail.com>
19067 Chung-Ju Wu <jasonwucj@gmail.com>
19069 * config/nds32/nds32-protos.h
19070 (nds32_expand_load_multiple): New arguments.
19071 (nds32_expand_store_multiple): Ditto.
19072 (nds32_valid_multiple_load_store): Rename ...
19073 (nds32_valid_multiple_load_store_p): ... to this.
19074 * config/nds32/nds32-memory-manipulation.c
19075 (nds32_expand_load_multiple): Refine implementation.
19076 (nds32_expand_store_multiple): Ditto.
19077 * config/nds32/nds32-multiple.md
19078 (load_multiple): Update nds32_expand_load_multiple interface.
19079 (store_multiple): Update nds32_expand_store_multiple interface.
19080 * config/nds32/nds32-predicates.c
19081 (nds32_valid_multiple_load_store): Rename ...
19082 (nds32_valid_multiple_load_store_p): ... to this and refine
19084 * config/nds32/predicates.md
19085 (nds32_load_multiple_and_update_address_operation): New predicate.
19086 (nds32_store_multiple_and_update_address_operation): New predicate.
19088 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
19089 Chung-Ju Wu <jasonwucj@gmail.com>
19091 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
19092 (combo): New attribute.
19093 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
19095 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
19097 * config/nds32/nds32.opt: Change -mcmodel= default value.
19099 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
19100 Monk Chiang <sh.chiang04@gmail.com>
19101 Chung-Ju Wu <jasonwucj@gmail.com>
19103 * config/nds32/constants.md (unspec_element): New enum.
19104 * config/nds32/constraints.md (Umw): New constraint.
19105 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
19106 * config/nds32/nds32-intrinsic.md: Likewise.
19107 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
19108 (nds32_valid_smw_lwm_base_p): New.
19109 (nds32_output_smw_single_word): New.
19110 (nds32_output_lmw_single_word): New.
19111 (nds32_expand_unaligned_load): New.
19112 (nds32_expand_unaligned_store): New.
19113 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
19114 (nds32_output_smw_single_word): Declare.
19115 (nds32_output_lmw_single_word): Declare.
19116 (nds32_expand_unaligned_load): Declare.
19117 (nds32_expand_unaligned_store): Declare.
19118 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
19119 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
19120 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
19121 NDS32_BUILTIN_UASTORE_DW.
19122 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
19125 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
19126 Kito Cheng <kito.cheng@gmail.com>
19127 Chung-Ju Wu <jasonwucj@gmail.com>
19129 * config/nds32/nds32-intrinsic.c
19130 (nds32_expand_builtin_null_ftype_reg): Delete.
19131 (nds32_expand_builtin_reg_ftype_imm): Ditto.
19132 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
19133 (nds32_read_argument): New.
19134 (nds32_legitimize_target): Ditto.
19135 (nds32_legitimize_argument): Ditto.
19136 (nds32_check_constant_argument): Ditto.
19137 (nds32_expand_unop_builtin): Ditto.
19138 (nds32_expand_unopimm_builtin): Ditto.
19139 (nds32_expand_binop_builtin): Ditto.
19140 (nds32_builtin_decl_impl): Ditto.
19141 (builtin_description): Ditto.
19142 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
19143 (nds32_init_builtins_impl): Ditto.
19144 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
19145 (nds32_builtin_decl): New.
19146 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
19147 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
19149 2018-03-02 Jeff Law <law@redhat.com>
19151 * reorg.c (stop_search_p): Handle DEBUG_INSN.
19152 (redundant_insn, fill_simple_delay_slots): Likewise.
19153 (fill_slots_from_thread): Likewise.
19154 * resource.c (mark_referenced_resources): Likewise.
19155 (mark_set_resources, find_dead_or_set_registers): Likewise.
19157 2018-03-02 Jakub Jelinek <jakub@redhat.com>
19159 * substring-locations.h (format_warning_va): Formatting fix for
19160 ATTRIBUTE_GCC_DIAG.
19161 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
19163 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
19164 * substring-locations.c: Include intl.h.
19165 (format_warning_va): Turned into small wrapper around
19166 format_warning_n_va, renamed to ...
19167 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
19168 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
19170 (format_warning_at_substring_n): New function.
19171 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
19172 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
19173 format_warning_at_substring with just a shorter name instead of
19174 const function pointer.
19175 (fmtwarn_n): New function.
19176 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
19177 appropriate, get rid of all the fmtstr temporaries, move conditionals
19178 with G_() wrapped string literals directly into fmtwarn arguments,
19179 cast dir.len to (int), formatting fixes.
19181 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
19183 * doc/invoke.texi: Remove "Cilk Plus" references.
19185 2018-03-02 Jakub Jelinek <jakub@redhat.com>
19186 Richard Biener <rguenther@suse.de>
19189 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
19190 for error or warning attributes if CALL_FROM_THUNK_P is set.
19193 2018-03-02 Jakub Jelinek <jakub@redhat.com>
19196 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
19197 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
19200 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
19201 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
19203 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
19204 instead of -1U in last predictors element's probability member.
19206 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
19209 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
19210 arguments if they are comparable.
19212 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
19214 PR tree-optimization/84634
19215 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
19216 masks and masked_loop_p with a single loop_masks, making sure it's
19217 null for bb vectorization.
19219 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
19221 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
19222 (vect_analyze_data_ref_access): Use loop->safe_len rather than
19223 loop->force_vectorize to check whether there is no alias.
19225 2018-03-02 Jakub Jelinek <jakub@redhat.com>
19228 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
19230 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
19232 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
19233 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
19234 instead of a loop around prev_real_insn.
19235 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
19238 PR inline-asm/84625
19239 * config/i386/i386.c (ix86_print_operand): Use conditional
19240 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
19243 2018-03-02 Richard Biener <rguenther@suse.de>
19245 PR tree-optimization/84427
19246 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
19247 (bitmap_set_subtract_values): Rewrite to handle multiple
19250 (prune_clobbered_mems): Likewise.
19251 (phi_translate): Take edge instead of pred/phiblock.
19252 (phi_translate_1): Likewise.
19253 (phi_translate_set): Likewise. Insert all translated
19254 exprs for a value into the set, keeping possibly multiple
19255 expressions per value.
19256 (compute_antic_aux): Adjust for phi_translate changes.
19257 When intersecting union the expressions and prune those
19258 not in the final value set, keeping possibly multiple
19259 expressions per value. Do not use value-insertion
19260 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
19261 all expressions. Add verification that the value-sets
19262 only shrink during iteration.
19263 (compute_partial_antic_aux): Adjust for the phi_translate changes.
19264 (do_pre_regular_insertion): Likewise.
19265 (do_pre_partial_partial_insertion): Likewise.
19267 2018-03-02 Richard Biener <rguenther@suse.de>
19270 * config/darwin.c (saved_debug_info_level): New static global.
19271 (darwin_asm_lto_start): Disable debug info generation for LTO out.
19272 (darwin_asm_lto_end): Restore debug info generation settings.
19274 2018-03-01 Martin Liska <mliska@suse.cz>
19277 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
19278 volatile arguments.
19280 2018-03-01 Richard Biener <rguenther@suse.de>
19283 * dwarf2out.c (gen_variable_die): Properly handle late VLA
19284 type annotation with LTO when debug was disabled at compile-time.
19286 2018-03-01 Matthew Fortune <mfortune@gmail.com>
19288 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
19290 (mips_final_postscan_insn): Likewise.
19292 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
19294 PR rtl-optimization/84528
19295 * alias.c (init_alias_target): Add commentary.
19296 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
19297 a unique base value if the frame pointer is not eliminated
19298 to the stack pointer.
19300 2018-03-01 Tom de Vries <tom@codesourcery.com>
19302 PR rtl-optimization/83327
19303 * lra-int.h (hard_regs_spilled_into): Declare.
19304 * lra.c (hard_regs_spilled_into): Define.
19305 (init_reg_info): Init hard_regs_spilled_into.
19306 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
19307 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
19308 (process_bb_lives): Handle hard_regs_spilled_into.
19309 (lra_create_live_ranges_1): Before doing liveness propagation, clear
19310 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
19312 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
19314 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
19315 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
19316 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
19317 * config/rs6000/aix72.h: New file.
19319 2018-02-28 Jakub Jelinek <jakub@redhat.com>
19321 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
19322 instead of warning_at with conditional singular and plural messages
19326 * stor-layout.c (update_alignment_for_field): For
19327 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
19328 && !DECL_PACKED (field), do the alignment update, just use
19329 only desired_align instead of MAX (type_align, desired_align)
19331 (place_field): Don't do known_align < desired_align handling
19332 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
19333 is non-NULL, instead do it after rli->prev_field handling and
19334 only if not within a bitfield word. For DECL_PACKED (field)
19335 use type_align of BITS_PER_UNIT.
19337 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
19339 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
19340 superfluous parentheses and trailing spaces.
19342 2018-02-28 Richard Biener <rguenther@suse.de>
19344 PR tree-optimization/84584
19345 * graphite-scop-detection.c (scop_detection::add_scop): Discard
19346 SCoPs with fake exit edge.
19348 2018-02-28 Martin Liska <mliska@suse.cz>
19351 * timevar.c (timer::print): Fix format to properly print 100%
19354 2018-02-28 Richard Biener <rguenther@suse.de>
19356 PR middle-end/84607
19357 * genmatch.c (capture_info::walk_match): Do not mark
19358 captured expressions without operands as expr_p given
19359 they act more like predicates and should be subject to
19360 "lost tail" side-effect preserving.
19362 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
19364 PR rtl-optimization/81611
19365 * auto-inc-dec.c (attempt_change): Move dead note from
19366 mem_insn if it's the next use of regno
19367 (find_address): Take address use of reg holding
19368 non-incremented value. Add parm to limit search to the named
19370 (merge_in_block): Attempt to use a mem insn that is the next
19371 use of the original regno.
19373 2018-02-27 Martin Sebor <msebor@redhat.com>
19376 * doc/invoke.texi (-Wmissing-attributes): New option.
19377 * print-tree.c (print_node): Handle DECL_UNINLINABLE.
19379 2018-02-27 Martin Sebor <msebor@redhat.com>
19381 PR translation/84207
19382 * diagnostic-core.h (warning_n, error_n, inform_n): Change
19383 n argument to unsigned HOST_WIDE_INT.
19384 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
19385 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
19386 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
19387 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
19389 2018-02-27 Richard Biener <rguenther@suse.de>
19391 PR tree-optimization/84512
19392 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
19393 Do not use the estimate returned from record_stmt_cost for
19394 the scalar iteration cost but sum properly using add_stmt_cost.
19396 2018-02-27 Richard Biener <rguenther@suse.de>
19398 PR tree-optimization/84466
19399 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
19400 Adjust last change to less strictly validate use operands.
19402 2018-02-27 Martin Liska <mliska@suse.cz>
19404 PR gcov-profile/84548
19405 * gcov.c (process_file): Allow partial overlap and consider it
19406 also as group functions.
19407 (output_lines): Properly calculate range of lines for a group.
19409 2018-02-27 Martin Liska <mliska@suse.cz>
19411 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
19412 'ggc' suffixes. Change first column width.
19413 (timer::print): Fix formatting of the column.
19415 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
19417 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
19418 preserve inline entry blocks for the sake of debug inline
19419 entry point markers alone.
19420 (remove_unused_locals): Suggest in comments a better place to
19421 force the preservation of inline entry blocks that are
19422 otherwise unused, but do not preserve them.
19424 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
19426 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
19428 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
19431 * config/i386/constraints.md (Bs): Replace
19432 ix86_indirect_branch_register with
19433 TARGET_INDIRECT_BRANCH_REGISTER.
19435 * config/i386/i386.md (indirect_jump): Likewise.
19436 (tablejump): Likewise.
19437 (*sibcall_memory): Likewise.
19438 (*sibcall_value_memory): Likewise.
19439 Peepholes of indirect call and jump via memory: Likewise.
19440 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
19441 (*sibcall_value_GOT_32): Likewise.
19442 * config/i386/predicates.md (indirect_branch_operand): Likewise.
19443 (GOT_memory_operand): Likewise.
19444 (call_insn_operand): Likewise.
19445 (sibcall_insn_operand): Likewise.
19446 (GOT32_symbol_operand): Likewise.
19447 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
19449 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
19451 PR rtl-optimization/83496
19452 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
19453 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
19454 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
19455 redundant insn, if any.
19456 (relax_delay_slots): Likewise.
19457 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
19459 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
19461 PR tree-optimization/83965
19462 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
19463 that grouped statements are part of a reduction chain. Return
19464 true if the statement is not marked as a reduction itself but
19465 is part of a group.
19466 (vect_recog_dot_prod_pattern): Don't check whether the statement
19467 is part of a group here.
19468 (vect_recog_sad_pattern): Likewise.
19469 (vect_recog_widen_sum_pattern): Likewise.
19471 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
19474 * final.c (rest_of_clean_state): Also look for calls inside sequences.
19476 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
19479 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
19481 (ix86_output_indirect_function_return): New prototype.
19482 (ix86_split_simple_return_pop_internal): Likewise.
19483 * config/i386/i386.c (indirect_return_via_cx): New.
19484 (indirect_return_via_cx_bnd): Likewise.
19485 (indirect_thunk_name): Handle return va CX_REG.
19486 (output_indirect_thunk_function): Create alias for
19487 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
19488 (ix86_output_indirect_jmp): Remove the bool argument.
19489 (ix86_output_indirect_function_return): New function.
19490 (ix86_split_simple_return_pop_internal): Likewise.
19491 * config/i386/i386.md (*indirect_jump): Don't pass false
19492 to ix86_output_indirect_jmp.
19493 (*tablejump_1): Likewise.
19494 (simple_return_pop_internal): Change it to define_insn_and_split.
19495 Call ix86_split_simple_return_pop_internal to split it for
19496 -mfunction-return=.
19497 (simple_return_indirect_internal): Call
19498 ix86_output_indirect_function_return instead of
19499 ix86_output_indirect_jmp.
19501 2018-02-26 Jakub Jelinek <jakub@redhat.com>
19504 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
19505 memset and value initialization afterwards.
19507 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
19509 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
19511 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
19514 * common/config/aarch64/aarch64-common.c
19515 (aarch_option_optimization_table[]): Switch
19516 off fomit-frame-pointer
19518 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
19519 Chung-Ju Wu <jasonwucj@gmail.com>
19521 * config/nds32/nds32-multiple.md (load_multiple): Disallow
19523 (store_multiple): Ditto.
19525 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
19527 * config.gcc: Add --with-cpu support for nds32 target.
19528 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
19529 * config/nds32/nds32.opt: Add -mcpu= option.
19531 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
19533 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
19534 isel=yes): Warn for these deprecated options.
19536 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
19538 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
19539 ISA_2_5_MASKS_EMBEDDED.
19541 2018-02-23 Jakub Jelinek <jakub@redhat.com>
19543 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
19544 p->max as pointers rather than using iterative_hash_expr.
19546 2018-02-23 Carl Love <cel@us.ibm.com>
19548 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
19549 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
19551 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
19552 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
19553 P8V_BUILTIN_VEC_VUNSIGNED2.
19555 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
19558 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
19559 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
19561 * lra-constraints.c (curr_insn_transform): Set up
19562 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
19564 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
19565 * lra-eliminations.c (spill_pseudos): Ditto.
19566 (process_insn_for_elimination): Ditto.
19567 * lra-lives.c (reg_early_clobber_p): Use the new macros.
19568 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
19569 LRA_NON_CLOBBERED_ALT.
19571 2018-02-22 Martin Sebor <msebor@redhat.com>
19573 PR tree-optimization/84480
19574 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
19575 to maybe_diag_stxncpy_trunc. Call it.
19576 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
19577 from gimple_fold_builtin_strcpy. Print inlining stack.
19578 (handle_builtin_stxncpy): Print inlining stack.
19579 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
19581 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
19584 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
19585 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
19586 and -fcheck-pointer-bounds are used together.
19587 (indirect_thunk_prefix): New enum.
19588 (indirect_thunk_need_prefix): New function.
19589 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
19590 "_nt" instead of "_bnd" for NOTRACK prefix.
19591 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
19592 (output_indirect_thunk_function): Likewise.
19594 (ix86_code_end): Update output_indirect_thunk_function calls.
19595 (ix86_output_indirect_branch_via_reg): Replace
19596 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
19597 (ix86_output_indirect_branch_via_push): Likewise.
19598 (ix86_output_function_return): Likewise.
19599 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
19600 incompatible with -fcf-protection=branch and
19601 -fcheck-pointer-bounds.
19603 2018-02-22 Steve Ellcey <sellcey@cavium.com>
19606 * config/aarch64/aarch64.c (aarch64_print_address_internal):
19607 Change gcc_assert call to output_operand_lossage.
19609 2018-02-22 Steve Ellcey <sellcey@cavium.com>
19611 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
19613 2018-02-22 DJ Delorie <dj@redhat.com>
19614 Sebastian Perta <sebastian.perta@renesas.com>
19615 Oleg Endo <olegendo@gcc.gnu.org>
19617 * config/rx/rx.c (rx_rtx_costs): New function.
19618 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
19620 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
19622 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
19624 2018-02-22 Martin Liska <mliska@suse.cz>
19627 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
19628 Add "native" as a possible value.
19630 2018-02-22 Martin Liska <mliska@suse.cz>
19633 * config/i386/i386.c (ix86_option_override_internal):
19634 Add "native" as a possible value for -march and -mtune.
19636 2018-02-22 Jakub Jelinek <jakub@redhat.com>
19639 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
19640 to all type variants.
19642 PR tree-optimization/84503
19643 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
19644 width as info->bitpos + info->bitsize - start.
19645 (merged_store_group::merge_overlapping): Simplify width computation.
19646 (check_no_overlap): New function.
19647 (imm_store_chain_info::try_coalesce_bswap): Compute expected
19648 start + width and last_order of the group, fail if check_no_overlap
19650 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
19651 to group if check_no_overlap fails.
19653 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
19655 * config/rs6000/altivec.md: Delete contraint arguments to
19656 define_expand, define_split, and define_peephole2, and in
19657 define_insn_and_split if always unused.
19658 * config/rs6000/darwin.md: Ditto.
19659 * config/rs6000/dfp.md: Ditto.
19660 * config/rs6000/rs6000.md: Ditto.
19661 * config/rs6000/sync.md: Ditto.
19662 * config/rs6000/vector.md: Ditto.
19663 * config/rs6000/vsx.md: Ditto.
19665 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
19667 * config/rs6000/altivec.md: Write output control strings as braced
19668 blocks instead of double-quoted strings.
19669 * config/rs6000/darwin.md: Ditto.
19670 * config/rs6000/rs6000.md: Ditto.
19671 * config/rs6000/vector.md: Ditto.
19672 * config/rs6000/vsx.md: Ditto.
19674 2018-02-21 Jason Merrill <jason@redhat.com>
19676 PR c++/84314 - ICE with templates and fastcall attribute.
19677 * attribs.c (build_type_attribute_qual_variant): Remove assert.
19679 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
19681 * ipa-cp.c (determine_versionability): Fix comment typos.
19683 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
19686 * ipa-cp.c (determine_versionability): Do not version functions caling
19689 2018-02-21 Martin Liska <mliska@suse.cz>
19692 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
19693 Add "native" as a possible value.
19694 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
19695 the macro when native cpu detection is available.
19697 2018-02-21 Martin Liska <mliska@suse.cz>
19700 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
19701 Add "native" as a possible value.
19702 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
19703 when native cpu detection is available.
19705 2018-02-21 Jakub Jelinek <jakub@redhat.com>
19706 Martin Sebor <msebor@redhat.com>
19708 PR tree-optimization/84478
19709 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
19711 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
19712 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
19713 support which is conservatively correct, for 2 only stay conservative
19714 for maxlen. Formatting and comment capitalization fixes. Add STRICT
19715 argument to the 2 argument get_range_strlen, adjust 6 arg
19716 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
19718 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
19719 (gimple_fold_builtin_strlen): Pass true as last argument to
19722 2018-02-20 Martin Sebor <msebor@redhat.com>
19724 PR middle-end/84095
19725 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
19726 (builtin_memref::set_base_and_offset): Same. Handle inner references.
19727 (builtin_memref::builtin_memref): Factor out parts into
19728 set_base_and_offset and call it.
19730 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
19732 PR middle-end/84406
19733 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
19734 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
19735 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
19736 search at the associated MODE_INT.
19738 2018-02-20 Jeff Law <law@redhat.com>
19740 PR middle-end/82123
19741 PR tree-optimization/81592
19742 PR middle-end/79257
19743 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
19744 for range data rather than using global data.
19745 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
19746 range data rather than using global data.
19747 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
19748 pass it to children as needed.
19749 (struct directive::fmtresult): Similarly.
19750 (struct directive::set_width): Similarly.
19751 (struct directive::set_precision): Similarly.
19752 (format_integer, format_directive, parse_directive): Similarly.
19753 (format_none): Accept unnamed vr_values parameter.
19754 (format_percent, format_floating, format_character): Similarly.
19755 (format_string, format_plain): Similarly.
19756 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
19757 the EVRP range analyzer for range data rather than using global data.
19758 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
19759 gimple-ssa-evrp-analyze.h
19760 (class sprintf_dom_walker): Add after_dom_children member function.
19761 Add evrp_range_analyzer member.
19762 (sprintf_dom_walker::before_dom_children): Call into the EVRP
19763 range analyzer as needed.
19764 (sprintf_dom_walker::after_dom_children): New member function.
19765 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
19767 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
19768 (evrp_range_analyzer::pop_to_marker): Likewise.
19770 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
19772 PR tree-optimization/84419
19773 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
19774 with the required type if its current type is compatible but
19777 2018-02-20 Jakub Jelinek <jakub@redhat.com>
19779 PR middle-end/82004
19780 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
19781 after vectorization.
19783 2018-02-20 Martin Liska <mliska@suse.cz>
19786 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
19787 possible values if we don't have a hint.
19789 2018-02-20 Martin Liska <mliska@suse.cz>
19793 * final.c (shorten_branches): Build align_tab array with one
19795 * opts.c (finish_options): Add alignment option limit check.
19796 (MAX_CODE_ALIGN): Likewise.
19797 (MAX_CODE_ALIGN_VALUE): Likewise.
19798 * doc/invoke.texi: Document maximum allowed option value for
19799 all -falign-* options.
19801 2018-02-19 Jakub Jelinek <jakub@redhat.com>
19804 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
19805 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
19806 * var-tracking.c (emit_note_insn_var_location): Remove all references
19807 to NOTE_INSN_CALL_ARG_LOCATION.
19808 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
19809 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
19810 Use copy_rtx_if_shared.
19811 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
19812 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
19813 (dwarf2out_var_location): Remove handling of
19814 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
19816 * final.c (final_scan_insn): Remove all references to
19817 NOTE_INSN_CALL_ARG_LOCATION.
19818 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
19819 before dumping final insns.
19820 * except.c (emit_note_eh_region_end): Remove all references to
19821 NOTE_INSN_CALL_ARG_LOCATION.
19822 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
19823 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
19824 * config/arc/arc.c (hwloop_optimize): Likewise.
19825 * config/arm/arm.c (create_fix_barrier): Likewise.
19826 * config/s390/s390.c (s390_chunkify_start): Likewise.
19827 * config/sh/sh.c (find_barrier): Likewise.
19828 * config/i386/i386.c (rest_of_insert_endbranch,
19829 ix86_seh_fixup_eh_fallthru): Likewise.
19830 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
19831 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
19832 * config/frv/frv.c (frv_function_prologue): Likewise.
19833 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
19835 (note_outside_basic_block_p): Remove all references to
19836 NOTE_INSN_CALL_ARG_LOCATION.
19837 * gengtype.c (adjust_field_rtx_def): Likewise.
19838 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
19840 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
19841 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
19844 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
19847 PR tree-optimization/84452
19848 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
19849 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
19852 2018-02-19 Martin Liska <mliska@suse.cz>
19855 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
19857 2018-02-19 Martin Liska <mliska@suse.cz>
19858 Richard Sandiford <richard.sandiford@linaro.org>
19860 PR tree-optimization/82491
19861 * gimple-fold.c (get_base_constructor): Make earlier bail out
19864 2018-02-19 Carl Love <cel@us.ibm.com>
19866 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
19867 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
19869 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
19870 P8V_BUILTIN_VEC_NEG.
19872 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
19874 * config/rl78/rl78.md (movdf): New define expand.
19876 2018-02-19 Martin Liska <mliska@suse.cz>
19879 * doc/invoke.texi: Fix typo.
19880 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
19882 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
19884 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
19885 handle rs6000_single_float and rs6000_double_float specially for
19888 2018-02-16 Jeff Law <law@redhat.com>
19890 * config/rx/rx.c (add_pop_cfi_notes): New function.;
19891 (pop_regs): Use it.
19893 2018-02-16 Jakub Jelinek <jakub@redhat.com>
19896 * ipa-inline.c (inline_small_functions): Fix a typo.
19898 2018-02-16 Nathan Sidwell <nathan@acm.org>
19900 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
19902 2018-02-16 Carl Love <cel@us.ibm.com>
19904 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
19905 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
19906 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
19907 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
19908 expansion to P8V_BUILTIN_VEC_FLOAT2.
19910 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
19912 PR rtl-optimization/70023
19913 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
19914 src_regno into account.
19916 2018-02-16 Carl Love <cel@us.ibm.com>
19918 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
19919 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
19920 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
19921 * config/rs6000/rs6000.c: Remove case statements for
19922 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
19923 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
19924 and P9V_BUILTIN_VEC_VINSERT4B.
19925 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
19926 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
19927 * config/rs6000/vsx.md:
19928 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
19931 2018-02-16 Carl Love <cel@us.ibm.com>
19933 * config/rs6000/altivec.h: Add builtin names vec_extract4b
19935 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
19937 * config/rs6000/rs6000-c.c: Add the definitions for
19938 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
19939 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
19940 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
19941 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
19942 definition for insert4b and define insn *insert3b_internal.
19943 * doc/extend.texi: Add documentation for vec_extract4b.
19945 2018-02-16 Nathan Sidwell <nathan@acm.org>
19947 * doc/extend.texi (Backwards Compatibility): Mention friend
19948 injection. Note for-scope is deprecated.
19949 * doc/invoke.texi (-ffriend-injection): Deprecate.
19951 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
19953 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
19954 that moved to I2, also allow destinations that are a paradoxical
19955 subreg (instead of a normal reg).
19957 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
19960 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
19963 2018-02-16 Richard Biener <rguenther@suse.de>
19965 PR tree-optimization/84037
19966 PR tree-optimization/84016
19968 * config/i386/i386.c (ix86_builtin_vectorization_cost):
19969 Adjust vec_construct for the fact we need additional higher latency
19970 128bit inserts for AVX256 and AVX512 vector builds.
19971 (ix86_add_stmt_cost): Scale vector construction cost for
19974 2018-02-16 Richard Biener <rguenther@suse.de>
19976 PR tree-optimization/84417
19977 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
19978 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
19979 (non_rewritable_lvalue_p): Likewise, use poly-ints.
19981 2018-02-16 Martin Liska <mliska@suse.cz>
19984 * internal-fn.def (ASAN_CHECK): Set proper flags.
19985 (ASAN_MARK): Likewise.
19987 2018-02-16 Julia Koval <julia.koval@intel.com>
19989 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
19990 from PTA_CANNONLAKE.
19992 2018-02-16 Jakub Jelinek <jakub@redhat.com>
19995 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
19996 Use ++iter rather than iter++ for std::list iterators.
19997 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
19998 defer deleting them until all nodes in the forest are processed. Do
19999 free even leaf nodes. Change to_process into auto_vec.
20002 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
20003 * vec.h (vec_default_construct): Use memset instead of placement new
20004 if BROKEN_VALUE_INITIALIZATION is defined.
20005 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
20006 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
20009 PR rtl-optimization/83723
20010 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
20011 * lra.c (lra_substitute_pseudo): Likewise. If true, use
20012 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
20014 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
20016 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
20018 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
20020 PR rtl-optimization/81443
20021 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
20022 from inner REGs to paradoxical SUBREGs.
20024 2018-02-16 Richard Biener <rguenther@suse.de>
20026 PR tree-optimization/84399
20027 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
20028 For operands we can analyze at their definition make sure we can
20029 analyze them at each use as well.
20031 2018-02-16 Richard Biener <rguenther@suse.de>
20033 PR tree-optimization/84190
20034 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
20035 volatile accesses if the decl isn't volatile.
20037 2018-02-15 Jason Merrill <jason@redhat.com>
20039 PR c++/84314 - ICE with templates and fastcall attribute.
20040 * attribs.c (build_type_attribute_qual_variant): Don't clobber
20041 TYPE_CANONICAL on an existing type.
20043 2018-02-15 Jakub Jelinek <jakub@redhat.com>
20045 PR tree-optimization/84383
20046 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
20047 dstoff nor call operand_equal_p if dstbase is NULL.
20049 PR tree-optimization/84334
20050 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
20051 also a CONSTANT_CLASS_P, punt.
20053 2018-02-14 Jim Wilson <jimw@sifive.com>
20055 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
20056 first SMALL_OPERAND check. New local min_second_step. Move assert
20057 to where locals are set. Add TARGET_RVC support.
20058 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
20060 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
20062 * doc/invoke.texi: Correct -Wformat-overflow code sample.
20064 2018-02-14 Martin Sebor <msebor@redhat.com>
20066 PR tree-optimization/83698
20067 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
20068 arrays constrain the offset range to their bounds.
20069 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
20070 (builtin_access::overlap): Avoid setting the size of overlap if it's
20072 (maybe_diag_overlap): Also consider arrays when deciding what values
20073 of offsets to include in diagnostics.
20075 2018-02-14 Martin Sebor <msebor@redhat.com>
20078 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
20079 that correspond to the kind of a declaration.
20081 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
20084 * config/pa/pa.md: Load address of PIC label using the linkage table
20085 if the label is nonlocal.
20087 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
20089 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
20090 warning message if user requests -maltivec=be.
20091 * doc/invoke.texi: Document deprecation of -maltivec=be.
20093 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
20096 * config/rs6000/rs6000-c.c: Update definitions for
20097 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
20098 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
20100 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
20103 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
20104 add _get_ssp intrinsics. Remove argument from
20105 __builtin_ia32_rdssp[d|q].
20106 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
20107 * config/i386/i386-builtin.def: Remove argument from
20108 __builtin_ia32_rdssp[d|q].
20109 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
20110 ix86_expand_special_args_builtin for _rdssp[d|q].
20111 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
20112 Clear register before usage.
20113 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
20114 Add documentation for new _get_ssp and _inc_ssp intrinsics.
20116 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
20118 PR tree-optimization/84357
20119 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
20120 operand 1 of an ARRAY_REF too.
20122 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
20125 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
20126 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
20128 (set_of_reg): New struct.
20129 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
20130 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
20131 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
20133 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
20134 Split into bitclr, bitset, bitinvert patterns if appropriate.
20135 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
20136 use rx_fuse_in_memory_bitop.
20137 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
20138 to named insn, correct maximum insn length.
20140 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
20143 * machmode.def: Define a complex mode for PARTIAL_INT.
20144 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
20146 * doc/rtl.texi: Document CSPImode.
20147 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
20149 (msp430_hard_regno_nregs_with_padding): Likewise.
20151 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
20154 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
20156 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
20158 PR rtl-optimization/84169
20159 * combine.c (try_combine): New variable split_i2i3. Set it to true if
20160 we generated a parallel as new i3 and we split that to new i2 and i3
20161 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
20162 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
20163 those to i2, not i1. Partially rewrite this scan code.
20165 2018-02-13 Jakub Jelinek <jakub@redhat.com>
20168 * stor-layout.c (place_field): For variable length fields, adjust
20169 offset_align afterwards not just based on the field's alignment,
20170 but also on the size.
20172 PR middle-end/84309
20173 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
20174 of exps and logs in the use_exp2 case.
20176 2018-02-13 Jeff Law <law@redhat.com>
20178 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
20179 entry for "vector".
20181 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
20184 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
20188 * common.opt (gas-loc-support, gas-locview-support): New.
20189 (ginline-points, ginternal-reset-location-views): New.
20190 * doc/invoke.texi: Document them. Use @itemx where intended.
20191 (gvariable-location-views): Adjust.
20192 * target.def (reset_location_view): New.
20193 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
20194 (TARGET_RESET_LOCATION_VIEW): New.
20195 * doc/tm.texi: Rebuilt.
20196 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
20197 (dwarf2out_default_as_locview_support): New.
20198 (output_asm_line_debug_info): Use option variables.
20199 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
20200 (output_loc_list): Likewise.
20201 (add_high_low_attributes): Check option variables.
20202 Don't output entry view attribute in strict mode.
20203 (gen_inlined_subroutine_die): Check option variables.
20204 (dwarf2out_inline_entry): Likewise.
20205 (init_sections_and_labels): Likewise.
20206 (dwarf2out_early_finish): Likewise.
20207 (maybe_reset_location_view): New, from...
20208 (dwarf2out_var_location): ... here. Call it.
20209 * debug.h (dwarf2out_default_as_loc_support): Declare.
20210 (dwarf2out_default_as_locview_support): Declare.
20211 * hooks.c (hook_int_rtx_insn_0): New.
20212 * hooks.h (hook_int_rtx_insn_0): Declare.
20213 * toplev.c (process_options): Take -gas-loc-support and
20214 -gas-locview-support from dwarf2out. Enable
20215 -gvariable-location-views by default only with locview
20216 assembler support. Enable -ginternal-reset-location-views by
20217 default only if the target defines the corresponding hook.
20218 Enable -ginline-points by default if location views are
20219 enabled; force it disabled if statement frontiers are
20221 * tree-inline.c (expand_call_inline): Check option variables.
20222 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
20224 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
20226 PR tree-optimization/84321
20227 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
20228 handling. Also check whether the anti-range contains any values
20229 that satisfy the mask; switch to a VR_RANGE if not.
20231 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
20234 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
20236 2018-02-13 Martin Jambor <mjambor@suse.cz>
20239 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
20240 of call statements, also set location of a load to a temporary.
20242 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
20244 * config/rl78/rl78.c (add_vector_labels): New function.
20245 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
20246 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
20247 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
20248 which checks that no arguments are passed.
20249 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
20250 * doc/extend.texi: Documentation for the new attribute.
20252 2018-02-13 Andreas Schwab <schwab@suse.de>
20254 * config/riscv/linux.h (CPP_SPEC): Define.
20256 2018-02-13 Jakub Jelinek <jakub@redhat.com>
20259 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
20260 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
20261 OPTION_MASK_ISA_AES as first argument to def_builtin_const
20262 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
20263 instead of OPTION_MASK_ISA_PCLMUL as first argument to
20264 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
20265 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
20266 temporarily for AES and PCLMUL builtins.
20268 PR tree-optimization/84339
20269 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
20270 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
20273 PR middle-end/84309
20274 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
20275 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
20276 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
20278 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
20280 * omp-simd-clone.h: New file.
20281 * omp-simd-clone.c: Include omp-simd-clone.h.
20282 (expand_simd_clones): No longer static.
20283 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
20284 cgraph.h and omp-simd-clone.h.
20285 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
20286 (vect_recog_widen_shift_pattern): Formatting fix.
20287 (vect_pattern_recog_1): Don't check optab for calls.
20290 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
20291 operands[2] into a REG before using gen_lowpart on it.
20293 2018-02-12 Jeff Law <law@redhat.com>
20296 * config/sh/sh.c (find_barrier): Consider a sibling call
20299 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
20300 successfully back substituting a reg.
20302 2018-02-12 Richard Biener <rguenther@suse.de>
20304 PR tree-optimization/84037
20305 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
20306 parameter, move visited init to caller.
20307 (vect_slp_analyze_operations): Separate cost from validity
20308 check, initialize visited once for all instances.
20309 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
20311 * tree-vect-stmts.c (vect_model_simple_cost): Make early
20313 (vect_model_promotion_demotion_cost): Likewise.
20314 (vectorizable_bswap): Guard cost modeling with !slp_node
20315 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
20317 (vectorizable_call): Likewise.
20318 (vectorizable_conversion): Likewise.
20319 (vectorizable_assignment): Likewise.
20320 (vectorizable_shift): Likewise.
20321 (vectorizable_operation): Likewise.
20322 (vectorizable_store): Likewise.
20323 (vectorizable_load): Likewise.
20324 (vectorizable_condition): Likewise.
20325 (vectorizable_comparison): Likewise.
20327 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
20330 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
20331 (ASAN_MARK): Fix fnspec to account for return value, change pointer
20332 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
20334 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
20336 PR middle-end/83665
20337 * params.def (inline-min-speedup): Increase from 8 to 15.
20338 (max-inline-insns-auto): Decrease from 40 to 30.
20339 * ipa-split.c (consider_split): Add some buffer for function to
20340 be considered inlining candidate.
20341 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
20344 2018-02-12 Richard Biener <rguenther@suse.de>
20346 PR tree-optimization/84037
20347 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
20348 matched stmts if we cannot swap the non-matched ones.
20350 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
20352 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
20353 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
20354 _mm_maskz_scalef_round_ss): New intrinsics.
20355 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
20356 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
20357 __builtin_ia32_scalefss_round): Remove.
20358 (__builtin_ia32_scalefsd_mask_round,
20359 __builtin_ia32_scalefss_mask_round): New intrinsics.
20360 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
20361 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
20362 ((match_operand:VF_128 2 "<round_nimm_predicate>"
20363 "<round_constraint>")): Changed to ...
20364 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
20365 "<round_scalar_constraint>")): ... this.
20366 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
20367 %0, %1, %2<round_op3>}"): Changed to ...
20368 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
20369 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
20370 %2<round_scalar_mask_op3>}"): ... this.
20371 * config/i386/subst.md (round_scalar_nimm_predicate): New.
20373 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
20375 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
20376 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
20377 (_mm_maskz_sqrt_round_ss): New intrinsics.
20378 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
20379 (__builtin_ia32_sqrtsd_mask_round)
20380 (__builtin_ia32_sqrtss_mask_round): New builtins.
20381 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
20382 (__builtin_ia32_sqrtss_round): Remove.
20383 (__builtin_ia32_sqrtsd_mask_round)
20384 (__builtin_ia32_sqrtss_mask_round): New builtins.
20385 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
20386 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
20387 ((match_operand:VF_128 1 "vector_operand"
20388 "xBm,<round_constraint>")): Changed to ...
20389 ((match_operand:VF_128 1 "vector_operand"
20390 "xBm,<round_scalar_constraint>")): ... this.
20391 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
20392 %0, %2, %<iptr>1<round_op3>}): Changed to ...
20393 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
20394 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
20395 %<iptr>1<round_scalar_mask_op3>}): ... this.
20396 ((set_attr "prefix" "<round_prefix>")): Changed to ...
20397 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
20399 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
20402 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
20403 Cast vec_cmpeq result to correct type.
20404 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
20405 Cast vec_cmpgt result to correct type.
20407 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
20409 * final.c (final_scan_insn_1): Renamed from...
20410 (final_scan_insn): ... this. New wrapper, to recover
20411 seen from the outermost call in recursive ones.
20412 * config/sparc/sparc.c (output_return): Drop seen from call.
20413 (output_sibcall): Likewise.
20414 * config/visium/visium.c (output_branch): Likewise.
20416 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
20418 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
20421 2018-02-10 Alan Modra <amodra@gmail.com>
20424 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
20425 Specify LR as an input.
20427 2018-02-10 Jakub Jelinek <jakub@redhat.com>
20430 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
20431 remove_member_access_dummy_vars): New functions.
20432 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
20433 lower_omp_1, execute_lower_omp): Use them.
20435 PR rtl-optimization/84308
20436 * shrink-wrap.c (spread_components): Release todo vector.
20438 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
20440 PR rtl-optimization/57193
20441 * ira-color.c (struct allocno_color_data): Add member
20442 conflict_allocno_hard_prefs.
20443 (update_conflict_allocno_hard_prefs): New.
20444 (bucket_allocno_compare_func): Add a preference based on
20445 conflict_allocno_hard_prefs.
20446 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
20447 (color_allocnos): Remove a dead code. Initiate
20448 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
20450 2018-02-09 Jakub Jelinek <jakub@redhat.com>
20453 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
20454 constraint from =wa to wa. Avoid a subreg on the output operand,
20455 instead use a pseudo and subreg it in a move.
20456 (p9_xxbrd_<mode>): Changed to ...
20457 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
20458 (p9_xxbrd_v2df): New expander.
20459 (p9_xxbrw_<mode>): Changed to ...
20460 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
20461 (p9_xxbrw_v4sf): New expander.
20463 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
20465 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
20467 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
20470 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
20471 multiply in 32-bit mode.
20472 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
20473 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
20476 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
20478 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
20479 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
20480 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
20481 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
20483 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
20486 * dwarf2out.c (is_trivial_indirect_ref): New function.
20487 (dwarf2out_late_global_decl): Do not generate a location
20488 attribute for variables that have a non-trivial DECL_VALUE_EXPR
20489 and that are not defined in the current unit.
20491 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
20493 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
20494 instead of a libcall for UNORDERED.
20496 2018-02-09 Tamar Christina <tamar.christina@arm.com>
20499 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
20500 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
20502 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
20505 * config/s390/s390.c (s390_set_current_function): Invoke
20506 s390_indirect_branch_settings also if fndecl didn't change.
20508 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
20510 * config/rs6000/rs6000.md (blockage): Set length to zero.
20512 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
20514 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
20516 2018-02-09 Jakub Jelinek <jakub@redhat.com>
20519 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
20520 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
20524 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
20525 PARALLEL incoming that failed vt_get_decl_and_offset check.
20527 PR middle-end/84237
20528 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
20529 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
20531 (get_variable_section): For decls in named .bss* sections pass true as
20532 second argument to bss_initializer_p.
20534 2018-02-09 Marek Polacek <polacek@redhat.com>
20535 Jakub Jelinek <jakub@redhat.com>
20538 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
20539 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
20540 Sync some changes from cxx_fold_indirect_ref.
20542 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
20544 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
20546 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
20547 (BLOCK_INLINE_ENTRY_LABEL): New.
20548 (dwarf2out_var_location): Disregard inline entry markers.
20549 (inline_entry_data): New struct.
20550 (inline_entry_data_hasher): New hashtable type.
20551 (inline_entry_data_hasher::hash): New.
20552 (inline_entry_data_hasher::equal): New.
20553 (inline_entry_data_table): New variable.
20554 (add_high_low_attributes): Add DW_AT_entry_pc and
20555 DW_AT_GNU_entry_view attributes if a pending entry is found
20556 in inline_entry_data_table. Add old entry_pc attribute only
20557 if debug nonbinding markers are disabled.
20558 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
20559 markers are enabled.
20560 (block_within_block_p, dwarf2out_inline_entry): New.
20561 (dwarf2out_finish): Check that no entries remained in
20562 inline_entry_data_table.
20563 * final.c (reemit_insn_block_notes): Handle inline entry notes.
20564 (final_scan_insn, notice_source_line): Likewise.
20565 (rest_of_clean_state): Skip inline entry markers.
20566 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
20568 * gimple.c (gimple_build_debug_inline_entry): New.
20569 * gimple.h (enum gimple_debug_subcode): Add
20570 GIMPLE_DEBUG_INLINE_ENTRY.
20571 (gimple_build_debug_inline_entry): Declare.
20572 (gimple_debug_inline_entry_p): New.
20573 (gimple_debug_nonbind_marker_p): Adjust.
20574 * insn-notes.def (INLINE_ENTRY): New.
20575 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
20576 inline entry marker notes.
20577 (print_insn): Likewise.
20578 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
20579 (INSN_DEBUG_MARKER_KIND): Likewise.
20580 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
20581 * tree-inline.c (expand_call_inline): Build and insert
20582 debug_inline_entry stmt.
20583 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
20584 inline entry blocks early, if nonbind markers are enabled.
20585 (dump_scope_block): Dump fragment info.
20586 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
20587 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
20588 (gimple_build_debug_inline_entry): New.
20589 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
20590 Enable/disable inline entry points too.
20591 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
20592 (DEBUG_INSN): Describe inline entry markers.
20594 * common.opt (gvariable-location-views): New.
20595 (gvariable-location-views=incompat5): New.
20596 * config.in: Rebuilt.
20597 * configure: Rebuilt.
20598 * configure.ac: Test assembler for view support.
20599 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
20600 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
20601 * dwarf2out.c (var_loc_view): New typedef.
20602 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
20603 (dwarf2out_locviews_in_attribute): New.
20604 (dwarf2out_locviews_in_loclist): New.
20605 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
20606 (enum dw_line_info_opcode): Add LI_adv_address.
20607 (struct dw_line_info_table): Add view.
20608 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
20609 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
20610 (zero_view_p): New variable.
20611 (ZERO_VIEW_P): New macro.
20612 (output_asm_line_debug_info): New.
20613 (struct var_loc_node): Add view.
20614 (add_AT_view_list, AT_loc_list): New.
20615 (add_var_loc_to_decl): Add view param. Test it against last.
20616 (new_loc_list): Add view params. Record them.
20617 (AT_loc_list_ptr): Handle loc and view lists.
20618 (view_list_to_loc_list_val_node): New.
20619 (print_dw_val): Handle dw_val_class_view_list.
20620 (size_of_die): Likewise.
20621 (value_format): Likewise.
20622 (loc_list_has_views): New.
20623 (gen_llsym): Set vl_symbol too.
20624 (maybe_gen_llsym, skip_loc_list_entry): New.
20625 (dwarf2out_maybe_output_loclist_view_pair): New.
20626 (output_loc_list): Output view list or entries too.
20627 (output_view_list_offset): New.
20628 (output_die): Handle dw_val_class_view_list.
20629 (output_dwarf_version): New.
20630 (output_compilation_unit_header): Use it.
20631 (output_skeleton_debug_sections): Likewise.
20632 (output_rnglists, output_line_info): Likewise.
20633 (output_pubnames, output_aranges): Update version comments.
20634 (output_one_line_info_table): Output view numbers in asm comments.
20635 (dw_loc_list): Determine current endview, pass it to new_loc_list.
20636 Call maybe_gen_llsym.
20637 (loc_list_from_tree_1): Adjust.
20638 (add_AT_location_description): Create view list attribute if
20639 needed, check it's absent otherwise.
20640 (convert_cfa_to_fb_loc_list): Adjust.
20641 (maybe_emit_file): Call output_asm_line_debug_info for test.
20642 (dwarf2out_var_location): Reset views as needed. Precompute
20643 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
20644 attribute. Set view.
20645 (new_line_info_table): Reset next view.
20646 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
20647 (dwarf2out_source_line): Likewise. Output view resets and labels to
20648 the assembler, or select appropriate line info opcodes.
20649 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
20650 (optimize_string_length): Catch it. Adjust.
20651 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
20652 dw_val_class_view_list, and remove it if no longer needed.
20653 (hash_loc_list): Hash view numbers.
20654 (loc_list_hasher::equal): Compare them.
20655 (optimize_location_lists): Check whether a view list symbol is
20656 needed, and whether the locview attribute is present, and
20657 whether they match. Remove the locview attribute if no longer
20659 (index_location_lists): Call skip_loc_list_entry for test.
20660 (dwarf2out_finish): Call output_asm_line_debug_info for test.
20661 Use output_dwarf_version.
20662 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
20663 (struct dw_val_node): Add val_view_list.
20664 * final.c (SEEN_NEXT_VIEW): New.
20665 (set_next_view_needed): New.
20666 (clear_next_view_needed): New.
20667 (maybe_output_next_view): New.
20668 (final_start_function): Rename to...
20669 (final_start_function_1): ... this. Take pointer to FIRST,
20670 add SEEN parameter. Emit param bindings in the initial view.
20671 (final_start_function): Reintroduce SEEN-less interface.
20672 (final): Rename to...
20673 (final_1): ... this. Take SEEN parameter. Output final pending
20674 next view at the end.
20675 (final): Reintroduce seen-less interface.
20676 (final_scan_insn): Output pending next view before switching
20677 sections or ending a block. Mark the next view as needed when
20678 outputting variable locations. Notify debug backend of section
20679 changes, and of location view changes.
20680 (rest_of_handle_final): Adjust.
20681 * toplev.c (process_options): Autodetect value for debug variable
20682 location views option. Warn on incompat5 without -gdwarf-5.
20683 * doc/invoke.texi (gvariable-location-views): New.
20684 (gvariable-location-views=incompat5): New.
20685 (gno-variable-location-views): New.
20687 2018-02-08 David Malcolm <dmalcolm@redhat.com>
20689 PR tree-optimization/84136
20690 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
20691 that the result of find_edge is non-NULL.
20693 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
20696 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
20697 storing integer register in SImode. Fix cost of 256 and 512
20698 byte aligned SSE register store.
20700 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
20702 * config/i386/i386.c (ix86_multiplication_cost): Fix
20703 multiplication cost for TARGET_AVX512DQ.
20705 2018-02-08 Marek Polacek <polacek@redhat.com>
20707 PR tree-optimization/84238
20708 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
20711 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
20713 PR tree-optimization/84265
20714 * tree-vect-stmts.c (vectorizable_store): Don't treat
20715 VMAT_CONTIGUOUS accesses as grouped.
20716 (vectorizable_load): Likewise.
20718 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
20720 PR tree-optimization/81635
20721 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
20722 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
20723 (test_round_for_mask): New functions.
20724 (wide_int_cc_tests): Call test_round_for_mask.
20725 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
20726 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
20727 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
20728 range returned by get_range_info.
20730 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
20733 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
20734 * symtab.c: Include builtins.h
20735 (symtab_node::output_to_lto_symbol_table_p): Move here
20736 from lto-streamer-out.c:output_symbol_p.
20737 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
20738 (output_symbol_p): Move all logic to symtab.c
20739 (produce_symtab): Update.
20741 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
20743 * config/s390/s390-opts.h (enum indirect_branch): Define.
20744 * config/s390/s390-protos.h (s390_return_addr_from_memory)
20745 (s390_indirect_branch_via_thunk)
20746 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
20747 (enum s390_indirect_branch_type): Define.
20748 * config/s390/s390.c (struct s390_frame_layout, struct
20749 machine_function): Remove.
20750 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
20751 (indirect_branch_table_label_no, indirect_branch_table_name):
20753 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
20754 (enum s390_indirect_branch_option): Define.
20755 (s390_return_addr_from_memory): New function.
20756 (s390_handle_string_attribute): New function.
20757 (s390_attribute_table): Add new attribute handler.
20758 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
20759 (s390_indirect_branch_via_thunk): New function.
20760 (s390_indirect_branch_via_inline_thunk): New function.
20761 (s390_function_ok_for_sibcall): When jumping via thunk disallow
20762 sibling call optimization for non z10 compiles.
20763 (s390_emit_call): Force indirect branch target to be a single
20764 register. Add r1 clobber for non-z10 compiles.
20765 (s390_emit_epilogue): Emit return jump via return_use expander.
20766 (s390_reorg): Handle JUMP_INSNs as execute targets.
20767 (s390_option_override_internal): Perform validity checks for the
20768 new command line options.
20769 (s390_indirect_branch_attrvalue): New function.
20770 (s390_indirect_branch_settings): New function.
20771 (s390_set_current_function): Invoke s390_indirect_branch_settings.
20772 (s390_output_indirect_thunk_function): New function.
20773 (s390_code_end): Implement target hook.
20774 (s390_case_values_threshold): Implement target hook.
20775 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
20777 * config/s390/s390.h (struct s390_frame_layout)
20778 (struct machine_function): Move here from s390.c.
20779 (TARGET_INDIRECT_BRANCH_NOBP_RET)
20780 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
20781 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
20782 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
20783 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
20784 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
20785 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
20786 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
20787 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
20788 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
20789 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
20790 (mnemonic attribute): Add values which aren't recognized
20792 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
20793 pattern for branch conversion. Fix mnemonic attribute.
20794 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
20795 indirect branch via thunk if requested.
20796 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
20797 ("*indirect_jump"): Disable for branch conversion using out of
20799 ("indirect_jump_via_thunk<mode>_z10")
20800 ("indirect_jump_via_thunk<mode>")
20801 ("indirect_jump_via_inlinethunk<mode>_z10")
20802 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
20803 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
20804 ("casesi_jump_via_inlinethunk<mode>_z10")
20805 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
20806 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
20807 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
20808 ("*indirect2_jump"): Disable for branch conversion.
20809 ("casesi_jump"): Turn into expander and expand patterns for branch
20811 ("return_use"): New expander.
20812 ("*return"): Emit return via thunk and rename it to ...
20813 ("*return<mode>"): ... this one.
20814 * config/s390/s390.opt: Add new options and and enum for the
20817 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
20819 * lra-constraints.c (match_reload): Unconditionally use
20820 gen_lowpart_SUBREG, rather than selecting between that
20821 and equivalent gen_rtx_SUBREG code.
20823 2018-02-08 Richard Biener <rguenther@suse.de>
20825 PR tree-optimization/84233
20826 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
20827 changed flag instead of boguously re-using phi_inserted.
20829 2018-02-08 Martin Jambor <mjambor@suse.cz>
20831 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
20832 static local variables.
20834 2018-02-08 Richard Biener <rguenther@suse.de>
20836 PR tree-optimization/84278
20837 * tree-vect-stmts.c (vectorizable_store): When looking for
20838 smaller vector types to perform grouped strided loads/stores
20839 make sure the mode is supported by the target.
20840 (vectorizable_load): Likewise.
20842 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
20844 * config/aarch64/aarch64.c (aarch64_components_for_bb):
20845 Increase LDP/STP opportunities by adding adjacent callee-saves.
20847 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
20849 PR rtl-optimization/84068
20850 PR rtl-optimization/83459
20851 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
20853 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
20855 PR tree-optimization/84224
20856 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
20857 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
20858 non-zero arguments.
20860 2018-02-07 Iain Sandoe <iain@codesourcery.com>
20863 * config/rs6000/altivec.md (*restore_world): Remove LR use.
20864 * config/rs6000/predicates.md (restore_world_operation): Adjust op
20865 count, remove one USE.
20867 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
20869 * doc/install.texi (Configuration): Document the
20870 --with-long-double-format={ibm,ieee} PowerPC configuration
20874 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
20875 Convert from define_expand to be define_insn_and_split. Rework
20876 float/double/_Float128 conversions to QI/HI/SImode to work with
20877 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
20878 conversions to QI/HImode types did a store and then a load to
20879 truncate the value. For conversions to VSX registers, don't split
20880 the insn, instead emit the code directly. Use the code iterator
20881 any_fix to combine signed and unsigned conversions.
20882 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
20883 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
20884 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
20885 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
20886 (fix_<mode>di2_hw): Likewise.
20887 (fixuns_<mode>di2_hw): Likewise.
20888 (fix_<mode>si2_hw): Likewise.
20889 (fixuns_<mode>si2_hw): Likewise.
20890 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
20891 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
20892 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
20893 fix<uns>_trunc<SFDF:mode>si2_p8.
20894 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer used.
20895 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
20896 (fix<uns>_<mode>_mem): Likewise.
20897 (fctiw<u>z_<mode>_mem): Likewise.
20898 (fix<uns>_<mode>_mem): Likewise.
20899 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
20900 the register allocator from doing a direct move to the GPRs to do
20901 a store, and instead use the ISA 3.0 store byte/half-word from
20902 vector register instruction. For IEEE 128-bit floating point,
20903 also optimize stores of 32-bit ints.
20904 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
20906 2018-02-07 Alan Hayward <alan.hayward@arm.com>
20908 * genextract.c (push_pathstr_operand): New function to support
20910 (walk_rtx): Call push_pathstr_operand.
20911 (print_path): Support [a-zA-Z].
20913 2018-02-07 Richard Biener <rguenther@suse.de>
20915 PR tree-optimization/84037
20916 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
20917 (cse_and_gimplify_to_preheader): Declare.
20918 (vect_get_place_in_interleaving_chain): Likewise.
20919 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
20921 (_loop_vec_info::~_loop_vec_info): Delete it.
20922 (cse_and_gimplify_to_preheader): New function.
20923 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
20924 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
20925 (vectorizable_load): Likewise. For grouped stores always base
20926 the IV on the first element.
20927 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
20928 condition before gimplifying.
20930 2018-02-07 Jakub Jelinek <jakub@redhat.com>
20932 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
20933 *DIV_EXPR and *MOD_EXPR.
20935 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
20938 * config/i386/i386.c (ix86_option_override_internal): Mask out
20939 the CF_SET bit when checking -fcf-protection.
20941 2018-02-07 Tom de Vries <tom@codesourcery.com>
20944 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
20947 2018-02-07 Richard Biener <rguenther@suse.de>
20949 PR tree-optimization/84204
20950 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
20953 PR tree-optimization/84205
20954 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
20955 special-case isl_ast_op_zdiv_r.
20957 PR tree-optimization/84223
20958 * graphite-scop-detection.c (gather_bbs::before_dom_children):
20959 Only add conditions from within the region.
20960 (gather_bbs::after_dom_children): Adjust.
20962 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
20965 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
20966 * config/avr/avr.md: Only post-reload split REG-REG moves if
20967 either register is GENERAL_REG_P.
20969 2018-02-07 Jakub Jelinek <jakub@redhat.com>
20971 PR tree-optimization/84235
20972 * tree-ssa-scopedtables.c
20973 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
20974 if the subtraction is performed in floating point type where NaNs are
20975 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
20976 build 1. Formatting fix.
20978 2018-02-06 Jakub Jelinek <jakub@redhat.com>
20981 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
20982 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
20983 and skip it regardless of bb boundaries. Use CALL_P macro,
20984 don't test INSN_P (insn) together with CALL_P or JUMP_P check
20985 unnecessarily, formatting fix.
20987 2018-02-06 Michael Collison <michael.collison@arm.com>
20989 * config/arm/thumb2.md:
20990 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
20991 (*thumb_mov_notscc): Ditto.
20993 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
20996 * config/rs6000/rs6000.md (su code attribute): Use "u" for
20997 unsigned_fix, not "s".
20999 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
21001 * configure.ac (gcc_fn_eh_frame_ro): New function.
21002 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
21003 correct .eh_frame permissions.
21004 * configure: Regenerate.
21006 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
21008 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
21009 irrelevant options.
21011 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
21013 * config/rs6000/rs6000.c (rs6000_option_override_internal):
21014 Display warning message for -mno-speculate-indirect-jumps.
21016 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
21018 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
21020 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
21022 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
21024 PR tree-optimization/84225
21025 * tree-eh.c (find_trapping_overflow): Only call
21026 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
21028 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
21031 * config/i386/i386.c: Reimplement the check of possible options
21032 -mibt/-mshstk conbination. Change error messages.
21033 * doc/invoke.texi: Fix a typo: remove extra '='.
21035 2018-02-06 Marek Polacek <polacek@redhat.com>
21037 PR tree-optimization/84228
21038 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
21040 2018-02-06 Tamar Christina <tamar.christina@arm.com>
21043 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
21044 emitted arch directives.
21045 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
21046 __ARM_FEATURE_COPROC before changing architectures.
21048 2018-02-06 Richard Biener <rguenther@suse.de>
21050 * config/i386/i386.c (print_reg): Fix typo.
21051 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
21053 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
21055 * configure: Regenerate.
21057 2018-02-05 Martin Sebor <msebor@redhat.com>
21059 PR tree-optimization/83369
21060 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
21063 2018-02-05 Martin Liska <mliska@suse.cz>
21065 * doc/invoke.texi: Cherry-pick upstream r323995.
21067 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
21069 * ira.c (ira_init_register_move_cost): Adjust comment.
21071 2018-02-05 Martin Liska <mliska@suse.cz>
21073 PR gcov-profile/84137
21074 * doc/gcov.texi: Fix typo in documentation.
21076 2018-02-05 Martin Liska <mliska@suse.cz>
21078 PR gcov-profile/83879
21079 * doc/gcov.texi: Document necessity of --dynamic-list-data when
21080 using dlopen functionality.
21082 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
21084 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
21085 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
21086 _mm_maskz_range_ss, _mm_mask_range_round_ss,
21087 _mm_maskz_range_round_ss): New intrinsics.
21088 (__builtin_ia32_rangesd128_round)
21089 (__builtin_ia32_rangess128_round): Remove.
21090 (__builtin_ia32_rangesd128_mask_round,
21091 __builtin_ia32_rangess128_mask_round): New builtins.
21092 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
21093 __builtin_ia32_rangess128_round): Remove.
21094 (__builtin_ia32_rangesd128_mask_round,
21095 __builtin_ia32_rangess128_mask_round): New builtins.
21096 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
21097 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
21098 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
21099 "<round_saeonly_constraint>")): Changed to ...
21100 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
21101 "<round_saeonly_scalar_constraint>")): ... this.
21102 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
21103 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
21104 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
21105 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
21106 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
21108 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
21110 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
21112 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
21113 Remove all values except native, 8540 and 8548.
21115 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
21117 * config/i386/i386.c (ix86_output_function_return): Pass
21118 INVALID_REGNUM, instead of -1, as invalid register number to
21119 indirect_thunk_name and output_indirect_thunk.
21121 2018-02-02 Julia Koval <julia.koval@intel.com>
21123 * config.gcc: Add -march=icelake.
21124 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
21125 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
21126 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
21127 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
21128 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
21129 (processor_target_table): Add icelake.
21130 (ix86_option_override_internal): Handle new PTAs.
21131 (get_builtin_code_for_version): Handle icelake.
21132 (M_INTEL_COREI7_ICELAKE): New.
21133 (fold_builtin_cpu): Handle icelake.
21134 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
21135 * doc/invoke.texi: Add -march=icelake.
21137 2018-02-02 Julia Koval <julia.koval@intel.com>
21139 * config/i386/i386.c (ix86_option_override_internal): Change flags type
21140 to wide_int_bitmask.
21141 * wide-int-bitmask.h: New.
21143 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
21146 * config/i386/i386.md: Replace Pmode with word_mode in
21147 builtin_setjmp_setup and builtin_longjmp to support x32.
21149 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
21153 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
21155 (rs6000_supported_cpu_names): New static variable.
21156 (linux_cpu_translation_table): Likewise.
21157 (elf_platform) <cpu>: Define new static variable and use it.
21158 Translate kernel AT_PLATFORM name to canonical name if needed.
21159 Error if platform name is unknown.
21161 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
21164 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
21166 2018-02-01 Jeff Law <law@redhat.com>
21169 * config/i386/i386.c (release_scratch_register_on_entry): Add new
21170 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
21171 the scratch if RELEASE_VIA_POP is false.
21172 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
21173 If we have to save a temporary register, decrement SIZE appropriately.
21174 Pass new arguments to release_scratch_register_on_entry.
21175 (ix86_adjust_stack_and_probe): Likewise.
21176 (ix86_emit_probe_stack_range): Pass new arguments to
21177 release_scratch_register_on_entry.
21179 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
21181 PR rtl-optimization/84157
21182 * combine.c (change_zero_ext): Use REG_P predicate in
21183 front of HARD_REGISTER_P predicate.
21185 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
21187 * config/avr/avr.c (avr_option_override): Move disabling of
21188 -fdelete-null-pointer-checks to...
21189 * common/config/avr/avr-common.c (avr_option_optimization_table):
21192 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
21194 PR tree-optimization/81635
21195 * tree-data-ref.c (split_constant_offset_1): For types that
21196 wrap on overflow, try to use range info to prove that wrapping
21199 2018-02-01 Renlin Li <renlin.li@arm.com>
21202 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
21203 TAILCALL_ADDR_REGS.
21204 (aarch64_register_move_cost): Likewise.
21205 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
21206 TAILCALL_ADDR_REGS.
21207 (REG_CLASS_NAMES): Likewise.
21208 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
21209 TAILCALL_ADDR_REGS. Remove IP registers.
21210 * config/aarch64/aarch64.md (Ucs): Update register constraint.
21212 2018-02-01 Richard Biener <rguenther@suse.de>
21214 * domwalk.h (dom_walker::dom_walker): Add additional constructor
21215 for specifying RPO order and allow NULL for that.
21216 * domwalk.c (dom_walker::dom_walker): Likewise.
21217 (dom_walker::walk): Handle NULL RPO order.
21218 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
21220 (rewrite_update_dom_walker): Likewise.
21221 (mark_def_dom_walker): Likewise.
21223 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
21225 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
21226 (aarch64_maybe_expand_sve_subreg_move): Declare.
21227 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
21228 * config/aarch64/predicates.md (aarch64_any_register_operand): New
21230 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
21231 that are semantically a reverse operation.
21232 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
21233 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
21234 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
21236 (aarch64_can_change_mode_class): For big-endian, forbid changes
21237 between two SVE modes if they have different element sizes.
21239 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
21241 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
21242 the TImode handling for big-endian targets.
21244 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
21246 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
21247 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
21249 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
21250 Remove BSWAP handing for big-endian targets and use the form of
21251 LD1RQ appropariate for the mode.
21253 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
21255 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
21256 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
21257 duplicated element.
21259 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
21262 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
21263 check for operands that need to go through aarch64_sve_reload_be.
21265 2018-02-01 Jakub Jelinek <jakub@redhat.com>
21267 PR tree-optimization/81661
21268 PR tree-optimization/84117
21269 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
21270 * tree-eh.c: Include gimplify.h.
21271 (find_trapping_overflow, replace_trapping_overflow,
21272 rewrite_to_non_trapping_overflow): New functions.
21273 * tree-vect-loop.c: Include tree-eh.h.
21274 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
21275 * tree-data-ref.c: Include tree-eh.h.
21276 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
21278 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
21280 PR rtl-optimization/84123
21281 * combine.c (change_zero_ext): Check if hard register satisfies
21282 can_change_dest_mode before calling gen_lowpart_SUBREG.
21284 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
21287 * ira.c (ira_init_register_move_cost): Remove assert.
21289 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
21291 PR rtl-optimization/84071
21292 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
21293 * doc/tm.texi: Regenerate.
21295 2018-01-31 Richard Biener <rguenther@suse.de>
21297 PR tree-optimization/84132
21298 * tree-data-ref.c (analyze_miv_subscript): Properly
21299 check whether evolution_function_is_affine_multivariate_p
21300 before calling gcd_of_steps_may_divide_p.
21302 2018-01-31 Julia Koval <julia.koval@intel.com>
21305 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
21306 * config/i386/i386.md (rdpid_rex64) New.
21307 (rdpid): Make 32bit only.
21309 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
21312 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
21313 an IDENTIFIER_NODE for FUNCTION_TYPE's.
21315 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
21318 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
21320 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
21322 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
21324 PR rtl-optimization/84071
21325 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
21326 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
21328 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
21330 * config/arc/arc.c (arc_handle_aux_attribute): New function.
21331 (arc_attribute_table): Add 'aux' attribute.
21332 (arc_in_small_data_p): Consider aux like variables.
21333 (arc_is_aux_reg_p): New function.
21334 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
21335 (arc_get_aux_arg): New function.
21336 (prepare_move_operands): Handle aux-register access.
21337 (arc_handle_aux_attribute): New function.
21338 * doc/extend.texi (ARC Variable attributes): Add subsection.
21340 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
21342 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
21343 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
21344 (arc_attribute_table): Add 'uncached' attribute.
21345 (arc_print_operand): Print '.di' flag for uncached memory
21347 (arc_in_small_data_p): Do not consider for small data the uncached
21349 (arc_is_uncached_mem_p): New function.
21350 * config/arc/predicates.md (compact_store_memory_operand): Check
21351 for uncached memory accesses.
21352 (nonvol_nonimm_operand): Likewise.
21353 * doc/extend.texi (ARC Type Attribute): New subsection.
21355 2018-01-31 Jakub Jelinek <jakub@redhat.com>
21358 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
21359 falign-loops=): Add Optimization flag.
21361 2018-01-30 Jeff Law <law@redhat.com>
21364 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
21365 INT_REGISTERS_SAVED. Check it prior to calling
21366 get_scratch_register_on_entry.
21367 (ix86_adjust_stack_and_probe): Similarly.
21368 (ix86_emit_probe_stack_range): Similarly.
21369 (ix86_expand_prologue): Corresponding changes.
21371 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
21374 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
21375 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
21377 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
21380 * lra-constraints.c (curr_insn_transform): Process AND in the
21383 2018-01-30 Jakub Jelinek <jakub@redhat.com>
21385 PR rtl-optimization/83986
21386 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
21387 dependence against last_pending_memory_flush in addition to
21388 pending_jump_insns.
21390 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
21392 PR tree-optimization/81611
21393 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
21396 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
21399 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
21402 2018-01-30 Richard Biener <rguenther@suse.de>
21403 Jakub Jelinek <jakub@redhat.com>
21405 PR tree-optimization/84111
21406 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
21407 inner loops added during recursion, as they don't have up-to-date
21410 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
21413 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
21414 (can_inline_edge_by_limits_p): ... here.
21415 (can_early_inline_edge_p, check_callers,
21416 update_caller_keys, update_callee_keys, recursive_inlining,
21417 add_new_edges_to_heap, speculation_useful_p,
21418 inline_small_functions,
21419 inline_small_functions, flatten_function,
21420 inline_to_all_callers_1): Update.
21422 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
21424 * profile-count.c (profile_count::combine_with_ipa_count): Handle
21427 2018-01-30 Richard Biener <rguenther@suse.de>
21429 PR tree-optimization/83008
21430 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
21431 invariant and constant vector uses in stmts when they need
21432 more than one stmt.
21434 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
21437 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
21438 * configure: Regenerate.
21440 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
21442 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
21444 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
21445 Use gen_rtx_REG rather than gen_lowpart.
21447 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
21449 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
21450 rather than 0 when creating partial subregs.
21452 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
21454 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
21457 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
21460 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
21461 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
21462 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
21463 flags. This restores the settings used before the 2017-07-24.
21464 Turning off pre increment/decrement/modify allows IVOPTS to
21465 optimize DF/SF loops where the index is an int.
21467 2018-01-29 Richard Biener <rguenther@suse.de>
21468 Kelvin Nilsen <kelvin@gcc.gnu.org>
21471 * tree-vect-stmts.c (vectorizable_call): Don't call
21472 targetm.vectorize_builtin_md_vectorized_function if callee is
21475 2018-01-22 Carl Love <cel@us.ibm.com>
21477 * doc/extend.tex: Fix typo in second arg in
21478 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
21480 2018-01-29 Richard Biener <rguenther@suse.de>
21482 PR tree-optimization/84086
21483 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
21484 (flush_ssaname_freelist): When SSA names were released reset
21485 the SCEV hash table.
21487 2018-01-29 Richard Biener <rguenther@suse.de>
21489 PR tree-optimization/84057
21490 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
21491 removed paths when removing edges.
21493 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
21495 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
21496 -mfunction-return=@var{choice}.
21498 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
21500 PR diagnostic/84034
21501 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
21502 Handle CR like TAB.
21503 (layout::print_source_line): Likewise.
21504 (test_get_line_width_without_trailing_whitespace): Add test cases.
21506 2018-01-27 Jakub Jelinek <jakub@redhat.com>
21508 PR middle-end/84040
21509 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
21512 2018-01-26 Jim Wilson <jimw@sifive.com>
21514 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
21516 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
21519 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21521 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
21522 and CMP + SUB-immediate -> SUBS.
21524 2018-01-26 Martin Sebor <msebor@redhat.com>
21526 PR tree-optimization/83896
21527 * tree-ssa-strlen.c (get_string_len): Rename...
21528 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
21529 Avoid assuming length is constant.
21530 (handle_char_store): Use HOST_WIDE_INT for string length.
21532 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
21535 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
21536 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
21538 2018-01-26 Richard Biener <rguenther@suse.de>
21540 PR rtl-optimization/84003
21541 * dse.c (record_store): Only record redundant stores when
21542 the earlier store aliases at least all accesses the later one does.
21544 2018-01-26 Jakub Jelinek <jakub@redhat.com>
21546 PR rtl-optimization/83985
21547 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
21548 REG_CFA_RESTORE insns.
21549 (delete_unmarked_insns): Don't ignore separate shrink wrapping
21550 REG_CFA_RESTORE insns here.
21553 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
21554 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
21556 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
21558 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
21559 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
21560 (arc_init): Likewise.
21561 (arc_override_options): Likewise.
21562 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
21564 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
21566 * config/arc/arc.h (TARGET_DBNZ): Define.
21567 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
21568 properly set the tune attribute.
21569 (dbnz): Use TARGET_DBNZ guard.
21570 * config/arc/arc.opt (mtune): Add core3 option.
21572 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
21574 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
21575 recognize new pic like addresses.
21576 (arc_delegitimize_address): Clean up.
21578 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
21580 * config/arc/arc-arches.def: Option mrf16 valid for all
21582 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
21583 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
21584 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
21585 * config/arc/arc-tables.opt: Regenerate.
21586 * config/arc/arc.c (arc_conditional_register_usage): Handle
21587 reduced register file case.
21588 (arc_file_start): Set must have build attributes.
21589 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
21590 mrf16 option value.
21591 * config/arc/arc.opt (mrf16): Add new option.
21592 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
21593 * config/arc/genmultilib.awk: Handle new mrf16 option.
21594 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
21595 * config/arc/t-multilib: Regenerate.
21596 * doc/invoke.texi (ARC Options): Document mrf16 option.
21598 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
21600 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
21601 * config/arc/arc.c (arc_handle_secure_attribute): New function.
21602 (arc_attribute_table): Add 'secure_call' attribute.
21603 (arc_print_operand): Print secure call operand.
21604 (arc_function_ok_for_sibcall): Don't optimize tail calls when
21606 (arc_is_secure_call_p): New function. * config/arc/arc.md
21607 (call_i): Add support for sjli instruction.
21608 (call_value_i): Likewise.
21609 * config/arc/constraints.md (Csc): New constraint.
21611 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
21612 John Eric Martin <John.Martin@emmicro-us.com>
21614 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
21615 * config/arc/arc.c (_arc_jli_section): New struct.
21616 (arc_jli_section): New type.
21617 (rc_jli_sections): New static variable.
21618 (arc_handle_jli_attribute): New function.
21619 (arc_attribute_table): Add jli_always and jli_fixed attribute.
21620 (arc_file_end): New function.
21621 (TARGET_ASM_FILE_END): Define.
21622 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
21623 (arc_add_jli_section): New function.
21624 (jli_call_scan): Likewise.
21625 (arc_reorg): Call jli_call_scan.
21626 (arc_output_addsi): Remove 'S' from printing asm operand.
21627 (arc_is_jli_call_p): New function.
21628 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
21630 (movhi_insn): Likewise.
21631 (movsi_insn): Likewise.
21632 (movsi_set_cc_insn): Likewise.
21633 (loadqi_update): Likewise.
21634 (load_zeroextendqisi_update): Likewise.
21635 (load_signextendqisi_update): Likewise.
21636 (loadhi_update): Likewise.
21637 (load_zeroextendhisi_update): Likewise.
21638 (load_signextendhisi_update): Likewise.
21639 (loadsi_update): Likewise.
21640 (loadsf_update): Likewise.
21641 (movsicc_insn): Likewise.
21642 (bset_insn): Likewise.
21643 (bxor_insn): Likewise.
21644 (bclr_insn): Likewise.
21645 (bmsk_insn): Likewise.
21646 (bicsi3_insn): Likewise.
21647 (cmpsi_cc_c_insn): Likewise.
21648 (movsi_ne): Likewise.
21649 (movsi_cond_exec): Likewise.
21650 (clrsbsi2): Likewise.
21651 (norm_f): Likewise.
21661 (call_i): Remove 'S' asm letter, add jli instruction.
21662 (call_value_i): Likewise.
21663 * config/arc/arc.op (mjli-always): New option.
21664 * config/arc/constraints.md (Cji): New constraint.
21665 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
21667 (subsf3_fpx): Likewise.
21668 (mulsf3_fpx): Likewise.
21669 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
21671 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
21672 function attrbutes.
21673 * doc/invoke.texi (ARC): Document mjli-always option.
21675 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
21677 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
21678 avoid addition with 0 and use incw and decw where possible.
21680 2018-01-26 Richard Biener <rguenther@suse.de>
21682 PR tree-optimization/81082
21683 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
21684 association if it requires casting to unsigned.
21685 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
21686 from fold_plusminus_mult_expr to catch important cases late when
21687 range info is available.
21689 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
21691 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
21692 * configure.ac (hidden_linkonce): New test.
21693 * configure: Regenerate.
21694 * config.in: Regenerate.
21696 2018-01-26 Julia Koval <julia.koval@intel.com>
21698 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
21699 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
21700 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
21701 _mm_mask_bitshuffle_epi64_mask): Fix type.
21702 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
21703 USI_FTYPE_V4DI_V4DI_USI): Remove.
21704 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
21705 __builtin_ia32_vpshufbitqmb256_mask,
21706 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
21707 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
21708 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
21710 2018-01-26 Alan Modra <amodra@gmail.com>
21713 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
21714 UNSPEC_VBPERMQ. Sort other unspecs.
21716 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
21718 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
21720 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
21722 PR middle-end/83055
21723 * predict.c (drop_profile): Do not push/pop cfun; update also
21725 (handle_missing_profiles): Fix logic looking for zero profiles.
21727 2018-01-25 Jakub Jelinek <jakub@redhat.com>
21729 PR middle-end/83977
21730 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
21731 on functions with #pragma omp declare simd or functions with simd
21733 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
21734 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
21735 Remove trailing \n from warning_at calls.
21737 2018-01-25 Tom de Vries <tom@codesourcery.com>
21740 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
21741 for neutered workers.
21743 2018-01-24 Joseph Myers <joseph@codesourcery.com>
21746 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
21747 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
21749 2018-01-24 Jeff Law <law@redhat.com>
21752 * i386.c (get_probe_interval): Move to earlier point.
21753 (ix86_compute_frame_layout): If -fstack-clash-protection and
21754 the frame is larger than the probe interval, then use pushes
21755 to save registers rather than reg->mem moves.
21756 (ix86_expand_prologue): Remove conditional for int_registers_saved
21759 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
21762 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
21763 min/max for never referenced object.
21765 2018-01-24 Jakub Jelinek <jakub@redhat.com>
21767 PR middle-end/83977
21768 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
21770 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
21771 attributes from DECL_ATTRIBUTES (decl) without affecting
21772 DECL_ATTRIBUTES (current_function_decl).
21773 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
21774 functions with non-NULL DECL_ABSTRACT_ORIGIN.
21776 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
21778 PR tree-optimization/83979
21779 * fold-const.c (fold_comparison): Use constant_boolean_node
21780 instead of boolean_{true,false}_node.
21782 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
21784 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
21787 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
21789 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
21790 Simplify the clause that sets the length attribute.
21791 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
21792 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
21793 clause that sets the length attribute.
21794 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
21796 2018-01-24 Tom de Vries <tom@codesourcery.com>
21799 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
21800 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
21801 Add strict parameter.
21802 (prevent_branch_around_nothing): Insert dummy insn between branch to
21803 label and label with no ptx insn inbetween.
21804 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
21806 2018-01-24 Tom de Vries <tom@codesourcery.com>
21809 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
21810 for neutered threads in warp.
21811 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
21813 2018-01-24 Richard Biener <rguenther@suse.de>
21815 PR tree-optimization/83176
21816 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
21819 2018-01-24 Richard Biener <rguenther@suse.de>
21821 PR tree-optimization/82819
21822 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
21823 code generating pluses that are no-ops in the target precision.
21825 2018-01-24 Richard Biener <rguenther@suse.de>
21827 PR middle-end/84000
21828 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
21830 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
21832 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
21833 to merge probabilities.
21834 * predict.c (probably_never_executed): Also mark as cold functions
21835 with global 0 profile and guessed local profile.
21836 * profile-count.c (profile_probability::combine_with_count): New
21838 * profile-count.h (profile_probability::operator*,
21839 profile_probability::operator*=, profile_probability::operator/,
21840 profile_probability::operator/=): Reduce precision to adjusted
21841 and set value to guessed on contradictory divisions.
21842 (profile_probability::combine_with_freq): Remove.
21843 (profile_probability::combine_wiht_count): Declare.
21844 (profile_count::force_nonzero):: Set to adjusted.
21845 (profile_count::probability_in):: Set quality to adjusted.
21846 * tree-ssa-tail-merge.c (replace_block_by): Use
21847 combine_with_count.
21849 2018-01-23 Andrew Waterman <andrew@sifive.com>
21850 Jim Wilson <jimw@sifive.com>
21852 * config/riscv/riscv.c (riscv_stack_boundary): New.
21853 (riscv_option_override): Set riscv_stack_boundary. Handle
21854 riscv_preferred_stack_boundary_arg.
21855 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
21856 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
21857 (STACK_BOUNDARY): Set to riscv_stack_boundary.
21858 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
21859 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
21860 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
21862 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
21865 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
21866 of struct ix86_frame.
21867 (ix86_expand_epilogue): Likewise. Add a local variable for
21868 the reg_save_offset field in struct ix86_frame.
21870 2018-01-23 Bin Cheng <bin.cheng@arm.com>
21872 PR tree-optimization/82604
21873 * tree-loop-distribution.c (enum partition_kind): New enum item
21874 PKIND_PARTIAL_MEMSET.
21875 (partition_builtin_p): Support above new enum item.
21876 (generate_code_for_partition): Ditto.
21877 (compute_access_range): Differentiate cases that equality can be
21878 proven at all loops, the innermost loops or no loops.
21879 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
21880 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
21881 (finalize_partitions, distribute_loop): Don't fuse partition of
21882 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
21883 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
21884 parloop is enabled.
21886 2018-01-23 Martin Liska <mliska@suse.cz>
21888 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
21889 order to ignore the predictor.
21890 (PRED_POLYMORPHIC_CALL): Likewise.
21891 (PRED_RECURSIVE_CALL): Likewise.
21893 2018-01-23 Martin Liska <mliska@suse.cz>
21895 * tree-profile.c (tree_profiling): Print function header to
21896 aware reader which function we are working on.
21897 * value-prof.c (gimple_find_values_to_profile): Do not print
21898 not interesting value histograms.
21900 2018-01-23 Martin Liska <mliska@suse.cz>
21902 * profile-count.h (enum profile_quality): Add
21903 profile_uninitialized as the first value. Do not number values
21904 as they are zero based.
21905 (profile_count::verify): Update sanity check.
21906 (profile_probability::verify): Likewise.
21908 2018-01-23 Nathan Sidwell <nathan@acm.org>
21910 * doc/invoke.texi (ffor-scope): Deprecate.
21912 2018-01-23 David Malcolm <dmalcolm@redhat.com>
21914 PR tree-optimization/83510
21915 * domwalk.c (set_all_edges_as_executable): New function.
21916 (dom_walker::dom_walker): Convert bool param
21917 "skip_unreachable_blocks" to enum reachability. Move setup of
21918 edge flags to set_all_edges_as_executable and only do it when
21919 reachability is REACHABLE_BLOCKS.
21920 * domwalk.h (enum dom_walker::reachability): New enum.
21921 (dom_walker::dom_walker): Convert bool param
21922 "skip_unreachable_blocks" to enum reachability.
21923 (set_all_edges_as_executable): New decl.
21924 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
21925 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
21927 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
21928 but converting true to REACHABLE_BLOCKS.
21929 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
21931 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
21932 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
21933 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
21935 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
21936 if check_all_array_refs will be called.
21938 2018-01-23 David Malcolm <dmalcolm@redhat.com>
21940 * tree.c (selftest::test_location_wrappers): Add more test
21943 2018-01-23 David Malcolm <dmalcolm@redhat.com>
21945 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
21946 (selftest::test_bit_in_range): Likewise.
21948 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
21951 * doc/sourcebuild.texi (vect_float): Say that the selector
21952 only describes the situation when -funsafe-math-optimizations is on.
21953 (vect_float_strict): Document.
21955 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
21957 PR tree-optimization/83965
21958 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
21959 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
21960 instead of checking only for a reduction.
21961 (vect_recog_widen_sum_pattern): Likewise.
21963 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
21965 * predict.c (probably_never_executed): Only use precise profile info.
21966 (compute_function_frequency): Skip after inlining hack since we now
21967 have quality checking.
21969 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
21971 * profile-count.h (profile_probability::very_unlikely,
21972 profile_probability::unlikely, profile_probability::even): Set
21973 precision to guessed.
21975 2018-01-23 Richard Biener <rguenther@suse.de>
21977 PR tree-optimization/83963
21978 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
21979 Properly terminate dominator walk when crossing the exit edge not
21980 when visiting its source block.
21982 2018-01-23 Jakub Jelinek <jakub@redhat.com>
21985 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
21986 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
21988 2018-01-22 Jakub Jelinek <jakub@redhat.com>
21990 PR tree-optimization/83957
21991 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
21992 semicolon after for body surrounded by braces.
21994 PR tree-optimization/83081
21995 * profile-count.h (profile_probability::split): New method.
21996 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
21997 Use profile_probability::split.
21998 (do_compare_rtx_and_jump): Fix adjustment of probabilities
21999 when splitting a single conditional jump into 2.
22001 2018-01-22 David Malcolm <dmalcolm@redhat.com>
22003 PR tree-optimization/69452
22004 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
22007 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
22009 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
22010 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
22011 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
22013 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
22015 * config/rl78/rl78-protos.h (rl78_split_movdi): New function
22017 * config/rl78/rl78.md (movdi): New define_expand.
22018 * config/rl78/rl78.c (rl78_split_movdi): New function.
22020 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
22023 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
22025 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
22026 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
22027 128-bit to produce an UNSPEC move to get the double word with the
22028 signbit and then a shift directly to do signbit.
22029 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
22030 implementation with a new version that just does either a direct
22031 move or a regular move. Move memory interface to separate insns.
22032 Move insns so they are next to the expander.
22033 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
22034 with signbit move. Split big and little endian case.
22035 (signbit<mode>2_dm_mem_le): Likewise.
22036 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
22037 (signbit<mode>2_dm2): Likewise.
22039 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
22041 * config/rl78/rl78.md (anddi3): New define_expand.
22043 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
22045 * config/rl78/rl78.md (umindi3): New define_expand.
22047 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
22049 * config/rl78/rl78.md (smindi3): New define_expand.
22051 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
22053 * config/rl78/rl78.md (smaxdi3): New define_expand.
22055 2018-01-22 Carl Love <cel@us.ibm.com>
22057 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
22058 LVX_V1TI): Add macro expansion.
22059 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
22060 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
22061 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
22062 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
22063 Change check to determine if the instruction is a byte reversing
22064 entry. Fix typo in comment.
22065 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
22066 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
22067 Add def_builtin calls for new builtins.
22068 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
22069 Add define_insn expansion.
22071 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
22073 * config/rl78/rl78.md (umaxdi3): New define_expand.
22075 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
22077 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
22078 for non-QImode registers.
22080 2018-01-22 Richard Biener <rguenther@suse.de>
22082 PR tree-optimization/83963
22083 * graphite-scop-detection.c (scop_detection::get_sese): Delay
22084 including the loop exit block.
22085 (scop_detection::merge_sese): Likewise.
22086 (scop_detection::add_scop): Do it here instead.
22088 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22090 * doc/sourcebuild.texi (arm_softfloat): Document.
22092 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
22095 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
22096 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
22097 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
22099 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
22100 David Edelsohn <dje.gcc@gmail.com>
22103 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
22104 Change "crset eq" to "crset 2".
22105 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
22106 (*call_indirect_aix<mode>_nospec): Likewise.
22107 (*call_value_indirect_aix<mode>_nospec): Likewise.
22108 (*call_indirect_elfv2<mode>_nospec): Likewise.
22109 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
22110 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
22111 change assembly output from . to $.
22112 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
22113 (indirect_jump<mode>_nospec): Change assembly output from . to $.
22114 (*tablejump<mode>_internal1_nospec): Likewise.
22116 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
22119 * config/sh/sh_optimize_sett_clrt.cc:
22120 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
22122 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
22124 PR tree-optimization/83940
22125 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
22126 offset_dt to vect_constant_def rather than vect_unknown_def_type.
22127 (vect_check_load_store_mask): Add a mask_dt_out parameter and
22128 use it to pass back the definition type.
22129 (vect_check_store_rhs): Likewise rhs_dt_out.
22130 (vect_build_gather_load_calls): Add a mask_dt argument and use
22131 it instead of a call to vect_is_simple_use.
22132 (vectorizable_store): Update calls to vect_check_load_store_mask
22133 and vect_check_store_rhs. Use the dt returned by the latter instead
22134 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
22135 instead of calls to vect_is_simple_use. Pass the scalar rather
22136 than the vector operand to vect_is_simple_use when handling
22137 second and subsequent copies of an rhs value.
22138 (vectorizable_load): Update calls to vect_check_load_store_mask
22139 and vect_build_gather_load_calls. Use the cached mask_dt and
22140 gs_info.offset_dt instead of calls to vect_is_simple_use.
22142 2018-01-20 Jakub Jelinek <jakub@redhat.com>
22144 PR middle-end/83945
22145 * tree-emutls.c: Include gimplify.h.
22146 (lower_emutls_2): New function.
22147 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
22148 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
22149 it before further processing.
22152 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
22153 UINTVAL (trueop1) instead of INTVAL (op1).
22155 2018-01-19 Jakub Jelinek <jakub@redhat.com>
22159 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
22160 INCOMING_FRAME_SP_OFFSET if not defined.
22161 (scan_trace): Add ENTRY argument. If true and
22162 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
22163 emit a note to adjust the CFA offset.
22164 (create_cfi_notes): Adjust scan_trace callers.
22165 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
22166 INCOMING_FRAME_SP_OFFSET in the CIE.
22167 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
22168 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
22170 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
22171 * doc/tm.texi: Regenerated.
22173 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
22175 PR rtl-optimization/83147
22176 * lra-constraints.c (remove_inheritance_pseudos): Use
22177 lra_substitute_pseudo_within_insn.
22179 2018-01-19 Tom de Vries <tom@codesourcery.com>
22180 Cesar Philippidis <cesar@codesourcery.com>
22183 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
22185 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
22188 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
22189 spaces for function labels.
22191 2018-01-19 Martin Liska <mliska@suse.cz>
22193 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
22194 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
22195 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
22196 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
22197 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
22198 (PRED_CONST_RETURN): Change from 69 to 65.
22199 (PRED_NULL_RETURN): Change from 91 to 71.
22200 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
22201 (PRED_LOOP_GUARD): Change from 66 to 73.
22203 2018-01-19 Martin Liska <mliska@suse.cz>
22205 * predict.c (predict_insn_def): Add new assert.
22206 (struct branch_predictor): Change type to signed integer.
22207 (test_prediction_value_range): Amend test to cover
22208 PROB_UNINITIALIZED.
22209 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
22210 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
22211 (PRED_LOOP_ITERATIONS_MAX): Likewise.
22212 (PRED_LOOP_IV_COMPARE): Likewise.
22213 * predict.h (PROB_UNINITIALIZED): Define new constant.
22215 2018-01-19 Martin Liska <mliska@suse.cz>
22217 * predict.c (dump_prediction): Add new format for
22218 analyze_brprob.py script which is enabled with -details
22220 * profile-count.h (precise_p): New function.
22222 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
22224 PR tree-optimization/83922
22225 * tree-vect-loop.c (vect_verify_full_masking): Return false if
22226 there are no statements that need masking.
22227 (vect_active_double_reduction_p): New function.
22228 (vect_analyze_loop_operations): Use it when handling phis that
22229 are not in the loop header.
22231 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
22233 PR tree-optimization/83914
22234 * tree-vect-loop.c (vectorizable_induction): Don't convert
22235 init_expr or apply the peeling adjustment for inductions
22236 that are nested within the vectorized loop.
22238 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22240 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
22243 2018-01-18 Jakub Jelinek <jakub@redhat.com>
22247 * function.h (gimplify_parameters): Add gimple_seq * argument.
22248 * function.c: Include gimple.h and options.h.
22249 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
22250 for the added local temporaries if needed.
22251 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
22252 if there are any parameter cleanups, wrap whole body into a
22253 try/finally with the cleanups.
22255 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
22258 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
22259 Use GET_MODE_CLASS for scalar floating point.
22261 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
22265 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
22266 Fix call of call_cgraph_insertion_hooks.
22268 2018-01-18 Martin Sebor <msebor@redhat.com>
22270 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
22272 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
22275 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
22278 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
22281 * common.opt: (-ffile-prefix-map): New option.
22282 * opts.c (common_handle_option): Defer it.
22283 * opts-global.c (handle_common_deferred_options): Handle it.
22284 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
22285 * file-prefix-map.h: New file.
22286 (remap_debug_filename, add_debug_prefix_map): ...here.
22287 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
22288 * final.c (debug_prefix_map, add_debug_prefix_map
22289 remap_debug_filename): Move to...
22290 * file-prefix-map.c: New file.
22291 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
22292 generalize, get rid of alloca(), use strrchr() instead of strchr().
22293 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
22294 Implement in terms of add_prefix_map().
22295 (remap_macro_filename, remap_debug_filename): Implement in term of
22297 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
22298 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
22299 * dbxout.c: Include file-prefix-map.h.
22300 * varasm.c: Likewise.
22301 * vmsdbgout.c: Likewise.
22302 * xcoffout.c: Likewise.
22303 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
22304 * doc/cppopts.texi (-fmacro-prefix-map): Document.
22305 * doc/invoke.texi (-ffile-prefix-map): Document.
22306 (-fdebug-prefix-map): Update description.
22308 2018-01-18 Martin Liska <mliska@suse.cz>
22310 * config/i386/i386.c (indirect_thunk_name): Document that also
22312 (output_indirect_thunk): Document why both instructions
22313 (pause and lfence) are generated.
22315 2018-01-18 Richard Biener <rguenther@suse.de>
22317 PR tree-optimization/83887
22318 * graphite-scop-detection.c
22319 (scop_detection::get_nearest_dom_with_single_entry): Remove.
22320 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
22321 (scop_detection::merge_sese): Re-implement with a flood-fill
22322 algorithm that properly finds a SESE region if it exists.
22324 2018-01-18 Jakub Jelinek <jakub@redhat.com>
22327 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
22328 pointer_diff optimizations use view_convert instead of convert.
22330 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
22332 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
22333 Generate different code for -mno-speculate-indirect-jumps.
22334 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
22335 (*call_indirect_aix<mode>): Disable for
22336 -mno-speculate-indirect-jumps.
22337 (*call_indirect_aix<mode>_nospec): New define_insn.
22338 (*call_value_indirect_aix<mode>): Disable for
22339 -mno-speculate-indirect-jumps.
22340 (*call_value_indirect_aix<mode>_nospec): New define_insn.
22341 (*sibcall_nonlocal_sysv<mode>): Generate different code for
22342 -mno-speculate-indirect-jumps.
22343 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
22345 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
22347 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
22348 long double type, set the flags for noting the default long double
22349 type, even if we don't pass or return a long double type.
22351 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
22354 * ipa-inline.c (flatten_function): Do not overwrite final inlining
22357 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
22359 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
22360 support for merge[hl].
22361 (fold_mergehl_helper): New helper function.
22362 (tree-vector-builder.h): New #include for tree_vector_builder usage.
22363 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
22364 (altivec_vmrglw_direct): Add xxmrglw insn.
22366 2018-01-17 Andrew Waterman <andrew@sifive.com>
22368 * config/riscv/riscv.c (riscv_conditional_register_usage): If
22369 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
22371 2018-01-17 David Malcolm <dmalcolm@redhat.com>
22374 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
22375 call the lto_location_cache before reading the
22376 DECL_SOURCE_LOCATION of the types.
22378 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
22379 Richard Sandiford <richard.sandiford@linaro.org>
22381 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
22382 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
22383 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
22384 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
22385 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
22387 * config/aarch64/constraints.md (aarch64_movti_operand):
22389 * config/aarch64/predicates.md (Uti): Add new constraint.
22391 2018-01-17 Carl Love <cel@us.ibm.com>
22393 * config/rs6000/vsx.md (define_expand xl_len_r,
22394 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
22395 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
22397 (define_expand, define_insn): Move the shift left from the
22398 define_insn to the define_expand for lxvl and stxvl instructions.
22399 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
22400 and XL_LEN_R definitions to PURE.
22402 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
22404 * config/i386/i386.c (indirect_thunk_name): Declare regno
22405 as unsigned int. Compare regno with INVALID_REGNUM.
22406 (output_indirect_thunk): Ditto.
22407 (output_indirect_thunk_function): Ditto.
22408 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
22409 in the call to output_indirect_thunk_function.
22411 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
22413 PR middle-end/83884
22414 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
22415 rather than the size of inner_type to determine the stack slot size
22416 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
22418 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
22421 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
22424 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
22426 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
22427 endian Linux systems to optionally enable multilibs for selecting
22428 the long double type if the user configured an explicit type.
22429 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
22430 have no long double multilibs if not defined.
22431 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
22432 warn if the user used -mabi={ieee,ibm}longdouble and we built
22433 multilibs for long double.
22434 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
22435 appropriate multilib option.
22436 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
22438 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
22439 for building long double multilibs.
22440 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
22442 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
22444 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
22447 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
22449 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
22452 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
22455 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
22458 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
22460 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
22461 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
22463 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
22465 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
22466 different rtl trees depending on TARGET_64BIT.
22467 (rs6000_gen_lvx): Likewise.
22469 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
22471 * config/visium/visium.md (nop): Tweak comment.
22472 (hazard_nop): Likewise.
22474 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
22476 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
22477 -mspeculate-indirect-jumps.
22478 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
22479 for -mno-speculate-indirect-jumps.
22480 (*call_indirect_elfv2<mode>_nospec): New define_insn.
22481 (*call_value_indirect_elfv2<mode>): Disable for
22482 -mno-speculate-indirect-jumps.
22483 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
22484 (indirect_jump): Emit different RTL for
22485 -mno-speculate-indirect-jumps.
22486 (*indirect_jump<mode>): Disable for
22487 -mno-speculate-indirect-jumps.
22488 (*indirect_jump<mode>_nospec): New define_insn.
22489 (tablejump): Emit different RTL for
22490 -mno-speculate-indirect-jumps.
22491 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
22492 (tablejumpsi_nospec): New define_expand.
22493 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
22494 (tablejumpdi_nospec): New define_expand.
22495 (*tablejump<mode>_internal1): Disable for
22496 -mno-speculate-indirect-jumps.
22497 (*tablejump<mode>_internal1_nospec): New define_insn.
22498 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
22501 2018-01-16 Artyom Skrobov tyomitch@gmail.com
22503 * caller-save.c (insert_save): Drop unnecessary parameter. All
22506 2018-01-16 Jakub Jelinek <jakub@redhat.com>
22507 Richard Biener <rguenth@suse.de>
22510 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
22511 return early, inline manually is_gimple_sizepos. Make sure if we
22512 call gimplify_expr we don't end up with a gimple constant.
22513 * tree.c (variably_modified_type_p): Don't return true for
22514 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
22515 * gimplify.h (is_gimple_sizepos): Remove.
22517 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
22519 PR tree-optimization/83857
22520 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
22521 vectorizable_live_operation for pure SLP statements.
22522 (vectorizable_live_operation): Handle PHIs.
22524 2018-01-16 Richard Biener <rguenther@suse.de>
22526 PR tree-optimization/83867
22527 * tree-vect-stmts.c (vect_transform_stmt): Precompute
22528 nested_in_vect_loop_p since the scalar stmt may get invalidated.
22530 2018-01-16 Jakub Jelinek <jakub@redhat.com>
22533 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
22534 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
22535 If off is not INTEGER_CST, issue a may not be aligned warning
22536 rather than isn't aligned. Use isn%'t rather than isn't.
22537 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
22539 <case MULT_EXPR>: Improve the case when bottom and one of the
22540 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
22541 operand, in that case check if the other operand is multiple of
22542 bottom divided by the INTEGER_CST operand.
22544 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
22547 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
22548 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
22549 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
22550 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
22551 * config/pa/pa.c (pa_function_arg_advance): Likewise.
22552 (pa_function_arg, pa_arg_partial_bytes): Likewise.
22553 (pa_function_arg_size): New function.
22555 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
22557 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
22558 in a separate statement.
22560 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
22562 PR tree-optimization/83847
22563 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
22564 group gathers and scatters.
22566 2018-01-16 Jakub Jelinek <jakub@redhat.com>
22568 PR rtl-optimization/86620
22569 * params.def (max-sched-ready-insns): Bump minimum value to 1.
22571 PR rtl-optimization/83213
22572 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
22573 to last if both are JUMP_INSNs.
22575 PR tree-optimization/83843
22576 * gimple-ssa-store-merging.c
22577 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
22578 store_immediate_info for bswap/nop orig_stores.
22580 2018-01-15 Andrew Waterman <andrew@sifive.com>
22582 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
22584 <UDIV>: Increase cost if !TARGET_DIV.
22586 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
22588 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
22589 (define_attr "cr_logical_3op"): New.
22590 (cceq_ior_compare): Adjust.
22591 (cceq_ior_compare_complement): Adjust.
22592 (*cceq_rev_compare): Adjust.
22593 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
22594 (is_cracked_insn): Adjust.
22595 (insn_must_be_first_in_group): Adjust.
22596 * config/rs6000/40x.md: Adjust.
22597 * config/rs6000/440.md: Adjust.
22598 * config/rs6000/476.md: Adjust.
22599 * config/rs6000/601.md: Adjust.
22600 * config/rs6000/603.md: Adjust.
22601 * config/rs6000/6xx.md: Adjust.
22602 * config/rs6000/7450.md: Adjust.
22603 * config/rs6000/7xx.md: Adjust.
22604 * config/rs6000/8540.md: Adjust.
22605 * config/rs6000/cell.md: Adjust.
22606 * config/rs6000/e300c2c3.md: Adjust.
22607 * config/rs6000/e500mc.md: Adjust.
22608 * config/rs6000/e500mc64.md: Adjust.
22609 * config/rs6000/e5500.md: Adjust.
22610 * config/rs6000/e6500.md: Adjust.
22611 * config/rs6000/mpc.md: Adjust.
22612 * config/rs6000/power4.md: Adjust.
22613 * config/rs6000/power5.md: Adjust.
22614 * config/rs6000/power6.md: Adjust.
22615 * config/rs6000/power7.md: Adjust.
22616 * config/rs6000/power8.md: Adjust.
22617 * config/rs6000/power9.md: Adjust.
22618 * config/rs6000/rs64.md: Adjust.
22619 * config/rs6000/titan.md: Adjust.
22621 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
22623 * config/i386/predicates.md (indirect_branch_operand): Rewrite
22624 ix86_indirect_branch_register logic.
22626 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
22628 * config/i386/constraints.md (Bs): Update
22629 ix86_indirect_branch_register check. Don't check
22630 ix86_indirect_branch_register with GOT_memory_operand.
22632 * config/i386/predicates.md (GOT_memory_operand): Don't check
22633 ix86_indirect_branch_register here.
22634 (GOT32_symbol_operand): Likewise.
22636 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
22638 * config/i386/predicates.md (constant_call_address_operand):
22639 Rewrite ix86_indirect_branch_register logic.
22640 (sibcall_insn_operand): Likewise.
22642 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
22644 * config/i386/constraints.md (Bs): Replace
22645 ix86_indirect_branch_thunk_register with
22646 ix86_indirect_branch_register.
22648 * config/i386/i386.md (indirect_jump): Likewise.
22649 (tablejump): Likewise.
22650 (*sibcall_memory): Likewise.
22651 (*sibcall_value_memory): Likewise.
22652 Peepholes of indirect call and jump via memory: Likewise.
22653 * config/i386/i386.opt: Likewise.
22654 * config/i386/predicates.md (indirect_branch_operand): Likewise.
22655 (GOT_memory_operand): Likewise.
22656 (call_insn_operand): Likewise.
22657 (sibcall_insn_operand): Likewise.
22658 (GOT32_symbol_operand): Likewise.
22660 2018-01-15 Jakub Jelinek <jakub@redhat.com>
22662 PR middle-end/83837
22663 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
22664 type rather than type addr's type points to.
22665 (expand_omp_atomic_mutex): Likewise.
22666 (expand_omp_atomic): Likewise.
22668 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
22671 * config/i386/i386.c (output_indirect_thunk_function): Use
22672 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
22673 for __x86_return_thunk.
22675 2018-01-15 Richard Biener <rguenther@suse.de>
22677 PR middle-end/83850
22678 * expmed.c (extract_bit_field_1): Fix typo.
22680 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22683 * config/arm/iterators.md (VF): New mode iterator.
22684 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
22685 Remove integer-related logic from pattern.
22686 (neon_vabd<mode>_3): Likewise.
22688 2018-01-15 Jakub Jelinek <jakub@redhat.com>
22690 PR middle-end/82694
22691 * common.opt (fstrict-overflow): No longer an alias.
22692 (fwrapv-pointer): New option.
22693 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
22694 also for pointer types based on flag_wrapv_pointer.
22695 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
22696 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
22697 opts->x_flag_wrapv got set.
22698 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
22699 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
22700 POINTER_TYPE_OVERFLOW_UNDEFINED.
22701 * match.pd: Likewise in address comparison pattern.
22702 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
22704 2018-01-15 Richard Biener <rguenther@suse.de>
22707 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
22708 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
22709 Reset type names to their identifier if their TYPE_DECL doesn't
22710 have linkage (and thus is used for ODR and devirt).
22711 (save_debug_info_for_decl): Remove.
22712 (save_debug_info_for_type): Likewise.
22713 (add_tree_to_fld_list): Adjust.
22714 * tree-pretty-print.c (dump_generic_node): Make dumping of
22715 type names more robust.
22717 2018-01-15 Richard Biener <rguenther@suse.de>
22719 * BASE-VER: Bump to 8.0.1.
22721 2018-01-14 Martin Sebor <msebor@redhat.com>
22724 * builtins.c (check_access): Avoid warning when the no-warning bit
22727 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
22729 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
22730 * ira-color (allocno_hard_regs_compare): Likewise.
22732 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
22735 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
22736 Use .pushsection/.popsection.
22738 2018-01-14 Martin Sebor <msebor@redhat.com>
22741 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
22743 2018-01-14 Jakub Jelinek <jakub@redhat.com>
22745 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
22746 entry from extra_headers.
22747 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
22748 extra_headers, make the list bitwise identical to the i?86-*-* one.
22750 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
22752 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
22753 -mcmodel=large with -mindirect-branch=thunk,
22754 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
22755 -mfunction-return=thunk-extern.
22756 * doc/invoke.texi: Document -mcmodel=large is incompatible with
22757 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
22758 -mfunction-return=thunk and -mfunction-return=thunk-extern.
22760 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
22762 * config/i386/i386.c (print_reg): Print the name of the full
22763 integer register without '%'.
22764 (ix86_print_operand): Handle 'V'.
22765 * doc/extend.texi: Document 'V' modifier.
22767 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
22769 * config/i386/constraints.md (Bs): Disallow memory operand for
22770 -mindirect-branch-register.
22772 * config/i386/predicates.md (indirect_branch_operand): Likewise.
22773 (GOT_memory_operand): Likewise.
22774 (call_insn_operand): Likewise.
22775 (sibcall_insn_operand): Likewise.
22776 (GOT32_symbol_operand): Likewise.
22777 * config/i386/i386.md (indirect_jump): Call convert_memory_address
22778 for -mindirect-branch-register.
22779 (tablejump): Likewise.
22780 (*sibcall_memory): Likewise.
22781 (*sibcall_value_memory): Likewise.
22782 Disallow peepholes of indirect call and jump via memory for
22783 -mindirect-branch-register.
22784 (*call_pop): Replace m with Bw.
22785 (*call_value_pop): Likewise.
22786 (*sibcall_pop_memory): Replace m with Bs.
22787 * config/i386/i386.opt (mindirect-branch-register): New option.
22788 * doc/invoke.texi: Document -mindirect-branch-register option.
22790 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
22792 * config/i386/i386-protos.h (ix86_output_function_return): New.
22793 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
22794 set function_return_type.
22795 (indirect_thunk_name): Add ret_p to indicate thunk for function
22797 (output_indirect_thunk_function): Pass false to
22798 indirect_thunk_name.
22799 (ix86_output_indirect_branch_via_reg): Likewise.
22800 (ix86_output_indirect_branch_via_push): Likewise.
22801 (output_indirect_thunk_function): Create alias for function
22802 return thunk if regno < 0.
22803 (ix86_output_function_return): New function.
22804 (ix86_handle_fndecl_attribute): Handle function_return.
22805 (ix86_attribute_table): Add function_return.
22806 * config/i386/i386.h (machine_function): Add
22807 function_return_type.
22808 * config/i386/i386.md (simple_return_internal): Use
22809 ix86_output_function_return.
22810 (simple_return_internal_long): Likewise.
22811 * config/i386/i386.opt (mfunction-return=): New option.
22812 (indirect_branch): Mention -mfunction-return=.
22813 * doc/extend.texi: Document function_return function attribute.
22814 * doc/invoke.texi: Document -mfunction-return= option.
22816 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
22818 * config/i386/i386-opts.h (indirect_branch): New.
22819 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
22820 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
22821 with local indirect jump when converting indirect call and jump.
22822 (ix86_set_indirect_branch_type): New.
22823 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
22824 (indirectlabelno): New.
22825 (indirect_thunk_needed): Likewise.
22826 (indirect_thunk_bnd_needed): Likewise.
22827 (indirect_thunks_used): Likewise.
22828 (indirect_thunks_bnd_used): Likewise.
22829 (INDIRECT_LABEL): Likewise.
22830 (indirect_thunk_name): Likewise.
22831 (output_indirect_thunk): Likewise.
22832 (output_indirect_thunk_function): Likewise.
22833 (ix86_output_indirect_branch_via_reg): Likewise.
22834 (ix86_output_indirect_branch_via_push): Likewise.
22835 (ix86_output_indirect_branch): Likewise.
22836 (ix86_output_indirect_jmp): Likewise.
22837 (ix86_code_end): Call output_indirect_thunk_function if needed.
22838 (ix86_output_call_insn): Call ix86_output_indirect_branch if
22840 (ix86_handle_fndecl_attribute): Handle indirect_branch.
22841 (ix86_attribute_table): Add indirect_branch.
22842 * config/i386/i386.h (machine_function): Add indirect_branch_type
22843 and has_local_indirect_jump.
22844 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
22846 (tablejump): Likewise.
22847 (*indirect_jump): Use ix86_output_indirect_jmp.
22848 (*tablejump_1): Likewise.
22849 (simple_return_indirect_internal): Likewise.
22850 * config/i386/i386.opt (mindirect-branch=): New option.
22851 (indirect_branch): New.
22854 (thunk-inline): Likewise.
22855 (thunk-extern): Likewise.
22856 * doc/extend.texi: Document indirect_branch function attribute.
22857 * doc/invoke.texi: Document -mindirect-branch= option.
22859 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
22862 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
22864 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
22866 * ipa-inline.c (want_inline_small_function_p): Return false if
22867 inlining has already failed with CIF_FINAL_ERROR.
22868 (update_caller_keys): Call want_inline_small_function_p before
22870 (update_callee_keys): Likewise.
22872 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
22874 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
22876 (rs6000_quadword_masked_address_p): Likewise.
22877 (quad_aligned_load_p): Likewise.
22878 (quad_aligned_store_p): Likewise.
22879 (const_load_sequence_p): Add comment to describe the outer-most loop.
22880 (mimic_memory_attributes_and_flags): New function.
22881 (rs6000_gen_stvx): Likewise.
22882 (replace_swapped_aligned_store): Likewise.
22883 (rs6000_gen_lvx): Likewise.
22884 (replace_swapped_aligned_load): Likewise.
22885 (replace_swapped_load_constant): Capitalize argument name in
22886 comment describing this function.
22887 (rs6000_analyze_swaps): Add a third pass to search for vector loads
22888 and stores that access quad-word aligned addresses and replace
22889 with stvx or lvx instructions when appropriate.
22890 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
22891 New function prototype.
22892 (rs6000_quadword_masked_address_p): Likewise.
22893 (rs6000_gen_lvx): Likewise.
22894 (rs6000_gen_stvx): Likewise.
22895 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
22896 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
22897 when memory address is aligned.
22898 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
22899 this split to select lvx instruction when memory address is aligned.
22900 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
22901 instruction when memory address is aligned.
22902 (*vsx_le_perm_load_v16qi): Likewise.
22903 (four unnamed splitters): Modify to select the stvx instruction
22904 when memory is aligned.
22906 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
22908 * predict.c (determine_unlikely_bbs): Handle correctly BBs
22909 which appears in the queue multiple times.
22911 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
22912 Alan Hayward <alan.hayward@arm.com>
22913 David Sherwood <david.sherwood@arm.com>
22915 * tree-vectorizer.h (vec_lower_bound): New structure.
22916 (_loop_vec_info): Add check_nonzero and lower_bounds.
22917 (LOOP_VINFO_CHECK_NONZERO): New macro.
22918 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
22919 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
22920 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
22921 fields. Make seg_len the distance travelled, not including the
22923 (dr_direction_indicator): Declare.
22924 (dr_zero_step_indicator): Likewise.
22925 (dr_known_forward_stride_p): Likewise.
22926 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
22928 (runtime_alias_check_p): Allow runtime alias checks with
22930 (operator ==): Compare access_size and align.
22931 (prune_runtime_alias_test_list): Rework for new distinction between
22932 the access_size and seg_len.
22933 (create_intersect_range_checks_index): Likewise. Cope with polynomial
22935 (get_segment_min_max): New function.
22936 (create_intersect_range_checks): Use it.
22937 (dr_step_indicator): New function.
22938 (dr_direction_indicator): Likewise.
22939 (dr_zero_step_indicator): Likewise.
22940 (dr_known_forward_stride_p): Likewise.
22941 * tree-loop-distribution.c (data_ref_segment_size): Return
22942 DR_STEP * (niters - 1).
22943 (compute_alias_check_pairs): Update call to the dr_with_seg_len
22945 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
22946 (vect_preserves_scalar_order_p): New function, split out from...
22947 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
22948 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
22949 (vect_vfa_access_size): New function.
22950 (vect_vfa_align): Likewise.
22951 (vect_compile_time_alias): Take access_size_a and access_b arguments.
22952 (dump_lower_bound): New function.
22953 (vect_check_lower_bound): Likewise.
22954 (vect_small_gap_p): Likewise.
22955 (vectorizable_with_step_bound_p): Likewise.
22956 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
22957 depencies if the vectorization factor is 1. Convert the checks
22958 for nonzero steps into checks on the bounds of DR_STEP. Try using
22959 a bunds check for variable steps if the minimum required step is
22960 relatively small. Update calls to the dr_with_seg_len
22961 constructor and to vect_compile_time_alias.
22962 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
22964 (vect_loop_versioning): Call it.
22965 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
22967 (vect_estimate_min_profitable_iters): Account for any bounds checks.
22969 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
22970 Alan Hayward <alan.hayward@arm.com>
22971 David Sherwood <david.sherwood@arm.com>
22973 * doc/sourcebuild.texi (vect_scatter_store): Document.
22974 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
22976 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
22978 * genopinit.c (main): Add supports_vec_scatter_store and
22979 supports_vec_scatter_store_cached to target_optabs.
22980 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
22981 IFN_MASK_SCATTER_STORE.
22982 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
22984 * internal-fn.h (internal_store_fn_p): Declare.
22985 (internal_fn_stored_value_index): Likewise.
22986 * internal-fn.c (scatter_store_direct): New macro.
22987 (expand_scatter_store_optab_fn): New function.
22988 (direct_scatter_store_optab_supported_p): New macro.
22989 (internal_store_fn_p): New function.
22990 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
22991 IFN_MASK_SCATTER_STORE.
22992 (internal_fn_mask_index): Likewise.
22993 (internal_fn_stored_value_index): New function.
22994 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
22995 for scatter stores.
22996 * optabs-query.h (supports_vec_scatter_store_p): Declare.
22997 * optabs-query.c (supports_vec_scatter_store_p): New function.
22998 * tree-vectorizer.h (vect_get_store_rhs): Declare.
22999 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
23000 true for scatter stores.
23001 (vect_gather_scatter_fn_p): Handle scatter stores too.
23002 (vect_check_gather_scatter): Consider using scatter stores if
23003 supports_vec_scatter_store_p.
23004 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
23005 scatter stores too.
23006 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
23007 internal_fn_stored_value_index.
23008 (check_load_store_masking): Handle scatter stores too.
23009 (vect_get_store_rhs): Make public.
23010 (vectorizable_call): Use internal_store_fn_p.
23011 (vectorizable_store): Handle scatter store internal functions.
23012 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
23013 when deciding whether the end of the group has been reached.
23014 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
23015 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
23016 (mask_scatter_store<mode>): New insns.
23018 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23019 Alan Hayward <alan.hayward@arm.com>
23020 David Sherwood <david.sherwood@arm.com>
23022 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
23023 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
23024 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
23026 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
23027 Use vect_truncate_gather_scatter_offset if we can't treat the
23028 operation as a normal gather load or scatter store.
23029 (get_group_load_store_type): Take the gather_scatter_info
23030 as argument. Try using a gather load or scatter store for
23031 single-element groups.
23032 (get_load_store_type): Update calls to get_group_load_store_type
23033 and vect_use_strided_gather_scatters_p.
23035 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23036 Alan Hayward <alan.hayward@arm.com>
23037 David Sherwood <david.sherwood@arm.com>
23039 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
23040 optional tree argument.
23041 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
23043 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
23044 but continue to use the current value as a fallback.
23045 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
23046 to compare the updates.
23047 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
23048 (get_load_store_type): Use it when handling a strided access.
23049 (vect_get_strided_load_store_ops): New function.
23050 (vect_get_data_ptr_increment): Likewise.
23051 (vectorizable_load): Handle strided gather loads. Always pass
23052 a step to vect_create_data_ref_ptr and bump_vector_ptr.
23054 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23055 Alan Hayward <alan.hayward@arm.com>
23056 David Sherwood <david.sherwood@arm.com>
23058 * doc/md.texi (gather_load@var{m}): Document.
23059 (mask_gather_load@var{m}): Likewise.
23060 * genopinit.c (main): Add supports_vec_gather_load and
23061 supports_vec_gather_load_cached to target_optabs.
23062 * optabs-tree.c (init_tree_optimization_optabs): Use
23063 ggc_cleared_alloc to allocate target_optabs.
23064 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
23065 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
23067 * internal-fn.h (internal_load_fn_p): Declare.
23068 (internal_gather_scatter_fn_p): Likewise.
23069 (internal_fn_mask_index): Likewise.
23070 (internal_gather_scatter_fn_supported_p): Likewise.
23071 * internal-fn.c (gather_load_direct): New macro.
23072 (expand_gather_load_optab_fn): New function.
23073 (direct_gather_load_optab_supported_p): New macro.
23074 (direct_internal_fn_optab): New function.
23075 (internal_load_fn_p): Likewise.
23076 (internal_gather_scatter_fn_p): Likewise.
23077 (internal_fn_mask_index): Likewise.
23078 (internal_gather_scatter_fn_supported_p): Likewise.
23079 * optabs-query.c (supports_at_least_one_mode_p): New function.
23080 (supports_vec_gather_load_p): Likewise.
23081 * optabs-query.h (supports_vec_gather_load_p): Declare.
23082 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
23083 and memory_type field.
23084 (NUM_PATTERNS): Bump to 15.
23085 * tree-vect-data-refs.c: Include internal-fn.h.
23086 (vect_gather_scatter_fn_p): New function.
23087 (vect_describe_gather_scatter_call): Likewise.
23088 (vect_check_gather_scatter): Try using internal functions for
23089 gather loads. Recognize existing calls to a gather load function.
23090 (vect_analyze_data_refs): Consider using gather loads if
23091 supports_vec_gather_load_p.
23092 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
23093 (vect_get_gather_scatter_offset_type): Likewise.
23094 (vect_convert_mask_for_vectype): Likewise.
23095 (vect_add_conversion_to_patterm): Likewise.
23096 (vect_try_gather_scatter_pattern): Likewise.
23097 (vect_recog_gather_scatter_pattern): New pattern recognizer.
23098 (vect_vect_recog_func_ptrs): Add it.
23099 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
23100 internal_fn_mask_index and internal_gather_scatter_fn_p.
23101 (check_load_store_masking): Take the gather_scatter_info as an
23102 argument and handle gather loads.
23103 (vect_get_gather_scatter_ops): New function.
23104 (vectorizable_call): Check internal_load_fn_p.
23105 (vectorizable_load): Likewise. Handle gather load internal
23107 (vectorizable_store): Update call to check_load_store_masking.
23108 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
23109 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
23110 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
23111 (aarch64_gather_scale_operand_d): New predicates.
23112 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
23113 (mask_gather_load<mode>): New insns.
23115 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23116 Alan Hayward <alan.hayward@arm.com>
23117 David Sherwood <david.sherwood@arm.com>
23119 * optabs.def (fold_left_plus_optab): New optab.
23120 * doc/md.texi (fold_left_plus_@var{m}): Document.
23121 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
23122 * internal-fn.c (fold_left_direct): Define.
23123 (expand_fold_left_optab_fn): Likewise.
23124 (direct_fold_left_optab_supported_p): Likewise.
23125 * fold-const-call.c (fold_const_fold_left): New function.
23126 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
23127 * tree-parloops.c (valid_reduction_p): New function.
23128 (gather_scalar_reductions): Use it.
23129 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
23130 (vect_finish_replace_stmt): Declare.
23131 * tree-vect-loop.c (fold_left_reduction_fn): New function.
23132 (needs_fold_left_reduction_p): New function, split out from...
23133 (vect_is_simple_reduction): ...here. Accept reductions that
23134 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
23135 (vect_force_simple_reduction): Also store the reduction type in
23136 the assignment's STMT_VINFO_REDUC_TYPE.
23137 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
23138 (merge_with_identity): New function.
23139 (vect_expand_fold_left): Likewise.
23140 (vectorize_fold_left_reduction): Likewise.
23141 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
23142 scalar phi in place for it. Check for target support and reject
23143 cases that would reassociate the operation. Defer the transform
23144 phase to vectorize_fold_left_reduction.
23145 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
23146 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
23147 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
23149 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23151 * tree-if-conv.c (predicate_mem_writes): Remove redundant
23152 call to ifc_temp_var.
23154 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23155 Alan Hayward <alan.hayward@arm.com>
23156 David Sherwood <david.sherwood@arm.com>
23158 * target.def (legitimize_address_displacement): Take the original
23159 offset as a poly_int.
23160 * targhooks.h (default_legitimize_address_displacement): Update
23162 * targhooks.c (default_legitimize_address_displacement): Likewise.
23163 * doc/tm.texi: Regenerate.
23164 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
23165 as an argument, moving assert of ad->disp == ad->disp_term to...
23166 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
23167 Try calling targetm.legitimize_address_displacement before expanding
23168 the address rather than afterwards, and adjust for the new interface.
23169 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
23170 Match the new hook interface. Handle SVE addresses.
23171 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
23172 new hook interface.
23174 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23176 * Makefile.in (OBJS): Add early-remat.o.
23177 * target.def (select_early_remat_modes): New hook.
23178 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
23179 * doc/tm.texi: Regenerate.
23180 * targhooks.h (default_select_early_remat_modes): Declare.
23181 * targhooks.c (default_select_early_remat_modes): New function.
23182 * timevar.def (TV_EARLY_REMAT): New timevar.
23183 * passes.def (pass_early_remat): New pass.
23184 * tree-pass.h (make_pass_early_remat): Declare.
23185 * early-remat.c: New file.
23186 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
23188 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
23190 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23191 Alan Hayward <alan.hayward@arm.com>
23192 David Sherwood <david.sherwood@arm.com>
23194 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
23195 vfm1 with a bound_epilog parameter.
23196 (vect_do_peeling): Update calls accordingly, and move the prologue
23197 call earlier in the function. Treat the base bound_epilog as 0 for
23198 fully-masked loops and retain vf - 1 for other loops. Add 1 to
23199 this base when peeling for gaps.
23200 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
23201 with fully-masked loops.
23202 (vect_estimate_min_profitable_iters): Handle the single peeled
23203 iteration in that case.
23205 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23206 Alan Hayward <alan.hayward@arm.com>
23207 David Sherwood <david.sherwood@arm.com>
23209 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
23210 single-element interleaving even if the size is not a power of 2.
23211 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
23212 accesses for single-element interleaving if the group size is
23215 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23216 Alan Hayward <alan.hayward@arm.com>
23217 David Sherwood <david.sherwood@arm.com>
23219 * doc/md.texi (fold_extract_last_@var{m}): Document.
23220 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
23221 * optabs.def (fold_extract_last_optab): New optab.
23222 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
23223 * internal-fn.c (fold_extract_direct): New macro.
23224 (expand_fold_extract_optab_fn): Likewise.
23225 (direct_fold_extract_optab_supported_p): Likewise.
23226 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
23227 * tree-vect-loop.c (vect_model_reduction_cost): Handle
23228 EXTRACT_LAST_REDUCTION.
23229 (get_initial_def_for_reduction): Do not create an initial vector
23230 for EXTRACT_LAST_REDUCTION reductions.
23231 (vectorizable_reduction): Leave the scalar phi in place for
23232 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
23233 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
23234 epilogue code for EXTRACT_LAST_REDUCTION and defer the
23235 transform phase to vectorizable_condition.
23236 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
23238 (vect_finish_stmt_generation): ...here.
23239 (vect_finish_replace_stmt): New function.
23240 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
23241 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
23243 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
23245 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23246 Alan Hayward <alan.hayward@arm.com>
23247 David Sherwood <david.sherwood@arm.com>
23249 * doc/md.texi (extract_last_@var{m}): Document.
23250 * optabs.def (extract_last_optab): New optab.
23251 * internal-fn.def (EXTRACT_LAST): New internal function.
23252 * internal-fn.c (cond_unary_direct): New macro.
23253 (expand_cond_unary_optab_fn): Likewise.
23254 (direct_cond_unary_optab_supported_p): Likewise.
23255 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
23256 loops using EXTRACT_LAST.
23257 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
23258 (extract_last_<mode>): ...this optab.
23259 (vec_extract<mode><Vel>): Update accordingly.
23261 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23262 Alan Hayward <alan.hayward@arm.com>
23263 David Sherwood <david.sherwood@arm.com>
23265 * target.def (empty_mask_is_expensive): New hook.
23266 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
23267 * doc/tm.texi: Regenerate.
23268 * targhooks.h (default_empty_mask_is_expensive): Declare.
23269 * targhooks.c (default_empty_mask_is_expensive): New function.
23270 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
23271 if the target says that empty masks are expensive.
23272 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
23274 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
23276 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23277 Alan Hayward <alan.hayward@arm.com>
23278 David Sherwood <david.sherwood@arm.com>
23280 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
23281 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
23282 (vect_use_loop_mask_for_alignment_p): New function.
23283 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
23284 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
23285 niters_skip argument. Make sure that the first niters_skip elements
23286 of the first iteration are inactive.
23287 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
23288 Update call to vect_set_loop_masks_directly.
23289 (get_misalign_in_elems): New function, split out from...
23290 (vect_gen_prolog_loop_niters): ...here.
23291 (vect_update_init_of_dr): Take a code argument that specifies whether
23292 the adjustment should be added or subtracted.
23293 (vect_update_init_of_drs): Likewise.
23294 (vect_prepare_for_masked_peels): New function.
23295 (vect_do_peeling): Skip prologue peeling if we're using a mask
23296 instead. Update call to vect_update_inits_of_drs.
23297 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
23299 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
23300 alignment. Do not include the number of peeled iterations in
23301 the minimum threshold in that case.
23302 (vectorizable_induction): Adjust the start value down by
23303 LOOP_VINFO_MASK_SKIP_NITERS iterations.
23304 (vect_transform_loop): Call vect_prepare_for_masked_peels.
23305 Take the number of skipped iterations into account when calculating
23307 * tree-vect-stmts.c (vect_gen_while_not): New function.
23309 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23310 Alan Hayward <alan.hayward@arm.com>
23311 David Sherwood <david.sherwood@arm.com>
23313 * doc/sourcebuild.texi (vect_fully_masked): Document.
23314 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
23315 default value to 0.
23316 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
23318 (vect_analyze_loop_2): ...here. Don't check the vectorization
23319 factor against the number of loop iterations if the loop is
23322 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23323 Alan Hayward <alan.hayward@arm.com>
23324 David Sherwood <david.sherwood@arm.com>
23326 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
23327 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
23328 (dump_groups): Update accordingly.
23329 (iv_use::mem_type): New member variable.
23330 (address_p): New function.
23331 (record_use): Add a mem_type argument and initialize the new
23333 (record_group_use): Add a mem_type argument. Use address_p.
23334 Remove obsolete null checks of base_object. Update call to record_use.
23335 (find_interesting_uses_op): Update call to record_group_use.
23336 (find_interesting_uses_cond): Likewise.
23337 (find_interesting_uses_address): Likewise.
23338 (get_mem_type_for_internal_fn): New function.
23339 (find_address_like_use): Likewise.
23340 (find_interesting_uses_stmt): Try find_address_like_use before
23341 calling find_interesting_uses_op.
23342 (addr_offset_valid_p): Use the iv mem_type field as the type
23343 of the addressed memory.
23344 (add_autoinc_candidates): Likewise.
23345 (get_address_cost): Likewise.
23346 (split_small_address_groups_p): Use address_p.
23347 (split_address_groups): Likewise.
23348 (add_iv_candidate_for_use): Likewise.
23349 (autoinc_possible_for_pair): Likewise.
23350 (rewrite_groups): Likewise.
23351 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
23352 (determine_group_iv_cost): Update after split of USE_ADDRESS.
23353 (get_alias_ptr_type_for_ptr_address): New function.
23354 (rewrite_use_address): Rewrite address uses in calls that were
23355 identified by find_address_like_use.
23357 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23358 Alan Hayward <alan.hayward@arm.com>
23359 David Sherwood <david.sherwood@arm.com>
23361 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
23363 * gimple-expr.h (is_gimple_addressable: Likewise.
23364 * gimple-expr.c (is_gimple_address): Likewise.
23365 * internal-fn.c (expand_call_mem_ref): New function.
23366 (expand_mask_load_optab_fn): Use it.
23367 (expand_mask_store_optab_fn): Likewise.
23369 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23370 Alan Hayward <alan.hayward@arm.com>
23371 David Sherwood <david.sherwood@arm.com>
23373 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
23374 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
23375 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
23376 (cond_umax@var{mode}): Document.
23377 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
23378 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
23379 (cond_umin_optab, cond_umax_optab): New optabs.
23380 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
23381 (COND_IOR, COND_XOR): New internal functions.
23382 * internal-fn.h (get_conditional_internal_fn): Declare.
23383 * internal-fn.c (cond_binary_direct): New macro.
23384 (expand_cond_binary_optab_fn): Likewise.
23385 (direct_cond_binary_optab_supported_p): Likewise.
23386 (get_conditional_internal_fn): New function.
23387 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
23388 Cope with reduction statements that are vectorized as calls rather
23390 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
23391 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
23392 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
23393 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
23394 (UNSPEC_COND_EOR): New unspecs.
23395 (optab): Add mappings for them.
23396 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
23397 (sve_int_op, sve_fp_op): New int attributes.
23399 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23400 Alan Hayward <alan.hayward@arm.com>
23401 David Sherwood <david.sherwood@arm.com>
23403 * optabs.def (while_ult_optab): New optab.
23404 * doc/md.texi (while_ult@var{m}@var{n}): Document.
23405 * internal-fn.def (WHILE_ULT): New internal function.
23406 * internal-fn.h (direct_internal_fn_supported_p): New override
23407 that takes two types as argument.
23408 * internal-fn.c (while_direct): New macro.
23409 (expand_while_optab_fn): New function.
23410 (convert_optab_supported_p): Likewise.
23411 (direct_while_optab_supported_p): New macro.
23412 * wide-int.h (wi::udiv_ceil): New function.
23413 * tree-vectorizer.h (rgroup_masks): New structure.
23414 (vec_loop_masks): New typedef.
23415 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
23416 and fully_masked_p.
23417 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
23418 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
23419 (vect_max_vf): New function.
23420 (slpeel_make_loop_iterate_ntimes): Delete.
23421 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
23422 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
23423 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
23424 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
23425 internal-fn.h, stor-layout.h and optabs-query.h.
23426 (vect_set_loop_mask): New function.
23427 (add_preheader_seq): Likewise.
23428 (add_header_seq): Likewise.
23429 (interleave_supported_p): Likewise.
23430 (vect_maybe_permute_loop_masks): Likewise.
23431 (vect_set_loop_masks_directly): Likewise.
23432 (vect_set_loop_condition_masked): Likewise.
23433 (vect_set_loop_condition_unmasked): New function, split out from
23434 slpeel_make_loop_iterate_ntimes.
23435 (slpeel_make_loop_iterate_ntimes): Rename to..
23436 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
23437 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
23438 (vect_do_peeling): Update call accordingly.
23439 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
23441 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
23442 mask_compare_type, can_fully_mask_p and fully_masked_p.
23443 (release_vec_loop_masks): New function.
23444 (_loop_vec_info): Use it to free the loop masks.
23445 (can_produce_all_loop_masks_p): New function.
23446 (vect_get_max_nscalars_per_iter): Likewise.
23447 (vect_verify_full_masking): Likewise.
23448 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
23449 retries, and free the mask rgroups before retrying. Check loop-wide
23450 reasons for disallowing fully-masked loops. Make the final decision
23451 about whether use a fully-masked loop or not.
23452 (vect_estimate_min_profitable_iters): Do not assume that peeling
23453 for the number of iterations will be needed for fully-masked loops.
23454 (vectorizable_reduction): Disable fully-masked loops.
23455 (vectorizable_live_operation): Likewise.
23456 (vect_halve_mask_nunits): New function.
23457 (vect_double_mask_nunits): Likewise.
23458 (vect_record_loop_mask): Likewise.
23459 (vect_get_loop_mask): Likewise.
23460 (vect_transform_loop): Handle the case in which the final loop
23461 iteration might handle a partial vector. Call vect_set_loop_condition
23462 instead of slpeel_make_loop_iterate_ntimes.
23463 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
23464 (check_load_store_masking): New function.
23465 (prepare_load_store_mask): Likewise.
23466 (vectorizable_store): Handle fully-masked loops.
23467 (vectorizable_load): Likewise.
23468 (supportable_widening_operation): Use vect_halve_mask_nunits for
23470 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
23471 (vect_gen_while): New function.
23472 * config/aarch64/aarch64.md (umax<mode>3): New expander.
23473 (aarch64_uqdec<mode>): New insn.
23475 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23476 Alan Hayward <alan.hayward@arm.com>
23477 David Sherwood <david.sherwood@arm.com>
23479 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
23480 (reduc_xor_scal_optab): New optabs.
23481 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
23482 (reduc_xor_scal_@var{m}): Document.
23483 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
23484 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
23485 internal functions.
23486 * fold-const-call.c (fold_const_call): Handle them.
23487 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
23488 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
23489 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
23490 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
23491 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
23492 (UNSPEC_XORV): New unspecs.
23493 (optab): Add entries for them.
23494 (BITWISEV): New int iterator.
23495 (bit_reduc_op): New int attributes.
23497 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23498 Alan Hayward <alan.hayward@arm.com>
23499 David Sherwood <david.sherwood@arm.com>
23501 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
23502 * internal-fn.def (VEC_SHL_INSERT): New internal function.
23503 * optabs.def (vec_shl_insert_optab): New optab.
23504 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
23505 (duplicate_and_interleave): Likewise.
23506 * tree-vect-loop.c: Include internal-fn.h.
23507 (neutral_op_for_slp_reduction): New function, split out from
23508 get_initial_defs_for_reduction.
23509 (get_initial_def_for_reduction): Handle option 2 for variable-length
23510 vectors by loading the neutral value into a vector and then shifting
23511 the initial value into element 0.
23512 (get_initial_defs_for_reduction): Replace the code argument with
23513 the neutral value calculated by neutral_op_for_slp_reduction.
23514 Use gimple_build_vector for constant-length vectors.
23515 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
23516 but the first group_size elements have a neutral value.
23517 Use duplicate_and_interleave otherwise.
23518 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
23519 Update call to get_initial_defs_for_reduction. Handle SLP
23520 reductions for variable-length vectors by creating one vector
23521 result for each scalar result, with the elements associated
23522 with other scalar results stubbed out with the neutral value.
23523 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
23524 Require IFN_VEC_SHL_INSERT for double reductions on
23525 variable-length vectors, or SLP reductions that have
23526 a neutral value. Require can_duplicate_and_interleave_p
23527 support for variable-length unchained SLP reductions if there
23528 is no neutral value, such as for MIN/MAX reductions. Also require
23529 the number of vector elements to be a multiple of the number of
23530 SLP statements when doing variable-length unchained SLP reductions.
23531 Update call to vect_create_epilog_for_reduction.
23532 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
23533 and remove initial values.
23534 (duplicate_and_interleave): Make public.
23535 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
23536 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
23538 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23539 Alan Hayward <alan.hayward@arm.com>
23540 David Sherwood <david.sherwood@arm.com>
23542 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
23543 (can_duplicate_and_interleave_p): New function.
23544 (vect_get_and_check_slp_defs): Take the vector of statements
23545 rather than just the current one. Remove excess parentheses.
23546 Restriction rejectinon of vect_constant_def and vect_external_def
23547 for variable-length vectors to boolean types, or types for which
23548 can_duplicate_and_interleave_p is false.
23549 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
23550 (duplicate_and_interleave): New function.
23551 (vect_get_constant_vectors): Use gimple_build_vector for
23552 constant-length vectors and suitable variable-length constant
23553 vectors. Use duplicate_and_interleave for other variable-length
23554 vectors. Don't defer the update when inserting new statements.
23556 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23557 Alan Hayward <alan.hayward@arm.com>
23558 David Sherwood <david.sherwood@arm.com>
23560 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
23561 min_profitable_iters doesn't go negative.
23563 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23564 Alan Hayward <alan.hayward@arm.com>
23565 David Sherwood <david.sherwood@arm.com>
23567 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
23568 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
23569 * optabs.def (vec_mask_load_lanes_optab): New optab.
23570 (vec_mask_store_lanes_optab): Likewise.
23571 * internal-fn.def (MASK_LOAD_LANES): New internal function.
23572 (MASK_STORE_LANES): Likewise.
23573 * internal-fn.c (mask_load_lanes_direct): New macro.
23574 (mask_store_lanes_direct): Likewise.
23575 (expand_mask_load_optab_fn): Handle masked operations.
23576 (expand_mask_load_lanes_optab_fn): New macro.
23577 (expand_mask_store_optab_fn): Handle masked operations.
23578 (expand_mask_store_lanes_optab_fn): New macro.
23579 (direct_mask_load_lanes_optab_supported_p): Likewise.
23580 (direct_mask_store_lanes_optab_supported_p): Likewise.
23581 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
23583 (vect_load_lanes_supported): Likewise.
23584 * tree-vect-data-refs.c (strip_conversion): New function.
23585 (can_group_stmts_p): Likewise.
23586 (vect_analyze_data_ref_accesses): Use it instead of checking
23587 for a pair of assignments.
23588 (vect_store_lanes_supported): Take a masked_p parameter.
23589 (vect_load_lanes_supported): Likewise.
23590 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
23591 vect_store_lanes_supported and vect_load_lanes_supported.
23592 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
23593 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
23594 parameter. Don't allow gaps for masked accesses.
23595 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
23596 and vect_load_lanes_supported.
23597 (get_load_store_type): Take a masked_p parameter and update
23598 call to get_group_load_store_type.
23599 (vectorizable_store): Update call to get_load_store_type.
23600 Handle IFN_MASK_STORE_LANES.
23601 (vectorizable_load): Update call to get_load_store_type.
23602 Handle IFN_MASK_LOAD_LANES.
23604 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23605 Alan Hayward <alan.hayward@arm.com>
23606 David Sherwood <david.sherwood@arm.com>
23608 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
23610 * config/aarch64/aarch64-protos.h
23611 (aarch64_sve_struct_memory_operand_p): Declare.
23612 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
23613 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
23614 (VPRED, vpred): Handle SVE structure modes.
23615 * config/aarch64/constraints.md (Utx): New constraint.
23616 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
23617 (aarch64_sve_struct_nonimmediate_operand): New predicates.
23618 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
23619 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
23620 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
23621 structure modes. Split into pieces after RA.
23622 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
23623 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
23625 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
23626 SVE structure modes.
23627 (aarch64_classify_address): Likewise.
23628 (sizetochar): Move earlier in file.
23629 (aarch64_print_operand): Handle SVE register lists.
23630 (aarch64_array_mode): New function.
23631 (aarch64_sve_struct_memory_operand_p): Likewise.
23632 (TARGET_ARRAY_MODE): Redefine.
23634 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23635 Alan Hayward <alan.hayward@arm.com>
23636 David Sherwood <david.sherwood@arm.com>
23638 * target.def (array_mode): New target hook.
23639 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
23640 * doc/tm.texi: Regenerate.
23641 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
23642 * hooks.c (hook_optmode_mode_uhwi_none): New function.
23643 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
23644 targetm.array_mode.
23645 * stor-layout.c (mode_for_array): Likewise. Support polynomial
23648 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23649 Alan Hayward <alan.hayward@arm.com>
23650 David Sherwood <david.sherwood@arm.com>
23652 * fold-const.c (fold_binary_loc): Check the argument types
23653 rather than the result type when testing for a vector operation.
23655 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23657 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
23658 * doc/tm.texi: Regenerate.
23660 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23661 Alan Hayward <alan.hayward@arm.com>
23662 David Sherwood <david.sherwood@arm.com>
23664 * doc/invoke.texi (-msve-vector-bits=): Document new option.
23665 (sve): Document new AArch64 extension.
23666 * doc/md.texi (w): Extend the description of the AArch64
23667 constraint to include SVE vectors.
23668 (Upl, Upa): Document new AArch64 predicate constraints.
23669 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
23671 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
23672 (msve-vector-bits=): New option.
23673 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
23674 SVE when these are disabled.
23675 (sve): New extension.
23676 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
23677 modes. Adjust their number of units based on aarch64_sve_vg.
23678 (MAX_BITSIZE_MODE_ANY_MODE): Define.
23679 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
23680 aarch64_addr_query_type.
23681 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
23682 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
23683 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
23684 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
23685 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
23686 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
23687 (aarch64_simd_imm_zero_p): Delete.
23688 (aarch64_check_zero_based_sve_index_immediate): Declare.
23689 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
23690 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
23691 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
23692 (aarch64_sve_float_mul_immediate_p): Likewise.
23693 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
23694 rather than an rtx.
23695 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
23696 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
23697 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
23698 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
23699 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
23700 (aarch64_regmode_natural_size): Likewise.
23701 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
23702 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
23704 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
23705 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
23706 for VG and the SVE predicate registers.
23707 (V_ALIASES): Add a "z"-prefixed alias.
23708 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
23709 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
23710 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
23711 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
23712 (REG_CLASS_NAMES): Add entries for them.
23713 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
23714 and the predicate registers.
23715 (aarch64_sve_vg): Declare.
23716 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
23717 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
23718 (REGMODE_NATURAL_SIZE): Define.
23719 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
23721 * config/aarch64/aarch64.c: Include cfgrtl.h.
23722 (simd_immediate_info): Add a constructor for series vectors,
23723 and an associated step field.
23724 (aarch64_sve_vg): New variable.
23725 (aarch64_dbx_register_number): Handle VG and the predicate registers.
23726 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
23727 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
23728 (VEC_ANY_DATA, VEC_STRUCT): New constants.
23729 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
23730 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
23731 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
23732 (aarch64_get_mask_mode): New functions.
23733 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
23734 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
23735 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
23736 predicate modes and predicate registers. Explicitly restrict
23737 GPRs to modes of 16 bytes or smaller. Only allow FP registers
23738 to store a vector mode if it is recognized by
23739 aarch64_classify_vector_mode.
23740 (aarch64_regmode_natural_size): New function.
23741 (aarch64_hard_regno_caller_save_mode): Return the original mode
23743 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
23744 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
23745 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
23746 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
23748 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
23749 does not overlap dest if the function is frame-related. Handle
23751 (aarch64_split_add_offset): New function.
23752 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
23753 them aarch64_add_offset.
23754 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
23755 and update call to aarch64_sub_sp.
23756 (aarch64_add_cfa_expression): New function.
23757 (aarch64_expand_prologue): Pass extra temporary registers to the
23758 functions above. Handle the case in which we need to emit new
23759 DW_CFA_expressions for registers that were originally saved
23760 relative to the stack pointer, but now have to be expressed
23761 relative to the frame pointer.
23762 (aarch64_output_mi_thunk): Pass extra temporary registers to the
23764 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
23765 IP0 and IP1 values for SVE frames.
23766 (aarch64_expand_vec_series): New function.
23767 (aarch64_expand_sve_widened_duplicate): Likewise.
23768 (aarch64_expand_sve_const_vector): Likewise.
23769 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
23770 Handle SVE constants. Use emit_move_insn to move a force_const_mem
23771 into the register, rather than emitting a SET directly.
23772 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
23773 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
23774 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
23775 (offset_9bit_signed_scaled_p): New functions.
23776 (aarch64_replicate_bitmask_imm): New function.
23777 (aarch64_bitmask_imm): Use it.
23778 (aarch64_cannot_force_const_mem): Reject expressions involving
23779 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
23780 (aarch64_classify_index): Handle SVE indices, by requiring
23781 a plain register index with a scale that matches the element size.
23782 (aarch64_classify_address): Handle SVE addresses. Assert that
23783 the mode of the address is VOIDmode or an integer mode.
23784 Update call to aarch64_classify_symbol.
23785 (aarch64_classify_symbolic_expression): Update call to
23786 aarch64_classify_symbol.
23787 (aarch64_const_vec_all_in_range_p): New function.
23788 (aarch64_print_vector_float_operand): Likewise.
23789 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
23790 "vN" for FP registers with SVE modes. Handle (const ...) vectors
23791 and the FP immediates 1.0 and 0.5.
23792 (aarch64_print_address_internal): Handle SVE addresses.
23793 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
23794 (aarch64_regno_regclass): Handle predicate registers.
23795 (aarch64_secondary_reload): Handle big-endian reloads of SVE
23797 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
23798 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
23799 (aarch64_convert_sve_vector_bits): New function.
23800 (aarch64_override_options): Use it to handle -msve-vector-bits=.
23801 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
23802 rather than an rtx.
23803 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
23804 Handle SVE vector and predicate modes. Accept VL-based constants
23805 that need only one temporary register, and VL offsets that require
23806 no temporary registers.
23807 (aarch64_conditional_register_usage): Mark the predicate registers
23808 as fixed if SVE isn't available.
23809 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
23810 Return true for SVE vector and predicate modes.
23811 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
23812 rather than an unsigned int. Handle SVE modes.
23813 (aarch64_preferred_simd_mode): Update call accordingly. Handle
23815 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
23817 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
23818 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
23819 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
23820 (aarch64_sve_float_mul_immediate_p): New functions.
23821 (aarch64_sve_valid_immediate): New function.
23822 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
23823 Explicitly reject structure modes. Check for INDEX constants.
23824 Handle PTRUE and PFALSE constants.
23825 (aarch64_check_zero_based_sve_index_immediate): New function.
23826 (aarch64_simd_imm_zero_p): Delete.
23827 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
23828 vector modes. Accept constants in the range of CNT[BHWD].
23829 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
23830 ask for an Advanced SIMD mode.
23831 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
23832 (aarch64_simd_vector_alignment): Handle SVE predicates.
23833 (aarch64_vectorize_preferred_vector_alignment): New function.
23834 (aarch64_simd_vector_alignment_reachable): Use it instead of
23836 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
23837 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
23839 (MAX_VECT_LEN): Delete.
23840 (expand_vec_perm_d): Add a vec_flags field.
23841 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
23842 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
23843 (aarch64_evpc_ext): Don't apply a big-endian lane correction
23845 (aarch64_evpc_rev): Rename to...
23846 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
23847 (aarch64_evpc_rev_global): New function.
23848 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
23849 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
23851 (aarch64_evpc_sve_tbl): New function.
23852 (aarch64_expand_vec_perm_const_1): Update after rename of
23853 aarch64_evpc_rev. Handle SVE permutes too, trying
23854 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
23855 than aarch64_evpc_tbl.
23856 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
23857 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
23858 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
23859 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
23860 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
23861 (aarch64_expand_sve_vcond): New functions.
23862 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
23863 of aarch64_vector_mode_p.
23864 (aarch64_dwarf_poly_indeterminate_value): New function.
23865 (aarch64_compute_pressure_classes): Likewise.
23866 (aarch64_can_change_mode_class): Likewise.
23867 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
23868 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
23869 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
23870 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
23871 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
23872 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
23873 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
23874 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
23876 (Dn, Dl, Dr): Accept const as well as const_vector.
23877 (Dz): Likewise. Compare against CONST0_RTX.
23878 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
23879 of "vector" where appropriate.
23880 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
23881 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
23882 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
23883 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
23884 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
23885 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
23886 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
23887 (v_int_equiv): Extend to SVE modes.
23888 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
23890 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
23891 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
23892 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
23893 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
23894 (SVE_COND_FP_CMP): New int iterators.
23895 (perm_hilo): Handle the new unpack unspecs.
23896 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
23898 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
23899 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
23900 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
23901 (aarch64_equality_operator, aarch64_constant_vector_operand)
23902 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
23903 (aarch64_sve_nonimmediate_operand): Likewise.
23904 (aarch64_sve_general_operand): Likewise.
23905 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
23906 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
23907 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
23908 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
23909 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
23910 (aarch64_sve_float_arith_immediate): Likewise.
23911 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
23912 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
23913 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
23914 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
23915 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
23916 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
23917 (aarch64_sve_float_arith_operand): Likewise.
23918 (aarch64_sve_float_arith_with_sub_operand): Likewise.
23919 (aarch64_sve_float_mul_operand): Likewise.
23920 (aarch64_sve_vec_perm_operand): Likewise.
23921 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
23922 (aarch64_mov_operand): Accept const_poly_int and const_vector.
23923 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
23924 as well as const_vector.
23925 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
23926 in file. Use CONST0_RTX and CONSTM1_RTX.
23927 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
23928 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
23929 Use aarch64_simd_imm_zero.
23930 * config/aarch64/aarch64-sve.md: New file.
23931 * config/aarch64/aarch64.md: Include it.
23932 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
23933 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
23934 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
23935 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
23936 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
23937 (sve): New attribute.
23938 (enabled): Disable instructions with the sve attribute unless
23940 (movqi, movhi): Pass CONST_POLY_INT operaneds through
23941 aarch64_expand_mov_immediate.
23942 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
23943 CNT[BHSD] immediates.
23944 (movti): Split CONST_POLY_INT moves into two halves.
23945 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
23946 Split additions that need a temporary here if the destination
23947 is the stack pointer.
23948 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
23949 (*add<mode>3_poly_1): New instruction.
23950 (set_clobber_cc): New expander.
23952 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23954 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
23955 parameter and use it instead of GET_MODE_SIZE (innermode). Use
23956 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
23957 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
23958 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
23959 Change innermode from fixed_mode_size to machine_mode.
23960 (simplify_subreg): Update call accordingly. Handle a constant-sized
23961 subreg of a variable-length CONST_VECTOR.
23963 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
23964 Alan Hayward <alan.hayward@arm.com>
23965 David Sherwood <david.sherwood@arm.com>
23967 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
23968 (add_offset_to_base): New function, split out from...
23969 (create_mem_ref): ...here. When handling a scale other than 1,
23970 check first whether the address is valid without the offset.
23971 Add it into the base if so, leaving the index and scale as-is.
23973 2018-01-12 Jakub Jelinek <jakub@redhat.com>
23976 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
23977 fold_for_warn before checking if arg2 is INTEGER_CST.
23979 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
23981 * config/rs6000/predicates.md (load_multiple_operation): Delete.
23982 (store_multiple_operation): Delete.
23983 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
23984 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
23985 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
23986 guarded by TARGET_STRING.
23987 (rs6000_output_load_multiple): Delete.
23988 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
23989 OPTION_MASK_STRING / TARGET_STRING handling.
23990 (print_operand) <'N', 'O'>: Add comment that these are unused now.
23991 (const rs6000_opt_masks) <"string">: Change mask to 0.
23992 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
23993 (MASK_STRING): Delete.
23994 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
23996 (load_multiple): Delete.
24003 (store_multiple): Delete.
24010 (movmemsi_8reg): Delete.
24011 (corresponding unnamed define_insn): Delete.
24012 (movmemsi_6reg): Delete.
24013 (corresponding unnamed define_insn): Delete.
24014 (movmemsi_4reg): Delete.
24015 (corresponding unnamed define_insn): Delete.
24016 (movmemsi_2reg): Delete.
24017 (corresponding unnamed define_insn): Delete.
24018 (movmemsi_1reg): Delete.
24019 (corresponding unnamed define_insn): Delete.
24020 * config/rs6000/rs6000.opt (mno-string): New.
24021 (mstring): Replace by deprecation warning stub.
24022 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
24024 2018-01-12 Jakub Jelinek <jakub@redhat.com>
24026 * regrename.c (regrename_do_replace): If replacing the same
24027 reg multiple times, try to reuse last created gen_raw_REG.
24030 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
24031 main to workaround a bug in GDB.
24033 2018-01-12 Tom de Vries <tom@codesourcery.com>
24036 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
24038 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
24040 PR rtl-optimization/80481
24041 * ira-color.c (get_cap_member): New function.
24042 (allocnos_conflict_by_live_ranges_p): Use it.
24043 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
24044 (setup_slot_coalesced_allocno_live_ranges): Ditto.
24046 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
24049 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
24050 (*saddl_se_1): Ditto.
24051 (*ssubsi_1): Ditto.
24052 (*ssubl_se_1): Ditto.
24054 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
24056 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
24057 rather than wi::to_widest for DR_INITs.
24058 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
24059 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
24060 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
24062 (vect_analyze_group_access_1): Note that here.
24064 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
24066 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
24067 polynomial type sizes.
24069 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
24071 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
24072 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
24073 (gimple_add_tmp_var): Likewise.
24075 2018-01-12 Martin Liska <mliska@suse.cz>
24077 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
24078 (gimple_alloc_sizes): Likewise.
24079 (dump_gimple_statistics): Use PRIu64 in printf format.
24080 * gimple.h: Change uint64_t to int.
24082 2018-01-12 Martin Liska <mliska@suse.cz>
24084 * tree-core.h: Use uint64_t instead of int.
24085 * tree.c (tree_node_counts): Likewise.
24086 (tree_node_sizes): Likewise.
24087 (dump_tree_statistics): Use PRIu64 in printf format.
24089 2018-01-12 Martin Liska <mliska@suse.cz>
24091 * Makefile.in: As qsort_chk is implemented in vec.c, add
24092 vec.o to linkage of gencfn-macros.
24093 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
24094 passing the info to record_node_allocation_statistics.
24095 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
24097 * ggc-common.c (struct ggc_usage): Add operator== and use
24098 it in operator< and compare function.
24099 * mem-stats.h (struct mem_usage): Likewise.
24100 * vec.c (struct vec_usage): Remove operator< and compare
24101 function. Can be simply inherited.
24103 2018-01-12 Martin Jambor <mjambor@suse.cz>
24106 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
24107 * tree-ssa-math-opts.c: Include domwalk.h.
24108 (convert_mult_to_fma_1): New function.
24109 (fma_transformation_info): New type.
24110 (fma_deferring_state): Likewise.
24111 (cancel_fma_deferring): New function.
24112 (result_of_phi): Likewise.
24113 (last_fma_candidate_feeds_initial_phi): Likewise.
24114 (convert_mult_to_fma): Added deferring logic, split actual
24115 transformation to convert_mult_to_fma_1.
24116 (math_opts_dom_walker): New type.
24117 (math_opts_dom_walker::after_dom_children): New method, body moved
24118 here from pass_optimize_widening_mul::execute, added deferring logic
24120 (pass_optimize_widening_mul::execute): Moved most of code to
24121 math_opts_dom_walker::after_dom_children.
24122 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
24123 * config/i386/i386.c (ix86_option_override_internal): Added
24124 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
24126 2018-01-12 Richard Biener <rguenther@suse.de>
24129 * dwarf2out.c (gen_variable_die): Do not reset old_die for
24130 inline instance vars.
24132 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
24135 * config/rx/rx.c (rx_is_restricted_memory_address):
24136 Handle SUBREG case.
24138 2018-01-12 Richard Biener <rguenther@suse.de>
24140 PR tree-optimization/80846
24141 * target.def (split_reduction): New target hook.
24142 * targhooks.c (default_split_reduction): New function.
24143 * targhooks.h (default_split_reduction): Declare.
24144 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
24145 target requests first reduce vectors by combining low and high
24147 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
24148 (get_vectype_for_scalar_type_and_size): Export.
24149 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
24150 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
24151 * doc/tm.texi: Regenerate.
24152 * config/i386/i386.c (ix86_split_reduction): Implement
24153 TARGET_VECTORIZE_SPLIT_REDUCTION.
24155 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
24158 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
24159 in PIC mode except for TARGET_VXWORKS_RTP.
24160 * config/sparc/sparc.c: Include cfgrtl.h.
24161 (TARGET_INIT_PIC_REG): Define.
24162 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
24163 (sparc_pic_register_p): New predicate.
24164 (sparc_legitimate_address_p): Use it.
24165 (sparc_legitimize_pic_address): Likewise.
24166 (sparc_delegitimize_address): Likewise.
24167 (sparc_mode_dependent_address_p): Likewise.
24168 (gen_load_pcrel_sym): Remove 4th parameter.
24169 (load_got_register): Adjust call to above. Remove obsolete stuff.
24170 (sparc_expand_prologue): Do not call load_got_register here.
24171 (sparc_flat_expand_prologue): Likewise.
24172 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
24173 (sparc_use_pseudo_pic_reg): New function.
24174 (sparc_init_pic_reg): Likewise.
24175 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
24176 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
24178 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
24180 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
24181 Add item for branch_cost.
24183 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
24185 PR rtl-optimization/83565
24186 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
24187 not extend the result to a larger mode for rotate operations.
24188 (num_sign_bit_copies1): Likewise.
24190 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24193 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
24195 Use values-Xc.o for -pedantic.
24196 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
24198 2018-01-12 Martin Liska <mliska@suse.cz>
24201 * ipa-devirt.c (final_warning_record::grow_type_warnings):
24203 (possible_polymorphic_call_targets): Use it.
24204 (ipa_devirt): Likewise.
24206 2018-01-12 Martin Liska <mliska@suse.cz>
24208 * profile-count.h (enum profile_quality): Use 0 as invalid
24209 enum value of profile_quality.
24211 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
24213 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
24214 -mext-string options.
24216 2018-01-12 Richard Biener <rguenther@suse.de>
24218 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
24219 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
24220 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
24222 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
24224 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
24226 * configure.ac (--with-long-double-format): Add support for the
24227 configuration option to change the default long double format on
24229 * config.gcc (powerpc*-linux*-*): Likewise.
24230 * configure: Regenerate.
24231 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
24232 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
24233 used without modification.
24235 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24237 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
24238 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
24239 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
24240 MISC_BUILTIN_SPEC_BARRIER.
24241 (rs6000_init_builtins): Likewise.
24242 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
24244 (speculation_barrier): New define_insn.
24245 * doc/extend.texi: Document __builtin_speculation_barrier.
24247 2018-01-11 Jakub Jelinek <jakub@redhat.com>
24250 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
24251 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
24252 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
24254 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
24255 integral modes instead of "ss" and "sd".
24256 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
24257 vectors with 32-bit and 64-bit elements.
24258 (vecdupssescalarmodesuffix): New mode attribute.
24259 (vec_dup<mode>): Use it.
24261 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
24264 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
24265 frame if argument is passed on stack.
24267 2018-01-11 Jakub Jelinek <jakub@redhat.com>
24270 * ree.c (combine_reaching_defs): Optimize also
24271 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
24272 reg2=any_extend(exp); reg1=reg2;, formatting fix.
24274 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
24276 PR middle-end/83189
24277 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
24279 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
24281 PR middle-end/83718
24282 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
24283 after they are computed.
24285 2018-01-11 Bin Cheng <bin.cheng@arm.com>
24287 PR tree-optimization/83695
24288 * gimple-loop-linterchange.cc
24289 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
24290 reset cached scev information after interchange.
24291 (pass_linterchange::execute): Remove call to scev_reset_htab.
24293 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24295 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
24296 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
24297 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
24298 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
24299 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
24300 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
24301 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
24302 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
24303 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
24304 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
24305 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
24306 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
24307 (V_lane_reg): Likewise.
24308 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
24310 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
24311 (vfmal_lane_low<mode>_intrinsic,
24312 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
24313 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
24314 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
24315 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
24316 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
24317 vfmsl_lane_high<mode>_intrinsic): New define_insns.
24319 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24321 * config/arm/arm-cpus.in (fp16fml): New feature.
24322 (ALL_SIMD): Add fp16fml.
24323 (armv8.2-a): Add fp16fml as an option.
24324 (armv8.3-a): Likewise.
24325 (armv8.4-a): Add fp16fml as part of fp16.
24326 * config/arm/arm.h (TARGET_FP16FML): Define.
24327 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
24329 * config/arm/arm-modes.def (V2HF): Define.
24330 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
24331 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
24332 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
24333 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
24334 vfmsl_low, vfmsl_high): New set of builtins.
24335 * config/arm/iterators.md (PLUSMINUS): New code iterator.
24336 (vfml_op): New code attribute.
24337 (VFMLHALVES): New int iterator.
24338 (VFML, VFMLSEL): New mode attributes.
24339 (V_reg): Define mapping for V2HF.
24340 (V_hi, V_lo): New mode attributes.
24341 (VF_constraint): Likewise.
24342 (vfml_half, vfml_half_selector): New int attributes.
24343 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
24345 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
24346 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
24348 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
24349 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
24350 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
24351 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
24353 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
24354 Document new effective target and option set.
24356 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24358 * config/arm/arm-cpus.in (armv8_4): New feature.
24359 (ARMv8_4a): New fgroup.
24360 (armv8.4-a): New arch.
24361 * config/arm/arm-tables.opt: Regenerate.
24362 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
24363 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
24364 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
24365 Add matching rules for -march=armv8.4-a and extensions.
24366 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
24368 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
24371 * config/rx/rx.md (BW): New mode attribute.
24372 (sync_lock_test_and_setsi): Add mode suffix to insn output.
24374 2018-01-11 Richard Biener <rguenther@suse.de>
24376 PR tree-optimization/83435
24377 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
24378 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
24379 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
24381 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
24382 Alan Hayward <alan.hayward@arm.com>
24383 David Sherwood <david.sherwood@arm.com>
24385 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
24387 (aarch64_classify_address): Initialize it. Track polynomial offsets.
24388 (aarch64_print_address_internal): Use it to check for a zero offset.
24390 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
24391 Alan Hayward <alan.hayward@arm.com>
24392 David Sherwood <david.sherwood@arm.com>
24394 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
24395 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
24396 Return a poly_int64 rather than a HOST_WIDE_INT.
24397 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
24398 rather than a HOST_WIDE_INT.
24399 * config/aarch64/aarch64.h (aarch64_frame): Protect with
24400 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
24401 hard_fp_offset, frame_size, initial_adjust, callee_offset and
24402 final_offset from HOST_WIDE_INT to poly_int64.
24403 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
24404 to_constant when getting the number of units in an Advanced SIMD
24406 (aarch64_builtin_vectorized_function): Check for a constant number
24408 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
24410 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
24411 attribute instead of GET_MODE_NUNITS.
24412 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
24413 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
24414 GET_MODE_SIZE for fixed-size registers.
24415 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
24416 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
24417 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
24418 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
24419 (aarch64_print_operand, aarch64_print_address_internal)
24420 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
24421 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
24422 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
24423 Handle polynomial GET_MODE_SIZE.
24424 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
24425 wider than SImode without modification.
24426 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
24427 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
24428 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
24429 passing and returning SVE modes.
24430 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
24431 rather than GEN_INT.
24432 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
24433 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
24434 (aarch64_allocate_and_probe_stack_space): Likewise.
24435 (aarch64_layout_frame): Cope with polynomial offsets.
24436 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
24437 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
24438 polynomial offsets.
24439 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
24440 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
24441 poly_int64 rather than a HOST_WIDE_INT.
24442 (aarch64_get_separate_components, aarch64_process_components)
24443 (aarch64_expand_prologue, aarch64_expand_epilogue)
24444 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
24445 (aarch64_anchor_offset): New function, split out from...
24446 (aarch64_legitimize_address): ...here.
24447 (aarch64_builtin_vectorization_cost): Handle polynomial
24448 TYPE_VECTOR_SUBPARTS.
24449 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
24451 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
24452 number of elements from the PARALLEL rather than the mode.
24453 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
24454 rather than GET_MODE_BITSIZE.
24455 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
24456 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
24457 (aarch64_expand_vec_perm_const_1): Handle polynomial
24458 d->perm.length () and d->perm elements.
24459 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
24460 Apply to_constant to d->perm elements.
24461 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
24462 polynomial CONST_VECTOR_NUNITS.
24463 (aarch64_move_pointer): Take amount as a poly_int64 rather
24465 (aarch64_progress_pointer): Avoid temporary variable.
24466 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
24467 the mode attribute instead of GET_MODE.
24469 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
24470 Alan Hayward <alan.hayward@arm.com>
24471 David Sherwood <david.sherwood@arm.com>
24473 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
24474 x exists before using it.
24475 (aarch64_add_constant_internal): Rename to...
24476 (aarch64_add_offset_1): ...this. Replace regnum with separate
24477 src and dest rtxes. Handle the case in which they're different,
24478 including when the offset is zero. Replace scratchreg with an rtx.
24479 Use 2 additions if there is no spare register into which we can
24480 move a 16-bit constant.
24481 (aarch64_add_constant): Delete.
24482 (aarch64_add_offset): Replace reg with separate src and dest
24483 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
24484 Use aarch64_add_offset_1.
24485 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
24486 an rtx rather than an int. Take the delta as a poly_int64
24487 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
24488 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
24489 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
24490 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
24491 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
24492 and aarch64_add_sp.
24493 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
24494 aarch64_add_constant.
24496 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
24498 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
24499 Use scalar_float_mode.
24501 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
24503 * config/aarch64/aarch64-simd.md
24504 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
24505 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
24506 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
24507 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
24508 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
24509 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
24510 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
24511 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
24512 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
24513 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
24515 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
24518 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
24519 targ_options->x_arm_arch_string is non NULL.
24521 2018-01-11 Tamar Christina <tamar.christina@arm.com>
24523 * config/aarch64/aarch64.h
24524 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
24526 2018-01-11 Sudakshina Das <sudi.das@arm.com>
24529 * expmed.c (emit_store_flag_force): Swap if const op0
24530 and change VOIDmode to mode of op0.
24532 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
24534 PR rtl-optimization/83761
24535 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
24536 than bytes to mode_for_size.
24538 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
24540 PR middle-end/83189
24541 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
24542 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
24545 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
24547 PR middle-end/83575
24548 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
24549 when in layout mode.
24550 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
24551 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
24554 2018-01-10 Michael Collison <michael.collison@arm.com>
24556 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
24557 * config/aarch64/aarch64-option-extension.def: Add
24558 AARCH64_OPT_EXTENSION of 'fp16fml'.
24559 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
24560 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
24561 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
24562 * config/aarch64/constraints.md (Ui7): New constraint.
24563 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
24564 (VFMLA_SEL_W): Ditto.
24567 (VFMLA16_LOW): New int iterator.
24568 (VFMLA16_HIGH): Ditto.
24569 (UNSPEC_FMLAL): New unspec.
24570 (UNSPEC_FMLSL): Ditto.
24571 (UNSPEC_FMLAL2): Ditto.
24572 (UNSPEC_FMLSL2): Ditto.
24573 (f16mac): New code attribute.
24574 * config/aarch64/aarch64-simd-builtins.def
24575 (aarch64_fmlal_lowv2sf): Ditto.
24576 (aarch64_fmlsl_lowv2sf): Ditto.
24577 (aarch64_fmlalq_lowv4sf): Ditto.
24578 (aarch64_fmlslq_lowv4sf): Ditto.
24579 (aarch64_fmlal_highv2sf): Ditto.
24580 (aarch64_fmlsl_highv2sf): Ditto.
24581 (aarch64_fmlalq_highv4sf): Ditto.
24582 (aarch64_fmlslq_highv4sf): Ditto.
24583 (aarch64_fmlal_lane_lowv2sf): Ditto.
24584 (aarch64_fmlsl_lane_lowv2sf): Ditto.
24585 (aarch64_fmlal_laneq_lowv2sf): Ditto.
24586 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
24587 (aarch64_fmlalq_lane_lowv4sf): Ditto.
24588 (aarch64_fmlsl_lane_lowv4sf): Ditto.
24589 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
24590 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
24591 (aarch64_fmlal_lane_highv2sf): Ditto.
24592 (aarch64_fmlsl_lane_highv2sf): Ditto.
24593 (aarch64_fmlal_laneq_highv2sf): Ditto.
24594 (aarch64_fmlsl_laneq_highv2sf): Ditto.
24595 (aarch64_fmlalq_lane_highv4sf): Ditto.
24596 (aarch64_fmlsl_lane_highv4sf): Ditto.
24597 (aarch64_fmlalq_laneq_highv4sf): Ditto.
24598 (aarch64_fmlsl_laneq_highv4sf): Ditto.
24599 * config/aarch64/aarch64-simd.md:
24600 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
24601 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
24602 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
24603 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
24604 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
24605 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
24606 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
24607 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
24608 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
24609 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
24610 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
24611 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
24612 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
24613 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
24614 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
24615 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
24616 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
24617 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
24618 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
24619 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
24620 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
24621 (vfmlsl_low_u32): Ditto.
24622 (vfmlalq_low_u32): Ditto.
24623 (vfmlslq_low_u32): Ditto.
24624 (vfmlal_high_u32): Ditto.
24625 (vfmlsl_high_u32): Ditto.
24626 (vfmlalq_high_u32): Ditto.
24627 (vfmlslq_high_u32): Ditto.
24628 (vfmlal_lane_low_u32): Ditto.
24629 (vfmlsl_lane_low_u32): Ditto.
24630 (vfmlal_laneq_low_u32): Ditto.
24631 (vfmlsl_laneq_low_u32): Ditto.
24632 (vfmlalq_lane_low_u32): Ditto.
24633 (vfmlslq_lane_low_u32): Ditto.
24634 (vfmlalq_laneq_low_u32): Ditto.
24635 (vfmlslq_laneq_low_u32): Ditto.
24636 (vfmlal_lane_high_u32): Ditto.
24637 (vfmlsl_lane_high_u32): Ditto.
24638 (vfmlal_laneq_high_u32): Ditto.
24639 (vfmlsl_laneq_high_u32): Ditto.
24640 (vfmlalq_lane_high_u32): Ditto.
24641 (vfmlslq_lane_high_u32): Ditto.
24642 (vfmlalq_laneq_high_u32): Ditto.
24643 (vfmlslq_laneq_high_u32): Ditto.
24644 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
24645 (AARCH64_FL_FOR_ARCH8_4): New.
24646 (AARCH64_ISA_F16FML): New ISA flag.
24647 (TARGET_F16FML): New feature flag for fp16fml.
24648 (doc/invoke.texi): Document new fp16fml option.
24650 2018-01-10 Michael Collison <michael.collison@arm.com>
24652 * config/aarch64/aarch64-builtins.c:
24653 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
24654 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
24655 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
24656 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
24657 (AARCH64_ISA_SHA3): New ISA flag.
24658 (TARGET_SHA3): New feature flag for sha3.
24659 * config/aarch64/iterators.md (sha512_op): New int attribute.
24660 (CRYPTO_SHA512): New int iterator.
24661 (UNSPEC_SHA512H): New unspec.
24662 (UNSPEC_SHA512H2): Ditto.
24663 (UNSPEC_SHA512SU0): Ditto.
24664 (UNSPEC_SHA512SU1): Ditto.
24665 * config/aarch64/aarch64-simd-builtins.def
24666 (aarch64_crypto_sha512hqv2di): New builtin.
24667 (aarch64_crypto_sha512h2qv2di): Ditto.
24668 (aarch64_crypto_sha512su0qv2di): Ditto.
24669 (aarch64_crypto_sha512su1qv2di): Ditto.
24670 (aarch64_eor3qv8hi): Ditto.
24671 (aarch64_rax1qv2di): Ditto.
24672 (aarch64_xarqv2di): Ditto.
24673 (aarch64_bcaxqv8hi): Ditto.
24674 * config/aarch64/aarch64-simd.md:
24675 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
24676 (aarch64_crypto_sha512su0qv2di): Ditto.
24677 (aarch64_crypto_sha512su1qv2di): Ditto.
24678 (aarch64_eor3qv8hi): Ditto.
24679 (aarch64_rax1qv2di): Ditto.
24680 (aarch64_xarqv2di): Ditto.
24681 (aarch64_bcaxqv8hi): Ditto.
24682 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
24683 (vsha512h2q_u64): Ditto.
24684 (vsha512su0q_u64): Ditto.
24685 (vsha512su1q_u64): Ditto.
24686 (veor3q_u16): Ditto.
24687 (vrax1q_u64): Ditto.
24688 (vxarq_u64): Ditto.
24689 (vbcaxq_u16): Ditto.
24690 * config/arm/types.md (crypto_sha512): New type attribute.
24691 (crypto_sha3): Ditto.
24692 (doc/invoke.texi): Document new sha3 option.
24694 2018-01-10 Michael Collison <michael.collison@arm.com>
24696 * config/aarch64/aarch64-builtins.c:
24697 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
24698 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
24699 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
24700 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
24701 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
24702 (AARCH64_ISA_SM4): New ISA flag.
24703 (TARGET_SM4): New feature flag for sm4.
24704 * config/aarch64/aarch64-simd-builtins.def
24705 (aarch64_sm3ss1qv4si): Ditto.
24706 (aarch64_sm3tt1aq4si): Ditto.
24707 (aarch64_sm3tt1bq4si): Ditto.
24708 (aarch64_sm3tt2aq4si): Ditto.
24709 (aarch64_sm3tt2bq4si): Ditto.
24710 (aarch64_sm3partw1qv4si): Ditto.
24711 (aarch64_sm3partw2qv4si): Ditto.
24712 (aarch64_sm4eqv4si): Ditto.
24713 (aarch64_sm4ekeyqv4si): Ditto.
24714 * config/aarch64/aarch64-simd.md:
24715 (aarch64_sm3ss1qv4si): Ditto.
24716 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
24717 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
24718 (aarch64_sm4eqv4si): Ditto.
24719 (aarch64_sm4ekeyqv4si): Ditto.
24720 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
24721 (sm3part_op): Ditto.
24722 (CRYPTO_SM3TT): Ditto.
24723 (CRYPTO_SM3PART): Ditto.
24724 (UNSPEC_SM3SS1): New unspec.
24725 (UNSPEC_SM3TT1A): Ditto.
24726 (UNSPEC_SM3TT1B): Ditto.
24727 (UNSPEC_SM3TT2A): Ditto.
24728 (UNSPEC_SM3TT2B): Ditto.
24729 (UNSPEC_SM3PARTW1): Ditto.
24730 (UNSPEC_SM3PARTW2): Ditto.
24731 (UNSPEC_SM4E): Ditto.
24732 (UNSPEC_SM4EKEY): Ditto.
24733 * config/aarch64/constraints.md (Ui2): New constraint.
24734 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
24735 * config/arm/types.md (crypto_sm3): New type attribute.
24736 (crypto_sm4): Ditto.
24737 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
24738 (vsm3tt1aq_u32): Ditto.
24739 (vsm3tt1bq_u32): Ditto.
24740 (vsm3tt2aq_u32): Ditto.
24741 (vsm3tt2bq_u32): Ditto.
24742 (vsm3partw1q_u32): Ditto.
24743 (vsm3partw2q_u32): Ditto.
24744 (vsm4eq_u32): Ditto.
24745 (vsm4ekeyq_u32): Ditto.
24746 (doc/invoke.texi): Document new sm4 option.
24748 2018-01-10 Michael Collison <michael.collison@arm.com>
24750 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
24751 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
24752 (AARCH64_FL_FOR_ARCH8_4): New.
24753 (AARCH64_FL_V8_4): New flag.
24754 (doc/invoke.texi): Document new armv8.4-a option.
24756 2018-01-10 Michael Collison <michael.collison@arm.com>
24758 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
24759 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
24760 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
24761 * config/aarch64/aarch64-option-extension.def: Add
24762 AARCH64_OPT_EXTENSION of 'sha2'.
24763 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
24764 (crypto): Disable sha2 and aes if crypto disabled.
24765 (crypto): Enable aes and sha2 if enabled.
24766 (simd): Disable sha2 and aes if simd disabled.
24767 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
24769 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
24770 (TARGET_SHA2): New feature flag for sha2.
24771 (TARGET_AES): New feature flag for aes.
24772 * config/aarch64/aarch64-simd.md:
24773 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
24774 conditional on TARGET_AES.
24775 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
24776 (aarch64_crypto_sha1hsi): Make pattern conditional
24778 (aarch64_crypto_sha1hv4si): Ditto.
24779 (aarch64_be_crypto_sha1hv4si): Ditto.
24780 (aarch64_crypto_sha1su1v4si): Ditto.
24781 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
24782 (aarch64_crypto_sha1su0v4si): Ditto.
24783 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
24784 (aarch64_crypto_sha256su0v4si): Ditto.
24785 (aarch64_crypto_sha256su1v4si): Ditto.
24786 (doc/invoke.texi): Document new aes and sha2 options.
24788 2018-01-10 Martin Sebor <msebor@redhat.com>
24790 PR tree-optimization/83781
24791 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
24794 2018-01-11 Martin Sebor <msebor@gmail.com>
24795 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
24797 PR tree-optimization/83501
24798 PR tree-optimization/81703
24800 * tree-ssa-strlen.c (get_string_cst): Rename...
24801 (get_string_len): ...to this. Handle global constants.
24802 (handle_char_store): Adjust.
24804 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
24805 Jim Wilson <jimw@sifive.com>
24807 * config/riscv/riscv-protos.h (riscv_output_return): New.
24808 * config/riscv/riscv.c (struct machine_function): New naked_p field.
24809 (riscv_attribute_table, riscv_output_return),
24810 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
24811 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
24812 (riscv_compute_frame_info): Only compute frame->mask if not a naked
24814 (riscv_expand_prologue): Add early return for naked function.
24815 (riscv_expand_epilogue): Likewise.
24816 (riscv_function_ok_for_sibcall): Return false for naked function.
24817 (riscv_set_current_function): New.
24818 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
24819 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
24820 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
24821 * doc/extend.texi (RISC-V Function Attributes): New.
24823 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
24825 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
24826 check for 128-bit long double before checking TCmode.
24827 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
24828 128-bit long doubles before checking TFmode or TCmode.
24829 (FLOAT128_IBM_P): Likewise.
24831 2018-01-10 Martin Sebor <msebor@redhat.com>
24833 PR tree-optimization/83671
24834 * builtins.c (c_strlen): Unconditionally return zero for the empty
24836 Use -Warray-bounds for warnings.
24837 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
24838 for non-constant array indices with COMPONENT_REF, arrays of
24839 arrays, and pointers to arrays.
24840 (gimple_fold_builtin_strlen): Determine and set length range for
24841 non-constant character arrays.
24843 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
24845 PR middle-end/81897
24846 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
24849 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
24851 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
24853 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
24856 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
24857 VECTOR_MEM_ALTIVEC_OR_VSX_P.
24858 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
24859 indexed_or_indirect_operand predicate.
24860 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
24861 (*vsx_le_perm_load_v8hi): Likewise.
24862 (*vsx_le_perm_load_v16qi): Likewise.
24863 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
24864 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
24865 (*vsx_le_perm_store_v8hi): Likewise.
24866 (*vsx_le_perm_store_v16qi): Likewise.
24867 (eight unnamed splitters): Likewise.
24869 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
24871 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
24872 * config/rs6000/emmintrin.h: Likewise.
24873 * config/rs6000/mmintrin.h: Likewise.
24874 * config/rs6000/xmmintrin.h: Likewise.
24876 2018-01-10 David Malcolm <dmalcolm@redhat.com>
24879 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
24881 * tree.c (tree_nop_conversion): Return true for location wrapper
24883 (maybe_wrap_with_location): New function.
24884 (selftest::check_strip_nops): New function.
24885 (selftest::test_location_wrappers): New function.
24886 (selftest::tree_c_tests): Call it.
24887 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
24888 (maybe_wrap_with_location): New decl.
24889 (EXPR_LOCATION_WRAPPER_P): New macro.
24890 (location_wrapper_p): New inline function.
24891 (tree_strip_any_location_wrapper): New inline function.
24893 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
24896 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
24897 stack_realign_offset for the largest alignment of stack slot
24899 (ix86_find_max_used_stack_alignment): New function.
24900 (ix86_finalize_stack_frame_flags): Use it. Set
24901 max_used_stack_alignment if we don't realign stack.
24902 * config/i386/i386.h (machine_function): Add
24903 max_used_stack_alignment.
24905 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
24907 * config/arm/arm.opt (-mbranch-cost): New option.
24908 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
24911 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
24914 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
24915 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
24917 2018-01-10 Richard Biener <rguenther@suse.de>
24920 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
24921 early out so it also covers the case where we have a non-NULL
24924 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
24926 PR tree-optimization/83753
24927 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
24928 for non-strided grouped accesses if the number of elements is 1.
24930 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
24933 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
24934 * i386.h (TARGET_USE_GATHER): Define.
24935 * x86-tune.def (X86_TUNE_USE_GATHER): New.
24937 2018-01-10 Martin Liska <mliska@suse.cz>
24940 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
24941 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
24943 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
24944 CLEANUP_NO_PARTITIONING is not set.
24946 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
24948 * doc/rtl.texi: Remove documentation of (const ...) wrappers
24949 for vectors, as a partial revert of r254296.
24950 * rtl.h (const_vec_p): Delete.
24951 (const_vec_duplicate_p): Don't test for vector CONSTs.
24952 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
24953 * expmed.c (make_tree): Likewise.
24956 * common.md (E, F): Use CONSTANT_P instead of checking for
24958 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
24959 checking for CONST_VECTOR.
24961 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
24963 PR middle-end/83575
24964 * predict.c (force_edge_cold): Handle in more sane way edges
24965 with no prediction.
24967 2018-01-09 Carl Love <cel@us.ibm.com>
24969 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
24971 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
24972 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
24973 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
24974 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
24975 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
24976 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
24977 * config/rs6000/rs6000-protos.h: Add extern defition for
24978 rs6000_generate_float2_double_code.
24979 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
24981 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
24982 (float2_v2df): Add define_expand.
24984 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
24987 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
24988 op_mode in the force_to_mode call.
24990 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
24992 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
24993 instead of checking each element individually.
24994 (aarch64_evpc_uzp): Likewise.
24995 (aarch64_evpc_zip): Likewise.
24996 (aarch64_evpc_ext): Likewise.
24997 (aarch64_evpc_rev): Likewise.
24998 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
24999 instead of checking each element individually. Return true without
25001 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
25002 whether all selected elements come from the same input, instead of
25003 checking each element individually. Remove calls to gen_rtx_REG,
25004 start_sequence and end_sequence and instead assert that no rtl is
25007 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
25009 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
25010 order of HIGH and CONST checks.
25012 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
25014 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
25015 if the destination isn't an SSA_NAME.
25017 2018-01-09 Richard Biener <rguenther@suse.de>
25019 PR tree-optimization/83668
25020 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
25022 (canonicalize_loop_form): ... here, renamed from ...
25023 (canonicalize_loop_closed_ssa_form): ... this and amended to
25024 swap successor edges for loop exit blocks to make us use
25025 the RPO order we need for initial schedule generation.
25027 2018-01-09 Joseph Myers <joseph@codesourcery.com>
25029 PR tree-optimization/64811
25030 * match.pd: When optimizing comparisons with Inf, avoid
25031 introducing or losing exceptions from comparisons with NaN.
25033 2018-01-09 Martin Liska <mliska@suse.cz>
25036 * asan.c (shadow_mem_size): Add gcc_assert.
25038 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
25040 Don't save registers in main().
25043 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
25044 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
25045 * config/avr/avr.c (avr_set_current_function): Don't error if
25046 naked, OS_task or OS_main are specified at the same time.
25047 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
25049 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
25051 * common/config/avr/avr-common.c (avr_option_optimization_table):
25052 Switch on -mmain-is-OS_task for optimizing compilations.
25054 2018-01-09 Richard Biener <rguenther@suse.de>
25056 PR tree-optimization/83572
25057 * graphite.c: Include cfganal.h.
25058 (graphite_transform_loops): Connect infinite loops to exit
25059 and remove fake edges at the end.
25061 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
25063 * ipa-inline.c (edge_badness): Revert accidental checkin.
25065 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
25068 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
25069 symbols; not inline clones.
25071 2018-01-09 Jakub Jelinek <jakub@redhat.com>
25074 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
25075 hard registers. Formatting fixes.
25077 PR preprocessor/83722
25078 * gcc.c (try_generate_repro): Pass
25079 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
25080 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
25083 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
25084 Kito Cheng <kito.cheng@gmail.com>
25086 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
25087 (riscv_leaf_function_p): Delete.
25088 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
25090 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
25092 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
25094 (do_ifelse): New function.
25095 (do_isel): New function.
25096 (do_sub3): New function.
25097 (do_add3): New function.
25098 (do_load_mask_compare): New function.
25099 (do_overlap_load_compare): New function.
25100 (expand_compare_loop): New function.
25101 (expand_block_compare): Call expand_compare_loop() when appropriate.
25102 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
25103 option description.
25104 (-mblock-compare-inline-loop-limit): New option.
25106 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25109 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
25110 Reverse order of second and third operands in first alternative.
25111 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
25112 of first and second elements in UNSPEC_VPERMR vector.
25113 (altivec_expand_vec_perm_le): Likewise.
25115 2018-01-08 Jeff Law <law@redhat.com>
25117 PR rtl-optimizatin/81308
25118 * tree-switch-conversion.c (cfg_altered): New file scoped static.
25119 (process_switch): If group_case_labels makes a change, then set
25121 (pass_convert_switch::execute): If a switch is converted, then
25122 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
25124 PR rtl-optimization/81308
25125 * recog.c (split_all_insns): Conditionally cleanup the CFG after
25128 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
25130 PR target/83663 - Revert r255946
25131 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
25132 generation for cases where splatting a value is not useful.
25133 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
25134 across a vec_duplicate and a paradoxical subreg forming a vector
25135 mode to a vec_concat.
25137 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25139 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
25140 -march=armv8.3-a variants.
25141 * config/arm/t-multilib: Likewise.
25142 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
25144 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
25146 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
25148 (cceq_ior_compare_complement): Give it a name so I can use it, and
25149 change boolean_or_operator predicate to boolean_operator so it can
25150 be used to generate a crand.
25151 (eqne): New code iterator.
25152 (bd/bd_neg): New code_attrs.
25153 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
25154 a single define_insn.
25155 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
25156 decrement (bdnzt/bdnzf/bdzt/bdzf).
25157 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
25158 with the new names of the branch decrement patterns, and added the
25159 names of the branch decrement conditional patterns.
25161 2018-01-08 Richard Biener <rguenther@suse.de>
25163 PR tree-optimization/83563
25164 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
25167 2018-01-08 Richard Biener <rguenther@suse.de>
25169 PR middle-end/83713
25170 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
25172 2018-01-08 Richard Biener <rguenther@suse.de>
25174 PR tree-optimization/83685
25175 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
25176 references to abnormals.
25178 2018-01-08 Richard Biener <rguenther@suse.de>
25181 * dwarf2out.c (output_indirect_strings): Handle empty
25182 skeleton_debug_str_hash.
25183 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
25185 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
25187 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
25188 (emit_store_direct): Likewise.
25189 (arc_trampoline_adjust_address): Likewise.
25190 (arc_asm_trampoline_template): New function.
25191 (arc_initialize_trampoline): Use asm_trampoline_template.
25192 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
25193 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
25194 * config/arc/arc.md (flush_icache): Delete pattern.
25196 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
25198 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
25199 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
25202 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
25205 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
25206 by not USED_FOR_TARGET.
25207 (make_pass_resolve_sw_modes): Likewise.
25209 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
25211 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
25214 2018-01-08 Richard Biener <rguenther@suse.de>
25216 PR middle-end/83580
25217 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
25219 2018-01-08 Richard Biener <rguenther@suse.de>
25221 PR middle-end/83517
25222 * match.pd ((t * 2) / 2) -> t): Add missing :c.
25224 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
25226 PR middle-end/81897
25227 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
25228 basic blocks with a small number of successors.
25229 (convert_control_dep_chain_into_preds): Improve handling of
25231 (dump_predicates): Split apart into...
25232 (dump_pred_chain): ...here...
25233 (dump_pred_info): ...and here.
25234 (can_one_predicate_be_invalidated_p): Add debugging printfs.
25235 (can_chain_union_be_invalidated_p): Improve check for invalidation
25237 (uninit_uses_cannot_happen): Avoid unnecessary if
25238 convert_control_dep_chain_into_preds yielded nothing.
25240 2018-01-06 Martin Sebor <msebor@redhat.com>
25242 PR tree-optimization/83640
25243 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
25244 subtracting negative offset from size.
25245 (builtin_access::overlap): Adjust offset bounds of the access to fall
25246 within the size of the object if possible.
25248 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
25250 PR rtl-optimization/83699
25251 * expmed.c (extract_bit_field_1): Restrict the vector usage of
25252 extract_bit_field_as_subreg to cases in which the extracted
25253 value is also a vector.
25255 * lra-constraints.c (process_alt_operands): Test for the equivalence
25256 substitutions when detecting a possible reload cycle.
25258 2018-01-06 Jakub Jelinek <jakub@redhat.com>
25261 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
25262 by default if flag_selective_schedling{,2}. Formatting fixes.
25264 PR rtl-optimization/83682
25265 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
25266 if it has non-VECTOR_MODE element mode.
25267 (vec_duplicate_p): Likewise.
25269 PR middle-end/83694
25270 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
25271 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
25273 2018-01-05 Jakub Jelinek <jakub@redhat.com>
25276 * config/i386/i386-builtin.def
25277 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
25278 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
25279 Require also OPTION_MASK_ISA_AVX512F in addition to
25280 OPTION_MASK_ISA_GFNI.
25281 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
25282 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
25283 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
25284 to OPTION_MASK_ISA_GFNI.
25285 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
25286 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
25287 OPTION_MASK_ISA_AVX512BW.
25288 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
25289 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
25290 addition to OPTION_MASK_ISA_GFNI.
25291 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
25292 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
25293 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
25294 to OPTION_MASK_ISA_GFNI.
25295 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
25296 a requirement for all ISAs rather than any of them with a few
25298 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
25300 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
25301 bitmasks to be enabled with 3 exceptions, instead of requiring any
25302 enabled ISA with lots of exceptions.
25303 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
25304 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
25305 Change avx512bw in isa attribute to avx512f.
25306 * config/i386/sgxintrin.h: Add license boilerplate.
25307 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
25308 to __AVX512F__ and __AVX512VL to __AVX512VL__.
25309 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
25310 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
25312 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
25313 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
25314 temporarily sse2 rather than sse if not enabled already.
25317 * config/i386/sse.md (VI248_VLBW): Rename to ...
25318 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
25319 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
25320 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
25321 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
25322 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
25323 mode iterator instead of VI248_VLBW.
25325 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
25327 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
25328 (record_modified): Skip clobbers; add debug output.
25329 (param_change_prob): Use sreal frequencies.
25331 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
25333 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
25334 punt for user-aligned variables.
25336 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
25338 * tree-chrec.c (chrec_contains_symbols): Return true for
25341 2018-01-05 Sudakshina Das <sudi.das@arm.com>
25344 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
25345 of (x|y) == x for BICS pattern.
25347 2018-01-05 Jakub Jelinek <jakub@redhat.com>
25349 PR tree-optimization/83605
25350 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
25351 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
25354 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
25356 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
25357 * config/epiphany/rtems.h: New file.
25359 2018-01-04 Jakub Jelinek <jakub@redhat.com>
25360 Uros Bizjak <ubizjak@gmail.com>
25363 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
25364 QIreg_operand instead of register_operand predicate.
25365 * config/i386/i386.c (ix86_rop_should_change_byte_p,
25366 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
25367 comments instead of -fmitigate[-_]rop.
25369 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
25372 * cgraphunit.c (symbol_table::compile): Switch to text_section
25373 before calling assembly_start debug hook.
25374 * run-rtl-passes.c (run_rtl_passes): Likewise.
25377 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
25379 * tree-vrp.c (extract_range_from_binary_expr_1): Check
25380 range_int_cst_p rather than !symbolic_range_p before calling
25381 extract_range_from_multiplicative_op_1.
25383 2018-01-04 Jeff Law <law@redhat.com>
25385 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
25386 redundant test in assertion.
25388 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
25390 * doc/rtl.texi: Document machine_mode wrapper classes.
25392 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
25394 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
25395 using tree_to_uhwi.
25397 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
25399 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
25400 the VEC_PERM_EXPR fold to fail.
25402 2018-01-04 Jakub Jelinek <jakub@redhat.com>
25405 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
25406 to switched_sections.
25408 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
25411 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
25412 test for d.testing.
25414 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
25417 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
25418 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
25420 2018-01-04 Jakub Jelinek <jakub@redhat.com>
25423 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
25424 is BLKmode and bitpos not zero or mode change is needed.
25426 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
25429 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
25432 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
25435 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
25436 instead of MULT rtx. Update all corresponding splitters.
25437 (*saddl_se): Ditto.
25438 (*ssub<modesuffix>): Ditto.
25439 (*ssubl_se): Ditto.
25440 (*cmp_sadd_di): Update split patterns.
25441 (*cmp_sadd_si): Ditto.
25442 (*cmp_sadd_sidi): Ditto.
25443 (*cmp_ssub_di): Ditto.
25444 (*cmp_ssub_si): Ditto.
25445 (*cmp_ssub_sidi): Ditto.
25446 * config/alpha/predicates.md (const23_operand): New predicate.
25447 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
25448 Look for ASHIFT, not MULT inner operand.
25449 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
25451 2018-01-04 Martin Liska <mliska@suse.cz>
25453 PR gcov-profile/83669
25454 * gcov.c (output_intermediate_file): Add version to intermediate
25456 * doc/gcov.texi: Document new field 'version' in intermediate
25457 file format. Fix location of '-k' option of gcov command.
25459 2018-01-04 Martin Liska <mliska@suse.cz>
25462 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
25464 2018-01-04 Jakub Jelinek <jakub@redhat.com>
25466 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
25468 2018-01-03 Martin Sebor <msebor@redhat.com>
25470 PR tree-optimization/83655
25471 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
25472 checking calls with invalid arguments.
25474 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25476 * tree-vect-stmts.c (vect_get_store_rhs): New function.
25477 (vectorizable_mask_load_store): Delete.
25478 (vectorizable_call): Return false for masked loads and stores.
25479 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
25480 instead of gimple_assign_rhs1.
25481 (vectorizable_load): Handle IFN_MASK_LOAD.
25482 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
25484 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25486 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
25488 (vectorizable_mask_load_store): ...here.
25489 (vectorizable_load): ...and here.
25491 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25493 * tree-vect-stmts.c (vect_build_all_ones_mask)
25494 (vect_build_zero_merge_argument): New functions, split out from...
25495 (vectorizable_load): ...here.
25497 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25499 * tree-vect-stmts.c (vect_check_store_rhs): New function,
25501 (vectorizable_mask_load_store): ...here.
25502 (vectorizable_store): ...and here.
25504 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25506 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
25508 (vectorizable_mask_load_store): ...here.
25510 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25512 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
25513 (vect_model_store_cost): Take a vec_load_store_type instead of a
25515 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
25516 (vect_model_store_cost): Take a vec_load_store_type instead of a
25518 (vectorizable_mask_load_store): Update accordingly.
25519 (vectorizable_store): Likewise.
25520 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
25522 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25524 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
25525 IFN_MASK_LOAD calls here rather than...
25526 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
25528 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25529 Alan Hayward <alan.hayward@arm.com>
25530 David Sherwood <david.sherwood@arm.com>
25532 * expmed.c (extract_bit_field_1): For vector extracts,
25533 fall back to extract_bit_field_as_subreg if vec_extract
25536 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25537 Alan Hayward <alan.hayward@arm.com>
25538 David Sherwood <david.sherwood@arm.com>
25540 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
25541 they are variable or constant sized.
25542 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
25543 slots for constant-sized data.
25545 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25546 Alan Hayward <alan.hayward@arm.com>
25547 David Sherwood <david.sherwood@arm.com>
25549 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
25550 handling COND_EXPRs with boolean comparisons, try to find a better
25551 basis for the mask type than the boolean itself.
25553 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25555 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
25556 is calculated and how it can be overridden.
25557 * genmodes.c (max_bitsize_mode_any_mode): New variable.
25558 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
25560 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
25563 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25564 Alan Hayward <alan.hayward@arm.com>
25565 David Sherwood <david.sherwood@arm.com>
25567 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
25568 Remove the mode argument.
25569 (aarch64_simd_valid_immediate): Remove the mode and inverse
25571 * config/aarch64/iterators.md (bitsize): New iterator.
25572 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
25573 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
25574 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
25575 aarch64_simd_valid_immediate.
25576 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
25577 (aarch64_reg_or_bic_imm): Likewise.
25578 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
25579 with an insn_type enum and msl with a modifier_type enum.
25580 Replace element_width with a scalar_mode. Change the shift
25581 to unsigned int. Add constructors for scalar_float_mode and
25582 scalar_int_mode elements.
25583 (aarch64_vect_float_const_representable_p): Delete.
25584 (aarch64_can_const_movi_rtx_p)
25585 (aarch64_simd_scalar_immediate_valid_for_move)
25586 (aarch64_simd_make_constant): Update call to
25587 aarch64_simd_valid_immediate.
25588 (aarch64_advsimd_valid_immediate_hs): New function.
25589 (aarch64_advsimd_valid_immediate): Likewise.
25590 (aarch64_simd_valid_immediate): Remove mode and inverse
25591 arguments. Rewrite to use the above. Use const_vec_duplicate_p
25592 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
25593 and aarch64_float_const_representable_p on the result.
25594 (aarch64_output_simd_mov_immediate): Remove mode argument.
25595 Update call to aarch64_simd_valid_immediate and use of
25596 simd_immediate_info.
25597 (aarch64_output_scalar_simd_mov_immediate): Update call
25600 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25601 Alan Hayward <alan.hayward@arm.com>
25602 David Sherwood <david.sherwood@arm.com>
25604 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
25605 (mode_nunits): Likewise CONST_MODE_NUNITS.
25606 * machmode.def (ADJUST_NUNITS): Document.
25607 * genmodes.c (mode_data::need_nunits_adj): New field.
25608 (blank_mode): Update accordingly.
25609 (adj_nunits): New variable.
25610 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
25612 (emit_mode_size_inline): Set need_bytesize_adj for all modes
25613 listed in adj_nunits.
25614 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
25615 listed in adj_nunits. Don't emit case statements for such modes.
25616 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
25617 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
25618 nothing if adj_nunits is nonnull.
25619 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
25620 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
25621 (emit_mode_fbit): Update use of print_maybe_const_decl.
25622 (emit_move_size): Likewise. Treat the array as non-const
25624 (emit_mode_adjustments): Handle adj_nunits.
25626 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25628 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
25629 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
25630 (VECTOR_MODES): Use it.
25631 (make_vector_modes): Take the prefix as an argument.
25633 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25634 Alan Hayward <alan.hayward@arm.com>
25635 David Sherwood <david.sherwood@arm.com>
25637 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
25638 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
25639 for MODE_VECTOR_BOOL.
25640 * machmode.def (VECTOR_BOOL_MODE): Document.
25641 * genmodes.c (VECTOR_BOOL_MODE): New macro.
25642 (make_vector_bool_mode): New function.
25643 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
25645 * lto-streamer-in.c (lto_input_mode_table): Likewise.
25646 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
25648 * stor-layout.c (int_mode_for_mode): Likewise.
25649 * tree.c (build_vector_type_for_mode): Likewise.
25650 * varasm.c (output_constant_pool_2): Likewise.
25651 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
25652 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
25653 for MODE_VECTOR_BOOL.
25654 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
25655 of mode class checks.
25656 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
25657 instead of a list of mode class checks.
25658 (expand_vector_scalar_condition): Likewise.
25659 (type_for_widest_vector_mode): Handle BImode as an inner mode.
25661 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25662 Alan Hayward <alan.hayward@arm.com>
25663 David Sherwood <david.sherwood@arm.com>
25665 * machmode.h (mode_size): Change from unsigned short to
25667 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
25668 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
25669 or if measurement_type is not polynomial.
25670 (fixed_size_mode::includes_p): Check for constant-sized modes.
25671 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
25672 return a poly_uint16 rather than an unsigned short.
25673 (emit_mode_size): Change the type of mode_size from unsigned short
25674 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
25675 (emit_mode_adjustments): Cope with polynomial vector sizes.
25676 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
25678 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
25680 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
25681 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
25682 * caller-save.c (setup_save_areas): Likewise.
25683 (replace_reg_with_saved_mem): Likewise.
25684 * calls.c (emit_library_call_value_1): Likewise.
25685 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
25686 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
25687 (gen_lowpart_for_combine): Likewise.
25688 * convert.c (convert_to_integer_1): Likewise.
25689 * cse.c (equiv_constant, cse_insn): Likewise.
25690 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
25691 (cselib_subst_to_values): Likewise.
25692 * dce.c (word_dce_process_block): Likewise.
25693 * df-problems.c (df_word_lr_mark_ref): Likewise.
25694 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
25695 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
25696 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
25697 (rtl_for_decl_location): Likewise.
25698 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
25699 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
25700 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
25701 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
25702 (expand_expr_real_1): Likewise.
25703 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
25704 (pad_below): Likewise.
25705 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
25706 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
25707 * ira.c (get_subreg_tracking_sizes): Likewise.
25708 * ira-build.c (ira_create_allocno_objects): Likewise.
25709 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
25710 (ira_sort_regnos_for_alter_reg): Likewise.
25711 * ira-costs.c (record_operand_costs): Likewise.
25712 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
25713 (resolve_simple_move): Likewise.
25714 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
25715 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
25716 (lra_constraints): Likewise.
25717 (CONST_POOL_OK_P): Reject variable-sized modes.
25718 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
25719 (add_pseudo_to_slot, lra_spill): Likewise.
25720 * omp-low.c (omp_clause_aligned_alignment): Likewise.
25721 * optabs-query.c (get_best_extraction_insn): Likewise.
25722 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
25723 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
25724 (expand_mult_highpart, valid_multiword_target_p): Likewise.
25725 * recog.c (offsettable_address_addr_space_p): Likewise.
25726 * regcprop.c (maybe_mode_change): Likewise.
25727 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
25728 * regrename.c (build_def_use): Likewise.
25729 * regstat.c (dump_reg_info): Likewise.
25730 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
25731 (find_reloads, find_reloads_subreg_address): Likewise.
25732 * reload1.c (eliminate_regs_1): Likewise.
25733 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
25734 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
25735 (simplify_binary_operation_1, simplify_subreg): Likewise.
25736 * targhooks.c (default_function_arg_padding): Likewise.
25737 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
25738 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
25739 (verify_gimple_assign_ternary): Likewise.
25740 * tree-inline.c (estimate_move_cost): Likewise.
25741 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
25742 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
25743 (get_address_cost_ainc): Likewise.
25744 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
25745 (vect_supportable_dr_alignment): Likewise.
25746 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
25747 (vectorizable_reduction): Likewise.
25748 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
25749 (vectorizable_operation, vectorizable_load): Likewise.
25750 * tree.c (build_same_sized_truth_vector_type): Likewise.
25751 * valtrack.c (cleanup_auto_inc_dec): Likewise.
25752 * var-tracking.c (emit_note_insn_var_location): Likewise.
25753 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
25754 (ADDR_VEC_ALIGN): Likewise.
25756 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25757 Alan Hayward <alan.hayward@arm.com>
25758 David Sherwood <david.sherwood@arm.com>
25760 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
25762 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
25763 or if measurement_type is polynomial.
25764 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
25765 * combine.c (make_extraction): Likewise.
25766 * dse.c (find_shift_sequence): Likewise.
25767 * dwarf2out.c (mem_loc_descriptor): Likewise.
25768 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
25769 (extract_bit_field, extract_low_bits): Likewise.
25770 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
25771 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
25772 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
25773 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
25774 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
25775 * reload.c (find_reloads): Likewise.
25776 * reload1.c (alter_reg): Likewise.
25777 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
25778 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
25779 * tree-if-conv.c (predicate_mem_writes): Likewise.
25780 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
25781 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
25782 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
25783 * valtrack.c (dead_debug_insert_temp): Likewise.
25784 * varasm.c (mergeable_constant_section): Likewise.
25785 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
25787 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25788 Alan Hayward <alan.hayward@arm.com>
25789 David Sherwood <david.sherwood@arm.com>
25791 * expr.c (expand_assignment): Cope with polynomial mode sizes
25792 when assigning to a CONCAT.
25794 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25795 Alan Hayward <alan.hayward@arm.com>
25796 David Sherwood <david.sherwood@arm.com>
25798 * machmode.h (mode_precision): Change from unsigned short to
25800 (mode_to_precision): Return a poly_uint16 rather than an unsigned
25802 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
25803 or if measurement_type is not polynomial.
25804 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
25805 in which the mode is already known to be a scalar_int_mode.
25806 * genmodes.c (emit_mode_precision): Change the type of mode_precision
25807 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
25809 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
25810 for GET_MODE_PRECISION.
25811 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
25812 for GET_MODE_PRECISION.
25813 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
25815 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
25816 (expand_field_assignment, make_extraction): Likewise.
25817 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
25818 (get_last_value): Likewise.
25819 * convert.c (convert_to_integer_1): Likewise.
25820 * cse.c (cse_insn): Likewise.
25821 * expr.c (expand_expr_real_1): Likewise.
25822 * lra-constraints.c (simplify_operand_subreg): Likewise.
25823 * optabs-query.c (can_atomic_load_p): Likewise.
25824 * optabs.c (expand_atomic_load): Likewise.
25825 (expand_atomic_store): Likewise.
25826 * ree.c (combine_reaching_defs): Likewise.
25827 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
25828 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
25829 * tree.h (type_has_mode_precision_p): Likewise.
25830 * ubsan.c (instrument_si_overflow): Likewise.
25832 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25833 Alan Hayward <alan.hayward@arm.com>
25834 David Sherwood <david.sherwood@arm.com>
25836 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
25837 polynomial numbers of units.
25838 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
25839 (valid_vector_subparts_p): New function.
25840 (build_vector_type): Remove temporary shim and take the number
25841 of units as a poly_uint64 rather than an int.
25842 (build_opaque_vector_type): Take the number of units as a
25843 poly_uint64 rather than an int.
25844 * tree.c (build_vector_from_ctor): Handle polynomial
25845 TYPE_VECTOR_SUBPARTS.
25846 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
25847 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
25848 (build_vector_from_val): If the number of units is variable,
25849 use build_vec_duplicate_cst for constant operands and
25850 VEC_DUPLICATE_EXPR otherwise.
25851 (make_vector_type): Remove temporary is_constant ().
25852 (build_vector_type, build_opaque_vector_type): Take the number of
25853 units as a poly_uint64 rather than an int.
25854 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
25856 * cfgexpand.c (expand_debug_expr): Likewise.
25857 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
25858 (store_constructor, expand_expr_real_1): Likewise.
25859 (const_scalar_mask_from_tree): Likewise.
25860 * fold-const-call.c (fold_const_reduction): Likewise.
25861 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
25862 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
25863 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
25864 (fold_relational_const): Likewise.
25865 (native_interpret_vector): Likewise. Change the size from an
25866 int to an unsigned int.
25867 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
25868 TYPE_VECTOR_SUBPARTS.
25869 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
25870 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
25871 duplicating a non-constant operand into a variable-length vector.
25872 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
25873 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
25874 * ipa-icf.c (sem_variable::equals): Likewise.
25875 * match.pd: Likewise.
25876 * omp-simd-clone.c (simd_clone_subparts): Likewise.
25877 * print-tree.c (print_node): Likewise.
25878 * stor-layout.c (layout_type): Likewise.
25879 * targhooks.c (default_builtin_vectorization_cost): Likewise.
25880 * tree-cfg.c (verify_gimple_comparison): Likewise.
25881 (verify_gimple_assign_binary): Likewise.
25882 (verify_gimple_assign_ternary): Likewise.
25883 (verify_gimple_assign_single): Likewise.
25884 * tree-pretty-print.c (dump_generic_node): Likewise.
25885 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
25886 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
25887 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
25888 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
25889 (vect_shift_permute_load_chain): Likewise.
25890 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
25891 (expand_vector_condition, optimize_vector_constructor): Likewise.
25892 (lower_vec_perm, get_compute_type): Likewise.
25893 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
25894 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
25895 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
25896 (vect_recog_mask_conversion_pattern): Likewise.
25897 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
25898 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
25899 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
25900 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
25901 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
25902 (vectorizable_shift, vectorizable_operation, vectorizable_store)
25903 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
25904 (supportable_widening_operation): Likewise.
25905 (supportable_narrowing_operation): Likewise.
25906 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
25908 * varasm.c (output_constant): Likewise.
25910 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25911 Alan Hayward <alan.hayward@arm.com>
25912 David Sherwood <david.sherwood@arm.com>
25914 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
25915 so that both the length == 3 and length != 3 cases set up their
25916 own permute vectors. Add comments explaining why we know the
25917 number of elements is constant.
25918 (vect_permute_load_chain): Likewise.
25920 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25921 Alan Hayward <alan.hayward@arm.com>
25922 David Sherwood <david.sherwood@arm.com>
25924 * machmode.h (mode_nunits): Change from unsigned char to
25926 (ONLY_FIXED_SIZE_MODES): New macro.
25927 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
25928 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
25929 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
25931 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
25932 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
25933 or if measurement_type is not polynomial.
25934 * genmodes.c (ZERO_COEFFS): New macro.
25935 (emit_mode_nunits_inline): Make mode_nunits_inline return a
25937 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
25938 Use ZERO_COEFFS when emitting initializers.
25939 * data-streamer.h (bp_pack_poly_value): New function.
25940 (bp_unpack_poly_value): Likewise.
25941 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
25942 for GET_MODE_NUNITS.
25943 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
25944 for GET_MODE_NUNITS.
25945 * tree.c (make_vector_type): Remove temporary shim and make
25946 the real function take the number of units as a poly_uint64
25947 rather than an int.
25948 (build_vector_type_for_mode): Handle polynomial nunits.
25949 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
25950 * emit-rtl.c (const_vec_series_p_1): Likewise.
25951 (gen_rtx_CONST_VECTOR): Likewise.
25952 * fold-const.c (test_vec_duplicate_folding): Likewise.
25953 * genrecog.c (validate_pattern): Likewise.
25954 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
25955 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
25956 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
25957 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
25958 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
25959 * rtlanal.c (subreg_get_info): Likewise.
25960 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
25961 (vect_grouped_load_supported): Likewise.
25962 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
25963 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
25964 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
25965 (simplify_const_unary_operation, simplify_binary_operation_1)
25966 (simplify_const_binary_operation, simplify_ternary_operation)
25967 (test_vector_ops_duplicate, test_vector_ops): Likewise.
25968 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
25969 instead of CONST_VECTOR_NUNITS.
25970 * varasm.c (output_constant_pool_2): Likewise.
25971 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
25972 explicit-encoded elements in the XVEC for variable-length vectors.
25974 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25976 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
25978 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25979 Alan Hayward <alan.hayward@arm.com>
25980 David Sherwood <david.sherwood@arm.com>
25982 * coretypes.h (fixed_size_mode): Declare.
25983 (fixed_size_mode_pod): New typedef.
25984 * builtins.h (target_builtins::x_apply_args_mode)
25985 (target_builtins::x_apply_result_mode): Change type to
25986 fixed_size_mode_pod.
25987 * builtins.c (apply_args_size, apply_result_size, result_vector)
25988 (expand_builtin_apply_args_1, expand_builtin_apply)
25989 (expand_builtin_return): Update accordingly.
25991 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
25993 * cse.c (hash_rtx_cb): Hash only the encoded elements.
25994 * cselib.c (cselib_hash_rtx): Likewise.
25995 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
25996 CONST_VECTOR encoding.
25998 2018-01-03 Jakub Jelinek <jakub@redhat.com>
25999 Jeff Law <law@redhat.com>
26002 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
26003 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
26004 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
26005 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
26008 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
26009 explicitly probe *sp in a noreturn function if there were any callee
26010 register saves or frame pointer is needed.
26012 2018-01-03 Jakub Jelinek <jakub@redhat.com>
26015 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
26016 BLKmode for ternary, binary or unary expressions.
26019 * var-tracking.c (delete_vta_debug_insn): New inline function.
26020 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
26021 insns from get_insns () to NULL instead of each bb separately.
26022 Use delete_vta_debug_insn. No longer static.
26023 (vt_debug_insns_local, variable_tracking_main_1): Adjust
26024 delete_vta_debug_insns callers.
26025 * rtl.h (delete_vta_debug_insns): Declare.
26026 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
26027 instead of variable_tracking_main.
26029 2018-01-03 Martin Sebor <msebor@redhat.com>
26031 PR tree-optimization/83603
26032 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
26033 arguments past the endof the argument list in functions declared
26034 without a prototype.
26035 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
26036 Avoid checking when arguments are null.
26038 2018-01-03 Martin Sebor <msebor@redhat.com>
26041 * doc/extend.texi (attribute const): Fix a typo.
26042 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
26043 issuing -Wsuggest-attribute for void functions.
26045 2018-01-03 Martin Sebor <msebor@redhat.com>
26047 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
26048 offset_int::from instead of wide_int::to_shwi.
26049 (maybe_diag_overlap): Remove assertion.
26050 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
26051 * gimple-ssa-sprintf.c (format_directive): Same.
26052 (parse_directive): Same.
26053 (sprintf_dom_walker::compute_format_length): Same.
26054 (try_substitute_return_value): Same.
26056 2018-01-03 Jeff Law <law@redhat.com>
26058 PR middle-end/83654
26059 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
26060 non-constant residual for zero at runtime and avoid probing in
26061 that case. Reorganize code for trailing problem to mirror handling
26064 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
26066 PR tree-optimization/83501
26067 * tree-ssa-strlen.c (get_string_cst): New.
26068 (handle_char_store): Call get_string_cst.
26070 2018-01-03 Martin Liska <mliska@suse.cz>
26072 PR tree-optimization/83593
26073 * tree-ssa-strlen.c: Include tree-cfg.h.
26074 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
26075 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
26076 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
26078 (strlen_dom_walker::before_dom_children): Call
26079 gimple_purge_dead_eh_edges. Dump tranformation with details
26081 (strlen_dom_walker::before_dom_children): Update call by adding
26082 new argument cleanup_eh.
26083 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
26085 2018-01-03 Martin Liska <mliska@suse.cz>
26088 * cif-code.def (VARIADIC_THUNK): New enum value.
26089 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
26092 2018-01-03 Jan Beulich <jbeulich@suse.com>
26094 * sse.md (mov<mode>_internal): Tighten condition for when to use
26095 vmovdqu<ssescalarsize> for TI and OI modes.
26097 2018-01-03 Jakub Jelinek <jakub@redhat.com>
26099 Update copyright years.
26101 2018-01-03 Martin Liska <mliska@suse.cz>
26104 * ipa-visibility.c (function_and_variable_visibility): Skip
26105 functions with noipa attribure.
26107 2018-01-03 Jakub Jelinek <jakub@redhat.com>
26109 * gcc.c (process_command): Update copyright notice dates.
26110 * gcov-dump.c (print_version): Ditto.
26111 * gcov.c (print_version): Ditto.
26112 * gcov-tool.c (print_version): Ditto.
26113 * gengtype.c (create_file): Ditto.
26114 * doc/cpp.texi: Bump @copying's copyright year.
26115 * doc/cppinternals.texi: Ditto.
26116 * doc/gcc.texi: Ditto.
26117 * doc/gccint.texi: Ditto.
26118 * doc/gcov.texi: Ditto.
26119 * doc/install.texi: Ditto.
26120 * doc/invoke.texi: Ditto.
26122 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26124 * vector-builder.h (vector_builder::m_full_nelts): Change from
26125 unsigned int to poly_uint64.
26126 (vector_builder::full_nelts): Update prototype accordingly.
26127 (vector_builder::new_vector): Likewise.
26128 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
26129 (vector_builder::operator ==): Likewise.
26130 (vector_builder::finalize): Likewise.
26131 * int-vector-builder.h (int_vector_builder::int_vector_builder):
26132 Take the number of elements as a poly_uint64 rather than an
26134 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
26135 from unsigned int to poly_uint64.
26136 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
26137 (vec_perm_indices::new_vector): Likewise.
26138 (vec_perm_indices::length): Likewise.
26139 (vec_perm_indices::nelts_per_input): Likewise.
26140 (vec_perm_indices::input_nelts): Likewise.
26141 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
26142 number of elements per input as a poly_uint64 rather than an
26143 unsigned int. Use the original encoding for variable-length
26144 vectors, rather than clamping each individual element.
26145 For the second and subsequent elements in each pattern,
26146 clamp the step and base before clamping their sum.
26147 (vec_perm_indices::series_p): Handle polynomial element counts.
26148 (vec_perm_indices::all_in_range_p): Likewise.
26149 (vec_perm_indices_to_tree): Likewise.
26150 (vec_perm_indices_to_rtx): Likewise.
26151 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
26152 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
26153 (tree_vector_builder::new_binary_operation): Handle polynomial
26154 element counts. Return false if we need to know the number
26155 of elements at compile time.
26156 * fold-const.c (fold_vec_perm): Punt if the number of elements
26157 isn't known at compile time.
26159 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26161 * vec-perm-indices.h (vec_perm_builder): Change element type
26162 from HOST_WIDE_INT to poly_int64.
26163 (vec_perm_indices::element_type): Update accordingly.
26164 (vec_perm_indices::clamp): Handle polynomial element_types.
26165 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
26166 (vec_perm_indices::all_in_range_p): Likewise.
26167 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
26169 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
26170 polynomial vec_perm_indices element types.
26171 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
26172 * fold-const.c (fold_vec_perm): Likewise.
26173 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
26174 * tree-vect-generic.c (lower_vec_perm): Likewise.
26175 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
26176 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
26177 element type to HOST_WIDE_INT.
26179 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26180 Alan Hayward <alan.hayward@arm.com>
26181 David Sherwood <david.sherwood@arm.com>
26183 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
26184 rather than an int. Use plus_constant.
26185 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
26186 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
26188 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26189 Alan Hayward <alan.hayward@arm.com>
26190 David Sherwood <david.sherwood@arm.com>
26192 * calls.c (emit_call_1, expand_call): Change struct_value_size from
26193 a HOST_WIDE_INT to a poly_int64.
26195 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26196 Alan Hayward <alan.hayward@arm.com>
26197 David Sherwood <david.sherwood@arm.com>
26199 * calls.c (load_register_parameters): Cope with polynomial
26200 mode sizes. Require a constant size for BLKmode parameters
26201 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
26202 forces a parameter to be padded at the lsb end in order to
26203 fill a complete number of words, require the parameter size
26204 to be ordered wrt UNITS_PER_WORD.
26206 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26207 Alan Hayward <alan.hayward@arm.com>
26208 David Sherwood <david.sherwood@arm.com>
26210 * reload1.c (spill_stack_slot_width): Change element type
26211 from unsigned int to poly_uint64_pod.
26212 (alter_reg): Treat mode sizes as polynomial.
26214 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26215 Alan Hayward <alan.hayward@arm.com>
26216 David Sherwood <david.sherwood@arm.com>
26218 * reload.c (complex_word_subreg_p): New function.
26219 (reload_inner_reg_of_subreg, push_reload): Use it.
26221 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26222 Alan Hayward <alan.hayward@arm.com>
26223 David Sherwood <david.sherwood@arm.com>
26225 * lra-constraints.c (process_alt_operands): Reject matched
26226 operands whose sizes aren't ordered.
26227 (match_reload): Refer to this check here.
26229 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26230 Alan Hayward <alan.hayward@arm.com>
26231 David Sherwood <david.sherwood@arm.com>
26233 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
26234 that the mode size is in the set {1, 2, 4, 8, 16}.
26236 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26237 Alan Hayward <alan.hayward@arm.com>
26238 David Sherwood <david.sherwood@arm.com>
26240 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
26241 Use plus_constant instead of gen_rtx_PLUS.
26243 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26244 Alan Hayward <alan.hayward@arm.com>
26245 David Sherwood <david.sherwood@arm.com>
26247 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
26248 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
26249 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
26250 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
26251 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
26252 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
26253 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
26254 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
26255 * config/i386/i386.c (ix86_push_rounding): ...this new function.
26256 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
26258 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
26259 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
26260 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
26261 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
26262 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
26263 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
26264 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
26265 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
26266 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
26267 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
26269 * expr.c (emit_move_resolve_push): Treat the input and result
26270 of PUSH_ROUNDING as a poly_int64.
26271 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
26272 (emit_push_insn): Likewise.
26273 * lra-eliminations.c (mark_not_eliminable): Likewise.
26274 * recog.c (push_operand): Likewise.
26275 * reload1.c (elimination_effects): Likewise.
26276 * rtlanal.c (nonzero_bits1): Likewise.
26277 * calls.c (store_one_arg): Likewise. Require the padding to be
26278 known at compile time.
26280 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26281 Alan Hayward <alan.hayward@arm.com>
26282 David Sherwood <david.sherwood@arm.com>
26284 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
26285 Use plus_constant instead of gen_rtx_PLUS.
26287 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26288 Alan Hayward <alan.hayward@arm.com>
26289 David Sherwood <david.sherwood@arm.com>
26291 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
26292 rather than an int.
26294 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26295 Alan Hayward <alan.hayward@arm.com>
26296 David Sherwood <david.sherwood@arm.com>
26298 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
26299 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
26300 via stack temporaries. Treat the mode size as polynomial too.
26302 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26303 Alan Hayward <alan.hayward@arm.com>
26304 David Sherwood <david.sherwood@arm.com>
26306 * expr.c (expand_expr_real_2): When handling conversions involving
26307 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
26308 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
26309 as a poly_uint64 too.
26311 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26312 Alan Hayward <alan.hayward@arm.com>
26313 David Sherwood <david.sherwood@arm.com>
26315 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
26317 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26318 Alan Hayward <alan.hayward@arm.com>
26319 David Sherwood <david.sherwood@arm.com>
26321 * combine.c (can_change_dest_mode): Handle polynomial
26322 REGMODE_NATURAL_SIZE.
26323 * expmed.c (store_bit_field_1): Likewise.
26324 * expr.c (store_constructor): Likewise.
26325 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
26326 and polynomial REGMODE_NATURAL_SIZE.
26327 (gen_lowpart_common): Likewise.
26328 * reginfo.c (record_subregs_of_mode): Likewise.
26329 * rtlanal.c (read_modify_subreg_p): Likewise.
26331 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26332 Alan Hayward <alan.hayward@arm.com>
26333 David Sherwood <david.sherwood@arm.com>
26335 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
26336 numbers of elements.
26338 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26339 Alan Hayward <alan.hayward@arm.com>
26340 David Sherwood <david.sherwood@arm.com>
26342 * match.pd: Cope with polynomial numbers of vector elements.
26344 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26345 Alan Hayward <alan.hayward@arm.com>
26346 David Sherwood <david.sherwood@arm.com>
26348 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
26349 in a POINTER_PLUS_EXPR.
26351 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26352 Alan Hayward <alan.hayward@arm.com>
26353 David Sherwood <david.sherwood@arm.com>
26355 * omp-simd-clone.c (simd_clone_subparts): New function.
26356 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
26357 (ipa_simd_modify_function_body): Likewise.
26359 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26360 Alan Hayward <alan.hayward@arm.com>
26361 David Sherwood <david.sherwood@arm.com>
26363 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
26364 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
26365 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
26366 (expand_vector_condition, vector_element): Likewise.
26367 (subparts_gt): New function.
26368 (get_compute_type): Use subparts_gt.
26369 (count_type_subparts): Delete.
26370 (expand_vector_operations_1): Use subparts_gt instead of
26371 count_type_subparts.
26373 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26374 Alan Hayward <alan.hayward@arm.com>
26375 David Sherwood <david.sherwood@arm.com>
26377 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
26378 (vect_compile_time_alias): ...this new function. Do the calculation
26379 on poly_ints rather than trees.
26380 (vect_prune_runtime_alias_test_list): Update call accordingly.
26382 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26383 Alan Hayward <alan.hayward@arm.com>
26384 David Sherwood <david.sherwood@arm.com>
26386 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
26388 (vect_schedule_slp_instance): Likewise.
26390 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26391 Alan Hayward <alan.hayward@arm.com>
26392 David Sherwood <david.sherwood@arm.com>
26394 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
26395 constant and extern definitions for variable-length vectors.
26396 (vect_get_constant_vectors): Note that the number of units
26397 is known to be constant.
26399 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26400 Alan Hayward <alan.hayward@arm.com>
26401 David Sherwood <david.sherwood@arm.com>
26403 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
26404 of units as polynomial. Choose between WIDE and NARROW based
26407 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26408 Alan Hayward <alan.hayward@arm.com>
26409 David Sherwood <david.sherwood@arm.com>
26411 * tree-vect-stmts.c (simd_clone_subparts): New function.
26412 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
26414 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26415 Alan Hayward <alan.hayward@arm.com>
26416 David Sherwood <david.sherwood@arm.com>
26418 * tree-vect-stmts.c (vectorizable_call): Treat the number of
26419 vectors as polynomial. Use build_index_vector for
26420 IFN_GOMP_SIMD_LANE.
26422 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26423 Alan Hayward <alan.hayward@arm.com>
26424 David Sherwood <david.sherwood@arm.com>
26426 * tree-vect-stmts.c (get_load_store_type): Treat the number of
26427 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
26428 for variable-length vectors.
26429 (vectorizable_mask_load_store): Treat the number of units as
26430 polynomial, asserting that it is constant if the condition has
26431 already been enforced.
26432 (vectorizable_store, vectorizable_load): Likewise.
26434 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26435 Alan Hayward <alan.hayward@arm.com>
26436 David Sherwood <david.sherwood@arm.com>
26438 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
26439 of units as polynomial. Punt if we can't tell at compile time
26440 which vector contains the final result.
26442 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26443 Alan Hayward <alan.hayward@arm.com>
26444 David Sherwood <david.sherwood@arm.com>
26446 * tree-vect-loop.c (vectorizable_induction): Treat the number
26447 of units as polynomial. Punt on SLP inductions. Use an integer
26448 VEC_SERIES_EXPR for variable-length integer reductions. Use a
26449 cast of such a series for variable-length floating-point
26452 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26453 Alan Hayward <alan.hayward@arm.com>
26454 David Sherwood <david.sherwood@arm.com>
26456 * tree.h (build_index_vector): Declare.
26457 * tree.c (build_index_vector): New function.
26458 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
26459 of units as polynomial, forcibly converting it to a constant if
26460 vectorizable_reduction has already enforced the condition.
26461 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
26462 to create a {1,2,3,...} vector.
26463 (vectorizable_reduction): Treat the number of units as polynomial.
26464 Choose vectype_in based on the largest scalar element size rather
26465 than the smallest number of units. Enforce the restrictions
26468 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26469 Alan Hayward <alan.hayward@arm.com>
26470 David Sherwood <david.sherwood@arm.com>
26472 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
26473 number of units as polynomial.
26475 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26476 Alan Hayward <alan.hayward@arm.com>
26477 David Sherwood <david.sherwood@arm.com>
26479 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
26480 * target.def (autovectorize_vector_sizes): Return the vector sizes
26481 by pointer, using vector_sizes rather than a bitmask.
26482 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
26483 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
26484 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
26486 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
26487 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
26488 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
26489 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
26490 * omp-general.c (omp_max_vf): Likewise.
26491 * omp-low.c (omp_clause_aligned_alignment): Likewise.
26492 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
26493 * tree-vect-loop.c (vect_analyze_loop): Likewise.
26494 * tree-vect-slp.c (vect_slp_bb): Likewise.
26495 * doc/tm.texi: Regenerate.
26496 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
26498 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
26499 the vector size as a poly_uint64 rather than an unsigned int.
26500 (current_vector_size): Change from an unsigned int to a poly_uint64.
26501 (get_vectype_for_scalar_type): Update accordingly.
26502 * tree.h (build_truth_vector_type): Take the size and number of
26503 units as a poly_uint64 rather than an unsigned int.
26504 (build_vector_type): Add a temporary overload that takes
26505 the number of units as a poly_uint64 rather than an unsigned int.
26506 * tree.c (make_vector_type): Likewise.
26507 (build_truth_vector_type): Take the number of units as a poly_uint64
26508 rather than an unsigned int.
26510 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26511 Alan Hayward <alan.hayward@arm.com>
26512 David Sherwood <david.sherwood@arm.com>
26514 * target.def (get_mask_mode): Take the number of units and length
26515 as poly_uint64s rather than unsigned ints.
26516 * targhooks.h (default_get_mask_mode): Update accordingly.
26517 * targhooks.c (default_get_mask_mode): Likewise.
26518 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
26519 * doc/tm.texi: Regenerate.
26521 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26522 Alan Hayward <alan.hayward@arm.com>
26523 David Sherwood <david.sherwood@arm.com>
26525 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
26526 * omp-general.c (omp_max_vf): Likewise.
26527 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
26528 (expand_omp_simd): Handle polynomial safelen.
26529 * omp-low.c (omplow_simd_context): Add a default constructor.
26530 (omplow_simd_context::max_vf): Change from int to poly_uint64.
26531 (lower_rec_simd_input_clauses): Update accordingly.
26532 (lower_rec_input_clauses): Likewise.
26534 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26535 Alan Hayward <alan.hayward@arm.com>
26536 David Sherwood <david.sherwood@arm.com>
26538 * tree-vectorizer.h (vect_nunits_for_cost): New function.
26539 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
26540 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
26541 (vect_analyze_slp_cost): Likewise.
26542 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
26543 (vect_model_load_cost): Likewise.
26545 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26546 Alan Hayward <alan.hayward@arm.com>
26547 David Sherwood <david.sherwood@arm.com>
26549 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
26550 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
26551 from an unsigned int * to a poly_uint64_pod *.
26552 (calculate_unrolling_factor): New function.
26553 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
26555 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26556 Alan Hayward <alan.hayward@arm.com>
26557 David Sherwood <david.sherwood@arm.com>
26559 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
26560 from an unsigned int to a poly_uint64.
26561 (_loop_vec_info::slp_unrolling_factor): Likewise.
26562 (_loop_vec_info::vectorization_factor): Change from an int
26564 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
26565 (vect_get_num_vectors): New function.
26566 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
26567 (vect_get_num_copies): Use vect_get_num_vectors.
26568 (vect_analyze_data_ref_dependences): Change max_vf from an int *
26569 to an unsigned int *.
26570 (vect_analyze_data_refs): Change min_vf from an int * to a
26572 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
26573 than an unsigned HOST_WIDE_INT.
26574 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
26575 (vect_analyze_data_ref_dependence): Change max_vf from an int *
26576 to an unsigned int *.
26577 (vect_analyze_data_ref_dependences): Likewise.
26578 (vect_compute_data_ref_alignment): Handle polynomial vf.
26579 (vect_enhance_data_refs_alignment): Likewise.
26580 (vect_prune_runtime_alias_test_list): Likewise.
26581 (vect_shift_permute_load_chain): Likewise.
26582 (vect_supportable_dr_alignment): Likewise.
26583 (dependence_distance_ge_vf): Take the vectorization factor as a
26584 poly_uint64 rather than an unsigned HOST_WIDE_INT.
26585 (vect_analyze_data_refs): Change min_vf from an int * to a
26587 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
26588 vfm1 as a poly_uint64 rather than an int. Make the same change
26589 for the returned bound_scalar.
26590 (vect_gen_vector_loop_niters): Handle polynomial vf.
26591 (vect_do_peeling): Likewise. Update call to
26592 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
26593 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
26595 * tree-vect-loop.c (vect_determine_vectorization_factor)
26596 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
26597 (vect_get_known_peeling_cost): Likewise.
26598 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
26599 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
26600 (vect_transform_loop): Likewise. Use the lowest possible VF when
26601 updating the upper bounds of the loop.
26602 (vect_min_worthwhile_factor): Make static. Return an unsigned int
26603 rather than an int.
26604 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
26605 polynomial unroll factors.
26606 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
26607 (vect_make_slp_decision): Likewise.
26608 (vect_supported_load_permutation_p): Likewise, and polynomial
26610 (vect_analyze_slp_cost): Handle polynomial vf.
26611 (vect_slp_analyze_node_operations): Likewise.
26612 (vect_slp_analyze_bb_1): Likewise.
26613 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
26614 than an unsigned HOST_WIDE_INT.
26615 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
26616 (vectorizable_load): Handle polynomial vf.
26617 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
26619 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
26621 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26622 Alan Hayward <alan.hayward@arm.com>
26623 David Sherwood <david.sherwood@arm.com>
26625 * match.pd: Handle bit operations involving three constants
26626 and try to fold one pair.
26628 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
26630 * tree-vect-loop-manip.c: Include gimple-fold.h.
26631 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
26632 niters_maybe_zero parameters. Handle other cases besides a step of 1.
26633 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
26634 Add a path that uses a step of VF instead of 1, but disable it
26636 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
26637 and niters_no_overflow parameters. Update calls to
26638 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
26639 Create a new SSA name if the latter choses to use a ste other
26640 than zero, and return it via niters_vector_mult_vf_var.
26641 * tree-vect-loop.c (vect_transform_loop): Update calls to
26642 vect_do_peeling, vect_gen_vector_loop_niters and
26643 slpeel_make_loop_iterate_ntimes.
26644 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
26645 (vect_gen_vector_loop_niters): Update declarations after above changes.
26647 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
26649 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
26650 128-bit round to integer instructions.
26651 (ceil<mode>2): Likewise.
26652 (btrunc<mode>2): Likewise.
26653 (round<mode>2): Likewise.
26655 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
26657 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
26658 unaligned VSX load/store on P8/P9.
26659 (expand_block_clear): Allow the use of unaligned VSX
26660 load/store on P8/P9.
26662 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
26664 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
26666 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
26667 swap associated with both a load and a store.
26669 2018-01-02 Andrew Waterman <andrew@sifive.com>
26671 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
26672 * config/riscv/riscv.md (clear_cache): Use it.
26674 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
26676 * web.c: Remove out-of-date comment.
26678 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26680 * expr.c (fixup_args_size_notes): Check that any existing
26681 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
26682 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
26683 (emit_single_push_insn): ...here.
26685 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26687 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
26688 (const_vector_encoded_nelts): New function.
26689 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
26690 (const_vector_int_elt, const_vector_elt): Declare.
26691 * emit-rtl.c (const_vector_int_elt_1): New function.
26692 (const_vector_elt): Likewise.
26693 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
26694 of CONST_VECTOR_ELT.
26696 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26698 * expr.c: Include rtx-vector-builder.h.
26699 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
26700 directly on the tree encoding.
26701 (const_vector_from_tree): Likewise.
26702 * optabs.c: Include rtx-vector-builder.h.
26703 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
26704 sequence of "u" values.
26705 * vec-perm-indices.c: Include rtx-vector-builder.h.
26706 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
26707 directly on the vec_perm_indices encoding.
26709 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26711 * doc/rtl.texi (const_vector): Describe new encoding scheme.
26712 * Makefile.in (OBJS): Add rtx-vector-builder.o.
26713 * rtx-vector-builder.h: New file.
26714 * rtx-vector-builder.c: Likewise.
26715 * rtl.h (rtx_def::u2): Add a const_vector field.
26716 (CONST_VECTOR_NPATTERNS): New macro.
26717 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
26718 (CONST_VECTOR_DUPLICATE_P): Likewise.
26719 (CONST_VECTOR_STEPPED_P): Likewise.
26720 (CONST_VECTOR_ENCODED_ELT): Likewise.
26721 (const_vec_duplicate_p): Check for a duplicated vector encoding.
26722 (unwrap_const_vec_duplicate): Likewise.
26723 (const_vec_series_p): Check for a non-duplicated vector encoding.
26724 Say that the function only returns true for integer vectors.
26725 * emit-rtl.c: Include rtx-vector-builder.h.
26726 (gen_const_vec_duplicate_1): Delete.
26727 (gen_const_vector): Call gen_const_vec_duplicate instead of
26728 gen_const_vec_duplicate_1.
26729 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
26730 (gen_const_vec_duplicate): Use rtx_vector_builder.
26731 (gen_const_vec_series): Likewise.
26732 (gen_rtx_CONST_VECTOR): Likewise.
26733 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
26734 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
26735 Build a new vector rather than modifying a CONST_VECTOR in-place.
26736 (handle_special_swappables): Update call accordingly.
26737 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
26738 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
26739 Build a new vector rather than modifying a CONST_VECTOR in-place.
26740 (handle_special_swappables): Update call accordingly.
26742 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26744 * simplify-rtx.c (simplify_const_binary_operation): Use
26745 CONST_VECTOR_ELT instead of XVECEXP.
26747 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26749 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
26750 the selector elements to be different from the data elements
26751 if the selector is a VECTOR_CST.
26752 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
26753 ssizetype for the selector.
26755 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26757 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
26758 before testing each element individually.
26759 * tree-vect-generic.c (lower_vec_perm): Likewise.
26761 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26763 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
26764 * selftest-run-tests.c (selftest::run_tests): Call it.
26765 * vector-builder.h (vector_builder::operator ==): New function.
26766 (vector_builder::operator !=): Likewise.
26767 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
26768 (vec_perm_indices::all_from_input_p): New function.
26769 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
26770 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
26771 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
26772 instead of reading the VECTOR_CST directly. Detect whether both
26773 vector inputs are the same before constructing the vec_perm_indices,
26774 and update the number of inputs argument accordingly. Use the
26775 utility functions added above. Only construct sel2 if we need to.
26777 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26779 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
26780 the broadcast of the low byte.
26781 (expand_mult_highpart): Use an explicit encoding for the permutes.
26782 * optabs-query.c (can_mult_highpart_p): Likewise.
26783 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
26784 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
26785 (vectorizable_bswap): Likewise.
26786 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
26787 explicit encoding for the power-of-2 permutes.
26788 (vect_permute_store_chain): Likewise.
26789 (vect_grouped_load_supported): Likewise.
26790 (vect_permute_load_chain): Likewise.
26792 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26794 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
26795 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
26796 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
26797 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
26798 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
26799 (vect_gen_perm_mask_any): Likewise.
26801 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26803 * int-vector-builder.h: New file.
26804 * vec-perm-indices.h: Include int-vector-builder.h.
26805 (vec_perm_indices): Redefine as an int_vector_builder.
26806 (auto_vec_perm_indices): Delete.
26807 (vec_perm_builder): Redefine as a stand-alone class.
26808 (vec_perm_indices::vec_perm_indices): New function.
26809 (vec_perm_indices::clamp): Likewise.
26810 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
26811 (vec_perm_indices::new_vector): New function.
26812 (vec_perm_indices::new_expanded_vector): Update for new
26813 vec_perm_indices class.
26814 (vec_perm_indices::rotate_inputs): New function.
26815 (vec_perm_indices::all_in_range_p): Operate directly on the
26816 encoded form, without computing elided elements.
26817 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
26818 encoding. Update for new vec_perm_indices class.
26819 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
26820 the given vec_perm_builder.
26821 (expand_vec_perm_var): Update vec_perm_builder constructor.
26822 (expand_mult_highpart): Use vec_perm_builder instead of
26823 auto_vec_perm_indices.
26824 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
26825 vec_perm_indices instead of auto_vec_perm_indices. Use a single
26826 or double series encoding as appropriate.
26827 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
26828 vec_perm_indices instead of auto_vec_perm_indices.
26829 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
26830 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
26831 (vect_permute_store_chain): Likewise.
26832 (vect_grouped_load_supported): Likewise.
26833 (vect_permute_load_chain): Likewise.
26834 (vect_shift_permute_load_chain): Likewise.
26835 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
26836 (vect_transform_slp_perm_load): Likewise.
26837 (vect_schedule_slp_instance): Likewise.
26838 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
26839 (vectorizable_mask_load_store): Likewise.
26840 (vectorizable_bswap): Likewise.
26841 (vectorizable_store): Likewise.
26842 (vectorizable_load): Likewise.
26843 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
26844 vec_perm_indices instead of auto_vec_perm_indices. Use
26845 tree_to_vec_perm_builder to read the vector from a tree.
26846 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
26847 vec_perm_builder instead of a vec_perm_indices.
26848 (have_whole_vector_shift): Use vec_perm_builder and
26849 vec_perm_indices instead of auto_vec_perm_indices. Leave the
26850 truncation to calc_vec_perm_mask_for_shift.
26851 (vect_create_epilog_for_reduction): Likewise.
26852 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
26853 from auto_vec_perm_indices to vec_perm_indices.
26854 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
26855 instead of changing individual elements.
26856 (aarch64_vectorize_vec_perm_const): Use new_vector to install
26857 the vector in d.perm.
26858 * config/arm/arm.c (expand_vec_perm_d::perm): Change
26859 from auto_vec_perm_indices to vec_perm_indices.
26860 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
26861 instead of changing individual elements.
26862 (arm_vectorize_vec_perm_const): Use new_vector to install
26863 the vector in d.perm.
26864 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
26865 Update vec_perm_builder constructor.
26866 (rs6000_expand_interleave): Likewise.
26867 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
26868 (rs6000_expand_interleave): Likewise.
26870 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26872 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
26873 to qimode could truncate the indices.
26874 * optabs.c (expand_vec_perm_var): Likewise.
26876 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
26878 * Makefile.in (OBJS): Add vec-perm-indices.o.
26879 * vec-perm-indices.h: New file.
26880 * vec-perm-indices.c: Likewise.
26881 * target.h (vec_perm_indices): Replace with a forward class
26883 (auto_vec_perm_indices): Move to vec-perm-indices.h.
26884 * optabs.h: Include vec-perm-indices.h.
26885 (expand_vec_perm): Delete.
26886 (selector_fits_mode_p, expand_vec_perm_var): Declare.
26887 (expand_vec_perm_const): Declare.
26888 * target.def (vec_perm_const_ok): Replace with...
26889 (vec_perm_const): ...this new hook.
26890 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
26891 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
26892 * doc/tm.texi: Regenerate.
26893 * optabs.def (vec_perm_const): Delete.
26894 * doc/md.texi (vec_perm_const): Likewise.
26895 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
26896 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
26897 expand_vec_perm for constant permutation vectors. Assert that
26898 the mode of variable permutation vectors is the integer equivalent
26899 of the mode that is being permuted.
26900 * optabs-query.h (selector_fits_mode_p): Declare.
26901 * optabs-query.c: Include vec-perm-indices.h.
26902 (selector_fits_mode_p): New function.
26903 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
26904 is defined, instead of checking whether the vec_perm_const_optab
26905 exists. Use targetm.vectorize.vec_perm_const instead of
26906 targetm.vectorize.vec_perm_const_ok. Check whether the indices
26907 fit in the vector mode before using a variable permute.
26908 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
26909 vec_perm_indices instead of an rtx.
26910 (expand_vec_perm): Replace with...
26911 (expand_vec_perm_const): ...this new function. Take the selector
26912 as a vec_perm_indices rather than an rtx. Also take the mode of
26913 the selector. Update call to shift_amt_for_vec_perm_mask.
26914 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
26915 Use vec_perm_indices::new_expanded_vector to expand the original
26916 selector into bytes. Check whether the indices fit in the vector
26917 mode before using a variable permute.
26918 (expand_vec_perm_var): Make global.
26919 (expand_mult_highpart): Use expand_vec_perm_const.
26920 * fold-const.c: Includes vec-perm-indices.h.
26921 * tree-ssa-forwprop.c: Likewise.
26922 * tree-vect-data-refs.c: Likewise.
26923 * tree-vect-generic.c: Likewise.
26924 * tree-vect-loop.c: Likewise.
26925 * tree-vect-slp.c: Likewise.
26926 * tree-vect-stmts.c: Likewise.
26927 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
26929 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
26930 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
26931 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
26932 (aarch64_vectorize_vec_perm_const): ...this new function.
26933 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
26934 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
26935 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
26936 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
26937 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
26938 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
26939 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
26941 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
26942 check for NEON modes.
26943 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
26944 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
26945 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
26946 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
26948 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
26949 the old VEC_PERM_CONST conditions.
26950 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
26951 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
26952 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
26953 (ia64_vectorize_vec_perm_const_ok): Merge into...
26954 (ia64_vectorize_vec_perm_const): ...this new function.
26955 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
26956 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
26957 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
26958 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
26959 * config/mips/mips.c (mips_expand_vec_perm_const)
26960 (mips_vectorize_vec_perm_const_ok): Merge into...
26961 (mips_vectorize_vec_perm_const): ...this new function.
26962 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
26963 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
26964 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
26965 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
26966 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
26967 (rs6000_expand_vec_perm_const): Delete.
26968 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
26970 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
26971 (altivec_expand_vec_perm_const_le): Take each operand individually.
26972 Operate on constant selectors rather than rtxes.
26973 (altivec_expand_vec_perm_const): Likewise. Update call to
26974 altivec_expand_vec_perm_const_le.
26975 (rs6000_expand_vec_perm_const): Delete.
26976 (rs6000_vectorize_vec_perm_const_ok): Delete.
26977 (rs6000_vectorize_vec_perm_const): New function.
26978 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
26979 an element count and rtx array.
26980 (rs6000_expand_extract_even): Update call accordingly.
26981 (rs6000_expand_interleave): Likewise.
26982 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
26983 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
26984 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
26985 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
26986 (rs6000_expand_vec_perm_const): Delete.
26987 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
26988 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
26989 (altivec_expand_vec_perm_const_le): Take each operand individually.
26990 Operate on constant selectors rather than rtxes.
26991 (altivec_expand_vec_perm_const): Likewise. Update call to
26992 altivec_expand_vec_perm_const_le.
26993 (rs6000_expand_vec_perm_const): Delete.
26994 (rs6000_vectorize_vec_perm_const_ok): Delete.
26995 (rs6000_vectorize_vec_perm_const): New function. Remove stray
26996 reference to the SPE evmerge intructions.
26997 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
26998 an element count and rtx array.
26999 (rs6000_expand_extract_even): Update call accordingly.
27000 (rs6000_expand_interleave): Likewise.
27001 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
27002 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
27004 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
27006 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
27008 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
27009 vector mode and that that mode matches the mode of the data
27011 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
27012 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
27013 directly using expand_vec_perm_1 when forcing selectors into
27015 (expand_vec_perm_var): New function, split out from expand_vec_perm.
27017 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
27019 * optabs-query.h (can_vec_perm_p): Delete.
27020 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
27021 * optabs-query.c (can_vec_perm_p): Split into...
27022 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
27023 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
27024 particular selector is valid.
27025 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
27026 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
27027 (vect_grouped_load_supported): Likewise.
27028 (vect_shift_permute_load_chain): Likewise.
27029 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
27030 (vect_transform_slp_perm_load): Likewise.
27031 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
27032 (vectorizable_bswap): Likewise.
27033 (vect_gen_perm_mask_checked): Likewise.
27034 * fold-const.c (fold_ternary_loc): Likewise. Don't take
27035 implementations of variable permutation vectors into account
27036 when deciding which selector to use.
27037 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
27038 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
27039 with a false third argument.
27040 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
27041 to test whether the constant selector is valid and can_vec_perm_var_p
27042 to test whether a variable selector is valid.
27044 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
27046 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
27047 * optabs-query.c (can_vec_perm_p): Likewise.
27048 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
27049 instead of vec_perm_indices.
27050 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
27051 (vect_gen_perm_mask_checked): Likewise,
27052 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
27053 (vect_gen_perm_mask_checked): Likewise,
27055 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
27057 * optabs-query.h (qimode_for_vec_perm): Declare.
27058 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
27059 (qimode_for_vec_perm): ...this new function.
27060 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
27062 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
27064 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
27065 does not have a conditional at the top.
27067 2018-01-02 Richard Biener <rguenther@suse.de>
27069 * ipa-inline.c (big_speedup_p): Fix expression.
27071 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
27074 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
27077 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
27081 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
27082 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
27083 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
27084 cond_taken_branch_cost 3->4.
27086 2018-01-01 Jakub Jelinek <jakub@redhat.com>
27088 PR tree-optimization/83581
27089 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
27090 TODO_cleanup_cfg if any changes have been made.
27092 PR middle-end/83608
27093 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
27094 convert_modes if target mode has the right side, but different mode
27097 PR middle-end/83609
27098 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
27099 last argument when extracting from CONCAT. If either from_real or
27100 from_imag is NULL, use expansion through memory. If result is not
27101 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
27102 the parts directly to inner mode, if even that fails, use expansion
27105 PR middle-end/83623
27106 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
27107 check for bswap in mode rather than HImode and use that in expand_unop
27110 Copyright (C) 2018 Free Software Foundation, Inc.
27112 Copying and distribution of this file, with or without modification,
27113 are permitted in any medium without royalty provided the copyright
27114 notice and this notice are preserved.