1 2018-12-17 David Edelsohn <dje.gcc@gmail.com>
3 * config.gcc (powerpc-ibm-aix6.*): Delete extra_headers.
4 (powerpc-ibm-aix7.1.*): Same.
5 (powerpc-ibm-aix[789].*): Same.
7 2018-12-17 H.J. Lu <hongjiu.lu@intel.com>
10 * dwarf2out.c (find_AT_string_in_table): Add insert argument
11 defaulting to INSERT and replace INSERT.
12 (find_AT_string): Likewise.
13 (output_macinfo_op): Pass NO_INSERT to find_AT_string.
15 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
17 * coverage.c (struct conts_entry): Add n_counts.
18 (remap_counts_file): Record number of ocunts.
19 (get_coverage_counts): Verify that counts match.
20 * coverage.h (get_coverage_counts): Update prototype.
21 * profile.c (get_exec_counts. compute_value_histograms): Add
24 2018-12-17 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
26 PR rtl-optimization/88253
27 * combine.c (combine_simplify_rtx): Test for side-effects before
30 2018-12-17 Richard Sandiford <richard.sandiford@arm.com>
32 * doc/invoke.texi (-fversion-loops-for-strides): Document
33 (loop-versioning-group-size, loop-versioning-max-inner-insns)
34 (loop-versioning-max-outer-insns): Document new --params.
35 * Makefile.in (OBJS): Add gimple-loop-versioning.o.
36 * common.opt (fversion-loops-for-strides): New option.
37 * opts.c (default_options_table): Enable fversion-loops-for-strides
39 * params.def (PARAM_LOOP_VERSIONING_GROUP_SIZE)
40 (PARAM_LOOP_VERSIONING_MAX_INNER_INSNS)
41 (PARAM_LOOP_VERSIONING_MAX_OUTER_INSNS): New parameters.
42 * passes.def: Add pass_loop_versioning.
43 * timevar.def (TV_LOOP_VERSIONING): New time variable.
44 * tree-ssa-propagate.h
45 (substitute_and_fold_engine::substitute_and_fold): Add an optional
47 * tree-ssa-propagate.c
48 (substitute_and_fold_engine::substitute_and_fold): Likewise.
49 When passed, only walk blocks dominated by that block.
50 * tree-vrp.h (range_includes_p): Declare.
51 (range_includes_zero_p): Turn into an inline wrapper around
53 * tree-vrp.c (range_includes_p): New function, generalizing...
54 (range_includes_zero_p): ...this.
55 * tree-pass.h (make_pass_loop_versioning): Declare.
56 * gimple-loop-versioning.cc: New file.
58 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
60 * ipa-fnsummary.c (remap_edge_change_prob): Do not ICE when changes
63 2018-12-15 H.J. Lu <hongjiu.lu@intel.com>
66 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Revert
69 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
71 * ipa-fnsummary.c (analyze_function_body): Do not loeak conds and
73 (ipa_fn_summary_generate): Add prevails parameter; do not allocate
74 data when symbol is not prevailing.
75 (inline_read_section): Likewise.
77 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
79 * cgraph.h (cgraph_node): Add predicate prevailing_p.
80 (cgraph_edge): Add predicate possible_call_in_translation_unit_p.
81 * ipa-prop.c (ipa_write_jump_function): Optimize streaming of ADDR_EXPR.
82 (ipa_read_jump_function): Add prevails parameter; optimize streaming.
83 (ipa_read_edge_info): Break out from ...
84 (ipa_read_node_info): ... here; optimize streaming.
85 * cgraph.c (cgraph_edge::possibly_call_in_translation_unit_p): New
88 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
90 * ipa-utils.c (ipa_merge_profiles): Do no merging when source function
93 2018-12-15 Jakub Jelinek <jakub@redhat.com>
95 PR tree-optimization/88464
97 * tree-vect-stmts.c (vect_build_gather_load_calls): For NARROWING
98 and mask with integral masktype, don't try to permute mask vectors,
99 instead emit VEC_UNPACK_{LO,HI}_EXPR. Fix up NOP_EXPR operand.
100 (vectorizable_store): Handle masked scatters with decl and integral
102 (permute_vec_elements): Allow scalar_dest to be NULL.
103 * config/i386/i386.c (ix86_get_builtin)
104 <case IX86_BUILTIN_GATHER3ALTDIV16SF>: Use lowpart_subreg for masks.
105 <case IX86_BUILTIN_GATHER3ALTDIV8SF>: Don't assume mask and src have
108 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
110 * ipa.c (cgraph_build_static_cdtor_1): Add OPTIMIZATION and TARGET
112 (cgraph_build_static_cdtor): Update.
113 (build_cdtor): Use OPTIMIZATION and TARGET of the first real cdtor
116 2018-12-15 Alan Modra <amodra@gmail.com>
118 * config/rs6000/rs6000.c (generate_set_vrsave, rs6000_emit_savres_rtx),
119 (rs6000_emit_prologue, rs6000_call_aix, rs6000_call_sysv),
120 (rs6000_call_darwin_1): Use gen_hard_reg_clobber.
122 2018-12-15 Jakub Jelinek <jakub@redhat.com>
125 * config/i386/sse.md (UNSPEC_SFIXUPIMM): New unspec enumerator.
126 (avx512f_sfixupimm<mode><mask_name><round_saeonly_name>): Use it
127 instead of UNSPEC_FIXUPIMM.
129 PR rtl-optimization/88478
130 * cselib.c (cselib_record_sets): Move sets[i].src_elt tests
131 after REG_P (dest) test.
133 2018-12-14 Martin Sebor <msebor@redhat.com>
135 PR tree-optimization/88372
136 * calls.c (maybe_warn_alloc_args_overflow): Handle function pointers.
137 * tree-object-size.c (alloc_object_size): Same. Simplify.
138 * doc/extend.texi (Object Size Checking): Update.
139 (Other Builtins): Add __builtin_object_size.
140 (Common Type Attributes): Add alloc_size.
141 (Common Variable Attributes): Ditto.
143 2018-12-14 Martin Sebor <msebor@redhat.com>
145 PR rtl-optimization/87096
146 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Avoid
147 folding calls whose bound may exceed INT_MAX. Diagnose bound ranges
148 that exceed the limit.
150 2018-12-14 Martin Sebor <msebor@redhat.com>
153 * doc/extend.texi (attribute const, pure): Clarify.
155 2018-12-14 H.J. Lu <hongjiu.lu@intel.com>
157 * config/i386/i386.c (rest_of_insert_endbranch): Insert ENDBR
158 at the function entry only when -mmanual-endbr isn't used or
159 there is cf_check function attribute.
160 (ix86_attribute_table): Add cf_check.
161 * config/i386/i386.opt: Add -mmanual-endbr.
162 * doc/extend.texi: Document cf_check attribute.
163 * doc/invoke.texi: Document -mmanual-endbr.
165 2018-12-14 Thomas Schwinge <thomas@codesourcery.com>
166 Cesar Philippidis <cesar@codesourcery.com>
168 * omp-offload.c (inform_oacc_loop): New function.
169 (execute_oacc_device_lower): Use it to display loop parallelism.
171 2018-12-14 Jakub Jelinek <jakub@redhat.com>
175 * expr.h (categorize_ctor_elements): Add p_unique_nz_elts argument.
176 * expr.c (categorize_ctor_elements_1): Likewise. Compute it like
177 p_nz_elts, except don't multiply it by mult. Adjust recursive call.
178 Fix up COMPLEX_CST handling.
179 (categorize_ctor_elements): Add p_unique_nz_elts argument, initialize
180 it and pass it through to categorize_ctor_elements_1.
181 (mostly_zeros_p, all_zeros_p): Adjust categorize_ctor_elements callers.
182 * gimplify.c (gimplify_init_constructor): Likewise. Don't force
183 ctor into readonly data section if num_unique_nonzero_elements is
184 smaller or equal to 1/8 of num_nonzero_elements and size is >= 64
187 2018-12-14 Thomas Preud'homme <thomas.preudhomme@arm.com>
189 * config/arm/arm.md (arm_movdi): Split if -mslow-flash-data and
190 source is a constant that would be loaded by literal pool.
191 (movsf expander): Generate a no_literal_pool_sf_immediate insn if
192 -mslow-flash-data is present, targeting hardfloat ABI and source is a
193 float constant that cannot be loaded via vmov.
194 (movdf expander): Likewise but generate a no_literal_pool_df_immediate
196 (arm_movsf_soft_insn): Split if -mslow-flash-data and source is a
197 float constant that would be loaded by literal pool.
198 (softfloat constant movsf splitter): Splitter for the above case.
199 (movdf_soft_insn): Split if -mslow-flash-data and source is a float
200 constant that would be loaded by literal pool.
201 (softfloat constant movdf splitter): Splitter for the above case.
202 * config/arm/constraints.md (Pz): Document existing constraint.
203 (Ha): Define constraint.
205 * config/arm/predicates.md (hard_sf_operand): New predicate.
206 (hard_df_operand): Likewise.
207 * config/arm/thumb2.md (thumb2_movsi_insn): Split if
208 -mslow-flash-data and constant would be loaded by literal pool.
209 * constant/arm/vfp.md (thumb2_movsi_vfp): Likewise and disable constant
210 load in VFP register.
211 (movdi_vfp): Likewise.
212 (thumb2_movsf_vfp): Use hard_sf_operand as predicate for source to
213 prevent match for a constant load if -mslow-flash-data and constant
214 cannot be loaded via vmov. Adapt constraint accordingly by
215 using Ha instead of E for generic floating-point constant load.
216 (thumb2_movdf_vfp): Likewise using hard_df_operand predicate instead.
217 (no_literal_pool_df_immediate): Add a clobber to use as the
218 intermediate general purpose register and also enable it after reload
219 but disable it constant is a valid FP constant. Add constraints and
220 generate a DI intermediate load rather than 2 SI loads.
221 (no_literal_pool_sf_immediate): Add a clobber to use as the
222 intermediate general purpose register and also enable it after
225 2018-12-14 Uros Bizjak <ubizjak@gmail.com>
228 * internal-fn.def (HYPOT): New.
229 * optabs.def (hypot_optab): New.
230 * config/i386/i386.md (hypot<mode>3): New expander.
232 2018-12-14 Jeff Law <law@redhat.com>
234 * target.def (post_cfi_startproc): Fix text.
236 2018-12-14 Sam Tebbs <sam.tebbs@arm.com>
238 * doc/tm.texi (TARGET_ASM_POST_CFI_STARTPROC): Define.
239 * doc/tm.texi.in (TARGET_ASM_POST_CFI_STARTPROC): Define.
240 * dwarf2out.c (dwarf2out_do_cfi_startproc): Trigger the hook.
241 * hooks.c (hook_void_FILEptr_tree): Define.
242 * hooks.h (hook_void_FILEptr_tree): Define.
243 * target.def (post_cfi_startproc): Define.
245 2018-12-14 Tom de Vries <tdevries@suse.de>
247 * lto-cgraph.c (verify_node_partition): New function.
248 (input_overwrite_node, input_varpool_node): Use verify_node_partition.
250 2018-12-14 H.J. Lu <hongjiu.lu@intel.com>
253 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Don't
254 use get_frame_size ().
256 2018-12-14 Andrew Stubbs <ams@codesourcery.com>
258 * gcc/lra-int.h (lra_register_new_scratch_op): Add third parameter.
259 * gcc/lra-remat.c (update_scratch_ops): Pass icode to
260 lra_register_new_scratch_op.
261 * gcc/lra.c (struct sloc): Add icode field.
262 (lra_register_new_scratch_op): Add icode parameter.
263 Use icode to skip insns that have changed beyond recognition.
265 2018-12-14 Eric Botcazou <ebotcazou@adacore.com>
267 * dwarf2out.c (analyze_discr_in_predicate): Simplify.
268 (analyze_variants_discr): Deal with naked boolean discriminants.
270 2018-12-14 Claudiu Zissulescu <claziss@synopsys.com>
272 * config/arc/arc.c (arc_restore_callee_milli) Don't clobber off
275 2018-12-14 Claudiu Zissulescu <claziss@synopsys.com>
277 * config/arc/arc.h (reg_class): Add SIBCALL_REGS.
279 2018-12-14 Richard Biener <rguenther@suse.de>
281 * gimple-ssa-split-paths.c (is_feasible_trace): Remove
282 duplicated code block.
284 2018-12-14 Alan Modra <amodra@gmail.com>
286 PR rtl-optimization/88311
287 * config/rs6000/rs6000.c (rs6000_call_sysv): Do not mask cookie.
288 (rs6000_sibcall_sysv): Likewise.
290 2018-12-14 Segher Boessenkool <segher@kernel.crashing.org>
292 PR rtl-optimization/88001
293 * function.c (match_asm_constraints_1): Don't invalidly share RTL.
295 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
297 * auto-profile.c (afdo_annotate_cfg): Call update_max_bb_count even
298 if autofdo counts are all zeros.
300 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
302 * auto-profile.c (afdo_indirect_call): Skip generating histogram
303 value for internal call.
305 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
307 * auto-profile.c (AFDO_EINFO): New macro.
308 (class edge_info): New class.
309 (is_edge_annotated, set_edge_annotated): Delete.
310 (afdo_propagate_edge, afdo_propagate_circuit, afdo_propagate): Remove
311 parameter. Adjust edge count computation and annotation using class
313 (afdo_calculate_branch_prob, afdo_annotate_cfg): Likewise.
315 2018-12-13 Michael Ploujnikov <michael.ploujnikov@oracle.com>
317 * ipa-cp.c (print_all_lattices): Skip cp clones.
319 * ipa-cp.c: Fix various comment typos.
321 2018-12-13 Jakub Jelinek <jakub@redhat.com>
323 PR tree-optimization/88444
324 * tree-inline.c (fold_marked_statements): Iterate up to
325 last_basic_block_for_fn rather than n_basic_blocks_for_fn.
327 PR rtl-optimization/88470
328 * cfgcleanup.c (outgoing_edges_match): If the function is
329 shrink-wrapped and bb1 ends with a JUMP_INSN with a single fake
330 edge to EXIT, return false.
332 2018-12-13 Martin Sebor <msebor@redhat.com>
334 * doc/extend.texi: Consistently use @code for const and volatile
335 qualifiers, the true and false constants, and asm statements.
337 2018-12-13 Vladimir Makarov <vmakarov@redhat.com>
339 PR rtl-optimization/88414
340 * lra-int.h (lra_asm_error_p): New.
341 * lra-assigns.c (lra_assign): Check lra_asm_error_p for checking
342 call crossed pseudo assignment correctness.
343 (lra_split_hard_reg_for): Set up lra_asm_error_p.
344 * lra-constraints.c (curr_insn_transform): Ditto.
345 * lra.c (lra_asm_error_p): New.
346 (lra): Reset lra_asm_error_p.
348 2018-12-13 Jakub Jelinek <jakub@redhat.com>
350 PR rtl-optimization/88416
351 * valtrack.c (cleanup_auto_inc_dec): Handle pre/post-inc/dec/modify
352 even if !AUTO_INC_DEC.
354 2018-12-13 David Edelsohn <dje.gcc@gmail.com>
356 * config/rs6000/rs6000.c (rs6000_function_arg): Ensure type is
358 (rs6000_arg_partial_bytes): Same.
360 2018-12-13 Jason Merrill <jason@redhat.com>
362 * gdbinit.in (pp): New macro.
365 2018-12-13 Jakub Jelinek <jakub@redhat.com>
367 PR tree-optimization/88464
368 * tree-vect-stmts.c (vect_build_gather_load_calls): Handle INTEGER_TYPE
369 masktype if mask is non-NULL.
370 (vectorizable_load): Don't reject masked gather loads if masktype
371 in the decl is INTEGER_TYPE.
373 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
375 * config/s390/s390-builtins.def (s390_vec_double_s64): Map to
376 s390_vec_double_s64 instead of s390_vcdgb.
377 (s390_vec_double_u64): Map to s390_vec_double_u64 instead of
380 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
382 * config/s390/vx-builtins.md ("vec_ctd_s64", "vec_ctd_u64")
383 ("vec_ctsl", "vec_ctul"): Replace 0 with VEC_NOINEXACT.
384 ("vec_double_s64", "vec_double_u64"): Replace 4 with VEC_INEXACT.
386 2018-12-13 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
388 * doc/invoke.texi (-msve-vector-bits): Clarify -msve-vector-bits=128
391 2018-12-13 Wei Xiao <wei3.xiao@intel.com>
393 * common/config/i386/i386-common.c (processor_names): Add cascadelake.
394 (processor_alias_table): Add cascadelake.
395 * config.gcc: Add -march=cascadelake.
396 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
398 * config/i386/i386.c (Add m_CASCADELAKE): New.
399 (processor_cost_table): Add cascadelake.
400 (get_builtin_code_for_version): Handle cascadelake.
401 * config/i386/i386.h (TARGET_CASCADELAKE, PROCESSOR_CASCADELAKE): New.
402 (PTA_CASCADELAKE): Ditto.
403 * doc/invoke.texi: Add -march=cascadelake.
405 2018-12-13 Jakub Jelinek <jakub@redhat.com>
408 * config/i386/i386.md (*movdi_internal, *movsi_internal,
409 *movhi_internal, *movqi_internal): Add alternative(s) to load
410 0 or -1 into k registers using kxor or kxnoq instructions.
413 * config/i386/sse.md (VI1248_AVX512VLBW, AVX512ZEXTMASK): New
415 (<avx512>_testm<mode>3<mask_scalar_merge_name>,
416 <avx512>_testnm<mode>3<mask_scalar_merge_name>): Merge patterns
417 with VI12_AVX512VL and VI48_AVX512VL iterators into ones with
418 VI1248_AVX512VLBW iterator.
419 (*<avx512>_testm<VI1248_AVX512VLBW:mode>3_zext,
420 *<avx512>_testm<VI1248_AVX512VLBW:mode>3_zext_mask,
421 *<avx512>_testnm<VI1248_AVX512VLBW:mode>3_zext,
422 *<avx512>_testnm<VI1248_AVX512VLBW:mode>3_zext_mask): New
426 * config/i386/i386.md (*zero_extendsidi2, zero_extend<mode>di2,
427 *zero_extend<mode>si2, *zero_extendqihi2): Add =*k, *km alternatives.
429 2018-12-12 Tom de Vries <tdevries@suse.de>
430 Jakub Jelinek <jakub@redhat.com>
432 * omp-builtins.def (BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_START,
433 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_START,
434 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_START,
435 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_START,
436 BUILT_IN_GOMP_PARALLEL_LOOP_NONMONOTONIC_RUNTIME,
437 BUILT_IN_GOMP_PARALLEL_LOOP_MAYBE_NONMONOTONIC_RUNTIME): Fix up
438 function types - remove one argument.
440 2018-12-12 Martin Sebor <msebor@redhat.com>
442 * doc/extend.texi (attribute copy): Fix typos.
444 2018-12-12 Martin Sebor <msebor@redhat.com>
446 * doc/extend.texi (Function Attributes): Clarify C++ aspects.
447 (Variable Attributes): Same.
448 (Type Attributes): Same.
450 2018-12-12 Olivier Hainque <hainque@adacore.com>
452 * config/aarch64/aarch64.c (aarch64_override_options): Once arch,
453 cpu and tune were validated, insert SUBTARGET_OVERRIDE_OPTIONS if
456 2018-12-12 Olivier Hainque <hainque@adacore.com>
458 * config/aarch64/aarch64.c (PROBE_STACK_FIRST_REG) : Redefine as
459 R9_REGNUM instead of 9.
460 (PROBE_STACK_SECOND_REG): Redefine as R10_REGNUM instead of 10.
462 2018-12-12 Eric Botcazou <ebotcazou@adacore.com>
465 * config/sparc/sparc.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
466 (speculation_barrier): New instruction for V9.
468 2018-12-12 Segher Boessenkool <segher@kernel.crashing.org>
469 Iain Sandoe <iain@sandoe.co.uk>
472 * config/rs6000/rs6000.c (save_reg_p): Do not save the picbase reg
473 unless it has been used.
474 (first_reg_to_save): Remove dead code.
476 2018-12-12 Iain Sandoe <iain@sandoe.co.uk>
478 * config/rs6000/rs6000-protos.h (rs6000_call_darwin): New.
479 (rs6000_sibcall_darwin): New. (macho_call_template): Remove.
480 * config/rs6000/rs6000.c (get_prev_label): Forward declaration.
481 (rs6000_call_template_1): Handle Darwin.
482 (macho_call_template): Remove.
483 (rs6000_call_sysv): Remove handling for Darwin.
484 (rs6000_call_darwin_1, rs6000_call_darwin): New
485 (rs6000_sibcall_darwin): New.
486 * config/rs6000/rs6000.md (define_expand “call”): Handle Darwin
487 with its own expander. (define_expand “call_value”): Likewise.
488 (define_expand “sibcall”): Likewise.
489 (define_expand “sibcall_value”): Likewise.
490 (call_nonlocal_sysv): Remove Darwin special-casing.
491 (call_value_nonlocal_sysv): Likewise.
493 2018-12-12 Iain Sandoe <iain@sandoe.co.uk>
495 * config/rs6000/darwin.md (call_indirect_nonlocal_darwin64): Remove.
496 (call_nonlocal_darwin64): Remove.
497 (call_value_indirect_nonlocal_darwin64): Remove.
498 (call_value_nonlocal_darwin64): Remove.
499 * config/rs6000/rs6000.c (rs6000_call_template_1): Handle Darwin with
500 the same asm output as AIX/ELFv2. (rs6000_call_sysv): Preserve the
501 CALL_LONG flag when needed for Darwin.
502 * config/rs6000/rs6000.md (define expand “call”): Expand Darwin as
504 (define_expand “call_value”): Likewise.
505 (define_expand “sibcall”): Likewise.
506 (define_expand “sibcall_value”): Likewise.
507 (call_indirect_nonlocal_sysv): Mark the clobber mode P.
508 (call_nonlocal_sysv): Likewise.
509 (call_nonlocal_sysv_secure): Likewise.
510 (call_value_indirect_nonlocal_sysv): Likewise.
511 (call_value_nonlocal_sysv): Likewise.
512 (call_value_nonlocal_sysv_secure): Likewise.
513 (call_local64): Mark the clobber DI.
514 (call_value_local64): Likewise.
516 2018-12-11 Jakub Jelinek <jakub@redhat.com>
518 PR tree-optimization/88444
519 * tree-vrp.c (register_edge_assert_for_2): Only register assertions
520 for conversions if rhs1 is a SSA_NAME.
522 2018-12-11 Dimitar Dimitrov <dimitar@dinux.eu>
524 * cfgexpand.c (asm_clobber_reg_is_valid): Also produce
525 error when stack pointer is clobbered.
526 (expand_asm_stmt): Refactor clobber check in separate function.
528 2018-12-11 Eric Botcazou <ebotcazou@adacore.com>
530 * config/rs6000/vxworks.h (RS6000_STARTING_FRAME_OFFSET): Define,
531 accounting for STACK_BOUNDARY 128.
532 (STACK_DYNAMIC_OFFSET): Likewise.
534 2018-12-11 Jakub Jelinek <jakub@redhat.com>
537 * config/i386/i386.md (*x86_mov<SWI48:mode>cc_0_m1_neg_leu<SWI:mode>):
538 New define_insn_and_split.
540 2018-12-11 Richard Biener <rguenther@suse.de>
544 * gimple.c (gimple_assign_set_rhs_with_ops): Revert previous
546 * tree-complex.c (update_complex_assignment): Properly transfer
547 or clean EH info around gimple_assign_set_rhs_with_ops.
549 2018-12-11 Richard Earnshaw <rearnsha@arm.com>
552 * config/aarch64/iterators.md (sizem1): Add sizes for SFmode and DFmode.
553 (Vbtype): Add SFmode mapping.
554 * config/aarch64/aarch64.md (copysigndf3, copysignsf3): Delete.
555 (copysign<GPF:mode>3): New expand pattern.
556 (copysign<GPF:mode>3_insn): New insn pattern.
558 2018-12-11 Richard Biener <rguenther@suse.de>
560 * ccmp.c (ccmp_candidate_p): Use GIMPLE API properly.
562 2018-12-11 Jakub Jelinek <jakub@redhat.com>
565 * doc/sourcebuild.texi (lto_incremental): Document new effective
568 2018-12-11 Segher Boessenkool <segher@kernel.crashing.org>
571 * config/rs6000/rs6000.c (rs6000_expand_zeroop_builtin): Use
572 rs6000_isa_flags instead of rs6000_isa_flags_explicit to decide
573 whether soft float is enabled.
574 (rs6000_expand_mtfsb_builtin): Ditto.
575 (rs6000_expand_set_fpscr_rn_builtin): Ditto.
576 (rs6000_expand_set_fpscr_drn_builtin): Ditto.
578 2018-12-10 Jeff Law <law@redhat.com>
580 PR tree-optimization/80520
581 * gimple-ssa-split-paths.c (is_feasible_trace): Recognize half
582 diamonds that are likely if convertable.
584 2018-12-10 Martin Sebor <msebor@redhat.com>
586 PR tree-optimization/86196
587 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
588 base size only of arrays.
590 2018-12-10 Segher Boessenkool <segher@kernel.crashing.org>
592 * config.gcc (Obsolete configurations): Delete powerpc*-*-*spe*.
593 (Unsupported targets): Add powerpc*-*-*spe*.
594 (powerpc*-*-*spe*): Delete.
595 (powerpc-*-eabispe*): Delete.
596 (powerpc-*-rtems*spe*): Delete.
597 (powerpc*-*-linux*spe*): Delete.
598 (powerpc*-*-linux*): Do not handle the linux*spe* targets.
599 (powerpc-wrs-vxworks*spe): Delete.
600 (with_cpu setting code): Delete powerpc*-*-*spe* handling.
601 * config.host (target powerpc*-*-*spe*): Delete.
602 * doc/invoke.texi (PowerPC SPE Options): Delete.
603 (PowerPC SPE Options): Delete.
604 * config/powerpcspe: Delete.
606 2018-12-10 Uros Bizjak <ubizjak@gmail.com>
609 * config/i386/i386.c (ix86_expand_sse_cmp): For vector modes,
610 check operand 1 with vector_operand predicate.
611 (ix86_expand_sse_movcc): For vector modes, check op_true with
612 vector_operand, not nonimmediate_operand.
614 2018-12-10 Richard Biener <rguenther@suse.de>
616 * tree-affine.c (tree_to_aff_combination): Remove unreachable
618 (aff_combination_expand): Cache on SSA names, not possibly
619 on conversion trees. Avoid expanding cases we do not handle.
621 2018-12-10 Richard Biener <rguenther@suse.de>
623 PR tree-optimization/88427
624 * vr-values.c (vr_values::extract_range_from_phi_node):
625 Handle symbolic ranges conservatively when trying to drop
628 2018-12-10 Martin Jambor <mjambor@suse.cz>
631 * ipa-prop.c (determine_locally_known_aggregate_parts): Make sure
632 we check pointers against pointers.
634 2018-12-10 Richard Biener <rguenther@suse.de>
637 * gimple.c (gimple_assign_set_rhs_with_ops): Transfer EH
638 info to a newly allocated stmt.
640 2018-12-10 Jerome Lambourg <lambourg@adacore.com>
642 * config/vxworksae.h (TARGET_VXWORKS_HAVE_CTORS_DTORS): Define.
644 2018-12-10 Fredrik Nyström <fredrik@lysator.liu.se>
647 * config/sol2.h: Only use libgcc-unwind.map if
648 ENABLE_SHARED_LIBGCC.
650 2018-12-10 Bin Cheng <bin.cheng@linux.alibaba.com>
652 * auto-profile.c (afdo_calculate_branch_prob): Convert profile_count
653 to afdo precision quality.
654 (afdo_callsite_hot_enough_for_early_inline): Likewise.
655 (afdo_annotate_cfg): Set profile_count for exit basic block.
657 2018-12-10 Bin Cheng <bin.cheng@linux.alibaba.com>
659 * auto-profile.c (string_table::get_index_by_decl)
660 (function_instance::get_function_instance_by_decl): Avoid infinite
661 recursion by using DECL_FROM_INLINE.
663 2018-12-09 John David Anglin <danglin@gcc.gnu.org>
665 * config.gcc (hppa*-*-linux*): Add pa/t-pa to tmake_file. Define
667 * config/pa/pa-protos.h (pa_d_target_versions): New prototype.
668 * config/pa/pa.h (TARGET_D_CPU_VERSIONS): Define.
669 * config/pa/pa-d.c: New file.
670 * config/pa/t-pa: New file.
672 2018-12-08 Bin Cheng <bin.cheng@linux.alibaba.com>
674 * ipa-cp.c (update_profiling_info): Call adjust_for_ipa_scaling for
677 2018-12-08 Jakub Jelinek <jakub@redhat.com>
680 * tree-nested.c (convert_local_reference_stmt): Handle clobbers where
681 lhs is not a decl normally, don't call use_pointer_in_frame on that
684 2018-12-08 Eric Botcazou <ebotcazou@adacore.com>
686 PR rtl-optimization/88390
687 * dwarf2cfi.c (struct dw_cfi_row): Add window_save field.
688 (cfi_row_equal_p): Compare it.
689 (dwarf2out_frame_debug_cfa_window_save): Add FAKE parameter.
690 If FAKE is false, set window_save of the current row.
691 (dwarf2out_frame_debug) <REG_CFA_TOGGLE_RA_MANGLE>: Call above
692 function with FAKE parameter set to true.
693 <REG_CFA_WINDOW_SAVE>: Likewise but with FAKE parameter set to false.
694 (change_cfi_row): Emit a DW_CFA_GNU_window_save if necessary.
696 2018-12-07 Peter Bergner <bergner@linux.ibm.com>
699 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
700 -mabi=ieeelongdouble and -mabi=ibmlongdouble without -mlong-double-128.
701 Do not error for -mabi=ibmlongdouble and no ISA 2.06 support.
702 * doc/invoke.texi: Document -mabi=ibmlongdouble and -mabi=ieeelongdouble
703 require -mlong-double-128.
705 2018-12-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
707 * config/aarch64/aarch64.c (aarch64_tuning_override_functions): Add
709 (aarch64_parse_sve_width_string): Define.
711 2018-12-07 Jeff Law <law@redhat.com>
714 * gimple-ssa-evrp-analyze.h (class evrp_range_analyzer): Add
715 m_update_global_ranges member. Add corresponding argument to ctor.
716 * gimple-ssa-evrp-analyze.c
717 (evrp_range_analyzer::evrp_range_analyzer): Add new argument and
718 initialize m_update_global_ranges.
719 (evrp_range_analyzer::set_ssa_range_info): Assert that we are
720 updating global ranges.
721 (evrp_range_analyzer::record_ranges_from_incoming_edge): Only
722 update global ranges if explicitly requested.
723 (evrp_range_analyzer::record_ranges_from_phis): Similarly.
724 (evrp_range_analyzer::record_ranges_from_stmt): Similarly.
725 * gimple-ssa-evrp.c (evrp_dom_walker): Pass new argument to
726 evrp_range_analyzer ctor.
727 * gimple-ssa-sprintf.c (sprintf_dom_walker): Similarly.
728 * tree-ssa-dom.c (dom_opt_dom_walker): Similarly.
730 2018-12-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
732 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum):
733 Add SVE_NOT_IMPLEMENTED value.
734 * config/aarch64/aarch64-protos.h (struct tune_params): Add sve_width
736 * config/aarch64/aarch64.c (generic_tunings,cortexa35_tunings,
737 cortexa53_tunings, cortexa57_tunings, cortexa72_tunings,
738 cortexa73_tunings, exynosm1_tunings, thunderx_tunings,
739 thunderx_tunings, tsv110_tunings, xgene1_tunings, qdf24xx_tunings,
740 saphira_tunings, thunderx2t99_tunings, emag_tunings):
742 (aarch64_estimated_poly_value): Define.
743 (TARGET_ESTIMATED_POLY_VALUE): Define.
745 2018-12-07 Paul A. Clarke <pc@us.ibm.com>
748 * config/rs6000/mmintrin.h (_mm_packs_pu16): Correctly use "__vector".
750 2018-12-07 Vladimir Makarov <vmakarov@redhat.com>
752 PR rtl-optimization/88349
753 * ira-costs.c (record_operand_costs): Check bigger reg class on
756 2018-12-07 Richard Sandiford <richard.sandiford@arm.com>
758 * config/aarch64/aarch64-sve.md (*mul<mode>3, *v<optab><mode>3):
759 Split the patterns after reload if we don't need the predicate
761 (*post_ra_mul<mode>3, *post_ra_v<optab><mode>3): New patterns.
763 2018-12-07 Richard Sandiford <richard.sandiford@arm.com>
765 * config/aarch64/iterators.md (SVE_UNPRED_FP_BINARY): New code
767 (sve_fp_op): Handle minus and mult.
768 * config/aarch64/aarch64-sve.md (*add<mode>3, *sub<mode>3)
769 (*mul<mode>3): Split the patterns after reload if we don't
770 need the predicate operand.
771 (*post_ra_<sve_fp_op><mode>3): New pattern.
773 2018-12-07 Bin Cheng <bin.cheng@linux.alibaba.com>
775 * profile-count.h (profile_count::oeprator>=): Fix typo by inverting
776 return condition when *this is precise zero.
778 2018-12-07 Jakub Jelinek <jakub@redhat.com>
781 * final.c (rest_of_handle_final): Don't call collect_fn_hard_reg_usage
782 for functions with naked attribute.
785 * tree-vrp.c (extract_range_from_binary_expr): For POINTER_PLUS_EXPR
786 with -fno-delete-null-pointer-checks, set_nonnull only if the pointer
787 is non-NULL and offset is known to have most significant bit clear.
788 * vr-values.c (vr_values::vrp_stmt_computes_nonzero): For ADDR_EXPR
789 of MEM_EXPR, return true if the MEM_EXPR has non-zero offset with
790 most significant bit clear. If offset does have most significant bit
791 set and -fno-delete-null-pointer-checks, don't return true even if
792 the base pointer is non-NULL.
794 2018-12-06 Alexandre Oliva <aoliva@redhat.com>
796 * cselib.c (cselib_record_sets): Skip strict low part sets
799 2018-12-06 Paul A. Clarke <pc@us.ibm.com>
802 * config/rs6000/smmintrin.h: New file.
803 * config.gcc: Add smmintrin.h to extra_headers for powerpc*-*-*.
805 2018-12-06 Paul A. Clarke <pc@us.ibm.com>
808 * config/rs6000/mmintrin.h (_mm_unpackhi_pi8): Fix for big-endian.
809 (_mm_unpacklo_pi8): Likewise.
810 (_mm_mulhi_pi16): Likewise.
811 (_mm_packs_pi16): Fix for big-endian. Use preferred API.
812 (_mm_packs_pi32): Likewise.
813 (_mm_packs_pu16): Likewise.
814 * config/rs6000/xmmintrin.h (_mm_cvtss_si32): Fix for big-endian.
815 (_mm_cvtss_si64): Likewise.
816 (_mm_cvtpi32x2_ps): Likewise.
817 (_mm_shuffle_ps): Likewise.
818 (_mm_movemask_pi8): Likewise.
819 (_mm_mulhi_pu16): Likewise.
820 (_mm_sad_pu8): Likewise.
821 (_mm_sad_pu8): Likewise.
822 (_mm_cvtpu16_ps): Fix for big-endian. Use preferred API.
823 (_mm_cvtpu8_ps): Likewise.
824 (_mm_movemask_ps): Better #else case for big-endian (no functional
826 (_mm_shuffle_pi16): Likewise.
827 * config/rs6000/emmintrin.h (_mm_movemask_pd): Fix for big-endian.
828 Better #else case for big-endian (no functional change).
829 (_mm_movemask_epi8): Likewise.
830 (_mm_shufflehi_epi16): Likewise.
831 (_mm_shufflelo_epi16): Likewise.
832 (_mm_shuffle_epi32): Likewise.
833 (_mm_mul_epu32): Fix for big-endian.
834 (_mm_bsrli_si128): Likewise.
835 (_mm_cvtps_pd): Better #else case for big endian.
836 (_mm_mulhi_epi16): Likewise.
837 (_mm_mul_epu32): Likewise.
838 (_mm_slli_si128): Likewise.
839 (_mm_sll_epi16): Likewise.
840 (_mm_sll_epi32): Likewise.
841 (_mm_sra_epi16): Likewise.
842 (_mm_sra_epi32): Likewise.
843 (_mm_srl_epi16): Likewise.
844 (_mm_srl_epi32): Likewise.
845 (_mm_mulhi_epu16): Likewise.
846 (_mm_sad_epu8): Likewise.
847 * config/rs6000/pmmintrin.h (_mm_hadd_ps): Fix for big-endian.
848 (_mm_sub_ps): Likewise.
849 * config/rs6000/mmintrin.h (_mm_cmpeq_pi8): Fix for 32-bit mode.
850 * gcc/config/rs6000/tmmintrin.h (_mm_alignr_epi8): Use ENDIAN
851 macros consistently (no functional changes).
852 (_mm_alignr_pi8): Likewise.
854 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
857 * config/darwin.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC) Remove, use the
859 * config/rs6000/darwin7.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC): New.
861 2018-12-06 Vladimir Makarov <vmakarov@redhat.com>
864 * ira.c (ira_init_register_move_cost): Use info from
865 hard_regno_mode_ok instead of contains_reg_of_mode.
866 * ira-costs.c (contains_reg_of_mode): Don't use cost from bigger
867 hard register class for some fixed hard registers.
869 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
871 * doc/extend.texi (Using Assembly Language with C): Document asm inline.
872 (Size of an asm): Fix typo. Document asm inline.
873 * gimple-pretty-print.c (dump_gimple_asm): Handle asm inline.
874 * gimple.h (enum gf_mask): Add GF_ASM_INLINE.
875 (gimple_asm_set_volatile): Fix typo.
876 (gimple_asm_inline_p): New.
877 (gimple_asm_set_inline): New.
878 * gimplify.c (gimplify_asm_expr): Propagate the asm inline flag from
880 * ipa-icf-gimple.c (func_checker::compare_gimple_asm): Compare the
881 gimple_asm_inline_p flag, too.
882 * tree-core.h (tree_base): Document that protected_flag is ASM_INLINE_P
884 * tree-inline.c (estimate_num_insns): If gimple_asm_inline_p return
885 a minimum size for an asm.
886 * tree.h (ASM_INLINE_P): New.
888 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
891 * doc/extend.texi (Basic Asm): Update grammar.
892 (Extended Asm): Update grammar.
894 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
897 * config/i386/darwin.h (STACK_BOUNDARY): Remove macro.
898 * config/i386/i386.c (ix86_compute_frame_layout): Ensure at least 128b
899 stack alignment in non-leaf functions.
901 2018-12-06 Jakub Jelinek <jakub@redhat.com>
904 * config/aarch64/aarch64.c (aarch64_print_address_internal): Don't
905 call output_operand_lossage on VOIDmode CONST_INTs. After
906 output_operand_lossage do return false.
908 2018-12-06 Richard Biener <rguenther@suse.de>
910 * df-problems.c (df_rd_local_compute): Use bitmap_release.
911 (df_live_free): Likewise.
912 (df_md_local_compute): Likewise.
913 (df_md_free): Release df_md_scratch bitmap.
914 * loop-invariant.c (calculate_loop_reg_pressure): Use
916 * sched-deps.c (true_dependency_cache, output_dependency_cache,
917 anti_dependency_cache, control_dependency_cache,
918 spec_dependency_cache): Use bitmap instead of bitmap_head *.
919 * sched-ebb.c (schedule_ebbs_init): Initialize non-GTY
920 dont_calc_deps as bitmap allocated from obstack not GC.
921 (schedule_ebbs_finish): Use bitmap_release.
922 * sched-rgn.c (schedule_insns): Initialize non-GTY
923 not_in_df as bitmap allocated from obstack not GC.
925 * sel-sched.c (_forced_ebb_heads): Remove premature optimization.
926 (sel_region_init): Allocate forced_ebb_heads.
927 (sel_region_finish): Free forced_ebb_heads.
929 2018-12-06 Richard Biener <rguenther@suse.de>
931 * bitmap.c (bitmap_head::crashme): Define.
932 * bitmap.h (bitmap_head): Add constexpr default constructor
933 poisoning the obstack member.
934 (bitmap_head::crashme): Declare.
935 (bitmap_release): New function clearing a bitmap and poisoning
937 * gengtype.c (main): Make it recognize CONSTEXPR.
938 * lra-constraints.c (lra_inheritance): Use bitmap_release
939 instead of bitmap_clear.
940 * ira.c (ira): Work around class-memaccess warning.
941 * regrename.c (create_new_chain): Likewise.
943 2018-12-06 Jakub Jelinek <jakub@redhat.com>
945 PR tree-optimization/85726
946 * generic-match-head.c (optimize_successive_divisions_p): New function.
947 * gimple-match-head.c (optimize_successive_divisions_p): Likewise.
948 * match.pd: Don't combine successive divisions if they aren't exact
949 and optimize_successive_divisions_p is false.
952 * tree-nested.c (convert_nonlocal_reference_stmt): Remove clobbers
953 for non-local automatic decls.
955 2018-12-05 David Edelsohn <dje.gcc@gmail.com>
957 * config/rs6000/aix72.h (ASM_DEFAULT_SPEC): Match Power7 processor
960 2018-12-05 Uros Bizjak <ubizjak@gmail.com>
962 * dwarf2out.c (field_byte_offset): Remove
963 #ifdef PCC_BITFIELD_TYPE_MATTERS check.
965 2018-12-05 Richard Biener <rguenther@suse.de>
966 Martin Sebor <msebor@redhat.com>
969 * calls.c (get_attr_nonstring_decl): Avoid setting *REF to
971 * gcc/gimple-low.c (lower_stmt): Fold builtin calls here.
972 * gimplify (maybe_fold_stmt): Avoid folding builtin calls.
974 2018-12-05 Iain Sandoe <iain@sandoe.co.uk>
976 * configure.ac (gcc_cv_otool): Set.
977 * configure: Regenerate.
979 2018-12-05 Uros Bizjak <ubizjak@gmail.com>
981 * config/i386/cygming.h (PCC_BITFIELD_TYPE_MATTERS): Remove.
982 (GROUP_BITFIELDS_BY_ALIGN): Ditto.
984 2018-12-05 Richard Sandiford <richard.sandiford@arm.com>
986 PR tree-optimization/88064
987 * tree-vect-patterns.c (vect_convert_input): Convert the result of
988 an existing cast if it has the right width but the wrong sign.
989 Do not test the signedness of the required result when
990 considering whether to split an existing cast; instead split to
991 a type with the same signedness as the source of the cast, then
992 convert it to the opposite signedness where necessary.
993 (vect_recog_over_widening_pattern): Handle sign changes between
994 the final PLUS_EXPR and the RSHIFT_EXPR.
995 (vect_recog_average_pattern): Use an unsigned operation when
996 truncating an addition, subtraction or multiplication. Cast the
997 result back to the "real" signedness before promoting.
999 2018-12-05 Richard Biener <rguenther@suse.de>
1001 PR tree-optimization/86637
1002 * tree-vectorizer.c (pass_slp_vectorize::execute): Reset
1003 vect_location at the end.
1005 2018-12-05 Jakub Jelinek <jakub@redhat.com>
1007 PR tree-optimization/87360
1008 * gimple-loop-jam.c (tree_loop_unroll_and_jam): On failure to analyze
1009 data dependencies, don't return false, just continue. Formatting
1011 (merge_loop_tree, bb_prevents_fusion_p, unroll_jam_possible_p,
1012 fuse_loops): Formatting fixes.
1015 * cfgexpand.c (expand_stack_vars): If asan_vec is empty, start with
1016 aligning frame offset to ASAN_RED_ZONE_SIZE bytes.
1018 2018-12-05 Xianmiao Qu <xianmiao_qu@c-sky.com>
1020 * config.gcc (csky-*-linux-gnu*): Force .init_array support.
1022 2018-12-05 Segher Boessenkool <segher@kernel.crashing.org>
1024 * config/rs6000/rs6000.c (rs6000_function_arg): Only do the special
1025 aggregate handling on actual AIX, not on somewhat similar systems.
1026 (rs6000_arg_partial_bytes): Ditto.
1028 2018-12-04 Vladimir Makarov <vmakarov@redhat.com>
1030 PR rtl-optimization/88317
1031 * lra-constraints.c (split_reg): Don't set up check_only_regs if
1032 we are outside the inheritance pass.
1034 2018-12-04 Jan Hubicka <hubicka@ucw.cz>
1036 * ipa-prop.c (jump_function_useful_p): New.
1037 (ipa_read_node_info): Do not allocated useless jump functions.
1039 2018-12-04 David Malcolm <dmalcolm@redhat.com>
1042 * spellcheck.c (selftest::test_suggestions): Add another assertion.
1044 2018-12-04 Martin Sebor <msebor@redhat.com>
1046 * doc/extend.texi (__builtin_has_attribute): Fix typo.
1048 2018-12-04 Jakub Jelinek <jakub@redhat.com>
1051 * config/rs6000/rs6000.c (ccr_bit): Return -1 instead of assertion
1053 (print_operand): Use REG_P instead of GET_CODE == REG.
1054 <case 'D'>: Also check CR_REGNO_P (REGNO (x)).
1055 <case 't'>: Likewise. Remove GET_MODE check.
1056 * config/rs6000/rs6000.md (scc patterns): Assert ccr_bit didn't
1059 2018-12-04 Martin Sebor <msebor@redhat.com>
1061 * doc/extend.texi (attribute aligned): Expand.
1063 2018-12-04 David Edelsohn <dje.gcc@gmail.com>
1066 * config/rs6000/rs6000.c (rs6000_function_arg): Don't pass aggregates
1068 (rs6000_arg_partial_bytes): Same.
1070 2018-12-04 Vladimir Makarov <vmakarov@redhat.com>
1073 * ira-costs.c (exec): Try bigger class to use smaller register
1076 2018-12-04 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1079 * ipa-cp.c (create_specialized_node): Track clone counters by
1080 node assembler names.
1081 (ipcp_driver): Change type of clone_num_suffixes key to const char*.
1083 2018-12-04 Richard Biener <rguenther@suse.de>
1085 * tree-vect-loop.c (vect_transform_loop): Fix epilogue iterations
1086 for epilogue vectorization.
1088 2018-12-04 Richard Biener <rguenther@suse.de>
1090 PR tree-optimization/88301
1091 * tree-vrp.c (register_edge_assert_for_2): Fix sign-conversion
1092 issues in last commit.
1094 2018-12-04 Richard Biener <rguenther@suse.de>
1096 PR tree-optimization/88315
1097 * tree-vect-loop.c (get_initial_defs_for_reduction): Simplify
1098 and fix initialization vector for SAD and DOT_PROD SLP reductions.
1100 2018-12-03 Sandra Loosemore <sandra@codesourcery.com>
1103 * doc/extend.texi (Nonlocal gotos): New section.
1105 2018-12-03 Uros Bizjak <ubizjak@gmail.com>
1107 * config/i386/sse.md (vec_concatv2df): Change (v,xm,C)
1108 alternative to (v,vm,c).
1110 2018-12-03 Segher Boessenkool <segher@kernel.crashing.org>
1112 * gcc/config.gcc (Unsupported targets): Add powerpc*-*-linux*paired*.
1113 (powerpc*-*-linux*): Don't handle it here.
1115 2018-12-03 Jeff Law <law@redhat.com>
1117 * config/h8300/h8300.md (<code>qi3_1): Add gcc_unreachable to keep
1120 * config/h8300/h8300.md (low byte masking peepholes): Only accept
1121 nonimmediate_operand for the to-be-masked operand.
1123 2018-12-03 Richard Biener <rguenther@suse.de>
1125 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
1126 allow expected function-pointer cast re-instantiation.
1128 2018-12-03 Ilya Leoshkevich <iii@linux.ibm.com>
1130 * common/config/s390/s390-common.c (s390_option_init_struct):
1131 Use section anchors by default.
1132 * config/s390/s390.c (s390_check_symref_alignment): Handle
1134 (TARGET_MAX_ANCHOR_OFFSET): Use short displacement.
1135 * output.h (assemble_align): Pass `align' as unsigned int, so
1136 that the value 0x80000000, which corresponds to `aligned(1 <<
1137 28)', would pass the `align > BITS_PER_UNIT' check.
1138 * varasm.c (assemble_align): Likewise.
1140 2018-12-03 Julian Brown <julian@codesourcery.com>
1142 * tree-pretty-print.c (dump_omp_clause): Make default case
1145 2018-12-03 Richard Biener <rguenther@suse.de>
1147 PR tree-optimization/88301
1148 * tree-vrp.c (register_edge_assert_for_2): Handle conversions
1149 that do not change the value by registering the same assert
1152 2018-12-03 Richard Biener <rguenther@suse.de>
1154 * tree-vect-loop.c (vect_transform_loop): Properly compute
1155 upper bound for the epilogue when doing epilogue vectorization.
1157 2018-12-03 Ilya Leoshkevich <iii@linux.ibm.com>
1160 * cfgcleanup.c (class pass_postreload_jump): New pass.
1161 (pass_postreload_jump::execute): Likewise.
1162 (make_pass_postreload_jump): Likewise.
1163 * passes.def: Add pass_postreload_jump before
1164 pass_postreload_cse.
1165 * tree-pass.h (make_pass_postreload_jump): New pass.
1167 2018-12-02 Uros Bizjak <ubizjak@gmail.com>
1169 * config/i386/i386.c (inline_memory_move_cost): Correctly
1170 compute number of TFmode GPR moves.
1172 2018-12-02 Jakub Jelinek <jakub@redhat.com>
1175 * config/i386/sse.md (*vec_concatv4sf_0, *vec_concatv4si_0): New insns.
1177 2018-12-02 Jeff Law <law@redhat.com>
1179 * config/h8300/h8300.md (call, call_value): Drop mode from
1180 operand containing number of bytes pushed.
1181 (call_insn, call_value_insn): Use mode iterator for number
1182 of bytes pushed operand. Make pattern name vary appropriately.
1184 2018-12-02 Jan Hubicka <jh@suse.cz>
1186 * bb-reorer.c (find_rarely_executed_basic_blocks_and_crossin_edges):
1187 trust precise profiles.
1189 2018-12-02 Jakub Jelinek <jakub@redhat.com>
1191 * tree-nested.c (convert_nonlocal_omp_clauses,
1192 convert_local_omp_clauses): Handle OMP_CLAUSE_IN_REDUCTION,
1193 OMP_CLAUSE_TASK_REDUCTION and OMP_CLAUSE__SIMT_ clauses.
1194 (convert_nonlocal_reference_stmt, convert_local_reference_stmt):
1195 Convert clauses for GIMPLE_OMP_TASKGROUP.
1197 * omp-low.c (check_omp_nesting_restrictions): Allow cancel or
1198 cancellation point with taskgroup clause inside of taskloop. Consider
1199 a taskloop construct without nogroup clause as implicit taskgroup for
1200 diagnostics if cancel/cancellation point with taskgroup clause is
1201 closely nested inside of taskgroup region.
1204 * asan.c (asan_clear_shadow): Move assert that len is multiple of 4
1205 to the start of the function.
1206 (asan_emit_stack_protection): When emitting clearing sequence for
1207 epilogue, align offset down to ASAN_RED_ZONE_SIZE granularity,
1208 add last_size_aligned which is last_size padded to multiples of
1209 ASAN_RED_ZONE_SIZE and emit asan_clear_shadow always on 4 byte
1212 2018-12-01 Jakub Jelinek <jakub@redhat.com>
1215 * asan.c (asan_redzone_buffer::flush_redzone_payload): Fix up
1216 an off-by-one for BYTES_BIG_ENDIAN.
1219 * combine.c (find_split_point): For invalid memory address
1220 nonobj + obj + const, if reg + obj + const is valid addressing
1221 mode, split at nonobj. Use if rather than else if for the
1222 fallback. Comment fixes.
1224 2018-11-30 Indu Bhagat <indu.bhagat@oracle.com>
1226 * coverage.c (get_coverage_counts): Use from_function_decl for precise
1228 * profile-count.c (profile_count::dump): Add handling for precise
1230 * profile.c (compute_branch_probabilities): Rely on exec_counts instead
1231 of profile_info to set profile_status of function.
1232 (branch_prob): Do not set profile_status of function based on
1233 profile_info. Done above based on exec_counts.
1235 2018-11-30 Jakub Jelinek <jakub@redhat.com>
1237 PR tree-optimization/88274
1238 * tree-ssa-reassoc.c (optimize_range_tests_xor,
1239 optimize_range_tests_diff): If type has smaller precision than
1240 corresponding mode or if it has non-standard min/max, compute
1241 everything in a standard type for the precision.
1244 * params.def (PARAM_LOGICAL_OP_NON_SHORT_CIRCUIT): New param.
1245 * tree-ssa-ifcombine.c (ifcombine_ifandif): If
1246 --param logical-op-non-short-circuit is present, override
1247 LOGICAL_OP_NON_SHORT_CIRCUIT value from the param.
1248 * fold-const.c (fold_range_test, fold_truth_andor): Likewise.
1250 2018-11-30 Jeff Law <law@redhat.com>
1252 * optabs.c (expand_binop): Use "machine_mode" rather than
1253 "enum machine mode" in most recent change.
1255 2018-11-30 Wilco Dijkstra <wdijkstr@arm.com>
1258 * builtins.c (expand_builtin_longjmp): Use a temporary when restoring
1260 (expand_builtin_nonlocal_goto): Likewise.
1262 2018-11-30 David Malcolm <dmalcolm@redhat.com>
1264 * diagnostic-core.h (emit_diagnostic): New decl.
1265 * diagnostic.c (emit_diagnostic): New overload, taking a
1268 2018-11-30 David Malcolm <dmalcolm@redhat.com>
1270 * pretty-print.c (class selftest::test_pretty_printer): New
1271 subclass of pretty_printer.
1272 (selftest::test_prefixes_and_wrapping): New test.
1273 (selftest::pretty_print_c_tests): Call it.
1275 2018-11-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1277 Minimize clone counter memory usage in create_virtual_clone.
1278 * cgraph.h (clone_function_name): Add a variant that takes a
1280 * cgraph.h (cgraph_node::create_virtual_clone): Add a new
1281 argument: num_suffix.
1282 * cgraphclones.c (cgraph_node::create_virtual_clone): Pass
1283 num_suffix to clone_function_name.
1284 (clone_function_name): Add a variant that takes a tree decl.
1285 * ipa-cp.c (create_specialized_node): Keep track of clone
1286 counters in clone_num_suffixes hash map.
1287 (ipcp_driver): Free the counter hash map.
1288 * ipa-hsa.c (process_hsa_functions): Creates at most one hsa
1291 2018-11-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1292 Make function assembly more independent.
1294 This is achieved by having clone_function_name assign unique clone
1295 numbers for each function independently.
1297 * cgraphclones.c: Replaced clone_fn_id_num with clone_fn_ids;
1299 (clone_function_name_numbered): Use clone_fn_ids.
1301 2018-11-30 Vladimir Makarov <vmakarov@redhat.com>
1303 PR rtl-optimization/88179
1304 * lra-constraints.c (address_eliminator::address_eliminator):
1305 Don't eleminate regs in illegitimate address.
1307 2018-11-30 David Malcolm <dmalcolm@redhat.com>
1309 PR preprocessor/88257
1310 * input.c (get_substring_ranges_for_loc): Fix indentation.
1311 Bulletproof against getting a different files back from
1312 linemap_resolve_location and expand_location_to_spelling_point.
1314 2018-11-30 Alexander Monakov <amonakov@ispras.ru>
1316 PR gcov-profile/88279
1317 * tree-profile.c (init_ic_make_global_vars): Call
1318 decl_default_tls_model for variable and not it's type.
1320 2018-11-30 Sam Tebbs <sam.tebbs@arm.com>
1322 * config/arm/arm.h (TARGET_DOTPROD): Add TARGET_VFP5 constraint.
1324 2018-11-30 Martin Liska <mliska@suse.cz>
1327 * asan.c (asan_shadow_cst): Remove, partially transform
1328 into flush_redzone_payload.
1329 (RZ_BUFFER_SIZE): New.
1330 (struct asan_redzone_buffer): New.
1331 (asan_redzone_buffer::emit_redzone_byte): Likewise.
1332 (asan_redzone_buffer::flush_redzone_payload): Likewise.
1333 (asan_redzone_buffer::flush_if_full): Likewise.
1334 (asan_emit_stack_protection): Use asan_redzone_buffer class
1335 that is responsible for proper aligned stores and flushing
1336 of shadow memory payload.
1337 * asan.h (ASAN_MIN_RED_ZONE_SIZE): New.
1338 (asan_var_and_redzone_size): Likewise.
1339 * cfgexpand.c (expand_stack_vars): Use smaller alignment
1340 (ASAN_MIN_RED_ZONE_SIZE) in order to make shadow memory
1341 for automatic variables more compact.
1343 2018-11-30 Alan Modra <amodra@gmail.com>
1345 * config/rs6000/predicates.md (easy_fp_constant): Avoid long
1346 dependent insn sequences.
1347 * config/rs6000/rs6000.c (num_insns_constant): Support long
1349 * config/rs6000/rs6000.md (mov<mode>_softfloat <FMOVE128>): Adjust
1352 2018-11-30 Alan Modra <amodra@gmail.com>
1354 * config/rs6000/rs6000.c (num_insns_constant_gpr): Renamed from
1355 num_insns_constant_wide. Make static. Revise comment.
1356 (num_insns_constant_multi): New function.
1357 (num_insns_constant): Formatting. Correct CONST_WIDE_INT
1358 calculation. Simplify and extract code common to both
1359 CONST_INT and CONST_DOUBLE. Add gcc_unreachable for unhandled
1361 * config/rs6000/rs6000-protos.h (num_insns_const_wide): Delete.
1363 2018-11-30 Richard Biener <rguenther@suse.de>
1365 PR tree-optimization/88274
1366 * tree-vrp.c (ranges_from_anti_range): Fix handling of
1369 2018-11-29 Andi Kleen <ak@linux.intel.com>
1371 * config/i386/i386.c (current_fentry_section): Add.
1372 (x86_function_profiler): Handle fentry section.
1373 (ix86_attribute_table): Add fentry section.
1374 * config/i386/i386.opt: Add -mfentry-section.
1375 * doc/extend.texi: Document fentry_section attribute.
1376 * doc/invoke.texi: Document -mfentry-section.
1378 2018-11-29 Andi Kleen <ak@linux.intel.com>
1380 * config/i386/i386.c (x86_print_call_or_nop): Handle nop name.
1381 (current_fentry_name): Add.
1382 (x86_function_profiler): Handle fentry_name attribute.
1383 (ix86_handle_fentry_name): Add.
1384 (ix86_attribute_table): Add fentry_name.
1385 * config/i386/i386.opt: Add -mfentry-name
1386 * doc/extend.texi: Document fentry_name.
1387 * doc/invoke.texi: Document minstrument-return.
1389 2018-11-29 Andi Kleen <ak@linux.intel.com>
1391 * config/i386/i386-opts.h (enum instrument_return): Add.
1392 * config/i386/i386.c (output_return_instrumentation): Add.
1393 (ix86_output_function_return): Call output_return_instrumentation.
1394 (ix86_output_call_insn): Call output_return_instrumentation.
1395 * config/i386/i386.opt: Add -minstrument-return=.
1396 * doc/invoke.texi (-minstrument-return): Document.
1398 2018-11-29 Eric Botcazou <ebotcazou@adacore.com>
1401 * config/sparc/sparc-modes.def: Minor tweak.
1402 * config/sparc/sparc.c: Minor reordering.
1403 (sparc_pass_by_reference): Move around.
1404 (traverse_record_type): Change offset from HOST_WIDE_INT to int.
1405 (classify_registers): Likewise for bitpos.
1406 (function_arg_slotno): Remove dead test and tweak comments.
1407 <MODE_RANDOM>: Remove useless assertion and test whether the
1408 parameter is named in order to pass it in FP registers. Return
1409 the regno for floating-point vector types.
1410 (compute_int_layout): Change bitpos from HOST_WIDE_INT to int.
1411 (compute_fp_layout): Likewise.
1412 (count_registers): Likewise.
1413 (assign_int_registers): Likewise.
1414 (assign_fp_registers): Likewise.
1415 (assign_registers): Likewise.
1416 (function_arg_record_value): Change size from HOST_WIDE_INT to int
1417 and use CEIL_NWORDS to compute the number of registers.
1418 (function_arg_union_value): Minor tweaks.
1419 (function_arg_vector_value): Add slotno and named parameters, use
1420 CEIL_NWORDS to compute the number of registers.
1421 (sparc_function_arg_1): Rework handling of vector types. Change
1422 size from HOST_WIDE_INT to int.
1423 (sparc_arg_partial_bytes): Rework handling of 32-bit ABI and deal
1424 with vector types for the 64-bt ABI.
1425 (sparc_function_arg_advance): Likewise.
1426 (sparc_return_in_memory): Add reference to -fpcc-struct-return.
1427 (sparc_struct_value_rtx): Return NULL_RTX instead of 0.
1428 (sparc_function_value_1): Rework handling of vector types. Change
1429 size from HOST_WIDE_INT to int.
1431 2018-11-29 Jakub Jelinek <jakub@redhat.com>
1434 * config/i386/sse.md (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_lt,
1435 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_zext_lt,
1436 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_shift,
1437 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_zext_shift,
1438 *<sse2_avx2>_pmovmskb_lt, *<sse2_avx2>_pmovmskb_zext_lt): New
1439 define_insn_and_split patterns.
1442 * config/i386/sse.md
1443 (*<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>_lt,
1444 *<sse4_1>_blendv<ssefltmodesuffix><avxsizesuffix>_ltint,
1445 *<sse4_1_avx2>_pblendvb_lt): Change define_insn into
1446 define_insn_and_split.
1448 2018-11-29 Peter Bergner <bergner@linux.ibm.com>
1451 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
1452 -mabi=ieeelongdouble without both -mpopcntd and -mvsx.
1454 2018-11-29 Uros Bizjak <ubizjak@gmail.com>
1456 * config/i386/i386.c (inline_memory_move_cost):
1457 Check "in" for 2 in MMX_CLASS_P case.
1458 * config/i386/mmx.md (*mov<mode>_internal): Correct
1459 TARGET_INTER_UNIT_MOVES_FROM_VEC and TARGET_INTER_UNIT_MOVES_TO_VEC
1460 alternatives in preferred_for_speed attribute calculation.
1462 2018-11-29 Martin Sebor <msebor@redhat.com>
1466 * doc/extend.texi (attribute constructor): Clarify.
1468 2018-11-29 Martin Liska <mliska@suse.cz>
1471 * builtins.c (expand_movstr): Fix thinko introduced
1472 when switching to the new enum.
1474 2018-11-29 qing zhao <qing.zhao@oracle.com>
1476 * cif-code.def (EXTERN_LIVE_ONLY_STATIC): New CIF code.
1477 * common.opt: Add -flive-patching flag.
1478 * doc/invoke.texi: Document -flive-patching.
1479 * flag-types.h (enum live_patching_level): New enum.
1480 * ipa-inline.c (can_inline_edge_p): Disable external functions from
1481 inlining when flag_live_patching is LIVE_PATCHING_INLINE_ONLY_STATIC.
1482 * opts.c (control_options_for_live_patching): New function.
1483 (finish_options): Make flag_live_patching incompatible with flag_lto.
1484 Control IPA optimizations based on different levels of
1487 2018-11-29 Giuliano Belinassi <giuliano.belinassi@usp.br>
1489 * match.pd (sinh (atanh (x))): New simplification rules.
1490 (cosh (atanh (x))): Likewise.
1492 2018-11-29 Jakub Jelinek <jakub@redhat.com>
1495 * config/i386/sse.md (ssebytemode): Add V16SI, V8SI and V4SI entries.
1496 (ssefltmodesuffix, ssefltvecmode): New define_mode_attrs.
1497 (*<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>_lt,
1498 *<sse4_1>_blendv<ssefltmodesuffix><avxsizesuffix>_ltint,
1499 *<sse4_1_avx2>_pblendvb_lt): New define_insns.
1502 * tree.h (build_uniform_cst, uniform_integer_cst_p): Declare.
1503 * tree.c (build_uniform_cst, uniform_integer_cst_p): New functions.
1504 * match.pd (define_predicates): Add uniform_integer_cst_p.
1505 (cmp @0 INTEGER_CST@1, cmp (convert?@2 @0) INTEGER_CST@1): Adjust
1506 so that it works also for vector comparisons with uniform constants
1507 with INTEGER_CST element.
1510 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): For
1511 vec_add and vec_sub builtins, perform PLUS_EXPR or MINUS_EXPR
1512 in unsigned_type_for instead of vector integral type where overflow
1515 2018-11-29 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1517 There can be at most one .resolver clone per function
1518 * config/rs6000/rs6000.c (make_resolver_func): Generate
1519 resolver symbol with clone_function_name instead of
1520 clone_function_name_numbered.
1522 2018-11-29 Richard Biener <rguenther@suse.de>
1524 PR tree-optimization/88243
1525 * tree-vect-patterns.c (vect_mark_pattern_stmts): Set the def
1526 type of all pattern-sequence stmts to vect_internal_def.
1528 2018-11-29 Andre Vieira <andre.simoesdiasvieira@arm.com>
1531 * config/arm/arm-cpus.in (armv7-r): Add FP16conv configurations.
1532 (cortex-r7, cortex-r8): Update default and add new configuration.
1533 * doc/invoke.texi (armv7-r): Add two new vfp options.
1534 (nofp.dp): Add cortex-r7 and cortex-r8 to the list of targets that
1535 support this option.
1537 2018-11-29 Alan Modra <amodra@gmail.com>
1539 * config/rs6000/rs6000.c (rs6000_emit_move): Disable long
1540 double split for targets other than Darwin.
1542 2018-11-29 Alan Modra <amodra@gmail.com>
1544 * config/rs6000/rs6000.md (movdi_internal64): Correct lengths.
1546 2018-11-29 Alan Modra <amodra@gmail.com>
1548 * config/rs6000/predicates.md (easy_fp_constant): Remove code
1549 dealing with integers in const_double. Assert on unexpected
1550 modes. Delete superfluous ABI_V4 test.
1551 * config/rs6000/rs6000.c (rs6000_emit_move): Comment fixes.
1552 Don't call easy_fp_constant for Pmode.
1553 (rs6000_hash_constant): Remove code dealing with integers in
1555 (rs6000_legitimate_constant_p): Likewise.
1556 (output_toc): Formatting, use CONST_DOUBLE_P.
1558 2018-11-29 Alan Modra <amodra@gmail.com>
1560 * config/rs6000/constraints.md (G, H): Comment on purpose of
1561 constraint. Correct mode comments and "G" mode test.
1562 * config/rs6000/rs6000.md (movdi_internal32): Remove "GH" from
1563 alternative handling "F". Add length attr. Formatting.
1564 (mov<mode>_softfloat <FMOVE128>): Delete "GH" from
1565 alternative, and move "F" to separate alternative. Correct
1568 2018-11-29 Alan Modra <amodra@gmail.com>
1570 * config/rs6000/predicates.md (easy_vector_constant): Don't call
1573 2018-11-29 Alan Modra <amodra@gmail.com>
1575 * config.in (HAVE_AS_PLTSEQ): Add.
1576 * config/rs6000/predicates.md (indirect_call_operand): New.
1577 * config/rs6000/rs6000-protos.h (rs6000_pltseq_template),
1578 (rs6000_sibcall_sysv): Declare.
1579 * config/rs6000/rs6000.c (init_cumulative_args): Set cookie
1580 CALL_LONG for -fno-plt.
1581 (print_operand <T, z, 0>): Handle UNSPEC_PLTSEQ.
1582 (rs6000_indirect_call_template_1): Emit .reloc directives for
1583 UNSPEC_PLTSEQ calls.
1584 (rs6000_pltseq_template): New function.
1585 (rs6000_longcall_ref): Add arg parameter. Use PLT16 insns if
1586 relocs supported by assembler. Move SYMBOL_REF test to callers.
1587 (rs6000_call_aix): Adjust rs6000_longcall_ref call. Package
1588 insns in UNSPEC_PLTSEQ, preserving original func_desc.
1589 (rs6000_call_sysv): Likewise.
1590 (rs6000_sibcall_sysv): New function.
1591 * config/rs6000/rs6000.h (HAVE_AS_PLTSEQ): Provide default.
1592 * config/rs6000/rs6000.md (UNSPEC_PLTSEQ, UNSPEC_PLT16_HA,
1593 UNSPEC_PLT16_LO): New.
1594 (pltseq_tocsave, pltseq_plt16_ha, pltseq_plt16_lo, pltseq_mtctr): New.
1595 (call_indirect_nonlocal_sysv): Don't differentiate zero from non-zero
1596 cookie in constraints. Test explicitly for flags in length attr.
1597 Handle unspec operand 1.
1598 (call_value_indirect_nonlocal_sysv): Likewise.
1599 (call_indirect_aix, call_value_indirect_aix): Handle unspec operand 1.
1600 (call_indirect_elfv2, call_value_indirect_elfv2): Likewise.
1601 (sibcall, sibcall_value): Use rs6000_sibcall_sysv.
1602 (sibcall_indirect_nonlocal_sysv): New pattern.
1603 (sibcall_value_indirect_nonlocal_sysv): Likewise.
1604 (sibcall_nonlocal_sysv, sibcall_value_nonlocal_sysv): Remove indirect
1606 * configure.ac: Check for gas plt sequence marker support.
1607 * configure: Regenerate.
1609 2018-11-29 Alan Modra <amodra@gmail.com>
1611 * config/rs6000/predicates.md (unspec_tls): New.
1612 * config/rs6000/rs6000-protos.h (rs6000_call_template),
1613 (rs6000_sibcall_template): Update prototype.
1614 (rs6000_longcall_ref): Delete.
1615 (rs6000_call_sysv): Declare.
1616 * config/rs6000/rs6000.c (edit_tls_call_insn): New function.
1617 (global_tlsarg): New variable.
1618 (rs6000_legitimize_tls_address): Rewrite __tls_get_addr call
1620 (print_operand): Extract UNSPEC_TLSGD address operand.
1621 (rs6000_call_template, rs6000_sibcall_template): Remove arg
1622 parameter, extract from second call operand instead.
1623 (rs6000_longcall_ref): Make static, localize vars.
1624 (rs6000_call_aix): Rename parameter to reflect new usage. Take
1625 tlsarg from global_tlsarg. Don't create unused rtl or nop insns.
1626 (rs6000_sibcall_aix): Rename parameter to reflect new usage. Take
1627 tlsarg from global_tlsarg.
1628 (rs6000_call_sysv): New function.
1629 * config/rs6000/rs6000.md: Adjust rs6000_call_template and
1630 rs6000_sibcall_template throughout.
1631 (tls_gd_aix, tls_gd_sysv, tls_gd_call_aix, tls_gd_call_sysv): Delete.
1632 (tls_ld_aix, tls_ld_sysv, tls_ld_call_aix, tls_ld_call_sysv): Delete.
1633 (tls_gdld_nomark): New insn.
1634 (tls_gd): Swap operand order. Simplify mode selection.
1635 (tls_gd_high, tls_gd_low): Swap operand order.
1636 (tls_ld): Remove const_int 0 vector element from UNSPEC_TLSLD.
1637 Simplify mode selection.
1638 (tls_ld_high, tls_ld_low): Similarly adjust UNSPEC_TLSLD.
1639 (call, call_value): Don't assert for second call operand.
1640 Use rs6000_call_sysv.
1642 2018-11-29 Alan Modra <amodra@gmail.com>
1644 * config/rs6000/darwin.md (call_indirect_nonlocal_darwin64),
1645 (call_nonlocal_darwin64, call_value_indirect_nonlocal_darwin64),
1646 (call_value_nonlocal_darwin64): Remove constraints from second call
1647 arg, the rounded_stack_size_rtx arg.
1648 * config/rs6000/rs6000.md (tls_gd_aix, tls_gd_sysv, tls_gd_call_aix),
1649 (tls_gd_call_sysv, tls_ld_aix, tls_ld_sysv, tls_ld_call_aix),
1650 (tls_ld_call_sysv, call_local32, call_local64, call_value_local32),
1651 (call_value_local64, call_indirect_nonlocal_sysv),
1652 (call_nonlocal_sysv, call_nonlocal_sysv_secure),
1653 (call_value_indirect_nonlocal_sysv, call_value_nonlocal_sysv),
1654 (call_value_nonlocal_sysv_secure, call_local_aix),
1655 (call_value_local_aix, call_nonlocal_aix, call_value_nonlocal_aix),
1656 (call_indirect_aix, call_value_indirect_aix, call_indirect_elfv2),
1657 (call_value_indirect_elfv2, sibcall_local32, sibcall_local64),
1658 (sibcall_value_local32, sibcall_value_local64, sibcall_aix),
1659 (sibcall_value_aix): Likewise.
1661 2018-11-29 Alan Modra <amodra@gmail.com>
1663 * config/rs6000/rs6000.md (TLSmode): Delete mode iterator. Replace
1664 with P throughout except for call mems which should use SI.
1665 (tls_abi_suffix, tls_sysv_suffix, tls_insn_suffix): Delete mode
1666 attributes. Replace with bits, mode and ptrload respectively.
1668 2018-11-29 Alan Modra <amodra@gmail.com>
1670 * config/rs6000/rs6000-protos.h (rs6000_indirect_call_template),
1671 (rs6000_indirect_sibcall_template): Declare.
1672 * config/rs6000/rs6000.c (rs6000_indirect_call_template_1),
1673 (rs6000_indirect_call_template, rs6000_indirect_sibcall_template):
1675 * config/rs6000/rs6000.md (call_indirect_nonlocal_sysv),
1676 (call_value_indirect_nonlocal_sysv, sibcall_nonlocal_sysv),
1677 (call_indirect_aix, call_value_indirect_aix): Use
1678 rs6000_indirect_call_template and rs6000_indirect_sibcall_template.
1679 call_indirect_elfv2, call_value_indirect_elfv2): Likewise, and
1680 handle both speculation and non-speculation cases.
1681 (call_indirect_aix_nospec, call_value_indirect_aix_nospec): Delete.
1682 (call_indirect_elfv2_nospec, call_value_indirect_elfv2_nospec): Delete.
1684 2018-11-29 Alan Modra <amodra@gmail.com>
1686 * config/rs6000/rs6000-protos.h (rs6000_call_template): Declare.
1687 (rs6000_sibcall_template): Declare.
1688 (macho_call_template): Rename from output_call.
1689 * config/rs6000/rs6000.c (rs6000_call_template_1): New function.
1690 (rs6000_call_template, rs6000_sibcall_template): Likewise.
1691 (macho_call_template): Rename from output_call.
1692 * config/rs6000/rs6000.md (tls_gd_aix, tls_gd_sysv),
1693 (tls_gd_call_aix, tls_gd_call_sysv, tls_ld_aix, tls_ld_sysv),
1694 (tls_ld_call_aix, tls_ld_call_sysv, call_nonlocal_sysv),
1695 (call_nonlocal_sysv_secure, call_value_nonlocal_sysv),
1696 (call_value_nonlocal_sysv_secure, call_nonlocal_aix),
1697 (call_value_nonlocal_aix): Use rs6000_call_template and update
1698 occurrences of output_call to macho_call_template.
1699 (sibcall_nonlocal_sysv, sibcall_value_nonlocal_sysv, sibcall_aix),
1700 (sibcall_value_aix): Use rs6000_sibcall_template.
1702 2018-11-28 Aaron Sawdey <acsawdey@linux.ibm.com>
1704 * config/rs6000/rs6000-string.c (expand_block_clear): Change how
1705 we determine if unaligned vsx is ok.
1707 2018-11-28 Jan Hubicka <jh@suse.cz>
1709 * predict.c (determine_unlikely_bbs): Forward declare; also determine
1710 edges that are always known to be taken because it is only likely
1711 edge out of given BB.
1712 (tree_estimate_probability): Call before profile guessing to get bit
1715 2018-11-28 Jan Hubicka <jh@suse.cz>
1717 * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Handle
1718 profile_probability::always better.
1720 2018-11-28 Jan Hubicka <jh@suse.cz>
1722 * profile-count.h (profile_count::split): Give better result when
1723 splitting profile_probability::always.
1725 2018-11-28 Vladimir Makarov <vmakarov@redhat.com>
1728 * ira-costs.c (scan_one_insn): Process subregs when updating costs
1729 for pseudos and allocnos from insn.
1731 2018-11-28 David Edelsohn <dje.gcc@gmail.com>
1733 * config/rs6000/aix72.h: Update to match aix71.h changes.
1735 2018-11-28 Jeff Law <law@redhat.com>
1737 * config/h8300/constraints.md: Add "C" constraint for call insns.
1738 * config/h8300/h8300.md (call, call_value): Turn into a define_expand
1739 and define_insn pair. Move invalid call targets into a register in
1740 the expander and fix constraints in the matching pattern.
1741 * config/h8300/predicates.md (call_expander_operand): Renamed from
1742 call_insn_operand. Reject things we shouldn't be trying to handle.
1743 (call_insn_operand): New predicate for use by the call/call_value
1745 (small_call_insn_operand): Update appropriately.
1747 2018-11-28 Sam Tebbs <sam.tebbs@arm.com>
1749 * config/aarch64/aarch64.c (aarch64_process_target_attr): Replace
1750 calls to strtok with strtok_r.
1752 2018-11-28 Richard Biener <rguenther@suse.de>
1754 PR tree-optimization/88223
1755 * tree-ssa-sccvn.c (vn_reference_lookup_3): When skipping
1756 over a stored-same value may-alias store make sure to consider
1757 partial overlaps which are valid when TBAA reasonings do not
1758 apply and byte-granular overlaps are possible at all.
1760 2018-11-28 Richard Biener <rguenther@suse.de>
1762 PR tree-optimization/88217
1763 * vr-values.c (vr_values::extract_range_from_phi_node): Make
1764 sure to handle results > +INF and < -INF correctly when
1765 trying to drop down to +INF - 1 or -INF + 1.
1767 2018-11-28 Alan Modra <amodra@gmail.com>
1769 * xcoffout.c (do_block): Signed/unsigned warning fix.
1771 2018-11-28 Richard Biener <rguenther@suse.de>
1773 PR tree-optimization/79351
1774 * tree-ssa-sccvn.c (vn_reference_lookup_3): For assignments from
1775 empty CONSTRUCTORs ensure the store is at a constant position.
1777 2018-11-28 Richard Biener <rguenther@suse.de>
1779 PR tree-optimization/88229
1780 * tree-ssa.c (non_rewritable_mem_ref_base): Check DECL_SIZE_UNIT
1781 is an INTEGER_CST before accessing it so.
1783 2018-11-28 Sam Tebbs <sam.tebbs@arm.com>
1785 * doc/invoke.texi (-mtune=): Remove obsolete CPU names.
1787 2018-11-28 Jakub Jelinek <jakub@redhat.com>
1790 * config/i386/i386.c (ix86_expand_sse_movcc): Handle DFmode and
1791 SFmode using sse4_1_blendvs[sd] with TARGET_SSE4_1. Formatting fixes.
1792 * config/i386/sse.md (sse4_1_blendv<ssemodesuffix>): New pattern.
1794 2018-11-27 Martin Liska <mliska@suse.cz>
1796 * gcov.c (generate_results): Append current_working_directory
1799 2018-11-27 Mike Gulick <mgulick@mathworks.com>
1801 PR preprocessor/83173
1802 * input.c (dump_location_info): Dump reason and included_from
1803 fields from line_map_ordinary struct. Fix indentation when
1804 location > 5 digits.
1805 * diagnostic-show-locus.c (num_digits, num_digits): Move to
1806 diagnostic.c to allow it to be utilized by input.c.
1807 * diagnostic.c (num_digits, selftest::test_num_digits): Moved
1809 (selftest::diagnostic_c_tests): Run selftest::test_num_digits.
1810 * diagnostic.h (num_digits): Add extern definition.
1812 2018-11-27 Fredrik Noring <noring@nocrew.org>
1814 * config/mips/mips.c (mips_reorg_process_insns)
1815 (mips_option_override): Handle `-mfix-r5900'.
1816 * config/mips/mips.h (ASM_SPEC): Add `mfix-r5900' and
1818 * config/mips/mips.opt (mfix-r5900): New option.
1819 * doc/invoke.texi: Document the `r5900' processor name, and
1820 `-mfix-r5900' and `-mno-fix-r5900' options.
1822 2018-11-27 Jakub Jelinek <jakub@redhat.com>
1825 * config/rs6000/rs6000.c (print_operand) <case 'D'>: Use
1826 output_operand_lossage instead of gcc_assert.
1827 <case 't'>: Likewise.
1828 <case 'z'>: Likewise.
1829 <case 'V'>: Use output_operand_lossage instead of gcc_unreachable.
1831 2018-11-27 Jeff Law <law@redhat.com>
1833 * config/riscv/riscv (riscv_block_mvoe_straight): Use RETURN_BEGIN
1834 in call to move_by_pieces.
1836 * config/sh/sh-mem.c (expand_block_move): Use RETURN_BEGIN in call
1839 * config/lm32/lm32.c (lm32_block_move_inline): Use RETURN_BEGIN in
1840 call to move_by_pieces.
1842 * config/mips/mips.c (mips_block_move_straight): Use RETURN_BEGIN
1843 in call to move_by_pieces.
1845 * config/microblaze/microblaze.c (microblaze_block_move_straight): Use
1846 RETURN_BEGIN in call to move_by_pieces.
1847 (microblaze_expand_block_move): Likewise.
1849 2018-11-27 Tamar Christina <tamar.christina@arm.com>
1851 * doc/md.texi (xorsign): Document it.
1853 2018-11-27 Martin Liska <mliska@suse.cz>
1855 * config/gnu-user.h (TARGET_F951_OPTIONS): New.
1856 * gcc.c (find_fortran_preinclude_file): New function
1857 to handle Fortran pre-include.
1859 2018-11-27 Martin Liska <mliska@suse.cz>
1861 * asan.c (asan_emit_stack_protection): Use new enum values
1862 instead of int constants.
1863 * builtins.c (expand_builtin_memory_copy_args): Replace int
1864 type with memop_ret enum type.
1865 (expand_builtin_mempcpy_args): Likewise.
1866 (expand_builtin_memcpy): Use new enum values
1867 instead of int constants. Likewise.
1868 (expand_builtin_mempcpy): Likewise.
1869 (expand_movstr): Likewise.
1870 (expand_builtin_strcpy_args): Likewise.
1871 (expand_builtin_stpcpy_1): Likewise.
1872 (expand_builtin_strncpy): Likewise.
1873 (expand_builtin_memset_args): Likewise.
1874 * expr.c (move_by_pieces_d::finish_endp): Rename to ...
1875 (move_by_pieces_d::finish_retmode): ... this.
1876 (move_by_pieces): Change last argument type to memop_ret.
1877 (store_by_pieces): Use new enum values
1878 instead of int constants.
1879 (emit_block_move_hints): Likewise.
1880 (emit_push_insn): Likewise.
1881 (store_expr): Likewise.
1882 * expr.h (store_by_pieces): Change int to newly added enum
1884 * rtl.h (enum memop_ret): Define.
1885 (move_by_pieces): Use the enum type.
1887 2018-11-27 Alan Modra <amodra@gmail.com>
1889 * config/rs6000/aix71.h (ASM_SPEC): Don't select default -maix64
1891 (ASM_CPU_SPEC): Do so here. Rewrite using if .. else if .. specs
1892 form. Error on missing -mcpu case.
1893 * config/rs6000/driver-rs6000.c (asm_names <_AIX>): Update NULL case.
1894 (asm_names <!_AIX>): Add missing cpus. Update NULL case. Apply
1895 PR63177 fix for -mcpu=power8 and -mcpu=powerpc64le.
1896 * config/rs6000/rs6000.h (ASM_CPU_SPEC): Rewrite using if ..
1897 else if .. specs form. Error on missing -mcpu case. Don't output
1898 duplicate -maltivec. Apply PR63177 fix for -mcpu=powerpc64le.
1900 2018-11-26 David Malcolm <dmalcolm@redhat.com>
1902 * dump-context.h (dump_context::dump_loc): Convert 1st param from
1903 dump_flags_t to const dump_metadata_t &. Convert 2nd param from
1904 const dump_location_t & to const dump_user_location_t &.
1905 (dump_context::dump_loc_immediate): Convert 2nd param from
1906 const dump_location_t & to const dump_user_location_t &.
1907 (dump_context::dump_gimple_stmt): Convert 1st param from
1908 dump_flags_t to const dump_metadata_t &.
1909 (dump_context::void dump_gimple_stmt_loc): Likewise; convert
1910 2nd param from const dump_location_t & to
1911 const dump_user_location_t &.
1912 (dump_context::dump_gimple_expr): Convert 1st param from
1913 dump_flags_t to const dump_metadata_t &.
1914 (dump_context::dump_gimple_expr_loc): Likewise; convert
1915 2nd param from const dump_location_t & to
1916 const dump_user_location_t &.
1917 (dump_context::dump_generic_expr): Convert 1st param from
1918 dump_flags_t to const dump_metadata_t &.
1919 (dump_context::dump_generic_expr_loc): Likewise; convert
1920 2nd param from const dump_location_t & to
1921 const dump_user_location_t &.
1922 (dump_context::dump_printf_va): Convert 1st param from
1923 dump_flags_t to const dump_metadata_t &.
1924 (dump_context::dump_printf_loc_va): Likewise; convert
1925 2nd param from const dump_location_t & to
1926 const dump_user_location_t &.
1927 (dump_context::dump_dec): Convert 1st param from
1928 dump_flags_t to const dump_metadata_t &.
1929 (dump_context::dump_symtab_node): Likewise.
1930 (dump_context::begin_scope): Split out 2nd param into
1931 user and impl locations.
1932 (dump_context::ensure_pending_optinfo): Add metadata param.
1933 (dump_context::begin_next_optinfo): Replace dump_location_t param
1934 with metadata and user location.
1935 * dumpfile.c (dump_context::dump_loc): Convert 1st param from
1936 dump_flags_t to const dump_metadata_t &. Convert 2nd param from
1937 const dump_location_t & to const dump_user_location_t &.
1938 (dump_context::dump_loc_immediate): Convert 2nd param from
1939 const dump_location_t & to const dump_user_location_t &.
1940 (dump_context::dump_gimple_stmt): Convert 1st param from
1941 dump_flags_t to const dump_metadata_t &.
1942 (dump_context::void dump_gimple_stmt_loc): Likewise; convert
1943 2nd param from const dump_location_t & to
1944 const dump_user_location_t &.
1945 (dump_context::dump_gimple_expr): Convert 1st param from
1946 dump_flags_t to const dump_metadata_t &.
1947 (dump_context::dump_gimple_expr_loc): Likewise; convert
1948 2nd param from const dump_location_t & to
1949 const dump_user_location_t &.
1950 (dump_context::dump_generic_expr): Convert 1st param from
1951 dump_flags_t to const dump_metadata_t &.
1952 (dump_context::dump_generic_expr_loc): Likewise; convert
1953 2nd param from const dump_location_t & to
1954 const dump_user_location_t &.
1955 (dump_context::dump_printf_va): Convert 1st param from
1956 dump_flags_t to const dump_metadata_t &.
1957 (dump_context::dump_printf_loc_va): Likewise; convert
1958 2nd param from const dump_location_t & to
1959 const dump_user_location_t &.
1960 (dump_context::dump_dec): Convert 1st param from
1961 dump_flags_t to const dump_metadata_t &.
1962 (dump_context::dump_symtab_node): Likewise.
1963 (dump_context::begin_scope): Split out 2nd param into
1964 user and impl locations.
1965 (dump_context::ensure_pending_optinfo): Add metadata param.
1966 (dump_context::begin_next_optinfo): Replace dump_location_t param
1967 with metadata and user location.
1968 (dump_gimple_stmt): Convert 1st param from dump_flags_t to
1969 const dump_metadata_t &.
1970 (dump_gimple_stmt_loc): Likewise; convert 2nd param from
1971 const dump_location_t & to const dump_user_location_t &.
1972 (dump_gimple_expr): Convert 1st param from dump_flags_t to
1973 const dump_metadata_t &.
1974 (dump_gimple_expr_loc): Likewise; convert 2nd param from
1975 const dump_location_t & to const dump_user_location_t &.
1976 (dump_generic_expr): Convert 1st param from dump_flags_t to
1977 const dump_metadata_t &.
1978 (dump_generic_expr_loc): Likewise; convert 2nd param from
1979 const dump_location_t & to const dump_user_location_t &.
1980 (dump_printf): Convert 1st param from dump_flags_t to
1981 const dump_metadata_t &.
1982 (dump_printf_loc): Likewise; convert 2nd param from
1983 const dump_location_t & to const dump_user_location_t &.
1984 (dump_dec): Convert 1st param from dump_flags_t to
1985 const dump_metadata_t &.
1986 (dump_symtab_node): Likewise.
1987 (dump_begin_scope): Split out 2nd param into user and impl
1989 (selftest::assert_impl_location_eq): New function.
1990 (ASSERT_IMPL_LOCATION_EQ): New macro.
1991 (selftest::test_impl_location): Update to use
1992 ASSERT_IMPL_LOCATION_EQ.
1993 (selftest::test_capture_of_dump_calls): Convert "loc" to
1994 dump_user_location_t. Add ASSERT_IMPL_LOCATION_EQ throughout,
1995 verifying line numbers of dump emissions.
1996 * dumpfile.h (class dump_metadata_t): New class.
1997 (dump_printf): Convert 1st param from dump_flags_t to
1998 const dump_metadata_t &.
1999 (dump_printf_loc): Likewise; convert 2nd param from
2000 const dump_location_t & to const dump_user_location_t &.
2001 (dump_generic_expr_loc): Likewise.
2002 (dump_generic_expr): Convert 1st param from dump_flags_t to
2003 const dump_metadata_t &.
2004 (dump_gimple_stmt_loc): Likewise; convert 2nd param from
2005 const dump_location_t & to const dump_user_location_t &.
2006 (dump_gimple_stmt): Convert 1st param from dump_flags_t to
2007 const dump_metadata_t &.
2008 (dump_gimple_expr_loc): Likewise; convert 2nd param from
2009 const dump_location_t & to const dump_user_location_t &.
2010 (dump_gimple_expr): Convert 1st param from dump_flags_t to
2011 const dump_metadata_t &.
2012 (dump_symtab_node): Likewise.
2013 (dump_dec): Likewise.
2014 (dump_begin_scope): Split out 2nd param into user and impl
2016 (auto_dump_scope::auto_dump_scope): Split "loc" param into a user
2017 location and impl_location, and capture the impl_location.
2018 (AUTO_DUMP_SCOPE): Rename param from LOC to USER_LOC.
2019 * loop-unroll.c (report_unroll): Update for changes to
2020 dump_printf_loc and dump_printf.
2021 * opt-problem.cc (opt_problem::opt_problem): Update for change to
2023 * optinfo-emit-json.cc
2024 (selftest::test_building_json_from_dump_calls): Convert "loc" from
2025 dump_location_t to dump_user_location_t.
2026 * optinfo.cc (optinfo::emit_for_opt_problem): Update for change in
2028 * profile.c (compute_branch_probabilities): Update for change to
2030 * selftest.h (ASSERT_STR_CONTAINS_AT): New macro.
2031 * tree-vect-slp.c (vect_print_slp_tree): Update for change to
2034 2018-11-27 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2036 * doc/sourcebuild.texi: Document check_effective_target_int_eq_float
2037 and check_effective_target_ptr_eq_long.
2039 2018-11-27 Alan Modra <amodra@gmail.com>
2041 * config.gcc (powerpc*-*-freebsd*, powerpc-*-netbsd*),
2042 (powerpc-*-eabisimaltivec*, powerpc-*-eabisim*, powerpc-*-elf*),
2043 (powerpc-*-eabialtivec*, powerpc-*-eabi*, powerpc-*-rtems*),
2044 (powerpc-wrs-vxworks*, powerpc-*-lynxos*, powerpcle-*-elf*),
2045 (powerpcle-*-eabisim*, powerpcle-*-eabi*): Add gnu-user.h to tm_file.
2046 * config/rs6000/freebsd.h (CPLUSPLUS_CPP_SPEC),
2047 (LINK_GCC_C_SEQUENCE_SPEC): Undef.
2048 (ASM_APP_ON, ASM_APP_OFF): Don't define.
2049 * config/rs6000/freebsd64.h (ASM_APP_ON, ASM_APP_OFF): Don't define.
2050 * config/rs6000/lynx.h (ASM_APP_ON, ASM_APP_OFF): Don't define.
2051 * config/rs6000/linux64.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
2052 * config/rs6000/netbsd.h (CPLUSPLUS_CPP_SPEC),
2053 (LINK_GCC_C_SEQUENCE_SPEC): Undef.
2054 * config/rs6000/rtems.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
2055 * config/rs6000/sysv4.h (GNU_USER_TARGET_CRTI): Redefine.
2056 (GNU_USER_TARGET_CRTN): Redefine.
2057 (CC1_SPEC): Use GNU_USER_TARGET_CC1_SPEC.
2058 (LIB_LINUX_SPEC): Use GNU_USER_TARGET_LIB_SPEC.
2059 (CRTOFFLOADBEGIN, CRTOFFLOADEND): Don't define.
2060 (STARTFILE_LINUX_SPEC): Define as GNU_USER_TARGET_STARTFILE_SPEC.
2061 (ENDFILE_LINUX_SPEC): Define as GNU_USER_TARGET_ENDFILE_SPEC.
2062 (UCLIBC_DYNAMIC_LINKER, CHOOSE_DYNAMIC_LINKER): Don't define.
2063 (LINK_EH_SPEC): Don't define.
2065 2018-11-26 Martin Sebor <msebor@redhat.com>
2068 * expr.c (string_constant): Handle top-level decls of all character
2069 types and subobjects of narrow character type.
2071 2018-11-27 Alan Modra <amodra@gmail.com>
2073 * config.gcc (powerpc*-*-linux*): Add linux.h to tm_file.
2074 * config/rs6000/linux.h (TARGET_OS_CPP_BUILTINS): Use
2075 GNU_USER_TARGET_OS_CPP_BUILTINS.
2076 (RS6000_ABI_NAME): Define.
2077 * config/rs6000/linux64.h (TARGET_OS_CPP_BUILTINS): Use
2078 GNU_USER_TARGET_OS_CPP_BUILTINS.
2079 (MUSL_DYNAMIC_LINKER32): Undef before defining.
2080 (UCLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER64): Don't define.
2081 (CHOOSE_DYNAMIC_LINKER): Don't define.
2082 (GNU_USER_DYNAMIC_LINKER32, GNU_USER_DYNAMIC_LINKER64): Don't define.
2083 * config/rs6000/sysv4.h (MUSL_DYNAMIC_LINKER): Undef before defining.
2084 (CHOOSE_DYNAMIC_LINKER, GNU_USER_DYNAMIC_LINKER): Only define when
2085 not already defined.
2086 (CPP_OS_LINUX_SPEC): Remove defines and asserts handled by
2087 TARGET_OS_CPP_BUILTINS.
2089 2018-11-26 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2091 * doc/sourcebuild.texi: Document check_effective_target_newlib_nano_io.
2093 2018-11-26 Jakub Jelinek <jakub@redhat.com>
2096 * config/i386/i386.c (def_builtin2): If tcode == VOID_FTYPE_UINT64
2097 and !TARGET_64BIT, return NULL_TREE.
2100 * dwarf2out.c (secname_for_decl): For functions with
2101 DECL_SECTION_NAME if in_cold_section_p, try to return
2102 current_function_section's name if it is a named section.
2104 2018-11-26 Maya Rashish <coypu@sdf.org>
2107 * config.host (*-*-netbsd*): Use x-netbsd and host-netbsd.o.
2108 * config/x-netbsd: New file.
2109 * config/host-netbsd: New file.
2111 2018-11-26 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2113 * doc/sourcebuild.texi: Document check_effective_target_size20plus.
2114 Clarify documentation for check_effective_target_size32plus.
2116 2018-11-26 Aaron Sawdey <acsawdey@linux.ibm.com>
2118 * config/rs6000/rs6000-string.c (expand_cmp_vec_sequence): Rename
2119 and modify expand_strncmp_vec_sequence.
2120 (emit_final_compare_vec): Rename and modify emit_final_str_compare_vec.
2121 (generate_6432_conversion): New function.
2122 (expand_block_compare): Add support for vsx.
2123 (expand_block_compare_gpr): New function.
2124 * config/rs6000/rs6000.opt (rs6000_block_compare_inline_limit): Increase
2125 default limit to 63 because of more compact vsx code.
2127 2018-11-26 Uros Bizjak <ubizjak@gmail.com>
2130 * config/i386/i386.c (dbx_register_map): Use IGNORED_DWARF_REGNUM
2131 for registers for which no debug information can be generated.
2132 Use INVALID_REGNUM for non-existent registers.
2133 (dbx64_register_map): Ditto.
2134 (svr4_dbx_register_map): Ditto.
2136 2018-11-26 Sandra Loosemore <sandra@codesourcery.com>
2139 * doc/invoke.texi (Optimize Options): Document that
2140 -freorder-functions also uses "hot" and "cold" attributes.
2142 2018-11-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2144 * config/aarch64/aarch64.c (aarch64_mangle_type): Fix typo in comment.
2146 2018-11-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2148 * config/arm/types.md (mul64): Rename to...
2149 (widen_mul64): ... This.
2150 * config/arm/arm-generic.md: Rename mul64 to widen_mul64.
2151 * config/arm/cortex-a15.md: Likewise.
2152 * config/arm/cortex-a5.md: Likewise.
2153 * config/arm/cortex-a53.md: Likewise.
2154 * config/arm/cortex-a57.md: Likewise.
2155 * config/arm/cortex-a7.md: Likewise.
2156 * config/arm/cortex-m4.md: Likewise.
2157 * config/arm/exynos-m1.md: Likewise.
2158 * config/arm/marvell-pj4.md: Likewise.
2159 * config/arm/xgene1.md: Likewise.
2161 2018-11-26 Richard Biener <rguenther@suse.de>
2163 PR tree-optimization/88182
2164 * tree-vect-loop.c (vectorizable_reduction): Pick up single
2165 correct reduc_def_info.
2166 * tree-vect-slp.c (vect_analyze_slp_instance): Set
2167 STMT_VINFO_REDUC_DEF of the first stmt.
2169 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2171 * doc/invoke.texi: Document z14/arch12 -march option.
2173 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2176 * doc/invoke.texi (Option Summary): Add -Wmissing-noreturn.
2177 (Warning Options): Likewise.
2179 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2182 * doc/extend.texi (Common Function Attributes): Clarify that
2183 functions with "const" attribute can read const global variables.
2185 2018-11-26 Alan Modra <amodra@gmail.com>
2187 * config/rs6000/rs6000.h (OBJECT_PEF, TARGET_MACOS): Delete.
2189 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2192 * doc/extend.texi (Common Variable Attributes): Use preferred
2193 placement of type attributes in examples, plus whitespace fixes.
2194 (Type Attributes): Clarify why placement of attributes
2195 immediately after struct/union/enum keyword is preferred.
2196 (Common Type Attributes): Use preferred placement of type
2197 attributes in examples, plus more whitespace fixes.
2199 2018-11-25 Paul Koning <ni1d@arrl.net>
2201 * config/pdp11/pdp11.h (TARGET_HAS_NO_HW_DIVIDE): Define.
2203 2018-11-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2205 * doc/sourcebuild.texi (Effective-Target Keywords, Environment
2206 attributes): Document d_runtime.
2208 2018-11-25 Vladimir Makarov <vmakarov@redhat.com>
2211 * ira-costs.c (record_operand_costs): Initiate register move cost
2214 2018-11-23 Jeff Law <law@redhat.com>
2216 PR rtl-optimization/87468
2217 * tree-ssa-threadupdate.c (create_block_for_threading): Clear
2218 EDGE_IGNORE on all outgoing edges of the duplicate block.
2220 2018-11-23 Vladimir Makarov <vmakarov@redhat.com>
2223 * ira-costs.c (record_operand_costs): Use bigger hard reg class if
2224 its mode does not fit to the original class.
2226 2018-11-23 Martin Sebor <msebor@redhat.com>
2228 PR tree-optimization/87756
2229 * expr.c (string_constant): Synthesize a string literal from
2230 the address of a constant character.
2231 * tree.c (build_string_literal): Add an argument.
2232 * tree.h (build_string_literal): Same.
2234 2018-11-23 Christoph Muellner <christoph.muellner@theobroma-systems.com>
2236 * config/aarch64/aarch64-cores.def: Define emag.
2237 * config/aarch64/aarch64-tune.md: Regenerated with emag.
2238 * config/aarch64/aarch64.c (emag_tunings): New struct.
2239 * doc/invoke.texi: Document mtune value.
2241 2018-11-23 Christoph Muellner <christoph.muellner@theobroma-systems.com>
2242 Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2244 * config/aarch64/aarch64.c (xgene1_tunings): Optimize Xgene1 tunings
2246 * config/aarch64/aarch64.c (xgene1_tunings): Add Xgene1 specific
2248 * config/aarch64/aarch64.c (xgene1_addrcost_table): Correct the post-modify
2250 * config/arm/aarch-cost-tables.h (xgene1_extra_costs): Update the cost table
2253 2018-11-23 Richard Biener <rguenther@suse.de>
2255 PR tree-optimization/88149
2256 * tree-vect-slp.c (vect_slp_analyze_node_operations): Detect
2257 the case where there are two different def types for the
2258 same operand at different operand position in the same stmt.
2260 2018-23-11 Mihail Ionescu <mihail.ionescu@arm.com>
2262 * config/arm/arm.c (arm_expand_compare_and_swap): Simplify and call
2263 gen_atomic_compare_swap_1.
2264 (arm_evpc_neon_vuzp): Likewise gen_neon_vuzp_internal.
2265 (arm_evpc_neon_vtrn): Likewise gen_neon_vtrn_internal.
2266 (arm_evpc_neon_vext): Likewise gen_neon_vext_internal.
2267 (arm_evpc_neon_vzip): Likewise gen_neon_vzip_internal.
2268 (arm_evpc_neon_vrev): Replace the function pointer and simplify the mode
2270 * config/arm/arm.md (neon_vext<mode>),
2271 (neon_vrev64<mode>, neon_vrev32<mode>),
2272 (neon_vrev16<mode>, neon_vtrn<mode>_internal),
2273 (neon_vzip<mode>_internal, neon_vuzp<mode>_internal): Add an '@'character
2274 before the pattern name.
2275 * config/arm/sync.md:
2276 (atomic_compare_and_swap<CCSI:arch><NARROW:mode>_1),
2277 (atomic_compare_and_swap<CCSI:arch><SIDI:mode>_1): Likewise.
2279 2018-11-23 Jakub Jelinek <jakub@redhat.com>
2281 PR tree-optimization/86614
2282 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return early
2283 if TREE_NO_WARNING is set on ref.ref.
2285 2018-11-22 Sandra Loosemore <sandra@codesourcery.com>
2286 Alan Coopersmith <alan.coopersmith@oracle.com>
2289 * doc/extend.texi (Designated Inits): Clarify handling of multiple
2290 initializers for unions.
2292 2018-11-22 Jan Hubicka <jh@suse.cz>
2295 * ipa-devirt.c (type_variants_equivalent_p): Drop warn and warned
2296 parameters; do not warn here.
2297 (odr_subtypes_equivalent_p): Likewise.
2298 (warn_odr): Fix typo.
2299 (warn_types_mismatch): Do not output confused warnings on integer types.
2300 (odr_types_equivalent_p): Update.
2302 2018-11-22 Jakub Jelinek <jakub@redhat.com>
2304 * config/i386/i386.c (ix86_option_override_internal,
2305 ix86_can_inline_p, classify_argument, construct_container,
2306 ix86_expand_prologue, ix86_expand_split_stack_prologue,
2307 ix86_expand_carry_flag_compare, expand_set_or_movmem_via_loop,
2308 expand_setmem_epilogue_via_loop, promote_duplicated_reg,
2309 ix86_expand_set_or_movmem, ix86_init_builtins_va_builtins_abi):
2312 * config/i386/i386.c (ix86_option_override_internal): For
2313 stack_protector_guard related options, use opts_set->x_ instead
2314 of global_options_set. and prefix options with opts->x_ . Move
2315 defaults for offset and reg into else block.
2317 2018-11-22 Uros Bizjak <ubizjak@gmail.com>
2319 * config/i386/i386.c (ix86_check_avx_upper_register):
2320 Return true for all SSE registers with mode bitsize > 128.
2322 2018-11-22 Vladimir Makarov <vmakarov@redhat.com>
2324 PR rtl-optimization/87718
2325 * ira-costs.c: Remove trailing white-spaces.
2326 (record_operand_costs): Add a special treatment for moves
2327 involving a hard register.
2329 2018-11-22 Uros Bizjak <ubizjak@gmail.com>
2331 * config/i386/i386.c (ix86_avx_emit_vzeroupper): Remove.
2332 (ix86_emit_mode_set) <case AVX_U128>: Emit vzeroupper here.
2334 2018-11-22 Martin Liska <mliska@suse.cz>
2336 * common/config/i386/i386-common.c (processor_names): Add
2337 static assert and add missing "znver2".
2338 (ix86_get_valid_option_values): Add checking assert for null
2339 values and add "native" value if feasible.
2340 * config/i386/i386.h: Do not declare size of processor_names.
2341 * common/config/i386/i386-common.c:
2342 * config/i386/i386.c: Add static assert for size
2343 of processor_cost_table.
2345 2018-11-22 Thomas Preud'homme <thomas.preudhomme@linaro.org>
2347 * target-insns.def (stack_protect_combined_set): Define new standard
2349 (stack_protect_combined_test): Likewise.
2350 * cfgexpand.c (stack_protect_prologue): Try new
2351 stack_protect_combined_set pattern first.
2352 * function.c (stack_protect_epilogue): Try new
2353 stack_protect_combined_test pattern first.
2354 * config/arm/arm.c (require_pic_register): Add pic_reg and compute_now
2355 parameters to control which register to use as PIC register and force
2356 reloading PIC register respectively. Insert in the stream of insns if
2358 (legitimize_pic_address): Expose above new parameters in prototype and
2359 adapt recursive calls accordingly. Use pic_reg if non null instead of
2361 (arm_load_pic_register): Add pic_reg parameter and use it if non null.
2362 (arm_legitimize_address): Adapt to new legitimize_pic_address
2364 (thumb_legitimize_address): Likewise.
2365 (arm_emit_call_insn): Adapt to require_pic_register prototype change.
2366 (arm_expand_prologue): Adapt to arm_load_pic_register prototype change.
2367 (thumb1_expand_prologue): Likewise.
2368 * config/arm/arm-protos.h (legitimize_pic_address): Adapt to prototype
2370 (arm_load_pic_register): Likewise.
2371 * config/arm/predicated.md (guard_addr_operand): New predicate.
2372 (guard_operand): New predicate.
2373 * config/arm/arm.md (movsi expander): Adapt to legitimize_pic_address
2375 (builtin_setjmp_receiver expander): Adapt to thumb1_expand_prologue
2377 (stack_protect_combined_set): New expander..
2378 (stack_protect_combined_set_insn): New insn_and_split pattern.
2379 (stack_protect_set_insn): New insn pattern.
2380 (stack_protect_combined_test): New expander.
2381 (stack_protect_combined_test_insn): New insn_and_split pattern.
2382 (arm_stack_protect_test_insn): New insn pattern.
2383 * config/arm/thumb1.md (thumb1_stack_protect_test_insn): New insn pattern.
2384 * config/arm/unspecs.md (UNSPEC_SP_SET): New unspec.
2385 (UNSPEC_SP_TEST): Likewise.
2386 * doc/md.texi (stack_protect_combined_set): Document new standard
2388 (stack_protect_set): Clarify that the operand for guard's address is
2390 (stack_protect_combined_test): Document new standard pattern name.
2391 (stack_protect_test): Clarify that the operand for guard's address is
2394 2018-11-22 Richard Biener <rguenther@suse.de>
2396 PR tree-optimization/88148
2397 * tree-ssa-loop-niter.c (simplify_replace_tree): Get optional
2398 valueization callback parameter and handle it.
2399 * tree-ssa-loop-niter.h (simplify_replace_tree): Export.
2400 * tree-ssa-sccvn.c (process_bb): Eliminate in loop niter trees.
2402 2018-11-22 Richard Biener <rguenther@suse.de>
2406 * lto-streamer-out.c (lto_is_streamable): Allow CALL_EXPRs
2407 which can appear in size expressions.
2408 * tree-streamer-in.c (unpack_ts_base_value_fields): Stream
2409 CALL_EXPR_BY_DESCRIPTOR.
2410 (streamer_read_tree_bitfields): Stream CALL_EXPR_IFN.
2411 * tree-streamer-out.c (pack_ts_base_value_fields): Stream
2412 CALL_EXPR_BY_DESCRIPTOR.
2413 (streamer_write_tree_bitfields): Stream CALL_EXPR_IFN.
2417 * tree.c (free_lang_data_in_one_sizepos): Free non-gimple-val
2420 2018-11-22 Richard Biener <rguenther@suse.de>
2422 PR tree-optimization/88069
2423 * tree-ssa-sccvn.c (visit_phi): Tweak previous fix to not
2424 apply to default defs.
2426 2018-11-22 Jakub Jelinek <jakub@redhat.com>
2430 * config/i386/i386.c (ix86_option_override_internal): Default
2431 ix86_stack_protector_guard to SSP_TLS only if TARGET_THREAD_SSP_OFFSET
2433 * config/i386/i386.md (stack_protect_set, stack_protect_set_<mode>,
2434 stack_protect_test, stack_protect_test_<mode>): Use empty condition
2435 instead of TARGET_SSP_TLS_GUARD.
2437 2018-11-22 Martin Liska <mliska@suse.cz>
2440 * config/i386/i386.c (ix86_option_override_internal): Error
2441 about usage -mabi=ms and -fsanitize=thread.
2443 2018-11-21 Uros Bizjak <ubizjak@gmail.com>
2446 2013-10-26 Vladimir Makarov <vmakarov@redhat.com>
2449 2013-10-25 Vladimir Makarov <vmakarov@redhat.com>
2451 * lra-spills.c (lra_final_code_change): Remove useless move insns.
2453 2018-11-21 Uros Bizjak <ubizjak@gmail.com>
2456 * function.c (expand_function_end): Do not emit extra blockage insn.
2458 2018-11-21 Lokesh Janghel <lokeshjanghel91@gmail.com>
2461 * config/i386/i386.c (function_value_ms_64): Return AX_REG instead
2462 of FIRST_SSE_REG for 4 or 8 byte modes.
2464 2018-11-21 Jan Hubicka <jh@suse.cz>
2467 * tree.c (fld_decl_context): Break out from ...
2468 (free_lang_data_in_decl): ... here; free TREE_PUBLIC, TREE_PRIVATE
2469 DECL_ARTIFICIAL of TYPE_DECL; do not free TREE_TYPE of TYPE_DECL.
2470 (fld_incomplete_type_of): Build copy of TYP_DECL.
2471 * ipa-devirt.c (free_enum_values): Rename to ...
2472 (free_odr_warning_data): ... this one; free also duplicated TYPE_DECLs
2473 and TREE_TYPEs of TYPE_DECLs.
2474 (get_odr_type): Initialize odr_vtable_hash if needed.
2476 2018-11-21 Alexandre Oliva <oliva@adacore.com>
2478 * final.c (compute_discriminator): Declare. Renamed from...
2479 (maybe_set_discriminator): ... this. Set and return a local.
2480 (override_discriminator): New.
2481 (final_scan_insn_1): Set it.
2482 (notice_source_line): Adjust. Always set discriminator.
2484 2018-11-21 Jakub Jelinek <jakub@redhat.com>
2487 * config/aarch64/atomics.md (@aarch64_compare_and_swap<mode>): Use
2488 rIJ constraint for aarch64_plus_operand rather than rn.
2490 2018-11-21 Renlin Li <renlin.li@arm.com>
2493 * explow.h (get_dynamic_stack_size): Declare it as external.
2494 * explow.c (record_new_stack_level): Remove function static attribute.
2495 * function.c (assign_stack_local_1): Dynamically align the stack slot
2496 addr for parameter copy on the stack.
2498 2018-11-21 Richard Biener <rguenther@suse.de>
2501 * bitmap.c (bitmap_last_set_bit): Refactor to avoid warning.
2502 * Makefile.in (bitmap.o-warn): Remove again.
2504 2018-11-20 Jeff Law <law@redhat.com>
2506 PR tree-optimization/88069
2507 * tree-ssa-dom.c (record_equivalences_from_phis): Propagate away
2508 degenerate virtual PHIs.
2510 2018-11-21 H.J. Lu <hongjiu.lu@intel.com>
2513 * config/i386/sse.md (sse4_1_<code>v8qiv8hi2<mask_name>): Replace
2514 nonimmediate_operand with register_operand.
2515 (avx2_<code>v8qiv8si2<mask_name>): Likewise.
2516 (sse4_1_<code>v4qiv4si2<mask_name>): Likewise.
2517 (sse4_1_<code>v4hiv4si2<mask_name>): Likewise.
2518 (sse4_1_<code>v2qiv2di2<mask_name>): Likewise.
2519 (avx512f_<code>v8qiv8di2<mask_name>): Likewise.
2520 (avx2_<code>v4qiv4di2<mask_name>): Likewise.
2521 (avx2_<code>v4hiv4di2<mask_name>): Likewise.
2522 (sse4_1_<code>v2hiv2di2<mask_name>): Likewise.
2523 (sse4_1_<code>v2siv2di2<mask_name>): Likewise.
2524 (*sse4_1_<code>v8qiv8hi2<mask_name>_1): New pattern.
2525 (*sse4_1_<code>v8qiv8hi2<mask_name>_2): Likewise.
2526 (*avx2_<code>v8qiv8si2<mask_name>_1): Likewise.
2527 (*avx2_<code>v8qiv8si2<mask_name>_2): Likewise.
2528 (*sse4_1_<code>v4qiv4si2<mask_name>_1): Likewise.
2529 (*sse4_1_<code>v4qiv4si2<mask_name>_2): Likewise.
2530 (*sse4_1_<code>v4hiv4si2<mask_name>_1): Likewise.
2531 (*sse4_1_<code>v4hiv4si2<mask_name>_2): Likewise.
2532 (*avx512f_<code>v8qiv8di2<mask_name>_1): Likewise.
2533 (*avx512f_<code>v8qiv8di2<mask_name>_2): Likewise.
2534 (*avx2_<code>v4qiv4di2<mask_name>_1): Likewise.
2535 (*avx2_<code>v4qiv4di2<mask_name>_2): Likewise.
2536 (*avx2_<code>v4hiv4di2<mask_name>_1): Likewise.
2537 (*avx2_<code>v4hiv4di2<mask_name>_2): Likewise.
2538 (*sse4_1_<code>v2hiv2di2<mask_name>_1): Likewise.
2539 (*sse4_1_<code>v2hiv2di2<mask_name>_2): Likewise.
2540 (*sse4_1_<code>v2siv2di2<mask_name>_1): Likewise.
2541 (*sse4_1_<code>v2siv2di2<mask_name>_2): Likewise.
2543 2018-11-21 H.J. Lu <hongjiu.lu@intel.com>
2545 * read-rtl.c (apply_subst_iterator): Handle define_split and
2546 define_insn_and_split.
2548 2018-11-21 Jakub Jelinek <jakub@redhat.com>
2550 PR rtl-optimization/87817
2551 * config/i386/i386.md (bmi2_bzhi_<mode>3, *bmi2_bzhi_<mode>3,
2552 *bmi2_bzhi_<mode>3_1, *bmi2_bzhi_<mode>3_1_ccz): Use IF_THEN_ELSE
2553 in the pattern to avoid triggering UB when operands[2] is zero.
2554 (tbm_bextri_<mode>): New expander. Renamed the old define_insn to ...
2555 (*tbm_bextri_<mode>): ... this.
2557 2018-11-21 Tom de Vries <tdevries@suse.de>
2560 * params.def (HOT_BB_COUNT_FRACTION): Terminate help message with
2563 2018-11-21 Andreas Krebbel <krebbel@linux.ibm.com>
2565 * configure.ac: Add check for Binutils to determine whether vector
2566 load/store alignments hints are being supported.
2567 * config.in: Regenerate.
2568 * configure: Regenerate.
2569 * config/s390/s390.c (print_operand): Support new output
2571 * config/s390/s390.md ("movti"): Append alignment hint output
2572 using the new output modifier 'A'.
2573 * config/s390/vector.md ("mov<mode>", "*vec_tf_to_v1tf")
2574 ("*vec_ti_to_v1ti"): Likewise.
2576 2018-11-20 Martin Sebor <msebor@redhat.com>
2578 * doc/extend.texi (Other Builtins): Add __builtin_has_attribute.
2580 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
2583 * ipa-devirt.c (odr_types_equivalent_p): Use operand_equal_p to
2584 compare ENUM values.
2586 2018-11-20 Jakub Jelinek <jakub@redhat.com>
2588 PR tree-optimization/87895
2589 * omp-simd-clone.c (ipa_simd_modify_function_body): When removing
2590 or replacing GIMPLE_RETURN, set EDGE_FALLTHRU on the edge to EXIT.
2591 (simd_clone_adjust): Don't set EDGE_FALLTHRU here. In a loop that
2592 redirects edges to EXIT to edges to incr_bb, iterate while EXIT
2593 has any preds and always use EDGE_PRED (, 0).
2595 2018-11-20 Uros Bizjak <ubizjak@gmail.com>
2598 * mode-switching.c (create_pre_exit): After reload, always split the
2599 fallthrough edge to the exit block.
2601 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
2603 * ipa-devirt.c (add_type_duplicate): Do not ICE on incomplete enums.
2604 * tree.c (build_array_type_1): Forward declare.
2605 (fld_type_variant_equal_p): Add INNER_TYPE parameter.
2606 (fld_type_variant): Likewise.
2607 (fld_simplified_types): New hash.
2608 (fld_process_array_type): New function.
2609 (fld_incomplete_type_of): Handle array and enumeration types.
2610 (fld_simplified_type): Handle simplification of arrays.
2611 (free_lang_data): Allocate and free simplified types hash.
2613 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
2616 * ipa-devirt.c (odr_subtypes_equivalent_p): Report ODR violation
2617 when sybtype already violates ODR.
2618 (get_odr_type): Do not ICE when insert is false and type duplicate
2619 is not registered yet.
2620 (register_odr_type): Be sure to register subtypes first.
2622 2018-11-20 Andreas Krebbel <krebbel@linux.ibm.com>
2624 * config/s390/s390.md ("clztidi2"): Swap the RTX's written to the
2625 DImode parts of the target operand.
2627 2018-11-20 Nathan Sidwell <nathan@acm.org>
2630 * Makefile.in (bitmap.o-warn): Use -Wno-error=array-bounds.
2632 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
2635 * tree.c (free_lang_data_in_cgraph): Add argument fld; break out
2637 (free_lang_data) ... here; update call of free_lang_data_in_cgraph.
2639 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
2642 * ipa-fnsummary.c (pass_ipa_fnsummary): Do not remove functions
2643 * ipa.c (possible_inline_candidate_p): Break out from ..
2644 (process_references): ... here ; drop before_inlining_p;
2645 cleanup handling of alises.
2646 (walk_polymorphic_call_targets): Likewise.
2647 (symbol_table::remove_unreachable_nodes): Likewise.
2648 * passes.c (pass_data_ipa_remove_symbols): New structure.
2649 (pass_ipa_remove_symbols): New pass.
2650 (make_pass_ipa_remove_symbols): New function.
2651 * tree-pass.h (make_pass_ipa_remove_symbols): Declare.
2652 * passes.def (pass_ipa_remove_symbols): Schedule after early passes.
2654 2018-11-20 Richard Biener <rguenther@suse.de>
2656 * tree-vect-stmts.c (vectorizable_condition): Do not get
2657 at else_clause vect def for EXTRACT_LAST_REDUCTION. Remove
2658 pointless vect_is_simple_use calls.
2660 2018-11-20 Richard Biener <rguenther@suse.de>
2662 PR tree-optimization/88074
2663 * tree-ssa-dom.c (pass_dominator::execute): Do not walk
2666 2018-11-20 Richard Biener <rguenther@suse.de>
2668 PR tree-optimization/88069
2669 * tree-ssa-sccvn.c (visit_phi): Do not value-number to unvisited
2670 virtual PHI arguments.
2672 2018-11-20 Ilya Leoshkevich <iii@linux.ibm.com>
2675 * config/s390/s390.md: Skip LT(G) peephole when literal pool is
2677 * rtl.h (contains_constant_pool_address_p): New function.
2678 * rtlanal.c (contains_constant_pool_address_p): Likewise.
2680 2018-11-20 Richard Biener <rguenther@suse.de>
2683 * alias.c (component_uses_parent_alias_set_from): Remove
2684 alias-set zero and TYPE_TYPELESS_STORAGE case both already
2685 handled in other ways.
2687 2018-11-20 Richard Biener <rguenther@suse.de>
2689 PR tree-optimization/88087
2690 * tree-ssa-pre.c (create_expression_by_pieces): Re-materialize
2692 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Remember
2695 2018-11-20 Richard Biener <rguenther@suse.de>
2698 * tree-data-ref.c (lambda_matrix_right_hermite): Use abs_hwi.
2700 2018-11-19 Jan Hubicka <hubicka@ucw.cz>
2703 * ipa-devirt.c (free_enum_values): Do not ICE on ODR vilations.
2705 2018-11-19 Sandra Loosemore <sandra@codesourcery.com>
2708 * doc/invoke.texi (Link Options): Mention shared libraries
2709 in documentation for the -l option. Simplify discussion and
2710 point to the system linker documentation for details.
2712 2018-11-19 Peter Bergner <bergner@linux.ibm.com>
2714 PR rtl-optimization/88033
2715 * ira-lives.c (non_conflicting_reg_copy_p): Skip copies from a register
2716 to itself. Use HARD_REGISTER_NUM_P.
2718 2018-11-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2720 * tree-vect-loop.c (vect_transform_loop): Disable further unrolling
2721 of the loop if vf is non-constant.
2723 2018-11-19 David Malcolm <dmalcolm@redhat.com>
2725 PR tree-optimization/87025
2726 * dumpfile.c (dump_context::begin_scope): Call end_any_optinfo
2727 immediately after creating the scope optinfo.
2728 (selftest::test_pr87025): New function.
2729 (selftest::dumpfile_c_tests): Call it.
2730 * optinfo-emit-json.cc (optrecord_json_writer::pop_scope): Assert
2731 that we're not popping the top-level records array.
2732 * optinfo.cc (optinfo::handle_dump_file_kind): Assert that we're
2733 not changing the kind of a "scope" optinfo.
2735 2018-11-19 David Malcolm <dmalcolm@redhat.com>
2737 PR tree-optimization/87025
2738 * dump-context.h: Include "optinfo.h".
2739 (class optrecord_json_writer): New forward decl.
2740 (dump_context::forcibly_enable_optinfo_p): Delete.
2741 (dump_context::optinfo_enabled_p): New member function.
2742 (dump_context::optimization_records_enabled_p): New member
2744 (dump_context::set_json_writer): New member function.
2745 (dump_context::emit_optinfo): New member function.
2746 (dump_context::m_forcibly_enable_optinfo): Delete.
2747 (dump_context::m_json_writer): New member data.
2748 * dumpfile.c (dump_context::set_json_writer): New member function.
2749 (dump_context::finish_any_json_writer): New member function.
2750 (dump_context::end_scope): Replace call to
2751 optimization_records_maybe_pop_dump_scope with call to
2752 m_json_writer->pop_scope.
2753 (dump_context::optinfo_enabled_p): New member function.
2754 (dump_context::end_any_optinfo): Replace call to optinfo::emit with call
2755 to dump_context::emit_optinfo.
2756 (dump_context::emit_optinfo): New member function.
2757 (temp_dump_context::temp_dump_context): Replace
2758 m_forcibly_enable_optinfo with call to set_json_writer.
2759 (temp_dump_context::~temp_dump_context): Clean up any json writer.
2760 * optinfo-emit-json.cc (class optrecord_json_writer): Move to
2762 (the_json_writer): Delete.
2763 (optimization_records_start): Delete.
2764 (optimization_records_finish): Delete.
2765 (optimization_records_enabled_p): Delete, in favor of
2766 dump_context::optimization_records_enabled_p.
2767 (optimization_records_maybe_record_optinfo): Delete.
2768 (optimization_records_maybe_pop_dump_scope): Delete.
2769 * optinfo-emit-json.h: Include "json.h". Delete forward
2771 (optimization_records_start): Delete.
2772 (optimization_records_finish): Delete.
2773 (optimization_records_enabled_p): Delete.
2774 (optimization_records_maybe_record_optinfo): Delete.
2775 (optimization_records_maybe_pop_dump_scope): Delete.
2776 (class optrecord_json_writer): Move here from
2777 optinfo-emit-json.cc.
2778 * optinfo.cc (optinfo::emit_for_opt_problem): Replace call
2779 to optinfo::emit with call to dump_context::emit_optinfo.
2780 (optinfo::emit): Delete, in favor of dump_context::emit_optinfo.
2781 (optinfo_enabled_p): Delete, in favor of
2782 dump_context::optinfo_enabled_p.
2783 (optinfo_wants_inlining_info_p): Update for conversion o
2784 optimization_records_enabled_p to a member function of
2786 * optinfo.h (optinfo_enabled_p): Delete, in favor of
2787 dump_context::optinfo_enabled_p.
2788 (optinfo::emit): Delete, in favor of dump_context::emit_optinfo.
2789 * toplev.c: Include "dump-context.h".
2790 (compile_file): Replace call to optimization_records_finish with
2791 dump_context::finish_any_json_writer.
2792 (do_compile): Replace call to optimization_records_start with
2793 conditionally creating a optrecord_json_writer for the
2796 2018-11-19 Jakub Jelinek <jakub@redhat.com>
2798 PR tree-optimization/88071
2799 * tree-vect-loop.c (vectorize_fold_left_reduction): Pass true instead
2800 of false as last argument to gsi_remove.
2801 * tree-vect-stmts.c (vect_finish_replace_stmt): Pass true instead of
2802 false as last argument to gsi_replace.
2805 * omp-expand.c: Don't include debug.h.
2806 (adjust_context_and_scope): Add REGION argument. Find DECL_CONTEXT
2807 from innermost outer parallel, task, teams or target that has a
2808 child_fn set, or, if there is no such outer region, use
2809 current_function_decl. Do the DECL_CONTEXT adjustment regardless of
2810 whether a suitable BLOCK is found or not.
2811 (expand_parallel_call, expand_teams_call): Don't call
2812 adjust_context_and_scope here.
2813 (grid_expand_target_grid_body): Revert 2017-01-25 changes.
2814 (expand_omp_taskreg, expand_omp_target): Likewise. Call
2815 adjust_context_and_scope.
2816 * dwarf2out.c (dwarf2out_early_global_decl): For
2817 decl_function_context recurse instead of calling dwarf2out_decl.
2819 2018-11-20 Eric Botcazou <ebotcazou@adacore.com>
2821 PR rtl-optimization/85925
2822 * rtl.h (word_register_operation_p): New predicate.
2823 * combine.c (record_dead_and_set_regs_1): Only apply specific handling
2824 for WORD_REGISTER_OPERATIONS targets to word_register_operation_p RTX.
2825 * rtlanal.c (nonzero_bits1): Likewise. Adjust couple of comments.
2826 (num_sign_bit_copies1): Likewise.
2828 2018-11-19 Richard Biener <rguenther@suse.de>
2831 * tree.c (free_lang_data_in_one_sizepos): Free non-gimple-val
2834 2018-11-19 Eric Botcazou <ebotcazou@adacore.com>
2836 * compare-elim.c (struct comparison): Add not_in_a field.
2837 (is_not): New static function.
2838 (strip_not): Likewise.
2839 (conforming_compare): Handle a NOT in the first operand.
2840 (can_eliminate_compare): Likewise.
2841 (find_comparison_dom_walker::before_dom_children): Likewise.
2842 (try_eliminate_compare): Likewise.
2843 * config/visium/visium.md (negsi2_insn_set_carry): Turn into...
2844 (neg<mode>2_insn_set_carry): ...this and add missing NEG operation.
2846 2018-11-19 Jonathan Wakely <jwakely@redhat.com>
2848 * doc/extend.texi (Common Type Attributes): Fix typos.
2850 2018-11-19 Martin Liska <mliska@suse.cz>
2852 PR gcov-profile/88045
2853 * coverage.c (coverage_begin_function): Add assert.
2855 2018-11-18 Sandra Loosemore <sandra@codesourcery.com>
2858 * doc/extend.texi (Common Function Attributes): Document that
2859 no_instrument_function applies to -p and -pg, too.
2860 * doc/invoke.texi (Instrumentation Options): Add cross-references
2861 to docs for -p, -pg, and -finstrument-functions.
2863 2018-11-18 Alan Modra <amodra@gmail.com>
2865 * config/gnu-user.h (GNU_USER_TARGET_CRTI): Define.
2866 (GNU_USER_TARGET_STARTFILE_SPEC): Use it here.
2867 (GNU_USER_TARGET_CRTN): Define.
2868 (GNU_USER_TARGET_ENDFILE_SPEC): Use it here.
2869 (GNU_USER_TARGET_LINK_GCC_C_SEQUENCE_SPEC): Define.
2871 2018-11-18 Alan Modra <amodra@gmail.com>
2873 * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Delete
2874 !HAVE_LD_PIE variant.
2875 (GNU_USER_TARGET_ENDFILE_SPEC): Likewise.
2877 2018-11-17 Nick Clifton <nickc@redhat.com>
2878 Sandra Loosemore <sandra@codesourcery.com>
2881 * doc/invoke.texi (Overall Options): Document that --help and
2882 --help=<value> options cannot be combined.
2884 2018-11-17 Jim Wilson <jimw@sifive.com>
2886 * config/riscv/riscv.c (epilogue_cfa_sp_offset): New.
2887 (riscv_restore_reg): If restoring HARD_FRAME_POINTER_REGNUM, and
2888 epilogue_cfa_sp_offset set, then add REG_CFA_DEF_CFA regnote.
2889 (riscv_expand_epilogue): Initialize epilogue_cfa_sp_offset. Set it
2890 to step2 if frame_pointer_needed and step1 is 0.
2892 2018-11-17 Sandra Loosemore <sandra@codesourcery.com>
2895 * doc/cpp.texi (System Headers): Add note about implicit
2896 extern "C" block on targets that define SYSTEM_IMPLICIT_EXTERN_C.
2898 2018-11-17 Sandra Loosemore <sandra@codesourcery.com>
2901 * doc/invoke.texi (C++ Dialect Options): Clarify usage of
2902 -fno-implicit-templates.
2904 2018-11-17 Jakub Jelinek <jakub@redhat.com>
2906 PR tree-optimization/87546
2907 * tree-vect-patterns.c (vect_look_through_possible_promotion): Add
2908 min_precision variable, initially set it to orig_precision, only does
2909 something if op_type's precision is <= min_precision and update
2910 min_precision whenever calling set_op.
2912 2018-11-16 Jan Hubicka <hubicka@ucw.cz>
2915 * ipa-devirt.c (warn_odr): Look for main variant to get TYPE_DECL.
2917 2018-11-16 Sandra Loosemore <sandra@codesourcery.com>
2919 * doc/invoke.texi (Option Summary): Fix whitespace and line
2920 breaks in @gccoptlist environments.
2921 (Warning Options): Likewise.
2922 (Optimize Options): Likewise.
2923 (PowerPC SPE Options): Likewise.
2924 (RS/6000 and PowerPC Options): Likewise.
2926 2018-11-16 Jeff Law <law@redhat.com>
2928 * config/mn10300/mn10300.md (adddi3_degenerate): Remove bogus
2931 2018-11-16 Sandra Loosemore <sandra@codesourcery.com>
2934 * doc/invoke.texi (Optimize Options): Update options enabled by
2935 fprofile-generate, -fprofile-use, and -fauto-profile.
2937 2018-11-16 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2940 * target-def.h: Initialize TARGET_ASM_{,UN}ALIGNED_P{S,D,T}I_OP.
2941 Add them to the TARGET_ASM_{,UN}ALIGNED_INT_OP structs.
2942 * target.def: Enumerate TARGET_ASM_{,UN}ALIGNED_P{S,D,T}I_OP in
2944 * target.h: Add psi, pdi, pti to struct asm_int_op definition.
2945 * targhooks.c (default_print_patchable_function_entry): Assert
2946 asm_int_op does not return a NULL string.
2947 * varasm.c (integer_asm_op): Return the op for a partial int type
2948 when the requested size does not correspond to an integer type.
2949 * config/msp430/msp430.c: Initialize TARGET_ASM_{,UN}ALIGNED_PSI_OP.
2950 * doc/tm.texi: Regenerate.
2952 2018-11-12 Jason Merrill <jason@redhat.com>
2954 * gimplify.c (gimplify_case_label_expr): Handle hot/cold attributes.
2956 2018-11-16 Michael Meissner <meissner@linux.ibm.com>
2958 * config/rs6000/constraints.md (wF constraint): Remove power9
2959 fusion documentation. Just document wF's use for power8 fusion.
2960 * config/rs6000/predicates.md (p9_fusion_reg_operand): Delete.
2961 (fusion_gpr_addis): Delete power9 fusion support. Change power8
2962 fusion support to require the upper 12 bits to be all 0's or all
2964 (fusion_gpr_mem_load): Add comment.
2965 (fusion_addis_mem_combo_load): Remove power9 fusion support.
2966 (fusion_addis_mem_combo_store): Delete.
2967 (fusion_offsettable_mem_operand): Delete.
2968 * config/rs6000/rs6000-cpus.def (ISA_2_7_MASKS_SERVER): Do not set
2970 (ISA_3_0_MASKS_SERVER): Delete power9 fusion.
2971 (POWERPC_MASKS): Delete power9 fusion.
2972 * config/rs6000/rs6000-protos.h (emit_fusion_load_store): Delete.
2973 (fusion_p9_p): Delete.
2974 (expand_fusion_p9_load): Delete.
2975 (expand_fusion_p9_store): Delete.
2976 (emit_fusion_p9_load): Delete.
2977 (emit_fusion_p9_store): Delete.
2978 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Delete power9
2980 (rs6000_option_override_internal): Set power8 fusion based on
2981 whether we are tuning for power8. Delete power9 fusion support.
2982 (rs6000_opt_masks): Delete -mpower9-fusion switch.
2983 (emit_fusion_load): Rename emit_fusion_load_store to
2984 emit_fusion_load, and drop fusion store support. Update callers.
2985 (emit_fusion_load_store): Likewise.
2986 (emit_fusion_gpr_load): Likewise.
2987 (fusion_p9_p): Delete.
2988 (expand_fusion_p9_load): Delete.
2989 (expand_fusion_p9_store): Delete.
2990 (emit_fusion_p9_load): Delete.
2991 (emit_fusion_p9_store): Delete.
2992 * config/rs6000/rs6000.md (UNSPEC_FUSION_P9): Delete.
2993 (GPR_FUSION): Delete.
2994 (FPR_FUSION): Delete.
2995 (power9 fusion peephole2s): Delete.
2996 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Delete.
2997 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Delete.
2998 (fusion_vsx_<P:mode>_<FPR_FUSION:mode>_load): Delete.
2999 (fusion_vsx_<P:mode>_<FPR_FUSION:mode>_store): Delete.
3000 (fusion_p9_<mode>_constant): Delete.
3001 * config/rs6000/rs6000.opt (-mpower9-fusion): Delete undocumented
3002 power9 fusion switch.
3003 * doc/md.texi (PowerPC constraints): Update wF constraint
3004 documentation for power8 fusion only.
3006 2018-11-16 Jakub Jelinek <jakub@redhat.com>
3008 PR rtl-optimization/87475
3009 * cfgrtl.c (patch_jump_insn): Allow redirection failure for
3010 CROSSING_JUMP_P insns.
3011 (cfg_layout_redirect_edge_and_branch): Don't ICE if ret is NULL.
3013 2018-11-16 Uros Bizjak <ubizjak@gmail.com>
3016 * config/i386/i386.md (floatunsdidf2): Allow only 64bit AVX512F targets.
3017 * config/i386/sse.md (UNSPEC_MOVDI_TO_SSE): New UNSPEC.
3018 (movdi_to_sse): Rewrite using UNSPEC_MOVDI_TO_SSE unspec.
3020 2018-11-16 Jakub Jelinek <jakub@redhat.com>
3023 * optabs.c (expand_binop): For op0_mode use GET_MODE (op0), unless it
3024 is VOIDmode, in which case use int_mode. Similarly for op1_mode.
3026 2018-11-16 Eric Botcazou <ebotcazou@adacore.com>
3028 * tree-switch-conversion.h (switch_decision_tree::emit_case_nodes): Add
3029 location_t parameter.
3030 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
3031 (switch_decision_tree::do_jump_if_equal): Likewise.
3032 * tree-switch-conversion.c (switch_decision_tree::emit): Pass location
3033 of switch statement to emit_case_nodes.
3034 (switch_decision_tree::emit_cmp_and_jump_insns): Add LOC parameter and
3035 set it on the newly built GIMPLE comparison statement.
3036 (switch_decision_tree::do_jump_if_equal): Likewise.
3037 (switch_decision_tree::emit_case_nodes): Add LOC parameter and pass it
3038 in calls to do_jump_if_equal as well as recursive calls.
3040 2018-11-16 Andi Kleen <ak@linux.intel.com>
3042 * config/i386/i386.md: Allow memory operands to ptwrite.
3044 2018-11-16 Michael Matz <matz@suse.de>
3046 * system.h (PRsa): New macro.
3047 (SIZE_AMOUNT): Cast number to uint64_t.
3048 * alloc-pool.h (pool_usage::dump): Don't use %zu but PRsa.
3049 (pool_usage::dump_footer): Likewise and also use PRIu64.
3050 * bitmap.h (bitmap_usage::dump): Likewise.
3051 * ggc-common.c (ggc_usage::dump): Likewise.
3052 * ggc-page.c (ggc_print_statistics): Likewise.
3053 * input.c (dump_line_table_statistics): Likewise.
3054 * mem-stats.h (mem_usage::dump): Likewise.
3055 (mem_usage::dump_footer): Likewise.
3056 * rtl.c (dump_rtx_statistics): Likewise.
3057 * tree-cfg.c (dump_cfg_stats): Likewise.
3058 * tree-dfa.c (dump_dfa_stats): Likewise.
3059 * tree-phinodes.c (phinodes_print_statistics): Likewise.
3060 * tree-ssanames (ssanames_print_statistics): Likewise.
3061 * vec.c (vec_usage::dump): Likewise.
3062 (vec_usage::dump_footer): Likewise.
3064 2018-11-16 Richard Biener <rguenther@suse.de>
3066 PR tree-optimization/88011
3067 * tree-vrp.c (extract_range_from_binary_expr): Fix error in
3068 replacing set_value_range_to_undefined and
3069 set_value_range_to_varying with method calls.
3071 2018-11-16 Ilya Leoshkevich <iii@linux.ibm.com>
3073 * config/s390/s390.md
3074 (*r<noxa>sbg_<mode>_srl_bitmask): Do not delegate arithmetic to
3076 (*r<noxa>sbg_<mode>_sll): Likewise.
3077 (*r<noxa>sbg_<mode>_srl): Likewise.
3078 (*r<noxa>sbg_sidi_srl): New pattern.
3080 2018-11-16 Jerome Lambourg <lambourg@adacore.com>
3082 * config/vxworks.h (TARGET_VXWORKS_HAVE_CTORS_DTORS): New macro.
3083 Default to TARGET_VXWORKS_RTP.
3084 (SUPPORTS_INIT_PRIORITY): Use TARGET_VXWORKS_HAVE_CTORS_DTORS instead
3085 of TARGET_VXWORKS_RTP.
3086 * config/vxworks.c: Use TARGET_VXWORKS_HAVE_CTORS_DTORS instead
3087 of TARGET_VXWORKS_RTP to set targetm.have_ctors_dtors.
3089 2018-11-15 Sandra Loosemore <sandra@codesourcery.com>
3092 * doc/extend.texi (Common Type Attributes): Make it explicit
3093 that attribute "packed" can apply to C++ classes.
3095 2018-11-15 Martin Sebor <msebor@redhat.com>
3099 * tree.c (type_argument_type): New function.
3100 * tree.h (type_argument_type): Declare it.
3101 * gcc/doc/extend.texi (alloc_align): Update and clarify.
3102 (alloc_size, nonnull, sentinel): Same.
3104 2018-11-15 Andrew Stubbs <ams@codesourcery.com>
3105 Kwok Cheung Yeung <kcy@codesourcery.com>
3107 * tree-vect-stmts.c (vectorizable_store): Don't ICE when
3108 int_mode_for_size fails.
3109 (vectorizable_load): Likewise.
3111 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3113 * doc/ux.texi (Group logically-related diagnostics): Move
3114 discussion of auto_diagnostic_group into this new subsection.
3115 Give an example of where this grouping is used.
3117 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3120 * Makefile.in (OBJS): Move json.o to...
3121 (OBJS-libcommon): ...here and add diagnostic-format-json.o.
3122 * common.opt (fdiagnostics-format=): New option.
3123 (diagnostics_output_format): New enum.
3124 * diagnostic-format-json.cc: New file.
3125 * diagnostic.c (default_diagnostic_final_cb): New function, taken
3126 from start of diagnostic_finish.
3127 (diagnostic_initialize): Initialize final_cb to
3128 default_diagnostic_final_cb.
3129 (diagnostic_finish): Move "being treated as errors" messages to
3130 default_diagnostic_final_cb. Call any final_cb.
3131 (default_diagnostic_finalizer): Add diagnostic_t param.
3132 (diagnostic_report_diagnostic): Pass "orig_diag_kind" to
3133 diagnostic_finalizer callback.
3134 * diagnostic.h (enum diagnostics_output_format): New enum.
3135 (diagnostic_finalizer_fn): Reimplement, adding diagnostic_t param.
3136 (struct diagnostic_context): Add "final_cb".
3137 (default_diagnostic_finalizer): Add diagnostic_t param.
3138 (diagnostic_output_format_init): New decl.
3139 * doc/invoke.texi (-fdiagnostics-format): New option.
3140 * dwarf2out.c (gen_producer_string): Ignore
3141 OPT_fdiagnostics_format_.
3142 * gcc.c (driver_handle_option): Handle OPT_fdiagnostics_format_.
3143 * lto-wrapper.c (append_diag_options): Ignore it.
3144 * opts.c (common_handle_option): Handle it.
3146 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3148 PR tree-optimization/88015
3149 * graphite-isl-ast-to-gimple.c
3150 (translate_isl_ast_to_gimple::scop_to_isl_ast): Add missing check
3152 * graphite-sese-to-poly.c (build_poly_scop): Likewise.
3154 2018-11-15 Richard Biener <rguenther@suse.de>
3157 * gimple.c (gimple_call_flags): Union flags from decl, type
3159 * trans-mem.c (is_tm_pure_call): Simplify.
3161 2018-11-15 Richard Biener <rguenther@suse.de>
3163 PR tree-optimization/88031
3164 * tree-vect-loop.c (vectorizable_reduction): Move check
3165 for multiple types earlier so we get the expected dump.
3166 Simplify calls to vectorizable_condition.
3167 * tree-vect-stmts.h (vectorizable_condition): Update prototype.
3168 * tree-vect-stmts.c (vectorizable_condition): Instead of
3169 reduc_def and reduc_index take just a flag. Simplify
3170 code-generation now that we can rely on the defs being set up.
3171 (vectorizable_comparison): Remove unused argument.
3173 2018-11-15 Richard Biener <rguenther@suse.de>
3175 PR tree-optimization/88030
3176 * tree-complex.c (need_eh_cleanup): New global.
3177 (update_complex_assignment): Mark blocks that need EH update.
3178 (expand_complex_comparison): Likewise.
3179 (tree_lower_complex): Allocate and deallocate need_eh_cleanup,
3180 perform EH cleanup and schedule CFG cleanup if that did anything.
3182 2018-11-15 Jakub Jelinek <jakub@redhat.com>
3184 PR rtl-optimization/88018
3185 * cfgrtl.c (fixup_abnormal_edges): Guard moving insns to fallthru edge
3186 on the presence of fallthru edge, rather than if it is a USE or not.
3188 2018-11-15 Richard Biener <rguenther@suse.de>
3191 * tree-data-ref.c (analyze_miv_subscript): Guard calls to
3192 analyze_subscript_affine_affine properly.
3194 2018-11-15 Xianmiao Qu <xianmiao_qu@c-sky.com>
3196 * config/csky/csky-linux-elf.h (LINUX_DYNAMIC_LINKER): Remove.
3197 (GLIBC_DYNAMIC_LINKER): Define.
3198 (LINUX_TARGET_LINK_SPEC): Update the dynamic linker's name.
3200 2018-11-15 Bin Cheng <bin.cheng@linux.alibaba.com>
3202 PR tree-optimization/84648
3203 * tree-ssa-loop-niter.c (adjust_cond_for_loop_until_wrap): New.
3204 (number_of_iterations_cond): Adjust exit cond for loop-until-wrap case
3205 by calling adjust_cond_for_loop_until_wrap.
3207 2018-11-15 Sandra Loosemore <sandra@codesourcery.com>
3210 * doc/extend.texi (Common Function Attributes): Clarify linker
3211 restrictions on "aligned" attribute.
3212 (Common Variable Attributes): Likewise. Mention that linker
3213 restrictions don't apply to stack-allocated variables.
3215 2018-11-15 Joern Rennecke <joern.rennecke@riscy-ip.com>
3217 * gensupport.c (add_predicate_code): Properly handle ZERO_EXTRACT
3220 2018-11-14 Sandra Loosemore <sandra@codesourcery.com>
3224 * doc/invoke.texi (Optimize Options): Remove bad example about
3225 interaction between -flto and -O. Replace it with a note that
3226 you need to compile with -O and not just link. Copy-edit -flto
3227 discussion to reduce verbiage and improve flow.
3229 2018-11-14 Sandra Loosemore <sandra@codesourcery.com>
3232 * doc/invoke.texi (Optimize Options): Clarify that -O0 and -Og
3233 also suppress many optimizations. Alphabetize option lists for
3234 -O1, -O2, and -Os. Add list of options disabled with -Og, and
3235 correct documentation for those options to say that.
3236 * opts.c (default_options_table): Sort table by level and option
3237 name, to make it easier to correlate to the manual.
3239 2018-11-14 Uros Bizjak <ubizjak@gmail.com>
3241 * config/i386/i386.c (ix86_print_operand_address_as): Simplify
3242 printing of the names of segment registers.
3244 2018-11-14 Nathan Sidwell <nathan@acm.org>
3248 * dwarf2out.c (dwarf2out_finish): Apply resolve_addr to comdat
3251 2018-11-14 David Malcolm <dmalcolm@redhat.com>
3253 * Makefile.in (CFLAGS-optinfo-emit-json.o): Add $(ZLIBINC).
3255 2018-11-14 Jakub Jelinek <jakub@redhat.com>
3257 P1236R1 - Signed integers are two's complement
3258 * doc/invoke.texi (Wshift-overflow): Adjust documentation for c++2a.
3261 * hash-map.h (hash_map::iterator::reference_pair): New class.
3262 (hash_map::iterator::operator*): Return it rather than std::pair.
3264 2018-11-14 Jeff Law <law@redhat.com>
3266 * optabs.c (expand_binop): Pass INT_MODE to operand_subword_force
3267 iff the operand is a constant.
3269 2018-11-14 Aldy Hernandez <aldyh@redhat.com>
3271 * gimple-ssa-evrp-analyze.c
3272 (evrp_range_analyzer::record_ranges_from_incoming_edge): Rename
3273 ignore_equivs_equal_p to equal_p.
3274 * ipa-cp.c (meet_with_1): Use equal_p instead of
3275 ignore_equivs_equal_p.
3276 * ipa-prop.c (ipa_vr_ggc_hash_traits::equal): Same.
3277 * tree-vrp.c (value_range::ignore_equivs_equal_p): Remove.
3278 (value_range::operator==): Remove.
3279 (value_range::operator!=): Remove.
3280 (vrp_prop::visit_stmt): Use equal_p.
3281 * tree-vrp.h (value_range): Remove operator==, operator!=,
3282 ignore_equivs_equal_p.
3283 * vr-values.c (update_value_range): Use equal_p.
3285 2018-11-14 Michael Matz <matz@suse.de>
3288 * gimplify.c (collect_fallthrough_labels): Add new argument,
3289 return location via that, don't modify statements.
3290 (warn_implicit_fallthrough_r): Adjust call, don't use
3291 statement location directly.
3293 2018-11-14 Richard Biener <rguenther@suse.de>
3296 * tree-data-ref.c (split_constant_offset): Add wrapper
3297 allocating a cache hash-map.
3298 (split_constant_offset_1): Cache results of expanding
3299 expressions from SSA def stmts.
3301 2018-11-14 Richard Biener <rguenther@suse.de>
3304 * tree-data-ref.c (lambda_matrix_row_add): Change const1 argument
3306 (lambda_vector_mult_const): Likewise.
3307 (lambda_matrix_right_hermite): Use lambda_int temporaries.
3309 2018-11-14 Wilco Dijkstra <wdijkstr@arm.com>
3310 Jackson Woodruff <jackson.woodruff@arm.com>
3312 PR 71026/tree-optimization
3313 * match.pd: Simplify floating point comparisons.
3315 2018-11-14 Jakub Jelinek <jakub@redhat.com>
3317 PR rtl-optimization/87817
3318 * config/i386/i386.c (ix86_fold_builtin): For _bzhi_u{32,64} if
3319 last argument has low 8 bits clear, fold to 0.
3321 2018-11-14 Iain Sandoe <iain@sandoe.co.uk>
3323 * tree-vect-data-refs.c (vect_can_force_dr_alignment_p): Cast
3324 MAX_OFILE_ALIGNMENT as needed.
3326 2018-11-14 Richard Biener <rguenther@suse.de>
3328 PR tree-optimization/88019
3329 * graphite-isl-ast-to-gimple.c (ternary_op_to_tree): Rewrite
3330 COND_EXPR arguments to non-trapping overflow.
3332 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
3334 * config/arc/arc.h (reg_class): Reorder registers classes, remove
3335 unused register classes.
3336 (REG_CLASS_NAMES): Likewise.
3337 (REG_CLASS_CONTENTS): Likewise.
3338 (FIXED_REGISTERS): Make lp_count fixed.
3339 (BASE_REG_CLASS): Remove ACC16_BASE_REGS reference.
3340 (PROGRAM_COUNTER_REGNO): Remove.
3341 * config/arc/arc.c (arc_conditional_register_usage): Remove unused
3342 register classes, use constants for register numbers, remove
3343 reg_class_contents references.
3344 (arc_process_double_reg_moves): Add asserts.
3345 (arc_secondary_reload): Remove LPCOUNT_REG reference, use
3346 lra_in_progress predicate.
3347 (arc_init_reg_tables): Remove unused register classes.
3348 (arc_register_move_cost): Likewise.
3349 (arc_preferred_reload_class): Likewise.
3350 (hwloop_optimize): Update rtx patterns involving lp_count register.
3351 (arc_return_address_register): Rename ILINK1, INLINK2 regnums macros.
3352 * config/arc/constraints.md ("c"): Choose between GENERAL_REGS and
3353 CHEAP_CORE_REGS. Former one will be used for LRA.
3354 ("Rac"): Choose between GENERAL_REGS and ALL_CORE_REGS. Former
3355 one will be used for LRA.
3356 ("w"): Choose between GENERAL_REGS and WRITABLE_CORE_REGS. Former
3357 one will be used for LRA.
3358 ("W"): Choose between GENERAL_REGS and MPY_WRITABLE_CORE_REGS.
3359 Former one will be used for LRA.
3360 ("f"): Delete constraint.
3363 ("l"): Change it from register constraint to constraint.
3364 * config/arc/arc.md (movqi_insn): Remove unsed lp_count constraints.
3365 (movhi_insn): Likewise.
3366 (movsi_insn): Update pattern.
3369 (stack_tie): Remove 'b' constraint letter.
3371 (R9_REG, R15_REG, R16_REG, R25_REG): Likewise.
3372 (R32_REG, R40_REG, R41_REG, R42_REG, R43_REG, R44_REG): Likewise.
3373 (R57_REG, R59_REG, PCL_REG): Likewise.
3374 (ILINK1_REGNUM): Renamed to ILINK1_REG.
3375 (ILINK2_REGNUM): Renamed to ILINK2_REG.
3377 (SP_REGS): Likewise.
3378 (Rcw): Remove unused reg classes.
3379 * config/arc/predicates.md (dest_reg_operand): Just default on
3380 register_operand predicate.
3381 (mpy_dest_reg_operand): Likewise.
3382 (move_dest_operand): Use macros instead of constants.
3383 * config/arc/arc.opt (mlra): Switch to lra as default.
3385 2018-11-14 Richard Biener <rguenther@suse.de>
3387 PR tree-optimization/87974
3388 * tree-vect-loop.c (vectorizable_reduction): When computing
3389 the vectorized reduction PHI vector type ignore constant
3392 2018-11-14 Jakub Jelinek <jakub@redhat.com>
3394 PR tree-optimization/87977
3395 * tree-ssa-math-opts.c (optimize_recip_sqrt): Don't reuse division
3396 stmt, build a new one and replace the old one with it. Formatting fix.
3397 Call release_ssa_name (x) if !has_other_use and !delete_div.
3398 (pass_cse_reciprocals::execute): Before calling optimize_recip_sqrt
3399 verify lhs of stmt is still def.
3401 2018-11-13 Peter Bergner <bergner@linux.ibm.com>
3403 PR rtl-optimization/87507
3404 * lower-subreg.c (operand_for_swap_move_operator): New function.
3405 (simple_move): Strip simple operators.
3406 (find_pseudo_copy): Likewise.
3407 (resolve_operand_for_swap_move_operator): New function.
3408 (resolve_simple_move): Strip simple operators and swap operands.
3410 2018-11-13 Jakub Jelinek <jakub@redhat.com>
3412 PR tree-optimization/87898
3413 * omp-simd-clone.c (ipa_simd_modify_stmt_ops): Formatting fix.
3414 (ipa_simd_modify_function_body): Remove debug stmts where the first
3415 argument was changed into a non-decl.
3417 2018-11-13 Peter Bergner <bergner@linux.ibm.com>
3419 PR rtl-optimization/87899
3420 * lra-lives.c (start_living): Update white space in comment.
3421 (enum point_type): New.
3422 (sparseset_contains_pseudos_p): New function.
3423 (update_pseudo_point): Likewise.
3424 (make_hard_regno_live): Use HARD_REGISTER_NUM_P macro.
3425 (make_hard_regno_dead): Likewise. Remove ignore_reg_for_conflicts
3426 handling. Move early exit after adding conflicts.
3427 (mark_pseudo_live): Use HARD_REGISTER_NUM_P macro. Add early exit
3428 if regno is already live. Remove all handling of program points.
3429 (mark_pseudo_dead): Use HARD_REGISTER_NUM_P macro. Add early exit
3430 after adding conflicts. Remove all handling of program points and
3431 ignore_reg_for_conflicts.
3432 (mark_regno_live): Use HARD_REGISTER_NUM_P macro. Remove return value
3433 and do not guard call to mark_pseudo_live.
3434 (mark_regno_dead): Use HARD_REGISTER_NUM_P macro. Remove return value
3435 and do not guard call to mark_pseudo_dead.
3436 (check_pseudos_live_through_calls): Use HARD_REGISTER_NUM_P macro.
3437 (process_bb_lives): Use HARD_REGISTER_NUM_P and HARD_REGISTER_P macros.
3438 Use new function update_pseudo_point. Handle register copies by
3439 removing the source register from the live set. Handle INOUT operands.
3440 Update to the next program point using the unused_set, dead_set and
3442 (lra_create_live_ranges_1): Use HARD_REGISTER_NUM_P macro.
3444 2018-11-13 David Malcolm <dmalcolm@redhat.com>
3446 * builtins.c: Replace "source_location" with "location_t".
3447 * diagnostic-show-locus.c: Likewise.
3448 * diagnostic.c: Likewise.
3449 * dumpfile.c: Likewise.
3450 * gcc-rich-location.h: Likewise.
3451 * genmatch.c: Likewise.
3452 * gimple.h: Likewise.
3453 * gimplify.c: Likewise.
3454 * input.c: Likewise.
3455 * input.h: Likewise. Eliminate the typedef.
3456 * omp-expand.c: Likewise.
3457 * selftest.h: Likewise.
3458 * substring-locations.h (get_source_location_for_substring):
3460 (get_location_within_string): ...this.
3461 * tree-cfg.c: Replace "source_location" with "location_t".
3462 * tree-cfgcleanup.c: Likewise.
3463 * tree-diagnostic.c: Likewise.
3464 * tree-into-ssa.c: Likewise.
3465 * tree-outof-ssa.c: Likewise.
3466 * tree-parloops.c: Likewise.
3467 * tree-phinodes.c: Likewise.
3468 * tree-phinodes.h: Likewise.
3469 * tree-ssa-loop-ivopts.c: Likewise.
3470 * tree-ssa-loop-manip.c: Likewise.
3471 * tree-ssa-phiopt.c: Likewise.
3472 * tree-ssa-phiprop.c: Likewise.
3473 * tree-ssa-threadupdate.c: Likewise.
3474 * tree-ssa.c: Likewise.
3475 * tree-ssa.h: Likewise.
3476 * tree-vect-loop-manip.c: Likewise.
3478 2018-11-13 Michael Ploujnikov <michael.ploujnikov@oracle.com>
3480 * doc/extend.texi: Fix typo in the weakref description.
3482 2018-11-13 Richard Biener <rguenther@suse.de>
3484 PR tree-optimization/86991
3485 * tree-vect-loop.c (vect_is_slp_reduction): Delay reduction
3486 group building until we have successfully detected the SLP
3488 (vect_is_simple_reduction): Remove fixup code here.
3490 2018-11-13 David Malcolm <dmalcolm@redhat.com>
3492 * dumpfile.c (VERIFY_DUMP_ENABLED_P): New macro.
3493 (dump_gimple_stmt): Use it.
3494 (dump_gimple_stmt_loc): Likewise.
3495 (dump_gimple_expr): Likewise.
3496 (dump_gimple_expr_loc): Likewise.
3497 (dump_generic_expr): Likewise.
3498 (dump_generic_expr_loc): Likewise.
3499 (dump_printf): Likewise.
3500 (dump_printf_loc): Likewise.
3501 (dump_dec): Likewise.
3502 (dump_dec): Likewise.
3503 (dump_hex): Likewise.
3504 (dump_symtab_node): Likewise.
3505 * gimple-loop-interchange.cc (tree_loop_interchange::interchange):
3506 Guard dump call with dump_enabled_p.
3507 * graphite-isl-ast-to-gimple.c (graphite_regenerate_ast_isl): Likewise.
3508 * graphite-optimize-isl.c (optimize_isl): Likewise.
3509 * graphite.c (graphite_transform_loops): Likewise.
3510 * tree-loop-distribution.c (pass_loop_distribution::execute): Likewise.
3511 * tree-parloops.c (parallelize_loops): Likewise.
3512 * tree-ssa-loop-niter.c (number_of_iterations_exit): Likewise.
3513 * tree-vect-data-refs.c (vect_analyze_group_access_1): Likewise.
3514 (vect_prune_runtime_alias_test_list): Likewise.
3515 * tree-vect-loop.c (vect_update_vf_for_slp): Likewise.
3516 (vect_estimate_min_profitable_iters): Likewise.
3517 * tree-vect-slp.c (vect_record_max_nunits): Likewise.
3518 (vect_build_slp_tree_2): Likewise.
3519 (vect_supported_load_permutation_p): Likewise.
3520 (vect_slp_analyze_operations): Likewise.
3521 (vect_slp_analyze_bb_1): Likewise.
3522 (vect_slp_bb): Likewise.
3523 * tree-vect-stmts.c (vect_analyze_stmt): Likewise.
3524 * tree-vectorizer.c (try_vectorize_loop_1): Likewise.
3525 (pass_slp_vectorize::execute): Likewise.
3526 (increase_alignment): Likewise.
3528 2018-11-13 David Malcolm <dmalcolm@redhat.com>
3531 * ipa-inline.c (report_inline_failed_reason): Guard calls to
3532 cl_target_option_print_diff and cl_optimization_print_diff with
3535 2018-11-13 David Malcolm <dmalcolm@redhat.com>
3537 * doc/invoke.texi (-fsave-optimization-record): Note that the
3538 output is compressed.
3539 * optinfo-emit-json.cc: Include <zlib.h>.
3540 (optrecord_json_writer::write): Compress the output.
3542 2018-11-13 Aldy Hernandez <aldyh@redhat.com>
3544 * tree-vrp.c (value_range_base::dump): Dump type.
3545 Do not use INF nomenclature for 1-bit types.
3546 (dump_value_range): Group all variants to common dumping code.
3547 (debug): New overloaded functions for value_ranges.
3548 (value_range_base::dump): Remove no argument version.
3549 (value_range::dump): Same.
3551 2018-11-13 Richard Biener <rguenther@suse.de>
3553 PR tree-optimization/87931
3554 * tree-vect-loop.c (vect_is_simple_reduction): Restrict
3555 nested cycles we support to latch computations vectorizable_reduction
3558 2018-11-13 Martin Liska <mliska@suse.cz>
3560 PR tree-optimization/87885
3561 * cfghooks.c (account_profile_record): Rename
3563 (profile_record_check_consistency): ... this.
3564 Calculate missing num_mismatched_freq_in.
3565 (profile_record_account_profile): New function
3566 that calculates time and size of a function.
3567 * cfghooks.h (struct profile_record): Remove
3569 (struct cfg_hooks): Remove after_pass flag.
3570 (account_profile_record): Rename to ...
3571 (profile_record_check_consistency): ... this.
3572 (profile_record_account_profile): New.
3573 * cfgrtl.c (rtl_account_profile_record): Remove
3575 * passes.c (check_profile_consistency): Do only
3577 (account_profile): Calculate size and time of
3579 (pass_manager::dump_profile_report): Reformat
3581 (execute_one_ipa_transform_pass): Call
3582 consistency check before clean upand call account_profile
3583 after a clean up is done.
3584 (execute_one_pass): Call check_profile_consistency and
3585 account_profile instead of using after_pass flag..
3586 * tree-cfg.c (gimple_account_profile_record): Likewise.
3588 2018-11-13 Martin Liska <mliska@suse.cz>
3591 * config/i386/i386.c (ix86_option_override_internal): Error
3592 about usage -mabi=ms and -fsanitize={,kernel-}address.
3594 2018-11-13 Andre Vieira <andre.simoesdiasvieira@arm.com>
3596 * config/aarch64/aarch64.c
3597 (aarch64_vectorize_preferred_vector_alignment): Change return type to
3599 (aarch64_simd_vector_alignment_reachable): Adapt to preferred vector
3600 alignment being a poly int.
3601 * doc/tm.texi (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Change
3602 return type to poly_uint64.
3603 * target.def (default_preferred_vector_alignment): Likewise.
3604 * targhooks.c (default_preferred_vector_alignment): Likewise.
3605 * targhooks.h (default_preferred_vector_alignment): Likewise.
3606 * tree-vect-data-refs.c (vect_calculate_target_alignment): Likewise.
3607 (vect_compute_data_ref_alignment): Adapt to vector alignment being a
3609 (vect_update_misalignment_for_peel): Likewise.
3610 (vect_enhance_data_refs_alignment): Likewise.
3611 (vect_find_same_alignment_drs): Likewise.
3612 (vect_duplicate_ssa_name_ptr_info): Likewise.
3613 (vect_setup_realignment): Likewise.
3614 (vect_can_force_dr_alignment_p): Change alignment parameter type to
3616 * tree-vect-loop-manip.c (get_misalign_in_elems): Learn to construct a
3617 mask with a compile time variable vector alignment.
3618 (vect_gen_prolog_loop_niters): Adapt to vector alignment being a poly
3620 (vect_do_peeling): Exit early if vector alignment is not constant.
3621 * tree-vect-stmts.c (ensure_base_align): Adapt to vector alignment being
3623 (vectorizable_store): Likewise.
3624 (vectorizable_load): Likweise.
3625 * tree-vectorizer.h (struct dr_vec_info): Make target_alignment field a
3627 (vect_known_alignment_in_bytes): Adapt to vector alignment being a
3629 (vect_can_force_dr_alignment_p): Change alignment parameter type to
3632 2018-11-13 Richard Biener <rguenther@suse.de>
3634 PR tree-optimization/87962
3635 * tree-vect-loop.c (vect_is_simple_reduction): More reliably
3636 detect outer reduction for disqualifying in-loop uses.
3638 2018-11-13 Richard Biener <rguenther@suse.de>
3640 PR tree-optimization/87967
3641 * tree-vect-loop.c (vect_transform_loop): Also copy PHIs
3642 for constants for the scalar loop.
3644 2018-11-13 Alan Modra <amodra@gmail.com>
3646 * config/rs6000/linux64.h (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Exclude
3647 integer constants when -mcmodel=medium.
3649 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
3651 * config/arc/arc.h (FUNCTION_PROFILER): Redefine to empty.
3652 * config/arc/elf.h (PROFILE_HOOK): Define.
3653 * config/arc/linux.h (PROFILE_HOOK): Likewise.
3655 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
3657 * config/arc/arc.c (hwloop_optimize): Bailout when detecting a
3658 jump table data in the text section.
3660 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
3662 * config/arc/arc.c (arc_eh_return_address_location): Repurpose it
3663 to fit the eh_return pattern.
3664 * config/arc/arc.md (eh_return): Define.
3665 (VUNSPEC_ARC_EH_RETURN): Likewise.
3666 * config/arc/arc-protos.h (arc_eh_return_address_location): Match
3668 * config/arc/arc.h (EH_RETURN_HANDLER_RTX): Remove it.
3671 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
3673 * common/config/arc/arc-common.c (arc_option_optimization_table):
3674 Millicode optimization is default on for size optimizations.
3675 * config/arc/arc-protos.h (arc_check_multi): New function.
3676 * config/arc/arc.c (RTX_OK_FOR_OFFSET_P): Rearange.
3677 (ENTER_LEAVE_START_REG): Define.
3678 (ENTER_LEAVE_END_REG): Likewise.
3679 (arc_override_options): Disable millicode when long calls option
3681 (arc_frame_info): Change it from int to bool.
3682 (arc_compute_frame_size): Clean up.
3683 (arc_save_restore): Remove.
3684 (frame_save_reg): New function.
3685 (frame_restore_reg): Likewise.
3686 (arc_enter_leave_p): Likewise.
3687 (arc_save_callee_saves): Likewise.
3688 (arc_restore_callee_saves): Likewise.
3689 (arc_save_callee_enter): Likewise.
3690 (arc_restore_callee_leave): Likewise.
3691 (arc_save_callee_milli): Likewise.
3692 (arc_restore_callee_milli): Likewise.
3693 (arc_expand_prologue): Reimplement to emit enter/leave
3695 (arc_expand_epilogue): Likewise.
3696 (arc_check_multi): New function.
3697 * config/arc/arc.md (push_multi_fp): New pattern.
3698 (push_multi_fp_blink): Likewise.
3699 (pop_multi_fp): Likewise.
3700 (pop_multi_fp_blink): Likewise.
3701 (pop_multi_fp_ret): Likewise.
3702 (pop_multi_fp_blink_ret): Likewise.
3703 * config/arc/arc.opt (mmillicode): Update option.
3704 (mcode-density-frame): New option.
3705 * config/arc/predicates.md (push_multi_operand): New predicate.
3706 (pop_multi_operand): Likewise.
3707 * doc/invoke.texi (ARC): Update ARC options information.
3710 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
3712 * config/arc/arc-protos.h (gen_operands_ldd_std): Add.
3713 * config/arc/arc.c (operands_ok_ldd_std): New function.
3714 (mem_ok_for_ldd_std): Likewise.
3715 (gen_operands_ldd_std): Likewise.
3716 * config/arc/arc.md: Add peephole2 rules for std/ldd.
3718 2018-11-13 Eric Botcazou <ebotcazou@adacore.com>
3720 * toplev.c (output_stack_usage): Turn test on flag_stack_usage into
3721 test on stack_usage_file.
3722 (lang_dependent_init): Do not open the .su file if generating LTO.
3724 2018-11-13 Jakub Jelinek <jakub@redhat.com>
3726 PR rtl-optimization/87918
3727 * simplify-rtx.c (simplify_merge_mask): For COMPARISON_P, use
3728 simplify_gen_relational rather than simplify_gen_binary.
3730 2018-11-13 Richard Biener <rguenther@suse.de>
3732 * tree-ssanames.h (set_range_info): Use value_range_base.
3733 (get_range_info): Likewise.
3734 * tree-ssanames.c (set_range_info): Likewise.
3735 (get_range_info): Likewise.
3736 * tree-vrp.c (value_range_base::union_helper): Split
3737 out common parts of value_range[_base]::union_.
3738 (value_range_base::union_): Update.
3739 (value_range::union_): Likewise.
3740 (determine_value_range_1): Use value_range_base.
3741 (determine_value_range): Likewise.
3742 * tree-vrp.h (value_range_base::union_helper): Move ...
3743 (value_range::union_helper): ... from here.
3745 2018-11-13 Alan Modra <amodra@gmail.com>
3747 * config/rs6000/rs6000.c (rs6000_secondary_reload_inner): Negate
3749 (rs6000_secondary_reload_gpr): Don't call find_replacement.
3751 2018-11-13 Sandra Loosemore <sandra@codesourcery.com>
3754 * doc/invoke.texi (Optimize Options): Clarify that the
3755 l1-cache-line-size, l1-cache-size, and l2-cache-size parameters
3756 apply to data cache size.
3758 2018-11-13 Alan Modra <amodra@gmail.com>
3760 * config/rs6000/predicates.md (logical_const_operand),
3761 (logical_operand): Correct comment.
3762 * config/rs6000/rs6000.c (rs6000_emit_prologue): Comment fix.
3764 2018-11-13 Alan Modra <amodra@gmail.com>
3766 * config/rs6000/rs6000.md (addsi3_high): Prefix with '*'.
3768 2018-11-13 Alan Modra <amodra@gmail.com>
3770 * gcc/doc/md.texi (Machine Constraints): Correct rs6000 h constraint
3772 * config/rs6000/rs6000.md (movsi_internal1): Delete MT%0 case
3773 covered by alternative.
3774 (movcc_internal1): Ignore h for register preference.
3775 (mov<mode>_hardfloat64): Likewise.
3776 (mov<mode>_softfloat): Ignore c, l, h for register preference.
3778 2018-11-12 Sandra Loosemore <sandra@codesourcery.com>
3780 PR preprocessor/47823
3781 * doc/cpp.texi (Alternatives to Wrapper #ifndef): Move #pragma once
3784 * doc/extend.texi (Pragmas): Note additional pragmas documented
3787 2018-11-13 Kugan Vivekanandarajah <kuganv@linaro.org>
3791 * tree-scalar-evolution.c (expression_expensive_p): Make
3792 BUILTIN POPCOUNT as expensive when backend does not define it.
3794 2018-11-12 Fredrik Noring <noring@nocrew.org>
3796 * config.gcc: Update with-llsc defaults for MIPS r5900.
3798 2018-11-12 Martin Liska <mliska@suse.cz>
3800 PR gcov-profile/87442
3801 * common.opt: Add -fprofile-filter-files and -fprofile-exclude-files
3803 * doc/invoke.texi: Document them.
3804 * tree-profile.c (parse_profile_filter): New.
3805 (parse_profile_file_filtering): Likewise.
3806 (release_profile_file_filtering): Likewise.
3807 (include_source_file_for_profile): Likewise.
3808 (tree_profiling): Filter source files based on the
3809 newly added options.
3811 2018-11-12 Martin Liska <mliska@suse.cz>
3814 * doc/extend.texi: Add missing values for __builtin_cpu_is and
3815 __builtin_cpu_supports for x86 target.
3817 2018-11-12 Sandra Loosemore <sandra@codesourcery.com>
3820 * doc/rtl.texi (Constants): Clarify that mode of "high" doesn't
3822 (Arithmetic): Likewise for "lo_sum".
3824 2018-11-12 Renlin Li <renlin.li@arm.com>
3827 * dse.c (get_stored_val): Add check for compile-time constantness
3830 2018-11-12 Sudakshina Das <sudi.das@arm.com>
3832 * config/arm/arm-cpus.in (armv8_5, sb, predres): New features.
3833 (ARMv8_5a): New fgroup.
3834 (armv8.5-a): New arch.
3835 (armv8-a, armv8.1-a, armv8.2-a, armv8.3-a, armv8.4-a): New options
3837 * config/arm/arm-tables.opt: Regenerate.
3838 * config/arm/t-aprofile: Add matching rules for -march=armv8.5-a
3839 * config/arm/t-arm-elf (all_v8_archs): Add armv8.5-a.
3840 * config/arm/t-multilib (v8_5_a_simd_variants): New variable.
3841 Add matching rules for -march=armv8.5-a and extensions.
3842 * doc/invoke.texi (ARM options): Document -march=armv8.5-a.
3843 Add sb and predres to all armv8-a except armv8.5-a.
3845 2018-11-12 Richard Biener <rguenther@suse.de>
3847 * tree-vrp.h (value_range[_base]::set): Make public. Provide
3848 overload for single value.
3849 (value_range[_base]::set_nonnull): New.
3850 (value_range[_base]::set_null): Likewise.
3851 (value_range): Document bitmap copying behavior, mark
3852 copy constructor and assignment operator deleted.
3853 (value_range::move): New.
3854 (value_range::set_and_canonicalize): Default bitmap to zero.
3855 (set_value_range_to_nonnull): Remove.
3856 (set_value_range_to_null): Likewise.
3857 (set_value_range): Likewise.
3858 (set_value_range_to_value): Likewise.
3859 (extract_range_from_unary_expr): Work on value_range_base.
3860 (extract_range_from_binary_expr_1): Likewise. Rename to...
3861 (extract_range_from_binary_expr): ... this.
3862 * tree-vrp.c (value_range::update): Clear equiv bitmap
3864 (value_range::move): New, move equiv bitmap.
3865 (value_range_base::set_undefined): Avoid assignment.
3866 (value_range::set_undefined): Likewise.
3867 (value_range_base::set_varying): Likewise.
3868 (value_range::set_varying): Likewise.
3869 (set_value_range): Remove.
3870 (value_range_base::set): New overload for value.
3871 (value_range::set): Likewise.
3872 (set_value_range_to_nonnull): Remove.
3873 (value_range_base::set_nonnull): New.
3874 (value_range::set_nonnull): Likewise.
3875 (set_value_range_to_null): Remove.
3876 (value_range_base::set_null): New.
3877 (value_range::set_null): Likewise.
3878 (range_is_null): Work on value_range_base.
3879 (range_is_nonnull): Likewise.
3880 (ranges_from_anti_range): Likewise.
3881 (extract_range_into_wide_ints): Likewise.
3882 (extract_range_from_multiplicative_op): Likewise.
3883 (extract_range_from_binary_expr): Likewise. Update for API changes.
3884 (extract_range_from_unary_expr): Likewise. Remove OBJ_TYPE_REF
3886 (value_range::intersect_helper): Avoid copy and assignment.
3887 (value_range::union_helper): Likewise.
3888 (determine_value_range_1): Adjust.
3889 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::try_find_new_range):
3890 Avoid assignment by using move.
3891 (evrp_range_analyzer::record_ranges_from_stmt): Avoid assignment.
3892 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
3894 * tree-ssanames.c (get_range_info): Likewise.
3895 * vr-values.h (vr_values::get_vr_for_comparison): Adjust API.
3896 * vr-values.c (vr_values::get_value_range): Adjust.
3897 (vr_values::update_value_range): Likewise.
3898 (symbolic_range_based_on_p): Work on value_range_base.
3899 (vr_values::extract_range_from_binary_expr): Use value_range_base.
3900 (vr_values::extract_range_from_unary_expr): Likewise.
3901 (vr_values::extract_range_from_cond_expr): Avoid assignment.
3902 (vr_values::extract_range_from_comparison): Adjust.
3903 (vr_values::check_for_binary_op_overflow): Use value_range_base.
3904 (vr_values::extract_range_basic): Adjust.
3905 (vr_values::adjust_range_with_scev): Likewise.
3906 (vr_values::vrp_visit_assignment_or_call): Likewise.
3907 (vr_values::get_vr_for_comparison): Change API to avoid
3908 assignment and copy construction.
3909 (vr_values::compare_name_with_value): Adjust accordingly.
3910 (vr_values::compare_names): Likewise.
3911 (vr_values::extract_range_from_phi_node): Avoid assignment and
3912 bogus in-place modify of equiv bitmap.
3913 (vr_values::simplify_bit_ops_using_ranges): Use value_range_base.
3914 * ipa-prop.c (ipa_compute_jump_functions_for_edge): Adjust
3915 for extract_range_from_unary_expr API change.
3916 * ipa-cp.c (ipa_vr_operation_and_type_effects): Likewise.
3918 2018-11-12 Eric Botcazou <ebotcazou@adacore.com>
3920 * config/mcore/mcore.h (WORD_REGISTER_OPERATIONS): Remove duplicate.
3922 2018-11-12 Richard Biener <rguenther@suse.de>
3924 * tree-vrp.h (value_range_base::symbolic_p,
3925 value_range_base::constant_p, value_range_base::zero_p,
3926 value_range_base::singleton_p): Move from value_range.
3927 (value_range::dump): Add.
3928 * gimple-ssa-evrp-analyze.c
3929 (evrp_range_analyzer::record_ranges_from_phis): Use set_varying.
3930 * ipa-cp.c (ipcp_vr_lattice::print): Use dump_value_range.
3931 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
3933 * tree-vrp.c (value_range::symbolic_p): Move to value_range_base.
3934 (value_range::constant_p): Likewise.
3935 (value_range::singleton_p): Likewise.
3936 (value_range_base::dump): Add.
3937 (set_value_range_to_undefined): Remove.
3938 (set_value_range_to_varying): Likewise.
3939 (range_int_cst_p): Take value_range_base argument.
3940 (range_int_cst_singleton_p): Likewise.
3941 (value_range_constant_singleton): Likewise.
3942 (vrp_set_zero_nonzero_bits): Likewise.
3943 (extract_range_from_multiplicative_op): Use set_varying.
3944 (extract_range_from_binary_expr_1): Likewise. Use set_undefined.
3945 (extract_range_from_unary_expr): Likewise.
3946 (dump_value_range_base): Change to overload of dump_value_range.
3947 (vrp_prop::vrp_initialize): Use set_varying and set_undefined.
3948 (vrp_prop::visit_stmt): Likewise.
3949 (value_range::intersect_helper): Likewise.
3950 (value_range::union_helper): Likewise.
3951 (determine_value_range_1): Likewise.
3953 2018-11-12 Richard Biener <rguenther@suse.de>
3955 * tree-vrp.c (set_value_range_to_nonnull): Clear equiv.
3956 (set_value_range_to_null): Likewise.
3957 * vr-values.c (vr_values::extract_range_from_comparison):
3958 Clear equiv for constant singleton ranges.
3960 2018-11-12 Wei Xiao <wei3.xiao@intel.com>
3962 * config/i386/sse.md: Combine VFIXUPIMM* patterns
3963 (<avx512>_fixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
3964 (<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
3965 (<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Remove.
3966 (avx512f_sfixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
3967 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
3968 (avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Remove.
3970 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
3973 * doc/extend.texi (Common Type Attributes): For the align type
3974 attribute, copy language about decreasing alignment from the
3975 corresponding variable attribute.
3977 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
3979 * config/csky/csky.md (*fpuv2_nmulsf3_1, *fpuv2_nmuldf3_1): Handle
3982 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
3985 * doc/invoke.texi (C++ Dialect Options): Add warning about mixing
3986 -frtti and -fno-rtti code.
3988 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
3991 * doc/extend.texi (Other Builtins): Document probability associated
3992 with __builtin_expect.
3994 2018-11-11 Uros Bizjak <ubizjak@gmail.com>
3997 * config/i386/i386.h (STACK_BOUNDARY): Use TARGET_64BIT_MS_ABI
3998 instead of (TARGET_64BIT && ix86_abi == MS_ABI).
3999 * config/i386/darwin.h (STACK_BOUNDARY): Ditto.
4000 * config/i386/cygming.h (STACK_BOUNDARY): Remove.
4002 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
4004 * config/csky/csky-linux-elf.h (CC1_SPEC): Support -profile.
4006 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
4008 * config/csky/csky.h (ASM_PREFERRED_EH_DATA_FORMAT): Define.
4010 2018-11-11 Richard Biener <rguenther@suse.de>
4012 * tree-vrp.h (class value_range_base): New base class for
4013 value_range containing all but the m_equiv member.
4014 (dump_value_range_base): Add.
4015 (range_includes_zero_p): Work on value_range_base.
4016 * tree-vrp.c (value_range_base::set): Split out base handling
4018 (value_range::set): this.
4019 (value_range::set_equiv): New.
4020 (value_range_base::value_range_base): New constructors.
4021 (value_range_base::check): Split out base handling from...
4022 (value_range::check): this.
4023 (value_range::equal_p): Refactor in terms of
4024 ignore_equivs_equal_p which is now member of the base.
4025 (value_range_base::set_undefined): New.
4026 (value_range_base::set_varying): Likewise.
4027 (value_range_base::dump):Split out base handling from...
4028 (value_range::dump): this.
4029 (value_range_base::set_and_canonicalize): Split out base handling
4031 (value_range::set_and_canonicalize): this.
4032 (value_range_base::union_): New.
4033 * ipa-prop.h (struct ipa_jump_func): Use value_range_base *
4035 * ipa-cp.c (class ipcp_vr_lattice): Use value_range_base
4036 instead of value_range everywhere.
4037 (ipcp_vr_lattice::print): Use dump_value_range_base.
4038 (ipcp_vr_lattice::meet_with): Adjust.
4039 (ipcp_vr_lattice::meet_with_1): Likewise.
4040 (ipa_vr_operation_and_type_effects): Likewise.
4041 (propagate_vr_across_jump_function): Likewise.
4042 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Likewise.
4043 (ipa_get_value_range): Likewise.
4044 (ipa_set_jfunc_vr): Likewise.
4045 (ipa_compute_jump_functions_for_edge): Likewise.
4047 2018-11-10 Sandra Loosemore <sandra@codesourcery.com>
4050 * doc/invoke.texi (Optimize Options): Add @opindex entries
4051 for the positive forms of -fno-xxx and -mno-xxx options
4052 that were lacking them.
4054 2018-11-10 Segher Boessenkool <segher@kernel.crashing.org>
4056 * combine.c (make_more_copies): Only make an intermediate copy if the
4057 dest of a move is a pseudo.
4059 2018-11-09 Maya Rashish <coypu@sdf.org>
4062 * config/netbsd-elf.h (NETBSD_STARTFILE_SPEC): Use crtbeginS.o for PIE.
4063 (NETBSD_ENDFILE_SPEC): Use crtendS.o for PIE.
4065 2018-11-09 Sandra Loosemore <sandra@codesourcery.com>
4069 * doc/invoke.texi (Optimize Options): Clarify default behavior
4070 for -fno-toplevel-reorder, -fno-defer-pop, and -fno-branch-count-reg.
4072 2018-11-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
4074 PR tree-optimization/87940
4075 * expr.c (string_constant): Don't strip NOPS in subexpressions.
4076 Fold PLUS_EXPR correctly.
4078 2018-11-09 Ilya Leoshkevich <iii@linux.ibm.com>
4081 * config/s390/s390.c (s390_safe_relative_long_p): New function.
4082 (annotate_constant_pool_refs): Skip insns which support
4083 relative addressing.
4084 (annotate_constant_pool_refs_1): New helper function.
4085 (find_constant_pool_ref): Skip insns which support relative
4087 (find_constant_pool_ref_1): New helper function.
4088 (replace_constant_pool_ref): Skip insns which support
4089 relative addressing.
4090 (replace_constant_pool_ref_1): New helper function.
4091 (s390_mainpool_start): Adapt to the new signature.
4092 (s390_mainpool_finish): Likewise.
4093 (s390_chunkify_start): Likewise.
4094 (s390_chunkify_finish): Likewise.
4095 (pass_s390_early_mach::execute): Likewise.
4096 (s390_prologue_plus_offset): Likewise.
4097 (s390_emit_prologue): Likewise.
4098 (s390_emit_epilogue): Likewise.
4100 2018-11-09 Jakub Jelinek <jakub@redhat.com>
4102 * gimplify.c (gimplify_scan_omp_clauses): Call sorry_at for valid
4103 but unsupported lastprivate with conditional modifier.
4105 2018-11-09 Jeff Law <law@redhat.com>
4107 * config/mips/mips.c (mips_loongson_ext2_prefetch_cookie): Handle
4108 unused argument better. Add gcc_unreachable to silence warning.
4110 2018-11-09 Martin Sebor <msebor@redhat.com>
4113 * attribs.c (has_attribute): New helper function.
4114 (decls_mismatched_attributes, maybe_diag_alias_attributes): Same.
4115 * attribs.h (decls_mismatched_attributes): Declare.
4116 * cgraphunit.c (handle_alias_pairs): Call maybe_diag_alias_attributes.
4117 (maybe_diag_incompatible_alias): Use OPT_Wattribute_alias_.
4118 * common.opt (-Wattribute-alias): Take an argument.
4119 (-Wno-attribute-alias): New option.
4120 * doc/extend.texi (Common Function Attributes): Document copy.
4121 (Common Variable Attributes): Same.
4122 * doc/invoke.texi (-Wmissing-attributes): Document enhancement.
4123 (-Wattribute-alias): Document new option argument.
4125 2018-11-09 Richard Earnshaw <rearnsha@arm.com>
4127 * config/arm/parsecpu.awk (/alias/): Tighten invisible alias
4128 matching criteria. Remove unused array initializer.
4130 2018-11-09 Bill Schmidt <wschmidt@linux.ibm.com>
4131 Jinsong Ji <jji@us.ibm.com>
4133 * config/rs6000/xmmintrin.h (_mm_cvtss_si32): Fix incorrect
4134 constraints by introducing a new temporary.
4135 (_mm_cvtss_si64): Likewise.
4137 2018-11-09 Martin Liska <mliska@suse.cz>
4139 * common.opt: Add -fipa-stack-alignment flag.
4140 * doc/invoke.texi: Document it.
4141 * final.c (rest_of_clean_state): Guard stack
4142 shrinking with flag.
4144 2018-11-09 Martin Liska <mliska@suse.cz>
4146 * cgraph.h (ipa_discover_readonly_nonaddressable_vars): Rename
4148 (ipa_discover_variable_flags): ... this.
4149 * common.opt: Come up with new flag -fipa-reference-addressable.
4150 * doc/invoke.texi: Document it.
4151 * ipa-reference.c (propagate): Call the renamed fn.
4152 * ipa-visibility.c (whole_program_function_and_variable_visibility):
4154 * ipa.c (ipa_discover_readonly_nonaddressable_vars): Renamed to
4156 (ipa_discover_variable_flags): ... this. Discover
4157 non-addressable variables only with the newly added flag.
4158 * opts.c: Enable the newly added flag with -O1 and higher
4161 2018-11-09 David Malcolm <dmalcolm@redhat.com>
4163 * json.cc (selftest::test_writing_literals): Fix comment.
4165 2018-11-09 Martin Liska <mliska@suse.cz>
4167 * config/aarch64/aarch64.c (aarch64_parse_arch): Do not copy
4168 string to a stack buffer.
4169 (aarch64_parse_cpu): Likewise.
4170 (aarch64_parse_tune): Likewise.
4172 2018-11-09 Richard Biener <rguenther@suse.de>
4174 PR tree-optimization/87953
4175 * tree-vect-loop.c (vectorizable_reduction): For analysis
4176 always pass ops[0] to vectorizable_condition.
4178 2018-11-09 Stafford Horne <shorne@gmail.com>
4179 Richard Henderson <rth@twiddle.net>
4180 Joel Sherrill <joel@rtems.org>
4182 * common/config/or1k/or1k-common.c: New file.
4183 * config/or1k/*: New.
4184 * config.gcc (or1k*-*-*): New.
4185 * configure.ac (or1k*-*-*): New test for openrisc tls.
4186 * configure: Regenerated.
4187 * doc/install.texi: Document OpenRISC triplets.
4188 * doc/invoke.texi: Document OpenRISC arguments.
4189 * doc/md.texi: Document OpenRISC.
4191 2018-11-09 Richard Earnshaw <rearnsha@arm.com>
4193 * config/arm/arm-cpus.in (arm7tdmi): Add an alias for arm7tdmi-s.
4194 (arm7tdmi-s): Delete CPU.
4195 (arm710t): Add aliases for arm720t and arm740t.
4196 (arm720t, arm740t): Delete CPUs.
4197 (arm920t): Add aliases for arm920, arm922t and arm940t.
4198 (arm920, arm922t, arm940t): Delete CPUs.
4199 (arm10tdmi): Add alias for arm1020t.
4200 (arm1020t): Delete CPU.
4201 (arm9e): Add aliases for arm946e-s, arm966e-s and arm968e-s.
4202 (arm946e-s, arm966e-s, arm968e-s): Delete CPUs.
4203 (arm10e): Add aliases for arm1020e and arm1022e.
4204 (arm1020e, arm1022e): Delete CPU.
4205 * config/arm/arm.md (generic_sched): Remove entries that are now
4207 (generic_vfp): Likewise.
4208 * config/arm/arm1020e.md: Simplify tuning selection based on alias
4210 * config/arm/arm-tune.md: Regenerated.
4211 * config/arm/arm-tables.opt: Regenerated.
4213 2018-11-09 Richard Biener <rguenther@suse.de>
4215 PR tree-optimization/87621
4216 * tree-vect-loop.c (vectorizable_reduction): Handle reduction
4217 op with only phi inputs.
4218 * tree-ssa-loop-ch.c: Include tree-ssa-sccvn.h.
4219 (ch_base::copy_headers): Run CSE on copied loop headers.
4220 (pass_ch_vect::process_loop_p): Simplify.
4222 2018-11-09 Alexandre Oliva <oliva@adacore.com>
4224 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Adjust
4225 for non-w64 x86_64 biarch.
4227 2018-11-09 Alexandre Oliva <aoliva@redhat.com>
4229 PR rtl-optimization/86438
4230 * compare-elim.c (try_eliminate_compare): Use SET_SRC instead
4231 of in_b for the compare if in_b is SET_DEST.
4234 * config/i386/i386.c (ix86_const_not_ok_for_debug_p): Reject
4235 non-toplevel UNSPEC.
4237 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4239 * tree-vrp.c (value_range::check): Do not access internals
4241 (value_range::singleton_p): Same.
4242 (value_range::type): Same.
4243 (vrp_finalize): Use value_range API.
4245 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4247 * tree-vrp.c (may_contain_p): Do not access m_min/m_max directly.
4249 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4251 * vr-values.c (vr_values::get_value_range): Use value_range API
4252 instead of piecing together ranges.
4253 (vr_values::update_value_range): Same.
4255 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4257 * gimple-fold.c (size_must_be_zero_p): Use value_range API instead
4258 of performing ad-hoc calculations.
4259 * tree-ssanames.c (set_range_info): New overloaded function
4260 accepting value_range &.
4261 (get_range_info): Same.
4262 * tree-ssanames.h (set_range_info_raw): Remove.
4263 (set_range_info): New prototype.
4264 (get_range_info): Same.
4265 * tree-vrp.h (value_range::null_p): Rename to zero_p.
4266 * tree-vrp.c (value_range::null_p): Same.
4268 2018-11-09 Jan Hubicka <jh@suse.cz>
4270 * tree.c (fld_type_variant_equal_p): Test user align flag.
4271 (flt_type_variant): Copy user align flag.
4272 (fld_incomplete_type_of): Clear it.
4274 2018-11-09 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4276 * config/arm/neon.md (div<mode>3): New pattern.
4278 2018-11-08 Andi Kleen <ak@linux.intel.com>
4280 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PTWRITE_SET): New.
4281 (OPTION_MASK_ISA_PTWRITE_UNSET): New.
4282 (ix86_handle_option): Handle OPT_mptwrite.
4283 * config/i386/cpuid.h (bit_PTWRITE): Add.
4284 * config/i386/driver-i386.c (host_detect_local_cpu): Detect ptwrite.
4285 * config/i386/i386-builtin.def (BDESC): Add ptwrite32/64.
4286 * config/i386/i386-c.c (ix86_target_macros_internal): Define __PTWRITE__.
4287 * config/i386/i386.c (ix86_target_string): Handle ptwrite.
4288 (ix86_option_override_internal): Handle PTA_PTWRITE.
4289 (ix86_valid_target_attribute_inner_p): Define ptwrite.
4290 (def_builtin2): Force UINT64 to be 64bit only.
4291 * config/i386/i386.h (TARGET_PTWRITE): Add.
4292 (TARGET_PTWRITE_P): Add.
4294 * config/i386/i386.md: Define ptwrite.
4295 * config/i386/i386.opt: Add -mptwrite.
4296 * config/i386/immintrin.h (_ptwrite64): Add.
4298 * doc/extend.texi: Document __builtin_ia32_ptwrite*.
4299 * doc/invoke.texi: Document -mptwrite.
4301 2018-11-08 Peter Bergner <bergner@linux.ibm.com>
4303 PR rtl-optimization/87600
4304 * cfgexpand.c (expand_asm_stmt): Catch illegal asm constraint usage.
4305 * lra-constraints.c (process_alt_operands): Skip illegal hard
4306 register usage. Prefer reloading non hard register operands.
4308 2018-11-08 Sandra Loosemore <sandra@codesourcery.com>
4311 * doc/invoke.texi (Optimize Options): Clarify default behavior
4312 for -fno-sched-interblock and -fno-sched-spec.
4314 2018-11-08 Roman Geissler <roman.geissler@amadeus.com>
4316 * collect2.c (linker_select): Add USE_LLD_LD.
4317 (ld_suffixes): Add ld.lld.
4318 (main): Handle -fuse-ld=lld.
4319 * common.opt (-fuse-ld=lld): New option.
4320 * doc/invoke.texi (-fuse-ld=lld): Document.
4321 * opts.c (common_handle_option): Handle OPT_fuse_ld_lld.
4323 2018-11-08 Paul Koning <ni1d@arrl.net>
4325 * config/pdp11/constraints.md: Add "Z" series constraints for use
4326 with pre-dec and post-inc addressing.
4327 * config/pdp11/pdp11-protos.m (expand_block_move): Delete.
4328 (pdp11_expand_operands): Add int argument (word count).
4329 (pdp11_sp_frame_offset): Delete.
4330 (pdp11_cmp_length): New function.
4331 (pushpop_regeq): New function.
4332 * config/pdp11/pdp11.c (TARGET_STACK_PROTECT_RUNTIME_ENABLED_P):
4334 (pdp11_expand_prologue, pdp11_expand_epilogue): Rewrite for new
4336 (pdp11_initial_elimination_offset): Ditto.
4337 (pdp11_expand_operands): Add word count argument. Bugfixes.
4338 (output_move_multiple): Change how pointer adjustment is done.
4339 (pdp11_gen_int_label): Correct format.
4340 (output_ascii): Ditto.
4341 (pdp11_asm_output_var): Add code for DEC assembler case.
4342 (pdp11_asm_print_operand): Bugfix for CONST_DOUBLE holding integer
4344 (legitimate_const_double_p): Ditto.
4345 (pdp11_register_move_cost): Adjust for new register classes.
4346 (pdp11_regno_reg_class): Ditto.
4347 (expand_block_move): Delete.
4348 (pushpop_regeq): New function.
4349 (pdp11_legitimate_address_p): Bugfix in check for constant
4351 (pdp11_sp_frame_offset): Delete.
4352 (pdp11_reg_save_size): New helper function for new frame layout.
4353 (output_addr_const_pdp11): Remove CONST_DOUBLE case.
4354 (pdp11_expand_shift): Bugfix in check for constant shift count.
4355 (pdp11_shift_length): Ditto.
4356 (pdp11_assemble_shift): Copy input to pdp11_expand_operands.
4357 (pdp11_cmp_length): New function.
4358 * config/pdp11/pdp11.h (TARGET_CPU_CPP_BUILTINS): Add macros for
4359 some compile options.
4360 (FIXED_REGISTERS): Remove HARD_FRAME_POINTER_REGNUM.
4361 (CALL_USED_REGISTERS): Ditto.
4362 (ELIMINABLE_REGS): Ditto.
4363 (REGISTER_NAMES): Ditto.
4364 (reg_class): Add classes NOTR0_REG through NOTSP_REG for use by Z
4366 (REG_CLASS_NAMES): Ditto.
4367 (REG_CLASS_CONTENTS): Ditto. Also remove
4368 HARD_FRAME_POINTER_REGNUM.
4369 (CPU_REG_CLASS): New macro.
4370 (CLASS_MAX_NREGS): Adjust for new register classes.
4371 (FUNCTION_PROFILER): Make no-op.
4372 (may_call_alloca): Remove unused declaration.
4373 (ASM_OUTPUT_ALIGN): Add workaround for PR87795.
4374 (ASM_OUTPUT_SKIP): Fix format.
4375 * config/pdp11/pdp11.md (unspecv): Add UNSPECV_MOVMEM.
4376 (HARD_FRAME_POINTER_REGNUM): Remove.
4378 (*rts): Rename. Remove epilogue related checks.
4379 (cmpsi, cmpdi): New insn.
4380 (cbranch<mode>4): Change to apply to SI and DI modes as well.
4381 (mov<mode>): Change constraints to enforce that push/pop
4382 destination cannot use the same register as source.
4383 (*mov<mode><cc_cc>): Ditto.
4384 (movmemhi, movmemhi1, movmemhi_nocc): Change to expand block move
4385 at assembly output rather than as RTL expander.
4386 (zero_extendqihi2): Bugfix in check for same registers.
4387 (adddi3_nocc): Bugfix in check for constant operand.
4388 (addsi3_nocc): Ditto.
4389 (subdi3_nocc): Ditto.
4390 (subsi3_nocc): Ditto.
4391 (negdi2_nocc): Copy input to pdp11_expand_operands.
4392 (negsi2_nocc): Ditto.
4393 (bswap2_nocc): Ditto.
4394 * config/pdp11/pdp11.opt (mlra): Fix documentation.
4395 * config/pdp11/t-pdp11: Use -Os.
4397 2018-11-08 Richard Earnshaw <rearnsha@arm.com>
4399 * config/arm/parsecpu.awk (/alias/): New parsing rule.
4400 (/begin cpu/): Check that the cpu name hasn't been previously defined.
4401 (gen_comm_data): Print out CPU alias tables.
4402 (check_cpu): Match aliases when checking the CPU name.
4403 * config/arm/arm-protos.h (cpu_alias): New structure.
4404 (cpu_option): Add entry for aliases.
4405 * config/arm/arm-cpus.in (strongarm): Add aliases for strongarm110
4406 strongarm1100 and strongarm1110.
4407 (strongarm110, strongarm1100, strongarm1110): Delete CPU entries.
4408 (config/arm/arm-generic.md): Remove redundant references to
4409 strongarm110, strongarm1100 and strongarm1110.
4410 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
4411 Scan aliases for additional hints.
4412 (arm_parse_cpu_option_name): Also match a cpu name against the list
4414 * config/arm/arm-tables.opt: Regenerated.
4415 * config/arm/arm-tune.md: Regenerated.
4417 2018-11-08 Jakub Jelinek <jakub@redhat.com>
4419 * builtin-types.def (BT_FN_VOID_BOOL, BT_FN_VOID_SIZE_SIZE_PTR,
4420 BT_FN_UINT_UINT_PTR_PTR, BT_FN_UINT_OMPFN_PTR_UINT_UINT,
4421 BT_FN_BOOL_UINT_LONGPTR_LONG_LONG_LONGPTR_LONGPTR_PTR_PTR,
4422 BT_FN_BOOL_UINT_ULLPTR_LONG_ULL_ULLPTR_ULLPTR_PTR_PTR,
4423 BT_FN_BOOL_LONG_LONG_LONG_LONG_LONG_LONGPTR_LONGPTR_PTR_PTR,
4424 BT_FN_BOOL_BOOL_ULL_ULL_ULL_LONG_ULL_ULLPTR_ULLPTR_PTR_PTR): New.
4425 * gengtype.c (open_base_files): Add omp-general.h.
4426 * gimple.c (gimple_build_omp_critical):
4427 (gimple_build_omp_taskgroup): Add CLAUSES argument. Call
4428 gimple_omp_taskgroup_set_clauses.
4429 (gimple_build_omp_atomic_load): Add mo argument, call
4430 gimple_omp_atomic_set_memory_order.
4431 (gimple_build_omp_atomic_store): Likewise.
4432 (gimple_copy): Adjust handling of GIMPLE_OMP_TASKGROUP.
4433 * gimple.def (GIMPLE_OMP_TASKGROUP): Use GSS_OMP_SINGLE_LAYOUT
4435 (GIMPLE_OMP_TEAMS): Use GSS_OMP_PARALLEL_LAYOUT instead
4436 of GSS_OMP_SINGLE_LAYOUT, adjust comments.
4437 * gimple.h (enum gf_mask): Add GF_OMP_TEAMS_HOST, GF_OMP_TASK_TASKWAIT
4438 and GF_OMP_ATOMIC_MEMORY_ORDER. Remove GF_OMP_ATOMIC_SEQ_CST, use
4439 different value for GF_OMP_ATOMIC_NEED_VALUE.
4440 (struct gimple_statement_omp_taskreg): Add GIMPLE_OMP_TEAMS to
4442 (struct gimple_statement_omp_single_layout): And remove here.
4443 (struct gomp_teams): Inherit from gimple_statement_omp_taskreg rather
4444 than gimple_statement_omp_single_layout.
4445 (is_a_helper <gimple_statement_omp_taskreg *>::test): Allow
4447 (is_a_helper <const gimple_statement_omp_taskreg *>::test): Likewise.
4448 (gimple_omp_subcode): Formatting fix.
4449 (gimple_omp_teams_child_fn, gimple_omp_teams_child_fn_ptr,
4450 gimple_omp_teams_set_child_fn, gimple_omp_teams_data_arg,
4451 gimple_omp_teams_data_arg_ptr, gimple_omp_teams_set_data_arg,
4452 gimple_omp_teams_host, gimple_omp_teams_set_host,
4453 gimple_omp_task_taskwait_p, gimple_omp_task_set_taskwait_p,
4454 gimple_omp_taskgroup_clauses, gimple_omp_taskgroup_clauses_ptr,
4455 gimple_omp_taskgroup_set_clauses): New inline functions.
4456 (gimple_build_omp_atomic_load): Add enum omp_memory_order argument.
4457 (gimple_build_omp_atomic_store): Likewise.
4458 (gimple_omp_atomic_seq_cst_p): Remove.
4459 (gimple_omp_atomic_memory_order): New function.
4460 (gimple_omp_atomic_set_seq_cst): Remove.
4461 (gimple_omp_atomic_set_memory_order): New function.
4462 (gimple_build_omp_taskgroup): Add clauses argument.
4463 * gimple-pretty-print.c (dump_gimple_omp_taskgroup): New function.
4464 (dump_gimple_omp_task): Print taskwait with depend clauses.
4465 (dump_gimple_omp_atomic_load, dump_gimple_omp_atomic_store): Use
4466 dump_omp_atomic_memory_order.
4467 (pp_gimple_stmt_1): Handle GIMPLE_OMP_TASKGROUP.
4468 * gimplify.c (enum gimplify_omp_var_data): Add GOVD_MAP_ALLOC_ONLY,
4469 GOVD_MAP_FROM_ONLY and GOVD_NONTEMPORAL.
4470 (enum omp_region_type): Reserve bits 1 and 2 for auxiliary flags,
4471 renumber values of most of ORT_* enumerators, add ORT_HOST_TEAMS,
4472 ORT_COMBINED_HOST_TEAMS, ORT_TASKGROUP, ORT_TASKLOOP and
4473 ORT_UNTIED_TASKLOOP enumerators.
4474 (enum gimplify_defaultmap_kind): New.
4475 (struct gimplify_omp_ctx): Remove target_map_scalars_firstprivate and
4476 target_map_pointers_as_0len_arrays members, add defaultmap.
4477 (new_omp_context): Initialize defaultmap member.
4478 (gimple_add_tmp_var): Handle ORT_TASKGROUP like ORT_WORKSHARE.
4479 (maybe_fold_stmt): Don't fold even in host teams regions.
4480 (omp_firstprivatize_variable): Handle ORT_TASKGROUP like
4481 ORT_WORKSHARE. Test ctx->defaultmap[GDMK_SCALAR] instead of
4482 ctx->omp_firstprivatize_variable.
4483 (omp_add_variable): Don't add private/firstprivate for VLAs in
4485 (omp_default_clause): Print "taskloop" rather than "task" if
4487 (omp_notice_variable): Handle ORT_TASKGROUP like ORT_WORKSHARE.
4488 Handle new defaultmap clause kinds.
4489 (omp_is_private): Handle ORT_TASKGROUP like ORT_WORKSHARE. Allow simd
4490 iterator to be lastprivate or private. Fix up diagnostics if linear
4491 is used on collapse>1 simd iterator.
4492 (omp_check_private): Handle ORT_TASKGROUP like ORT_WORKSHARE.
4493 (gimplify_omp_depend): New function.
4494 (gimplify_scan_omp_clauses): Add shared clause on parallel for
4495 combined parallel master taskloop{, simd} if taskloop has
4496 firstprivate, lastprivate or reduction clause. Handle
4497 OMP_CLAUSE_REDUCTION_TASK diagnostics. Adjust tests for
4498 ORT_COMBINED_TEAMS. Gimplify depend clauses with iterators. Handle
4499 cancel and simd OMP_CLAUSE_IF_MODIFIERs. Handle
4500 OMP_CLAUSE_NONTEMPORAL. Handle new defaultmap clause kinds. Handle
4501 OMP_CLAUSE_{TASK,IN}_REDUCTION. Diagnose invalid conditional
4503 (gimplify_adjust_omp_clauses_1): Ignore GOVD_NONTEMPORAL. Handle
4504 GOVD_MAP_ALLOC_ONLY and GOVD_MAP_FROM_ONLY.
4505 (gimplify_adjust_omp_clauses): Handle OMP_CLAUSE_NONTEMPORAL. Handle
4506 OMP_CLAUSE_{TASK,IN}_REDUCTION.
4507 (gimplify_omp_task): Handle taskwait with depend clauses.
4508 (gimplify_omp_for): Add shared clause on parallel for combined
4509 parallel master taskloop{, simd} if taskloop has firstprivate,
4510 lastprivate or reduction clause. Use ORT_TASKLOOP or
4511 ORT_UNTIED_TASKLOOP instead of ORT_TASK or ORT_UNTIED_TASK. Adjust
4512 tests for ORT_COMBINED_TEAMS. Handle C++ range for loops with
4513 NULL TREE_PURPOSE in OMP_FOR_ORIG_DECLS. Firstprivatize
4514 __for_end and __for_range temporaries on OMP_PARALLEL for
4515 distribute parallel for{, simd}. Move OMP_CLAUSE_REDUCTION
4516 and OMP_CLAUSE_IN_REDUCTION from taskloop to the task construct
4517 sandwiched in between two taskloops.
4518 (computable_teams_clause): Test ctx->defaultmap[GDMK_SCALAR]
4519 instead of ctx->omp_firstprivatize_variable.
4520 (gimplify_omp_workshare): Set ort to ORT_HOST_TEAMS or
4521 ORT_COMBINED_HOST_TEAMS if not inside of target construct. If
4522 host teams, use gimplify_and_return_first etc. for body like
4523 for target or target data constructs, and at the end call
4524 gimple_omp_teams_set_host on the GIMPLE_OMP_TEAMS object.
4525 (gimplify_omp_atomic): Use OMP_ATOMIC_MEMORY_ORDER instead
4526 of OMP_ATOMIC_SEQ_CST, pass it as new argument to
4527 gimple_build_omp_atomic_load and gimple_build_omp_atomic_store, remove
4528 gimple_omp_atomic_set_seq_cst calls.
4529 (gimplify_expr) <case OMP_TASKGROUP>: Move handling into a separate
4530 case, handle taskgroup clauses.
4531 * lto-streamer-out.c (hash_tree): Handle
4532 OMP_CLAUSE_{TASK,IN}_REDUCTION.
4533 * Makefile.in (GTFILES): Add omp-general.h.
4534 * omp-builtins.def (BUILT_IN_GOMP_TASKWAIT_DEPEND,
4535 BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_START,
4536 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_START,
4537 BUILT_IN_GOMP_LOOP_START, BUILT_IN_GOMP_LOOP_ORDERED_START,
4538 BUILT_IN_GOMP_LOOP_DOACROSS_START,
4539 BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_NEXT,
4540 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_NEXT,
4541 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_START,
4542 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_START,
4543 BUILT_IN_GOMP_LOOP_ULL_START, BUILT_IN_GOMP_LOOP_ULL_ORDERED_START,
4544 BUILT_IN_GOMP_LOOP_ULL_DOACROSS_START,
4545 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_NEXT,
4546 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_NEXT,
4547 BUILT_IN_GOMP_PARALLEL_LOOP_NONMONOTONIC_RUNTIME,
4548 BUILT_IN_GOMP_PARALLEL_LOOP_MAYBE_NONMONOTONIC_RUNTIME,
4549 BUILT_IN_GOMP_PARALLEL_REDUCTIONS, BUILT_IN_GOMP_SECTIONS2_START,
4550 BUILT_IN_GOMP_TEAMS_REG, BUILT_IN_GOMP_TASKGROUP_REDUCTION_REGISTER,
4551 BUILT_IN_GOMP_TASKGROUP_REDUCTION_UNREGISTER,
4552 BUILT_IN_GOMP_TASK_REDUCTION_REMAP,
4553 BUILT_IN_GOMP_WORKSHARE_TASK_REDUCTION_UNREGISTER): New builtins.
4554 * omp-expand.c (workshare_safe_to_combine_p): Return false for
4555 non-worksharing loops.
4556 (omp_adjust_chunk_size): Don't adjust anything if chunk_size is zero.
4557 (determine_parallel_type): Don't combine parallel with worksharing
4558 which has _reductemp_ clause.
4559 (expand_parallel_call): Emit the GOMP_*nonmonotonic_runtime* or
4560 GOMP_*maybe_nonmonotonic_runtime* builtins instead of GOMP_*runtime*
4561 if there is nonmonotonic modifier or if there is no modifier and no
4562 ordered clause. For dynamic and guided schedule without monotonic
4563 and nonmonotonic modifier, default to nonmonotonic.
4564 (expand_omp_for): Likewise. Adjust expand_omp_for_generic caller, use
4565 GOMP_loop{,_ull}{,_ordered,_doacross}_start builtins if there are
4567 (expand_task_call): Add GOMP_TASK_FLAG_REDUCTION flag to flags if
4568 there are any reduction clauses.
4569 (expand_taskwait_call): New function.
4570 (expand_teams_call): New function.
4571 (expand_omp_taskreg): Allow GIMPLE_OMP_TEAMS and call
4572 expand_teams_call for it. Formatting fix. Handle taskwait with
4574 (expand_omp_for_generic): Add SCHED_ARG argument. Handle expansion
4575 of worksharing loops with task reductions.
4576 (expand_omp_for_static_nochunk, expand_omp_for_static_chunk): Handle
4577 expansion of worksharing loops with task reductions.
4578 (expand_omp_sections): Handle expansion of sections with task
4580 (expand_omp_synch): For host teams call expand_omp_taskreg.
4581 (omp_memory_order_to_memmodel): New function.
4582 (expand_omp_atomic_load, expand_omp_atomic_store,
4583 expand_omp_atomic_fetch_op): Use it and gimple_omp_atomic_memory_order
4584 instead of gimple_omp_atomic_seq_cst_p.
4585 (build_omp_regions_1, omp_make_gimple_edges): Treat taskwait with
4586 depend clauses as a standalone directive.
4587 * omp-general.c (enum omp_requires): New variable.
4588 (omp_extract_for_data): Initialize have_reductemp member. Allow
4589 NE_EXPR even in OpenMP loops, transform them into LT_EXPR or
4590 GT_EXPR loops depending on incr sign. Formatting fixes.
4591 * omp-general.h (struct omp_for_data): Add have_reductemp member.
4592 (enum omp_requires): New enum.
4593 (omp_requires_mask): Declare.
4594 * omp-grid.c (grid_eliminate_combined_simd_part): Formatting fix.
4596 * omp-low.c (struct omp_context): Add task_reductions and
4597 task_reduction_map fields.
4598 (is_host_teams_ctx): New function.
4599 (is_taskreg_ctx): Return true also if is_host_teams_ctx.
4600 (use_pointer_for_field): Use is_global_var instead of
4601 TREE_STATIC || DECL_EXTERNAL, and apply only if not privatized
4603 (build_outer_var_ref): Ignore taskgroup outer contexts.
4604 (delete_omp_context): Release task_reductions and task_reduction_map.
4605 (scan_sharing_clauses): Don't add any fields for reduction clause on
4606 taskloop. Handle OMP_CLAUSE__REDUCTEMP_. Handle
4607 OMP_CLAUSE_{IN,TASK}_REDUCTION and OMP_CLAUSE_REDUCTION with task
4608 modifier. Don't ignore shared clauses in is_host_teams_ctx contexts.
4609 Handle OMP_CLAUSE_NONTEMPORAL.
4610 (add_taskreg_looptemp_clauses): Add OMP_CLAUSE__REDUCTEMP_ clause if
4612 (scan_omp_parallel): Add _reductemp_ clause if there are any reduction
4613 clauses with task modifier.
4614 (scan_omp_task): Handle taskwait with depend clauses.
4615 (finish_taskreg_scan): Move field corresponding to _reductemp_ clause
4616 first. Move also OMP_CLAUSE__REDUCTEMP_ clause in front if present.
4617 Handle GIMPLE_OMP_TEAMS like GIMPLE_OMP_PARALLEL.
4618 (scan_omp_for): Fix comment formatting.
4619 (scan_omp_teams): Handle host teams constructs.
4620 (check_omp_nesting_restrictions): Allow teams with no outer
4621 OpenMP context. Adjust diagnostics for teams strictly nested into
4622 some explicit OpenMP construct other than target. Allow OpenMP atomics
4623 inside of simd regions.
4624 (scan_omp_1_stmt): Call scan_sharing_clauses for taskgroups.
4625 (scan_omp_1_stmt) <case GIMPLE_OMP_TEAMS>: Temporarily bump
4626 taskreg_nesting_level while scanning host teams construct.
4627 (task_reduction_read): New function.
4628 (lower_rec_input_clauses): Handle OMP_CLAUSE_REDUCTION on taskloop
4629 construct. Handle OMP_CLAUSE_IN_REDUCTION and OMP_CLAUSE__REDUCTEMP_
4630 clauses. Handle OMP_CLAUSE_REDUCTION with task modifier. Remove
4631 second argument create_tmp_var if it is NULL. Don't ignore shared
4632 clauses in is_host_teams_ctx contexts. Handle
4633 OMP_CLAUSE_FIRSTPRIVATE_NO_REFERENCE on OMP_CLAUSE_FIRSTPRIVATE
4635 (lower_reduction_clauses): Ignore reduction clauses with task
4636 modifier. Remove second argument create_tmp_var if it is NULL.
4637 Initialize OMP_ATOMIC_MEMORY_ORDER to relaxed.
4638 (lower_send_clauses): Ignore reduction clauses with task modifier.
4639 Handle OMP_CLAUSE__REDUCTEMP_. Don't send anything for
4640 OMP_CLAUSE_REDUCTION on taskloop. Handle OMP_CLAUSE_IN_REDUCTION.
4641 (maybe_add_implicit_barrier_cancel): Add OMP_RETURN argument, don't
4642 rely that it is the last stmt in body so far. Ignore outer taskgroup
4644 (omp_task_reductions_find_first, omp_task_reduction_iterate,
4645 lower_omp_task_reductions): New functions.
4646 (lower_omp_sections): Handle reduction clauses with taskgroup
4647 modifiers. Adjust maybe_add_implicit_barrier_cancel caller.
4648 (lower_omp_single): Adjust maybe_add_implicit_barrier_cancel caller.
4649 (lower_omp_for): Likewise. Handle reduction clauses with taskgroup
4651 (lower_omp_taskgroup): Handle taskgroup reductions.
4652 (create_task_copyfn): Copy over OMP_CLAUSE__REDUCTEMP_ pointer.
4653 Handle OMP_CLAUSE_IN_REDUCTION and OMP_CLAUSE_REDUCTION clauses.
4654 (lower_depend_clauses): If there are any
4655 OMP_CLAUSE_DEPEND_DEPOBJ or OMP_CLAUSE_DEPEND_MUTEXINOUTSET
4656 depend clauses, use a new array format. If OMP_CLAUSE_DEPEND_LAST is
4657 seen, assume lowering is done already and return early. Set kind
4658 on artificial depend clause to OMP_CLAUSE_DEPEND_LAST.
4659 (lower_omp_taskreg): Handle reduction clauses with task modifier on
4660 parallel construct. Handle reduction clause on taskloop construct.
4661 Handle taskwait with depend clauses.
4662 (lower_omp_1): Use lower_omp_taskreg instead of lower_omp_teams
4663 for host teams constructs.
4664 * tree.c (omp_clause_num_ops): Add in_reduction, task_reduction,
4665 nontemporal and _reductemp_ clause entries.
4666 (omp_clause_code_name): Likewise.
4667 (walk_tree_1): Handle OMP_CLAUSE_{IN,TASK}_REDUCTION,
4668 OMP_CLAUSE_NONTEMPORAL and OMP_CLAUSE__REDUCTEMP_.
4669 * tree-core.h (enum omp_clause_code): Add
4670 OMP_CLAUSE_{{IN,TASK}_REDUCTION,NONTEMPORAL,_REDUCTEMP_}.
4671 (enum omp_clause_defaultmap_kind, enum omp_memory_order): New.
4672 (struct tree_base): Add omp_atomic_memory_order field into union.
4673 Remove OMP_ATOMIC_SEQ_CST comment.
4674 (enum omp_clause_depend_kind): Add OMP_CLAUSE_DEPEND_MUTEXINOUTSET
4675 and OMP_CLAUSE_DEPEND_DEPOBJ.
4676 (struct tree_omp_clause): Add subcode.defaultmap_kind.
4677 * tree.def (OMP_TASKGROUP): Add another operand, move next to other
4678 OpenMP constructs with body and clauses operands.
4679 * tree.h (OMP_BODY): Use OMP_MASTER instead of OMP_TASKGROUP.
4680 (OMP_CLAUSES): Use OMP_TASKGROUP instead of OMP_SINGLE.
4681 (OMP_TASKGROUP_CLAUSES): Define.
4682 (OMP_CLAUSE_DECL): Use OMP_CLAUSE__REDUCTEMP_ instead of
4683 OMP_CLAUSE__LOOPTEMP_.
4684 (OMP_ATOMIC_SEQ_CST): Remove.
4685 (OMP_ATOMIC_MEMORY_ORDER, OMP_CLAUSE_FIRSTPRIVATE_NO_REFERENCE,
4686 OMP_CLAUSE_LASTPRIVATE_CONDITIONAL): Define.
4687 (OMP_CLAUSE_REDUCTION_CODE, OMP_CLAUSE_REDUCTION_INIT,
4688 OMP_CLAUSE_REDUCTION_MERGE, OMP_CLAUSE_REDUCTION_PLACEHOLDER,
4689 OMP_CLAUSE_REDUCTION_DECL_PLACEHOLDER,
4690 OMP_CLAUSE_REDUCTION_OMP_ORIG_REF): Handle
4691 OMP_CLAUSE_{,IN_,TASK_}REDUCTION.
4692 (OMP_CLAUSE_REDUCTION_TASK, OMP_CLAUSE_REDUCTION_INSCAN,
4693 OMP_CLAUSE_DEFAULTMAP_KIND, OMP_CLAUSE_DEFAULTMAP_CATEGORY,
4694 OMP_CLAUSE_DEFAULTMAP_BEHAVIOR, OMP_CLAUSE_DEFAULTMAP_SET_KIND):
4696 * tree-inline.c (remap_gimple_stmt): Remap taskgroup clauses.
4697 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
4698 OMP_CLAUSE__REDUCTEMP_, OMP_CLAUSE_NONTEMPORAL.
4699 (convert_local_omp_clauses): Likewise. Remove useless test.
4700 * tree-parloops.c (create_call_for_reduction_1): Pass
4701 OMP_MEMORY_ORDER_RELAXED as new argument to
4702 dump_gimple_omp_atomic_load and dump_gimple_omp_atomic_store.
4703 * tree-pretty-print.c (dump_omp_iterators): New function.
4704 (dump_omp_clause): Handle OMP_CLAUSE__REDUCTEMP_,
4705 OMP_CLAUSE_NONTEMPORAL, OMP_CLAUSE_{TASK,IN}_REDUCTION. Print
4706 reduction modifiers. Handle OMP_CLAUSE_DEPEND_DEPOBJ and
4707 OMP_CLAUSE_DEPEND_MUTEXINOUTSET. Print iterators in depend clauses.
4708 Print __internal__ for OMP_CLAUSE_DEPEND_LAST. Handle cancel and
4709 simd OMP_CLAUSE_IF_MODIFIERs. Handle new kinds of
4710 OMP_CLAUSE_DEFAULTMAP. Print conditional: for
4711 OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
4712 (dump_omp_atomic_memory_order): New function.
4713 (dump_generic_node): Use it. Print taskgroup clauses. Print
4714 taskwait with depend clauses.
4715 * tree-pretty-print.h (dump_omp_atomic_memory_order): Declare.
4716 * tree-streamer-in.c (unpack_ts_omp_clause_value_fields):
4717 Handle OMP_CLAUSE_{TASK,IN}_REDUCTION.
4718 * tree-streamer-out.c (pack_ts_omp_clause_value_fields,
4719 write_ts_omp_clause_tree_pointers): Likewise.
4721 2018-11-08 David Malcolm <dmalcolm@redhat.com>
4724 * doc/invoke.texi (-fdump-ipa-): Document the "-optimized",
4725 "-missed", "-note", and "-all" sub-options.
4726 * ipa-inline.c (caller_growth_limits): Port from fprintf to dump
4728 (can_early_inline_edge_p): Likewise.
4729 (want_early_inline_function_p): Likewise.
4730 (want_inline_self_recursive_call_p): Likewise.
4731 (recursive_inlining): Likewise.
4732 (inline_small_functions): Likewise.
4733 (flatten_function): Likewise.
4734 (ipa_inline): Likewise.
4735 (inline_always_inline_functions): Likewise.
4736 (early_inline_small_functions): Likewise.
4737 (early_inliner): Likewise.
4738 * tree-inline.c (expand_call_inline): Likewise.
4740 2018-11-08 David Malcolm <dmalcolm@redhat.com>
4742 * pretty-print.c (pp_format): Handle %f.
4743 (selftest::test_pp_format): Add test of %f.
4744 * pretty-print.h (pp_double): New macro.
4746 2018-11-08 David Malcolm <dmalcolm@redhat.com>
4748 * dump-context.h (ASSERT_IS_CGRAPH_NODE): New macro.
4749 * dumpfile.c (make_item_for_dump_cgraph_node): Move to before...
4750 (dump_pretty_printer::decode_format): Implement "%C" for
4752 (selftest::test_capture_of_dump_calls): Rename "where" to
4753 "stmt_loc". Convert test_decl to a function decl and set its
4754 location. Add a symbol_table_test RAII instance and a
4755 cgraph_node, using it to test "%C" and dump_symtab_node.
4757 2018-11-08 Eric Botcazou <ebotcazou@adacore.com>
4760 * cgraphclones.c (duplicate_thunk_for_node): Also set DECL_IGNORED_P.
4762 2018-11-08 David Malcolm <dmalcolm@redhat.com>
4764 * cgraph.c: Include "selftest.h".
4765 (saved_symtab): New variable.
4766 (selftest::symbol_table_test::symbol_table_test): New ctor.
4767 (selftest::symbol_table_test::~symbol_table_test): New dtor.
4768 (selftest::test_symbol_table_test): New test.
4769 (selftest::cgraph_c_tests): New.
4770 * cgraph.h (saved_symtab): New decl.
4771 (selftest::symbol_table_test): New class.
4772 * selftest-run-tests.c (selftest::run_tests): Call
4773 selftest::cgraph_c_tests.
4774 * selftest.h (selftest::cgraph_c_tests): New decl.
4776 2018-11-08 Richard Biener <rguenther@suse.de>
4778 * tree-data-ref.h (lambda_int): New typedef.
4779 (lambda_vector_gcd): Adjust.
4780 (lambda_vector_new): Likewise.
4781 (lambda_matrix_new): Likewise.
4782 * tree-data-ref.c (print_lambda_vector): Adjust.
4784 2018-11-08 Richard Biener <rguenther@suse.de>
4786 PR tree-optimization/87929
4787 * tree-complex.c (expand_complex_comparison): Clean EH.
4789 2018-11-08 Martin Liska <mliska@suse.cz>
4791 * doc/extend.texi: Reword.
4792 * predict.c (expr_expected_value_1): Likewise.
4794 2018-11-08 Richard Biener <rguenther@suse.de>
4796 PR tree-optimization/87913
4797 * tree-ssa-phiopt.c (minmax_replacement): Turn EQ/NE compares
4798 of extreme values to ordered comparisons.
4800 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
4803 * doc/invoke.texi (Code Gen Options): Clarify -fno-common behavior.
4805 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
4807 * doc/invoke.texi: Remove leading dash from @opindex entries
4808 throughout the file.
4810 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
4813 * doc/invoke.texi (Option Summary): Add -e and --entry.
4814 (Link Options): Likewise.
4816 2018-11-07 Nathan Sidwell <nathan@acm.org>
4819 * Makefile.in (bitmap.o-warn): Add -Wno-error to unbreak
4820 --disable-checking bootstrap.
4822 2018-11-07 Hafiz Abid Qadeer <abidh@codesourcery.com>
4824 * configure: Regenerated.
4826 2018-11-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
4829 * stor-layout.c (compute_record_mode): Set TYPE_MODE of UNION_TYPE
4830 to the mode of the widest field iff the widest field has mode class
4831 MODE_INT, or MODE_PARTIAL_INT and the union would be passed by
4834 2018-11-07 Nikolai Merinov <n.merinov@inango-systems.com>
4836 * common.opt: Add -Wattribute-warning.
4837 * doc/invoke.texi: Add documentation for -Wno-attribute-warning.
4838 * expr.c (expand_expr_real_1): Add new attribute to warning_at
4839 call to allow user configure behavior of "warning" attribute.
4841 2018-11-07 Segher Boessenkool <segher@kernel.crashing.org>
4843 * target.def: Put @: after every vs., e.g., and i.e. where it is
4844 followed by whitespace.
4845 * doc/extend.texi: Ditto.
4846 * doc/fragments.texi: Ditto.
4847 * doc/gimple.texi: Ditto.
4848 * doc/implement-c.texi: Ditto.
4849 * doc/install.texi: Ditto.
4850 * doc/invoke.texi: Ditto.
4851 * doc/md.texi: Ditto.
4852 * doc/plugins.texi: Ditto.
4853 * doc/rtl.texi: Ditto.
4854 * doc/sourcebuild.texi: Ditto.
4855 * doc/tm.texi.in: Ditto.
4856 * doc/ux.texi: Ditto.
4857 * doc/tm.texi: Regenerate.
4859 2018-11-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4861 * config/arm/arm-cpus.in (ares): New entry.
4862 * config/arm/arm-tables.opt: Regenerate.
4863 * config/arm/arm-tune.md: Likewise.
4864 * doc/invoke.texi (ARM Options): Document ares.
4866 2018-11-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4868 * config/aarch64/aarch64-cores.def (ares): Define.
4869 * config/aarch64/aarch64-tune.md: Regenerate.
4870 * doc/invoke.texi (AArch64 Options): Document ares value for mtune.
4872 2018-11-07 Jan Hubicka <jh@suse.cz>
4874 * tree.c (fld_incomplete_type_of): Clear TREE_ADDRESSABLE.
4875 (free_lang_data_in_decl): Set TREE_ADDRESSABLE for public vars and
4876 functions; clear TYPE_DECL_SUPPRESS_DEBUG and DECL_MODE for
4879 2018-11-07 Richard Biener <rguenther@suse.de>
4881 PR tree-optimization/87914
4882 * tree-vect-loop.c (vect_is_simple_reduction): Improve detection
4884 (vectorizable_reduction): Handle shifts and rotates by dispatching
4885 to vectorizable_shift.
4886 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Handle
4887 in-loop uses of vect_nested_cycle defs. Merge cycle and internal
4889 (vectorizable_shift): Export and handle being called as
4891 (vect_analyze_stmt): Call vectorizable_shift after
4892 vectorizable_reduction.
4893 * tree-vectorizer.h (vectorizable_shift): Declare.
4895 2018-11-07 Jan Hubicka <jh@suse.cz>
4897 * ipa-devirt.c (odr_types_equivalent_p): Expect constants
4898 than const decls in TREE_VALUE of enum.
4899 (dump_type_inheritance_graph): Improve duplicate dumping.
4900 (free_enum_values): New.
4901 (build_type_inheritance_graph): Use it.
4902 * tree.c (free_lang_data_in_type): Free TYPE_VALUES of enums
4903 which are not main variants or not ODR types.
4904 (verify_type_variant): Expect variants to have no TYPE_VALUES.
4906 2018-11-07 Richard Biener <rguenther@suse.de>
4908 * ipa-inline.c (want_inline_small_function_p): Compute
4909 big_speedup_p lazily and last.
4911 2018-11-07 Jan Hubicka <jh@suse.cz>
4913 * tree.c (fld_type_variant_equal_p): Skip TYPE_ALIGN check when
4914 building incomplete variant of complete type.
4915 (fld_type_variant): Do not copy TYPE_ALIGN when building incomplete
4916 variant of complete type.
4918 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
4920 * config/mips/mips.c: Fix typo in documentation of
4921 mips_loongson_ext2_prefetch_cookie.
4922 (mips_option_override): fix brain twister logical.
4923 * config/mips/mips.h: Fix typo in documentation of
4924 ISA_HAS_CTZ_CTO and define pattern.
4925 * config/mips/mips.md (prefetch): Hoist EXT2 above
4927 (prefetch_indexed): Hoist EXT2 above the EXT block.
4929 2018-11-07 Jan Hubicka <jh@suse.cz>
4931 * tree.c (free_lang_data_in_type): Add fld parameter; simplify
4932 return and parameter types of function and method types.
4933 (free_lang_data_in_cgraph): Update.
4935 2018-11-07 Martin Liska <mliska@suse.cz>
4937 PR rtl-optimization/87868
4938 * postreload-gcse.c (eliminate_partially_redundant_load): Set
4939 threshold to max_count if we would overflow.
4940 * profile-count.h: Make max_count a public constant.
4942 2018-11-07 Martin Liska <mliska@suse.cz>
4944 * mem-stats.h: Fix GNU coding style.
4946 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
4948 * config/mips/gs264e.md: New.
4949 * config/mips/mips-cpus.def: Define gs264e.
4950 * config/mips/mips-tables.opt: Regenerate.
4951 * config/mips/mips.c (mips_rtx_cost_data): Add DEFAULT_COSTS for
4953 (mips_issue_rate): Add support for gs264e.
4954 (mips_multipass_dfa_lookahead): Likewise.
4955 * config/mips/mips.h: Define TARGET_GS264E and TUNE_GS264E.
4956 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs264e.
4957 (MIPS_ASE_MSA_SPEC): New.
4958 (BASE_DRIVER_SELF_SPECS): march=gs264e implies -mmsa.
4959 (ISA_HAS_FUSED_MADD4): Enable for TARGET_GS264E.
4960 (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_GS264E.
4961 * config/mips/mips.md: Include gs264e.md.
4962 (processor): Add gs264e.
4963 * config/mips/mips.opt (MSA): Use Mask instead of Var.
4964 * doc/invoke.texi: Add gs264e to supported architectures.
4966 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
4968 * config/mips/gs464e.md: New.
4969 * config/mips/mips-cpus.def: Define gs464e.
4970 * config/mips/mips-tables.opt: Regenerate.
4971 * config/mips/mips.c (mips_rtx_cost_data): Add DEFAULT_COSTS for
4973 (mips_issue_rate): Add support for gs464e.
4974 (mips_multipass_dfa_lookahead): Likewise.
4975 (mips_option_override): Enable MMI, EXT and EXT2 for gs464e.
4976 * config/mips/mips.h: Define TARGET_GS464E and TUNE_GS464E.
4977 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs464e.
4978 (ISA_HAS_FUSED_MADD4): Enable for TARGET_GS464E.
4979 (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_GS464E.
4980 * config/mips/mips.md: Include gs464e.md.
4981 (processor): Add gs464e.
4982 * doc/invoke.texi: Add gs464e to supported architectures.
4984 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
4986 * config/mips/loongson3a.md: Rename to ...
4987 * config/mips/gs464.md: ... here.
4988 * config/mips/mips-cpus.def: Define gs464; Add loongson3a
4989 as an alias of gs464 processor.
4990 * config/mips/mips-tables.opt: Regenerate.
4991 * config/mips/mips.c (mips_issue_rate): Use PROCESSOR_GS464
4992 instead of PROCESSOR_LOONGSON_3A.
4993 (mips_multipass_dfa_lookahead): Use TUNE_GS464 instead of
4995 (mips_option_override): Enable MMI and EXT for gs464.
4996 * config/mips/mips.h: Rename TARGET_LOONGSON_3A to TARGET_GS464;
4997 Rename TUNE_LOONGSON_3A to TUNE_GS464.
4998 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs464.
4999 (ISA_HAS_ODD_SPREG, ISA_AVOID_DIV_HILO, ISA_HAS_FUSED_MADD4,
5000 ISA_HAS_UNFUSED_MADD4): Use TARGET_GS464 instead of
5002 * config/mips/mips.md: Include gs464.md instead of loongson3a.md.
5003 (processor): Add gs464;
5004 * doc/invoke.texi: Add gs464 to supported architectures.
5006 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5008 * config/mips/mips-protos.h
5009 (mips_loongson_ext2_prefetch_cookie): New prototype.
5010 * config/mips/mips.c (mips_loongson_ext2_prefetch_cookie): New.
5011 (mips_option_override): Enable TARGET_LOONGSON_EXT when
5012 TARGET_LOONGSON_EXT2 is true.
5013 * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Define
5014 __mips_loongson_ext2, __mips_loongson_ext_rev=2.
5015 (ISA_HAS_CTZ_CTO): New, true if TARGET_LOONGSON_EXT2.
5016 (ISA_HAS_PREFETCH): Include TARGET_LOONGSON_EXT and
5017 TARGET_LOONGSON_EXT2.
5018 (ASM_SPEC): Add mloongson-ext2 and mno-loongson-ext2.
5019 (define_insn "ctz<mode>2"): New insn pattern.
5020 (define_insn "prefetch"): Include TARGET_LOONGSON_EXT2.
5021 (define_insn "prefetch_indexed_<mode>"): Include
5022 TARGET_LOONGSON_EXT and TARGET_LOONGSON_EXT2.
5023 * config/mips/mips.opt (-mloongson-ext2): Add option.
5024 * gcc/doc/invoke.texi (-mloongson-ext2): Document.
5026 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5028 * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Add
5029 __mips_loongson_ext.
5030 (MIPS_ASE_LOONGSON_EXT_SPEC): New.
5031 (BASE_DRIVER_SELF_SPECS): march=loongson3a implies
5033 (ASM_SPEC): Add mloongson-ext and mno-loongson-ext.
5034 * config/mips/mips.md (mul<mode>3, mul<mode>3_mul3_nohilo,
5035 <u>div<mode>3, <u>mod<mode>3, prefetch): Use TARGET_LOONGSON_EXT
5036 instead of TARGET_LOONGSON_3A.
5037 * config/mips/mips.opt (-mloongson-ext): Add option.
5038 * gcc/doc/invoke.texi (-mloongson-ext): Document.
5040 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5042 * config.gcc (extra_headers): Add loongson-mmiintrin.h.
5043 * config/mips/loongson.md: Move to ...
5044 * config/mips/loongson-mmi.md: here; Adjustment.
5045 * config/mips/loongson.h: Move to ...
5046 State as deprecated. Include loongson-mmiintrin.h for back
5047 compatibility and warning.
5048 * config/mips/loongson-mmiintrin.h: ... here.
5049 * config/mips/mips.c (mips_hard_regno_mode_ok_uncached,
5050 mips_vector_mode_supported_p, AVAIL_NON_MIPS16): Use
5051 TARGET_LOONGSON_MMI instead of TARGET_LOONGSON_VECTORS.
5052 (mips_option_override): Make sure MMI use hard float;
5053 (mips_shift_truncation_mask, mips_expand_vpc_loongson_even_odd,
5054 mips_expand_vpc_loongson_pshufh, mips_expand_vpc_loongson_bcast,
5055 mips_expand_vector_init): Use TARGET_LOONGSON_MMI instead of
5056 TARGET_LOONGSON_VECTORS.
5057 * gcc/config/mips/mips.h (TARGET_LOONGSON_VECTORS): Delete.
5058 (TARGET_CPU_CPP_BUILTINS): Add __mips_loongson_mmi.
5059 (MIPS_ASE_DSP_SPEC, MIPS_ASE_LOONGSON_MMI_SPEC): New.
5060 (BASE_DRIVER_SELF_SPECS): march=loongson2e/2f/3a implies
5062 (SHIFT_COUNT_TRUNCATED): Use TARGET_LOONGSON_MMI instead of
5063 TARGET_LOONGSON_VECTORS.
5064 * gcc/config/mips/mips.md (MOVE64, MOVE128): Use
5065 TARGET_LOONGSON_MMI instead of TARGET_LOONGSON_VECTORS.
5066 (Loongson MMI patterns): Include loongson-mmi.md instead of
5068 * gcc/config/mips/mips.opt (-mloongson-mmi): New option.
5069 * gcc/doc/invoke.texi (-mloongson-mmi): Document.
5071 2018-11-07 Richard Biener <rguenther@suse.de>
5074 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Fixup
5075 BLOCK_ABSTRACT_ORIGIN to be the ultimate origin.
5077 2018-11-07 Alexandre Oliva <aoliva@redhat.com>
5079 PR rtl-optimization/87874
5080 * lra.c (lra_substitute_pseudo): Do not create a subreg for
5083 2018-11-06 Aaron Sawdey <acsawdey@linux.ibm.com>
5085 * config/rs6000/rs6000.md (bswap<mode>2): Force address into register
5086 if not in indexed or indirect form.
5087 (bswap<mode>2_load): Change predicate to indexed_or_indirect_operand.
5088 (bswap<mode>2_store): Ditto.
5090 2018-11-06 Richard Earnshaw <rearnsha@arm.com>
5092 * config/aarch64/aarch64.md (speculation_tracker): Set the mode for
5095 2018-11-06 Richard Biener <rguenther@suse.de>
5097 PR tree-optimization/86850
5098 * vec.h (vec<T, va_heap, vl_ptr>::splice): Check src.length ()
5099 instead of src.m_vec.
5101 2018-11-06 Jan Hubicka <jh@suse.cz>
5103 * tree.c (fld_simplified_type_name): Break out form ...
5104 (free_lang_data_in_type): ... here.
5105 (fld_type_variant_equal_p): Use it.
5107 2018-11-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5109 * config/default-d.c: Include memmodel.h.
5111 * config/sol2-d.c: New file.
5112 * config/t-sol2 (sol2-d.o): New rule.
5113 * config.gcc <*-*-solaris2*>: Set d_target_objs,
5114 target_has_targetdm.
5116 2018-11-06 Jan Hubicka <jh@suse.cz>
5118 * tree.c (fld_type_variant): Also copy alignment; be sure that
5119 new variant is equal.
5121 2018-11-06 Ilya Leoshkevich <iii@linux.ibm.com>
5124 * config/s390/s390.md: Add relative_long attribute.
5126 2018-11-06 Jan Hubicka <jh@suse.cz>
5128 * ipa-pure-const.c (check_decl): Do not test TYPE_NEEDS_CONSTRUCTING.
5129 * lto-streamer-out.c (hash_tree): Do not hash TYPE_NEEDS_CONSTRUCTING.
5130 * tree-streamer-in.c (unpack_ts_type_common_value_fields): Do not
5131 stream TYPE_NEEDS_CONSTRUCTING.
5132 * tree-streamer-out.c (pack_ts_type_common_value_fields): Likewise.
5133 * tree.c (free_lang_data_in_type): Clear TYPE_NEEDS_CONSTRUCTING.
5135 2018-11-06 Richard Biener <rguenther@suse.de>
5137 * tree-vect-slp.c (vect_slp_bb): Move opening of vect_slp_analyze_bb
5139 (vect_slp_analyze_bb_1): ... here to avoid hiding optimized locations.
5141 2018-11-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
5143 * gcc/config/msp430/msp430.h (REG_CLASS_CONTENTS): Add R0 to
5144 REG_CLASS_CONTENTS[GEN_REGS].
5145 (REGNO_REG_CLASS): Return NO_REGS for R2 and R3.
5147 2018-11-06 Jan Hubicka <jh@suse.cz>
5149 * tree.c (fld_simplified_type_of): Clear TYPELESS_STORAGE flag.
5151 2018-11-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5154 * config/sol2.h (ASAN_CC1_SPEC): Define.
5155 (LD_WHOLE_ARCHIVE_OPTION): Define.
5156 (LD_NO_WHOLE_ARCHIVE_OPTION): Define.
5157 (ASAN_REJECT_SPEC): Provide default.
5158 (LIBASAN_EARLY_SPEC): Define.
5159 (LIBTSAN_EARLY_SPEC): Define.
5160 (LIBLSAN_EARLY_SPEC): Define.
5161 * config/i386/sol2.h (CC1_SPEC): Redefine.
5162 (ASAN_REJECT_SPEC): Define.
5164 * config/sparc/sparc.c (sparc_asan_shadow_offset): Declare.
5165 (TARGET_ASAN_SHADOW_OFFSET): Define.
5166 (sparc_asan_shadow_offset): New function.
5167 * config/sparc/sol2.h (CC1_SPEC): Append ASAN_CC1_SPEC.
5168 (ASAN_REJECT_SPEC): Define.
5170 2018-11-06 Jan Hubicka <jh@suse.cz>
5172 * tree.c (fld_type_variant): Copy canonical type.
5173 (fld_incomplete_type_of): Check that canonical types looks sane;
5174 copy canonical type.
5175 (verify_type): Accept when incomplete type has complete canonical type.
5177 2018-11-06 Jan Hubicka <jh@suse.cz>
5179 * tree.c (free_lang_data): Reset overwite_assembler_name,
5180 print_xnode, print_decl, print_type and print_identifier of
5183 2018-11-06 Richard Biener <rguenther@suse.de>
5185 PR tree-optimization/87889
5186 * tree-vect-loop-manip.c (slpeel_duplicate_current_defs_from_edges):
5187 Do nothing if old and new arg are the same
5189 2018-11-06 Andreas Krebbel <krebbel@linux.ibm.com>
5192 * config/s390/s390.md ("*r<noxa>sbg_di_rotl"): Remove mode
5193 attributes for operands 3 and 4.
5195 2018-11-06 Richard Biener <rguenther@suse.de>
5198 * simplify-rtx.c (simplify_binary_operation_1): Add pattern
5199 matching bitfield insertion.
5201 2018-11-06 Alexandre Oliva <aoliva@redhat.com>
5203 * auto-inc-dec.c: Include valtrack.h. Improve comments.
5204 (reg_next_debug_use): New.
5205 (attempt_change): Propagate adjusted expression into affected
5207 (merge_in_block): Track uses in debug insns.
5208 (pass_inc_dec::execute): Allocate and release
5211 2018-11-06 Wei Xiao <wei3.xiao@intel.com>
5213 * config/i386/avx512fintrin.h: Update VFIXUPIMM* intrinsics.
5214 (_mm512_fixupimm_round_pd): Update parameters and builtin.
5215 (_mm512_maskz_fixupimm_round_pd): Ditto.
5216 (_mm512_fixupimm_round_ps): Ditto.
5217 (_mm512_maskz_fixupimm_round_ps): Ditto.
5218 (_mm_fixupimm_round_sd): Ditto.
5219 (_mm_maskz_fixupimm_round_sd): Ditto.
5220 (_mm_fixupimm_round_ss): Ditto.
5221 (_mm_maskz_fixupimm_round_ss): Ditto.
5222 (_mm512_fixupimm_pd): Ditto.
5223 (_mm512_maskz_fixupimm_pd): Ditto.
5224 (_mm512_fixupimm_ps): Ditto.
5225 (_mm512_maskz_fixupimm_ps): Ditto.
5226 (_mm_fixupimm_sd): Ditto.
5227 (_mm_maskz_fixupimm_sd): Ditto.
5228 (_mm_fixupimm_ss): Ditto.
5229 (_mm_maskz_fixupimm_ss): Ditto.
5230 (_mm512_mask_fixupimm_round_pd): Update builtin.
5231 (_mm512_mask_fixupimm_round_ps): Ditto.
5232 (_mm_mask_fixupimm_round_sd): Ditto.
5233 (_mm_mask_fixupimm_round_ss): Ditto.
5234 (_mm512_mask_fixupimm_pd): Ditto.
5235 (_mm512_mask_fixupimm_ps): Ditto.
5236 (_mm_mask_fixupimm_sd): Ditto.
5237 (_mm_mask_fixupimm_ss): Ditto.
5238 * config/i386/avx512vlintrin.h:
5239 (_mm256_fixupimm_pd): Update parameters and builtin.
5240 (_mm256_maskz_fixupimm_pd): Ditto.
5241 (_mm256_fixupimm_ps): Ditto.
5242 (_mm256_maskz_fixupimm_ps): Ditto.
5243 (_mm_fixupimm_pd): Ditto.
5244 (_mm_maskz_fixupimm_pd): Ditto.
5245 (_mm_fixupimm_ps): Ditto.
5246 (_mm_maskz_fixupimm_ps): Ditto.
5247 (_mm256_mask_fixupimm_pd): Update builtin.
5248 (_mm256_mask_fixupimm_ps): Ditto.
5249 (_mm_mask_fixupimm_pd): Ditto.
5250 (_mm_mask_fixupimm_ps): Ditto.
5251 * config/i386/i386-builtin-types.def: Add new types and remove useless ones.
5252 * config/i386/i386-builtin.def: Update builtin definitions.
5253 * config/i386/i386.c: Handle new builtin types and remove useless ones.
5254 * config/i386/sse.md: Update VFIXUPIMM* patterns.
5255 (<avx512>_fixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
5256 (<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
5257 (<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Update.
5258 (avx512f_sfixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
5259 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
5260 (avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Update.
5261 * config/i386/subst.md:
5262 (round_saeonly_sd_mask_operand4): Add new subst_attr.
5263 (round_saeonly_sd_mask_op4): Ditto.
5264 (round_saeonly_expand_operand5): Ditto.
5265 (round_saeonly_expand): Update.
5267 2018-11-05 Max Filippov <jcmvbkbc@gmail.com>
5269 * config/xtensa/uclinux.h (XTENSA_ALWAYS_PIC): Change to 0.
5271 2018-11-05 Segher Boessenkool <segher@kernel.crashing.org>
5273 PR rtl-optimization/87871
5274 * combine.c (make_more_copies): Skip if dest is frame_pointer_rtx.
5276 2018-11-05 Paul Koning <ni1d@arrl.net>
5278 * doc/sourcebuild.texi (target attributes): Document new "inf"
5279 effective target keyword.
5281 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5283 * config/s390/s390.c (s390_register_move_cost): Increase costs for
5284 moves involving the CC reg.
5286 2018-11-05 Richard Biener <rguenther@suse.de>
5288 PR tree-optimization/87873
5289 * tree-ssa-loop-manip.h (split_loop_exit_edge): Add copy_constants_p
5291 * tree-ssa-loop-manip.c (split_loop_exit_edge): Likewise.
5292 * tree-vect-loop.c (vect_transform_loop): When splitting the
5293 loop exit also create forwarder PHIs for constants.
5294 * tree-vect-loop-manip.c (slpeel_duplicate_current_defs_from_edges):
5295 Handle constant to_arg, add extra checking we match up the correct
5298 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5300 * config/s390/s390.md: QImode and HImode for load on condition.
5302 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5304 * config/s390/predicates.md: Fix typo.
5305 * config/s390/s390.md: Allow immediates for load on condition.
5307 2018-11-05 Martin Liska <mliska@suse.cz>
5309 * alloc-pool.h (struct pool_usage): Use SIZE_AMOUNT.
5310 * bitmap.h (struct bitmap_usage): Likewise.
5311 * ggc-common.c (SCALE): Remove.
5313 (struct ggc_usage): Use SIZE_AMOUNT. And update
5315 * ggc-page.c (SCALE): Remove.
5316 (STAT_LABEL): Remove.
5317 (ggc_print_statistics): Use SIZE_AMOUNT.
5318 * gimple.h (SCALE): Remove.
5320 * input.c (ONE_K): Remove.
5323 (STAT_LABEL): Likewise.
5324 (FORMAT_AMOUNT): Likewise.
5325 (dump_line_table_statistics): Use SIZE_AMOUNT.
5326 * mem-stats.h (struct mem_usage): Likewise.
5327 * rtl.c (dump_rtx_statistics): Likewise.
5328 (rtx_alloc_counts): Change type to size_t.
5329 (rtx_alloc_sizes): Likewise.
5330 (rtx_count_cmp): New.
5331 (dump_rtx_statistics): Sort first based on counts.
5332 * tree.c (tree_nodes_cmp): New.
5333 (tree_codes_cmp): New.
5334 (dump_tree_statistics): Sort first based on counts.
5335 * system.h (ONE_K): New.
5337 (SIZE_SCALE): Likewise.
5338 (SIZE_LABEL): Likewise.
5339 (SIZE_AMOUNT): Likewise.
5340 * tree-cfg.c (dump_cfg_stats): Use SIZE_AMOUNT.
5341 * tree-dfa.c (dump_dfa_stats): Likewise.
5342 * tree-phinodes.c (phinodes_print_statistics): Likewise.
5343 * tree-ssanames.c (ssanames_print_statistics): Likewise.
5344 * tree.c (dump_tree_statistics): Likewise.
5345 * vec.c (struct vec_usage): Likewise.
5346 * trans-mem.c (tm_mangle): Enlarge buffer in order to not
5347 trigger a -Werror=format-overflow with
5348 --enable-gather-detailed-stats.
5350 2018-11-05 Martin Liska <mliska@suse.cz>
5352 * mem-stats.h (mem_alloc_description::release_instance_overhead):
5354 * vec.c (struct vec_usage): Register m_element_size.
5355 (vec_prefix::register_overhead): New arguments: elements and
5357 (vec_prefix::release_overhead): Subtract elements.
5358 * vec.h (struct vec_prefix): Change signature.
5359 (va_heap::reserve): Pass proper arguments.
5360 (va_heap::release): Likewise.
5362 2018-11-05 Martin Liska <mliska@suse.cz>
5364 * mem-stats.h (mem_alloc_description::get_list): Fix GNU coding
5368 2018-11-05 Richard Biener <rguenther@suse.de>
5370 * tree-scalar-evolution.h (final_value_replacement_loop): Update
5372 * tree-scalar-evolution.c (final_value_replacement_loop): Return
5373 whether anything was done.
5374 (scev_const_prop): Remove constant propagation part, fold
5376 * tree-ssa-loop.c (pass_scev_cprop::execute): ... here.
5377 (pass_data_scev_cprop): TODO_cleanup_cfg is now done
5380 2018-11-05 Jakub Jelinek <jakub@redhat.com>
5382 PR tree-optimization/87859
5383 * gimple-ssa-store-merging.c (struct merged_store_group): Add
5384 only_constants and first_nonmergeable_order members.
5385 (merged_store_group::merged_store_group): Initialize them.
5386 (merged_store_group::do_merge): Clear only_constants member if
5387 adding something other than INTEGER_CST store.
5388 (imm_store_chain_info::coalesce_immediate_stores): Don't merge
5389 stores with order >= first_nonmergeable_order. Use
5390 merged_store->only_constants instead of always recomputing it.
5391 Set merged_store->first_nonmergeable_order if we've skipped any
5392 stores. Attempt to merge overlapping INTEGER_CST stores that
5393 we would otherwise skip.
5396 * match.pd (X + Y < X): Don't optimize if TYPE_OVERFLOW_SANITIZED.
5398 2018-11-05 Xuepeng Guo <xuepeng.guo@intel.com>
5401 * config/i386/emmintrin.h (__v16qs): New to cope with option
5403 (_mm_cmpeq_epi8): Replace __v16qi with __v16qs.
5404 (_mm_cmplt_epi8): Likewise.
5405 (_mm_cmpgt_epi8): Likewise.
5407 2018-11-05 Richard Biener <rguenther@suse.de>
5409 PR rtl-optimization/87852
5410 * fwprop.c (use_killed_between): Only consider single-defs of the
5411 use whose definition statement dominates the use.
5413 2018-11-05 Martin Liska <mliska@suse.cz>
5416 * doc/invoke.texi: Remove options that are
5417 not disabled with -Os.
5419 2018-11-05 Martin Liska <mliska@suse.cz>
5422 * doc/extend.texi: Update constrain about the last argument
5423 of __builtin_expect_with_probability.
5425 2018-11-05 Martin Liska <mliska@suse.cz>
5428 * predict.c (expr_expected_value_1): Verify
5429 that last argument is a real constants and emit
5432 2018-11-05 Martin Liska <mliska@suse.cz>
5434 PR gcov-profile/77698
5435 * ipa-profile.c (ipa_profile): Adjust hotness threshold
5438 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
5440 PR tree-optimization/86572
5441 * builtins.c (c_strlen): Handle negative offsets in a safe way.
5443 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
5445 PR tree-optimization/87672
5446 * gimple-fold.c (gimple_fold_builtin_stxcpy_chk): Gimplify.
5447 * tree-ssa-strlen.c (handle_builtin_strcat): Adjust object size.
5449 2018-11-04 Uros Bizjak <ubizjak@gmail.com>
5452 * cfgexpand.c (pass_expand::execute): Move the call to
5453 finish_eh_generation in front of the call to expand_stack_alignment.
5455 2018-11-04 Venkataramanan Kumar <venkataramanan.kumar@amd.com>
5457 * common/config/i386/i386-common.c (processor_alias_table): Add
5459 * config.gcc (i[34567]86-*-linux* | ...): Add znver2.
5460 (case ${target}): Add znver2.
5461 * config/i386/driver-i386.c: (host_detect_local_cpu): Let
5462 -march=native recognize znver2 processors.
5463 * config/i386/i386-c.c (ix86_target_macros_internal): Add znver2.
5464 * config/i386/i386.c (m_znver2): New definition.
5465 (m_ZNVER): New definition.
5466 (m_AMD_MULTIPLE): Includes m_znver2.
5467 (processor_cost_table): Add znver2 entry.
5468 (processor_target_table): Add znver2 entry.
5469 (get_builtin_code_for_version): Set priority for
5471 (processor_model): Add M_AMDFAM17H_ZNVER2.
5472 (arch_names_table): Ditto.
5473 (ix86_reassociation_width): Include znver2.
5474 * config/i386/i386.h (TARGET_znver2): New definition.
5475 (struct ix86_size_cost): Add TARGET_ZNVER2.
5476 (enum processor_type): Add PROCESSOR_ZNVER2.
5477 * config/i386/i386.md (define_attr "cpu"): Add znver2.
5478 * config/i386/x86-tune-costs.h: (processor_costs) Add znver2 costs.
5479 * config/i386/x86-tune-sched.c: (ix86_issue_rate): Add znver2.
5480 (ix86_adjust_cost): Add znver2.
5481 * config/i386/x86-tune.def: Replace m_ZNVER1 by m_ZNVER.
5482 * gcc/doc/extend.texi: Add details about znver2.
5483 * gcc/doc/invoke.texi: Add details about znver2.
5485 2018-11-03 Sandra Loosemore <sandra@codesourcery.com>
5489 * config/nios2/nios2.c (nios2_rtx_costs): Recognize <mul>sidi3
5492 2018-11-02 Aaron Sawdey <acsawdey@linux.ibm.com>
5494 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Pay
5495 attention to TARGET_AVOID_XFORM and BYTES_BIG_ENDIAN.
5497 2018-11-02 Richard Earnshaw <rearnsha@arm.com>
5499 * config/aarch64/aarch64.c ((aarch64_override_options): Disable
5500 shrink-wrapping when -mtrack-speculation.
5502 2018-11-02 Richard Biener <rguenther@suse.de>
5504 * tree-ssa-coalesce.c (struct coalesce_list): Add obstack member.
5505 (pop_cost_one_pair): Do not free pair.
5506 (pop_best_coalesce): Likewise.
5507 (create_coalesce_list): Initialize obstack.
5508 (delete_coalesce_list): Free obstack.
5509 (find_coalesce_pair): Obstack-allocate coalesce pairs.
5510 (add_cost_one_coalesce): Likewise.
5511 (struct live_track): Remove bitmap pointer indirections.
5512 (new_live_track): Adjust.
5513 (delete_live_track): Likewise.
5514 (live_track_remove_partition): Likewise.
5515 (live_track_add_partition): Likewise.
5516 (live_track_live_p): Likewise.
5517 (live_track_process_def): Likewise.
5518 (live_track_clear_base_vars): Likewise.
5520 2018-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5522 * configure.ac (gcc_cv_as_sparc_register_op): Remove.
5523 * configure: Regenerate.
5524 * config.in: Regenerate.
5525 * config/sparc/sparc.c (sparc_output_scratch_registers): Remove
5526 HAVE_AS_REGISTER_PSEUDO_OP guard.
5527 * config/sparc/sparc.h (ASM_ARCH64_SPEC): Remove
5528 !HAVE_AS_REGISTER_PSEUDO_OP support.
5529 (ASM_DECLARE_REGISTER_GLOBAL): Remove HAVE_AS_REGISTER_PSEUDO_OP
5532 2018-11-02 Richard Biener <rguenther@suse.de>
5534 * dwarf2out.c (build_abbrev_table): Guard lookup_external_ref call
5537 2018-11-02 Richard Biener <rguenther@suse.de>
5539 PR tree-optimization/87776
5540 * tree-ssa-sccvn.c (do_rpo_vn): Do not mark backedges
5541 executable when iterating but running into rpo-vn-max-loop-depth
5542 and not eliding the iteration.
5544 2018-11-30 Jan Hubicka <jh@suse.cz>
5546 * tree.c (free_lang_data_in_decl): Free TREE_TYPE and alignment of
5549 2018-11-01 Aaron Sawdey <acsawdey@linux.ibm.com>
5551 * config/rs6000/rs6000-protos.h (rs6000_address_for_fpconvert): Remove
5553 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem):
5554 Combine with rs6000_address_for_fpconvert.
5555 (rs6000_address_for_fpconvert): Combine with
5556 rs6000_force_indexed_or_indirect_mem.
5557 (rs6000_expand_vector_init): Change function call from
5558 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
5559 * config/rs6000/rs6000.md (floatsi<mode>2_lfiwax): Change call from
5560 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
5561 (floatsi<mode>2_lfiwax_mem): Ditto.
5562 (floatunssi<mode>2_lfiwzx): Ditto.
5563 (floatunssi<mode>2_lfiwzx_mem): Ditto.
5564 (float<QHI:mode><FP_ISA3:mode>2): Ditto.
5565 (floatuns<QHI:mode><FP_ISA3:mode>2): Ditto.
5566 (fix_trunc<mode>si2_stfiwx): Ditto.
5567 (fixuns_trunc<mode>si2_stfiwx): Ditto.
5568 (float_<mode>si2_hw): Ditto.
5569 (floatuns_<mode>si2_hw): Ditto.
5570 * config/rs6000/vsx.md (*vsx_extract_si): Ditto.
5571 (vsx_splat_<mode>): Ditto.
5573 2018-11-01 Joseph Myers <joseph@codesourcery.com>
5575 * configure.ac (gcc_cv_as_ia64_ltoffx_ldxmov_relocs): Add newline
5576 at end of assembler input text.
5577 * configure: Regenerate.
5579 2018-11-01 Jakub Jelinek <jakub@redhat.com>
5581 PR tree-optimization/87826
5582 * gimple-ssa-store-merging.c (do_shift_rotate): Punt if count is
5583 negative or larger or equal to type's precision.
5585 2018-10-31 Alexandre Oliva <aoliva@redhat.com>
5587 * opts.c (default_options_table): Do not enable
5588 OPT_fdelayed_branch at -Og.
5589 * doc/invoke.texi (-fdelayed-branch): Document it.
5591 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
5593 * optabs-libfuncs.c (build_libfunc_function_visibility):
5594 New, split out from...
5595 (build_libfunc_function): ... here.
5596 (init_one_libfunc_visibility): New, split out from ...
5597 (init_one_libfunc): ... here.
5599 * config/aarch64/atomics.md (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse):
5600 scratch register need not be early-clobber. Document the reason
5601 why we cannot use ST<OP>.
5603 2018-10-31 Joseph Myers <joseph@codesourcery.com>
5606 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. Use single
5607 line for second argument of AC_DEFINE_UNQUOTED.
5608 * doc/install.texi (Tools/packages necessary for modifying GCC):
5609 Update to autoconf 2.69 and automake 1.15.1.
5610 * aclocal.m4, config.in, configure: Regenerate.
5612 2018-10-31 Pat Haugen <pthaugen@us.ibm.com>
5614 * tree-ssa-loop-ivcanon.c (try_peel_loop): Fix typo and remove dead
5617 2018-10-31 Martin Liska <mliska@suse.cz>
5620 * common/config/aarch64/aarch64-common.c (aarch64_parse_extension):
5621 Add new argument invalid_extension.
5622 (aarch64_get_all_extension_candidates): New function.
5623 (aarch64_rewrite_selected_cpu): Add NULL to function call.
5624 * config/aarch64/aarch64-protos.h (aarch64_parse_extension): Add
5626 (aarch64_get_all_extension_candidates): New function.
5627 * config/aarch64/aarch64.c (aarch64_parse_arch): Add new
5628 argument invalid_extension.
5629 (aarch64_parse_cpu): Likewise.
5630 (aarch64_print_hint_for_extensions): New function.
5631 (aarch64_validate_mcpu): Provide hint about invalid extension.
5632 (aarch64_validate_march): Likewise.
5633 (aarch64_handle_attr_arch): Pass new argument.
5634 (aarch64_handle_attr_cpu): Provide hint about invalid extension.
5635 (aarch64_handle_attr_isa_flags): Likewise.
5637 2018-10-31 Richard Biener <rguenther@suse.de>
5641 * tree-outof-ssa.c (insert_backedge_copies): Restrict
5642 copy generation to useful cases. Place the copy before
5643 the definition of the backedge value when possible.
5645 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
5647 * config/arc/arc-arch.h (ARC_TUNE_ARC7XX): New tune value.
5648 * config/arc/arc.c (arc_active_insn): New function.
5649 (check_store_cacheline_hazard): Likewise.
5650 (workaround_arc_anomaly): Use check_store_cacheline_hazard.
5651 (arc_override_options): Disable delay slot scheduler for older
5653 (arc_store_addr_hazard_p): New implementation, old one renamed to
5655 (arc_store_addr_hazard_internal_p): Renamed.
5656 (arc_reorg): Don't combine into brcc instructions which are part
5657 of hardware hazard solution.
5658 * config/arc/arc.md (attr tune): Consider new arc7xx tune value.
5659 (tune_arc700): Likewise.
5660 * config/arc/arc.opt (arc7xx): New tune value.
5661 * config/arc/arc700.md: Improve A7 scheduler.
5663 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
5665 * config/arc/arc.c (arc_override_options): Remove
5666 TARGET_COMPACT_CASESI.
5667 * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Update.
5668 (CASE_VECTOR_MODE): Likewise.
5669 (CASE_VECTOR_PC_RELATIVE): Likewise.
5670 (CASE_VECTOR_SHORTEN_MODE): Likewise.
5671 (CASE_VECTOR_SHORTEN_MODE1): Delete.
5672 (ADDR_VEC_ALIGN): Update.
5673 (ASM_OUTPUT_CASE_LABEL): Undefine.
5674 (ASM_OUTPUT_BEFORE_CASE_LABEL): Undefine.
5675 (TARGET_BI_BIH): Define.
5676 (DEFAULT_BRANCH_INDEX): Likewise.
5677 * config/arc/arc.md (casesi): Rework to accept BI/BIH
5678 instructions, remove compact_casesi use case.
5679 (casesi_compact_jump): Remove.
5680 (casesi_dispatch): New pattern.
5681 * config/arc/arc.opt: Add mbranch-index option. Deprecate
5682 compact_casesi option.
5683 * doc/invoke.texi: Document mbranch-index option.
5685 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
5687 * config/arc/arc.c (arc_get_tp): Remove function.
5688 (arc_emit_call_tls_get_addr): Likewise.
5689 (arc_call_tls_get_addr): New function.
5690 (arc_legitimize_tls_address): Make use of arc_call_tls_get_addr.
5691 * config/arc/arc.md (tls_load_tp_soft): Remove.
5692 (tls_gd_get_addr): Likewise.
5694 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
5696 * config/arc/arc.md (mulsi3): Remove call to mulsi_600_lib.
5697 (mulsi3_600_lib): Remove pattern.
5698 (umulsi3_highpart_600_lib_le): Likewise.
5699 (umulsi3_highpart): Remove call to umulsi3_highpart_600_lib_le.
5700 (umulsidi3): Remove call to umulsidi3_600_lib.
5701 (umulsidi3_600_lib): Remove pattern.
5702 (peephole2): Remove peephole using the above deprecated patterns.
5704 2018-10-31 Thomas Preud'homme <thomas.preudhomme@linaro.org>
5707 * config/arm/arm.c (arm_option_check_internal): Disable the combined
5708 use of -mslow-flash-data and -mword-relocations.
5709 (arm_option_override): Enable -mword-relocations if -fpic or -fPIC.
5710 * config/arm/arm.md (SYMBOL_REF MOVT splitter): Stop checking for
5712 * doc/invoke.texi (-mword-relocations): Mention conflict with
5714 (-mslow-flash-data): Reciprocally.
5716 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
5718 * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Force
5719 16-byte modes held in GP registers to use an even regno.
5721 * config/aarch64/aarch64.c (aarch64_emit_bic): Remove.
5722 (aarch64_atomic_ldop_supported_p): Remove.
5723 (aarch64_gen_atomic_ldop): Remove.
5724 * config/aarch64/atomic.md (atomic_<atomic_optab><ALLI>):
5725 Fully expand LSE operations here.
5726 (atomic_fetch_<atomic_optab><ALLI>): Likewise.
5727 (atomic_<atomic_optab>_fetch<ALLI>): Likewise.
5728 (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse): Drop atomic_op iterator
5729 and use ATOMIC_LDOP instead; use register_operand for the input;
5730 drop the split and emit insns directly.
5731 (aarch64_atomic_fetch_<ATOMIC_LDOP><ALLI>_lse): Likewise.
5732 (aarch64_atomic_<atomic_op>_fetch<ALLI>_lse): Remove.
5733 (@aarch64_atomic_load<ATOMIC_LDOP><ALLI>): Remove.
5735 * config/aarch64/aarch64.c (aarch64_emit_atomic_swap): Remove.
5736 (aarch64_gen_atomic_ldop): Don't call it.
5737 * config/aarch64/atomics.md (atomic_exchange<ALLI>):
5738 Use aarch64_reg_or_zero.
5739 (aarch64_atomic_exchange<ALLI>): Likewise.
5740 (aarch64_atomic_exchange<ALLI>_lse): Remove split; remove & from
5741 operand 0; use aarch64_reg_or_zero for input; merge ...
5742 (@aarch64_atomic_swp<ALLI>): ... this and remove.
5744 * config/aarch64/aarch64.c (aarch64_gen_compare_reg_maybe_ze): New.
5745 (aarch64_split_compare_and_swap): Use it.
5746 (aarch64_expand_compare_and_swap): Likewise. Remove convert_modes;
5747 test oldval against the proper predicate.
5748 * config/aarch64/atomics.md (@atomic_compare_and_swap<ALLI>):
5749 Use nonmemory_operand for expected.
5750 (cas_short_expected_pred): New.
5751 (@aarch64_compare_and_swap<SHORT>): Use it; use "rn" not "rI" to match.
5752 (@aarch64_compare_and_swap<GPI>): Use "rn" not "rI" for expected.
5753 * config/aarch64/predicates.md (aarch64_plushi_immediate): New.
5754 (aarch64_plushi_operand): New.
5756 * config/aarch64/aarch64.c (aarch64_expand_compare_and_swap):
5757 Force oldval into the rval register for TARGET_LSE; emit the compare
5758 during initial expansion so that it may be deleted if unused.
5759 (aarch64_gen_atomic_cas): Remove.
5760 * config/aarch64/atomics.md (@aarch64_compare_and_swap<SHORT>_lse):
5761 Change =&r to +r for operand 0; use match_dup for operand 2;
5762 remove is_weak and mod_f operands as unused. Drop the split
5764 (@aarch64_atomic_cas<SHORT>): ... this pattern's output; remove.
5765 (@aarch64_compare_and_swap<GPI>_lse): Similarly.
5766 (@aarch64_atomic_cas<GPI>): Similarly.
5768 2018-10-31 Richard Biener <rguenther@suse.de>
5770 * tree-eh.c (replace_trapping_overflow): Simplify ABS_EXPR case
5773 2018-10-31 Sameera Deshpande <sameera.deshpande@linaro.org>
5775 * config/aarch64/aarch64-cores.def (saphira): Use saphira pipeline.
5776 * config/aarch64/aarch64.md: Include saphira.md
5777 * config/aarch64/saphira.md: New file for pipeline description.
5779 2018-10-30 Martin Sebor <msebor@redhat.com>
5782 * gimple-ssa-sprintf.c (format_directive): Use %G to include
5784 (sprintf_dom_walker::compute_format_length):
5785 Avoid setting POSUNDER4K here.
5786 (get_destination_size): Handle null argument values.
5787 (get_user_idx_format): New function.
5788 (sprintf_dom_walker::handle_gimple_call): Handle all printf-like
5789 functions, including user-defined with attribute format printf.
5790 Use %G to include inlining context.
5791 Set POSUNDER4K here.
5793 2018-10-30 Jan Hubicka <jh@suse.cz>
5795 * params.def (lto-partitions): Bump from 32 to 128.
5797 2018-10-30 Jan Hubicka <jh@suse.cz>
5800 (free_lang_data_d, add_tree_to_fld_list, fld_worklist_push): Move
5802 (free_lang_data_in_type): Forward declare.
5803 (fld_type_variant_equal_p): New function.
5804 (fld_type_variant): New function
5805 (fld_incomplete_types): New hash.
5806 (fld_incomplete_type_of): New function
5807 (fld_simplfied-type): New function.
5808 (free_lang_data_in_decl): Add fld parameter; simplify type of FIELD_DECL
5809 (free_lang_data): Allocate and free fld_incomplete_type; update call
5810 of free_lang_data_in_decl.
5812 2018-10-30 Eric Botcazou <ebotcazou@adacore.com>
5814 * gcov.c (output_lines): Remove duplicate line.
5816 2018-10-30 Aaron Sawdey <acsawdey@linux.ibm.com>
5818 * config/rs6000/rs6000.md (bswapdi2): Force address into register
5819 if not in indexed or indirect form.
5820 (bswapdi2_load): Change predicate to indexed_or_indirect_operand.
5821 (bswapdi2_store): Ditto.
5822 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem): New
5824 * config/rs6000/rs6000-protos.h (rs6000_force_indexed_or_indirect_mem):
5825 Prototype for helper function.
5827 2018-10-30 Martin Sebor <msebor@redhat.com>
5829 * doc/extend.texi (optimize): Clarify/expand attribute documentation.
5830 (target, pragma GCC optimize, pragma GCC target): Ditto.
5832 2018-10-30 Jonathan Wakely <jwakely@redhat.com>
5834 * doc/extend.texi: Fix prototype and description of
5835 __builtin_expect_with_probability.
5837 2018-10-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
5839 * cgraph.h (clone_function_name_1): Replaced by new
5840 clone_function_name_numbered that takes name as string; for
5841 privatize_symbol_name_1 use only.
5842 (clone_function_name): Renamed to
5843 clone_function_name_numbered to be explicit about numbering.
5844 (clone_function_name): New two-argument function that does
5845 not number its output.
5846 (clone_function_name): New three-argument function that
5847 takes a number to append to its output.
5848 * cgraphclones.c (duplicate_thunk_for_node):
5849 (clone_function_name_1): Renamed.
5850 (clone_function_name_numbered): Two new functions.
5851 (clone_function_name): Improved documentation.
5852 (cgraph_node::create_virtual_clone): Use clone_function_name_numbered.
5853 * config/rs6000/rs6000.c (make_resolver_func): Ditto.
5854 * final.c (final_scan_insn_1): Use the new clone_function_name
5856 * multiple_target.c (create_dispatcher_calls): Ditto.
5857 (create_target_clone): Ditto.
5858 * omp-expand.c (grid_expand_target_grid_body): Ditto.
5859 * omp-low.c (create_omp_child_function_name): Ditto.
5860 * omp-simd-clone.c (simd_clone_create): Ditto.
5861 * symtab.c (simd_symtab_node::noninterposable_alias): Use the
5862 new clone_function_name without numbering.
5864 2018-10-30 Richard Earnshaw <rearnsha@arm.com>
5866 * alloc-pool.h (base_pool_allocator <TBlockAllocator>::initialize):
5867 Assert that the allocation size is not zero.
5869 2018-10-30 Richard Biener <rguenther@suse.de>
5871 PR tree-optimization/87800
5872 * tree-vect-slp.c (vect_build_slp_tree_2): Reject any
5873 non-induction or reduction PHIs.
5875 2018-10-30 Sameera Deshpande <sameera.deshpande@linaro.org
5877 * config/aarch64/falkor-tag-collision-avoidance.c
5878 (execute_tag_collision_avoidance): Call df_note_add_problem.
5880 2018-10-30 Martin Liska <mliska@suse.cz>
5882 * doc/extend.texi: Fix typo in documentation
5883 of __builtin_expect_with_probability.
5885 2018-10-29 David Malcolm <dmalcolm@redhat.com>
5888 * input.c (get_substring_ranges_for_loc): Detect if
5889 linemap_resolve_location gives us a NULL map, and reject
5892 2018-10-29 Iain Buclaw <ibuclaw@gdcproject.org>
5894 * config.gcc (xstormy16-*-elf): Set tm_d_file.
5896 2018-10-29 David Malcolm <dmalcolm@redhat.com>
5897 Martin Sebor <msebor@redhat.com>
5898 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
5900 * doc/ux.texi (Quoting): New subsection, adapted from material at
5901 https://gcc.gnu.org/wiki/DiagnosticsGuidelines written by
5902 MartinSebor and ManuelLopezIbanez.
5903 (Fix-it hints): Note that fix-it hints shouldn't be marked for
5906 2018-10-29 Kugan Vivekanandarajah <kuganv@linaro.org>
5909 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Fix niter
5912 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
5914 * gcc.target/powerpc/ssse3-check.h: Remove inaccurate comment.
5916 2018-10-29 Paul Koning <ni1d@arrl.net>
5918 * doc/rtl.texi (CONST_WIDE_INT_ELT): Give correct macro name.
5920 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
5922 * gcc/config/rs6000/mmintrin.h (_mm_packs_pi16, _mm_packs_pi32,
5923 _mm_packs_pu16, _mm_unpackhi_pi8, _mm_unpacklo_pi8, _mm_add_pi8,
5924 _mm_add_pi16, _mm_add_pi32, _mm_sub_pi8, _mm_sub_pi16, _mm_sub_pi32,
5925 _mm_cmpgt_pi8, _mm_cmpeq_pi16, _mm_cmpgt_pi16, _mm_cmpeq_pi32,
5926 _mm_cmpgt_pi32, _mm_adds_pi8, _mm_adds_pi16, _mm_adds_pu8,
5927 _mm_adds_pu16, _mm_subs_pi8, _mm_subs_pi16, _mm_subs_pu8,
5928 _mm_subs_pu16, _mm_madd_pi16, _mm_mulhi_pi16, _mm_mullo_pi16,
5929 _mm_sll_pi16, _mm_sra_pi16, _mm_srl_pi16, _mm_set1_pi16, _mm_set1_pi8):
5930 Change 'vector' to '__vector'.
5931 * gcc/config/rs6000/xmmintrin.h (_mm_cvtps_pi32, _mm_cvttps_pi32,
5932 _mm_cvtps_pi16, _mm_cvtps_pi8, _mm_max_pi16, _mm_max_pu8, _mm_min_pi16,
5933 _mm_min_pu8, _mm_mulhi_pu16, _mm_shuffle_pi16, _mm_avg_pu8,
5934 _mm_avg_pu16): Likewise. And, whitespace corrections.
5936 2018-10-29 Richard Biener <rguenther@suse.de>
5938 PR tree-optimization/87785
5939 * tree-vect-slp.c (vect_gather_slp_loads): Only gather
5942 2018-10-29 Olivier Hainque <hainque@adacore.com>
5944 * VXWORKS_NET_LIBS_RTP: New macro, network part of VXWORKS_LIBS_RTP.
5946 2018-10-29 Olivier Hainque <hainque@adacore.com>
5948 * config/vxworks.h (VXWORKS_PERSONALITY): New VxWorks
5949 ports configuration macro, defaults to "gnu".
5950 (VXWORKS_OS_CPP_BUILTINS): Use it. Feed TOOL and
5951 TOOL_FAMILY instead of _VX_TOOL/_VXTOOL_FAMILY.
5953 2018-10-29 Olivier Hainque <hainque@adacore.com>
5955 * config/vxworks.h (CLEAR_INSN_CACHE): #undef before #define.
5957 2018-10-29 Richard Biener <rguenther@suse.de>
5959 PR tree-optimization/87790
5960 * tree-vect-slp.c (vect_mark_slp_stmts): Simplify.
5961 (vect_make_slp_decision): Adjust.
5962 (vect_slp_analyze_bb_1): Likewise.
5963 (vect_detect_hybrid_slp_stmts): Properly union SLP type over
5966 2018-10-29 Richard Biener <rguenther@suse.de>
5968 PR tree-optimization/87785
5969 * tree-vect-slp.c (vect_build_slp_tree_2): Remove loads argument
5971 (vect_build_slp_tree): Likewise.
5972 (vect_gather_slp_loads): New function.
5973 (vect_analyze_slp_instance): Gather loads separately from the
5976 2018-10-29 Martin Liska <mliska@suse.cz>
5978 * Makefile.in: Make dependency to json.o.
5979 * doc/gcov.texi: Document new JSON format, remove
5980 old intermediate format documentation.
5981 * gcov.c (struct function_info): Come up with m_name and
5983 (function_info::function_info): Initialize it.
5984 (function_info::~function_info): Release it.
5985 (main): Rename flag_intermediate_format to flag_json_format.
5986 (print_usage): Describe --json-format.
5987 (process_args): Set flag_json_format.
5988 (output_intermediate_line): Remove.
5989 (output_intermediate_json_line): Likewise.
5990 (get_gcov_intermediate_filename): Return new extension
5992 (output_intermediate_file): Implement JSON emission.
5993 (output_json_intermediate_file): Implement JSON emission.
5994 (generate_results): Use ::get_name for function name.
5995 Handle JSON output file.
5996 (read_graph_file): Use ::get_name instead of cplus_demangle.
5997 (read_count_file): Likewise.
5998 (solve_flow_graph): Likewise.
5999 (add_line_counts): Likewise.
6000 (accumulate_line_counts): Use new flag_json_format.
6001 (output_function_details): Use ::get_name instead of cplus_demangle.
6002 (output_lines): Likewise.
6003 * json.cc (test_writing_literals): Add new tests.
6004 * json.h (class literal): Add new boolean constructor.
6006 2018-10-29 Segher Boessenkool <segher@kernel.crashing.org>
6008 PR rtl-optimization/87701
6009 PR rtl-optimization/87780
6010 * combine.c (make_more_copies): Rewrite.
6012 2018-10-28 Kugan Vivekanandarajah <kuganv@linaro.org>
6014 * doc/generic.texi (ABSU_EXPR): Document.
6015 * match.pd (absu(x)*absu(x) -> x*x): Handle.
6016 (absu(absu(X)) -> absu(X)): Likewise.
6017 (absu(-X) -> absu(X)): Likewise.
6018 (absu(X) where X is nonnegative -> X): Likewise.
6020 2018-10-28 Iain Buclaw <ibuclaw@gdcproject.org>
6022 * Makefile.in (tm_d_file_list, tm_d_include_list): New variables.
6023 (TM_D_H, D_TARGET_DEF, D_TARGET_H, D_TARGET_OBJS): New variables.
6024 (tm_d.h, cs-tm_d.h, default-d.o): New rules.
6025 (d/d-target-hooks-def.h, s-d-target-hooks-def-h): New rules.
6026 (s-tm-texi): Also check timestamp on d-target.def.
6027 (generated_files): Add TM_D_H and d-target-hooks-def.h.
6028 (build/genhooks.o): Also depend on D_TARGET_DEF.
6029 * config.gcc (tm_d_file, d_target_objs, target_has_targetdm): New
6031 * config/aarch64/aarch64-d.c: New file.
6032 * config/aarch64/aarch64-linux.h (GNU_USER_TARGET_D_CRITSEC_SIZE):
6034 * config/aarch64/aarch64-protos.h (aarch64_d_target_versions): New
6036 * config/aarch64/aarch64.h (TARGET_D_CPU_VERSIONS): Define.
6037 * config/aarch64/t-aarch64 (aarch64-d.o): New rule.
6038 * config/arm/arm-d.c: New file.
6039 * config/arm/arm-protos.h (arm_d_target_versions): New prototype.
6040 * config/arm/arm.h (TARGET_D_CPU_VERSIONS): Define.
6041 * config/arm/linux-eabi.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6042 * config/arm/t-arm (arm-d.o): New rule.
6043 * config/default-d.c: New file.
6044 * config/glibc-d.c: New file.
6045 * config/gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6046 * config/i386/i386-d.c: New file.
6047 * config/i386/i386-protos.h (ix86_d_target_versions): New prototype.
6048 * config/i386/i386.h (TARGET_D_CPU_VERSIONS): Define.
6049 * config/i386/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6050 (GNU_USER_TARGET_D_CRITSEC_SIZE): Define.
6051 * config/i386/t-i386 (i386-d.o): New rule.
6052 * config/kfreebsd-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6053 * config/kopensolaris-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6054 * config/linux-android.h (ANDROID_TARGET_D_OS_VERSIONS): Define.
6055 * config/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6056 * config/mips/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6057 * config/mips/mips-d.c: New file.
6058 * config/mips/mips-protos.h (mips_d_target_versions): New prototype.
6059 * config/mips/mips.h (TARGET_D_CPU_VERSIONS): Define.
6060 * config/mips/t-mips (mips-d.o): New rule.
6061 * config/powerpcspe/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6062 * config/powerpcspe/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6063 * config/powerpcspe/powerpcspe-d.c: New file.
6064 * config/powerpcspe/powerpcspe-protos.h (rs6000_d_target_versions):
6066 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
6067 Support GNU D by using 0 as the language type.
6068 * config/powerpcspe/powerpcspe.h (TARGET_D_CPU_VERSIONS): Define.
6069 * config/powerpcspe/t-powerpcspe (powerpcspe-d.o): New rule.
6070 * config/riscv/riscv-d.c: New file.
6071 * config/riscv/riscv-protos.h (riscv_d_target_versions): New
6073 * config/riscv/riscv.h (TARGET_D_CPU_VERSIONS): Define.
6074 * config/riscv/t-riscv (riscv-d.o): New rule.
6075 * config/rs6000/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6076 * config/rs6000/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6077 * config/rs6000/rs6000-d.c: New file.
6078 * config/rs6000/rs6000-protos.h (rs6000_d_target_versions): New
6080 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
6081 Support GNU D by using 0 as the language type.
6082 * config/rs6000/rs6000.h (TARGET_D_CPU_VERSIONS): Define.
6083 * config/rs6000/t-rs6000 (rs6000-d.o): New rule.
6084 * config/s390/s390-d.c: New file.
6085 * config/s390/s390-protos.h (s390_d_target_versions): New prototype.
6086 * config/s390/s390.h (TARGET_D_CPU_VERSIONS): Define.
6087 * config/s390/t-s390 (s390-d.o): New rule.
6088 * config/sparc/sparc-d.c: New file.
6089 * config/sparc/sparc-protos.h (sparc_d_target_versions): New
6091 * config/sparc/sparc.h (TARGET_D_CPU_VERSIONS): Define.
6092 * config/sparc/t-sparc (sparc-d.o): New rule.
6093 * config/t-glibc (glibc-d.o): New rule.
6094 * configure: Regenerated.
6095 * configure.ac (tm_d_file): New variable.
6096 (tm_d_file_list, tm_d_include_list, d_target_objs): Add substitutes.
6097 * doc/contrib.texi (Contributors): Add self for the D frontend.
6098 * doc/frontends.texi (G++ and GCC): Mention D as a supported language.
6099 * doc/install.texi (Configuration): Mention libphobos as an option for
6100 --enable-shared. Mention d as an option for --enable-languages.
6101 (Testing): Mention check-d as a target.
6102 * doc/invoke.texi (Overall Options): Mention .d, .dd, and .di as file
6103 name suffixes. Mention d as a -x option.
6104 * doc/sourcebuild.texi (Top Level): Mention libphobos.
6105 * doc/standards.texi (Standards): Add section on D language.
6106 * doc/tm.texi: Regenerated.
6107 * doc/tm.texi.in: Add @node for D language and ABI, and @hook for
6108 TARGET_CPU_VERSIONS, TARGET_D_OS_VERSIONS, and TARGET_D_CRITSEC_SIZE.
6109 * dwarf2out.c (is_dlang): New function.
6110 (gen_compile_unit_die): Use DW_LANG_D for D.
6111 (declare_in_namespace): Return module die for D, instead of adding
6112 extra declarations into the namespace.
6113 (gen_namespace_die): Generate DW_TAG_module for D.
6114 (gen_decl_die): Handle CONST_DECLSs for D.
6115 (dwarf2out_decl): Likewise.
6116 (prune_unused_types_walk_local_classes): Handle DW_tag_interface_type.
6117 (prune_unused_types_walk): Handle DW_tag_interface_type same as other
6118 kinds of aggregates.
6119 * gcc.c (default_compilers): Add entries for .d, .dd and .di.
6120 * genhooks.c: Include d/d-target.def.
6122 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
6125 * config/rs6000/darwin.h (STACK_BOUNDARY): New.
6126 (RS6000_STARTING_FRAME_OFFSET): Adjust to preserve 16byte alignment.
6127 (STACK_DYNAMIC_OFFSET): Likewise.
6129 2018-10-27 Sandra Loosemore <sandra@codesourcery.com>
6132 * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Fix
6135 2018-10-26 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
6137 * doc/extend.texi (PowerPC builtins): Fix __builtin_unpack_ibm128
6138 return type and other typos.
6140 2018-10-26 Aaron Sawdey <acsawdey@linux.ibm.com>
6142 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Change to
6143 a shorter sequence with fewer branches.
6144 (emit_final_str_compare_gpr): Ditto.
6146 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6148 * config/rs6000/tmmintrin.h: New file.
6149 * config.gcc (powerpc*-*-*): Add tmmintrin.h to extra_headers.
6151 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6153 * config/rs6000/mmintrin.h: Enable 32bit compilation.
6154 * config/rs6000/xmmintrin.h: Likewise.
6156 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6158 * config/rs6000/xmmintrin.h (_mm_extract_pi16): Fix for big-endian.
6160 2018-10-26 Richard Biener <rguenther@suse.de>
6162 * tree-vect-slp.c (vect_mark_slp_stmts): Add visited hash_set
6164 (vect_mark_slp_stmts_relevant): Likewise.
6165 (vect_detect_hybrid_slp_stmts): Likewise.
6166 (vect_bb_slp_scalar_cost): Likewise.
6167 (vect_remove_slp_scalar_calls): Likewise.
6169 2018-10-26 Jan Hubicka <jh@suse.cz>
6171 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix recursion.
6172 (warn_types_mismatch): Fix walk of DECL_NAME.
6173 (odr_types_equivalent_p): Fix overactive assert.
6175 2018-10-26 Richard Biener <rguenther@suse.de>
6177 PR tree-optimization/87105
6178 * tree-vectorizer.h (_slp_tree::refcnt): New member.
6179 * tree-vect-slp.c (vect_free_slp_tree): Decrement and honor
6181 (vect_create_new_slp_node): Initialize refcnt to one.
6183 (scalar_stmts_set_t, bst_fail): Remove.
6184 (vect_build_slp_tree_2): Add bst_map argument and adjust calls.
6185 (vect_build_slp_tree): Add bst_map argument and lookup
6186 already created SLP nodes.
6187 (vect_print_slp_tree): Handle a SLP graph, print SLP node
6189 (vect_slp_rearrange_stmts): Handle a SLP graph.
6190 (vect_analyze_slp_instance): Adjust and free SLP nodes from
6191 the CSE map. Fix indenting.
6192 (vect_schedule_slp_instance): Add short-cut.
6194 2018-10-26 Martin Liska <mliska@suse.cz>
6197 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Hash with
6198 addr_expr and not with pointers.
6200 2018-10-26 Jan Hubicka <jh@suse.cz>
6202 * tree.c (free_lang_data_in_type): Only check main variants.
6203 * ipa-devirt.c (warn_odr): Make static.
6204 (types_same_for_odr): Drop strict variant.
6205 (types_odr_comparable): Likewise.
6206 (odr_or_derived_type_p): Look for main variants.
6207 (odr_name_hasher::equal): Cleanup comment.
6208 (odr_subtypes_equivalent): Add warn and warned arguments; check main
6210 (type_variants_equivalent_p): break out from ...
6211 (odr_types_equivalent): ... here; go for main variants where needed.
6212 (warn_odr): ... here; turn static.
6213 (warn_types_mismatch): Compare mangled names of main variants.
6214 * ipa-utils.h (types_odr_comparable): Drop strict parameter.
6215 (type_with_linkage_p): Sanity check that we look at main variant.
6216 * lto.c (lto_read_decls): Only consider main variant to be ODR type.
6217 * tree.h (types_same_for_odr): Drop strict argument.
6219 2018-10-26 Richard Biener <rguenther@suse.de>
6221 PR tree-optimization/87746
6222 * tree-vect-data-refs.c (vect_update_misalignment_for_peel):
6223 Simplify and fix WRT strided store groups with size not
6224 equal to step in element count.
6225 (vect_analyze_group_access_1): Dump the whole group.
6227 2018-10-25 Carl Love <cel@us.ibm.com>
6229 * config/rs6000/rs6000-c.c (P9V_BUILTIN_VEC_VSCEDPGT,
6230 P9V_BUILTIN_VEC_VSCEDPLT, P9V_BUILTIN_VEC_VSCEDPEQ,
6231 P9V_BUILTIN_VEC_VSCEDPUO): Rename base overloaded name. Add quad
6232 precicion entry for each overloaded builtin.
6233 * config/rs6000/rs6000-builtin.def (VSCEDPGT, VSCEDPLT, VSCEDPEQ,
6234 VSCEDPUO): Rename overloaded name.
6235 (VSCEDPGT, VSCEQPGT, VSCEDPLT, VSCEQPLT, VSCEDPEQ, VSCEQPEQ,
6236 VSCEDPUO, VSCEQPUO): Add defitions for overloaded builtins.
6237 * config/rs6000/vsx.md (xscmpexpqp_<code>_<mode>): Add
6238 define_expand for xscmpexqp instruction.
6239 (*xscmpexpqp): Add define_insn for the xscmpexqp instruction.
6241 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6242 Jinsong Ji <jji@us.ibm.com>
6244 * config/rs6000/emmintrin.h (_mm_slli_epi16): Replace deprecated
6245 function with vec_sl.
6246 (_mm_slli_epi32): Likewise.
6247 (_mm_slli_epi64): Likewise.
6248 (_mm_srai_epi16): Replace deprecated function with vec_sra.
6249 (_mm_srai_epi32): Likewise.
6250 (_mm_srli_epi16): Replace deprecated function with vec_sr.
6251 (_mm_srli_epi32): Likewise.
6252 (_mm_srli_epi64): Likewise.
6253 (_mm_sll_epi16): Replace deprecated function with vec_sl.
6254 (_mm_sll_epi32): Likewise.
6255 (_mm_sll_epi64): Likewise.
6256 (_mm_sra_epi16): Replace deprecated function with vec_sra.
6257 (_mm_sra_epi32): Likewise.
6258 (_mm_srl_epi16): Replace deprecated function with vec_sr.
6259 (_mm_srl_epi32): Likewise.
6260 (_mm_srl_epi64): Likewise.
6262 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6263 Jinsong Ji <jji@us.ibm.com>
6265 * gcc/config/rs6000/emmintrin.h (_mm_sll_epi16): Replace
6266 comparison operators with vec_cmp* for compatibility due to
6267 unfortunate history; clean up formatting and use types more
6269 (_mm_sll_epi32): Likewise.
6270 (_mm_sll_epi64): Likewise.
6271 (_mm_srl_epi16): Likewise.
6272 (_mm_srl_epi32): Likewise.
6273 (_mm_srl_epi64): Likewise.
6275 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6276 Jinsong Ji <jji@us.ibm.com>
6278 * config/rs6000/emmintrin.h (_mm_sll_epi64): Remove wrong cast.
6279 * config/rs6000/xmmintrin.h (_mm_min_ps): Change m's type to
6280 __vector __bool int. Use vec_cmpgt in preference to deprecated
6281 function vec_vcmpgtfp.
6282 (_mm_max_ps): Likewise.
6284 2018-10-25 Jeff Law <law@redhat.com>
6286 * config/rl78/rl78.c (insn_ok_now): Always re-recognize the insn
6289 2018-10-25 Martin Sebor <msebor@redhat.com>
6291 * doc/extend.texi (aligned): Expand attribute description.
6292 (Alignment): Rename section. Discuss function arguments.
6294 2018-10-25 Jan Hubicka <jh@suse.cz>
6296 * ipa-devirt.c (main_odr_variant): Remove.
6297 (hash_odr_name, types_same_for_odr, types_odr_comparable,
6298 odr_name_hasher::equal, odr_subtypes_equivalent_p):
6299 Drop use of main_odr_variant.
6300 (add_type_duplicate): Silence confused warnings on integer types.
6301 (get_odr_type): Always look for main variant.
6302 (register_odr_type): Simplify.
6304 2018-10-25 Richard Biener <rguenther@suse.de>
6306 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses):
6307 Initialize ng to silence error with release checking bootstrap.
6309 2018-10-25 Richard Biener <rguenther@suse.de>
6311 * tree-if-conv.c: Include tree-ssa-sccvn.h.
6312 (tree_if_conversion): Run CSE on the if-converted loop body.
6314 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
6316 * config/s390/constraints.md (ZL): New constraint.
6317 * config/s390/s390.c (legitimate_pic_operand_p): Accept LARL
6319 * config/s390/s390.md (movdi_larl): Remove.
6320 (movdi_64): Add the LARL alternative.
6322 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
6325 * rtl.c (RTX_CODE_HWINT_P_1): New helper macro.
6326 (RTX_CODE_HWINT_P): New macro.
6327 (rtx_code_size): Use RTX_CODE_HWINT_P ().
6329 2018-10-25 Jan Hubicka <jh@suse.cz>
6331 * ipa-devirt.c (odr_types_equivalent_p): Do not ICE if one of types
6334 2018-10-25 Richard Biener <rguenther@suse.de>
6336 PR tree-optimization/87665
6337 PR tree-optimization/87745
6338 * tree-vectorizer.h (get_earlier_stmt): Remove.
6339 (get_later_stmt): Pick up UID from the original non-pattern stmt.
6341 2018-10-25 Sam Tebbs <sam.tebbs@arm.com>
6343 * options.texi (Deprecated): Move list to Var section.
6345 2018-10-24 Bill Schmidt <wschmidt@linux.ibm.com>
6346 Jinsong Ji <jji@us.ibm.com>
6348 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Change deprecated
6349 __vector long to __vector long long.
6350 (_mm_cvtpd_ps): Likewise.
6351 (_mm_cvttpd_epi32): Likewise.
6352 (_mm_cvtpi32_pd): Likewise.
6353 (_mm_unpackhi_epi64): Likewise.
6354 (_mm_unpacklo_epi64): Likewise.
6356 2018-10-24 Segher Boessenkool <segher@kernel.crashing.org>
6358 PR rtl-optimization/87720
6359 * combine.c (make_more_copies): Skip if the dest is pc_rtx.
6361 2018-10-24 Alexandre Oliva <aoliva@redhat.com>
6363 * gimple-ssa-isolate-paths.c
6364 (find_implicit_erroneous_behavior): Do not change code if the
6365 pass is running for warnings only.
6366 (find_explicit_erroneous_behavior): Likewise.
6368 2018-10-24 Michael Meissner <meissner@linux.ibm.com>
6370 * config/rs6000/rs6000.c (TARGET_MANGLE_DECL_ASSEMBLER_NAME):
6371 Define as rs6000_mangle_decl_assembler_name.
6372 (rs6000_mangle_decl_assembler_name): If the user switched from IBM
6373 long double to IEEE long double, switch the names of the long
6374 double built-in functions to be <func>f128 instead of <func>l.
6376 2018-10-24 Martin Sebor <msebor@redhat.com>
6378 * doc/extend.texi (nonnull): List no-argument form. Reference
6379 -fno-delete-null-pointer-checks and -fisolate-erroneous-paths-attribute.
6381 2018-10-24 Richard Biener <rguenther@suse.de>
6383 * tree-ssa-sccvn.c (do_rpo_vn): Free rpo_state.
6385 2018-10-24 Martin Liska <mliska@suse.cz>
6387 PR tree-optimization/84436
6388 * tree-switch-conversion.c (switch_conversion::contains_same_values_p):
6390 (switch_conversion::contains_linear_function_p): New.
6391 (switch_conversion::build_one_array): Support linear
6392 transformation on input.
6393 * tree-switch-conversion.h (struct switch_conversion): Add
6394 contains_linear_function_p declaration.
6396 2018-10-24 Richard Biener <rguenther@suse.de>
6398 * varasm.c (const_hash_1): Return hash of ADDR_EXPR
6399 if its argument is CONSTANT_CLASS_P.
6401 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
6403 * ipa-utils.h (type_with_linkage_p): No longer check for TYPE_STUB_DECL;
6404 it is wrong for forward declarations.
6406 2018-10-24 Ilya Leoshkevich <iii@linux.ibm.com>
6408 * config/s390/s390.c (s390_check_qrst_address): Add the missing
6409 SYMBOL_REF_P () check.
6411 2018-10-24 Richard Biener <rguenther@suse.de>
6413 PR tree-optimization/87105
6414 * tree-vect-data-refs.c (vect_analyze_group_access_1): Adjust
6415 dump classification.
6416 (vect_analyze_data_ref_accesses): Handle duplicate loads and
6417 stores by splitting the affected group after the fact.
6418 * tree-vect-slp.c (vect_build_slp_tree_2): Dump when we
6419 fail the SLP build because of size constraints.
6421 2018-10-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6423 * configure.ac (gcc_cv_ld_aligned_shf_merge): New test.
6424 * configure: Regenerate.
6425 * config.in: Regenerate.
6426 * varasm.c (mergeable_string_section): Use readonly_data_section
6427 if linker doesn't support SHF_MERGE with alignment > 8.
6428 (mergeable_constant_section): Likewise.
6430 2018-10-24 Richard Biener <rguenther@suse.de>
6432 PR tree-optimization/84013
6433 * tree-ssa-structalias.c (struct msdi_data): New struct for
6434 marshalling data to walk_stmt_load_store_ops.
6435 (maybe_set_dependence_info): Refactor as callback for
6436 walk_stmt_load_store_ops.
6437 (compute_dependence_clique): Set restrict info on all stmt kinds.
6439 2018-10-24 Martin Liska <mliska@suse.cz>
6441 * cgraph.c (cgraph_node::dump):
6442 Remove reduntant dumps and make tp_first_run dump more compact.
6444 2018-10-24 Richard Biener <rguenther@suse.de>
6446 PR tree-optimization/87665
6447 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
6450 2018-10-12 Jeff Law <law@redhat.com>
6452 * config/h8300/h8300.c (h8300_expand_prologue): Fix stm generation
6455 2018-10-23 Richard Biener <rguenther@suse.de>
6457 * tree-vrp.c (add_assert_info): Guard dump_printf with
6459 * gimple-ssa-evrp-analyze.c
6460 (evrp_range_analyzer::record_ranges_from_incoming_edge):
6461 Use value_range::ignore_equivs_equal_p.
6463 2018-10-23 Richard Biener <rguenther@suse.de>
6465 PR tree-optimization/87105
6466 PR tree-optimization/87608
6467 * passes.def (pass_all_early_optimizations): Add early phi-opt
6469 * tree-ssa-phiopt.c (value_replacement): Ignore NOPs and predicts in
6470 addition to debug stmts.
6471 (tree_ssa_phiopt_worker): Add early_p argument, do only min/max
6472 and abs replacement early.
6473 * tree-cfg.c (gimple_empty_block_p): Likewise.
6475 2018-10-23 Richard Earnshaw <rearnsha@arm.com>
6478 * config.gcc (arm*-*-netbsdelf*): Default to StrongARM if no CPU
6479 specified to configure.
6480 (arm*-*-*): Use ARM7TDMI as the target CPU if no default provided.
6482 2018-10-23 Richard Biener <rguenther@suse.de>
6484 PR tree-optimization/87700
6485 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
6487 2018-10-23 Jakub Jelinek <jakub@redhat.com>
6490 * config/i386/avx512vlintrin.h (_mm_mask_mullo_epi32): Change type of
6491 second argument from __mmask16 to __mmask8.
6492 * config/i386/avx512vlbwintrin.h (_mm_mask_packus_epi32,
6493 _mm_mask_packs_epi32): Likewise.
6494 * config/i386/avx512pfintrin.h (_mm512_mask_prefetch_i64scatter_ps):
6496 (_mm512_mask_prefetch_i64scatter_pd): Likewise. Formatting fix.
6498 2018-10-23 Richard Biener <rguenther@suse.de>
6500 * tree-vect-stmts.c (vect_analyze_stmt): Fix typo in comment.
6502 2018-10-23 Richard Biener <rguenther@suse.de>
6504 PR tree-optimization/86144
6505 * tree-vect-stmts.c (vect_analyze_stmt): Prefer -mveclibabi
6506 over simd attribute.
6508 2018-10-23 Richard Biener <rguenther@suse.de>
6510 PR tree-optimization/87693
6511 * tree-ssa-threadedge.c (thread_around_empty_blocks): Handle
6512 the case we do not find the taken edge.
6514 2018-10-22 Bill Schmidt <wschmidt@linux.ibm.com>
6515 Jinsong Ji <jji@us.ibm.com>
6517 * config/rs6000/emmintrin.h (_MM_SHUFFLE2): Comment cleanup.
6518 (_mm_store_pd): Use unaligned vector type for pointer cast.
6519 (_mm_maskmoveu_si128): Likewise.
6520 * config/rs6000/xmmintrin.h (__m128_u): New typedef.
6521 (_mm_store_ps): Use unaligned vector type for pointer cast.
6523 2018-10-22 Paul Koning <ni1d@arrl.net>
6525 * symtab.c (symtab_node::increase_alignment): Correct max
6528 2018-10-22 Yury Gribov <tetra2005@gmail.com>
6530 PR tree-optimization/87633
6531 * match.pd: Do not generate unordered integer comparisons.
6533 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
6535 PR rtl-optimization/87600
6536 * combine.c: Add include of expr.h.
6537 (cant_combine_insn_p): Do not combine moves from any hard non-fixed
6538 register to a pseudo.
6539 (make_more_copies): New function, add a copy to a new pseudo after
6540 the moves from hard registers into pseudos.
6541 (rest_of_handle_combine): Declare rebuild_jump_labels_after_combine
6542 later. Call make_more_copies.
6544 2018-10-22 Andrew Stubbs <ams@codesourcery.com>
6546 * lra-constraints.c (process_alt_operands): New local array,
6547 matching_early_clobber. Check matching_early_clobber before
6548 decrementing reject, and set matching_early_clobber after.
6550 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
6553 * config/rs6000/rs6000.c (print_operand_address): For unexpected RTL
6554 call output_addr_const and hope for the best.
6556 2018-10-22 Richard Biener <rguenther@suse.de>
6558 * gimple-ssa-evrp-analyze.c
6559 (evrp_range_analyzer::record_ranges_from_incoming_edge): Be
6560 smarter about what ranges to use.
6561 * tree-vrp.c (add_assert_info): Dump here.
6562 (register_edge_assert_for_2): Instead of here at multiple but
6565 * gcc.dg/tree-ssa/evrp12.c: New testcase.
6566 * gcc.dg/predict-6.c: Adjust.
6567 * gcc.dg/tree-ssa/vrp33.c: Disable EVRP.
6568 * gcc.dg/tree-ssa/vrp02.c: Likewise.
6569 * gcc.dg/tree-ssa/cunroll-9.c: Likewise.
6571 2018-10-22 Steven Bosscher <steven@gcc.gnu.org>
6572 Richard Biener <rguenther@suse.de>
6574 * bitmap.h: Update data structure documentation, including a
6575 description of bitmap views as either linked-lists or splay trees.
6576 (struct bitmap_element_def): Update comments for splay tree bitmaps.
6577 (struct bitmap_head_def): Likewise.
6578 (bitmap_list_view, bitmap_tree_view): New prototypes.
6579 (bitmap_initialize_stat): Initialize a bitmap_head's indx and
6581 (bmp_iter_set_init): Assert the iterated bitmaps are in list form.
6582 (bmp_iter_and_init, bmp_iter_and_compl_init): Likewise.
6583 * bitmap.c (bitmap_elem_to_freelist): Unregister overhead of a
6584 released bitmap element here.
6585 (bitmap_element_free): Remove.
6586 (bitmap_elt_clear_from): Work on splay tree bitmaps.
6587 (bitmap_list_link_element): Renamed from bitmap_element_link. Move
6588 this function similar ones such that linked-list bitmap implementation
6589 functions are grouped.
6590 (bitmap_list_unlink_element): Renamed from bitmap_element_unlink,
6591 and moved for grouping.
6592 (bitmap_list_insert_element_after): Renamed from
6593 bitmap_elt_insert_after, and moved for grouping.
6594 (bitmap_list_find_element): New function spliced from bitmap_find_bit.
6595 (bitmap_tree_link_left, bitmap_tree_link_right,
6596 bitmap_tree_rotate_left, bitmap_tree_rotate_right, bitmap_tree_splay,
6597 bitmap_tree_link_element, bitmap_tree_unlink_element,
6598 bitmap_tree_find_element): New functions for splay-tree bitmap
6600 (bitmap_element_link, bitmap_element_unlink, bitmap_elt_insert_after):
6601 Renamed and moved, see above entries.
6602 (bitmap_tree_listify_from): New function to convert part of a splay
6603 tree bitmap to a linked-list bitmap.
6604 (bitmap_list_view): Convert a splay tree bitmap to linked-list form.
6605 (bitmap_tree_view): Convert a linked-list bitmap to splay tree form.
6606 (bitmap_find_bit): Remove.
6607 (bitmap_clear, bitmap_clear_bit, bitmap_set_bit,
6608 bitmap_single_bit_set_p, bitmap_first_set_bit, bitmap_last_set_bit):
6609 Handle splay tree bitmaps.
6610 (bitmap_copy, bitmap_count_bits, bitmap_and, bitmap_and_into,
6611 bitmap_elt_copy, bitmap_and_compl, bitmap_and_compl_into,
6612 bitmap_compl_and_into, bitmap_elt_ior, bitmap_ior, bitmap_ior_into,
6613 bitmap_xor, bitmap_xor_into, bitmap_equal_p, bitmap_intersect_p,
6614 bitmap_intersect_compl_p, bitmap_ior_and_compl,
6615 bitmap_ior_and_compl_into, bitmap_set_range, bitmap_clear_range,
6616 bitmap_hash): Reject trying to act on splay tree bitmaps. Make
6617 corresponding changes to use linked-list specific bitmap_element
6618 manipulation functions as applicable for efficiency.
6619 (bitmap_tree_to_vec): New function.
6620 (debug_bitmap_elt_file): New function split out from ...
6621 (debug_bitmap_file): ... here. Handle splay tree bitmaps.
6622 (bitmap_print): Likewise.
6624 PR tree-optimization/63155
6625 * tree-ssa-propagate.c (ssa_prop_init): Use tree-view for the
6627 * tree-ssa-coalesce.c (coalesce_ssa_name): Populate used_in_copies
6630 2018-10-22 Martin Liska <mliska@suse.cz>
6632 PR tree-optimization/87686
6634 2018-08-29 Martin Liska <mliska@suse.cz>
6636 * tree-switch-conversion.c (switch_conversion::expand):
6637 Strenghten assumption about gswitch statements.
6639 2018-10-22 Martin Liska <mliska@suse.cz>
6641 * ipa-icf.c (sem_item::compare_attributes): Remove.
6642 (sem_item::compare_referenced_symbol_properties): Use
6643 attribute_list_equal instead.
6644 (sem_function::equals_wpa): Likewise.
6645 * ipa-icf.h: Remove compare_attributes.
6647 2018-10-22 Richard Biener <rguenther@suse.de>
6650 * mem-stats.h (mem_usage::operator==): Fix pasto.
6652 2018-10-22 Richard Biener <rguenther@suse.de>
6654 PR tree-optimization/87640
6655 * tree-vrp.c (set_value_range_with_overflow): Decompose
6657 (extract_range_from_binary_expr_1): Adjust.
6659 2018-10-22 Martin Jambor <mjambor@suse.cz>
6661 * tree-eh.h (stmt_could_throw_p): Add function parameter.
6662 (stmt_can_throw_external): Likewise.
6663 (stmt_can_throw_internal): Likewise.
6664 * tree-eh.c (lower_eh_constructs_2): Pass cfun to stmt_could_throw_p.
6665 (lower_eh_constructs_2): Likewise.
6666 (stmt_could_throw_p): Add fun parameter, use it instead of cfun.
6667 (stmt_can_throw_external): Likewise.
6668 (stmt_can_throw_internal): Likewise.
6669 (maybe_clean_eh_stmt_fn): Pass cfun to stmt_could_throw_p.
6670 (maybe_clean_or_replace_eh_stmt): Pass cfun to stmt_could_throw_p.
6671 (maybe_duplicate_eh_stmt_fn): Pass new_fun to stmt_could_throw_p.
6672 (maybe_duplicate_eh_stmt): Pass cfun to stmt_could_throw_p.
6673 (pass_lower_eh_dispatch::execute): Pass cfun to
6674 stmt_can_throw_external.
6675 (cleanup_empty_eh): Likewise.
6676 (verify_eh_edges): Pass cfun to stmt_could_throw_p.
6677 * cgraph.c (cgraph_edge::set_call_stmt): Pass a function to
6678 stmt_can_throw_external instead of pushing it to cfun.
6679 (symbol_table::create_edge): Likewise.
6680 * gimple-fold.c (fold_builtin_atomic_compare_exchange): Pass cfun to
6681 stmt_can_throw_internal.
6682 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Pass cfun
6683 to stmt_could_throw_p.
6684 * gimple-ssa-store-merging.c (handled_load): Pass cfun to
6685 stmt_can_throw_internal.
6686 (pass_store_merging::execute): Likewise.
6687 * gimple-ssa-strength-reduction.c
6688 (find_candidates_dom_walker::before_dom_children): Pass cfun to
6690 * gimplify-me.c (gimple_regimplify_operands): Pass cfun to
6691 stmt_can_throw_internal.
6692 * ipa-pure-const.c (check_call): Pass cfun to stmt_could_throw_p and
6693 to stmt_can_throw_external.
6694 (check_stmt): Pass cfun to stmt_could_throw_p.
6695 (check_stmt): Pass cfun to stmt_can_throw_external.
6696 (pass_nothrow::execute): Likewise.
6697 * trans-mem.c (expand_call_tm): Pass cfun to stmt_can_throw_internal.
6698 * tree-cfg.c (is_ctrl_altering_stmt): Pass cfun to
6699 stmt_can_throw_internal.
6700 (verify_gimple_in_cfg): Pass cfun to stmt_could_throw_p.
6701 (stmt_can_terminate_bb_p): Pass cfun to stmt_can_throw_external.
6702 (gimple_purge_dead_eh_edges): Pass cfun to stmt_can_throw_internal.
6703 * tree-complex.c (expand_complex_libcall): Pass cfun to
6704 stmt_could_throw_p and to stmt_can_throw_internal.
6705 (expand_complex_multiplication): Pass cfun to stmt_can_throw_internal.
6706 * tree-inline.c (copy_edges_for_bb): Likewise.
6707 (maybe_move_debug_stmts_to_successors): Likewise.
6708 * tree-outof-ssa.c (ssa_is_replaceable_p): Pass cfun to
6710 * tree-parloops.c (oacc_entry_exit_ok_1): Likewise.
6711 * tree-sra.c (scan_function): Pass cfun to stmt_can_throw_external.
6712 * tree-ssa-alias.c (stmt_kills_ref_p): Pass cfun to
6713 stmt_can_throw_internal.
6714 * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Likewise.
6715 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Pass cfun to
6717 (mark_aliased_reaching_defs_necessary_1): Pass cfun to
6718 stmt_can_throw_internal.
6719 * tree-ssa-forwprop.c (pass_forwprop::execute): Likewise.
6720 * tree-ssa-loop-im.c (movement_possibility): Pass cfun to
6722 * tree-ssa-loop-ivopts.c (find_givs_in_stmt_scev): Likewise.
6723 (add_autoinc_candidates): Pass cfun to stmt_can_throw_internal.
6724 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
6725 (convert_mult_to_fma_1): Likewise.
6726 (convert_to_divmod): Likewise.
6727 * tree-ssa-phiprop.c (propagate_with_phi): Likewise.
6728 * tree-ssa-pre.c (compute_avail): Pass cfun to stmt_could_throw_p.
6729 * tree-ssa-propagate.c
6730 (substitute_and_fold_dom_walker::before_dom_children): Likewise.
6731 * tree-ssa-reassoc.c (suitable_cond_bb): Likewise.
6732 (maybe_optimize_range_tests): Likewise.
6733 (linearize_expr_tree): Likewise.
6734 (reassociate_bb): Likewise.
6735 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
6736 * tree-ssa-scopedtables.c (hashable_expr_equal_p): Likewise.
6737 * tree-ssa-strlen.c (adjust_last_stmt): Likewise.
6738 (handle_char_store): Likewise.
6739 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Pass cfun to
6740 stmt_can_throw_internal.
6741 * tree-vect-patterns.c (check_bool_pattern): Pass cfun to
6743 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
6744 (vectorizable_call): Pass cfun to stmt_can_throw_internal.
6745 (vectorizable_simd_clone_call): Likewise.
6746 * value-prof.c (gimple_ic): Pass cfun to stmt_could_throw_p.
6747 (gimple_stringop_fixed_value): Likewise.
6749 2018-10-22 Ilya Leoshkevich <iii@linux.ibm.com>
6751 * config/s390/s390.c (s390_loadrelative_operand_p): Accept
6752 literal pool references.
6753 (s390_check_qrst_address): Adapt to the new behavior of
6754 s390_loadrelative_operand_p ().
6756 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
6759 * config/i386/sse.md (*andnot<mode>3_bcst): New.
6761 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
6764 * config/i386/sse.md (*<code><mode>3_bcst): New.
6766 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
6769 * config/i386/sse.md (avx512bcst): Updated for V4SI, V2DI, V8SI,
6770 V4DI, V16SI and V8DI.
6771 (*sub<mode>3<mask_name>_bcst): New.
6772 (*add<mode>3<mask_name>_bcst): Likewise.
6774 2018-10-21 Bill Schmidt <wschmidt@linux.ibm.com>
6775 Jinsong Ji <jji@us.ibm.com>
6777 * config/rs6000/emmintrin.h (_mm_movemask_pd): Replace __vector
6778 __m64 with __vector unsigned long long for compatibility.
6779 (_mm_movemask_epi8): Likewise.
6780 * config/rs6000/xmmintrin.h (_mm_cvtps_pi32): Likewise.
6781 (_mm_cvttps_pi32): Likewise.
6782 (_mm_cvtpi32_ps): Likewise.
6783 (_mm_cvtps_pi16): Likewise.
6784 (_mm_loadh_pi): Likewise.
6785 (_mm_storeh_pi): Likewise.
6786 (_mm_movehl_ps): Likewise.
6787 (_mm_movelh_ps): Likewise.
6788 (_mm_loadl_pi): Likewise.
6789 (_mm_storel_pi): Likewise.
6790 (_mm_movemask_ps): Likewise.
6791 (_mm_shuffle_pi16): Likewise.
6793 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
6796 * config/i386/avx512fintrin.h (_mm512_fnmsub_round_pd): Use
6797 __builtin_ia32_vfnmsubpd512_mask.
6798 (_mm512_mask_fnmsub_round_pd): Likewise.
6799 (_mm512_fnmsub_pd): Likewise.
6800 (_mm512_mask_fnmsub_pd): Likewise.
6801 (_mm512_maskz_fnmsub_round_pd): Use
6802 __builtin_ia32_vfnmsubpd512_maskz.
6803 (_mm512_maskz_fnmsub_pd): Likewise.
6804 (_mm512_fnmsub_round_ps): Use __builtin_ia32_vfnmsubps512_mask.
6805 (_mm512_mask_fnmsub_round_ps): Likewise.
6806 (_mm512_fnmsub_ps): Likewise.
6807 (_mm512_mask_fnmsub_ps): Likewise.
6808 (_mm512_maskz_fnmsub_round_ps): Use
6809 __builtin_ia32_vfnmsubps512_maskz.
6810 (_mm512_maskz_fnmsub_ps): Likewise.
6811 * config/i386/avx512vlintrin.h (_mm256_mask_fnmsub_pd): Use
6812 __builtin_ia32_vfnmsubpd256_mask.
6813 (_mm256_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256_maskz.
6814 (_mm_mask_fnmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
6815 (_mm_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd128_maskz.
6816 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
6817 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
6818 (_mm256_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_maskz.
6819 (_mm_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_mask.
6820 (_mm_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_maskz.
6821 * config/i386/fmaintrin.h (_mm_fnmsub_pd): Use
6822 __builtin_ia32_vfnmsubpd.
6823 (_mm256_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256.
6824 (_mm_fnmsub_ps): Use __builtin_ia32_vfnmsubps.
6825 (_mm256_fnmsub_ps): Use __builtin_ia32_vfnmsubps256.
6826 (_mm_fnmsub_sd): Use __builtin_ia32_vfnmsubsd3.
6827 (_mm_fnmsub_ss): Use __builtin_ia32_vfnmsubss3.
6828 * config/i386/i386-builtin.def: Add
6829 __builtin_ia32_vfnmsubpd256_mask,
6830 __builtin_ia32_vfnmsubpd256_maskz,
6831 __builtin_ia32_vfnmsubpd128_mask,
6832 __builtin_ia32_vfnmsubpd128_maskz,
6833 __builtin_ia32_vfnmsubps256_mask,
6834 __builtin_ia32_vfnmsubps256_maskz,
6835 __builtin_ia32_vfnmsubps128_mask,
6836 __builtin_ia32_vfnmsubps128_maskz,
6837 __builtin_ia32_vfnmsubpd512_mask,
6838 __builtin_ia32_vfnmsubpd512_maskz,
6839 __builtin_ia32_vfnmsubps512_mask,
6840 __builtin_ia32_vfnmsubps512_maskz, __builtin_ia32_vfnmsubss3,
6841 __builtin_ia32_vfnmsubsd3, __builtin_ia32_vfnmsubps,
6842 __builtin_ia32_vfnmsubpd, __builtin_ia32_vfnmsubps256 and.
6843 __builtin_ia32_vfnmsubpd256.
6844 * config/i386/sse.md (fma4i_fnmsub_<mode>): New.
6845 (<avx512>_fnmsub_<mode>_maskz<round_expand_name>): Likewise.
6846 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_1):
6848 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_2):
6850 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_3):
6852 (fmai_vmfnmsub_<mode><round_name>): Likewise.
6854 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
6857 * config/i386/avx512fintrin.h (_mm512_fnmadd_round_pd): Use
6858 __builtin_ia32_vfnmaddpd512_mask.
6859 (_mm512_mask_fnmadd_round_pd): Likewise.
6860 (_mm512_fnmadd_pd): Likewise.
6861 (_mm512_mask_fnmadd_pd): Likewise.
6862 (_mm512_maskz_fnmadd_round_pd): Use
6863 __builtin_ia32_vfnmaddpd512_maskz.
6864 (_mm512_maskz_fnmadd_pd): Likewise.
6865 (_mm512_fnmadd_round_ps): Use __builtin_ia32_vfnmaddps512_mask.
6866 (_mm512_mask_fnmadd_round_ps): Likewise.
6867 (_mm512_fnmadd_ps): Likewise.
6868 (_mm512_mask_fnmadd_ps): Likewise.
6869 (_mm512_maskz_fnmadd_round_ps): Use
6870 __builtin_ia32_vfnmaddps512_maskz.
6871 (_mm512_maskz_fnmadd_ps): Likewise.
6872 * config/i386/avx512vlintrin.h (_mm256_mask_fnmadd_pd): Use
6873 __builtin_ia32_vfnmaddpd256_mask.
6874 (_mm256_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256_maskz.
6875 (_mm_mask_fnmadd_pd): Use __builtin_ia32_vfmaddpd128_mask
6876 (_mm_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd128_maskz.
6877 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
6878 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
6879 (_mm256_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_maskz.
6880 (_mm_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_mask.
6881 (_mm_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_maskz.
6882 * config/i386/fmaintrin.h (_mm_fnmadd_pd): Use
6883 __builtin_ia32_vfnmaddpd.
6884 (_mm256_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256.
6885 (_mm_fnmadd_ps): Use __builtin_ia32_vfnmaddps.
6886 (_mm256_fnmadd_ps): Use __builtin_ia32_vfnmaddps256.
6887 (_mm_fnmadd_sd): Use __builtin_ia32_vfnmaddsd3.
6888 (_mm_fnmadd_ss): Use __builtin_ia32_vfnmaddss3.
6889 * config/i386/i386-builtin.def: Add
6890 __builtin_ia32_vfnmaddpd256_mask,
6891 __builtin_ia32_vfnmaddpd256_maskz,
6892 __builtin_ia32_vfnmaddpd128_mask,
6893 __builtin_ia32_vfnmaddpd128_maskz,
6894 __builtin_ia32_vfnmaddps256_mask,
6895 __builtin_ia32_vfnmaddps256_maskz,
6896 __builtin_ia32_vfnmaddps128_mask,
6897 __builtin_ia32_vfnmaddps128_maskz,
6898 __builtin_ia32_vfnmaddpd512_mask,
6899 __builtin_ia32_vfnmaddpd512_maskz,
6900 __builtin_ia32_vfnmaddps512_mask,
6901 __builtin_ia32_vfnmaddps512_maskz, __builtin_ia32_vfnmaddss3,
6902 __builtin_ia32_vfnmaddsd3, __builtin_ia32_vfnmaddps,
6903 __builtin_ia32_vfnmaddpd, __builtin_ia32_vfnmaddps256 and.
6904 __builtin_ia32_vfnmaddpd256.
6905 * config/i386/sse.md (fma4i_fnmadd_<mode>): New.
6906 (<avx512>_fnmadd_<mode>_maskz<round_expand_name>): Likewise.
6907 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_1):
6909 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_2):
6911 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_3):
6913 (fmai_vmfnmadd_<mode><round_name>): Likewise.
6915 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
6918 * config/i386/avx512fintrin.h (_mm512_fmsub_round_pd): Use
6919 __builtin_ia32_vfmsubpd512_mask.
6920 (_mm512_mask_fmsub_round_pd): Likewise.
6921 (_mm512_fmsub_pd): Likewise.
6922 (_mm512_mask_fmsub_pd): Likewise.
6923 (_mm512_maskz_fmsub_round_pd): Use
6924 __builtin_ia32_vfmsubpd512_maskz.
6925 (_mm512_maskz_fmsub_pd): Likewise.
6926 (_mm512_fmsub_round_ps): Use __builtin_ia32_vfmsubps512_mask.
6927 (_mm512_mask_fmsub_round_ps): Likewise.
6928 (_mm512_fmsub_ps): Likewise.
6929 (_mm512_mask_fmsub_ps): Likewise.
6930 (_mm512_maskz_fmsub_round_ps): Use
6931 __builtin_ia32_vfmsubps512_maskz.
6932 (_mm512_maskz_fmsub_ps): Likewise.
6933 * config/i386/avx512vlintrin.h (_mm256_mask_fmsub_pd): Use
6934 __builtin_ia32_vfmsubpd256_mask.
6935 (_mm256_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd256_maskz.
6936 (_mm_mask_fmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
6937 (_mm_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd128_maskz.
6938 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
6939 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
6940 (_mm256_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps256_maskz.
6941 (_mm_mask_fmsub_ps): Use __builtin_ia32_vfmsubps128_mask.
6942 (_mm_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps128_maskz.
6943 * config/i386/fmaintrin.h (_mm_fmsub_pd): Use
6944 __builtin_ia32_vfmsubpd.
6945 (_mm256_fmsub_pd): Use __builtin_ia32_vfmsubpd256.
6946 (_mm_fmsub_ps): Use __builtin_ia32_vfmsubps.
6947 (_mm256_fmsub_ps): Use __builtin_ia32_vfmsubps256.
6948 (_mm_fmsub_sd): Use __builtin_ia32_vfmsubsd3.
6949 (_mm_fmsub_ss): Use __builtin_ia32_vfmsubss3.
6950 * config/i386/i386-builtin.def: Add
6951 __builtin_ia32_vfmsubpd256_mask,
6952 __builtin_ia32_vfmsubpd256_maskz,
6953 __builtin_ia32_vfmsubpd128_mask,
6954 __builtin_ia32_vfmsubpd128_maskz,
6955 __builtin_ia32_vfmsubps256_mask,
6956 __builtin_ia32_vfmsubps256_maskz,
6957 __builtin_ia32_vfmsubps128_mask,
6958 __builtin_ia32_vfmsubps128_maskz,
6959 __builtin_ia32_vfmsubpd512_mask,
6960 __builtin_ia32_vfmsubpd512_maskz,
6961 __builtin_ia32_vfmsubps512_mask,
6962 __builtin_ia32_vfmsubps512_maskz, __builtin_ia32_vfmsubss3,
6963 __builtin_ia32_vfmsubsd3, __builtin_ia32_vfmsubps,
6964 __builtin_ia32_vfmsubpd, __builtin_ia32_vfmsubps256 and.
6965 __builtin_ia32_vfmsubpd256.
6966 * config/i386/sse.md (fma4i_fmsub_<mode>): New.
6967 (<avx512>_fmsub_<mode>_maskz<round_expand_name>): Likewise.
6968 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_1):
6970 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_2):
6972 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_3):
6974 (fmai_vmfmsub_<mode><round_name>): Likewise.
6976 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
6978 * config/i386/sse.md (*<plusminus_insn><mode>3<mask_name>_bcst_1):
6979 Remove plus. Renamed to ...
6980 (*sub<mode>3<mask_name>_bcst): This.
6981 (*add<mode>3<mask_name>_bcst_2): Renamede to ...
6982 (*add<mode>3<mask_name>_bcst): This.
6984 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
6987 * config/i386/sse.md (*mul<mode>3<mask_name>_bcst): New.
6989 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
6992 * i386/avx512vlintrin.h (_mm256_or_epi32): New.
6993 (_mm_or_epi32): Likewise.
6994 (_mm256_xor_epi32): Likewise.
6995 (_mm_xor_epi32): Likewise.
6996 (_mm256_or_epi64): Likewise.
6997 (_mm_or_epi64): Likewise.
6998 (_mm256_xor_epi64): Likewise.
6999 (_mm_xor_epi64): Likewise.
7001 2018-10-20 H.J. Lu <hongjiu.lu@intel.com>
7004 * config/i386/sse.md (*<avx512>_div<mode>3<mask_name>_bcst): New.
7006 2018-10-20 Jakub Jelinek <jakub@redhat.com>
7009 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
7011 2018-10-20 Andreas Schwab <schwab@linux-m68k.org>
7013 * doc/ux.texi: Move @section directly after @node.
7015 2018-10-19 Jakub Jelinek <jakub@redhat.com>
7019 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
7020 depend closely nested inside of loop with ordered clause with
7023 2018-10-19 David Malcolm <dmalcolm@redhat.com>
7025 * Makefile.in (TEXI_GCCINT_FILES): Add ux.texi.
7026 * doc/gccint.texi: Include ux.texi and use it in top-level menu.
7027 * doc/ux.texi: New file.
7029 2018-10-19 Segher Boessenkool <segher@kernel.crashing.org>
7031 * config/rs6000/rs6000.h (REG_ALLOC_ORDER): Move 68 (that is, CR0) to
7032 be the first CR field allocated.
7034 2018-10-19 Richard Biener <rguenther@suse.de>
7037 * config/i386/i386.c (ix86_builtin_vectorization_cost): Use
7038 TYPE_VECTOR_SUBPARTS and avoid relying on vector mode.
7040 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
7043 * config/i386/sse.md
7044 (*<plusminus_insn><mode>3<mask_name>_bcst_1): New.
7045 (*add<mode>3<mask_name>_bcst_2): Likewise.
7047 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
7049 * config/i386/sse.md
7050 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
7051 Replace nonimmediate_operand with register_operand.
7052 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
7054 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
7057 2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
7059 PR rtl-optimization/87596
7060 * lra-constraints.c (spill_hard_reg_in_range): Use INSN_P () +
7061 lra_get_insn_recog_data () instead of lra_insn_recog_data[]
7062 for instructions in FROM..TO range.
7064 2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
7066 * cfgexpand.c (expand_one_var): Use specific wording in error message
7067 for non-local frame variables.
7068 * stor-layout.c (layout_decl): Do not issue a warning for them.
7070 2018-10-19 Robin Dapp <rdapp@linux.ibm.com>
7072 * haifa-sched.c (priority): Add force_recompute parameter.
7073 (apply_replacement): Call priority () with force_recompute = true.
7074 (restore_pattern): Likewise.
7076 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7078 * simplify-rtx.c (simplify_subreg): Limit mask of vec_merge to
7079 HOST_BITS_PER_WIDE_INT.
7080 (test_vector_ops_duplicate): Likewise.
7082 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7085 * config/i386/sse.md (VF_AVX512): New.
7086 (avx512bcst): Likewise.
7087 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
7089 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
7091 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
7094 2018-10-18 Jonathan Wakely <jwakely@redhat.com>
7096 * doc/invoke.texi (-dumpversion): Improve grammar.
7097 (-dumpfullversion): Make more consistent with -dumpversion.
7099 2018-10-18 Uros Bizjak <ubizjak@gmail.com>
7101 * config/i386/i386.c (ix86_emit_fp_unordered_jump):
7102 Set JUMP_LABEL to the jump insn.
7103 (ix86_emit_i387_log1p): Use ix86_expand_branch to expand branch.
7104 Predict emitted jump and add label to jump insn.
7106 2018-10-18 David Malcolm <dmalcolm@redhat.com>
7108 PR tree-optimization/87562
7109 * input.c (get_substring_ranges_for_loc): Use
7110 LRK_SPELLING_LOCATION rather than LRK_MACRO_EXPANSION_POINT when
7111 getting the linemap for the endpoint. Verify that it's either
7112 in the same linemap as the start point's spelling location, or
7113 at least in the same file.
7115 2018-10-18 Richard Biener <rguenther@suse.de>
7117 * config/i386/i386.c (ix86_builtin_vectorization_cost): Do not
7118 feed width-specific load/store costs through ix86_vec_cost.
7119 * config/i386/x86-tune-costs.h (athlon_cost): Adjust.
7120 (k8_cost): Likewise.
7121 (bdver_cost): Likewise.
7122 (znver1_cost): Likewise.
7123 (btver1_cost): Likewise.
7124 (btver2_cost): Likewise.
7126 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7128 * simplify-rtx.c (simplify_subreg): Call simplify_gen_subreg
7129 to simplify subreg of vec_merge.
7131 2018-10-18 Richard Biener <rguenther@suse.de>
7133 * config/i386/i386.c: Fix costing of vector FMA.
7135 2018-10-18 Richard Biener <rguenther@suse.de>
7137 * config/i386/i386.c (ix86_vec_cost): Remove !parallel path
7139 (ix86_builtin_vectorization_cost): For vec_construct properly
7140 cost insertion into SSE regs.
7141 (...): Adjust calls to ix86_vec_cost.
7143 2018-10-18 Richard Biener <rguenther@suse.de>
7147 2018-02-07 Richard Biener <rguenther@suse.de>
7149 PR tree-optimization/84204
7150 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
7153 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7156 * simplify-rtx.c (simplify_subreg): Simplify subreg of vec_merge
7158 (test_vector_ops_duplicate): Add test for a scalar subreg of a
7159 VEC_MERGE of a VEC_DUPLICATE.
7161 2018-10-17 Joseph Myers <joseph@codesourcery.com>
7163 * doc/cpp.texi (__STDC_VERSION__): Document C2X handling.
7164 * doc/invoke.texi (-std=c2x, -std=gnu2x): Document new options.
7165 * doc/standards.texi (C Language): Document C2X.
7166 * dwarf2out.c (highest_c_language), config/rl78/rl78.c
7167 (rl78_option_override): Handle "GNU C2X" language name.
7169 2018-10-17 Joseph Myers <joseph@codesourcery.com>
7171 * doc/invoke.texi (-std=c17), doc/standards.texi (C Language):
7172 Document C17 as published in 2018.
7174 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
7177 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
7178 bail out if both sides do not have the same storage order.
7180 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
7182 * bitmap.c (bitmap_head::dump): New.
7183 * bitmap.h (bitmap_head): Add dump().
7184 * gimple-ssa-evrp-analyze.c
7185 (evrp_range_analyzer::try_find_new_range): Adjust for value_range API.
7186 (evrp_range_analyzer::set_ssa_range_info): Same.
7187 (evrp_range_analyzer::record_ranges_from_phis): Same.
7188 (evrp_range_analyzer::record_ranges_from_stmt): Same.
7189 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Same.
7190 * gimple-ssa-sprintf.c (get_int_range): Same.
7191 (format_integer): Same.
7192 (sprintf_dom_walker::handle_gimple_call): Same.
7193 * ipa-cp.c (ipcp_vr_lattice::meet_with_1): Same.
7194 (ipcp_vr_lattice::top_p): Same.
7195 (ipcp_vr_lattice::bottom_p): Same.
7196 (ipcp_vr_lattice::set_to_bottom): Same.
7197 (ipa_vr_operation_and_type_effects): Same.
7198 (propagate_vr_across_jump_function): Same.
7199 (ipcp_store_vr_results): Same.
7200 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Same.
7201 (ipa_print_node_jump_functions_for_edge): Same.
7202 (ipa_get_value_range): Same.
7203 (ipa_compute_jump_functions_for_edge): Same.
7204 (ipa_write_jump_function): Same.
7205 * tree-ssa-dom.c (simplify_stmt_for_jump_threading): Same.
7206 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
7208 * vr-values.c (set_value_range_to_nonnegative): Same.
7209 (set_value_range_to_truthvalue): Same.
7210 (vr_values::get_value_range): Same.
7211 (vr_values::set_defs_to_varying): Same.
7212 (vr_values::update_value_range): Same.
7213 (symbolic_range_based_on_p): Same.
7214 (vr_values::op_with_boolean_value_range_p): Same.
7215 (vr_values::extract_range_for_var_from_comparison_expr): Same.
7216 (vr_values::extract_range_from_ssa_name): Same.
7217 (vr_values::extract_range_from_binary_expr): Same.
7218 (vr_values::extract_range_from_unary_expr): Same.
7219 (vr_values::extract_range_from_cond_expr): Same.
7220 (vr_values::extract_range_from_comparison): Same.
7221 (vr_values::check_for_binary_op_overflow): Same.
7222 (vr_values::extract_range_basic): Same.
7223 (vr_values::extract_range_from_assignment): Same.
7224 (compare_ranges): Same.
7225 (compare_range_with_value): Same.
7226 (vr_values::adjust_range_with_scev): Same.
7227 (vrp_valueize): Same.
7228 (vrp_valueize_1): Same.
7229 (vr_values::get_vr_for_comparison): Same.
7230 (vr_values::compare_name_with_value): Same.
7231 (vr_values::compare_names): Same.
7232 (vr_values::vrp_evaluate_conditional): Same.
7233 (find_case_label_ranges): Same.
7234 (vr_values::vrp_visit_switch_stmt): Same.
7235 (vr_values::extract_range_from_phi_node): Same.
7236 (vr_values::simplify_div_or_mod_using_ranges): Same.
7237 (vr_values::simplify_bit_ops_using_ranges): Same.
7238 (test_for_singularity): Same.
7239 (range_fits_type_p): Same.
7240 (vr_values::simplify_cond_using_ranges_1): Same.
7241 (vr_values::simplify_switch_using_ranges): Same.
7242 (vr_values::simplify_float_conversion_using_ranges): Same.
7243 (vr_values::two_valued_val_range_p): Same.
7244 (vr_values::add_equivalence): Move to value_range::equiv_add.
7245 * vr-values.h (vr_values::add_equivalence): Remove.
7246 (VR_INITIALIZER): Remove.
7247 * tree-vrp.c (value_range::set): New.
7248 (value_range::equiv_add): New.
7249 (value_range::value_range): New.
7250 (value_range::deep_copy): New.
7251 (value_range::check): New.
7252 (value_range::equal_p): New.
7253 (value_range::ignore_equivs_equal_p): New.
7254 (value_range::operator==): New.
7255 (value_range::operator!=): New.
7256 (value_range::symbolic_p): New.
7257 (value_range::numeric_p): New.
7258 (value_range::set_undefined): New.
7259 (value_range::set_varying): New.
7260 (value_range::may_contain_p): New.
7261 (value_range::equiv_clear): New.
7262 (value_range::singleton_p): New.
7263 (value_range::intersect): New.
7264 (value_range::dump): New.
7265 (value_range::set_and_canonicalize): New.
7266 (set_value_range): Adjust for value_range API.
7267 (set_value_range_to_undefined): Same.
7268 (set_value_range_to_varying): Same.
7269 (set_and_canonicalize_value_range): Same.
7270 (set_value_range_to_nonnull): Same.
7271 (set_value_range_to_null): Same.
7272 (range_is_null): Same.
7273 (range_is_nonnull): Same.
7274 (range_int_cst_p): Same.
7275 (range_int_cst_singleton_p): Same.
7276 (symbolic_range_p): Same.
7277 (range_includes_zero_p): Same.
7278 (value_range_constant_singleton): Same.
7279 (vrp_set_zero_nonzero_bits): Same.
7280 (ranges_from_anti_range): Same.
7281 (extract_range_into_wide_ints): Same.
7282 (extract_range_from_multiplicative_op): Same.
7283 (set_value_range_with_overflow): Same.
7284 (extract_range_from_binary_expr_1): Same.
7285 (extract_range_from_unary_expr): Same.
7286 (dump_value_range): Same.
7287 (debug_value_range): Same.
7288 (vrp_prop::check_array_ref): Same.
7289 (vrp_prop::check_mem_ref): Same.
7290 (vrp_prop::vrp_initialize): Same.
7291 (vrp_prop::visit_stmt): Same.
7292 (intersect_ranges): Same.
7293 (vrp_prop::visit_phi): Same.
7294 (vrp_prop::vrp_finalize): Same.
7295 (determine_value_range_1): Same.
7296 (determine_value_range): Same.
7297 (vrp_intersect_ranges_1): Rename to...
7298 (vrp_intersect_1): this.
7299 (vrp_intersect_ranges): Rename to...
7300 (value_range::intersect_helper): ...this.
7301 (vrp_meet_1): Rename to...
7302 (value_range::union_helper): ...this.
7303 (vrp_meet): Rename to...
7304 (value_range::union_): ...this.
7305 (copy_value_range): Remove.
7306 * tree-vrp.h (struct value_range): Rewrite into a proper class.
7307 (value_range::vrtype): New.
7308 (value_range::type): New.
7309 (value_range::equiv): New.
7310 (value_range::min): New.
7311 (value_range::max): New.
7312 (value_range::varying_p): New.
7313 (value_range::undefined_p): New.
7314 (value_range::null_p): New.
7315 (value_range::equiv_add): New.
7316 (copy_value_range): Remove.
7318 2018-10-17 David Malcolm <dmalcolm@redhat.com>
7320 * Makefile.in (SELFTEST_TARGETS): New.
7321 (selftest) Change from s-selftest-c to $(SELFTEST_TARGETS).
7322 (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb)
7323 (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move to
7325 (CPP_SELFTEST_FLAGS, CPP_SELFTEST_DEPS, s-selftest-c++)
7326 (selftest-c++-gdb, selftest-c++-valgrind): Move to
7328 * configure: Regenerate.
7329 * configure.ac (selftest_languages): New.
7331 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
7333 * tree-vrp.c (extract_range_from_multiplicative_op): Remove
7334 overflow wraps argument.
7335 (extract_range_from_binary_expr_1): Do not pass overflow wraps to
7336 wide_int_range_multiplicative_op.
7337 * wide-int-range.cc (wide_int_range_mult_wrapping): Remove
7338 overflow wraps argument.
7339 (wide_int_range_multiplicative_op): Same.
7340 (wide_int_range_lshift): Same.
7341 (wide_int_range_div): Same.
7342 * wide-int-range.h (wide_int_range_multiplicative_op): Same.
7343 (wide_int_range_lshift): Same.
7344 (wide_int_range_div): Same.
7346 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
7348 * wide-int-range.h (wide_int_range_shift_undefined_p): Adjust to
7349 use sign as argument.
7350 * tree-vrp.c (extract_range_from_binary_expr_1): Pass sign to
7351 wide_int_range_shift_undefined_p.
7353 2018-10-16 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
7355 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>):
7357 (@despeculate_copy<ALLI_TI:mode>): ... This.
7358 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): Remove
7361 2018-10-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7363 * config.gcc: Obsolete *-*-solaris2.10*.
7364 * doc/install.texi (Specific, *-*-solaris2*): Document it.
7366 2018-10-12 Jeff Law <law@redhat.com>
7368 * config/ft32/ft32.md (ft32_general_movsrc_operand): Disable
7369 reg + sym +- const_int addressing modes.
7371 2018-10-15 David Malcolm <dmalcolm@redhat.com>
7373 * common.opt (fdiagnostics-minimum-margin-width=): New option.
7374 * diagnostic-show-locus.c (layout::layout): Apply the minimum
7376 (layout::start_annotation_line): Only print up to 3 of the
7377 margin character, to avoid touching the left-hand side.
7378 (selftest::test_diagnostic_show_locus_fixit_lines): Update for
7379 minimum margin width, as set by test_diagnostic_context's ctor.
7380 (selftest::test_fixit_insert_containing_newline): Likewise.
7381 (selftest::test_fixit_insert_containing_newline_2): Likewise.
7382 (selftest::test_line_numbers_multiline_range): Clear
7383 dc.min_margin_width.
7384 * diagnostic.c (diagnostic_initialize): Initialize
7386 * diagnostic.h (struct diagnostic_context): Add field
7388 * doc/invoke.texi: Add -fdiagnostics-minimum-margin-width=.
7389 * opts.c (common_handle_option): Handle
7390 OPT_fdiagnostics_minimum_margin_width_.
7391 * selftest-diagnostic.c
7392 (selftest::test_diagnostic_context::test_diagnostic_context):
7393 Initialize min_margin_width to 6.
7394 * toplev.c (general_init): Initialize global_dc->min_margin_width.
7396 2018-10-15 David Malcolm <dmalcolm@redhat.com>
7398 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
7399 Fix usage of "error_at_rich_loc" in the comment.
7401 2018-10-15 Renlin Li <renlin.li@arm.com>
7404 * tree-vectorizer.c (try_vectorize_loop_1): Don't use
7405 if-conversioned loop when it contains ifn with types not
7406 supported by backend.
7407 * internal-fn.c (expand_direct_optab_fn): Add an assert.
7408 (direct_internal_fn_supported_p): New helper function.
7409 * internal-fn.h (direct_internal_fn_supported_p): Declare.
7411 2018-10-15 Jakub Jelinek <jakub@redhat.com>
7414 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
7415 Remove OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
7416 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
7418 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
7420 PR tree-optimization/87022
7421 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
7422 bits in dist vector rather than the first one.
7424 2018-10-15 Richard Biener <rguenther@suse.de>
7427 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
7428 (visit_loadstore): When a used restrict tag escaped verify that
7429 the points-to solution of "other" pointers do not include
7431 (compute_dependence_clique): If a used restrict tag escaped
7432 communicated that down to visit_loadstore.
7434 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
7436 * config/s390/s390.c (s390_expand_vec_init): Force vector element
7437 into reg if it isn't a general operand.
7439 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
7442 * config/i386/sse.md (*vec_dupv2di): Add register source to
7445 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
7448 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
7449 Add OPTION_MASK_ISA_AVX512IFMA_UNSET,
7450 OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
7451 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
7453 2018-10-13 Eric Botcazou <ebotcazou@adacore.com>
7455 * dwarf2cfi.c (struct dw_trace_info): Add args_size_defined_for_eh.
7456 (notice_args_size): Set it in the current trace if no insn that can
7457 throw internally has been seen yet.
7458 (connect_traces): When connecting args_size between traces, allow the
7459 incoming values not to match if there is an insn setting it before the
7460 first insn that can throw internally; in that case, force the creation
7461 of a CFI note on this latter insn.
7463 2018-10-13 Jonathan Wakely <jwakely@redhat.com>
7465 * opt-problem.h (opt_wrapper): Use template-argument-list when naming
7466 the base class, because using the injected-class-name was not clearly
7467 specified until DR 176.
7469 2018-10-12 Paul Koning <ni1d@arrl.net>
7471 * config/pdp11/pdp11.md (doloop_end): New expander.
7472 (doloop_end_insn): renamed from "doloop_end".
7473 (addqi3): New pattern.
7474 (subqi3): New pattern.
7475 * config/pdp11/predicates.md (incdec_operand): New predicate.
7477 2018-10-12 Yury Gribov <tetra2005@gmail.com>
7480 * real.c (format_helper::can_represent_integral_type_p): New function
7481 * real.h (format_helper::can_represent_integral_type_p): Ditto.
7482 * match.pd: New pattern.
7484 2018-10-12 Alexandre Oliva <oliva@adacore.com>
7486 * configure.ac: Introduce --enable-large-address-aware
7487 to define MINGW_DEFAULT_LARGE_ADDR_AWARE.
7488 * doc/install.texi: Document it.
7489 * configure, config.in: Rebuilt.
7490 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Define,
7491 based on MINGW_DEFAULT_LARGE_ADDR_AWARE.
7492 (LINK_SPEC): Insert it.
7493 * config/i386/mingw-w64.h: Likewise.
7495 * cygming.h (HAVE_GAS_ALIGNED_COMM): Fallback-define.
7497 2018-10-12 Peter Bergner <bergner@linux.ibm.com>
7499 PR rtl-optimization/87600
7500 * ira-lives (non_conflicting_reg_copy_p): Disable for non LRA targets.
7502 2018-10-12 Paul Koning <ni1d@arrl.net>
7504 * doc/md.texi (doloop_end): Document that the pattern code may
7505 need to check operand mode.
7507 2018-10-12 Wilco Dijkstra <wdijkstr@arm.com>
7509 * config/aarch64/aarch64.md (zero_extendsidi2_aarch64): Add alternatives
7510 to zero-extend between int and floating-point registers.
7511 (load_pair_zero_extendsidi2_aarch64): Add alternative for zero-extended
7512 ldp into floating-point registers. Add type and arch attributes.
7513 (zero_extend<SHORT:mode><GPI:mode>2_aarch64): Add arch attribute.
7514 Use f_loads for type attribute.
7516 2018-10-11 Martin Sebor <msebor@redhat.com>
7518 * doc/extend.texi (attribute packed): Correct typos.
7520 2018-10-11 Martin Sebor <msebor@redhat.com>
7522 * doc/extend.texi (attribute flatten): Mention interaction with
7525 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
7528 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
7529 Set new_decl virtual flag to zero.
7531 2018-10-11 Martin Sebor <msebor@redhat.com>
7534 * doc/extend.texi (attribute format_arg): Discuss using multiple
7535 attributes on a single function.
7537 2018-10-11 Giuliano Belinassi <giuliano.belinassi@usp.br>
7539 PR tree-optimization/86829
7540 * match.pd (sin (atan (x))): New simplification rules.
7541 (cos (atan (x))): Likewise.
7542 * real.c (build_sinatan_real): New function.
7543 * real.h (build_sinatan_real): Prototype.
7545 2018-10-11 Will Schmidt <will_schmidt@vnet.ibm.com>
7547 * config/rs6000/rs6000.c (map_to_integral_tree_type): New helper
7549 (fold_mergeeo_helper): New helper function.
7550 (rs6000_gimple_fold_builtin): Add hooks for vec_mergee and vec_mergeo
7551 intrinsics. Correct some whitespace indentation issues.
7553 2018-10-11 Wilco Dijkstra <wdijkstr@arm.com>
7556 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
7557 Use HOST_WIDE_INT_1U for shift.
7559 2018-10-11 Doug Rupp <rupp@adacore.com>
7560 Olivier Hainque <hainque@adacore.com>
7562 * config/rs6000/vxworks.h (VXWORKS_RELAX_LINK_SPEC): New macro.
7563 Pass --relax to the linker for RTPs.
7564 (LINK_SPEC): Append VXWORKS_RELAX_LINK_SPEC.
7566 2018-10-11 Andrew Stubbs <ams@codesourcery.com>
7567 Jan Hubicka <jh@suse.cz>
7568 Martin Jambor <mjambor@suse.cz>
7570 * print-rtl.c (print_rtx_operand_codes_E_and_V): Print how many times
7571 the same elements are repeated rather than printing all of them.
7572 * read-rtl.c (rtx_reader::read_rtx_operand): Recognize and expand
7573 "repeated" elements.
7574 * read-rtl-function.c (test_loading_repeat): New function.
7575 (read_rtl_function_c_tests): Call test_loading_repeat.
7576 * rtl-tests.c (test_dumping_repeat): New function.
7577 (rtl_tests_c_tests): Call test_dumping_repeat.
7579 2018-10-11 Richard Biener <rguenther@suse.de>
7581 * config/i386/x86-tune-costs.h (bdver?_memcpy, bdver?_memset,
7582 bdver?_cost): Unify to ...
7583 (bdver_memcpy, bdver_memset, bdver_cost): ... this.
7584 * config/i386/i386.c (processor_cost_table): Adjust.
7586 2018-10-10 Eric Botcazou <ebotcazou@adacore.com>
7589 * cgraphunit.c (cgraph_node::expand_thunk): Force DECL_IGNORED_P on
7590 the thunk when expanding to GIMPLE.
7592 2018-10-10 Bernd Edlinger <bernd.edlinger@hotmail.de>
7595 * varasm.c (mergeable_string_section): Don't try to move zero-length
7596 strings to the merge section.
7598 2018-10-10 Uros Bizjak <ubizjak@gmail.com>
7601 * config/i386/mmx.md (const_vector 0 -> mem splitter): New splitter.
7603 2018-10-10 Jakub Jelinek <jakub@redhat.com>
7606 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
7607 to special_args set.
7609 2018-10-10 Richard Biener <rguenther@suse.de>
7611 * config/i386/sse.md (reduc_plus_scal_v8df, reduc_plus_scal_v4df,
7612 reduc_plus_scal_v2df, reduc_plus_scal_v16sf, reduc_plus_scal_v8sf,
7613 reduc_plus_scal_v4sf): Merge into pattern reducing to half width
7614 and recursing and pattern terminating the recursion on SSE
7615 vector width using ix86_expand_reduc.
7616 (reduc_sminmax_scal_<mode>): Split into part reducing to half
7617 width and recursing and SSE2 vector variant doing the final
7618 reduction with ix86_expand_reduc.
7619 (reduc_uminmax_scal_<mode>): Likewise for the AVX512 variants
7620 with terminating the recursion at AVX level, splitting that
7623 2018-10-09 David Malcolm <dmalcolm@redhat.com>
7625 * genmatch.c (error_cb): Rename to...
7626 (diagnostic_cb): ...this, converting int params to enums.
7627 (fatal_at): Update for renaming.
7628 (warning_at): Likewise.
7630 * input.c (selftest::ebcdic_execution_charset::apply):
7631 Update for renaming of...
7632 (selftest::ebcdic_execution_charset::on_error): ...this, renaming
7634 (selftest::ebcdic_execution_charset::on_diagnostic): ...this,
7635 converting level and reason to enums.
7636 (class selftest::lexer_error_sink): Rename to...
7637 (class selftest::lexer_test_options): ...this, renaming field
7638 "m_errors" to "m_diagnostics".
7639 (selftest::lexer_test_options::apply): Update for renaming of...
7640 (selftest::lexer_test_options::on_error): ...this, renaming to...
7641 (selftest::lexer_test_options::on_diagnostic): ...this
7642 converting level and reason to enums.
7643 (selftest::test_lexer_string_locations_raw_string_unterminated):
7644 Update for renamings.
7645 * opth-gen.awk (struct cpp_reason_option_codes_t): Use enum for
7648 2018-10-09 Paul A. Clarke <pc@us.ibm.com>
7650 * config.gcc (powerpc*-*-*): Add pmmintrin.h to extra_headers.
7651 * config/rs6000/pmmintrin.h: New file.
7653 2018-10-09 Eric Botcazou <ebotcazou@adacore.com>
7655 PR tree-optimization/86659
7656 * gimple-match.h (gimple_match_op constructors): Initialize reverse.
7658 2018-10-09 Richard Biener <rguenther@suse.de>
7660 PR tree-optimization/63155
7661 * tree-ssa-structalias.c: Include tree-ssa.h.
7662 (get_constraint_for_ssa_var): For undefs return nothing_id.
7663 (find_func_aliases): Cleanup PHI handling.
7665 2018-10-09 Richard Biener <rguenther@suse.de>
7667 * tree-vectorizer.c (dump_stmt_cost): Fix cut&paste missing
7670 2018-10-09 Martin Liska <mliska@suse.cz>
7672 * asan.c (asan_emit_stack_protection): If a stack variable
7673 is located in a same file as current function, then emit
7674 line info into variable definition string.
7676 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
7678 * print-rtl.c (rtx_writer::print_rtx_operand_code_i): Print column
7681 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
7683 * cgraphunit.c (cgraph_node::expand_thunk): Do not force DECL_IGNORED_P
7686 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
7688 PR tree-optimization/86659
7689 * gimple-match.h (struct gimple_match_op): Add reverse field.
7690 (gimple_match_op::set_op): New overloaded method.
7691 * gimple-match-head.c (maybe_build_generic_op) <BIT_FIELD_REF>: Set
7692 the REF_REVERSE_STORAGE_ORDER flag on the value.
7693 (gimple_simplify) <GIMPLE_ASSIGN>: For BIT_FIELD_REF, propagate the
7694 REF_REVERSE_STORAGE_ORDER flag and avoid simplifying if it is set.
7696 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
7699 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
7700 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
7702 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
7705 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
7706 Defined with __builtin_ia32_vfmaddsubpd512_mask.
7708 2018-10-08 Richard Biener <rguenther@suse.de>
7710 * config/i386/x86-tune-costs.h (znver1_cost): Make AVX256 vector loads
7711 cost the same as AVX128 ones.
7713 2018-10-08 Paul Koning <ni1d@arrl.net>
7715 * config/pdp11/pdp11-protos.h (output_block_move): Remove.
7716 (expand_block_move): New function.
7717 * config/pdp11/pdp11.c (output_block_move): Remove.
7718 (expand_block_move): New function.
7719 * config/pdp11/pdp11.h (MOVE_RATIO): New definition.
7720 * config/pdp11/pdp11.md (movmemhi): Use expand_block_move.
7721 (*movmemhi1): Remove.
7723 2018-10-08 Robin Dapp <rdapp@linux.ibm.com>
7725 * config/s390/2827.md: Increase latencies for some FP instructions.
7727 2018-10-08 Richard Biener <rguenther@suse.de>
7729 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
7731 * tree-vectorizer.c (dump_stmt_cost): Add cost param and dump it.
7732 * tree-vectorizer.h (dump_stmt_cost): Adjust.
7733 (add_stmt_cost): Dump return value of the hook.
7735 2018-10-08 Richard Biener <rguenther@suse.de>
7737 PR tree-optimization/63155
7738 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
7739 (ssa_propagation_engine::ssa_propagate): Remove redundant
7740 bitmap bit clearing.
7742 2018-10-05 Peter Bergner <bergner@linux.ibm.com>
7744 PR rtl-optimization/86939
7745 PR rtl-optimization/87479
7746 * ira.h (non_conflicting_reg_copy_p): New prototype.
7747 * ira-lives.c (ignore_reg_for_conflicts): New static variable.
7748 (make_hard_regno_dead): Don't add conflicts for register
7749 ignore_reg_for_conflicts.
7750 (make_object_dead): Likewise.
7751 (non_conflicting_reg_copy_p): New function.
7752 (process_bb_node_lives): Set ignore_reg_for_conflicts for copies.
7753 Remove special conflict handling of REAL_PIC_OFFSET_TABLE_REGNUM.
7754 * lra-lives.c (ignore_reg_for_conflicts): New static variable.
7755 (make_hard_regno_dead): Don't add conflicts for register
7756 ignore_reg_for_conflicts. Remove special conflict handling of
7757 REAL_PIC_OFFSET_TABLE_REGNUM. Remove now unused argument
7758 check_pic_pseudo_p and update callers.
7759 (mark_pseudo_dead): Don't add conflicts for register
7760 ignore_reg_for_conflicts.
7761 (process_bb_lives): Set ignore_reg_for_conflicts for copies.
7763 2018-10-05 Andrew Waterman <andrew@sifive.com>
7764 Jim Wilson <jimw@sifive.com>
7766 * config/riscv/riscv.md (f<quiet_pattern>_quiet<ANYF:mode><X:mode>4):
7767 Add define_expand. Add ! HONOR_SNANS check to current pattern. Add
7768 new pattern using HONOR_SNANS that emits one extra instruction.
7770 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
7772 * config/rs6000/rs6000.md (unnamed mfcr scc_comparison_operator
7773 patterns): Merge SI and DI patterns to a GPR pattern.
7774 (unnamed define_insn and define_split for record form of that): Merge
7775 to a single define_insn_and_split pattern.
7777 2018-10-05 David Malcolm <dmalcolm@redhat.com>
7780 * input.c (expand_location_to_spelling_point): Add param "aspect"
7781 and use rather than hardcoding LOCATION_ASPECT_CARET.
7782 (get_substring_ranges_for_loc): Handle the case of a single token
7783 within a macro expansion.
7784 * input.h (expand_location_to_spelling_point): Add "aspect" param,
7785 defaulting to LOCATION_ASPECT_CARET.
7787 2018-10-05 Paul Koning <ni1d@arrl.net>
7789 * config/pdp11/pdp11.c (TARGET_CXX_GUARD_TYPE): Define.
7790 (TARGET_CXX_CLASS_DATA_ALWAYS_COMDAT): Define.
7791 (TARGET_CXX_LIBRARY_RTTI_COMDAT): Define.
7792 (pdp11_guard_type): New function.
7794 2018-10-05 Paul Koning <ni1d@arrl.net>
7796 * config/pdp11/pdp11.h (FLOAT_TYPE_SIZE): Always 32.
7797 * config/pdp11/pdp11.opt (mfloat32): Remove.
7799 * doc/invoke.texi (pdp11 -mfloat32): Remove:
7800 (pdp11 -mfloat64): Remove.
7802 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
7804 * config/i386/i386.md (*cmpxf_cc_i387): Remove pattern.
7805 (*cmp<mode>_cc_i387): Ditto.
7806 (*cmpu<mode>_cc_i387): Ditto.
7807 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
7808 * config/i386/i386.c (ix86_expand_fp_compare): Remove
7810 <case IX86_FPCMP_SAHF>: Do not generate pattern with HImode clobber.
7811 Emit x86_sahf_1 pattern.
7812 (ix86_expand_compare): Update call to ix86_expand_fp_compare.
7813 (ix86_expand_carry_flag_compare): Ditto.
7815 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
7817 * config/i386/i386.md (*cmpxf_i387): Change operand 2 predicate
7818 to reg_or_0_operand. Add "C" constraint.
7819 (*cmpxf_cc_i387): Ditto.
7820 (*cmp<mode>_i387): Change operand 2 predicate
7821 to nonimm_or_0_operand. Add "C" constraint.
7822 (*cmp<mode>_cc_i387): Ditto.
7823 (*cmp<mode>_0_i387): Remove insn pattern.
7824 (*cmp<mode>_0_cc_i387): Ditto.
7826 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
7828 * config/i386/constraints.md ("C"): Do not depend on TARGET_SSE.
7829 * config/i386/predicates.md (nonimm_or_0_operand): Rename
7830 from vector_move_operand. Update all uses.
7832 2018-10-05 Martin Sebor <msebor@redhat.com>
7834 PR tree-optimization/87490
7835 * builtins.c (expand_builtin_strnlen): Handle a null data.decl
7838 2018-10-05 Richard Biener <rguenther@suse.de>
7840 PR tree-optimization/63155
7841 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
7842 vertical space in dumpfiles.
7843 * tree-ssa-propagate.h
7844 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
7845 * tree-ssa-propagate.c (cfg_blocks_back): New global.
7846 (ssa_edge_worklist_back): Likewise.
7847 (curr_order): Likewise.
7848 (cfg_blocks_get): Remove abstraction.
7849 (cfg_blocks_add): Likewise.
7850 (cfg_blocks_empty_p): Likewise.
7851 (add_ssa_edge): Add to current or next worklist based on
7853 (add_control_edge): Likewise.
7854 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
7856 (ssa_propagation_engine::ssa_propagate): ... here. Unify
7857 iteration from CFG and SSA edge worklist so we process
7858 everything in RPO order, prioritizing forward progress
7860 (ssa_prop_init): Allocate new worklists, do not dump
7862 (ssa_prop_fini): Free new worklists.
7864 2018-10-05 Richard Biener <rguenther@suse.de>
7866 * tree-core.h (tree_block::abstract_flag): Remove.
7867 (tree_block::block_num): Make full 32bits.
7868 * tree.def (BLOCK): Remove docs about BLOCK_ABSTRACT.
7869 * tree.h (BLOCK_ABSTRACT): Remove.
7870 * dwarf2out.c (gen_lexical_block_die): Remove dead code
7871 resulting from BLOCK_ABSTRACT being always false.
7872 (gen_inlined_subroutine_die): Likewise.
7873 (gen_block_die): Likewise.
7874 * tree.c (block_ultimate_origin): Likewise.
7875 * tree-pretty-print.c (dump_block_node): Remove code dealing
7876 with BLOCK_ABSTRACT.
7877 * tree-ssa-live.c (dump_scope_block): Likewise.
7878 * tree-streamer-in.c (unpack_ts_block_value_fields): Likewise.
7879 * tree-streamer-out.c (pack_ts_block_value_fields): Likewise.
7881 2018-10-05 Richard Biener <rguenther@suse.de>
7883 * config/i386/i386.c (ix86_add_stmt_cost): When scalar cost
7884 is asked for initialize mode to the component mode of the
7887 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
7890 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
7891 assembler for -mavx.
7892 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
7894 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
7897 * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_SET_FPSCR_DRN): Use
7899 * config/rs6000/rs6000.md (rs6000_set_fpscr_rn): Require the operand
7900 to be DImode. When using mffscrn, force the operand to a register.
7902 2018-10-04 Uros Bizjak <ubizjak@gmail.com>
7904 * config/i386/i386.md (*fop_<X87MODEF:mode>_2_i387): Macroize insn
7905 from *fop_<MODEF:mode>_2_i387 and *fop_xf_2_i387 using
7906 X87MODEF mode iterator.
7907 (*fop_<X87MODEF:mode>_3_i387): Macroize insn from
7908 *fop_<MODEF:mode>_3_i387 and *fop_xf_3_i387 using
7909 X87MODEF mode iterator.
7911 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
7913 * doc/invoke.texi (-Wno-prio-ctor-dtor): Document new warning
7914 -Wno-prio-ctor-dtor.
7916 2018-10-04 David Malcolm <dmalcolm@redhat.com>
7918 * Makefile.in (OBJS): Add opt-problem.o.
7919 * dump-context.h: Include "selftest.h.
7920 (selftest::temp_dump_context): New forward decl.
7921 (class dump_context): Make friend of class
7922 selftest::temp_dump_context.
7923 (dump_context::dump_loc_immediate): New decl.
7924 (class dump_pretty_printer): Move here from dumpfile.c.
7925 (class temp_dump_context): Move to namespace selftest.
7926 (temp_dump_context::temp_dump_context): Add param
7927 "forcibly_enable_dumping".
7928 (selftest::verify_dumped_text):
7929 (ASSERT_DUMPED_TEXT_EQ): Move here from dumpfile.c.
7930 (selftest::verify_item):
7931 (ASSERT_IS_TEXT): Move here from dumpfile.c.
7932 (ASSERT_IS_TREE): Likewise.
7933 (ASSERT_IS_GIMPLE): Likewise.
7934 * dumpfile.c (dump_context::dump_loc): Move immediate dumping
7936 (dump_context::dump_loc_immediate): ...this new function.
7937 (class dump_pretty_printer): Move to dump-context.h.
7938 (dump_switch_p_1): Don't enable MSG_PRIORITY_REEMITTED.
7939 (opt_info_switch_p_1): Enable MSG_PRIORITY_REEMITTED.
7940 (temp_dump_context::temp_dump_context): Move to "selftest"
7941 namespace. Add param "forcibly_enable_dumping", and use it to
7942 conditionalize the use of m_pp;
7943 (selftest::verify_dumped_text): Make non-static.
7944 (ASSERT_DUMPED_TEXT_EQ): Move to dump-context.h.
7945 (selftest::verify_item): Make non-static.
7946 (ASSERT_IS_TEXT): Move to dump-context.h.
7947 (ASSERT_IS_TREE): Likewise.
7948 (ASSERT_IS_GIMPLE): Likewise.
7949 (selftest::test_capture_of_dump_calls): Pass "true" for new
7950 param of temp_dump_context.
7951 * dumpfile.h (enum dump_flag): Add MSG_PRIORITY_REEMITTED, adding
7952 it to MSG_ALL_PRIORITIES. Update values of TDF_COMPARE_DEBUG and
7954 * opt-problem.cc: New file.
7955 * opt-problem.h: New file.
7956 * optinfo-emit-json.cc
7957 (selftest::test_building_json_from_dump_calls): Pass "true" for
7958 new param of temp_dump_context.
7959 * optinfo.cc (optinfo_kind_to_dump_flag): New function.
7960 (optinfo::emit_for_opt_problem): New function.
7961 (optinfo::emit): Clarity which emit_item is used.
7962 * optinfo.h (optinfo::get_dump_location): New accessor.
7963 (optinfo::emit_for_opt_problem): New decl.
7964 (optinfo::emit): Make const.
7965 * selftest-run-tests.c (selftest::run_tests): Call
7966 selftest::opt_problem_cc_tests.
7967 * selftest.h (selftest::opt_problem_cc_tests): New decl.
7968 * tree-data-ref.c (dr_analyze_innermost): Convert return type from
7969 bool to opt_result, converting fprintf messages to
7970 opt_result::failure_at calls. Add "stmt" param for use by the
7972 (create_data_ref): Pass "stmt" to the dr_analyze_innermost call.
7973 (runtime_alias_check_p): Convert return type from bool to
7974 opt_result, converting dump_printf calls to
7975 opt_result::failure_at, using the statement DDR_A for their
7977 (find_data_references_in_stmt): Convert return type from bool to
7978 opt_result, converting "return false" to opt_result::failure_at
7980 * tree-data-ref.h: Include "opt-problem.h".
7981 (dr_analyze_innermost): Convert return type from bool to opt_result,
7982 and add a const gimple * param.
7983 (find_data_references_in_stmt): Convert return type from bool to
7985 (runtime_alias_check_p): Likewise.
7986 * tree-predcom.c (find_looparound_phi): Pass "init_stmt" to
7987 dr_analyze_innermost.
7988 * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test):
7989 Convert return type from bool to opt_result, adding a message for
7990 the PARAM_VECT_MAX_VERSION_FOR_ALIAS_CHECKS zero case.
7991 (vect_analyze_data_ref_dependence): Convert return type from bool
7992 to opt_result. Change sense of return type from "false"
7993 effectively meaning "no problems" to "false" meaning a problem,
7994 so that "return false" becomes "return opt_result::success".
7995 Convert "return true" calls to opt_result::failure_at, using
7996 the location of statement A rather than vect_location.
7997 (vect_analyze_data_ref_dependences): Convert return type from bool
7999 (verify_data_ref_alignment): Likewise, converting dump_printf_loc
8000 calls to opt_result::failure_at, using the stmt location rather
8002 (vect_verify_datarefs_alignment): Convert return type from bool
8004 (vect_enhance_data_refs_alignment): Likewise. Split local "stat"
8005 into multiple more-tightly-scoped copies.
8006 (vect_analyze_data_refs_alignment): Convert return type from bool
8008 (vect_analyze_data_ref_accesses): Likewise, converting a
8009 "return false" to a "return opt_result::failure_at", adding a
8011 (vect_prune_runtime_alias_test_list): Convert return type from
8012 bool to opt_result, converting dump_printf_loc to
8013 opt_result::failure_at. Add a %G to show the pertinent statement,
8014 and use the stmt's location rather than vect_location.
8015 (vect_find_stmt_data_reference): Convert return type from
8016 bool to opt_result, converting dump_printf_loc to
8017 opt_result::failure_at, using stmt's location.
8018 (vect_analyze_data_refs): Convert return type from bool to
8019 opt_result. Convert "return false" to "return
8020 opt_result::failure_at", adding messages as needed.
8021 * tree-vect-loop.c (vect_determine_vf_for_stmt_1): Convert return
8022 type from bool to opt_result.
8023 (vect_determine_vf_for_stmt): Likewise.
8024 (vect_determine_vectorization_factor): Likewise, converting
8025 dump_printf_loc to opt_result::failure_at, using location of phi
8026 rather than vect_location.
8027 (vect_analyze_loop_form_1): Convert return type from bool to
8028 opt_result, converting dump_printf_loc calls, retaining the use of
8030 (vect_analyze_loop_form): Convert return type from loop_vec_info
8031 to opt_loop_vec_info.
8032 (vect_analyze_loop_operations): Convert return type from bool to
8033 opt_result, converting dump_printf_loc calls, using the location
8034 of phi/stmt rather than vect_location where available. Convert
8035 various "return false" to "return opt_result::failure_at" with
8036 "unsupported phi" messages.
8037 (vect_get_datarefs_in_loop): Convert return type from bool to
8038 opt_result. Add a message for the
8039 PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS failure.
8040 (vect_analyze_loop_2): Convert return type from bool to
8041 opt_result. Ensure "ok" is set to a opt_result::failure_at before
8042 each "goto again;", adding new messages where needed.
8043 Add "unsupported grouped {store|load}" messages.
8044 (vect_analyze_loop): Convert return type from loop_vec_info to
8046 * tree-vect-slp.c (vect_analyze_slp): Convert return type from
8048 * tree-vect-stmts.c (process_use): Likewise, converting
8049 dump_printf_loc call and using stmt location, rather than
8051 (vect_mark_stmts_to_be_vectorized): Likeise.
8052 (vect_analyze_stmt): Likewise, adding a %G.
8053 (vect_get_vector_types_for_stmt): Convert return type from bool to
8054 opt_result, converting dump_printf_loc calls and using stmt
8055 location, rather than vect_location.
8056 (vect_get_mask_type_for_stmt): Convert return type from tree to
8057 opt_tree, converting dump_printf_loc calls and using stmt location.
8058 * tree-vectorizer.c: Include "opt-problem.h.
8059 (try_vectorize_loop_1): Flag "Analyzing loop at" dump message as
8060 MSG_PRIORITY_INTERNALS. Convert local "loop_vinfo" from
8061 loop_vec_info to opt_loop_vec_info. If if fails, and dumping is
8062 enabled, use it to report at the top level "couldn't vectorize
8063 loop" followed by the problem.
8064 * tree-vectorizer.h (opt_loop_vec_info): New typedef.
8065 (vect_mark_stmts_to_be_vectorized): Convert return type from bool
8067 (vect_analyze_stmt): Likewise.
8068 (vect_get_vector_types_for_stmt): Likewise.
8069 (tree vect_get_mask_type_for_stmt): Likewise.
8070 (vect_analyze_data_ref_dependences): Likewise.
8071 (vect_enhance_data_refs_alignment): Likewise.
8072 (vect_analyze_data_refs_alignment): Likewise.
8073 (vect_verify_datarefs_alignment): Likewise.
8074 (vect_analyze_data_ref_accesses): Likewise.
8075 (vect_prune_runtime_alias_test_list): Likewise.
8076 (vect_find_stmt_data_reference): Likewise.
8077 (vect_analyze_data_refs): Likewise.
8078 (vect_analyze_loop): Convert return type from loop_vec_info to
8080 (vect_analyze_loop_form): Likewise.
8081 (vect_analyze_slp): Convert return type from bool to opt_result.
8083 2018-10-04 David Malcolm <dmalcolm@redhat.com>
8085 * doc/invoke.texi (-fopt-info): Document new "internals"
8087 * dump-context.h (dump_context::apply_dump_filter_p): New decl.
8088 * dumpfile.c (dump_options): Update for renaming of MSG_ALL to
8090 (optinfo_verbosity_options): Add "internals".
8091 (kind_as_string): Update for renaming of MSG_ALL to MSG_ALL_KINDS.
8092 (dump_context::apply_dump_filter_p): New member function.
8093 (dump_context::dump_loc): Use apply_dump_filter_p rather than
8094 explicitly masking the dump_kind.
8095 (dump_context::begin_scope): Increment the scope depth first. Use
8096 apply_dump_filter_p rather than explicitly masking the dump_kind.
8097 (dump_context::emit_item): Use apply_dump_filter_p rather than
8098 explicitly masking the dump_kind.
8099 (dump_dec): Likewise.
8100 (dump_hex): Likewise.
8101 (dump_switch_p_1): Default to MSG_ALL_PRIORITIES.
8102 (opt_info_switch_p_1): Default to MSG_PRIORITY_USER_FACING.
8103 (opt_info_switch_p): Update handling of default
8104 MSG_OPTIMIZED_LOCATIONS to cope with default of
8105 MSG_PRIORITY_USER_FACING.
8106 (dump_basic_block): Use apply_dump_filter_p rather than explicitly
8107 masking the dump_kind.
8108 (selftest::test_capture_of_dump_calls): Update test_dump_context
8109 instances to use MSG_ALL_KINDS | MSG_PRIORITY_USER_FACING rather
8110 than MSG_ALL. Generalize scope test to be run at all four
8111 combinations of with/without MSG_PRIORITY_USER_FACING and
8112 MSG_PRIORITY_INTERNALS, adding examples of explicit priority
8113 for each of the two values.
8114 * dumpfile.h (enum dump_flag): Add comment about the MSG_* flags.
8115 Rename MSG_ALL to MSG_ALL_KINDS. Add MSG_PRIORITY_USER_FACING,
8116 MSG_PRIORITY_INTERNALS, and MSG_ALL_PRIORITIES, updating the
8117 values for TDF_COMPARE_DEBUG and TDF_ALL_VALUES.
8118 (AUTO_DUMP_SCOPE): Add a note to the comment about the interaction
8119 with MSG_PRIORITY_*.
8120 * tree-vect-loop-manip.c (vect_loop_versioning): Mark versioning
8121 dump messages as MSG_PRIORITY_USER_FACING.
8122 * tree-vectorizer.h (DUMP_VECT_SCOPE): Add a note to the comment
8123 about the interaction with MSG_PRIORITY_*.
8125 2018-10-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
8127 * varasm.c (output_constant): Add new parameter merge_strings.
8128 Make strings properly zero terminated in merge string sections.
8129 (mergeable_string_section): Don't fail if the last char is non-zero.
8130 (assemble_variable_contents): Handle merge string sections.
8131 (assemble_variable): Likewise.
8132 (assemble_constant_contents): Likewise.
8133 (output_constant_def_contents): Likewise.
8134 (output_constructor_array_range,
8135 output_constructor_regular_field): Adjust call to output_constant.
8136 (output_object_block): Adjust call to assemble_constant_contents
8137 and assemble_variable_contents.
8139 2018-10-04 Martin Liska <mliska@suse.cz>
8142 * cgraphunit.c (process_function_and_variable_attributes):
8143 Warn about a function with alias attribute and a body.
8145 2018-10-04 Martin Liska <mliska@suse.cz>
8148 * multiple_target.c (redirect_to_specific_clone): New function.
8149 (ipa_target_clone): Use it.
8150 * tree-inline.c: Fix comment.
8152 2018-10-04 David Malcolm <dmalcolm@redhat.com>
8154 * dumpfile.c (gcc::dump_manager::dump_manager): Initialize new
8156 (gcc::dump_manager::~dump_manager): Free m_optinfo_filename.
8157 (gcc::dump_manager::register_pass): New member function, adapted
8158 from loop body in gcc::pass_manager::register_pass, adding a
8159 call to update_dfi_for_opt_info.
8160 (gcc::dump_manager::opt_info_enable_passes): Store the
8161 -fopt-info options into the new fields. Move the loop
8163 (gcc::dump_manager::update_dfi_for_opt_info): ...this new member
8165 * dumpfile.h (struct opt_pass): New forward decl.
8166 (gcc::dump_manager::register_pass): New decl.
8167 (gcc::dump_manager::update_dfi_for_opt_info): New decl.
8168 (class gcc::dump_manager): Add fields "m_optgroup_flags",
8169 "m_optinfo_flags", and "m_optinfo_filename".
8170 * passes.c (gcc::pass_manager::register_pass): Move all of the
8171 dump-handling code to gcc::dump_manager::register_pass.
8173 2018-10-04 Peter Bergner <bergner@linux.ibm.com>
8175 PR rtl-optimization/87466
8176 * target.def (setjmp_preserves_nonvolatile_regs_p): New target hook.
8177 * doc/tm.texi.in (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P): New hook.
8178 * doc/tm.texi: Regenerate.
8179 * ira-lives.c (process_bb_node_lives): Use the new target hook.
8180 * lra-lives.c (process_bb_lives): Likewise.
8181 * config/rs6000/rs6000.c (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P):
8184 2018-10-04 Tamar Christina <tamar.christina@arm.com>
8186 * params.c (add_params): Fix initialization.
8188 2018-10-04 Martin Liska <mliska@suse.cz>
8190 PR gcov-profile/84107
8191 * tree-profile.c (init_ic_make_global_vars):
8192 Remove ic_void_ptr_var and ic_gcov_type_ptr_var.
8193 Come up with new ic_tuple* variables. Emit
8194 __gcov_indirect_call{,_topn} variables.
8195 (gimple_gen_ic_profiler): Access the variable
8197 (gimple_gen_ic_func_profiler): Access
8198 __gcov_indirect_call.callee field.
8199 (gimple_init_gcov_profiler): Use ptr_type_node.
8200 * value-prof.c (gimple_ic): Use ptr_type_node.
8202 2018-10-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
8204 PR tree-optimization/85787
8205 * ipa-pure-const.c (malloc_candidate_p_1): Move most of
8206 malloc_candidate_p into this function and add support for
8207 detecting multiple phis.
8208 (DUMP_AND_RETURN): Move from malloc_candidate_p into top-level macro.
8210 2018-10-04 Martin Liska <mliska@suse.cz>
8213 * ipa-inline.c (inline_to_all_callers_1):
8214 Call ultimate_alias_target for node being inlined.
8216 2018-10-03 Jeff Law <law@redhat.com>
8218 * gimple-ssa-sprintf.c (format_string): Do not hardcode size of
8220 * tree.c (get_typenode_from_name): Moved from fortran/trans-types.c.
8221 * tree.h (get_typenode_from_name): Prototype.
8223 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
8225 * config/i386/i386.md (*cmp<X87MODEF:mode>_<SWI24:mode>_i387):
8226 Change operand 2 predicate to nonimmediate_operand.
8227 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
8229 2018-10-03 Martin Sebor <msebor@redhat.com>
8230 Jeff Law <law@redhat.com>
8232 * gimple-ssa-sprintf.c (struct fmtresult): Add new member and
8234 (get_string_length): Detect unterminated arrays.
8235 (format_string): Same.
8236 (format_directive): Warn about unterminated arrays.
8237 (handle_gimple_call): Mark statements with no_warning as needed.
8239 2018-10-03 Jim Wilson <jimw@sifive.com>
8241 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): For ABI_ILP32E,
8242 also define __riscv_abi_rve. Delete trailing white space.
8244 2018-10-03 Paul Koning <ni1d@arrl.net>
8246 Enable LRA register allocator for PDP11.
8247 * config/pdp11/constraints.md (Q): Use define_memory_constraint.
8250 * config/pdp11/pdp11.c (pdp11_lra_p): New function.
8251 * config/pdp11/pdp11.opt (-mlra): New option.
8252 * doc/invoke.texi (PDP-11 Options): Document -mlra.
8254 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
8256 * config/i386/i386.md (*<absneg:code>extendsfdf2): Remove.
8257 (*<absneg:code>extend<mode>xf2): Ditto.
8259 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
8261 PR tree-optimization/87415
8262 * tree-vrp.c (set_value_range_with_overflow): Special case one bit
8265 2018-10-02 Jeff Law <law@redhat.com>
8267 * gimple-fold.c (get_range_strlen): Only set *nonstr when
8268 an unterminated string is discovered. Bubble up range
8269 even for unterminated strings.
8270 (gimple_fold_builtin_strlen): Do not fold if get_range_strlen
8271 indicates the string was not terminated via NONSTR.
8273 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
8275 * tree-vrp.c (extract_range_from_unary_expr): Special case all
8276 pointer conversions.
8277 Do not do anything special for anti-ranges.
8279 2018-10-03 Jérôme Lambourg <lambourg@adacore.com>
8281 * config/arm/vxworks.h (ARM_TARGET2_DWARF_FORMAT): Adjust to
8282 DW_EH_PE_pcrel | DW_EH_PE_indirect for RTPs.
8284 2018-10-03 Martin Liska <mliska@suse.cz>
8286 PR gcov-profile/86109
8287 * coverage.c (coverage_begin_function): Do not
8288 mark lambdas as artificial.
8289 * tree-core.h (struct GTY): Remove tm_clone_flag
8290 and introduce new lambda_function.
8291 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
8293 2018-10-02 Aaron Sawdey <acsawdey@linux.ibm.com>
8296 * config/rs6000/rs6000-string.c (expand_strn_compare): Check that both
8297 P8_VECTOR and VSX are enabled.
8299 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
8301 * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
8302 0x3907 as CPU model number.
8304 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
8306 * common/config/s390/s390-common.c: Rename PF_ARCH12 to PF_Z14.
8307 * config/s390/s390.h (enum processor_flags): Rename PF_ARCH12 to
8308 PF_Z14. Rename TARGET_CPU_ARCH12 to TARGET_CPU_Z14,
8309 TARGET_CPU_ARCH12_P to TARGET_CPU_Z14_P, TARGET_ARCH12 to
8310 TARGET_Z14, and TARGET_ARCH12_P to TARGET_Z14_P.
8311 * config/s390/s390.md: Likewise. Rename also the cpu attribute
8312 value from arch12 to z14.
8314 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
8316 * config/i386/i386.md (fxam<mode>2_i387_with_temp): Remove.
8318 (isinf<mode>2): Ditto.
8320 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
8322 * config/i386/i386.c (ix86_emit_i387_round): Extend op1 to XFmode
8323 before emitting fxam. Perform calculations in XFmode.
8325 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
8327 * match.pd (((X /[ex] A) +- B) * A): New transformation.
8329 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
8332 * fold-const.c (fold_plusminus_mult_expr): Handle complex and vectors.
8333 * tree.c (signed_or_unsigned_type_for): Handle complex.
8335 2018-10-02 Jeff Law <law@redhat.com>
8337 * gimple-fold.c (get_range_strlen): Remove dead code.
8339 2018-10-02 Martin Sebor <msebor@redhat.com>
8340 Jeff Law <law@redhat.com>
8342 * builtins.c (unterminated_array): Add new arguments.
8343 If argument is not terminated, bubble up size and exact
8345 (expand_builtin_strnlen): Detect, avoid expanding
8346 and diagnose unterminated arrays.
8347 (c_strlen): Fill in offset of start of unterminated strings.
8348 * builtins.h (unterminated_array): Update prototype.
8350 2018-10-02 Richard Biener <rguenther@suse.de>
8352 * config/i386/sse.md (reduc_plus_scal_v4df): Avoid the use
8353 of haddv4df, first reduce to SSE width and exploit the fact
8354 that we only need element zero with the reduction result.
8355 (reduc_plus_scal_v2df): Likewise.
8357 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
8359 * dojump.h (do_jump): Delete.
8360 (do_jump_1): Likewise.
8361 (split_comparison): Move around.
8362 * dojump.c (do_jump): Make static.
8363 (do_jump_1): Likewise.
8364 (jumpifnot): Move around.
8365 (jumpifnot_1): Likewise.
8367 (jumpif_1): Likewise.
8368 * expr.c (expand_expr_real_1): Call jumpif[not] instead of do_jump.
8370 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
8372 * reorg.c (make_return_insns): Use emit_copy_of_insn_after for the
8373 insns in the delay slot and add_insn_after for the jump insn.
8375 2018-10-02 Richard Biener <rguenther@suse.de>
8377 * tree-inline.c (expand_call_inline): Use the location of
8378 the callee declaration for the inline-entry marker.
8379 * final.c (notice_source_line): Remove special-casing of
8380 NOTE_INSN_INLINE_ENTRY.
8382 2018-10-01 Carl Love <cel@us.ibm.com>
8385 * config/rs6000/rs6000-builtin.def (__builtin_mffsl): New.
8386 (__builtin_mtfsb0): New.
8387 (__builtin_mtfsb1): New.
8388 ( __builtin_set_fpscr_rn): New.
8389 (__builtin_set_fpscr_drn): New.
8390 * config/rs6000/rs6000.c (rs6000_expand_mtfsb_builtin): Add.
8391 (rs6000_expand_set_fpscr_rn_builtin): Add.
8392 (rs6000_expand_set_fpscr_drn_builtin): Add.
8393 (rs6000_expand_builtin): Add case statement entries for
8394 RS6000_BUILTIN_MTFSB0, RS6000_BUILTIN_MTFSB1,
8395 RS6000_BUILTIN_SET_FPSCR_RN, RS6000_BUILTIN_SET_FPSCR_DRN,
8396 RS6000_BUILTIN_MFFSL.
8397 (rs6000_init_builtins): Add ftype initialization and def_builtin
8398 calls for __builtin_mffsl, __builtin_mtfsb0, __builtin_mtfsb1,
8399 __builtin_set_fpscr_rn, __builtin_set_fpscr_drn.
8400 * config/rs6000.md (rs6000_mtfsb0, rs6000_mtfsb1, rs6000_mffscrn,
8401 rs6000_mffscdrn): Add define_insn.
8402 (rs6000_set_fpscr_rn, rs6000_set_fpscr_drn): Add define_expand.
8403 * doc/extend.texi: Add documentation for the builtins.
8405 2018-10-01 Richard Biener <rguenther@suse.de>
8407 PR tree-optimization/87465
8408 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
8409 causing branch miscounts.
8411 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8413 * common/config/aarch64/aarch64-common.c (TARGET_OPTION_DEFAULT_PARAM,
8414 aarch64_option_default_param): New.
8415 (params.h): Include.
8416 (TARGET_OPTION_VALIDATE_PARAM, aarch64_option_validate_param): New.
8417 * config/aarch64/aarch64.c (aarch64_override_options_internal): Simplify
8418 stack-clash protection validation code.
8420 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8422 * params.c (validate_param): New.
8423 (add_params): Use it.
8424 (set_param_value): Refactor param validation into validate_param.
8425 (diagnostic.h): Include.
8426 * diagnostic.h (diagnostic_ready_p): New.
8428 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8430 * params.c (set_param_value):
8431 Add index of parameter being validated.
8432 * common/common-target.def (option_validate_param): New.
8433 * common/common-targhooks.h (default_option_validate_param): New.
8434 * common/common-targhooks.c (default_option_validate_param): New.
8435 * doc/tm.texi.in (TARGET_OPTION_VALIDATE_PARAM): New.
8436 * doc/tm.texi: Regenerate.
8438 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8441 * config/aarch64/aarch64.c (aarch64_override_options_internal):
8442 Add validation for stack-clash parameters and set defaults.
8444 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8447 * configure.ac: Add stack-clash-protection-guard-size.
8448 * doc/install.texi: Document it.
8449 * config.in (DEFAULT_STK_CLASH_GUARD_SIZE): New.
8450 * params.def: Update comment for guard-size.
8451 (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE,
8452 PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Update description.
8453 * configure: Regenerate.
8455 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8458 * config/aarch64/aarch64.h (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS,
8459 STACK_DYNAMIC_OFFSET): New.
8460 * config/aarch64/aarch64.c (aarch64_layout_frame):
8461 Update outgoing args size.
8462 (aarch64_stack_clash_protection_alloca_probe_range,
8463 TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
8465 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8468 * explow.c (anti_adjust_stack_and_probe_stack_clash): Support custom
8470 * target.def (stack_clash_protection_alloca_probe_range): New.
8471 (stack_clash_protection_final_dynamic_probe): Remove.
8472 * targhooks.h (default_stack_clash_protection_alloca_probe_range) New.
8473 (default_stack_clash_protection_final_dynamic_probe): Remove.
8474 * targhooks.c: Likewise.
8475 * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
8476 (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE): Remove.
8477 * doc/tm.texi: Regenerate.
8479 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8482 * config/aarch64/aarch64-protos.h (aarch64_output_probe_sve_stack_clash): New.
8483 * config/aarch64/aarch64.c (aarch64_output_probe_sve_stack_clash,
8484 aarch64_clamp_to_uimm12_shift): New.
8485 (aarch64_allocate_and_probe_stack_space): Add SVE specific section.
8486 * config/aarch64/aarch64.md (probe_sve_stack_clash): New.
8488 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8491 * config/aarch64/aarch64.c (aarch64_layout_frame): Add assert.
8493 2018-10-01 Jeff Law <law@redhat.com>
8494 Richard Sandiford <richard.sandiford@linaro.org>
8495 Tamar Christina <tamar.christina@arm.com>
8498 * config/aarch64/aarch64.md
8499 (probe_stack_range): Add k (SP) constraint.
8500 * config/aarch64/aarch64.h (STACK_CLASH_CALLER_GUARD,
8501 STACK_CLASH_MAX_UNROLL_PAGES): New.
8502 * config/aarch64/aarch64.c (aarch64_output_probe_stack_range): Emit
8503 stack probes for stack clash.
8504 (aarch64_allocate_and_probe_stack_space): New.
8505 (aarch64_expand_prologue): Use it.
8506 (aarch64_expand_epilogue): Likewise and update IP regs re-use criteria.
8507 (aarch64_sub_sp): Add emit_move_imm optional param.
8509 2018-10-01 MCC CS <deswurstes@users.noreply.github.com>
8511 PR tree-optimization/87261
8512 * match.pd: Remove trailing whitespace.
8513 Add (x & y) | ~(x | y) -> ~(x ^ y),
8514 (~x | y) ^ (x ^ y) -> x | ~y and (x ^ y) | ~(x | y) -> ~(x & y)
8516 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
8518 * config/arc/arc.md (*add_n): Clean up pattern, update instruction
8520 (ashlsi3_insn): Update instruction constraints.
8521 (ashrsi3_insn): Likewise.
8522 (rotrsi3): Likewise.
8523 (add_shift): Likewise.
8524 * config/arc/constraints.md (Csz): New 32 bit constraint. It
8525 avoids placing in the limm field small constants which, otherwise,
8526 could end into a small instruction.
8528 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
8530 * config/arc/arc.md (maddsidi4_split): Don't use dmac if the
8531 destination register is not odd-even.
8532 (umaddsidi4_split): Likewise.
8534 2018-10-01 Richard Biener <rguenther@suse.de>
8536 * tree-inline.c (expand_call_inline): Store origin of fn
8537 in BLOCK_ABSTRACT_ORIGIN for the inline BLOCK.
8538 * tree.c (block_ultimate_origin): Simplify and do some
8541 2018-09-30 Uros Bizjak <ubizjak@gmail.com>
8543 * config/i386/mmx.md (EMMS): New int iterator.
8544 (emms): New int attribute.
8545 (mmx_<emms>): Macroize insn from *mmx_emms and *mmx_femms using
8546 EMMS int iterator. Explicitly declare clobbers.
8547 (mmx_emms): Remove expander.
8549 * config/i386/predicates.md (emms_operation): Remove predicate.
8550 (vzeroall_pattern): New predicate.
8551 (vzeroupper_pattern): Rename from vzeroupper_operation.
8552 * config/i386/i386.c (ix86_avx_u128_mode_after): Use
8553 vzeroupper_pattern and vzeroall_pattern predicates.
8555 2018-09-30 Peter Bergner <bergner@linux.ibm.com>
8557 PR rtl-optimization/86939
8558 * ira-lives.c (make_hard_regno_born): Rename from this...
8559 (make_hard_regno_live): ... to this. Remove update to conflict
8560 information. Update function comment.
8561 (make_hard_regno_dead): Add conflict information update. Update
8563 (make_object_born): Rename from this...
8564 (make_object_live): ... to this. Remove update to conflict information.
8565 Update function comment.
8566 (make_object_dead): Add conflict information update. Update function
8568 (mark_pseudo_regno_live): Call make_object_live.
8569 (mark_pseudo_regno_subword_live): Likewise.
8570 (mark_hard_reg_dead): Update function comment.
8571 (mark_hard_reg_live): Call make_hard_regno_live.
8572 (process_bb_node_lives): Likewise.
8573 * lra-lives.c (make_hard_regno_born): Rename from this...
8574 (make_hard_regno_live): ... to this. Remove update to conflict
8575 information. Remove now uneeded check_pic_pseudo_p argument.
8576 Update function comment.
8577 (make_hard_regno_dead): Add check_pic_pseudo_p argument and add update
8578 to conflict information. Update function comment.
8579 (mark_pseudo_live): Remove update to conflict information. Update
8581 (mark_pseudo_dead): Add conflict information update.
8582 (mark_regno_live): Call make_hard_regno_live.
8583 (mark_regno_dead): Call make_hard_regno_dead with new arguement.
8584 (process_bb_lives): Call make_hard_regno_live and make_hard_regno_dead.
8586 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
8589 * config/i386/i386.c (construct_container): Use TImode for
8590 BLKmode values in 2 integer registers.
8592 2018-09-29 Jeff Law <law@redhat.com>
8594 * builtins.c (unterminated_array): Pass in c_strlen_data * to
8595 c_strlen rather than just a tree *.
8596 (c_strlen): Change NONSTR argument to a c_strlen_data pointer.
8597 Update recursive calls appropriately. If caller did not provide a
8598 suitable data pointer, create a local one. When a non-terminated
8599 string is discovered, bubble up information about the string via the
8600 c_strlen_data object.
8601 * builtins.h (c_strlen): Update prototype.
8602 (c_strlen_data): New structure.
8603 * gimple-fold.c (get_range_strlen): Update calls to c_strlen.
8604 For a type 2 call, if c_strlen indicates a non-terminated string
8605 use the length of the non-terminated string.
8606 (gimple_fold_builtin_stpcpy): Update calls to c_strlen.
8608 2018-09-29 Jakub Jelinek <jakub@redhat.com>
8611 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
8612 __m512d type for __A argument rather than __m512.
8614 2018-09-28 John David Anglin <danglin@gcc.gnu.org>
8616 * match.pd (simple_comparison): Don't optimize if either operand is
8617 a function pointer when target needs function pointer canonicalization.
8619 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
8621 * config/rs6000/driver-rs6000.c (asm_names): Adjust the entries for
8622 power5 .. power9 to remove indirection.
8623 * config/rs6000/rs6000.h (ASM_CPU_POWER5_SPEC, ASM_CPU_POWER6_SPEC,
8624 ASM_CPU_POWER7_SPEC, ASM_CPU_POWER8_SPEC, ASM_CPU_POWER9_SPEC,
8625 ASM_CPU_476_SPEC): Delete.
8626 (ASM_CPU_SPEC): Adjust.
8627 (EXTRA_SPECS): Delete asm_cpu_power5, asm_cpu_power6, asm_cpu_power7,
8628 asm_cpu_power8, asm_cpu_power9, asm_cpu_476.
8630 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
8632 * config.in: Delete HAVE_AS_DCI.
8633 * config/powerpcspe/powerpcspe.h: Treat HAVE_AS_DCI as always true.
8634 * config/rs6000/rs6000.h: Ditto.
8635 * configure.ac: Delete HAVE_AS_DCI.
8636 * configure: Regenerate.
8638 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
8640 * config.in (HAVE_AS_LWSYNC): Delete.
8641 * config/powerpcspe/powerpcspe.h (TARGET_LWSYNC_INSTRUCTION): Delete.
8642 * config/powerpcspe/sync.md (*lwsync): Always generate lwsync, never
8644 * config/rs6000/rs6000.h (TARGET_LWSYNC_INSTRUCTION): Delete.
8645 * config/rs6000/sync.md (*lwsync): Always generate lwsync, never do it
8647 * configure.ac: Delete HAVE_AS_LWSYNC.
8648 * configure: Regenerate.
8650 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
8651 Pierre-Marie de Rodat <derodat@adacore.com>
8653 * calls.c (expand_call): Try to do a tail call for thunks at -O0 too.
8654 * cgraph.h (struct cgraph_thunk_info): Add indirect_offset.
8655 (cgraph_node::create_thunk): Add indirect_offset parameter.
8656 (thunk_adjust): Likewise.
8657 * cgraph.c (cgraph_node::create_thunk): Add indirect_offset parameter
8658 and initialize the corresponding field with it.
8659 (cgraph_node::dump): Dump indirect_offset field.
8660 * cgraphclones.c (duplicate_thunk_for_node): Deal with indirect_offset.
8661 * cgraphunit.c (cgraph_node::analyze): Be prepared for external thunks.
8662 (thunk_adjust): Add indirect_offset parameter and deal with it.
8663 (cgraph_node::expand_thunk): Deal with the indirect_offset field and
8664 pass it to thunk_adjust. Do not call the target hook if it's non-zero
8665 or if the thunk is external or local. Fix formatting. Do not chain
8666 the RESULT_DECL to BLOCK_VARS. Pass the static chain to the target,
8667 if any, in the GIMPLE representation.
8668 * ipa-icf.c (sem_function::equals_wpa): Deal with indirect_offset.
8669 * lto-cgraph.c (lto_output_node): Write indirect_offset field.
8670 (input_node): Read indirect_offset field.
8671 * tree-inline.c (expand_call_inline): Pass indirect_offset field in the
8672 call to thunk_adjust.
8673 * tree-nested.c (struct nesting_info): Add thunk_p field.
8674 (create_nesting_tree): Set it.
8675 (convert_all_function_calls): Copy static chain from targets to thunks.
8676 (finalize_nesting_tree_1): Return early for thunks.
8677 (unnest_nesting_tree_1): Do not finalize thunks.
8678 (gimplify_all_functions): Do not gimplify thunks.
8680 2018-09-28 David Malcolm <dmalcolm@redhat.com>
8682 * opt-suggestions.c (option_proposer::build_option_suggestions):
8683 Release "option_values".
8685 2018-09-28 David Malcolm <dmalcolm@redhat.com>
8687 * coverage.c (get_coverage_counts): Convert problem-reporting dump
8688 messages from MSG_OPTIMIZED_LOCATIONS to MSG_MISSED_OPTIMIZATION.
8689 * dumpfile.c (kind_as_string): New function.
8690 (dump_loc): Rather than a hardcoded prefix of "note: ", use
8691 kind_as_string to vary the prefix based on dump_kind.
8692 (selftest::test_capture_of_dump_calls): Update for above.
8694 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
8696 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
8697 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
8699 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
8701 * config/i386/i386.h (CC_REGNO): Remove FPSR_REG.
8702 * config/i386/i386.c (ix86_fixed_condition_code_regs): Use
8703 INVALID_REGNUM instead of FPSR_REG.
8704 (ix86_md_asm_adjust): Do not clobber FPSR_REG.
8705 * config/i386/i386.md: Update comment of FP compares.
8706 (fldenv): Do not clobber FPSR_REG.
8708 2018-09-28 Richard Biener <rguenther@suse.de>
8710 * tree.h (BLOCK_ORIGIN): New.
8711 * omp-expand.c (grid_expand_target_grid_body): Assign
8712 BLOCK_ORIGIN to BLOCK_ABSTRACT_ORIGIN.
8713 * tree-inline.c (remap_block): Likewise.
8714 * auto-profile.c (get_function_decl_from_block): Simplify
8715 by eliding the BLOCK_ABSTRACT_ORIGIN chasing.
8716 * langhooks.c (lhd_print_error_function): Likewise.
8717 * optinfo-emit-json.cc (optrecord_json_writer::inlining_chain_to):
8719 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
8720 * tree.c (block_nonartificial_location): Likewise.
8721 (block_ultimate_origin): Likewise.
8722 * tree-pretty-print.c (percent_K_format): Likewise. Remove
8723 no longer needed LTO case.
8725 2018-09-28 Andrew Stubbs <ams@codesourcery.com>
8726 Jan Hubicka <jh@suse.cz>
8727 Martin Jambor <mjambor@suse.cz>
8729 * simplify-rtx.c (simplify_merge_mask): New function.
8730 (simplify_ternary_operation): Use it, also see if VEC_MERGEs with the
8731 same masks are used in op1 or op2.
8732 (test_vec_merge): New function.
8733 (test_vector_ops): Call test_vec_merge.
8735 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
8737 * config/sparc/sparc-protos.h (sparc_branch_cost): Declare.
8738 * config/sparc/sparc.h (BRANCH_COST): Call sparc_branch_cost.
8739 * config/sparc/sparc.c (struct processor_costs): Add branch_cost field.
8740 (cypress_costs): Set it.
8741 (supersparc_costs): Likewise.
8742 (hypersparc_costs): Likewise.
8743 (leon_cost): Likewise.
8744 (leon3_costs): Likewise.
8745 (sparclet_costs): Likewise.
8746 (ultrasparc_costs): Likewise.
8747 (ultrasparc_costs): Likewise.
8748 (niagara_costs): Likewise.
8749 (niagara2_costs): Likewise.
8750 (niagara3_costs): Likewise.
8751 (niagara4_costs): Likewise.
8752 (niagara7_costs): Likewise.
8753 (m8_costs): Likewise.
8754 (TARGET_CAN_FOLLOW_JUMP): Define.
8755 (pass_work_around_errata::gate): Minor tweak.
8756 (sparc_option_override): Remove MASK_FSMULD mask for V7 processors.
8757 Do not set both MASK_VIS4 and MASK_VIS4B for M8 processor.
8758 Automaitcally clear MASK_FSMULD mask for V7 processors.
8759 (sparc_can_follow_jump): New static function.
8760 (output_ubranch): Deal with CROSSING_JUMP_P.
8761 (sparc_use_sched_lookahead): Rewrite using switch statement.
8762 (sparc_issue_rate): Reorder.
8763 (sparc_branch_cost): New function.
8765 2018-09-27 Martin Sebor <msebor@redhat.com>
8767 * tree.h (tree_to_shwi): Add attribute nonnull and pure.
8768 (tree_to_poly_int64, tree_to_uhwi, tree_to_poly_uint64): Same.
8769 (int_fits_type_p): Same.
8771 2018-09-27 Uros Bizjak <ubizjak@gmail.com>
8773 * config/i386/i386.md (FPCR_REG): Remove.
8774 (UNSPEC_FLDCW): Remove.
8775 (x86_fnstcw_1): Use (const_int 0) instead of FPCR_REG.
8776 (x86_fldcw_1): Remove insn pattern.
8777 (fnstenv): Do not clobber FPCR_REG.
8779 * config/i386/i386.h (FIXED_REGISTERS) Remove fpsr register.
8780 (CALL_USED_REGISTERS): Ditto.
8781 (REG_ALLOC_ORDER): Ditto.
8782 (REG_CLASS_CONTENTS): Ditto.
8783 (HI_REGISTER_NAMES): Ditto.
8784 (ADDITIONAL_REGISTER_NAMES): Use defines instead
8785 of numerical constants.
8786 * config/i386/i386.c (regclass_map): Remove fpsr register.
8787 (dbx_register_map): Ditto.
8788 (dbx64_register_map): Ditto.
8789 (svr4_dbx_register_map): Ditto.
8790 (print_reg): Do not handle FPCR_REG.
8792 2018-09-27 Segher Boessenkool <segher@kernel.crashing.org>
8795 * config.in (HAVE_AS_CMPB, HAVE_AS_DFP, HAVE_AS_FPRND, HAVE_AS_MFPGPR,
8796 HAVE_AS_POPCNTB, HAVE_AS_POPCNTD, HAVE_AS_POWER8, HAVE_AS_POWER9):
8797 Delete, always treat as true.
8798 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
8799 Ditto. Simplify remaining code.
8800 * config/powerpcspe/powerpcspe.h: Ditto.
8801 * config/rs6000/rs6000.c (rs6000_option_override_internal): Ditto.
8802 Simplify remaining code.
8803 (rs6000_expand_builtin): Ditto.
8804 * config/rs6000/rs6000.h: Ditto.
8805 * configure.ac: Ditto.
8806 * configure: Regenerate.
8808 2018-09-27 Martin Liska <mliska@suse.cz>
8810 * coverage.c (get_coverage_counts): Revert the formatting
8811 of missing profile opt info.
8813 2018-09-27 Richard Biener <rguenther@suse.de>
8817 * dwarf2out.c (set_block_origin_self): Do not mark outermost
8818 block as we do not output that.
8819 (gen_inlined_subroutine_die): Elide the originally outermost
8820 block, matching what we do for concrete instances.
8821 (decls_for_scope): Add parameter specifying whether to recurse
8824 2018-09-27 Andrew Stubbs <ams@codesourcery.com>
8825 Tom de Vries <tom@codesourcery.com>
8829 * expmed.c (emit_cstore): Fix handling of result_mode == BImode and
8830 STORE_FLAG_VALUE == 1.
8832 2018-09-27 Andreas Krebbel <krebbel@linux.ibm.com>
8834 * config/s390/s390.md (PPA_TX_ABORT, PPA_OOO_BARRIER): New
8835 constant definitions.
8836 ("tx_assist"): Replace magic number with PPA_TX_ABORT.
8837 ("*ppa"): Enable pattern also for -march=zEC12 -mno-htm.
8838 ("speculation_barrier"): New expander definition.
8840 2018-09-26 Indu Bhagat <indu.bhagat@oracle.com>
8842 PR gcov-profile/86957
8843 * common.opt: New warning option -Wmissing-profile.
8844 * coverage.c (get_coverage_counts): Add warning for missing .gcda file.
8845 * doc/invoke.texi: Document -Wmissing-profile.
8847 2018-09-26 Jim Wilson <jimw@sifive.com>
8849 * config/riscv/riscv.md (subsi3_extended2): Add J constraint.
8850 (negdi2, negsi2, negsi2_extended, negsi2_extended2): New.
8852 2018-09-26 Martin Sebor <msebor@redhat.com>
8854 * tree.c (zerop): Change return type to bool.
8855 (integer_zerop, integer_onep, integer_each_onep): Same.
8856 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
8857 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
8858 (real_onep, real_minus_onep, chain_index): Same.
8859 (print_type_hash_statistics, type_list_equal): Same.
8860 * tree.h (zerop): Same.
8861 (zerop, integer_zerop, integer_onep, integer_each_onep): Same.
8862 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
8863 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
8864 (real_onep, real_minus_onep, chain_index): Same.
8865 (print_type_hash_statistics, type_list_equal): Same.
8867 2018-09-26 Jim Wilson <jimw@sifive.com>
8869 * config/riscv/riscv.h (FUNCTION_ARG_REGNO_P): Fix comment.
8871 2018-09-26 Jakub Jelinek <jakub@redhat.com>
8874 * config/i386/i386.c: Include debug.h and dwarf2out.h.
8875 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
8878 2018-09-25 Andrew Stubbs <ams@codesourcery.com>
8880 * builtins.c (get_builtin_sync_mem): Force address mode conversion.
8882 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
8884 * config/i386/i386.h (enum reg_class): Remove FP_TOP_SSE_REGS
8885 and FP_SECOND_SSE_REGS.
8886 (REG_CLASS_NAMES): Ditto.
8887 (REG_CLASS_CONTENTS): Ditto.
8888 * config/i386/i386.c (ix86_preferred_reload_class) Do not handle
8889 FP_TOP_SSE_REGS and FP_SECOND_SSE_REGS classes.
8890 (ix86_preferred_output_reload_class): Ditto.
8891 * config/i386/i386.md (fix_trunc<mode>_i387_fisttp): Change "=&1f"
8892 clobber constraint to "=&f".
8893 (fix_truncdi_i387): Ditto.
8894 (lrintxfdi2): Ditto.
8895 (fistdi2_<rounding>): Ditto.
8896 (fpremxf4_i387): Change "=u" constraint to "=f".
8897 (fprem1xf4_i387): Ditto.
8899 (fptanxf4_i387): Ditto.
8900 (fxtractxf3_i387): Ditto.
8901 (fscalexf4_i387): Ditto.
8902 (atan2xf3): Change "u" constraint to "f".
8903 (fyl2xxf3_i387): Ditto.
8904 (fyl2xp1xf3_i387): Ditto.
8906 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
8909 * config/i386/i386.h (NUM_MODES_FOR_MODE_SWITCHING): Update
8910 for removed I387_MASK_PM entity.
8913 2018-09-26 Jeff Law <law@redhat.com>
8915 2018-09-26 Alexey Neyman <stilor@att.net>
8917 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
8918 headers are no longer pulled in by <isl/val.h>.
8920 2018-09-26 Richard Biener <rguenther@suse.de>
8923 * dwarf2out.c (gen_lexical_block_die): Do not equate inline
8924 or concrete instance DIE to the tree. Create abstract origin
8925 attributes also for concrete instances.
8927 2018-09-26 Alexey Neyman <stilor@att.net>
8929 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
8930 headers are no longer pulled in by <isl/val.h>.
8932 2018-09-26 Matthew Malcomson <matthew.malcomson@arm.com>
8934 * config/arm/arm.c (arm_split_compare_and_swap, arm_split_atomic_op):
8935 Use new helper functions.
8936 * config/arm/sync.md (atomic_load<mode>, atomic_store<mode>):
8937 Use new helper functions.
8938 * config/arm/aarch-common-protos.h (aarch_mm_needs_acquire,
8939 aarch_mm_needs_release): New declarations.
8940 * config/arm/aarch-common.c (aarch_mm_needs_acquire,
8941 aarch_mm_needs_release): New.
8943 2018-09-26 Eric Botcazou <ebotcazou@adacore.com>
8945 * config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
8946 (arm32_output_mi_thunk): Deal with long calls.
8948 2018-09-26 Richard Biener <rguenther@suse.de>
8952 * tree-inline.c (expand_call_inline): When the location
8953 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
8954 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
8955 the inserted BLOCK to make inlined_function_outer_scope_p
8957 * dwarf2out.c (add_call_src_coords_attributes): Do not add
8958 coords for reserved locations.
8960 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
8962 * config/rs6000/rs6000.md (*movcc_internal1): Use set_attr_alternative.
8963 (*call_indirect_nonlocal_sysv<mode>): Ditto.
8964 (*call_value_indirect_nonlocal_sysv<mode>): Ditto.
8965 (*sibcall_nonlocal_sysv<mode>): Ditto.
8966 (*sibcall_value_nonlocal_sysv<mode>): Ditto.
8967 (<bd>_<mode>): Ditto.
8968 (<bd>tf_<mode>): Ditto.
8970 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
8972 * config/rs6000/altivec.md (*altivec_mov<mode>): Write the output
8973 control string as a list of templates instead of as C code.
8974 (*altivec_movti): Ditto.
8975 * config/rs6000/darwin.md (movdf_low_di): Ditto.
8977 2018-09-25 Jim Wilson <jimw@sifive.com>
8979 * config/riscv/riscv.c (riscv_split_symbol): Mark auipc label as weak
8980 when target symbol is weak.
8982 2018-09-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
8985 * builtins.c (unterminated_array): Simplify.
8986 * expr.c (string_constant): Handle SSA_NAME. Add more exceptions
8987 where pointer arithmetic is safe.
8989 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
8992 * config/rs6000/altivec.md (altivec_vspltb): Use
8993 const_0_to_15_operand instead of u5bit_cint_operand.
8994 (*altivec_vspltb_internal): Ditto.
8995 (altivec_vspltb_direct): Ditto.
8996 (altivec_vsplth): Use const_0_to_7_operand instead of
8998 (*altivec_vsplth_internal): Ditto.
8999 (altivec_vsplth_direct): Ditto.
9000 (altivec_vspltw): Use const_0_to_3_operand instead of
9002 (*altivec_vspltw_internal): Ditto.
9003 (altivec_vspltw_direct): Ditto.
9004 (altivec_vspltsf): Ditto.
9005 (*altivec_vspltsf_internal): Ditto.
9006 * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Handle the
9007 various splats with the proper size immediate. Reorder the various
9008 cases by ascending size of immediate, and put all such together.
9010 2018-09-25 Richard Biener <rguenther@suse.de>
9013 * dwarf2out.c (add_AT_external_die_ref): Remove now redundant
9015 (maybe_create_die_with_external_ref): Do not create
9016 DW_TAG_imported_unit here.
9017 (add_abstract_origin_attribute): Handle external BLOCK refs.
9018 (dwarf2out_abstract_function): Simplify LTO case.
9019 (dwarf2out_early_finish): Create DW_TAG_imported_unit explicitely
9020 rather than using maybe_create_die_with_external_ref.
9022 2018-09-25 Uros Bizjak <ubizjak@gmail.com>
9025 * config/i386/i386.md (frndintxf2_mask_pm): Remove.
9026 (frndintxf2_mask_pm_i387): Ditto.
9027 (nearbyintxf2): Rewrite expander pattern to match rintxf2.
9028 Enable for !flag_trapping_math.
9029 (nearbyint<mode>2): Enable x87 modes for !flag_trapping_math.
9030 Enable SSE modes for TARGET_SSE4_1 and expand them with round insn.
9031 Change operand 1 predicate to nonimmediate_operand.
9032 (attr "i387_cw"): Remove mask_pm.
9033 * config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_CW_MASK_PM.
9034 (enum ix86_entity): Remove I387_MASK_PM.
9035 * config/i386/i386.c (ix86_i387_mode_needed): Do not
9036 handle I387_MASK_PM.
9037 (ix86_mode_needed): Ditto.
9038 (ix86_mode_after): Ditto.
9039 (ix86_mode_entry): Ditto.
9040 (ix86_mode_exit): Ditto.
9041 (emit_i387_cw_initialization): Do not handle I387_CW_MASK_PM.
9043 2018-09-25 Jakub Jelinek <jakub@redhat.com>
9045 * vr-values.c (vr_values::vr_values): Initialize to_remove_edges and
9046 to_update_switch_stmts to vNULL instead of calling create on them
9049 2018-09-25 Richard Biener <rguenther@suse.de>
9051 PR tree-optimization/87402
9052 * tree-ssa-sccvn.c (SSA_VISITED): Remove unused function.
9053 (visit_phi): Re-instantiate handling of supposed to be VARYING
9054 but non-VARYING backedge value.
9056 2018-09-25 Richard Biener <rguenther@suse.de>
9059 * dwarf2out.c (struct sym_off_pair): New.
9060 (external_die_map): New global.
9061 (lookup_decl_die): When in LTO create DIEs lazily from the
9063 (lookup_block_die): New function, create DIEs lazily in LTO.
9064 (equate_block_to_die): New function.
9065 (dwarf2out_die_ref_for_decl): During WPA get the association
9066 from the external DIE map.
9067 (dwarf2out_register_external_die): Record mapping into the
9069 (maybe_create_die_with_external_ref): New function split out from
9070 DIE generation part of old dwarf2out_register_external_die.
9071 (add_abstract_origin_attribute): Do not return the DIE. When
9072 in LTO reference externals directly.
9073 (dwarf2out_abstract_function): When in LTO ignore calls for
9074 decls with external DIEs (already present abstract instances).
9075 (gen_call_site_die): Adjust.
9076 (add_high_low_attributes): Likewise.
9077 (gen_lexical_block_die): Likewise.
9078 (gen_inlined_subroutine_die): Likewie.
9079 (gen_block_die): Likewise.
9080 (dwarf2out_inline_entry): Likewise.
9081 (dwarf2out_early_finish): In LTRANS phase create DW_TAG_imported_unit
9084 2018-09-25 Martin Liska <mliska@suse.cz>
9086 * ipa-fnsummary.c (estimate_node_size_and_time): Scale by two
9087 integers and not by a float value.
9089 2018-09-25 Martin Liska <mliska@suse.cz>
9092 * dbgcnt.c (dbg_cnt_process_single_pair): Return false
9094 * dumpfile.c (dump_enable_all): Remove extra parenthesis.
9095 * gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
9096 * godump.c (go_format_type): Remove extra parenthesis.
9098 2018-09-25 Martin Liska <mliska@suse.cz>
9100 * alias.c (set_dest_equal_p): Remove unused function.
9101 * config/i386/i386.c (def_builtin_pure2): Likewise.
9102 * diagnostic-show-locus.c (class layout): Remove
9104 (layout::layout): Likewise here.
9105 * dump-context.h (class temp_dump_context): Likewise.
9106 * dwarf2out.c (add_AT_fde_ref): Remove unused function.
9107 (add_AT_loclistsptr): Likewise.
9108 (add_AT_offset): Likewise.
9109 (get_AT_hi_pc): Likewise.
9110 (is_comdat_die): Likewise.
9111 (type_is_enum): Likewise.
9112 (ceiling): Likewise.
9113 (add_AT_vms_delta): Likewise.
9114 (is_class_die): Likewise.
9115 * edit-context.c (class line_event): Remove unused field.
9116 * graphite-sese-to-poly.c (tree_int_to_gmp): Remove
9118 * ipa-cp.c (ipa_get_vr_lat): Likewise.
9119 * lra-constraints.c (ok_for_index_p_nonstrict): Likewise.
9120 (ok_for_base_p_nonstrict): Likewise.
9121 * tree-chrec.c (is_not_constant_evolution): Likewise.
9122 (chrec_fold_poly_cst): Likewise.
9123 * tree-if-conv.c (has_pred_critical_p): Likewise.
9124 * tree-ssa-coalesce.c (print_exprs): Likewise.
9125 * tree-ssa-pre.c (bitmap_set_contains_expr): Likewise.
9126 * tree-ssa-uninit.c (is_and_or_or_p): Likewise.
9127 * tree-vrp.c (value_ranges_intersect_p): Likewise.
9128 (value_range_nonnegative_p): Likewise.
9130 2018-09-25 Martin Liska <mliska@suse.cz>
9132 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
9133 Do not handle "GNU Pascal".
9134 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
9136 * config/sparc/sparc.c (sparc_pass_by_reference): Remove Pascal
9137 from documentation. Likewise.
9138 * dbxout.c (dbxout_range_type): Likewise.
9139 * doc/cpp.texi: Likewise.
9140 * doc/extend.texi: Likewise.
9141 * doc/frontends.texi: Likewise.
9142 * doc/invoke.texi: Remove Pascal entry.
9143 * tree.def (CLEANUP_POINT_EXPR): Likewise.
9144 * doc/rtl.texi (MODE_FUNCTION): Remove not used entry.
9146 2018-09-25 Martin Liska <mliska@suse.cz>
9149 * doc/invoke.texi: Document all parameters and remove default
9152 2018-09-25 Ilya Leoshkevich <iii@linux.ibm.com>
9155 * rtl.c (rtx_code_size): Take into account that EQ_ATTR_ALT
9156 contains HOST_WIDE_INTs when computing its size.
9158 2018-09-24 Jim Wilson <jimw@sifive.com>
9161 * config/riscv/riscv.h (STACK_BOUNDARY): Test riscv_abi == ABI_ILP32E
9163 (ABI_STACK_BOUNDARY, MAX_ARGS_IN_REGISTERS): Likewise.
9165 2018-09-24 Andrew Pinski <apinski@marvell.com>
9167 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
9168 access prev before checking it for NULLness in the
9169 AARCH64_FUSE_CMP_BRANCH case.
9171 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
9174 * config/i386/i386.c (rest_of_insert_endbranch): Set
9175 endbr_queued_at_entrance to true and don't insert ENDBR if
9176 x86_function_profiler will be called.
9177 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
9179 * config/i386/i386.h (machine_function): Add
9180 endbr_queued_at_entrance.
9182 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
9184 * genattrtab.c (mk_attr_alt): Use alternative_mask.
9185 (attr_rtx_1): Adjust caching to match the new EQ_ATTR_ALT field
9187 (check_attr_test): Use alternative_mask.
9188 (get_attr_value): Likewise.
9189 (compute_alternative_mask): Use alternative_mask and XWINT.
9190 (make_alternative_compare): Use alternative_mask.
9191 (attr_alt_subset_p): Use XWINT.
9192 (attr_alt_subset_of_compl_p): Likewise.
9193 (attr_alt_intersection): Use alternative_mask and XWINT.
9194 (attr_alt_union): Likewise.
9195 (attr_alt_complement): Use HOST_WIDE_INT and XWINT.
9196 (mk_attr_alt): Use alternative_mask and HOST_WIDE_INT.
9197 (simplify_test_exp): Use alternative_mask and XWINT.
9198 (write_test_expr): Use alternative_mask and XWINT, adjust bit
9199 number calculation to support 64 bits. Generate code that
9200 checks 64-bit masks.
9201 (main): Use alternative_mask.
9202 * rtl.def (EQ_ATTR_ALT): Change field types from ii to ww.
9204 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
9207 * config/s390/s390.c (s390_emit_epilogue): Do not use PARALLEL
9208 RETURN+USE when returning via %r14.
9210 2018-09-24 Martin Liska <mliska@suse.cz>
9212 * gcov.c (output_lines): Print colorization legend
9213 for both flag_use_colors and flag_use_hotness_colors.
9216 2018-09-24 Martin Liska <mliska@suse.cz>
9218 * coverage.c (get_coverage_counts): Use warning_at
9219 with current_function_decl location. Use %qD in warning
9222 2018-09-24 Martin Liska <mliska@suse.cz>
9224 * memory-block.h (memory_block_pool::release): Annotate with
9225 valgrind that the memory is not accessible.
9227 2018-09-24 Martin Liska <mliska@suse.cz>
9230 * asan.c: Make asan_handled_variables extern.
9232 * cfgexpand.c (expand_stack_vars): Make sure
9233 a representative is unpoison if another
9234 variable in the partition is handled by
9235 use-after-scope sanitization.
9237 2018-09-24 Richard Biener <rguenther@suse.de>
9239 PR tree-optimization/63155
9240 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
9241 the worklist when the edge of the respective argument isn't
9244 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9246 * config/i386/i386.h (enum reg_class): Rename MASK_REGS to
9247 ALL_MASK_REGS and MASK_EVEX_REGS to MASK_REGS.
9248 (MASK_CLASS_P): Update for rename.
9249 (MAYBE_MASK_CLASS_P): Ditto.
9250 (REG_CLASS_NAMES): Update.
9251 (REG_CLASS_CONTENT): Update.
9252 * config/i386/i386.c (regclass_map): Update for MASK_REG
9253 and ALL_MASK_REGS rename.
9254 * config/i386/constraints.md (Yk): Update for rename.
9257 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9259 * config/i386/i386.h (enum reg_class): Remove
9260 EVEX_SSE_REGS and MOD4_SSE_REGS.
9261 (REG_CLASS_NAMES): Update.
9262 (REG_CLASS_CONTENT): Update.
9263 * config/i386/i386.c (regclass_map): Declare AVX-512 SSE
9264 registers as ALL_SSE_REGS.
9265 (ix86_additional_allocno_class_p): Remove.
9266 (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Remove.
9267 (ix86_register_priority): Lower priority of EVEX SSE registers.
9268 Use IN_RANGE macro where appropriate.
9269 (ix86_hard_regno_mode_ok): Merge AVX-5124FMAPS and
9270 AVX-5124VNNIW checks.
9271 (ix86_modes_tieable_p): Tie 512-bit SSE modes.
9272 * config/i386/sse.md (avx5124fmaddps_4fmaddps)
9273 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddps_maskz)
9274 (avx5124fmaddps_4fmaddss, avx5124fmaddps_4fmaddss_mask)
9275 (avx5124fmaddps_4fmaddss_maskz, avx5124fmaddps_4fnmaddps)
9276 (avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddps_maskz)
9277 (avx5124fmaddps_4fnmaddss, avx5124fmaddps_4fnmaddss_mask)
9278 (avx5124fmaddps_4fnmaddss_maskz, avx5124vnniw_vp4dpwssd)
9279 (avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssd_maskz)
9280 (avx5124vnniw_vp4dpwssds, avx5124vnniw_vp4dpwssds_mask)
9281 (avx5124vnniw_vp4dpwssds_maskz): Use "v" instead of "Yh" constraint.
9282 * config/i386/constraints.md (Yh): Remove.
9284 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9286 * config/i386/i386.c (regclass_map): Declare integer REX registers
9289 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
9291 * doc/service.texi (Service): Switch the fsf.org link to https.
9293 2018-09-22 Chung-Ju Wu <jasonwucj@gmail.com>
9296 * config/nds32/nds32.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
9297 Define to speculation_safe_value_not_needed.
9299 2018-09-21 Florian Weimer <fweimer@redhat.com>
9302 * doc/extend.texi (Common Function Attributes): Mention that
9303 noreturn suppresses tail call optimization.
9305 2018-09-21 Jeff Law <law@redhat.com>
9307 * gimple-ssa-evrp.c (evrp_dom_walker::cleanup): Call
9308 vr_values::cleanup_edges_and_switches.
9309 * tree-vrp.c (to_remove_edges, to_update_switch_stmts): Moved into
9311 (identify_jump_threads): Remove EDGE_IGNORE handling.
9312 (execute_vrp): Move handling of to_remove_edges and
9313 to_update_switch_stmts into vr_values class member functions.
9314 * tree-vrp.h (switch_update, to_remove_edges): Remove declarations.
9315 (to_update_switch_stmts): Likewise.
9316 * vr-values.c: Include cfghooks.h.
9317 (vr_values::vr_values): Initialize to_remove_edges and
9318 to_update_switch_stmts.
9319 (vr_values::~vr_values): Verify to_remove_edges and
9320 to_update_switch_stmts are empty.
9321 (vr_values::simplify_switch_using_ranges): Set EDGE_IGNORE as needed.
9322 (vr_values::cleanup_edges_and_switches): New member function.
9323 * vr-values.h (vr_values): Add cleanup_edges_and_switches member
9324 function. Add new data members.
9326 2018-09-21 David Malcolm <dmalcolm@redhat.com>
9328 PR tree-optimization/87309
9329 * dumpfile.c (dump_context::begin_scope): Filter the dump_loc
9330 calls with pflags and alt_flags.
9331 (selftest::test_capture_of_dump_calls): Add test of interaction of
9332 MSG_OPTIMIZED_LOCATIONS with AUTO_DUMP_SCOPE.
9334 2018-09-21 Olivier Hainque <hainque@adacore.com>
9336 * config.gcc: Factorize and comment inclusion of vxworks-dummy.h.
9338 2018-09-21 Olivier Hainque <hainque@adacore.com>
9340 * config/vxworks.h (CLEAR_INSN_CACHE): #define to 1.
9342 2018-09-21 Olivier Hainque <hainque@adacore.com>
9344 * config/vxworks.h (VXWORKS_LIBGCC_SPEC): Remove -lc_internal.
9345 Merge block comment with the one ahead of VXWORKS_LIBS_RTP. Then:
9346 (VXWORKS_LIBS_RTP): Minor reordering.
9348 2018-09-21 Olivier Hainque <hainque@adacore.com>
9350 * config/vxworks.h (STARTFILE_PREFIX_SPEC): Define.
9351 (VXWORKS_LIBS_DIR_RTP): Remove definition and use.
9353 2018-09-21 Olivier Hainque <hainque@adacore.com>
9355 * config/vxworks.h (SIZE_TYPE): Account for TARGET_VXWORKS64.
9356 (PTRDIFF_TYPE): Likewise.
9358 2018-09-21 Olivier Hainque <hainque@adacore.com>
9360 * config.gcc: Enforce def of TARGET_VXWORKS64 to 1 from
9361 triplet, similar to support for VxWorks7.
9362 * config/vxworks-dummy.h: Provide a default definition
9363 of TARGET_VXWORKS64 to 0.
9365 2018-09-21 Olivier Hainque <hainque@adacore.com>
9367 * config/vxworks.h (TARGET_VXWORKS7): Move default definition ...
9368 * config/vxworks-dummy.h: here.
9370 2018-09-21 Olivier Hainque <hainque@adacore.com>
9372 * config.gcc: Prepend vxworks-dummy.h to tm_file for powerpc*
9374 2018-09-21 Shaokun Zhang <zhangshaokun@hisilicon.com>
9375 Bo Zhou <zbo.zhou@hisilicon.com>
9377 * config/aarch64/aarch64-cores.def (tsv110): New CPU.
9378 * config/aarch64/aarch64-tune.md: Regenerated.
9379 * doc/invoke.texi (AArch64 Options/-mtune): Add "tsv110".
9380 * config/aarch64/aarch64.c (tsv110_tunings): New tuning table.
9381 * config/aarch64/aarch64-cost-tables.h: Add "tsv110" extra costs.
9383 2018-09-21 Andrew Stubbs <ams@codesourcery.com>
9384 Julian Brown <julian@codesourcery.com>
9386 * builtins.c (get_builtin_sync_mem): Handle address spaces.
9388 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
9390 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
9391 if the call takes a static chain.
9393 2018-09-21 Martin Liska <mliska@suse.cz>
9395 * auto-profile.c (autofdo_source_profile::read): Do not
9397 (read_profile): Do not add working sets.
9398 (read_autofdo_file): Remove sum_all.
9399 (afdo_callsite_hot_enough_for_early_inline): Remove const
9401 * coverage.c (struct counts_entry): Remove gcov_summary.
9402 (read_counts_file): Read new GCOV_TAG_OBJECT_SUMMARY,
9403 do not support GCOV_TAG_PROGRAM_SUMMARY.
9404 (get_coverage_counts): Remove summary and expected
9406 * coverage.h (get_coverage_counts): Likewise.
9407 * doc/gcov-dump.texi: Remove -w option.
9408 * gcov-dump.c (dump_working_sets): Remove.
9409 (main): Do not support '-w' option.
9410 (print_usage): Likewise.
9411 (tag_summary): Likewise.
9412 * gcov-io.c (gcov_write_summary): Do not dump
9414 (gcov_read_summary): Likewise.
9415 (gcov_histo_index): Remove.
9416 (gcov_histogram_merge): Likewise.
9417 (compute_working_sets): Likewise.
9418 * gcov-io.h (GCOV_TAG_OBJECT_SUMMARY): Mark
9420 (GCOV_TAG_PROGRAM_SUMMARY): Mark it obsolete.
9421 (GCOV_TAG_SUMMARY_LENGTH): Adjust.
9422 (GCOV_HISTOGRAM_SIZE): Remove.
9423 (GCOV_HISTOGRAM_BITVECTOR_SIZE): Likewise.
9424 (struct gcov_summary): Simplify rapidly just
9425 to runs and sum_max fields.
9426 (gcov_histo_index): Remove.
9427 (NUM_GCOV_WORKING_SETS): Likewise.
9428 (compute_working_sets): Likewise.
9429 * gcov-tool.c (print_overlap_usage_message): Remove
9430 trailing empty line.
9431 * gcov.c (read_count_file): Read GCOV_TAG_OBJECT_SUMMARY.
9432 (output_lines): Remove program related line.
9433 * ipa-profile.c (ipa_profile): Do not consider GCOV histogram.
9434 * lto-cgraph.c (output_profile_summary): Do not stream GCOV
9436 (input_profile_summary): Do not read it.
9437 (merge_profile_summaries): And do not merge it.
9438 (input_symtab): Do not call removed function.
9439 * modulo-sched.c (sms_schedule): Do not print sum_max.
9440 * params.def (HOT_BB_COUNT_FRACTION): Reincarnate param that was
9441 removed when histogram method was invented.
9442 (HOT_BB_COUNT_WS_PERMILLE): Mention that it's used only in LTO
9444 * postreload-gcse.c (eliminate_partially_redundant_load): Fix
9446 * predict.c (get_hot_bb_threshold): Use HOT_BB_COUNT_FRACTION
9447 and dump selected value.
9448 * profile.c (add_working_set): Remove.
9449 (get_working_sets): Likewise.
9450 (find_working_set): Likewise.
9451 (get_exec_counts): Do not work with working sets.
9452 (read_profile_edge_counts): Do not inform as sum_max is removed.
9453 (compute_branch_probabilities): Likewise.
9454 (compute_value_histograms): Remove argument for call of
9455 get_coverage_counts.
9456 * profile.h: Do not make gcov_summary const.
9458 2018-09-21 Monk Chiang <sh.chiang04@gmail.com>
9460 * config.gcc (nds32*-*-*): Set TARGET_DEFAULT_TLSDESC_TRAMPOLINE=0.
9462 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
9464 PR tree-optimization/86990
9465 * gimple-ssa-store-merging.c (imm_store_chain_info:coalesce_immediate):
9466 Check that the entire merged store group is made of constants only for
9469 2018-09-20 Allan Sandfeld Jensen <allan.jensen@qt.io>
9471 * gcc.c (LINK_COMMAND_SPEC): Handle -r like -nostdlib.
9472 (VTABLE_VERIFICATION_SPEC): Likewise.
9473 (SANITIZER_EARLY_SPEC): Likewise.
9474 (SANITIZER_SPEC): Likewise.
9475 * config/darwin.h (LINK_COMMAND_SPEC): Likewise.
9476 * doc/invoke.texi (Link Options): Document -r.
9478 2018-09-20 Richard Biener <rguenther@suse.de>
9481 * gimplify.c (gimplify_expr): Retain alignment of
9482 addressable lvalue in dereference.
9484 2018-09-20 Alexandre Oliva <aoliva@redhat.com>
9487 * configure.ac: Check for .loc is_stmt support.
9488 * configure, config.in: Rebuilt.
9489 * dwarf2out.c (dwarf2out_source_line): Skip is_stmt
9492 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
9494 * config/rs6000/rs6000.opt (misel=no, misel=yes): Delete.
9495 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -misel=yes and
9498 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
9500 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
9502 * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete
9505 2018-09-20 Marek Polacek <polacek@redhat.com>
9507 * doc/invoke.texi: Add -Wno-init-list-lifetime to C++ Language Options.
9509 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
9511 PR tree-optimization/87288
9512 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
9513 into account when determining PEELING_FOR_NITERS.
9515 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
9517 PR tree-optimization/86877
9518 * tree-vect-loop.c (vect_analyze_loop_2): Call
9519 vect_verify_datarefs_alignment.
9521 2018-09-19 Marek Polacek <polacek@redhat.com>
9523 * doc/invoke.texi: Document -Wclass-conversion.
9525 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
9527 * config/pa/pa.c (pa_adjust_priority): Delete.
9528 (TARGET_SCHED_ADJUST_PRIORITY): Delete define.
9530 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
9531 (atomic_storehi): Likewise.
9532 (atomic_storesi): Likewise.
9533 (atomic_loaddi): Restore compare and swap exchange loop code.
9535 2018-09-19 Segher Boessenkool <segher@kernel.crashing.org>
9537 PR rtl-optimization/86902
9538 * combine.c (try_combine): When changing the CC mode used, don't change
9539 an unrelated mode in other_insn to that new CC mode.
9541 2018-09-19 David Malcolm <dmalcolm@redhat.com>
9543 * tree-data-ref.c (runtime_alias_check_p): Use formatted printing
9544 with %T in place of calls to dump_generic_expr.
9545 (prune_runtime_alias_test_list): Likewise.
9546 (create_runtime_alias_checks): Likewise.
9547 * tree-vect-data-refs.c (vect_check_nonzero_value): Likewise.
9548 (vect_analyze_data_ref_dependence): Likewise.
9549 (vect_slp_analyze_data_ref_dependence): Likewise.
9550 (vect_record_base_alignment): Likewise. Use %G in place of call
9551 to dump_gimple_stmt.
9552 (vect_compute_data_ref_alignment): Likewise.
9553 (verify_data_ref_alignment): Likewise.
9554 (vect_find_same_alignment_drs): Likewise.
9555 (vect_analyze_group_access_1): Likewise.
9556 (vect_analyze_data_ref_accesses): Likewise.
9557 (dependence_distance_ge_vf): Likewise.
9558 (dump_lower_bound): Likewise.
9559 (vect_prune_runtime_alias_test_list): Likewise.
9560 (vect_find_stmt_data_reference): Likewise.
9561 (vect_analyze_data_refs): Likewise.
9562 (vect_create_addr_base_for_vector_ref): Likewise.
9563 (vect_create_data_ref_ptr): Likewise.
9564 * tree-vect-loop-manip.c (vect_set_loop_condition): Likewise.
9565 (vect_can_advance_ivs_p): Likewise.
9566 (vect_update_ivs_after_vectorizer): Likewise.
9567 (vect_gen_prolog_loop_niters): Likewise.
9568 (vect_prepare_for_masked_peels): Likewise.
9569 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
9570 (vect_determine_vectorization_factor): Likewise.
9571 (vect_is_simple_iv_evolution): Likewise.
9572 (vect_analyze_scalar_cycles_1): Likewise.
9573 (vect_analyze_loop_operations): Likewise.
9574 (report_vect_op): Likewise.
9575 (vect_is_slp_reduction): Likewise.
9576 (check_reduction_path): Likewise.
9577 (vect_is_simple_reduction): Likewise.
9578 (vect_create_epilog_for_reduction): Likewise.
9579 (vect_finalize_reduction:): Likewise.
9580 (vectorizable_induction): Likewise.
9581 (vect_transform_loop_stmt): Likewise.
9582 (vect_transform_loop): Likewise.
9583 (optimize_mask_stores): Likewise.
9584 * tree-vect-patterns.c (vect_pattern_detected): Likewise.
9585 (vect_split_statement): Likewise.
9586 (vect_recog_over_widening_pattern): Likewise.
9587 (vect_recog_average_pattern): Likewise.
9588 (vect_determine_min_output_precision_1): Likewise.
9589 (vect_determine_precisions_from_range): Likewise.
9590 (vect_determine_precisions_from_users): Likewise.
9591 (vect_mark_pattern_stmts): Likewise.
9592 (vect_pattern_recog_1): Likewise.
9593 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
9594 (vect_record_max_nunits): Likewise.
9595 (vect_build_slp_tree_1): Likewise.
9596 (vect_build_slp_tree_2): Likewise.
9597 (vect_print_slp_tree): Likewise.
9598 (vect_analyze_slp_instance): Likewise.
9599 (vect_detect_hybrid_slp_stmts): Likewise.
9600 (vect_detect_hybrid_slp_1): Likewise.
9601 (vect_slp_analyze_operations): Likewise.
9602 (vect_slp_analyze_bb_1): Likewise.
9603 (vect_transform_slp_perm_load): Likewise.
9604 (vect_schedule_slp_instance): Likewise.
9605 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
9606 (vect_mark_stmts_to_be_vectorized): Likewise.
9607 (vect_init_vector_1): Likewise.
9608 (vect_get_vec_def_for_operand): Likewise.
9609 (vect_finish_stmt_generation_1): Likewise.
9610 (vect_check_load_store_mask): Likewise.
9611 (vectorizable_call): Likewise.
9612 (vectorizable_conversion): Likewise.
9613 (vectorizable_operation): Likewise.
9614 (vectorizable_load): Likewise.
9615 (vect_analyze_stmt): Likewise.
9616 (vect_is_simple_use): Likewise.
9617 (vect_get_vector_types_for_stmt): Likewise.
9618 (vect_get_mask_type_for_stmt): Likewise.
9619 * tree-vectorizer.c (increase_alignment): Likewise.
9621 2018-09-19 Andrew Stubbs <ams@codesourcery.com>
9623 * doc/rtl.texi: Adjust vec_select description.
9624 * simplify-rtx.c (simplify_binary_operation_1): Allow VEC_SELECT to use
9625 non-constant selectors.
9627 2018-09-19 Matthew Malcomson <matthew.malcomson@arm.com>
9629 * config/aarch64/aarch64-protos.h
9630 (aarch64_offset_9bit_signed_unscaled_p): New declaration.
9631 * config/aarch64/aarch64.md (arches): New "rcpc8_4" attribute value.
9632 (arch_enabled): Add check for "rcpc8_4" attribute value of "arch".
9633 * config/aarch64/aarch64.h (AARCH64_FL_RCPC8_4): New bitfield.
9634 (AARCH64_FL_FOR_ARCH8_4): Include AARCH64_FL_RCPC8_4.
9635 (AARCH64_FL_PROFILE): Move index so flags are ordered.
9636 (AARCH64_ISA_RCPC8_4): New flag.
9637 * config/aarch64/aarch64.c (offset_9bit_signed_unscaled_p): Renamed
9638 to aarch64_offset_9bit_signed_unscaled_p.
9639 * config/aarch64/atomics.md (atomic_store<mode>): Allow offset
9641 * config/aarch64/constraints.md (Ust): New constraint.
9642 * config/aarch64/predicates.md.
9643 (aarch64_9bit_offset_memory_operand): New predicate.
9644 (aarch64_rcpc_memory_operand): New predicate.
9646 2018-09-19 Eric Botcazou <ebotcazou@adacore.com>
9648 PR rtl-optimization/87361
9649 * rtlanal.c (nonzero_bits1): Revert accidental change.
9651 2018-09-19 Richard Biener <rguenther@suse.de>
9653 PR tree-optimization/87349
9654 PR tree-optimization/87342
9655 * tree-ssa-sccvn.c (do_rpo_vn): Iterate max_rpo computation.
9657 2018-09-18 Marek Polacek <polacek@redhat.com>
9659 P1064R0 - Allowing Virtual Function Calls in Constant Expressions
9660 * gimple-fold.c (gimple_get_virt_method_for_vtable): Adjust assert.
9662 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
9664 * config/rs6000/rs6000.md: Remove old "Cygnus sibcall" comment.
9666 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
9668 PR rtl-optimization/86882
9669 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
9671 2018-09-18 Uros Bizjak <ubizjak@gmail.com>
9673 * config/i386/i386.md (*<code>extend<mode>xf2): Macroize insn from
9674 *<code>extendsfxf2 and *<code>extenddfxf2 using MODEF mode iterator.
9676 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
9679 * doc/invoke.texi (Link Options): Fix formatting and grammar.
9681 2018-09-18 Richard Biener <rguenther@suse.de>
9684 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
9685 (compute_samebase_partition_bases): Likewise.
9686 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
9687 (gimple_can_coalesce_p): Simplify.
9689 2018-09-18 Hans-Peter Nilsson <hp@bitrange.com>
9691 Handle a library implementation of ffs calling __builtin_ffs.
9692 * config/mmix/mmix.c (TARGET_INIT_LIBFUNCS): Override with...
9693 (mmix_init_libfuncs): New function: make __builtin_ffs expand
9696 2018-09-17 David Malcolm <dmalcolm@redhat.com>
9698 * diagnostic-show-locus.c (class layout_range): Add field
9700 (layout_range::layout_range): Add "original_idx" param and use it
9701 to initialize new field.
9702 (make_range): Use 0 for original_idx.
9703 (layout::layout): Pass in index to calls to
9704 maybe_add_location_range.
9705 (layout::maybe_add_location_range): Add param "original_idx" and
9706 pass it on to layout_range.
9707 (layout::print_any_labels): Pass on range->m_original_idx to
9709 (gcc_rich_location::add_location_if_nearby): Use 0 for
9711 * gcc-rich-location.h (text_range_label::get_text): Update for new
9713 (range_label_for_type_mismatch::get_text): Likewise.
9715 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
9717 * config/i386/i386.c (ix86_emit_i387_log1p): Emit fldln2 earlier.
9719 2018-09-17 David Malcolm <dmalcolm@redhat.com>
9721 * gimple-ssa-sprintf.c (fmtwarn): Update for introduction of
9722 format_string_diagnostic_t.
9723 (fmtwarn_n): Likewise.
9724 * substring-locations.c
9725 (format_string_diagnostic_t::format_string_diagnostic_t) New ctor.
9726 (format_warning_n_va): Convert to...
9727 (format_string_diagnostic_t::emit_warning_n_va): ...this.
9728 (format_warning_va): Convert to...
9729 (format_string_diagnostic_t::emit_warning_va): ...this.
9730 (format_warning_at_substring): Convert to...
9731 (format_string_diagnostic_t::emit_warning): ...this.
9732 (format_warning_at_substring_n): Convert to...
9733 (format_string_diagnostic_t::emit_warning_n): ...this.
9734 * substring-locations.h (class format_string_diagnostic_t): New
9736 (format_warning_va): Convert to
9737 format_string_diagnostic_t::emit_warning_va.
9738 (format_warning_n_va): Convert to
9739 format_string_diagnostic_t::emit_warning_n_va.
9740 (format_warning_at_substring): Convert to
9741 format_string_diagnostic_t::emit_warning.
9742 (format_warning_at_substring_n): Convert to
9743 format_string_diagnostic_t::emit_warning_n.
9745 2018-09-17 Cesar Philippidis <cesar@codesourcery.com>
9746 Bernd Schmidt <bernds_cb1@t-online.de>
9748 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with
9751 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
9753 * config/i386/i386.md (truncxf<mode>2_i387_noop_unspec): Change
9754 operand 0 predicate to nonimmediate operand.
9755 (rint<mode>2_frndint): Remove insn pattern.
9756 (rint<mode>2): Change operand 1 predicate to general_operand.
9757 Extend operand 1 to XFmode and generate rintxf2 insn.
9758 (frndintxf2_<rounding>): Rename from frndint<mode>2_<rounding>.
9759 Do not use X87MODEF mode macro.
9760 (frndintxf2_<rounding>_i387): Rename from
9761 frndint<mode>2_<rounding>_i387. Do not use X87MODEF mode macro.
9762 (<rounding_insn><mode>2): For non-SSE modes, extend operand 1
9763 to XFmode and generate significandxf3 insn.
9765 2018-09-17 Richard Biener <rguenther@suse.de>
9767 PR tree-optimization/87328
9768 * tree-ssa-sccvn.c (process_bb): Remove assertion about not
9769 visiting unexecutable backedges when not iterating.
9770 (do_rpo_vn): Mark all edges not executable even when not
9773 2018-09-17 Martin Jambor <mjambor@suse.cz>
9776 * doc/invoke.texi (Warning Options): Likewise.
9778 2018-09-17 Richard Biener <rguenther@suse.de>
9780 PR tree-optimization/87301
9781 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup): Properly
9782 clean EH info from leftover copy assignments.
9784 2018-09-17 Martin Liska <mliska@suse.cz>
9786 PR gcov-profile/85871
9787 * gcov.c (output_intermediate_file): Fix out of bounds
9790 2018-09-17 Vineet Gupta <vgupta@synopsys.com>
9792 * config/arc/arc.c: Object attributes for core4 not reflected
9794 * config/arc/arc.h: Don't restrict DBNZ to core3 (core4 includes
9797 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
9799 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
9801 2018-09-17 Martin Liska <mliska@suse.cz>
9803 * doc/gcov.texi: Document new option --use-hotness-colors.
9804 * gcov.c (struct source_info): Declare new field.
9805 (source_info::source_info): Set default for maximum_count.
9806 (print_usage): Add new -q option.
9807 (process_args): Process it.
9808 (accumulate_line_info): Save src->maximum_count.
9809 (output_line_beginning): Make color line number if
9810 flag_use_hotness_colors is set.
9811 (output_line_details): Pass default argument value.
9812 (output_lines): Pass src->maximum_count.
9814 2018-09-17 Martin Liska <mliska@suse.cz>
9816 * common/config/i386/i386-common.c (ix86_get_valid_option_values):
9817 Use processor_names table.
9818 * config/i386/i386.c (ix86_default_align): Use
9819 processor_cost_table for alignment values.
9820 (ix86_option_override_internal): Use processor_names.
9821 (ix86_function_specific_print): Likewise.
9822 * config/i386/i386.h (struct processor_costs):
9823 Add alignment values.
9824 (struct ptt): Remove and replace with const char *.
9825 * config/i386/x86-tune-costs.h (struct processor_costs):
9826 Declare default alignments for all costs.
9828 2018-09-17 Aldy Hernandez <aldyh@redhat.com>
9830 * tree-vrp.c (extract_range_from_unary_expr): Do not special case
9831 symbolics or VR_VARYING ranges for ABS_EXPR.
9832 * wide-int-range.cc (wide_int_range_abs): Return positive numbers
9833 when range will wrap.
9835 2018-09-15 Eric Botcazou <ebotcazou@adacore.com>
9838 * cfgexpand.c (expand_gimple_basic_block): Be prepared for a BARRIER
9839 before and after a JUMP_TABLE_DATA.
9841 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
9844 * dojump.c (do_compare_and_jump): Canonicalize function pointers
9845 when one operand is a function pointer. Use POINTER_TYPE_P and
9846 FUNC_OR_METHOD_TYPE_P.
9847 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
9848 * fold-const.c (build_range_check): Likewise.
9849 * match.pd (simple_comparison): Likewise.
9851 2018-09-14 David Malcolm <dmalcolm@redhat.com>
9854 * spellcheck.c (get_edit_distance_cutoff): New function.
9855 (selftest::test_edit_distance_unit_test_oneway): Rename to...
9856 (selftest::test_get_edit_distance_one_way): ...this.
9857 (selftest::test_get_edit_distance_unit): Rename to...
9858 (selftest::test_get_edit_distance_both_ways): ...this.
9859 (selftest::test_edit_distances): Move tests to this new function,
9860 and test some more pairs of strings. Update for above renaming.
9861 (selftest::get_old_cutoff): New function.
9862 (selftest::test_get_edit_distance_cutoff): New function.
9863 (selftest::assert_suggested_for): New function.
9864 (ASSERT_SUGGESTED_FOR): New macro.
9865 (selftest::assert_not_suggested_for): New function.
9866 (ASSERT_NOT_SUGGESTED_FOR): New macro.
9867 (selftest::test_suggestions): New function.
9868 (selftest::spellcheck_c_tests): Move test_get_edit_distance_unit
9869 tests to selftest::test_edit_distances and call it. Add calls to
9870 selftest::test_get_edit_distance_cutoff and
9871 selftest::test_suggestions.
9872 * spellcheck.h (get_edit_distance_cutoff): New function declaration.
9873 (best_match::consider): Replace hard-coded cutoff calculation with
9875 (best_match::get_cutoff): New declaration.
9876 (best_match::get_best_meaningful_candidate): Likewise.
9878 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
9880 * builtins.c (fold_builtin_strlen): Remove TODO comment.
9882 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
9885 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
9887 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
9888 terminated string literal.
9890 2018-09-14 Martin Sebor <msebor@redhat.com>
9892 * builtins.c (unterminated_array): Handle ARRAY_REF.
9893 (expand_builtin_stpcpy_1): Detect unterminated char arrays.
9894 * builtins.h (unterminated_array): Declare extern.
9895 * gimple-fold.c (gimple_fold_builtin_stpcpy): Detect unterminated
9897 (gimple_fold_builtin_sprintf): Propagate NO_WARNING to transformed
9900 2018-09-14 Martin Sebor <msebor@redhat.com>
9901 Jeff Law <law@redhat.com>
9903 * builtins.c (unterminated_array): New.
9904 (expand_builtin_strcpy): Adjust.
9905 (expand_builtin_strcpy_args): Detect unterminated arrays.
9906 * gimple-fold.c (get_maxval_strlen): Add argument. Detect
9907 unterminated arrays.
9908 * gimple-fold.h (get_maxval_strlen): Add argument.
9909 (gimple_fold_builtin_strcpy): Detec unterminated arrays.
9911 * gimple-fold.c (get_range_strlen): Add argument.
9912 (get_maxval_strlen): Adjust.
9913 * gimple-fold.h (get_range_strlen): Add argument.
9915 2018-09-14 Wei Xiao <wei3.xiao@intel.com>
9917 * config/i386/movdirintrin.h: Fix copyright year.
9919 2018-09-14 Uros Bizjak <ubizjak@gmail.com>
9921 * reg-stack.c: Include regs.h.
9922 (replace_reg): Assert that mode is MODE_FLOAT or MODE_COMPLEX_FLOAT.
9923 (emit_pop_insn): Default pop insn mode to the reg_raw_mode of
9924 FIRST_STACK_REG, not DFmode.
9925 (emit_swap_insn): Default swap insn mode to the reg_raw_mode of
9926 FIRST_STACK_REG, not XFmode. Explicitly construct swap RTX.
9927 (change stack): Default register mode to the reg_raw_mode of
9928 FIRST_STACK_REG, not DFmode.
9929 * config/i386/i386.md (*swap<mode>): Remove insn pattern.
9930 (*swapxf): Rename from swapxf.
9932 2018-09-14 Carl Love <cel@us.ibm.com>
9934 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
9935 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
9937 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
9940 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
9943 2018-09-14 Sam Tebbs <sam.tebbs@arm.com>
9946 * config/aarch64/aarch64.md (*aarch64_bfxilsi_uxtw): Define.
9948 2018-09-14 Jason Merrill <jason@redhat.com>
9950 Fix --enable-gather-detailed-mem-stats.
9951 * hash-table.c (hash_table_usage): Change from variable to function.
9952 * hash-table.h: Adjust.
9953 * Makefile.in: Add missing dependencies on hash-table.h.
9955 2018-09-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
9957 PR tree-optimization/87259
9959 (pass_cse_reciprocals::execute): Run optimize_recip_sqrt after
9960 execute_cse_reciprocals_1 has tried transforming.
9962 2018-09-14 Aldy Hernandez <aldyh@redhat.com>
9964 * tree-vrp.c (extract_range_from_binary_expr_1): Normalize
9965 VR_VARYING for PLUS/MINUS_EXPR.
9967 2018-09-14 Ilya Leoshkevich <iii@linux.ibm.com>
9969 * config/s390/s390-passes.def (INSERT_PASS_BEFORE): Improve
9972 2018-09-14 Richard Biener <rguenther@suse.de>
9975 * tree-ssa-coalesce.c (ssa_conflicts_merge): Remove conflict
9976 bits for the merged partition.
9978 2018-09-13 Martin Sebor <msebor@redhat.com>
9979 Bernd Edlinger <bernd.edlinger@hotmail.de>
9981 * builtins.h (c_srlen): Add argument.
9982 * builtins.c (warn_string_no_nul): New function.
9983 (c_strlen): Add argument and use it. Update recursive calls.
9984 Pass DECL argument to string_constant to get info on non
9985 terminated strings. Update *NONSTR as needed.
9986 (fold_builtin_strlen): Add argument to calls to c_strlen.
9987 Warn for unterminated arrays.
9988 (warn_string_no_null): Add prototype.
9989 * expr.c (string_constant): Update arguments. Update recursive
9990 calls appropriately. Detect missing NUL terminator and outermost
9991 declaration its missing in.
9992 Improve checks for arrays with nonzero lower bound or elements
9993 that are not a single byte. Simplify offset computation.
9994 Simplify checks for non-NUL terminated strings.
9995 * gimple-fold.c (get_range_strlen): Add argument to c_strlen call.
9996 * gimple-ssa-sprintf.c (get_string_length): Remove unnecessary code.
9998 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
10000 * builtins.c (c_strlen): Handle not zero terminated STRING_CSTs
10002 * fold-const.c (c_getstr): Fix function comment. Remove unused third
10003 argument. Fix range checks.
10004 * fold-const.h (c_getstr): Adjust protoype.
10005 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid folding when
10006 string is constant but contains no NUL byte.
10008 * expr.c (string_constant): Adjust function comment.
10009 Remove bogus check for zero termination.
10011 * fold-const.c (c_getstr): Clamp STRING_LENGTH to STRING_SIZE.
10013 * varasm.c (compare_constant): Compare type size of STRING_CSTs.
10014 (get_constant_size): Don't make STRING_CSTs larger than they are.
10015 (check_string_literal): New check function for STRING_CSTs.
10016 (output_constant): Use it.
10018 2018-09-13 Eric Botcazou <ebotcazou@adacore.com>
10021 * config/visium/visium.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define.
10023 2018-09-13 Richard Biener <rguenther@suse.de>
10025 PR tree-optimization/87263
10026 * tree-ssa-sccvn.c (visit_phi): Revert some earlier changes.
10027 (struct unwind_state): Add max_rpo field.
10028 (do_rpo_vn): Allow up-to-date loop state to be used when not iterating.
10029 Compute max_rpo, the max RPO number a block can be backwards reached
10030 from. Re-write non-iterating mode to a RPO ordered worklist approach,
10031 separating it from the iterating mode.
10033 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
10035 * haifa-sched.c (rank_for_schedule): Schedule by INSN_COST.
10036 (rfs_decision): New scheduling decision.
10038 2018-09-13 Richard Biener <rguenther@suse.de>
10041 * tree-ssa-sccvn.c (vn_nary_op_insert_into): Fix assert.
10042 (vn_nary_op_insert_pieces_predicated): Do not write useless
10043 valid_dominated_by_p entry outside of the allocated storage.
10045 2018-09-13 Omar Sandoval <osandov@osandov.com>
10046 Tom de Vries <tdevries@suse.de>
10049 * dwarf2out.c (is_c): New function.
10050 (add_subscript_info): Add DW_AT_count of 0 for C zero-length arrays.
10052 2018-09-13 Sam Tebbs <sam.tebbs@arm.com>
10055 * config/aarch64/aarch64.md (*aarch64_bfxil):
10057 * config/aarch64/constraints.md (Ulc): Define.
10058 * config/aarch64/aarch64-protos.h (aarch64_high_bits_all_ones_p):
10060 * config/aarch64/aarch64.c (aarch64_high_bits_all_ones_p):
10063 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
10065 * config/aarch64/aarch64.h (TARGET_COMPUTE_FRAME_LAYOUT): Define.
10066 * config/aarch64/aarch64.c (aarch64_expand_prologue): Remove
10067 aarch64_layout_frame call.
10068 (aarch64_expand_epilogue): Likewise.
10069 (aarch64_initial_elimination_offset): Likewise.
10070 (aarch64_get_separate_components): Likewise.
10071 (aarch64_use_return_insn_p): Likewise.
10072 (aarch64_layout_frame): Remove unneeded check.
10074 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10076 * configure.ac: Only append
10077 " : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" to
10078 gcc_config_arguments if it was never reconfigured or last reconfigure
10079 was with different arguments.
10080 * configure: Regenerated.
10082 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10083 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10085 PR middle-end/87290
10086 * expr.c (maybe_optimize_pow2p_mod_cmp): New function.
10087 (maybe_optimize_mod_cmp): Use it if integer_pow2p treeop1.
10089 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10091 PR tree-optimization/87287
10092 * fold-const.c (fold_binary_loc) <case EQ_EXPR>: Move signed modulo
10093 X % C == 0 to X % (unsigned) C == 0 optimization to ...
10094 * match.pd (X % C == 0): ... here. New optimization.
10096 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10098 PR middle-end/82853
10099 * expr.h (maybe_optimize_mod_cmp): Declare.
10100 * expr.c (mod_inv): New function.
10101 (maybe_optimize_mod_cmp): New function.
10102 (do_store_flag): Use it.
10103 * cfgexpand.c (expand_gimple_cond): Likewise.
10105 2018-09-09 Cesar Philippidis <cesar@codesourcery.com>
10106 Julian Brown <julian@codesourcery.com>
10108 PR middle-end/86336
10109 * gimplify.c (gimplify_scan_omp_clauses): Set
10110 target_firstprivatize_array_bases in OpenACC parallel and kernels
10111 region contexts. Remove GOMP_MAP_FIRSTPRIVATE_REFERENCE clauses from
10112 OpenACC data regions.
10114 2018-09-12 Uros Bizjak <ubizjak@gmail.com>
10116 * config/i386/i386.md (sqrt_extend<mode>xf3_i387): Remove.
10117 (sqrt<mode>2): Extend operand 1 to XFmode and generate sqrtxf3 insn.
10119 2018-09-12 Richard Biener <rguenther@suse.de>
10121 PR tree-optimization/87280
10122 * tree-ssa-sccvn.c (process_bb): Handle the case of executable
10123 edge but unreachable target.
10124 (do_rpo_vn): For conservatively handling a PHI only mark
10125 the backedge executable but not the block reachable.
10127 2018-09-12 Richard Biener <rguenther@suse.de>
10129 PR tree-optimization/87266
10130 * tree-ssa-sccvn.c (do_rpo_vn): Always iterate to not yet
10133 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
10135 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
10137 ("trunc<BFP:mode><DFP_ALL:mode>2")
10138 ("trunc<DFP_ALL:mode><BFP:mode>2")
10139 ("extend<BFP:mode><DFP_ALL:mode>2")
10140 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
10141 according to the target operand type.
10143 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10144 Andreas Krebbel <krebbel@linux.ibm.com>
10146 PR tree-optimization/86844
10147 * gimple-ssa-store-merging.c
10148 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
10149 there are any overlapping stores in between them, make sure they are
10150 also coalesced or we give up completely.
10152 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10154 PR middle-end/87248
10155 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
10156 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
10158 2018-09-12 Tom de Vries <tdevries@suse.de>
10160 * common.opt (gdescribe-dies): Add option.
10161 * dwarf2out.c (add_name_and_src_coords_attributes): Add description
10162 attribute for artifical and nameless decls.
10163 (dwarf2out_register_external_die): Add description attribute to
10164 external reference die.
10165 (add_desc_attribute): New functions.
10166 (gen_subprogram_die): Add description attribute to
10167 DW_TAG_call_site_parameter.
10168 * tree-pretty-print.c (print_generic_expr_to_str): New function.
10169 * tree-pretty-print.h (print_generic_expr_to_str): Declare.
10170 * doc/invoke.texi (@item Debugging Options): Add -gdescribe-dies and
10171 -gno-describe-dies.
10172 (@item -gdescribe-dies): Add.
10174 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
10176 * tree-vrp.c (vrp_shift_undefined_p): Remove.
10177 (extract_range_from_binary_expr_1: Call
10178 wide_int_range_shift_undefined_p instead of vrp_shift_undefined_p.
10179 * wide-int-range.h (wide_int_range_shift_undefined_p): Do not
10182 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
10184 * gimple-ssa-warn-alloca.c
10185 (alloca_type_and_limit::alloca_type_and_limit): Initialize limit
10186 field for ALLOCA_BOUND_*_LARGE.
10188 2018-09-11 Nathan Sidwell <nathan@acm.org>
10190 * gcc.c (load_specs, execute, run_attempt): Use %qs not '%s'.
10192 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10194 * reg-stack.c (subst_asm_stack_regs): Call replace_reg also
10195 for clobbers. Remove obsolete comment.
10197 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10199 * config/i386/i386.md (define_attr "type"): Remove mpxmov, mpxmk,
10200 mpxchk, mpxld and mpxst types.
10201 (define_attr length_immediate): Remove all processing of mpx types.
10202 (define_attr prefix_0f): Ditto.
10203 (define_attr memory): Ditto.
10205 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10207 * config/i386/i386.md (fyl2x_extend<mode>xf3_i387): Remove.
10208 (log<mode>2): Change operand 1 predicate to general_operand.
10209 Extend operand 1 to XFmode and generate logxf3 insn.
10210 (log10<mode>2): Change operand 1 predicate to general_operand.
10211 Extend operand 1 to XFmode and generate log10xf3 insn.
10212 (log2<mode>2): Change operand 1 predicate to general_operand.
10213 Extend operand 1 to XFmode and generate log2xf3 insn.
10214 (fyl2xp1_extend<mode>xf3_i387): Remove.
10215 (log1p<mode>2): Change operand 1 predicate to general_operand.
10216 Extend operand 1 to XFmode and generate log1pxf3 insn.
10217 (fxtract_extend<mode>xf3_i387): Remove.
10218 (logb<mode>2): Change operand 1 predicate to general_operand.
10219 Extend operand 1 to XFmode and generate logbxf3 insn.
10220 (ilogb<mode>2): Change operand 1 predicate to general_operand.
10221 Extend operand 1 to XFmode and generate fxtractxf3_i387 insn.
10222 (significand<mode>2): Change operand 1 predicate to general_operand.
10223 Extend operand 1 to XFmode and generate significandxf3 insn.
10225 2018-09-11 Nathan Sidwell <nathan@acm.org>
10227 * gcc.c (perror_with_name, pfatal_with_name): Delete.
10228 (load_specs): Use fatal_error.
10229 (DELETE_IF_ORDINARY, process_command): Use error.
10230 (execute, run_attempt): Use fatal_error.
10232 2018-09-11 Andrew Stubbs <ams@codesourcery.com>
10234 * diagnostic-core.h (sorry_at): New prototype.
10235 * diagnostic.c (sorry_at): New function.
10237 2018-09-11 Aldy Hernandez <aldyh@redhat.com>
10239 * tree-vrp.c (extract_range_from_binary_expr_1): Treat all divisions
10240 by zero as VR_UNDEFINED.
10242 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
10244 * config/i386/i386.md (<sincos>xf2): Rename from *<sincos>xf2_i387.
10245 (*<sincos>_extend<mode>xf2_i387): Remove insn pattern.
10246 (<sincos>mode2): New expander.
10247 (sincos_extend<mode>xf3_i387): Remove insn pattern.
10248 (sincos -> sin, cos splitters): Remove splitter patterns.
10249 (sincos<mode>3): Change operand 2 predicate to general_operand.
10250 Extend operand 2 to XFmode and generate sincosxf3 insn.
10251 (fptanxf4_i387): Change mode of operands 0 and 3 to SFmode.
10252 Change operand 3 predicate to const1_operand.
10253 (fptan_extend<mode>xf4_i387): Remove insn pattern.
10254 (tanxf2): Update operands in the call to fptanxf4_i387.
10255 (tan<mode>2): Change operand 1 predicate to general_operand.
10256 Extend operand 1 to XFmode and generate tanxf3 insn.
10257 (atan2xf3): Rename from *fpatanxf3_i387.
10258 (fpatan_extend<mode>xf3_i387): Remove insn pattern.
10259 (atan2xf3): Remove expander.
10260 (atan2<mode<3): Change operand 1 and 2 predicates to general_operand.
10261 Extend operands 1 and 2 to XFmode and generate atan2xf3 insn.
10262 (atan<mode>2): Change operand 1 predicate to general_operand.
10263 Extend operand 1 to XFmode and generate atanxf3 insn.
10265 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
10267 * config/i386/i386.md (x87/SSE constant load splitter): Use
10268 memory_operand instead of nonimmediate_operand for input operand
10271 2018-09-09 Uros Bizjak <ubizjak@gmail.com>
10273 * config/i386/i386.md (float partial SSE register stall splitter): Move
10274 splitter near its instruction pattern.
10275 (float_extend partial SSE register stall splitter): Ditto.
10276 (float_truncate partial SSE register stall splitter): Ditto.
10278 2018-09-09 Hans-Peter Nilsson <hp@bitrange.com>
10281 * config/mmix/mmix.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
10282 to speculation_safe_value_not_needed.
10285 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
10286 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
10287 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
10288 leaf_function_p, instead use has_hard_reg_initial_val.
10290 2018-09-09 Nathan Sidwell <nathan@acm.org>
10292 * gcc.h (pfatal_with_name): Don't declare here.
10293 * gcc.c (pfatal_with_name): Make static.
10295 2018-09-09 Xianmiao Qu <xianmiao_qu@c-sky.com>
10297 * config/csky/csky.md (*cskyv2_adddi3, *cskyv2_subdi3): Add
10300 2018-09-08 John David Anglin <danglin@gcc.gnu.org>
10302 PR rtl-optimization/85458
10303 * sel-sched.c (sel_target_adjust_priority): Allow backend adjust
10304 priority hook to reduce the priority of EXPR.
10306 2018-09-07 Uros Bizjak <ubizjak@gmail.com>
10308 * config/i386/i386.md (float<SWI48x:mode><MODEF:mode>2) Enable
10309 DImode for x87 on 32bit targets. Conditionally disable x87 modes
10310 with X87_ENABLE_FLOAT. Remove preparation code.
10311 (*float<SWI48:mode><MODEF:mode>2): Rename from
10312 *float<SWI48:mode><MODEF:mode>2_mixed. Handle x87, SSE and mixed
10313 math using "enabled" attribute.
10314 (*floatdi<MODEF:mode>2_i387): Rename from
10315 *float<SWI48x:mode><MODEF:mode>2_i387. Handle only DImode and
10316 enable for 32bit targets only.
10317 (floatdi<X87MODEF:mode>2_i387_with_xmm pre-reload splitter): New
10319 (floatdi<X87MODEF:mode>2_i387_with_xmm): Use register_operand
10320 as operand 1 predicate. Rewrite as define_insn_and_split.
10321 (floatdi<X87MODEF:mode>2_i387_with_xmm memory input splitter): Remove.
10323 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
10325 * reg-stack.c (get_true_reg) <case FLOAT_TRUNCATE>: Reorder
10326 to fallthru to FLOAT case.
10328 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
10331 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
10332 around folding of vec_sl to handle out of range shift values.
10334 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
10336 * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Remove.
10337 Update callers to gen_fix_trunc<mode>_i387_fisttp
10338 (fix_trunc<mode>_i387_fisttp): Change operand 0 predicate to
10339 nonimmediate_operand.
10340 (fix_trunc<mode>_i387_fisttp_with_temp): Remove insn pattern
10341 and corresponding splitters.
10342 (*fix_trunc<mode>_i387_1): Always expand with fix_trunc<mode>_i387.
10343 (fix_truncdi_i387): Change operand 0 predicate to nonimmediate_operand.
10344 (fix_truncdi_i387_with_temp): Remove insn pattern
10345 and corresponding splitters.
10346 (fix_trunc<mode>_i387): Change operand 0 predicate to
10347 nonimmediate_operand.
10348 (fix_trunc<mode>_i387_with_temp): Remove insn pattern
10349 and corresponding splitters.
10350 (*fistdi2_1): Remove.
10352 (fistdi2_with_temp): Remove insn pattern and corresponding splitters.
10353 (lrintxfdi2): Remove expander. Reimplement as define_insn.
10354 (*fist<mode>2_1): Remove.
10355 (fist<mode>2): Ditto.
10356 (fist<mode>2_with_temp): Remove insn pattern and corresponding
10358 (lrintxf<mode>2): Remove expander. Reimplement as define_insn.
10359 (*fist<mode>2_<rounding>_1): Always expand with fist<mode>2_<rounding>.
10360 (fistdi2_<rounding>): Change operand 0 predicate to
10361 nonimmediate_operand.
10362 (fistdi2_<rounding>_with_temp): Remove insn pattern
10363 and corresponding splitters.
10364 (fist<mode>2_<rounding>): Change operand 0 predicate to
10365 nonimmediate_operand.
10366 (fist<mode>2_<rounding>_with_temp): Remove insn pattern
10367 and corresponding splitters.
10369 (*fixuns_trunc<mode>si2_avx512f_zext): Depend on TARGET_SSE_MATH.
10371 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
10373 * varasm.c (output_constructor_regular_field): Check TYPE_SIZE_UNIT of
10376 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
10378 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
10379 early gimple folding of vec_splat().
10380 * tree-vect-generic.c: Remove static from tree_vec_extract() definition.
10381 * gimple-fold.h: Add an extern define for tree_vec_extract().
10383 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
10385 * config/rs6000/rs6000.c (fold_mergehl_helper): Add types_compatible_p
10386 wrappers around TREE_TYPE comparisons.
10388 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
10391 * config/s390/predicates.md: Add nonsym_memory_operand.
10392 * config/s390/s390.c (s390_legitimize_cs_operand): If operand
10393 contains a SYMBOL_REF, load it into an intermediate pseudo.
10394 (s390_emit_compare_and_swap): Legitimize operand.
10395 * config/s390/s390.md: Use the new nonsym_memory_operand
10396 with UNSPECV_CAS patterns.
10398 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
10401 * config/s390/s390-passes.def: New file.
10402 * config/s390/s390-protos.h (class rtl_opt_pass): Add forward
10404 (make_pass_s390_early_mach): Add declaration.
10405 * config/s390/s390.c (make_pass_s390_early_mach):
10406 (s390_option_override): Remove dynamic registration.
10407 * config/s390/t-s390: Add s390-passes.def.
10409 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
10411 * config/s390/s390.c (s390_decompose_constant_pool_ref):
10412 Remove UNSPEC_LTREL_BASE check.
10413 (annotate_constant_pool_refs): Likewise.
10414 (find_constant_pool_ref): Likewise.
10415 (find_ltrel_base): Removed.
10416 (replace_ltrel_base): Removed.
10417 (s390_mainpool_finish): Remove replace_ltrel_base call.
10418 (s390_chunkify_start): Remove pending LTREL_BASE logic.
10419 (s390_chunkify_finish): Remove replace_ltrel_base call.
10420 * config/s390/s390.md: Remove UNSPEC_LTREL_BASE.
10422 2018-09-06 Hans-Peter Nilsson <hp@axis.com>
10425 * config/cris/cris.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
10426 to speculation_safe_value_not_needed.
10428 2018-09-05 Cesar Philippidis <cesar@codesourcery.com>
10429 Bernd Schmidt <bernds_cb1@t-online.de>
10431 * config/nvptx/nvptx-opts.h: New file.
10432 * config/nvptx/nvptx.c (nvptx_file_start): Print the correct .target.
10433 * config/nvptx/nvptx.h: Include "nvptx-opts.h".
10434 (ASM_SPEC): Define.
10435 (TARGET_SM35): New macro.
10436 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with the
10438 * config/nvptx/nvptx.opt (ptx_isa, sm_30, sm_35): New enum and its
10440 (misa=): New option.
10441 * doc/invoke.texi (Nvidia PTX Options): Document -misa.
10443 2018-09-05 Uros Bizjak <ubizjak@gmail.com>
10445 * config/i386/i386.md (truncdfsf2): Remove expander.
10446 (truncdfsf2_with_temp): Ditto.
10447 (truncxf<mode>2): Ditto.
10448 (*truncdfsf_fast_mixed): Remove insn pattern.
10449 (*truncdfsf_fast_i387): Ditto.
10450 (*truncdfsf_mixed): Ditto.
10451 (*truncdfsf_i387): Ditto.
10452 (*truncdfsf2_i387_1): Ditto.
10453 (*truncxfsf2_mixed): Ditto.
10454 (*truncxfdf2_mixed): Ditto.
10455 (*truncxf<mode>2_i387_noop): Ditto. Update callers
10456 to call gen_truncxf<mode>2 instead.
10457 (*truncxf<mode>2_i387): Remove.
10458 (reg->reg splitters): Remove splitter pattern.
10459 (reg->mem splitters): Ditto.
10461 (truncdfsf2): New insn pattern.
10462 (truncxf<mode>2): Ditto.
10464 2018-09-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10466 * tree-ssa-math-opts.c (is_mult_by): New function.
10467 (is_square_of): Use the above.
10468 (optimize_recip_sqrt): New function.
10469 (pass_cse_reciprocals::execute): Use the above.
10471 2018-09-05 Richard Biener <rguenther@suse.de>
10474 * tree-ssa-sccvn.c (rpo_elim::eliminate_push_avail): Make sure
10475 to zero-init the emplaced vec.
10477 2018-09-05 Martin Liska <mliska@suse.cz>
10479 PR tree-optimization/87205
10480 * tree-switch-conversion.c (pass_lower_switch::execute):
10481 Group cases for switch statements.
10483 2018-09-05 Richard Biener <rguenther@suse.de>
10485 PR tree-optimization/87217
10486 * tree-ssa-sccvn.c (vuse_valueize): New.
10487 (vn_reference_lookup_pieces): Use it.
10488 (vn_reference_lookup): Likewise.
10490 2018-09-05 Nathan Sidwell <nathan@acm.org>
10493 * stor-layout.c (place_field): Scan forwards to check last
10494 bitfield when ms_bitfield_placement is in effect.
10496 2018-09-05 Richard Biener <rguenther@suse.de>
10499 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
10502 2018-09-05 Siddhesh Poyarekar <siddhesh@sourceware.org>
10503 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
10505 * config/aarch64/falkor-tag-collision-avoidance.c: New file.
10506 * config.gcc (extra_objs): Build it.
10507 * config/aarch64/t-aarch64 (falkor-tag-collision-avoidance.o):
10509 * config/aarch64/aarch64-passes.def
10510 (pass_tag_collision_avoidance): New pass.
10511 * config/aarch64/aarch64.c (qdf24xx_tunings): Add
10512 AARCH64_EXTRA_TUNE_RENAME_LOAD_REGS to tuning_flags.
10513 (aarch64_classify_address): Remove static qualifier.
10514 (aarch64_address_info, aarch64_address_type): Move to...
10515 * config/aarch64/aarch64-protos.h: ... here.
10516 (make_pass_tag_collision_avoidance): New function.
10517 * config/aarch64/aarch64-tuning-flags.def (rename_load_regs):
10520 2018-09-05 Martin Liska <mliska@suse.cz>
10522 * doc/gcov.texi: Update documentation of humar
10524 * gcov.c (format_count): Print one decimal place, it provides
10525 more fine number of situations like '1G' vs. '1.4G'.
10527 2018-09-05 Martin Liska <mliska@suse.cz>
10530 * config/rs6000/rs6000.opt: Mark the option as Deprecated.
10531 * optc-gen.awk: Allow 'Var' for Deprecated options in order
10532 to generate a MASK value.
10534 2018-09-04 H.J. Lu <hongjiu.lu@intel.com>
10537 * dwarf2out.c (based_loc_descr): Allow hard frame pointer even
10538 if frame pointer isn't used.
10539 (compute_frame_pointer_to_fb_displacement): Likewise.
10541 2018-09-04 Jakub Jelinek <jakub@redhat.com>
10544 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
10545 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
10546 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
10547 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
10548 and OPTION_MASK_ISA_XSAVEC_UNSET.
10550 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
10552 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
10553 XOR operations in NAND case.
10555 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
10557 * wide-int-range.cc (wide_int_range_convert): New.
10558 * wide-int-range.h (wide_int_range_convert): New.
10559 * tree-vrp.c (extract_range_from_unary_expr): Abstract wide int
10560 code into wide_int_range_convert.
10561 (extract_range_into_wide_ints): Do not munge anti range constants
10562 into the entire domain. Just return the range back.
10564 2018-09-04 Martin Liska <mliska@suse.cz>
10566 * genmatch.c (output_line_directive): Add new argument
10568 (dt_simplify::gen_1): Encapsulate dump within __builtin_expect.
10570 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
10572 * doc/invoke.texi (Option Summary): Add whitespace.
10574 * doc/invoke.texi (Option Summary): Add -Waligned-new.
10576 2018-09-04 Richard Biener <rguenther@suse.de>
10578 PR tree-optimization/87211
10579 * tree-ssa-sccvn.c (visit_phi): When value-numbering to a
10580 backedge value we're supposed to treat as VARYING also number
10581 the PHI to VARYING in case it got a different value-number already.
10583 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
10585 * tree-vrp.c (vrp_can_optimize_bit_op): Remove.
10586 (extract_range_from_binary_expr_1): Do not call
10587 vrp_can_optimize_bit_op.
10588 * wide-int-range.cc (wide_int_range_can_optimize_bit_op): Make
10590 (wide_int_range_get_mask_and_bounds): New.
10591 (wide_int_range_optimize_bit_op): New.
10592 (wide_int_range_bit_ior): Call wide_int_range_optimize_bit_op.
10593 (wide_int_range_bit_and): Same.
10594 * wide-int-range.h (wide_int_range_can_optimize_bit_op): Remove.
10595 (wide_int_range_optimize_bit_op): New.
10596 (wide_int_range_get_mask_and_bounds): New.
10598 2018-09-04 Richard Biener <rguenther@suse.de>
10600 PR tree-optimization/87176
10601 * tree-ssa-sccvn.c (visit_phi): Remove redundant allsame
10602 variable. When value-numbering a virtual PHI node make sure
10603 to not value-number to the backedge value.
10605 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
10607 * doc/extend.texi (Long Long, Hex Floats): Document support for
10608 long long and hex floats in more recent versions of ISO C++.
10610 2018-09-03 Richard Biener <rguenther@suse.de>
10612 PR tree-optimization/87177
10613 * tree-ssa-sccvn.c (vuse_ssa_val): Revert previous change, keep
10616 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
10618 * bb-reorder.c (edge_order): Convert to C-qsort-style
10619 tri-state comparator.
10620 (reorder_basic_blocks_simple): Change std::stable_sort to
10623 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
10625 * tree-loop-distribution.c (offset_cmp): Convert to C-qsort-style
10626 tri-state comparator.
10627 (fuse_memset_builtins): Change std::stable_sort to gcc_stablesort.
10629 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
10631 * sort.cc (struct sort_ctx): New field 'nlim'. Use it...
10632 (mergesort): ... here as maximum count for using netsort.
10633 (gcc_qsort): Set nlim to 3 if stable sort is requested.
10634 (gcc_stablesort): New.
10635 * system.h (gcc_stablesort): Declare.
10637 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
10639 * sort.cc (gcc_qsort) [CHECKING_P]: Call qsort_chk.
10640 * system.h (qsort): Always redirect to gcc_qsort. Update comment.
10641 * vec.c (qsort_chk): Do not call gcc_qsort. Update comment.
10643 2018-09-03 Segher Boessenkool <segher@kernel.crashing.org>
10645 * config/rs6000/rs6000.md (*mov<mode>_hardfloat32): Remove %U from the
10646 lxsdx and stxsdx alternatives.
10647 (*mov<mode>_hardfloat64): Ditto.
10648 * config/rs6000/vsx.md (*vsx_extract_<mode>_store): Ditto.
10650 2018-09-03 Richard Biener <rguenther@suse.de>
10652 PR tree-optimization/87200
10653 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Valueize a
10656 2018-09-03 Martin Liska <mliska@suse.cz>
10658 PR tree-optimization/87201
10659 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
10660 Fix parenthesis in an expression.
10662 2018-09-03 Richard Biener <rguenther@suse.de>
10664 PR tree-optimization/87197
10665 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Mark the new def
10666 visited. CSE the VN_INFO hashtable lookup.
10668 PR tree-optimization/87169
10669 * tree-ssa-sccvn.c (do_rpo_vn): When marking loops for not
10670 iterating make sure there's no extra backedges from irreducible
10671 regions feeding the header. Mark the destination block
10674 2018-09-03 Martin Liska <mliska@suse.cz>
10677 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES.
10678 * common/common-targhooks.c (default_get_valid_option_values):
10680 * common/common-targhooks.h (default_get_valid_option_values):
10682 * common/config/i386/i386-common.c: Move processor_target_table
10684 (ix86_get_valid_option_values): New function.
10685 (TARGET_GET_VALID_OPTION_VALUES): New macro.
10686 * config/i386/i386.c (struct ptt): Move to i386-common.c.
10687 (PTA_*): Move all defined masks into i386-common.c.
10688 (ix86_function_specific_restore): Use new processor_cost_table.
10689 * config/i386/i386.h (struct ptt): Moved from i386.c.
10690 (struct pta): Likewise.
10691 * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES.
10692 * doc/tm.texi.in: Likewise.
10693 * opt-suggestions.c (option_proposer::suggest_option):
10694 Pass prefix to build_option_suggestions.
10695 (option_proposer::get_completions): Likewise.
10696 (option_proposer::build_option_suggestions): Use the new target
10698 * opts.c (struct option_help_tuple): New struct.
10699 (print_filtered_help): Use the new target hook.
10701 2018-09-03 Martin Liska <mliska@suse.cz>
10703 PR middle-end/59521
10704 * predict.c (set_even_probabilities): Add likely_edges
10705 argument and handle cases where we have precisely one
10707 (combine_predictions_for_bb): Catch also likely_edges.
10708 (tree_predict_by_opcode): Handle gswitch statements.
10709 * tree-cfg.h (find_case_label_for_value): New declaration.
10710 (find_taken_edge_switch_expr): Likewise.
10711 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
10712 Find pivot in decision tree based on probabily, not by number of
10715 2018-09-02 Gerald Pfeifer <gerald@pfeifer.com>
10717 * doc/standards.texi (Standards): Update Objective-C reference.
10719 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
10721 * doc/install.texi (Prerequisites): Update link for MPC.
10723 2018-09-01 Michael Matz <matz@suse.de>
10725 PR tree-optimization/87074
10726 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
10727 PHIs for outer-loop uses.
10729 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
10731 * doc/generic.texi (OpenMP): Adjust link to openmp.org.
10732 * doc/invoke.texi (C Dialect Options): Ditto.
10734 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
10736 * doc/install.texi (Prerequisites): Adjust link mpfr.org.
10738 2018-08-31 Richard Biener <rguenther@suse.de>
10740 PR tree-optimization/87168
10741 * tree-ssa-sccvn.c (SSA_VAL): Add visited output parameter.
10742 (rpo_elim::eliminate_avail): When OP was not visited it must
10745 2018-08-31 David Malcolm <dmalcolm@redhat.com>
10747 * tree-vrp.c (copy_value_range): Convert param "from" from
10748 "value_range *" to "const value_range *".
10749 (range_is_null): Likewise for param "vr".
10750 (range_int_cst_p): Likewise.
10751 (range_int_cst_singleton_p): Likewise.
10752 (symbolic_range_p): Likewise.
10753 (value_ranges_intersect_p): Likewise for both params.
10754 (value_range_nonnegative_p): Likewise for param "vr".
10755 (value_range_constant_singleton): Likewise.
10756 (vrp_set_zero_nonzero_bits): Likewise for param "ar".
10757 (extract_range_into_wide_ints): Likewise for param "vr".
10758 (extract_range_from_multiplicative_op): Likewise for params "vr0"
10760 (vrp_can_optimize_bit_op): Likewise.
10761 (extract_range_from_binary_expr_1): Likewise for params "vr0_" and
10763 (extract_range_from_unary_expr): Likewise.
10764 (debug_value_range): Likewise for param "vr".
10765 (value_range::dump): Add "const" qualifier.
10766 (vrp_prop::check_array_ref): Convert local "vr" from
10767 "value_range *" to "const value_range *".
10768 (vrp_prop::check_mem_ref): Likewise.
10769 (vrp_prop::visit_stmt): Likewise for local "old_vr".
10770 (vrp_intersect_ranges_1): Likewise for param "vr_1".
10771 (vrp_intersect_ranges): Likewise.
10772 (simplify_stmt_for_jump_threading): Likewise for local "vr".
10773 (vrp_prop::vrp_finalize): Likewise.
10774 * tree-vrp.h (value_range::dump): Add "const" qualifier.
10775 (vrp_intersect_ranges): Add "const" qualifier to params as above.
10776 (extract_range_from_unary_expr): Likewise.
10777 (value_range_constant_singleton): Likewise.
10778 (symbolic_range_p): Likewise.
10779 (copy_value_range): Likewise.
10780 (extract_range_from_binary_expr_1): Likewise.
10781 (range_int_cst_p): Likewise.
10782 (vrp_set_zero_nonzero_bits): Likewise.
10783 (range_int_cst_singleton_p): Likewise.
10785 2018-08-31 Vlad Lazar <vlad.lazar@arm.com>
10787 * config/aarch64/arm_neon.h (vabsd_s64): New.
10788 (vnegd_s64): Likewise.
10790 2018-08-31 Martin Jambor <mjambor@suse.cz>
10792 * ipa-cp.c (estimate_local_effects): Replace wrong MAX with MIN.
10794 2018-08-31 Martin Liska <mliska@suse.cz>
10796 * ipa-icf.c (sem_item::add_type): Use
10797 sem_item::m_type_hash_cache.
10798 * ipa-icf.h: Move the cache from sem_item_optimizer
10801 2018-08-31 Nathan Sidwell <nathan@acm.org>
10803 * doc/extend.texi (Backwards Compatibility): Remove implicit
10804 extern C leeway of () being (...).
10806 2018-08-31 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10808 * ipa-inline.c (can_inline_edge_by_limits_p): Fix typos in comment.
10810 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
10814 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
10816 2018-08-31 Jakub Jelinek <jakub@redhat.com>
10818 PR middle-end/87138
10819 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
10820 gen_int_mode. Formatting fixes.
10822 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
10824 * target.def (custom_function_descriptors): Improve documentation.
10825 * doc/tm.texi.in (Trampolines): Expand discussion of function
10826 descriptors and move TARGET_CUSTOM_FUNCTION_DESCRIPTORS to the
10827 beginning of the section.
10828 * doc/tm.texi: Regenerated.
10830 2018-08-30 Jose E. Marchesi <jose.marchesi@oracle.com>
10832 * cfg.h (class auto_edge_flag): Spell out the template-id of the
10833 base class in the initializer list. This is a workaround for
10834 building with older GCC.
10835 (class auto_bb_flag): Likewise.
10837 2018-08-30 Aaron Sawdey <acsawdey@linux.ibm.com>
10839 * config/rs6000/altivec.md (altivec_eq<mode>): Remove star.
10840 (altivec_vcmpequ<VI_char>_p): Remove star.
10841 * config/rs6000/rs6000-string.c (do_load_for_compare): Support
10843 (expand_strncmp_vec_sequence): New function.
10844 (emit_final_str_compare_vec): New function.
10845 (expand_strn_compare): Add support for vector strncmp.
10846 * config/rs6000/rs6000.opt (-mstring-compare-inline-limit): Change
10847 length specification to bytes.
10848 * config/rs6000/vsx.md (vsx_ld_elemrev_v16qi_internal): Remove star.
10849 (vcmpnezb_p): New pattern.
10850 * doc/invoke.texi (RS/6000 and PowerPC Options): Update documentation
10851 for option -mstring-compare-inline-limit.
10853 2018-08-30 Thiago Macieira <thiago.macieira@intel.com>
10855 * config/i386/i386.c (PTA_WESTMERE): Remove PTA_AES.
10856 (PTA_SKYLAKE): Add PTA_AES.
10857 (PTA_GOLDMONT): Likewise.
10859 2018-08-29 Jan Hubicka <jh@suse.cz>
10862 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
10863 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
10865 2018-08-29 Jan Hubicka <jh@suse.cz>
10867 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not follow
10869 (hash_tree): Do not visit TYPE_STUB_DECL.
10870 * tree-streamer-out.c (write_ts_type_common_tree_pointers): Do not
10871 stream TYPE_STUB_DECL.
10872 * tree-streamer-in.c (lto_input_ts_type_common_tree_pointers): Likewise.
10873 * ipa-utils.h (type_with_linkage_p): Do not rely on TYPE_STUB_DECL
10874 after free_lang_data.
10875 (type_in_anonymous_namespace_p): Likewise.
10877 2018-08-29 Jan Hubicka <jh@suse.cz>
10879 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
10880 comment that it has to be even number.
10881 (class sreal): Change m_sig type to int32_t.
10882 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
10883 int64_t for temporary calculations.
10884 (sreal_verify_basics): Drop one bit from minimum and maximum.
10886 2018-08-30 Richard Biener <rguenther@suse.de>
10888 PR tree-optimization/87147
10889 * tree-ssa-sccvn.c (SSA_VISITED): New function.
10890 (visit_phi): When the degenerate result is from the backedge and
10891 we didn't visit its definition yet drop to VARYING.
10892 (do_rpo_vn): Properly mark blocks with incoming backedges as executable.
10894 2018-08-29 Jan Hubicka <jh@suse.cz>
10896 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not walk
10898 (hash_tree): Likewise.
10900 2018-08-29 Jan Hubicka <jh@suse.cz>
10902 * tree.c (find_decls_types_r): Walk also TYPE_NEXT_PTR_TO
10903 and TYPE_NEXT_REF_TO.
10905 2018-08-29 Jan Hubicka <jh@suse.cz>
10907 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
10908 comment that it has to be even number.
10909 (class sreal): Change m_sig type to int32_t.
10910 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
10911 int64_t for temporary calculations.
10912 (sreal_verify_basics): Drop one bit from minimum and maximum.
10914 2018-08-30 Tamar Christina <tamar.christina@arm.com>
10916 * config/aarch64/aarch64.c (aarch64_expand_movmem): Set TImode max.
10918 2018-08-30 Vlad Lazar <vlad.lazar@arm.com>
10920 PR middle-end/86995
10921 * expmed.c (canonicalize_comparison): Use wi::sub instead of wi::add
10922 if to_add is negative.
10924 2018-08-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
10926 PR middle-end/87053
10927 * builtins.c (c_strlen): Improve range checks.
10929 2018-08-29 Martin Sebor <msebor@redhat.com>
10930 Jeff Law <law@redhat.com>
10932 PR tree-optimization/86714
10933 PR tree-optimization/86711
10934 * builtins.c (c_strlen): Add arguments to call to string_constant.
10935 * expr.c (string_constant): Add argument. Detect missing nul
10936 terminator and outermost declaration it's missing in.
10937 * expr.h (string_constant): Add argument.
10938 * fold-const.c (read_from_constant_string): Add arguments to call to
10940 (c_getstr): Likewise.
10941 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
10942 to string_constant.
10943 * tree-ssa-strlen.c (get_stridx): Likewise.
10945 2018-08-29 Jan Hubicka <jh@suse.cz>
10947 * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers):
10948 Do not stream DECL_VINDEX.
10949 * tree-streamer-out.c (write_ts_function_decl_tree_pointers): Likewise.
10950 * tree.c (free_lang_data_in_decl): Clear DECL_VINDEX.
10951 (decl_function_context): Use DECL_VIRTUAL_P rather than DECL_VINDEX.
10953 2018-08-29 Richard Biener <rguenther@suse.de>
10955 * tree-ssa-sccvn.c (vuse_ssa_val): Return NULL for unvisited
10956 virtual operands that are not default defs to honor region
10958 (rpo_vn_valueize): Remove ineffective code here.
10960 2018-08-29 Richard Biener <rguenther@suse.de>
10962 PR tree-optimization/87132
10963 * tree-ssa-alias.c (get_continuation_for_phi): Do not translate
10964 when skipping defs reachable over backedges.
10966 2018-08-29 Richard Biener <rguenther@suse.de>
10968 * tree-core.h: Document use of deprecated_flag in SSA_NAME.
10969 * tree.h (SSA_NAME_POINTS_TO_READONLY_MEMORY): Define.
10970 * tree-into-ssa.c (pass_build_ssa::execute): Initialize
10971 function parameters SSA_NAME_POINTS_TO_READONLY_MEMORY from fnspec.
10972 * tree-ssa-sccvn.c (const_parms, init_const_parms): Remove.
10973 (vn_reference_lookup_3): Remove use of const_parms.
10974 (free_rpo_vn): Do not free const_parms.
10975 (do_rpo_vn): Do not call init_const_parms.
10976 * tree-ssa-alias.c (refs_may_alias_p_1): Honor
10977 SSA_NAME_POINTS_TO_READONLY_MEMORY.
10978 (call_may_clobber_ref_p_1): Likewise.
10980 2018-08-29 Alexander Monakov <amonakov@ispras.ru>
10983 * invoke.texi (Optimization Options): List -ftree-scev-cprop.
10985 (-ftree-scev-cprop): Document.
10987 2018-08-29 Jan Hubicka <jh@suse.cz>
10989 * sreal.h (normalize, normalize_up, normalize_down): Add new_sig/new_exp
10991 (sreal constructor): Update.
10992 * sreal.c (sreal:operator+, sreal:operator-, sreal:operator*,
10993 sreal:operator/): Update.
10995 2018-08-29 Martin Liska <mliska@suse.cz>
10997 * tree-switch-conversion.c (switch_conversion::expand):
10998 Strenghten assumption about gswitch statements.
11000 2018-08-29 Richard Biener <rguenther@suse.de>
11002 PR tree-optimization/87117
11003 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
11004 re-value-number released SSA VDEFs.
11006 2018-08-29 Richard Biener <rguenther@suse.de>
11008 PR tree-optimization/87126
11009 * tree-ssa-sccvn.c (vn_reference_insert): Remove assert.
11011 2018-08-28 Jim Wilson <jimw@sifive.com>
11013 * config/riscv/pic.md: Rewrite.
11014 * config/riscv/riscv.c (riscv_address_insns): Return cost of 3 for
11016 * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Delete.
11017 (SOFTF, default_load, softload, softstore): New.
11019 2018-08-28 Jeff Law <law@redhat.com>
11021 * fold-const.c (fold_binary_loc): Remove recently added assert.
11023 2018-08-28 Joern Rennecke <joern.rennecke@riscy-ip.com>
11025 * genpreds.c (write_predicate_subfunction): Also add ATTRIBUTE_UNUSED
11026 to OP parmeter of generated function.
11028 2018-08-28 MCC CS <deswurstes@users.noreply.github.com>
11030 PR tree-optimization/87009
11031 * match.pd: Add boolean optimizations.
11033 2018-08-28 Martin Sebor <msebor@redhat.com>
11035 PR middle-end/86631
11036 * calls.c (alloc_max_size): Treat HOST_WIDE_INT special.
11037 * gimple-ssa-warn-alloca.c (adjusted_warn_limit): New function.
11038 (pass_walloca::gate): Use it.
11039 (alloca_call_type): Same.
11040 (pass_walloca::execute): Same.
11041 * stor-layout.c (layout_decl): Treat HOST_WIDE_INT special.
11043 2018-08-28 David Malcolm <dmalcolm@redhat.com>
11045 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): Change version check on
11046 GCC_VERSION for usage of "__gcc_dump_printf__" format from
11047 >= 3005 to >= 9000.
11049 2018-08-28 Richard Biener <rguenther@suse.de>
11051 PR tree-optimization/87124
11052 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Guard against
11053 constants before looking up avail.
11055 2018-08-28 Jakub Jelinek <jakub@redhat.com>
11057 PR middle-end/87099
11058 * calls.c (maybe_warn_nonstring_arg): Punt early if
11059 warn_stringop_overflow is zero. Don't call get_range_strlen
11060 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
11061 Swap comparison operands to have constants on rhs. Only use
11062 lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
11063 increment lenrng[0].
11065 2018-08-28 Richard Sandiford <richard.sandiford@arm.com>
11067 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Fix unguarded
11068 use of tree_to_shwi. Remove duplicated test for the size being
11069 a whole number of bytes.
11071 2018-08-28 Richard Biener <rguenther@suse.de>
11073 PR tree-optimization/87117
11074 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup):
11075 Handle removed stmt without LHS (GIMPLE_NOP).
11077 2018-08-28 Richard Biener <rguenther@suse.de>
11079 PR tree-optimization/87117
11080 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Exclude
11081 void which is is_gimple_reg_type by checking for COMPLETE_TYPE_P.
11083 2018-08-28 Richard Biener <rguenther@suse.de>
11085 PR tree-optimization/87117
11086 * tree-ssa-pre.c (compute_avail): Do not make expressions
11087 with predicated values available.
11088 (get_expr_value_id): Assert we do not run into predicated value
11091 2018-08-28 Richard Biener <rguenther@suse.de>
11093 PR tree-optimization/87117
11094 * tree-ssa-operands.c (add_stmt_operand): STRING_CST may
11095 get virtual operands.
11096 (get_expr_operands): Handle STRING_CST like other decls.
11098 2018-08-28 Martin Liska <mliska@suse.cz>
11100 * tree.h: Update documentation of fndecl_built_in_p
11104 2018-08-27 Jeff Law <law@redhat.com>
11105 PR tree-optimization/87110
11106 * tree-ssa-dse.c (compute_trims): Handle non-constant
11109 2018-08-27 Martin Sebor <msebor@redhat.com>
11111 PR tree-optimization/86914
11112 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
11114 2018-08-27 Martin Sebor <msebor@redhat.com>
11116 PR tree-optimization/87112
11117 * builtins.c (expand_builtin_strnlen): Convert c_strlen result to
11118 the type of the bound argument.
11120 2018-08-27 Jeff Law <law@redhat.com>
11122 * tree-ssa-dse.c (compute_trims): Handle case where the reference's
11123 type does not have a TYPE_SIZE_UNIT.
11125 2018-08-27 Steve Ellcey <sellcey@cavium.com>
11127 * config/aarch64/aarch64-speculation.cc: Replace include of cfg.h
11128 with include of backend.h.
11130 2018-08-27 Richard Biener <rguenther@suse.de>
11132 PR tree-optimization/86927
11133 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
11134 use const cond reduction code.
11136 2018-08-27 Alexander Monakov <amonakov@ispras.ru>
11138 PR tree-optimization/85758
11139 * match.pd ((X & Y) ^ Y): Add :s qualifier to inner expression.
11141 2018-08-27 David Malcolm <dmalcolm@redhat.com>
11144 * diagnostic-show-locus.c (class layout_range): Update for
11145 conversion of show_caret_p to a tri-state.
11146 (layout_range::layout_range): Likewise.
11147 (make_range): Likewise.
11148 (layout::maybe_add_location_range): Likewise.
11149 (layout::should_print_annotation_line_p): Don't show annotation
11150 lines for ranges that are SHOW_LINES_WITHOUT_RANGE.
11151 (layout::get_state_at_point): Update for conversion of
11152 show_caret_p to a tri-state. Bail out early for
11153 SHOW_LINES_WITHOUT_RANGE, so that such ranges don't affect
11154 underlining or source colorization.
11155 (gcc_rich_location::add_location_if_nearby): Update for conversion
11156 of show_caret_p to a tri-state.
11157 (selftest::test_one_liner_multiple_carets_and_ranges): Likewise.
11158 (selftest::test_one_liner_fixit_replace_equal_secondary_range):
11160 (selftest::test_one_liner_labels): Likewise.
11161 * gcc-rich-location.c (gcc_rich_location::add_expr): Update for
11162 conversion of show_caret_p to a tri-state.
11163 * pretty-print.c (text_info::set_location): Likewise.
11164 * pretty-print.h (text_info::set_location): Likewise.
11165 * substring-locations.c (format_warning_n_va): Likewise.
11166 * tree-diagnostic.c (default_tree_printer): Likewise.
11167 * tree-pretty-print.c (newline_and_indent): Likewise.
11169 2018-08-27 David Malcolm <dmalcolm@redhat.com>
11172 * diagnostic-show-locus.c (get_line_span_for_fixit_hint): Show the
11173 line above for line-insertion fix-it hints.
11174 (selftest::test_fixit_insert_containing_newline): Update the
11175 expected results, and add a test with line-numbering enabled.
11177 2018-08-27 Martin Liska <mliska@suse.cz>
11180 * sanopt.c (sanitize_rewrite_addressable_params): Ignore
11181 params with DECL_HAS_VALUE_EXPR_P.
11183 2018-08-27 Martin Liska <mliska@suse.cz>
11185 * config/i386/i386.c (ix86_expand_set_or_movmem): Dump
11186 selected expansion strategy.
11188 2018-08-27 Martin Liska <mliska@suse.cz>
11190 * builtins.h (is_builtin_fn): Remove and fndecl_built_in_p.
11191 * builtins.c (is_builtin_fn): Likewise.
11192 * attribs.c (diag_attr_exclusions): Use new function
11193 fndecl_built_in_p and remove check for FUNCTION_DECL if
11195 (builtin_mathfn_code): Likewise.
11196 (fold_builtin_expect): Likewise.
11197 (fold_call_expr): Likewise.
11198 (fold_builtin_call_array): Likewise.
11199 (fold_call_stmt): Likewise.
11200 (set_builtin_user_assembler_name): Likewise.
11201 (is_simple_builtin): Likewise.
11202 * calls.c (gimple_alloca_call_p): Likewise.
11203 (maybe_warn_nonstring_arg): Likewise.
11204 * cfgexpand.c (expand_call_stmt): Likewise.
11205 * cgraph.c (cgraph_update_edges_for_call_stmt_node): Likewise.
11206 (cgraph_edge::verify_corresponds_to_fndecl): Likewise.
11207 (cgraph_node::verify_node): Likewise.
11208 * cgraphclones.c (build_function_decl_skip_args): Likewise.
11209 (cgraph_node::create_clone): Likewise.
11210 * config/arm/arm.c (arm_insert_attributes): Likewise.
11211 * config/i386/i386.c (ix86_gimple_fold_builtin): Likewise.
11212 * dse.c (scan_insn): Likewise.
11213 * expr.c (expand_expr_real_1): Likewise.
11214 * fold-const.c (operand_equal_p): Likewise.
11215 (fold_binary_loc): Likewise.
11216 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
11217 * gimple-low.c (lower_stmt): Likewise.
11218 * gimple-pretty-print.c (dump_gimple_call): Likewise.
11219 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
11221 * gimple.c (gimple_build_call_from_tree): Likewise.
11222 (gimple_call_builtin_p): Likewise.
11223 (gimple_call_combined_fn): Likewise.
11224 * gimplify.c (gimplify_call_expr): Likewise.
11225 (gimple_boolify): Likewise.
11226 (gimplify_modify_expr): Likewise.
11227 (gimplify_addr_expr): Likewise.
11228 * hsa-gen.c (gen_hsa_insns_for_call): Likewise.
11229 * ipa-cp.c (determine_versionability): Likewise.
11230 * ipa-fnsummary.c (compute_fn_summary): Likewise.
11231 * ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
11232 * ipa-split.c (visit_bb): Likewise.
11233 (split_function): Likewise.
11234 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
11235 * lto-cgraph.c (input_node): Likewise.
11236 * lto-streamer-out.c (write_symbol): Likewise.
11237 * omp-low.c (setjmp_or_longjmp_p): Likewise.
11238 (lower_omp_1): Likewise.
11239 * predict.c (strip_predict_hints): Likewise.
11240 * print-tree.c (print_node): Likewise.
11241 * symtab.c (symtab_node::output_to_lto_symbol_table_p): Likewise.
11242 * trans-mem.c (is_tm_irrevocable): Likewise.
11243 (is_tm_load): Likewise.
11244 (is_tm_simple_load): Likewise.
11245 (is_tm_store): Likewise.
11246 (is_tm_simple_store): Likewise.
11247 (is_tm_abort): Likewise.
11248 (tm_region_init_1): Likewise.
11249 * tree-call-cdce.c (gen_shrink_wrap_conditions): Likewise.
11250 * tree-cfg.c (verify_gimple_call): Likewise.
11251 (move_stmt_r): Likewise.
11252 (stmt_can_terminate_bb_p): Likewise.
11253 * tree-eh.c (lower_eh_constructs_2): Likewise.
11254 * tree-if-conv.c (if_convertible_stmt_p): Likewise.
11255 * tree-inline.c (remap_gimple_stmt): Likewise.
11256 (copy_bb): Likewise.
11257 (estimate_num_insns): Likewise.
11258 (fold_marked_statements): Likewise.
11259 * tree-sra.c (scan_function): Likewise.
11260 * tree-ssa-ccp.c (surely_varying_stmt_p): Likewise.
11261 (optimize_stack_restore): Likewise.
11262 (pass_fold_builtins::execute): Likewise.
11263 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
11264 (mark_all_reaching_defs_necessary_1): Likewise.
11265 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Likewise.
11266 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
11267 (pass_forwprop::execute): Likewise.
11268 * tree-ssa-loop-im.c (stmt_cost): Likewise.
11269 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
11270 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Likewise.
11271 * tree-ssa-strlen.c (get_string_length): Likewise.
11272 * tree-ssa-structalias.c (handle_lhs_call): Likewise.
11273 (find_func_aliases_for_call): Likewise.
11274 * tree-ssa-ter.c (find_replaceable_in_bb): Likewise.
11275 * tree-stdarg.c (optimize_va_list_gpr_fpr_size): Likewise.
11276 * tree-tailcall.c (find_tail_calls): Likewise.
11277 * tree.c (need_assembler_name_p): Likewise.
11278 (free_lang_data_in_decl): Likewise.
11279 (get_call_combined_fn): Likewise.
11280 * ubsan.c (is_ubsan_builtin_p): Likewise.
11281 * varasm.c (incorporeal_function_p): Likewise.
11282 * tree.h (DECL_BUILT_IN): Remove and replace with
11284 (DECL_BUILT_IN_P): Transfort to fndecl_built_in_p.
11285 (fndecl_built_in_p): New.
11287 2018-08-27 Martin Liska <mliska@suse.cz>
11289 PR tree-optimization/86847
11290 * tree-switch-conversion.c (switch_decision_tree::dump_case_nodes):
11291 Dump also subtree probability.
11292 (switch_decision_tree::do_jump_if_equal): New function.
11293 (switch_decision_tree::emit_case_nodes): Handle special
11294 situations in balanced tree that can be emitted much simpler.
11295 Fix calculation of probabilities that happen in tree expansion.
11296 * tree-switch-conversion.h (struct cluster): Add
11298 (struct simple_cluster): Likewise.
11299 (struct case_tree_node): Add new function has_child.
11300 (do_jump_if_equal): New.
11302 2018-08-27 Martin Liska <mliska@suse.cz>
11304 * tree-switch-conversion.c (bit_test_cluster::find_bit_tests):
11305 Add new argument to bit_test_cluster constructor.
11306 (bit_test_cluster::emit): Set bits really number of values
11308 (bit_test_cluster::hoist_edge_and_branch_if_true): Add
11309 probability argument.
11310 * tree-switch-conversion.h (struct bit_test_cluster):
11311 Add m_handles_entire_switch.
11313 2018-08-27 Martin Liska <mliska@suse.cz>
11315 PR tree-optimization/86702
11316 * tree-switch-conversion.c (jump_table_cluster::emit):
11317 Make probabilities even for values in jump table
11318 according to number of cases handled.
11319 (switch_decision_tree::compute_cases_per_edge): Pass
11320 argument to reset_out_edges_aux function.
11321 (switch_decision_tree::analyze_switch_statement): Likewise.
11322 * tree-switch-conversion.h (switch_decision_tree::reset_out_edges_aux):
11325 2018-08-27 Martin Liska <mliska@suse.cz>
11327 * cfgexpand.c (expand_asm_stmt): Use label_to_block and pass
11328 cfun argument explicitly.
11329 * gimple-pretty-print.c (dump_gimple_switch): Likewise.
11330 * hsa-gen.c (gen_hsa_insns_for_switch_stmt): Use new
11331 function gimple_switch_default_bb.
11332 (convert_switch_statements):
11334 * ipa-fnsummary.c (set_switch_stmt_execution_predicate):
11335 * stmt.c (label_to_block_fn): Use label_to_block and pass
11336 cfun argument explicitly and use gimple_switch_label_bb.
11337 (expand_case): Likewise.
11338 * tree-cfg.c (lower_phi_internal_fn): Use label_to_block and pass
11339 cfun argument explicitly. Likewise.
11340 (make_edges_bb): Likewise.
11341 (make_cond_expr_edges): Likewise.
11342 (get_cases_for_edge): Likewise.
11343 (make_gimple_switch_edges): Likewise.
11344 (label_to_block_fn): Likewise.
11345 (label_to_block): Likewise.
11346 (make_goto_expr_edges): Likewise.
11347 (make_gimple_asm_edges): Likewise.
11348 (main_block_label): Likewise.
11349 (group_case_labels_stmt): Likewise.
11350 (find_taken_edge_computed_goto): Likewise.
11351 (find_taken_edge_switch_expr): Likewise.
11352 (gimple_verify_flow_info): Likewise.
11353 (gimple_redirect_edge_and_branch): Likewise.
11354 (gimple_switch_label_bb): New function.
11355 (gimple_switch_default_bb): Likewise.
11356 (gimple_switch_edge): Likewise.
11357 (gimple_switch_default_edge): Likewise.
11358 * tree-cfg.h (label_to_block_fn): Remove and replace ...
11359 (label_to_block): ... with this.
11360 (gimple_switch_label_bb): New.
11361 (gimple_switch_default_bb): Likewise.
11362 (gimple_switch_edge): Likewise.
11363 (gimple_switch_default_edge): Likewise.
11364 * tree-cfgcleanup.c (convert_single_case_switch): Use
11365 new gimple functions and pass new argument to label_to_block.
11366 (cleanup_control_flow_bb):
11367 * tree-eh.c (make_eh_dispatch_edges): Use label_to_block and pass
11368 cfun argument explicitly.
11369 (make_eh_edges): Likewise.
11370 (redirect_eh_dispatch_edge): Likewise.
11371 (lower_resx): Likewise.
11372 (lower_eh_dispatch): Likewise.
11373 (maybe_remove_unreachable_handlers): Likewise.
11374 (unsplit_eh): Likewise.
11375 (cleanup_empty_eh): Likewise.
11376 (verify_eh_edges): Likewise.
11377 (verify_eh_dispatch_edge): Likewise.
11378 * tree-ssa-dom.c (record_edge_info): Likewise.
11379 * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): Likewise.
11380 * tree-ssa-threadedge.c (thread_around_empty_blocks): Likewise.
11381 (thread_through_normal_block): Likewise.
11382 * tree-ssa-uncprop.c (associate_equivalences_with_edges): Likewise.
11383 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds):
11384 * tree-switch-conversion.c (switch_conversion::collect): Use new
11386 (switch_conversion::check_final_bb): Likewise.
11387 (switch_conversion::gather_default_values): Pass new argument
11389 (switch_conversion::build_constructors): Likewise.
11390 (switch_decision_tree::compute_cases_per_edge): Use new
11391 gimple_switch_edge function.
11392 (switch_decision_tree::analyze_switch_statement): Pass new argument
11394 (switch_decision_tree::try_switch_expansion): Use
11395 gimple_switch_default_edge.
11396 * tree-vrp.c (find_switch_asserts): Pass new argument
11398 * vr-values.c (vr_values::vrp_visit_switch_stmt): Likewise.
11399 (vr_values::simplify_switch_using_ranges): Likewise.
11401 2018-08-27 Richard Biener <rguenther@suse.de>
11403 * cfganal.h (rev_post_order_and_mark_dfs_back_seme): Declare.
11404 * cfganal.c (rev_post_order_and_mark_dfs_back_seme): New function.
11406 * tree-ssa-sccvn.h (struct vn_pval): New structure.
11407 (struct vn_nary_op_s): Add unwind_to member. Add
11408 predicated_values flag and put result into a union together
11409 with a linked list of vn_pval.
11410 (struct vn_ssa_aux): Add name member to make maintaining
11411 a map of SSA name to vn_ssa_aux possible. Remove no longer
11412 needed info, dfsnum, low, visited, on_sccstack, use_processed
11413 and range_info_anti_range_p members.
11414 (run_scc_vn, vn_eliminate, free_scc_vn, vn_valueize): Remove.
11415 (do_rpo_vn, run_rpo_vn, eliminate_with_rpo_vn, free_rpo_vn):
11417 (vn_valueize): New global.
11418 (vn_context_bb): Likewise.
11419 (VN_INFO_RANGE_INFO, VN_INFO_ANTI_RANGE_P, VN_INFO_RANGE_TYPE,
11420 VN_INFO_PTR_INFO): Remove.
11421 * tree-ssa-sccvn.c: ... (rewrite)
11422 (pass_fre::execute): For -O2+ initialize loops and run
11423 RPO VN in optimistic mode (iterating). For -O1 and -Og
11424 run RPO VN in non-optimistic mode.
11425 * params.def (PARAM_SCCVN_MAX_SCC_SIZE): Remove.
11426 (PARAM_RPO_VN_MAX_LOOP_DEPTH): Add.
11427 * doc/invoke.texi (sccvn-max-scc-size): Remove.
11428 (rpo-vn-max-loop-depth): Document.
11429 * tree-ssa-alias.c (walk_non_aliased_vuses): Stop walking
11430 when valuezing the VUSE signals we walked out of the region.
11431 * tree-ssa-pre.c (phi_translate_1): Ignore predicated values.
11432 (phi_translate): Set VN context block to use for availability
11434 (compute_avail): Likewise.
11435 (pre_valueize): New function.
11436 (pass_pre::execute): Adjust to the RPO VN API.
11438 * tree-ssa-loop-ivcanon.c: Include tree-ssa-sccvn.h.
11439 (propagate_constants_for_unrolling): Remove.
11440 (tree_unroll_loops_completely): Perform value-numbering
11441 on the unrolled bodies loop parent.
11443 2018-08-27 Richard Biener <rguenther@suse.de>
11445 * tree-ssa-pre.c (compute_antic): Re-use inverted postorder
11446 for partial antic compute.
11448 2018-08-27 Jakub Jelinek <jakub@redhat.com>
11450 PR rtl-optimization/87065
11451 * combine.c (simplify_if_then_else): Formatting fix.
11452 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
11454 (known_cond): Don't return const_true_rtx for vector modes. Use
11455 CONST0_RTX instead of const0_rtx. Formatting fixes.
11457 2018-08-27 Martin Liska <mliska@suse.cz>
11459 PR gcov-profile/87069
11460 * gcov.c (process_file): Record files already processed
11461 and warn about a file being processed multiple times.
11463 2018-08-27 Martin Liska <mliska@suse.cz>
11466 * config/aarch64/aarch64.c (aarch64_override_options_internal):
11467 Set default values for x_aarch64_*_string strings.
11468 * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}==
11469 prefix. For -mabi do not print '=ABI' in help and use
11470 <option_value> format for -msve-vector-bits and -moverride
11473 2018-08-26 Jeff Law <law@redhat.com>
11475 * config/mips/frame-header-opt.c: Include "backend.h" rather than
11478 2018-08-26 Marek Polacek <polacek@redhat.com>
11480 PR c++/87029, Implement -Wredundant-move.
11481 * doc/invoke.texi: Document -Wredundant-move.
11483 2018-08-25 Martin Sebor <msebor@redhat.com>
11485 PR tree-optimization/87059
11486 * builtins.c (expand_builtin_strncmp): Convert MIN_EXPR operand
11487 to the same type as the other.
11488 * fold-const.c (fold_binary_loc): Assert expectation.
11490 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
11492 * config/darwin.c (machopic_legitimize_pic_address): Clean up
11493 extraneous parentheses, dead code section and formatting.
11495 2018-08-24 David Malcolm <dmalcolm@redhat.com>
11498 * diagnostic-show-locus.c (layout::layout): Ensure the margin is
11499 wide enough for jumps in the line-numbering to be visible.
11500 (layout::print_gap_in_line_numbering): New member function.
11501 (layout::calculate_line_spans): When using line numbering, merge
11502 line spans that are only 1 line apart.
11503 (diagnostic_show_locus): When printing line numbers, show gaps in
11504 line numbering directly, rather than printing headers.
11505 (selftest::test_diagnostic_show_locus_fixit_lines): Add test of
11506 line-numbering with multiple line spans.
11507 (selftest::test_fixit_insert_containing_newline_2): Add test of
11508 line-numbering, in which the spans are close enough to be merged.
11510 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
11512 * gimple-ssa-evrp-analyze.c (set_ssa_range_info): Pass value_range
11513 to range_includes_zero_p. Do not special case VR_ANTI_RANGE.
11514 * tree-vrp.c (range_is_nonnull): Remove.
11515 (range_includes_zero_p): Accept value_range instead of min/max.
11516 (extract_range_from_binary_expr_1): Do not early bail on
11518 Use range_includes_zero_p instead of range_is_nonnull.
11519 (extract_range_from_unary_expr): Use range_includes_zero_p instead
11520 of range_is_nonnull.
11521 (vrp_meet_1): Pass value_range to range_includes_zero_p. Do not
11522 special case VR_ANTI_RANGE.
11523 (vrp_finalize): Same.
11524 * tree-vrp.h (range_includes_zero_p): Pass value_range as argument
11525 instead of min/max.
11526 (range_is_nonnull): Remove.
11527 * vr-values.c (vrp_stmt_computes_nonzero): Use
11528 range_includes_zero_p instead of range_is_nonnull.
11529 (extract_range_basic): Pass value_range to range_includes_zero_p
11530 instead of range_is_nonnull.
11532 2018-08-24 Uros Bizjak <ubizjak@gmail.com>
11534 * emit-rtl.c (init_emit_once): Do not emit MODE_POINTER_BOUNDS RTXes.
11535 * emit-rtl.h (rtl_data): Remove return_bnd.
11536 * explow.c (trunc_int_for_mode): Do not handle POINTER_BOUNDS_MODE_P.
11537 * function.c (diddle_return_value): Do not handle crtl->return_bnd.
11538 * genmodes.c (complete_mode): Do not handle MODE_POINTER_BOUNDS.
11539 (POINTER_BOUNDS_MODE): Remove definition.
11540 (make_pointer_bounds_mode): Remove.
11541 (get_mode_class): Do not handle MODE_POINTER_BOUNDS.
11542 * machmode.h (POINTER_BOUNDS_MODE_P): Remove definition.
11543 (scalare_mode::includes_p): Do not handle MODE_POINTER_BOUNDS.
11544 * mode-classes.def: Do not define MODE_POINTER_BOUNDS.
11545 * stor-layout.c (int_mode_for_mode): Do not handle MODE_POINTER_BOUNDS.
11546 * tree-core.h (enum tree_index): Remove TI_POINTER_BOUNDS_TYPE.
11547 * varasm.c (output_constant_pool_2): Do not handle MODE_POINTER_BOUNDS.
11549 * config/i386/i386-modes.def (BND32, BND64): Remove.
11550 * config/i386/i386.c (dbx_register_map): Remove bound registers.
11551 (dbx64_register_map): Ditto.
11552 (svr4_dbx_register_map): Ditto.
11553 (indirect_thunk_bnd_needed): Remove.
11554 (indirect_thunks_bnd_used): Ditto.
11555 (indirect_return_bnd_needed): Ditto.
11556 (indirect_return_via_cx_bnd): Ditto.
11557 (enum indirect_thunk_prefix): Remove indirect_thunk_prefix_bnd.
11558 (indirect_thunk_name): Remove handling of indirect_thunk_prefix_bnd.
11559 (output_indirect_thunk): Ditto. Remove need_prefix argument.
11560 (output_indirect_thunk_function): Remove handling of
11561 indirect_return_bnd_needed, indirect_return_via_cx_bnd,
11562 indirect_thunk_bnd_needed and indirect_thunks_bnd_used variables.
11563 (ix86_save_reg): Remove handling of crtl->return_bnd.
11564 (ix86_legitimate_constant_p): Remove handling of POINTER_BOUNDS_MODE_P.
11565 (ix86_print_operand_address_as): Remove handling of UNSPEC_BNDMK_ADDR
11566 and UNSPEC_BNDLX_ADDR.
11567 (ix86_output_indirect_branch_via_reg): Remove handling of
11568 indirect_thunk_prefix_bnd.
11569 (ix86_output_indirect_branch_via_push): Ditto.
11570 (ix86_output_function_return): Ditto.
11571 (ix86_output_indirect_function_return): Ditto.
11572 (avoid_func_arg_motion): Do not handle UNSPEC_BNDSTX.
11573 * config/i386/i386.h (FIXED_REGISTERS): Remove bound registers.
11574 (CALL_USED_REGISTERS): Ditto.
11575 (REG_ALLOC_ORDER): Update for removal of bound registers.
11576 (HI_REGISTER_NAMES): Ditto.
11577 * config/i386/i386.md (UNSPEC_BNDMK, UNSPEC_BNDMK_ADDR, UNSPEC_BNDSTX)
11578 (UNSPEC_BNDLDX, UNSPEC_BNDLDX_ADDR, UNSPEC_BNDCL, UNSPEC_BNDCU)
11579 (UNSPEC_BNDCN, UNSPEC_MPX_FENCE): Remove.
11580 (BND0_REG, BND1_REG, BND2_REG, BND3_REG): Remove
11581 (FIRST_PSEUDO_REG): Update.
11582 (BND): Remove mode iterator.
11583 * config/i386/predicates.md (bnd_mem_operator): Remove.
11585 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
11587 * tree-vect-stmts.c (vectorizable_bswap): Handle variable-length
11590 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
11592 * tree-vect-slp.c (vect_transform_slp_perm_load): Separate out
11593 the case in which the permute needs only a single element and
11594 repeats for every vector of the result. Extend that case to
11595 handle variable-length vectors.
11596 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
11598 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
11601 * dwarf2out.c (save_macinfo_strings): Call set_indirect_string
11602 on DW_MACINFO_start_file for -gsplit-dwarf -g3.
11604 2018-08-24 Richard Biener <rguenther@suse.de>
11606 * cfg.h (struct control_flow_graph): Add edge_flags_allocated and
11607 bb_flags_allocated members.
11608 (auto_flag): New RAII class for allocating flags.
11609 (auto_edge_flag): New RAII class for allocating edge flags.
11610 (auto_bb_flag): New RAII class for allocating bb flags.
11611 * cfgloop.c (verify_loop_structure): Allocate temporary edge
11613 * cfganal.c (dfs_enumerate_from): Remove use of visited sbitmap
11614 in favor of temporarily allocated BB flag.
11615 * hsa-brig.c: Re-order includes.
11616 * hsa-dump.c: Likewise.
11617 * hsa-regalloc.c: Likewise.
11618 * print-rtl.c: Likewise.
11619 * profile-count.c: Likewise.
11621 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
11624 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
11627 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
11630 * wide-int-range.cc (wide_int_range_div): Do not ignore result
11631 from wide_int_range_multiplicative_op.
11633 2018-08-23 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
11635 * tree-vect-data-refs.c (vect_grouped_store_supported): Fix typo
11638 2018-08-23 Giuliano Belinassi <giuliano.belinassi@usp.br>
11640 * genmatch.c (parser::parse_operation): Fix typo 'exapnded'
11643 2018-08-23 Alexander Monakov <amonakov@ispras.ru>
11645 * tree-scalar-evolution.c (final_value_replacement_loop): Dump
11646 full GENERIC expression used for replacement.
11648 2018-08-23 Aldy Hernandez <aldyh@redhat.com>
11650 * tree-vrp.c (abs_extent_range): Remove.
11651 (extract_range_into_wide_ints): Pass wide ints by reference.
11652 (extract_range_from_binary_expr_1): Rewrite the *DIV_EXPR code.
11653 Pass wide ints by reference in all calls to
11654 extract_range_into_wide_ints.
11655 * wide-int-range.cc (wide_int_range_div): New.
11656 * wide-int-range.h (wide_int_range_div): New.
11657 (wide_int_range_includes_zero_p): New.
11658 (wide_int_range_zero_p): New.
11660 2018-08-23 Matthew Malcomson <matthew.malcomson@arm.com>
11662 * config/aarch64/aarch64.md (arches): New enum.
11663 (arch): New enum attr.
11664 (arch_enabled): New attr.
11665 (enabled): Now uses arch_enabled only.
11666 (simd, sve, fp16): Removed attribute.
11667 (fp): Attr now defined in terms of 'arch'.
11668 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64, *movti_aarch64,
11669 *movhf_aarch64, <optab><fcvt_target><GPF:mode>2,
11670 <FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3,
11671 <FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Merge 'fp' and 'simd'
11672 attributes into 'arch'.
11673 (*movsf_aarch64, *movdf_aarch64, *movtf_aarch64, *add<mode>3_aarch64,
11674 subdi3, neg<mode>2, <optab><mode>3, one_cmpl<mode>2,
11675 *<NLOGICAL:optab>_one_cmpl<mode>3, *xor_one_cmpl<mode>3,
11676 *aarch64_ashl_sisd_or_int_<mode>3, *aarch64_lshr_sisd_or_int_<mode>3,
11677 *aarch64_ashr_sisd_or_int_<mode>3, *aarch64_sisd_ushl): Convert use of
11678 'simd' attribute into 'arch'.
11679 (load_pair_sw_<SX:mode><SX2:mode>, load_pair_dw_<DX:mode><DX2:mode>,
11680 store_pair_sw_<SX:mode><SX2:mode>, store_pair_dw_<DX:mode><DX2:mode>):
11681 Convert use of 'fp' attribute to 'arch'.
11682 * config/aarch64/aarch64-simd.md (move_lo_quad_internal_<mode>,
11683 move_lo_quad_internal_<mode>): (different modes) Merge 'fp' and 'simd'
11685 (move_lo_quad_internal_be_<mode>, move_lo_quad_internal_be_<mode>):
11686 (different modes) Merge 'fp' and 'simd' into 'arch'.
11687 (*aarch64_combinez<mode>, *aarch64_combinez_be<mode>): Merge 'fp' and
11688 'simd' into 'arch'.
11690 2018-08-23 Segher Boessenkool <segher@kernel.crashing.org>
11692 PR rtl-optimization/87026
11693 * expmed.c (canonicalize_comparison): If we can no longer create
11694 pseudoregisters, don't.
11696 2018-08-23 Richard Earnshaw <rearnsha@arm.com>
11699 * config/arm/arm-protos.h (arm_emit_speculation_barrier): New
11701 * config/arm/arm.c (speculation_barrier_libfunc): New static
11703 (arm_init_libfuncs): Initialize it.
11704 (arm_emit_speculation_barrier): New function.
11705 * config/arm/arm.md (speculation_barrier): Call
11706 arm_emit_speculation_barrier for architectures that do not have
11708 (speculation_barrier_insn): Only match on Armv7 or later.
11710 2018-08-23 Richard Biener <rguenther@suse.de>
11712 PR middle-end/87024
11713 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
11716 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
11718 * config/aarch64/aarch64.c (aarch64_evpc_sve_tbl): Fix handling
11719 of single-vector TBLs.
11720 (aarch64_vectorize_vec_perm_const): Set one_vector_p when only
11721 one input is given.
11723 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
11726 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
11727 aarch64_evpc_tbl guard.
11729 2018-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
11731 * tree-ssa-dse.c (compute_trims): Avoid folding away undefined
11734 2018-08-22 Martin Sebor <msebor@redhat.com>
11736 PR middle-end/87052
11737 * tree-pretty-print.c (pretty_print_string): Add argument.
11738 (dump_generic_node): Call to pretty_print_string with string size.
11740 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
11742 PR rtl-optimization/86771
11743 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
11744 of two SETs into those two SETs, one to be placed at i2, if that SETs
11745 destination is modified between i2 and i3.
11747 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
11749 PR tree-optimization/86725
11750 * tree-vect-loop.c (vect_inner_phi_in_double_reduction_p): New
11752 (vect_analyze_scalar_cycles_1): Check it.
11754 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
11756 PR tree-optimization/86725
11757 * tree-vect-loop.c (vect_is_simple_reduction): When treating
11758 an outer loop phi as a double reduction, make sure that the
11759 single user of the phi result is an inner loop phi.
11761 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
11763 * tree-vect-data-refs.c (vect_analyze_group_access_1): Convert
11764 grouped stores with gaps to a strided group.
11766 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
11768 * tree-vect-stmts.c (get_group_load_store_type)
11769 (get_load_store_type): Only test STMT_VINFO_STRIDED_P for the
11770 first statement in a group.
11772 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
11774 * config/darwin.h (LINK_COMMAND_SPEC_A): Sync LTO options with
11775 the sequence used in gcc/gcc.c.
11777 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
11780 * gcc-ar.c (main): Don’t try to invoke the plug-in if we’re not
11783 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
11785 * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Adjust to use the
11786 Darwin10-specific unwinder-shim.
11787 * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Remove.
11788 * config/rs6000/darwin.h (DARWIN_CRT1_SPEC, DARWIN_DYLIB1_SPEC):
11789 New to cater for Darwin10 Rosetta.
11791 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
11793 * config/i386/i386.c (ix86_output_addr_diff_elt): Move the MACH-O
11794 specific test before the one for HAVE_AS_GOTOFF_IN_DATA.
11796 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
11801 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
11802 (dwarf2out_switch_text_section): Generate a local label for the
11803 second function sub-section and apply it as the second FDE start
11805 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
11806 second sub-section start.
11808 2018-08-22 Richard Biener <rguenther@suse.de>
11810 PR tree-optimization/86988
11811 * tree-vrp.c (vrp_prop::check_mem_ref): Bail out on VLAs.
11813 2018-08-22 Richard Biener <rguenther@suse.de>
11815 PR tree-optimization/86945
11816 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
11818 2018-08-22 Alexandre Oliva <oliva@adacore.com>
11820 * config/rs6000/rs6000.c (SMALL_DATA_RELOC, SMALL_DATA_REG): Add
11821 a comment about how uses of r2 for .sdata2 come about.
11823 2018-08-22 Alexandre Oliva <aoliva@redhat.com>
11825 * tree-ssa-reassoc.c (is_reassociable_op): Fix cut&pasto.
11827 2018-08-21 Marek Polacek <polacek@redhat.com>
11829 PR c++/86981, Implement -Wpessimizing-move.
11830 * doc/invoke.texi: Document -Wpessimizing-move.
11832 2018-08-21 Jan Hubicka <jh@suse.cz>
11834 * tree.c (find_decls_types_r): Do not check for redundant typedefs.
11835 * tree.h (is_redundant_typedef): Remove.
11836 * dwarf2out.c (is_redundant_typedef): Turn into static function.
11838 2018-08-21 Jan Hubicka <jh@suse.cz>
11840 * tree.c (free_lang_data_in_decl): Remove types from DECL_CONTEXT
11843 2018-08-21 Tamar Christina <tamar.christina@arm.com>
11845 * expmed.c (extract_low_bits): Reject invalid subregs early.
11847 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
11849 PR middle-end/86121
11850 * tree-ssa-strlen.c (adjust_last_stmt): Avoid folding away undefined
11853 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
11855 * config/vxworks.h: Guard vxworks_asm_out_constructor and
11856 vxworks_asm_out_destructor by !HAVE_INITFINI_ARRAY_SUPPORT
11857 * config/vxworks.c: Likewise.
11859 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
11861 * config/vxworks.c: Set targetm.have_ctors_dtors
11862 if HAVE_INITFINI_ARRAY_SUPPORT.
11863 * config/vxworks.h: Set SUPPORTS_INIT_PRIORITY
11864 if HAVE_INITFINI_ARRAY_SUPPORT.
11866 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
11868 * config/vxworks.h: Add $(WIND_BASE)/target/h/wrn/coreip to
11869 default search path for VxWorks < 7.
11871 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
11873 * gimple-ssa-sprintf.c (decl_constant_value): Remove.
11874 (get_format_string): Refer to c_getstr.
11876 2018-08-21 Tom de Vries <tdevries@suse.de>
11878 * cgraph.h (debuginfo_early_init, debuginfo_init, debuginfo_fini)
11879 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
11880 (debuginfo_early_stop): Declare.
11881 * cgraphunit.c (debuginfo_early_init, debuginfo_init, debuginfo_fini)
11882 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
11883 (debuginfo_early_stop): New function.
11884 (symbol_table::finalize_compilation_unit): Call debuginfo_early_start
11885 and debuginfo_early_stop.
11886 * dwarf2out.c (dwarf2out_finish, dwarf2out_early_finish): Dump dwarf.
11887 * toplev.c (compile_file): Call debuginfo_start and debuginfo_stop.
11888 (general_init): Call debuginfo_early_init.
11889 (finalize): Call debuginfo_fini.
11890 (do_compile): Call debuginfo_init.
11891 * doc/invoke.texi (@gccoptlist): Add -fdump-debug and
11892 -fdump-early-debug.
11893 (@item -fdump-debug, @item -fdump-earlydebug): Add.
11895 2018-08-21 Tom de Vries <tdevries@suse.de>
11897 * dwarf2out.c (print_dw_val, print_loc_descr, print_die): Handle
11898 flag_dump_noaddr and flag_dump_unnumbered.
11900 2018-08-21 Aldy Hernandez <aldyh@redhat.com>
11902 * wide-int-range.cc (wide_int_range_abs): New.
11903 (wide_int_range_order_set): Rename from wide_int_range_min_max.
11904 * wide-int-range.h (wide_int_range_abs): New.
11905 (wide_int_range_min_max): New.
11906 * tree-vrp.c (extract_range_from_unary_expr): Rewrite ABS_EXPR
11907 case to call wide_int_range_abs.
11908 Rewrite MIN/MAX_EXPR to call wide_int_range_min_max.
11909 (extract_range_from_abs_expr): Delete.
11911 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
11914 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
11915 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
11918 2018-08-20 Nathan Sidwell <nathan@acm.org>
11919 Jeff Law <law@redhat.com>
11921 * config/s390/s390-c (s390_macro_to_expand): Use cpp_macro_p.
11922 * config/spu/spu-c.c (spu_macro_to_expand): Likewise.
11924 2018-08-20 David Malcolm <dmalcolm@redhat.com>
11927 * attribs.c (diag_attr_exclusions): Add auto_diagnostic_group instance.
11928 (decl_attributes): Likewise.
11929 * calls.c (maybe_warn_nonstring_arg): Add auto_diagnostic_group
11931 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
11932 * diagnostic-core.h (class auto_diagnostic_group): New class.
11933 * diagnostic.c (diagnostic_initialize): Initialize the new fields.
11934 (diagnostic_report_diagnostic): Handle the first diagnostics within
11936 (emit_diagnostic): Add auto_diagnostic_group instance.
11937 (inform): Likewise.
11938 (inform_n): Likewise.
11939 (warning): Likewise.
11940 (warning_at): Likewise.
11941 (warning_n): Likewise.
11942 (pedwarn): Likewise.
11943 (permerror): Likewise.
11945 (error_n): Likewise.
11946 (error_at): Likewise.
11948 (fatal_error): Likewise.
11949 (internal_error): Likewise.
11950 (internal_error_no_backtrace): Likewise.
11951 (auto_diagnostic_group::auto_diagnostic_group): New ctor.
11952 (auto_diagnostic_group::~auto_diagnostic_group): New dtor.
11953 * diagnostic.h (struct diagnostic_context): Add fields
11954 "diagnostic_group_nesting_depth",
11955 "diagnostic_group_emission_count", "begin_group_cb",
11957 * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior):
11958 Add auto_diagnostic_group instance(s).
11959 (find_explicit_erroneous_behavior): Likewise.
11960 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Likewise.
11961 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Likewise.
11962 * gimplify.c (warn_implicit_fallthrough_r): Likewise.
11963 (gimplify_va_arg_expr): Likewise.
11964 * hsa-gen.c (HSA_SORRY_ATV): Likewise.
11965 (HSA_SORRY_AT): Likewise.
11966 * ipa-devirt.c (compare_virtual_tables): Likewise.
11967 (warn_odr): Likewise.
11968 * multiple_target.c (expand_target_clones): Likewise.
11969 * opts-common.c (cmdline_handle_error): Likewise.
11970 * reginfo.c (globalize_reg): Likewise.
11971 * substring-locations.c (format_warning_n_va): Likewise.
11972 * tree-inline.c (expand_call_inline): Likewise.
11973 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Likewise.
11974 * tree-ssa-loop-niter.c
11975 (do_warn_aggressive_loop_optimizations): Likewise.
11976 * tree-ssa-uninit.c (warn_uninit): Likewise.
11977 * tree.c (warn_deprecated_use): Likewise.
11979 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
11982 * config/i386/i386.md (eh_return): Always update EH return
11983 address in word_mode.
11985 2018-08-20 Chung-Lin Tang <cltang@codesourcery.com>
11987 * targhooks.c (std_gimplify_va_arg_expr): Properly handle case of when
11988 TARGET_SPLIT_COMPLEX_ARG is defined.
11990 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
11992 * expr.c (store_field): Change gcc_assert to gcc_checking_assert.
11994 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
11997 * expr.c (expand_assignment): Assert that bitpos is positive.
11998 (store_field): Likewise
11999 (expand_expr_real_1): Make sure that bitpos is positive.
12000 * config/alpha/alpha.h (CONSTANT_ADDRESS_P): Avoid signed
12003 2018-08-20 Nathan Sidwell <nathan@acm.org>
12005 * Makefile.in (CPP_ID_DATA_H): Delete.
12006 (CPP_INTERNAL_H): Don't add it.
12007 (GTFILES): Replace CPP_ID_DATA_H with CPPLIB_H.
12008 * gengtype.c (open_base_files): Replace cpp-id-data.h with cpplib.h
12010 2018-08-20 Richard Biener <rguenther@suse.de>
12012 PR tree-optimization/78655
12013 * tree-vrp.c (extract_range_from_binary_expr_1): Make
12014 pointer + offset nonnull if either operand is nonnull work.
12016 2018-08-20 Tom de Vries <tdevries@suse.de>
12018 * dwarf2out.c (add_scalar_info): Don't add reference to existing die
12019 unless the referenced die describes the added property using
12020 DW_AT_location or DW_AT_const_value. Fall back to exprloc case.
12021 Otherwise, add a DW_AT_location to the referenced die.
12023 2018-08-19 Uros Bizjak <ubizjak@gmail.com>
12026 * config/i386/i386.c (ix86_rtx_costs) [case SET]: Check source for
12027 register_operand when calling ix86_set_reg_reg_cost.
12028 [case CONST_INT, case CONST, case LABEL_REF, case SYMBOL_REF]:
12029 Set *total to 0 for operands that satisfy x86_64_immediate_operand
12030 predicate and to 1 otherwise.
12032 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
12034 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
12035 emit a diagnostic that it is not supported and reset the option.
12036 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
12037 supported and consume the option. (ASM_FINAL_SPEC): New.
12039 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
12041 * doc/md.texi (Patterns): Use @ref instead of @xref in the middle of
12044 2018-08-17 Sandra Loosemore <sandra@codesourcery.com>
12046 C-SKY port: Documentation
12048 * doc/extend.texi (C-SKY Function Attributes): New section.
12049 * doc/invoke.texi (Option Summary): Add C-SKY options.
12050 (C-SKY Options): New section.
12051 * doc/md.texi (Machine Constraints): Document C-SKY constraints.
12053 2018-08-17 Jojo <jijie_rong@c-sky.com>
12054 Huibin Wang <huibin_wang@c-sky.com>
12055 Sandra Loosemore <sandra@codesourcery.com>
12056 Chung-Lin Tang <cltang@codesourcery.com>
12058 C-SKY port: Backend implementation
12060 * config/csky/*: New.
12061 * common/config/csky/*: New.
12063 2018-08-17 Jojo <jijie_rong@c-sky.com>
12064 Huibin Wang <huibin_wang@c-sky.com>
12065 Sandra Loosemore <sandra@codesourcery.com>
12066 Chung-Lin Tang <cltang@codesourcery.com>
12067 Andrew Jenner <andrew@codesourcery.com>
12069 C-SKY port: Configury
12071 * config.gcc (csky-*-*): New.
12072 * configure.ac: Add csky to targets for dwarf2 debug_line support.
12073 * configure: Regenerated.
12075 2018-08-17 David Malcolm <dmalcolm@redhat.com>
12077 * dump-context.h: Include "dumpfile.h".
12078 (dump_context::dump_printf_va): Convert final param from va_list
12079 to va_list *. Convert from ATTRIBUTE_PRINTF to
12080 ATTRIBUTE_GCC_DUMP_PRINTF.
12081 (dump_context::dump_printf_loc_va): Likewise.
12082 * dumpfile.c: Include "stringpool.h".
12083 (make_item_for_dump_printf_va): Delete.
12084 (make_item_for_dump_printf): Delete.
12085 (class dump_pretty_printer): New class.
12086 (dump_pretty_printer::dump_pretty_printer): New ctor.
12087 (dump_pretty_printer::emit_items): New member function.
12088 (dump_pretty_printer::emit_any_pending_textual_chunks): New member
12090 (dump_pretty_printer::emit_item): New member function.
12091 (dump_pretty_printer::stash_item): New member function.
12092 (dump_pretty_printer::format_decoder_cb): New member function.
12093 (dump_pretty_printer::decode_format): New member function.
12094 (dump_context::dump_printf_va): Reimplement in terms of
12095 dump_pretty_printer.
12096 (dump_context::dump_printf_loc_va): Convert final param from va_list
12098 (dump_context::begin_scope): Reimplement call to
12099 make_item_for_dump_printf.
12100 (dump_printf): Update for change to dump_printf_va.
12101 (dump_printf_loc): Likewise.
12102 (selftest::test_capture_of_dump_calls): Convert "stmt" from
12103 greturn * to gimple *. Add a test_decl. Add tests of dump_printf
12104 with %T, %E, and %G.
12105 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): New macro.
12106 (dump_printf): Replace ATTRIBUTE_PRINTF_2 with
12107 ATTRIBUTE_GCC_DUMP_PRINTF (2, 3).
12108 (dump_printf_loc): Replace ATTRIBUTE_PRINTF_3 with
12109 ATTRIBUTE_GCC_DUMP_PRINTF (3, 0).
12110 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Convert
12111 use of HOST_WIDE_INT_PRINT_DEC on unsigned HOST_WIDE_INT "count"
12112 within a dump_printf_loc call to "%wu".
12113 (vector_alignment_reachable_p): Merge two dump_printf[_loc] calls,
12114 converting a use of HOST_WIDE_INT_PRINT_DEC to "%wd". Add a
12115 missing space after "=".
12116 * tree-vect-loop.c (vect_analyze_loop_2) Within a dump_printf
12117 call, convert use of HOST_WIDE_INT_PRINT_DEC to "%wd".
12118 * tree-vect-slp.c (vect_slp_bb): Within a dump_printf_loc call,
12119 convert use of HOST_WIDE_INT_PRINT_UNSIGNED to "%wu".
12120 * tree-vectorizer.c (try_vectorize_loop_1): Likewise. Remove
12121 duplicate "vectorized" from message.
12123 2018-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
12125 * config/arm/arm-builtins.c (arm_init_simd_builtin_types): Clear
12126 polyNxK_t element's TYPE_STRING_FLAG.
12128 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
12130 * config/rs6000/rs6000.md (*cbranch, *creturn): Name these patterns
12131 (they were unnamed before). Fix comments.
12133 2018-08-17 Nathan Sidwell <nathan@acm.org>
12135 * cppbuiltin.c: Include "cpplib.h", not "cpp-id-data.h".
12137 2018-08-17 Richard Biener <rguenther@suse.de>
12139 PR tree-optimization/86841
12140 * wide-int-range.cc (wide_int_range_lshift): Use to_uhwi.
12142 2018-08-17 Martin Liska <mliska@suse.cz>
12144 * common.opt: Remove Warn, Init and Report for options with
12145 Ignore/Deprecated flag. Warning is done automatically for
12147 * config/i386/i386.opt: Likewise.
12148 * config/ia64/ia64.opt: Likewise.
12149 * config/rs6000/rs6000.opt: Likewise.
12150 * cppbuiltin.c (define_builtin_macros_for_compilation_flags):
12151 Remove usage of flag_check_pointer_bounds.
12152 * lto-wrapper.c (merge_and_complain): Do not handle
12153 OPT_fcheck_pointer_bounds.
12154 (append_compiler_options): Likewise.
12155 * opt-functions.awk: Do not handle Deprecated.
12156 * optc-gen.awk: Check that Var, Report and Init are not
12157 used for an option with Ignore/Deprecated flag.
12158 * opts-common.c (decode_cmdline_option): Do not report
12160 (read_cmdline_option): Report warning for OPT_SPECIAL_deprecated
12162 * opts.h (struct cl_option): Remove cl_deprecated flag.
12163 (CL_ERR_DEPRECATED): Remove error enum value.
12165 2018-08-17 Richard Biener <rguenther@suse.de>
12167 PR middle-end/86505
12168 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
12169 across a va-arg-pack using call adjust its return value accordingly.
12171 2018-08-16 Martin Sebor <msebor@redhat.com>
12173 PR tree-optimization/86853
12174 * gimple-ssa-sprintf.c (struct format_result): Rename member.
12175 (struct fmtresult): Add member and initialize it in ctors.
12176 (format_character): Handle %C. Extend range to NUL. Set MAYFAIL.
12177 (format_string): Handle %S the same as %ls. Set MAYFAIL.
12178 (format_directive): Set POSUNDER4K when MAYFAIL is set.
12179 (parse_directive): Handle %C same as %c.
12180 (sprintf_dom_walker::compute_format_length): Adjust.
12181 (is_call_safe): Adjust.
12183 2018-08-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
12185 * builtins.c (c_strlen): Add new parameter eltsize. Use it
12186 for determining how to count the elements.
12187 * builtins.h (c_strlen): Adjust prototype.
12188 * expr.c (string_constant): Add new parameter mem_size.
12189 Set *mem_size appropriately.
12190 * expr.h (string_constant): Adjust protoype.
12191 * gimple-fold.c (get_range_strlen): Add new parameter eltsize.
12192 * gimple-fold.h (get_range_strlen): Adjust prototype.
12193 * gimple-ssa-sprintf.c (get_string_length): Add new parameter eltsize.
12194 (format_string): Call get_string_length with eltsize.
12196 2018-08-16 David Malcolm <dmalcolm@redhat.com>
12198 * diagnostic.c (default_diagnostic_start_span_fn): Call pp_string
12199 to emit the span, rather than setting it as the prefix.
12201 2018-08-16 David Malcolm <dmalcolm@redhat.com>
12203 * diagnostic-show-locus.c (layout::start_annotation_line): Add
12204 "margin_char" parameter, defaulting to space. Use it in place
12205 of pp_space for the initial part of the margin.
12206 (layout::print_leading_fixits): Use '+' when filling the margin
12207 of line-insertion fix-it hints.
12209 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12211 * config/rs6000/rs6000.md (two unnamed define_insn and define_split):
12214 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12216 * config/rs6000/altivec.md: Don't set length attribute to the default
12218 * config/rs6000/darwin.md: Ditto.
12219 * config/rs6000/dfp.md: Ditto.
12220 * config/rs6000/htm.md: Ditto.
12221 * config/rs6000/rs6000.md: Ditto.
12222 * config/rs6000/sync.md: Ditto.
12223 * config/rs6000/vsx.md: Ditto.
12225 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12227 * config/rs6000/altivec.md: Don't set length attribute to the default
12228 value, for branch instructions.
12229 * config/rs6000/darwin.md: Ditto.
12230 * config/rs6000/rs6000.md: Ditto.
12232 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12234 * config/rs6000/rs6000.md (length): Always define as const_int 4.
12235 (unnamed conditional branch define_insn): Set length to 4 or 8
12236 depending on offset.
12237 (<bd>_<mode>): Similar, for alternative 0.
12238 (<bd>tf_<mode>): Ditto.
12240 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12242 * expr.c (copy_blkmode_to_reg): Perform larger copies when safe.
12244 2018-08-16 Matthew Malcomson <matthew.malcomson@arm.com>
12246 * doc/rtl.texi: Replace old RTX class names with new names.
12249 2018-08-16 Vlad Lazar <vlad.lazar@arm.com>
12251 * expmed.h (canonicalize_comparison): New declaration.
12252 * expmed.c (canonicalize_comparison, equivalent_cmp_code): New function.
12253 * expmed.c (emit_store_flag_1): Add call to canonicalize_comparison.
12254 * optabs.c (prepare_cmp_insn): Likewise.
12255 * rtl.h (unsigned_condition_p): New function which checks if a
12256 comparison operator is unsigned.
12258 2018-08-16 Nathan Sidwell <nathan@acm.org>
12260 * config/rs6000/rs6000-c.c (rs6000_macro_to_expend): Use cpp_macro_p.
12261 * config/powerpcspc/powerpcspe-c.c (rs6000_macro_to_expend): Likewise.
12263 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12266 * config/arm/arm.c (arm_can_change_mode_class): Disallow subreg.
12267 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
12268 (mov<mov>): ..this and enable unconditionally.
12270 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12272 * config/arm/neon.md (*neon_mov<mode>): Remove reg-to-reg alternative.
12274 2018-08-16 Sam Tebbs <sam.tebbs@arm.com>
12276 * config/aarch64/aarch64.opt (mlow-precision-recip-sqrt)
12277 (mlow-precision-sqrt, mlow-precision-div, mverbose-cost-dump): Replace
12278 "Common" with "Target".
12280 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
12282 * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
12283 * doc/invoke.texi (mmitigate-rop): Remove.
12284 * config/i386/i386.c: Do not include "regrename.h".
12285 (ix86_rop_should_change_byte_p, reg_encoded_number)
12286 (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
12288 (ix86_reorg): Remove call to ix86_mitigate_rop.
12289 * config/i386/i386.md (attr "modrm_class"): Remove.
12290 (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor)
12291 (x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
12292 (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
12294 2018-08-15 Will Schmidt <will_schmidt@vnet.ibm.com>
12296 * config/rs6000/rs600.c (rs6000_gimple_fold_builtin): Add entries to
12297 allow folding of mergeh() and mergel() for the float and double types.
12298 (fold_mergehl_helper): Rework to handle building a permute tree
12301 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
12303 * config/i386/i386.c (expand_vec_perm_movs): Enable V4SFmode
12306 2018-08-15 David Malcolm <dmalcolm@redhat.com>
12308 * common.opt (fdiagnostics-show-labels): New option.
12309 * diagnostic-show-locus.c (class layout_range): Add field
12311 (class layout): Add field "m_show_labels_p".
12312 (layout_range::layout_range): Add param "label" and use it to
12313 initialize m_label.
12314 (make_range): Pass in NULL for new "label" param of layout_range's
12316 (layout::layout): Initialize m_show_labels_p.
12317 (layout::maybe_add_location_range): Pass in loc_range->m_label
12318 when constructing layout_range instances.
12319 (struct line_label): New struct.
12320 (layout::print_any_labels): New member function.
12321 (layout::print_line): Call it if label-printing is enabled.
12322 (selftest::test_one_liner_labels): New test.
12323 (selftest::test_diagnostic_show_locus_one_liner): Call it.
12324 * diagnostic.c (diagnostic_initialize): Initialize
12325 context->show_labels_p.
12326 * diagnostic.h (struct diagnostic_context): Add field
12328 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
12329 -fno-diagnostics-show-labels.
12330 * dwarf2out.c (gen_producer_string): Add
12331 OPT_fdiagnostics_show_labels to the ignored options.
12332 * gcc-rich-location.c (gcc_rich_location::add_expr): Add "label"
12334 (gcc_rich_location::maybe_add_expr): Likewise.
12335 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location): Add
12336 label" param, defaulting to NULL.
12337 (gcc_rich_location::add_expr): Add "label" param.
12338 (gcc_rich_location::maybe_add_expr): Likewise.
12339 (class text_range_label): New class.
12340 (class range_label_for_type_mismatch): New class.
12341 * gimple-ssa-sprintf.c (fmtwarn): Pass NULL for new label params
12342 of format_warning_va.
12343 (fmtwarn_n): Likewise for new params of format_warning_n_va.
12344 * lto-wrapper.c (merge_and_complain): Add
12345 OPT_fdiagnostics_show_labels to the "pick one setting" options.
12346 (append_compiler_options): Likewise to the dropped options.
12347 (append_diag_options): Likewise to the passed-on options.
12348 * opts.c (common_handle_option): Handle the new option.
12349 * selftest-diagnostic.c
12350 (test_diagnostic_context::test_diagnostic_context): Enable
12352 * substring-locations.c: Include "gcc-rich-location.h".
12353 (format_warning_n_va): Add "fmt_label" and "param_label" params
12354 and use them as appropriate.
12355 (format_warning_va): Add "fmt_label" and "param_label" params,
12356 passing them on to format_warning_n_va.
12357 (format_warning_at_substring): Likewise.
12358 (format_warning_at_substring_n): Likewise.
12359 * substring-locations.h (format_warning_va): Add "fmt_label" and
12360 "param_label" params.
12361 (format_warning_n_va): Likewise.
12362 (format_warning_at_substring): Likewise.
12363 (format_warning_at_substring_n): Likewise.
12364 * toplev.c (general_init): Initialize global_dc->show_labels_p.
12366 2018-08-15 Qing Zhao <qing.zhao@oracle.com>
12369 * builtins.c (expand_builtin_memcmp): Do not expand the call
12370 when overflow is detected.
12372 2018-08-15 Martin Sebor <msebor@redhat.com>
12374 PR tree-optimization/71625
12375 * config/aarch64/aarch64-builtins.c
12376 (aarch64_init_simd_builtin_types): Clear Poly8_t's TYPE_STRING_FLAG.
12378 2018-08-15 Ilya Leoshkevich <iii@linux.ibm.com>
12380 * config/s390/s390.c (s390_reorg): Remove loop.
12382 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
12385 (darwin_function_switched_text_sections): Delete.
12386 * gcc/config/darwin.h
12387 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
12389 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
12392 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
12393 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
12394 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
12396 2018-08-15 Martin Liska <mliska@suse.cz>
12398 PR tree-optimization/86925
12399 * predict.c (expr_expected_value_1): When taking
12400 later predictor, assign also probability.
12401 Use fold_build2_initializer_loc in order to fold
12402 the expression in -frounding-math.
12404 2018-08-14 Allan Sandfeld Jensen <allan.jensen@qt.io>
12406 * config/i386/i386.c (expand_vec_perm_movs): New method matching movs
12408 (expand_vec_perm_1): Try the new method.
12410 2018-08-14 Ilya Leoshkevich <iii@linux.ibm.com>
12413 * lra-lives.c (remove_some_program_points_and_update_live_ranges):
12414 Check whether lra_live_max_point is 0 before dividing.
12416 2018-08-14 Martin Sebor <msebor@redhat.com>
12418 PR tree-optimization/86650
12419 * tree-vrp.c (vrp_prop::check_array_ref): Print an inform message.
12420 (vrp_prop::check_mem_ref): Same.
12422 2018-08-13 Liu Hao <lh_mouse@126.com>
12424 * pretty-print.c (eat_esc_sequence): Swap the foreground and
12425 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
12426 and clear it thereafter, as it only works for DBCS.
12428 2018-08-13 Liu Hao <lh_mouse@126.com>
12430 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
12431 handle returned by _get_osf_handle().
12433 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
12435 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support
12436 for folding vec_perm.
12438 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
12440 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin):
12441 Add support for gimple-folding of vec_pack() and vec_unpack()
12444 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
12446 * config/rs6000/rs6000.c (rs6000_builtin_valid_without_lhs): Add
12447 vec_xst variants to the list.
12448 (rs6000_gimple_fold_builtin): Add support for folding unaligned
12449 vector loads and stores.
12451 2018-08-13 David Edelsohn <dje.gcc@gmail.com>
12453 * config.gcc (rs6000-ibm-aix4.x): Delete.
12454 (rs6000-ibm-aix5.1): Delete.
12455 (rs6000-ibm-aix5.2): Delete.
12456 (rs6000-ibm-aix5.3): Delete.
12457 * config/rs6000/aix43.h: Delete.
12458 * config/rs6000/aix51.h: Delete.
12459 * config/rs6000/aix52.h: Delete.
12460 * config/rs6000/t-aix43: Delete.
12462 2018-08-13 Ilya Leoshkevich <iii@linux.ibm.com>
12464 * config/s390/s390.c (s390_decompose_constant_pool_ref):
12466 (s390_decompose_address): Factor out constant pool ref
12469 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
12471 * config/nds32/nds32-predicates.c
12472 (nds32_can_use_bclr_p): Change return type as bool.
12473 (nds32_can_use_bset_p): Ditto.
12474 (nds32_can_use_btgl_p): Ditto.
12475 (nds32_can_use_bitci_p): Ditto.
12476 * config/nds32/nds32-protos.h
12477 (nds32_can_use_bclr_p): Change declaration.
12478 (nds32_can_use_bset_p): Ditto.
12479 (nds32_can_use_btgl_p): Ditto.
12480 (nds32_can_use_bitci_p): Ditto.
12482 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
12484 * config/nds32/nds32.c (nds32_expand_prologue, nds32_expand_epilogue):
12485 Support -msched-prolog-epilog option.
12486 * config/nds32/nds32.opt (msched-prolog-epilog): New option.
12488 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
12490 * common/config/nds32/nds32-common.c
12491 (nds32_option_optimization_table): Enalbe -malways-align.
12493 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
12495 * config.gcc (nds32*): Add nds32_isr.h and nds32_init.inc in
12497 * common/config/nds32/nds32-common.c (nds32_handle_option): Handle
12498 OPT_misr_secure_ case.
12499 * config/nds32/nds32-isr.c: Implementation of backward compatibility.
12500 * config/nds32/nds32-protos.h (nds32_isr_function_critical_p): New.
12501 * config/nds32/nds32.c (nds32_attribute_table): Add critical and
12503 * config/nds32/nds32.h (nds32_isr_nested_type): Add NDS32_CRITICAL.
12504 (nds32_isr_info): New field security_level.
12505 (TARGET_ISR_VECTOR_SIZE_4_BYTE): New macro.
12506 * config/nds32/nds32.md (return_internal): Consider critical attribute.
12507 * config/nds32/nds32.opt (misr-secure): New option.
12508 * config/nds32/nds32_init.inc: New file.
12509 * config/nds32/nds32_isr.h: New file.
12511 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
12513 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
12514 Update comment for atomic instructions.
12515 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
12516 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
12518 (atomic_loaddi): Revise fence expansion to only emit fence prior to
12519 load for __ATOMIC_SEQ_CST model.
12520 (atomic_loaddi_1): Remove float register target.
12521 (atomic_storedi): Handle CONST_INT values.
12522 (atomic_storedi_1): Remove float register source. Add special case
12524 (memory_barrier): New expander and insn.
12526 2018-08-11 Jakub Jelinek <jakub@redhat.com>
12528 PR tree-optimization/86835
12529 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
12530 new_stmt after def_gsi, make sure to insert new_square_stmt after
12531 that stmt, not 2 stmts before it.
12533 2018-08-10 Alexander Monakov <amonakov@ispras.ru>
12536 * config/i386/i386.md (<s>mul<mode>3_highpart): Use DWIH mode iterator
12539 2018-08-10 Martin Liska <mliska@suse.cz>
12542 * builtin-types.def (BT_FN_LONG_LONG_LONG_DOUBLE): Add new
12544 * builtins.c (expand_builtin_expect_with_probability):
12546 (expand_builtin_expect_with_probability): New function.
12547 (build_builtin_expect_predicate): Add new argumnet probability
12548 for BUILT_IN_EXPECT_WITH_PROBABILITY.
12549 (fold_builtin_expect):
12552 * builtins.def (BUILT_IN_EXPECT_WITH_PROBABILITY):
12553 * builtins.h (fold_builtin_expect): Set new argument.
12554 * doc/extend.texi: Document __builtin_expect_with_probability.
12555 * doc/invoke.texi: Likewise.
12556 * gimple-fold.c (gimple_fold_call): Pass new argument.
12557 * ipa-fnsummary.c (find_foldable_builtin_expect): Handle
12558 also BUILT_IN_EXPECT_WITH_PROBABILITY.
12559 * predict.c (get_predictor_value): New function.
12560 (expr_expected_value): Add new argument probability. Assume
12561 that predictor and probability are always non-null.
12562 (expr_expected_value_1): Likewise. For __builtin_expect and
12563 __builtin_expect_with_probability set probability. Handle
12564 combination in binary expressions.
12565 (tree_predict_by_opcode): Simplify code by simply calling
12566 get_predictor_value.
12567 (pass_strip_predict_hints::execute): Add handling of
12568 BUILT_IN_EXPECT_WITH_PROBABILITY.
12569 * predict.def (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Add
12571 * tree.h (DECL_BUILT_IN_P): New function.
12573 2018-08-10 Martin Liska <mliska@suse.cz>
12575 PR tree-optimization/85799
12576 * passes.def: Add argument for pass_strip_predict_hints.
12577 * predict.c (class pass_strip_predict_hints): Add new argument
12579 (strip_predictor_early): New function.
12580 (pass_strip_predict_hints::execute): Call the function to
12582 (strip_predict_hints): New function.
12583 * predict.def: Fix comment.
12585 2018-08-10 Thomas Preud'homme <thomas.preudhomme@linaro.org>
12587 * Makefile.in: Clarify which tm.texi to copy over to assert the
12588 right to grant a GFDL license for all.
12590 2018-08-09 Jeff Law <law@redhat.com>
12592 * config/m68k/m68k.c (m68k_adjust_decorated_operand): Remove
12595 2018-08-09 Andreas Schwab <schwab@linux-m68k.org>
12597 * config/m68k/m68k-protos.h (m68k_final_prescan_insn): Remove
12600 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
12602 * tree-vect-loop.c (vectorizable_reduction): Allow inner-loop
12603 reductions for variable-length vectors.
12605 2018-08-09 David Malcolm <dmalcolm@redhat.com>
12608 * common.opt (fdiagnostics-show-line-numbers): New option.
12609 * diagnostic-show-locus.c (class layout): Add fields
12610 "m_show_line_numbers_p" and "m_linenum_width";
12611 (num_digits): New function.
12612 (test_num_digits): New function.
12613 (layout::layout): Initialize new fields. Update m_x_offset
12614 logic to handle any left margin.
12615 (layout::print_source_line): Print line number when requested.
12616 (layout::start_annotation_line): New member function.
12617 (layout::print_annotation_line): Call it.
12618 (layout::print_leading_fixits): Likewise.
12619 (layout::print_trailing_fixits): Likewise. Update calls to
12620 move_to_column for new parameter.
12621 (layout::get_x_bound_for_row): Add "add_left_margin" param and use
12622 it to potentially call start_annotation_line.
12623 (layout::show_ruler): Call start_annotation_line.
12624 (selftest::test_line_numbers_multiline_range): New selftest.
12625 (selftest::diagnostic_show_locus_c_tests): Call test_num_digits
12626 and selftest::test_line_numbers_multiline_range.
12627 * diagnostic.c (diagnostic_initialize): Initialize
12628 show_line_numbers_p.
12629 * diagnostic.h (struct diagnostic_context): Add field
12630 "show_line_numbers_p".
12631 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
12632 -fno-diagnostics-show-line-numbers.
12633 * dwarf2out.c (gen_producer_string): Add
12634 OPT_fdiagnostics_show_line_numbers to the ignored options.
12635 * lto-wrapper.c (merge_and_complain): Likewise to the "pick
12636 one setting" options.
12637 (append_compiler_options): Likewise to the dropped options.
12638 (append_diag_options): Likewise to the passed-on options.
12639 * opts.c (common_handle_option): Handle the new option.
12640 * toplev.c (general_init): Set up global_dc->show_line_numbers_p.
12642 2018-08-09 Kelvin Nilsen <kelvin@gcc.gnu.org>
12644 * doc/extend.texi (PowerPC AltiVec Built-in Functions Available on
12645 ISA 2.07): Correct spelling of bcdsub to be __builtin_bcdsub. Add
12646 third argument of type "const signed char" to descriptions of
12647 __builtin_bcdadd, __builtin_bcdadd_lt, __builtin_bcdadd_eq,
12648 __builtin_bcdadd_gt, __builtin_bcdadd_ov, __builtin_bcdsub,
12649 __builtin_bcdsub_lt, __builtin_bcdsub_eq, __builtin_bcdsub_gt,
12650 __builtin_bcdsub_ov functions.
12652 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
12654 PR tree-optimization/86858
12655 * tree-vect-loop.c (vect_is_simple_reduction): Restore
12656 flow_bb_inside_loop_p calls.
12658 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
12660 PR tree-optimization/86871
12661 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
12662 instead of gimple_assign_lhs.
12664 2018-08-09 Richard Earnshaw <rearnsha@arm.com>
12667 * config/aarch64/aarch64.md (add<mode>3_carryinC_zero): Add missing
12668 register constraint to operand 0.
12669 (add<mode>3_carryinC): Likewise.
12670 (add<mode>3_carryinV_zero, add<mode>3_carryinV): Likewise.
12672 2018-08-09 Martin Liska <mliska@suse.cz>
12675 * common.opt: Remove extra line.
12677 2018-08-09 Martin Liska <mliska@suse.cz>
12679 * params.def (PARAM_ALIGN_LOOP_ITERATIONS): Remove double dots
12680 at the end of a line, make first letter capital and end up
12681 a sentence with a dot.
12682 (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): Likewise.
12683 (PARAM_LOOP_BLOCK_TILE_SIZE): Likewise.
12684 (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Likewise.
12685 (PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP): Likewise.
12686 (PARAM_MAX_ISL_OPERATIONS): Likewise.
12687 (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): Likewise.
12688 (PARAM_PROFILE_FUNC_INTERNAL_ID): Likewise.
12689 (PARAM_INDIR_CALL_TOPN_PROFILE): Likewise.
12690 (PARAM_SLP_MAX_INSNS_IN_BB): Likewise.
12691 (PARAM_IPA_CP_EVAL_THRESHOLD): Likewise.
12692 (PARAM_IPA_CP_RECURSION_PENALTY): Likewise.
12693 (PARAM_IPA_CP_SINGLE_CALL_PENALTY): Likewise.
12694 (PARAM_IPA_CP_LOOP_HINT_BONUS): Likewise.
12695 (PARAM_IPA_CP_ARRAY_INDEX_HINT_BONUS): Likewise.
12696 (PARAM_TREE_REASSOC_WIDTH): Likewise.
12697 (PARAM_HSA_GEN_DEBUG_STORES): Likewise.
12698 (PARAM_MAX_SPECULATIVE_DEVIRT_MAYDEFS): Likewise.
12699 (PARAM_MAX_VRP_SWITCH_ASSERTIONS): Likewise.
12701 2018-08-09 Andreas Krebbel <krebbel@linux.ibm.com>
12704 * config/s390/s390.c (s390_option_override_internal): Reduce the
12705 stack-clash-protection-probe-interval param if it would be too big
12708 2018-08-08 Andreas Schwab <schwab@linux-m68k.org>
12711 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Don't define.
12712 * config/m68k/m68k.c (handle_move_double): Don't call
12713 m68k_final_prescan_insn.
12714 (m68k_adjust_decorated_operand): Renamed from
12715 m68k_final_prescan_insn, remove first and third operand and
12717 (print_operand): Call it.
12718 (print_operand_address): Call it.
12720 2018-08-08 Nathan Sidwell <nathan@acm.org>
12722 * diagnostic.c (diagnostic_report_current_module): Use
12723 linemap_included_from & linemap_included_from_linemap.
12725 2018-08-08 Hongbo Zhang <hongbo.zhang@linaro.org>
12727 * config/aarch64/aarch64-cores.def: Add phecda core.
12728 * config/aarch64/aarch64-tune.md: Regenerate.
12729 * doc/invoke.texi: Add phecda core.
12731 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
12734 * config/s390/constraints.md ("NxHD0", "NxSD0"): New constraint
12736 * config/s390/s390.md ("movti"): Add more alternatives for
12737 constant to GPR copies.
12739 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
12741 * config/s390/s390.c: Fix whitespace damage throughout the file.
12742 * config/s390/s390.h: Likewise.
12743 * config/s390/tpf.h: Likewise.
12745 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
12747 * config/s390/s390.c (s390_loadrelative_operand_p):
12748 Remove TARGET_CPU_ZARCH usages.
12749 (s390_rtx_costs): Likewise.
12750 (s390_legitimate_constant_p): Likewise.
12751 (s390_cannot_force_const_mem): Likewise.
12752 (legitimate_reload_constant_p): Likewise.
12753 (s390_preferred_reload_class): Likewise.
12754 (legitimize_pic_address): Likewise.
12755 (legitimize_tls_address): Likewise.
12756 (s390_split_branches): Removed.
12757 (s390_add_execute): Removed.
12758 (s390_dump_pool): Remove TARGET_CPU_ZARCH usages.
12759 (s390_mainpool_start): Likewise.
12760 (s390_mainpool_finish): Likewise.
12761 (s390_mainpool_cancel): Removed.
12762 (s390_chunkify_start): Remove TARGET_CPU_ZARCH usages.
12763 (s390_chunkify_cancel): Likewise.
12764 (s390_return_addr_rtx): Likewise.
12765 (s390_register_info): Remove split_branches_pending_p uages.
12766 (s390_optimize_register_info): Likewise.
12767 (s390_init_frame_layout): Remove TARGET_CPU_ZARCH and
12768 split_branches_pending_p usages.
12769 (s390_can_eliminate): Remove TARGET_CPU_ZARCH usages.
12770 (s390_load_got): Likewise.
12771 (s390_expand_split_stack_prologue): Likewise.
12772 (output_asm_nops): Likewise.
12773 (s390_function_profiler): Likewise.
12774 (s390_emit_call): Likewise.
12775 (s390_conditional_register_usage): Likewise.
12776 (s390_optimize_prologue): Likewise.
12777 (s390_reorg): Remove TARGET_CPU_ZARCH and
12778 split_branches_pending_p usages.
12779 (s390_option_override_internal): Remove TARGET_CPU_ZARCH
12781 (s390_output_indirect_thunk_function): Likewise.
12782 * config/s390/s390.h (TARGET_CPU_ZARCH): Removed.
12783 (TARGET_CPU_ZARCH_P): Removed.
12784 (struct machine_function): Remove split_branches_pending_p.
12785 * config/s390/s390.md: Remove TARGET_CPU_ZARCH usages.
12787 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
12789 * common/config/s390/s390-common.c (processor_flags_table):
12791 * config.gcc: Remove with_arch/with_tune support.
12792 * config/s390/2064.md: Remove cpu attribute comparisons.
12793 * config/s390/driver-native.c (s390_host_detect_local_cpu):
12795 * config/s390/linux.h (ASM_SPEC):
12796 Remove -march support.
12797 * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal):
12798 Use a table to get an arch level.
12799 * config/s390/s390-opts.h (enum processor_type):
12800 Remove enum values.
12801 * config/s390/s390.c
12802 (processor_table): Remove entries, add arch_level values.
12803 (s390_issue_rate): Remove cases.
12804 (s390_option_override): Adjust
12805 s390_option_override_internal() call.
12806 (s390_option_override_internal): Remove deprecation warning.
12807 (s390_valid_target_attribute_tree): Adjust
12808 s390_option_override_internal() call.
12809 * config/s390/s390.h (struct s390_processor):
12810 Share with s390-c.c, add arch_level field.
12811 * config/s390/s390.md:
12812 Remove occurrences in cpu attribute.
12813 * config/s390/s390.opt: Remove -march/-mtune support.
12814 * config/s390/tpf.h (ASM_SPEC): Remove -march support.
12815 * doc/invoke.texi: Remove deprecation warning.
12817 2018-08-08 Luis Machado <luis.machado@linaro.org>
12819 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static
12821 (qdf24xx_tunings): Set vector cost structure to
12822 qdf24xx_vector_cost.
12824 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
12825 <register_sextend>: Set to 3.
12827 2018-08-07 Richard Sandiford <richard.sandiford@arm.com>
12830 * config/aarch64/iterators.md (FRECP, frecp_suffix): Delete.
12831 * config/aarch64/aarch64-simd.md
12832 (aarch64_frecp<FRECP:frecp_suffix><mode>): Fold FRECPE into...
12833 (@aarch64_frecpe<mode>): ...here and the move FRECPX to...
12834 (aarch64_frecpx<mode>): ...this new pattern.
12835 * config/aarch64/aarch64-simd-builtins.def: Remove comment
12836 about aarch64_frecp<FRECP:frecp_suffix><mode>.
12838 2018-08-07 Martin Liska <mliska@suse.cz>
12840 PR middle-end/83023
12841 * predict.c (expr_expected_value_1): Handle DECL_IS_MALLOC,
12842 BUILT_IN_REALLOC and DECL_IS_OPERATOR_NEW.
12843 * predict.def (PRED_MALLOC_NONNULL): New predictor.
12844 * doc/extend.texi: Document that malloc attribute adds
12847 2018-08-06 John David Anglin <danglin@gcc.gnu.org>
12850 * config/pa/pa.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
12851 Define to speculation_safe_value_not_needed.
12853 2018-08-06 Jeff Law <law@redhat.com>
12855 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Pass down
12856 the vr_values instance to cprop_into_stmt.
12857 (cprop_into_stmt): Pass vr_values instance down to cprop_operand.
12858 (cprop_operand): Also query EVRP to determine if OP is a constant.
12860 2018-08-06 Nathan Sidwell <nathan@acm.org>
12862 * diagnostic.c (diagnostic_report_current_module): Reroll
12863 included-at loop. Translate text.
12865 2018-08-06 David Malcolm <dmalcolm@redhat.com>
12867 * function-tests.c (selftest::test_expansion_to_rtl): Call
12868 free_after_compilation.
12870 2018-08-06 Alan Hayward <alan.hayward@arm.com>
12872 * config/aarch64/aarch64.md: Add clobber highs to tls_desc.
12874 2018-08-06 Andreas Krebbel <krebbel@linux.ibm.com>
12876 * config/s390/s390.c (s390_loop_unroll_adjust): Prevent small
12877 loops with memory block operations from getting unrolled.
12879 2018-08-06 Ulrich Weigand <uweigand@de.ibm.com>
12882 * config/spu/spu.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
12883 Define to speculation_safe_value_not_needed.
12885 2018-08-06 Jeff Law <law@redhat.com>
12887 * reload1.c (forget_old_reloads_1): Adjust CLOBBER_HIGH
12890 2018-08-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
12893 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
12894 with all enabled __intN types.
12896 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
12898 2018-08-06 Alan Hayward <alan.hayward@arm.com>
12900 * alias.c (record_set): Check for clobber high.
12901 * cfgexpand.c (expand_gimple_stmt): Likewise.
12902 * combine-stack-adj.c (single_set_for_csa): Likewise.
12903 * combine.c (find_single_use_1): Likewise.
12904 (set_nonzero_bits_and_sign_copies): Likewise.
12905 (get_combine_src_dest): Likewise.
12906 (is_parallel_of_n_reg_sets): Likewise.
12907 (try_combine): Likewise.
12908 (record_dead_and_set_regs_1): Likewise.
12909 (reg_dead_at_p_1): Likewise.
12910 (reg_dead_at_p): Likewise.
12911 * dce.c (deletable_insn_p): Likewise.
12912 (mark_nonreg_stores_1): Likewise.
12913 (mark_nonreg_stores_2): Likewise.
12914 * df-scan.c (df_find_hard_reg_defs): Likewise.
12915 (df_uses_record): Likewise.
12916 (df_get_call_refs): Likewise.
12917 * dwarf2out.c (mem_loc_descriptor): Likewise.
12918 * haifa-sched.c (haifa_classify_rtx): Likewise.
12919 * ira-build.c (create_insn_allocnos): Likewise.
12920 * ira-costs.c (scan_one_insn): Likewise.
12921 * ira.c (equiv_init_movable_p): Likewise.
12922 (rtx_moveable_p): Likewise.
12923 (interesting_dest_for_shprep): Likewise.
12924 * jump.c (mark_jump_label_1): Likewise.
12925 * postreload-gcse.c (record_opr_changes): Likewise.
12926 * postreload.c (reload_cse_simplify): Likewise.
12927 (struct reg_use): Add source expr.
12928 (reload_combine): Check for clobber high.
12929 (reload_combine_note_use): Likewise.
12930 (reload_cse_move2add): Likewise.
12931 (move2add_note_store): Likewise.
12932 * print-rtl.c (print_pattern): Likewise.
12933 * recog.c (decode_asm_operands): Likewise.
12934 (store_data_bypass_p): Likewise.
12935 (if_test_bypass_p): Likewise.
12936 * regcprop.c (kill_clobbered_value): Likewise.
12937 (kill_set_value): Likewise.
12938 * reginfo.c (reg_scan_mark_refs): Likewise.
12939 * reload1.c (maybe_fix_stack_asms): Likewise.
12940 (eliminate_regs_1): Likewise.
12941 (elimination_effects): Likewise.
12942 (mark_not_eliminable): Likewise.
12943 (scan_paradoxical_subregs): Likewise.
12944 (forget_old_reloads_1): Likewise.
12945 * reorg.c (find_end_label): Likewise.
12946 (try_merge_delay_insns): Likewise.
12947 (redundant_insn): Likewise.
12948 (own_thread_p): Likewise.
12949 (fill_simple_delay_slots): Likewise.
12950 (fill_slots_from_thread): Likewise.
12951 (dbr_schedule): Likewise.
12952 * resource.c (update_live_status): Likewise.
12953 (mark_referenced_resources): Likewise.
12954 (mark_set_resources): Likewise.
12955 * rtl.c (copy_rtx): Likewise.
12956 * rtlanal.c (reg_referenced_p): Likewise.
12957 (single_set_2): Likewise.
12958 (noop_move_p): Likewise.
12959 (note_stores): Likewise.
12960 * sched-deps.c (sched_analyze_reg): Likewise.
12961 (sched_analyze_insn): Likewise.
12963 2018-08-06 Alan Hayward <alan.hayward@arm.com>
12965 * cse.c (invalidate_reg): New function extracted from...
12966 (invalidate): ...here.
12967 (canonicalize_insn): Check for clobber high.
12968 (invalidate_from_clobbers): invalidate clobber highs.
12969 (invalidate_from_sets_and_clobbers): Likewise.
12970 (count_reg_usage): Check for clobber high.
12971 (insn_live_p): Likewise.
12972 * cselib.c (cselib_expand_value_rtx_1):Likewise.
12973 (cselib_invalidate_regno): Check for clobber in setter.
12974 (cselib_invalidate_rtx): Pass through setter.
12975 (cselib_invalidate_rtx_note_stores):
12976 (cselib_process_insn): Check for clobber high.
12977 * cselib.h (cselib_invalidate_rtx): Add operand.
12979 2018-08-06 Alan Hayward <alan.hayward@arm.com>
12981 * lra-eliminations.c (lra_eliminate_regs_1): Check for clobber high.
12982 (mark_not_eliminable): Likewise.
12983 * lra-int.h (struct lra_insn_reg): Add clobber high marker.
12984 * lra-lives.c (process_bb_lives): Check for clobber high.
12985 * lra.c (new_insn_reg): Remember clobber highs.
12986 (collect_non_operand_hard_regs): Check for clobber high.
12987 (lra_set_insn_recog_data): Likewise.
12988 (add_regs_to_insn_regno_info): Likewise.
12989 (lra_update_insn_regno_info): Likewise.
12991 2018-08-06 Alan Hayward <alan.hayward@arm.com>
12993 * rtl.h (reg_is_clobbered_by_clobber_high): Add declarations.
12994 * rtlanal.c (reg_is_clobbered_by_clobber_high): Add function.
12996 2018-08-06 Alan Hayward <alan.hayward@arm.com>
12998 * emit-rtl.c (verify_rtx_sharing): Check for CLOBBER_HIGH.
12999 (copy_insn_1): Likewise.
13000 (gen_hard_reg_clobber_high): New gen function.
13001 * genconfig.c (walk_insn_part): Check for CLOBBER_HIGH.
13002 * genemit.c (gen_exp): Likewise.
13003 (gen_emit_seq): Pass through info.
13004 (gen_insn): Check for CLOBBER_HIGH.
13005 (gen_expand): Pass through info.
13006 (gen_split): Likewise.
13007 (output_add_clobbers): Likewise.
13008 * genrecog.c (validate_pattern): Check for CLOBBER_HIGH.
13009 (remove_clobbers): Likewise.
13010 * rtl.h (gen_hard_reg_clobber_high): New declaration.
13012 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13014 * doc/rtl.texi (clobber_high): Add.
13015 (parallel): Add in clobber high
13016 * rtl.c (rtl_check_failed_code3): Add function.
13017 * rtl.def (CLOBBER_HIGH): Add expression.
13018 * rtl.h (RTL_CHECKC3): Add macro.
13019 (rtl_check_failed_code3): Add declaration.
13020 (XC3EXP): Add macro.
13022 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
13025 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
13026 cfun->machine->max_used_stack_alignment if needed.
13028 2018-08-04 Martin Sebor <msebor@redhat.com>
13030 PR tree-optimization/86571
13031 * gimple-ssa-sprintf.c (format_floating): Extend upper bound of
13034 2018-08-03 Sandra Loosemore <sandra@codesourcery.com>
13037 * config/nios2/nios2.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13040 2018-08-03 Jeff Law <law@redhat.com>
13043 * config/mn10300/mn10300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13044 Define to speculation_safe_value_not_needed.
13046 2018-08-03 David Malcolm <dmalcolm@redhat.com>
13048 * doc/gcov.texi (-x): Remove duplicate "to".
13049 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
13050 (-Wif-not-aligned): Remove duplicate "is".
13051 (-flto): Remove duplicate "the".
13052 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
13053 duplicate "v5.00.b".
13054 (MSP430 Options): Remove duplicate "and" from the description
13055 of "-mgprel-sec=regexp".
13056 (x86 Options): Remove duplicate copies of "vmldLog102" and
13057 vmlsLog104 from description of "-mveclibabi=type".
13059 2018-08-03 Richard Sandiford <richard.sandiford@arm.com>
13061 * internal-fn.h (first_commutative_argument): Declare.
13062 * internal-fn.c (first_commutative_argument): New function.
13063 * tree-vect-slp.c (vect_get_and_check_slp_defs): Remove extra
13064 restrictions for pattern statements. Use first_commutative_argument
13065 to look for commutative operands in calls to internal functions.
13067 2018-08-03 Aldy Hernandez <aldyh@redhat.com>
13069 * Makefile.in (wide-int-range.o): New.
13070 * tree-vrp.c: Move all the wide_int_* functions to...
13071 * wide-int-range.cc: ...here.
13072 * tree-vrp.h: Move all the wide_int_* prototypes to...
13073 * wide-int-range.h: ...here.
13075 2018-08-03 Tom de Vries <tdevries@suse.de>
13077 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): Return
13079 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Remove define.
13080 * except.c (output_function_exception_table): Do early exit if
13081 targetm_common.except_unwind_info (&global_options) == UI_NONE.
13083 2018-08-03 Martin Liska <mliska@suse.cz>
13085 * predict.c (dump_prediction): Change to 2 digits
13088 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
13090 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
13092 (falkor_am_1_gtov_gtov): ... a new insn reservation.
13094 2018-07-19 Ilya Leoshkevich <iii@linux.ibm.com>
13096 * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Replace > with >=.
13097 * df-problems.c (df_remove_dead_eq_notes): Replace > with >=.
13098 * dwarf2out.c (mem_loc_descriptor): Replace > with >=.
13099 * lra-constraints.c (spill_hard_reg_in_range): Replace <= with <.
13100 * lra-remat.c (call_used_input_regno_present_p): Replace <= with <.
13102 2018-08-02 David Malcolm <dmalcolm@redhat.com>
13104 * diagnostic-show-locus.c (diagnostic_show_locus): Use
13105 pp_take_prefix when saving the existing prefix.
13106 * diagnostic.c (diagnostic_append_note): Likewise.
13107 * langhooks.c (lhd_print_error_function): Likewise.
13108 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
13109 param's type. Free the existing prefix.
13110 (pp_take_prefix): New function.
13111 (pretty_printer::pretty_printer): Drop the prefix parameter.
13112 Rename the length parameter to match the comment.
13113 (pretty_printer::~pretty_printer): Free the prefix.
13114 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
13116 (struct pretty_printer): Drop the "const" from "prefix" field's
13117 type and clarify memory management.
13118 (pp_set_prefix): Drop the "const" from the 2nd param.
13119 (pp_take_prefix): New decl.
13121 2018-08-02 Aaron Sawdey <acsawdey@linux.ibm.com>
13123 * config/rs6000/rs6000-string.c (select_block_compare_mode): Move test
13124 for word_mode_ok here instead of passing as argument.
13125 (expand_block_compare): Change select_block_compare_mode() call.
13126 (expand_strncmp_gpr_sequence): New function.
13127 (expand_strn_compare): Make use of expand_strncmp_gpr_sequence.
13129 2018-08-02 Jeff Law <law@redhat.com>
13132 * config/m68k/m68k.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13133 Define to speculation_safe_value_not_needed.
13136 * config/h8300/h8300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13137 Define to speculation_safe_value_not_needed.
13139 2018-08-02 Tom de Vries <tdevries@suse.de>
13142 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): New
13143 function. Return UI_TARGET unconditionally.
13144 (TARGET_EXCEPT_UNWIND_INFO): Redefine to nvptx_except_unwind_info.
13145 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Emit commented out '.byte'.
13147 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13149 * genemit.c (print_overload_test): Fix typo.
13151 2018-08-02 Richard Biener <rguenther@suse.de>
13153 PR tree-optimization/86816
13154 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
13155 which checks for value availability before querying it.
13156 (gvn_uses_equal): Use it.
13157 (same_succ_hash): Likewise.
13158 (gimple_equal_p): Likewise.
13160 2018-08-02 Nick Clifton <nickc@redhat.com>
13163 * config/stormy16/stormy16.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13164 Define to speculation_safe_value_not_needed.
13167 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13168 Define to speculation_safe_value_not_needed.
13171 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13172 Define to speculation_safe_value_not_needed.
13175 * config/rx/rx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13176 Define to speculation_safe_value_not_needed.
13179 * config/msp430/msp430.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13180 Define to speculation_safe_value_not_needed.
13183 * config/mcore/mcore.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13184 Define to speculation_safe_value_not_needed.
13187 * config/m32r/m32r.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13188 Define to speculation_safe_value_not_needed.
13191 * config/iq2000/iq2000.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13192 Define to speculation_safe_value_not_needed.
13195 * config/frv/frv.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
13196 speculation_safe_value_not_needed.
13199 * config/fr30/fr30.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
13200 to speculation_safe_value_not_needed.
13202 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13204 * doc/md.texi: Expand the documentation of instruction names
13205 to mention port-local uses. Document '@' in pattern names.
13206 * read-md.h (overloaded_instance, overloaded_name): New structs.
13207 (mapping): Declare.
13208 (md_reader::handle_overloaded_name): New member function.
13209 (md_reader::get_overloads): Likewise.
13210 (md_reader::m_first_overload): New member variable.
13211 (md_reader::m_next_overload_ptr): Likewise.
13212 (md_reader::m_overloads_htab): Likewise.
13213 * read-md.c (md_reader::md_reader): Initialize m_first_overload,
13214 m_next_overload_ptr and m_overloads_htab.
13215 * read-rtl.c (iterator_group): Add "type" and "get_c_token" fields.
13216 (get_mode_token, get_code_token, get_int_token): New functions.
13217 (map_attr_string): Add an optional argument that passes back
13218 the associated iterator.
13219 (overloaded_name_hash, overloaded_name_eq_p, named_rtx_p):
13220 (md_reader::handle_overloaded_name, add_overload_instance): New
13222 (apply_iterators): Handle '@' names. Report an error if '@'
13223 is used without iterators.
13224 (initialize_iterators): Initialize the new iterator_group fields.
13225 * genopinit.c (handle_overloaded_code_for)
13226 (handle_overloaded_gen): New functions.
13227 (main): Use them to print declarations of maybe_code_for_* and
13228 maybe_gen_* functions, and inline definitions of code_for_* and gen_*.
13229 * genemit.c (print_overload_arguments, print_overload_test)
13230 (handle_overloaded_code_for, handle_overloaded_gen): New functions.
13231 (main): Use it to print definitions of maybe_code_for_* and
13232 maybe_gen_* functions.
13233 * config/aarch64/aarch64.c (aarch64_split_128bit_move): Use
13234 gen_aarch64_mov{low,high}_di and gen_aarch64_movdi_{low,high}
13235 instead of explicit mode checks.
13236 (aarch64_split_simd_combine): Likewise gen_aarch64_simd_combine.
13237 (aarch64_split_simd_move): Likewise gen_aarch64_split_simd_mov.
13238 (aarch64_emit_load_exclusive): Likewise gen_aarch64_load_exclusive.
13239 (aarch64_emit_store_exclusive): Likewise gen_aarch64_store_exclusive.
13240 (aarch64_expand_compare_and_swap): Likewise
13241 gen_aarch64_compare_and_swap and gen_aarch64_compare_and_swap_lse
13242 (aarch64_gen_atomic_cas): Likewise gen_aarch64_atomic_cas.
13243 (aarch64_emit_atomic_swap): Likewise gen_aarch64_atomic_swp.
13244 (aarch64_constant_pool_reload_icode): Delete.
13245 (aarch64_secondary_reload): Use code_for_aarch64_reload_movcp
13246 instead of aarch64_constant_pool_reload_icode. Use
13247 code_for_aarch64_reload_mov instead of explicit mode checks.
13248 (rsqrte_type, get_rsqrte_type, rsqrts_type, get_rsqrts_type): Delete.
13249 (aarch64_emit_approx_sqrt): Use gen_aarch64_rsqrte instead of
13250 get_rsqrte_type and gen_aarch64_rsqrts instead of gen_rqrts_type.
13251 (recpe_type, get_recpe_type, recps_type, get_recps_type): Delete.
13252 (aarch64_emit_approx_div): Use gen_aarch64_frecpe instead of
13253 get_recpe_type and gen_aarch64_frecps instead of get_recps_type.
13254 (aarch64_atomic_load_op_code): Delete.
13255 (aarch64_emit_atomic_load_op): Likewise.
13256 (aarch64_gen_atomic_ldop): Use UNSPECV_ATOMIC_* instead of
13257 aarch64_atomic_load_op_code. Use gen_aarch64_atomic_load
13258 instead of aarch64_emit_atomic_load_op.
13259 * config/aarch64/aarch64.md (aarch64_reload_movcp<GPF_TF:mode><P:mode>)
13260 (aarch64_reload_movcp<VALL:mode><P:mode>, aarch64_reload_mov<mode>)
13261 (aarch64_movdi_<mode>low, aarch64_movdi_<mode>high)
13262 (aarch64_mov<mode>high_di, aarch64_mov<mode>low_di): Add a '@'
13263 character before the pattern name.
13264 * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
13265 (aarch64_rsqrte<mode>, aarch64_rsqrts<mode>)
13266 (aarch64_simd_combine<mode>, aarch64_frecpe<mode>)
13267 (aarch64_frecps<mode>): Likewise.
13268 * config/aarch64/atomics.md (atomic_compare_and_swap<mode>)
13269 (aarch64_compare_and_swap<mode>, aarch64_compare_and_swap<mode>_lse)
13270 (aarch64_load_exclusive<mode>, aarch64_store_exclusive<mode>)
13271 (aarch64_atomic_swp<mode>, aarch64_atomic_cas<mode>)
13272 (aarch64_atomic_load<atomic_ldop><mode>): Likewise.
13274 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13276 * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
13277 Allow HFmode constants if TARGET_FP_F16INST.
13279 2018-08-02 Jackson Woodruff <jackson.woodruff@arm.com>
13282 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp):
13283 No longer check last store for clobber of address register.
13285 2018-08-02 Martin Liska <mliska@suse.cz>
13287 PR gcov-profile/86817
13288 * gcov.c (process_all_functions): New function.
13290 (process_file): Move functions processing to
13291 process_all_functions.
13293 2018-08-02 David Malcolm <dmalcolm@redhat.com>
13295 * dumpfile.c (dump_user_location_t::dump_user_location_t): Add
13296 "const" to the "gimple *" and "rtx_insn *" parameters.
13297 * dumpfile.h (dump_user_location_t::dump_user_location_t):
13299 (dump_location_t::dump_location_t): Likewise.
13301 2018-08-01 Martin Sebor <msebor@redhat.com>
13303 PR tree-optimization/86650
13304 * gimple-pretty-print.c (percent_G_format): Accept a "gimple *"
13305 rather than a "gcall *". Directly pass the data of interest
13306 to percent_K_format, rather than building a temporary CALL_EXPR
13308 * gimple-fold.c (gimple_fold_builtin_strncpy): Adjust.
13309 (gimple_fold_builtin_strncat): Adjust.
13310 * gimple-ssa-warn-restrict.h (check_bounds_or_overlap): Replace
13311 gcall* argument with gimple*.
13312 * gimple-ssa-warn-restrict.c (check_call): Same.
13313 (wrestrict_dom_walker::before_dom_children): Same.
13314 (builtin_access::builtin_access): Same.
13315 (check_bounds_or_overlap): Same
13316 (maybe_diag_overlap): Same.
13317 (maybe_diag_offset_bounds): Same.
13318 * tree-diagnostic.c (default_tree_printer): Move usage of
13319 EXPR_LOCATION (t) and TREE_BLOCK (t) from within percent_K_format
13321 * tree-pretty-print.c (percent_K_format): Add argument.
13322 * tree-pretty-print.h: Add argument.
13323 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Adjust.
13324 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Adjust.
13325 (maybe_diag_stxncpy_trunc): Same.
13326 (handle_builtin_stxncpy): Same.
13327 (handle_builtin_strcat): Same.
13329 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13331 * match.pd: Optimise pointer range checks.
13333 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13335 PR tree-optimization/86758
13336 * tree-vect-stmts.c (vectorizable_simd_clone_call): Don't try
13337 to remove pattern statements.
13339 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13341 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Use the
13342 result of dfs_enumerate_from when constructing stmt_vec_infos,
13343 instead of additionally calling get_loop_body.
13345 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13347 * tree-vectorizer.h (vect_create_data_ref_ptr): Remove inv_p
13349 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
13350 When creating an iv, assert that the step is not known to be zero.
13351 (vect_setup_realignment): Update call accordingly.
13352 * tree-vect-stmts.c (vectorizable_store): Likewise.
13353 (vectorizable_load): Likewise. Handle VMAT_INVARIANT separately.
13355 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13357 * tree-vectorizer.h (vect_stmt_to_vectorize): New function.
13358 * tree-vect-loop.c (vect_update_vf_for_slp): Use it.
13359 (vectorizable_reduction): Likewise.
13360 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
13361 (vect_detect_hybrid_slp_stmts): Likewise.
13362 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
13364 2018-08-01 Aldy Hernandez <aldyh@redhat.com>
13366 * tree-vrp (zero_nonzero_bits_from_bounds): Rename to...
13367 (wide_int_set_zero_nonzero_bits): ...this.
13368 (zero_nonzero_bits_from_vr): Rename to...
13369 (vrp_set_zero_nonzero_bits): ...this.
13370 (extract_range_from_multiplicative_op_1): Abstract wide int
13372 (wide_int_range_multiplicative_op): ...here.
13373 (extract_range_from_binary_expr_1): Extract wide int binary
13374 operations into their own functions.
13375 (wide_int_range_lshift): New.
13376 (wide_int_range_can_optimize_bit_op): New.
13377 (wide_int_range_shift_undefined_p): New.
13378 (wide_int_range_bit_xor): New.
13379 (wide_int_range_bit_ior): New.
13380 (wide_int_range_bit_and): New.
13381 (wide_int_range_trunc_mod): New.
13382 (extract_range_into_wide_ints): New.
13383 (vrp_shift_undefined_p): New.
13384 (extract_range_from_multiplicative_op): New.
13385 (vrp_can_optimize_bit_op): New.
13386 * tree-vrp.h (value_range::dump): New.
13387 (wide_int_range_multiplicative_op): New.
13388 (wide_int_range_lshift):New.
13389 (wide_int_range_shift_undefined_p): New.
13390 (wide_int_range_bit_xor): New.
13391 (wide_int_range_bit_ior): New.
13392 (wide_int_range_bit_and): New.
13393 (wide_int_range_trunc_mod): New.
13394 (zero_nonzero_bits_from_bounds): Rename to...
13395 (wide_int_set_zero_nonzero_bits): ...this.
13396 (zero_nonzero_bits_from_vr): Rename to...
13397 (vrp_set_zero_nonzero_bits): ...this.
13398 (range_easy_mask_min_max): Rename to...
13399 (wide_int_range_can_optimize_bit_op): this.
13400 * vr-values.c (simplify_bit_ops_using_ranges): Rename
13401 zero_nonzero_bits_from_vr into vrp_set_zero_nonzero_bits.
13403 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13405 * tree-vectorizer.h (vect_orig_stmt): New function.
13406 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Use it.
13407 * tree-vect-loop.c (vect_model_reduction_cost): Likewise.
13408 (vect_create_epilog_for_reduction): Likewise.
13409 (vectorizable_live_operation): Likewise.
13410 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
13411 (vect_detect_hybrid_slp_stmts, vect_schedule_slp): Likewise.
13412 * tree-vect-stmts.c (vectorizable_call): Likewise.
13413 (vectorizable_simd_clone_call, vect_remove_stores): Likewise.
13415 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13417 * tree-vectorizer.h (vect_transform_stmt): Remove grouped_store
13419 * tree-vect-stmts.c (vect_transform_stmt): Likewise.
13420 * tree-vect-loop.c (vect_transform_loop_stmt): Update call accordingly.
13421 (vect_transform_loop): Likewise.
13422 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
13424 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13426 * tree-vectorizer.h (vect_schedule_slp): Return void.
13427 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
13428 (vect_schedule_slp): Likewise.
13430 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13432 * tree-vect-loop.c (vect_transform_loop_stmt): Remove slp_scheduled
13434 (vect_transform_loop): Update calls accordingly. Schedule SLP
13435 instances before the main loop, if any exist.
13437 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13439 PR tree-optimization/86749
13440 * tree-vect-patterns.c (vect_determine_min_output_precision_1):
13441 If the lhs is used in a COND_EXPR, check that it is being used
13442 as the "then" or "else" value.
13444 2018-08-01 Tom de Vries <tdevries@suse.de>
13447 * config/nvptx/nvptx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
13448 speculation_safe_value_not_needed.
13450 2018-08-01 Richard Biener <rguenther@suse.de>
13452 * tree-ssa-sccvn.c (visit_phi): Compare invariant addresses
13453 as base and offset.
13455 2018-08-01 Martin Liska <mliska@suse.cz>
13457 * value-prof.c (gimple_divmod_fixed_value_transform): Unify
13458 format how successful transformation is dumped.
13459 (gimple_mod_pow2_value_transform): Likewise.
13460 (gimple_mod_subtract_transform): Likewise.
13461 (gimple_stringops_transform): Likewise.
13463 2018-08-01 Martin Liska <mliska@suse.cz>
13465 PR value-prof/35543
13466 * value-prof.c (interesting_stringop_to_profile_p):
13467 Simplify the code and add BUILT_IN_MEMMOVE.
13468 (gimple_stringops_transform): Likewise.
13470 2018-08-01 Sam Tebbs <sam.tebbs@arm.com>
13472 * config/aarch64/aarch64-simd.md
13473 (*aarch64_get_lane_zero_extendsi<mode>): Rename to...
13474 (*aarch64_get_lane_zero_extend<GPI:mode><VDQQH:mode>): ... This and
13475 use GPI iterator instead of SI mode.
13477 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
13479 * config/rs6000/rs6000.md (speculation_barrier): Renamed from
13480 rs6000_speculation_barrier.
13481 * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
13482 new barrier pattern name.
13484 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
13486 * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
13487 (speculation_barrier): New insn.
13489 2018-08-01 Richard Biener <rguenther@suse.de>
13492 * graphite.h: Include isl/id.h and isl/space.h to allow build
13495 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
13498 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
13499 mode for COFF targets.
13500 * defaults.h (TARGET_COFF): Define.
13501 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
13502 TARGET_COFF): Define.
13503 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
13504 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
13505 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
13507 2018-07-31 Alexandre Oliva <oliva@adacore.com>
13509 * gimple-streamer-in.c (input_bb): Restore BB discriminator.
13510 * gimple-streamer-out.c (output_bb): Save it.
13511 * lto-streamer-in.c (input_struct_function_base): Restore
13512 instance discriminator if available. Create map on demand.
13513 * lto-streamer-out.c (output_struct_function_base): Save it if
13515 * final.c (decl_to_instance_map): Document LTO strategy.
13517 2018-07-31 Alexandre Oliva <oliva@adacore.com>
13518 Olivier Hainque <hainque@adacore.com>
13520 * debug.h (decl_to_instance_map_t): New type.
13521 (decl_to_instance_map): Declare.
13522 (maybe_create_decl_to_instance_map): New inline function.
13523 * final.c (bb_discriminator, last_bb_discriminator): New statics,
13524 to track basic block discriminators.
13525 (final_start_function_1): Initialize them.
13526 (final_scan_insn_1): On NOTE_INSN_BASIC_BLOCK, track
13528 (decl_to_instance_map): New variable.
13529 (map_decl_to_instance, maybe_set_discriminator): New functions.
13530 (notice_source_line): Set discriminator.
13532 2018-07-31 Ian Lance Taylor <iant@golang.org>
13534 * targhooks.c (default_have_speculation_safe_value): Add
13537 2018-07-31 David Malcolm <dmalcolm@redhat.com>
13539 * dump-context.h: Include "pretty-print.h".
13540 (dump_context::refresh_dumps_are_enabled): New decl.
13541 (dump_context::emit_item): New decl.
13542 (class dump_context): Add fields "m_test_pp" and
13544 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
13545 (temp_dump_context::get_dumped_text): New decl.
13546 (class temp_dump_context): Add field "m_pp".
13547 * dumpfile.c (refresh_dumps_are_enabled): Convert to...
13548 (dump_context::refresh_dumps_are_enabled): ...and add a test for
13550 (set_dump_file): Update for above change.
13551 (set_alt_dump_file): Likewise.
13552 (dump_loc): New overload, taking a pretty_printer *.
13553 (dump_context::dump_loc): Call end_any_optinfo. Dump the location
13554 to any test pretty-printer.
13555 (make_item_for_dump_gimple_stmt): New function, adapted from
13556 optinfo::add_gimple_stmt.
13557 (dump_context::dump_gimple_stmt): Call it, and use the result,
13558 eliminating the direct usage of dump_file and alt_dump_file in
13559 favor of indirectly using them via emit_item.
13560 (make_item_for_dump_gimple_expr): New function, adapted from
13561 optinfo::add_gimple_expr.
13562 (dump_context::dump_gimple_expr): Call it, and use the result,
13563 eliminating the direct usage of dump_file and alt_dump_file in
13564 favor of indirectly using them via emit_item.
13565 (make_item_for_dump_generic_expr): New function, adapted from
13567 (dump_context::dump_generic_expr): Call it, and use the result,
13568 eliminating the direct usage of dump_file and alt_dump_file in
13569 favor of indirectly using them via emit_item.
13570 (make_item_for_dump_printf_va): New function, adapted from
13571 optinfo::add_printf_va.
13572 (make_item_for_dump_printf): New function.
13573 (dump_context::dump_printf_va): Call make_item_for_dump_printf_va,
13574 and use the result, eliminating the direct usage of dump_file and
13575 alt_dump_file in favor of indirectly using them via emit_item.
13576 (make_item_for_dump_dec): New function.
13577 (dump_context::dump_dec): Call it, and use the result,
13578 eliminating the direct usage of dump_file and alt_dump_file in
13579 favor of indirectly using them via emit_item.
13580 (make_item_for_dump_symtab_node): New function, adapted from
13581 optinfo::add_symtab_node.
13582 (dump_context::dump_symtab_node): Call it, and use the result,
13583 eliminating the direct usage of dump_file and alt_dump_file in
13584 favor of indirectly using them via emit_item.
13585 (dump_context::begin_scope): Reimplement, avoiding direct usage
13586 of dump_file and alt_dump_file in favor of indirectly using them
13588 (dump_context::emit_item): New member function.
13589 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
13590 Set up test pretty-printer on the underlying context. Call
13591 refresh_dumps_are_enabled.
13592 (temp_dump_context::~temp_dump_context): Call
13593 refresh_dumps_are_enabled.
13594 (temp_dump_context::get_dumped_text): New member function.
13595 (selftest::verify_dumped_text): New function.
13596 (ASSERT_DUMPED_TEXT_EQ): New macro.
13597 (selftest::test_capture_of_dump_calls): Run all tests twice, with
13598 and then without optinfo enabled. Add uses of
13599 ASSERT_DUMPED_TEXT_EQ to all tests. Add test of nested scopes.
13600 * dumpfile.h: Update comment for the dump_* API.
13601 * optinfo-emit-json.cc
13602 (selftest::test_building_json_from_dump_calls): Update for new
13603 param for temp_dump_context ctor.
13604 * optinfo.cc (optinfo_item::optinfo_item): Remove "owned" param
13605 and "m_owned" field.
13606 (optinfo_item::~optinfo_item): Likewise.
13607 (optinfo::add_item): New member function.
13608 (optinfo::emit): Update comment.
13609 (optinfo::add_string): Delete.
13610 (optinfo::add_printf): Delete.
13611 (optinfo::add_printf_va): Delete.
13612 (optinfo::add_gimple_stmt): Delete.
13613 (optinfo::add_gimple_expr): Delete.
13614 (optinfo::add_tree): Delete.
13615 (optinfo::add_symtab_node): Delete.
13616 (optinfo::add_dec): Delete.
13617 * optinfo.h (class dump_context): New forward decl.
13618 (optinfo::add_item): New decl.
13619 (optinfo::add_string): Delete.
13620 (optinfo::add_printf): Delete.
13621 (optinfo::add_printf_va): Delete.
13622 (optinfo::add_gimple_stmt): Delete.
13623 (optinfo::add_gimple_expr): Delete.
13624 (optinfo::add_tree): Delete.
13625 (optinfo::add_symtab_node): Delete.
13626 (optinfo::add_dec): Delete.
13627 (optinfo::add_poly_int): Delete.
13628 (optinfo_item::optinfo_item): Remove "owned" param.
13629 (class optinfo_item): Remove field "m_owned".
13631 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13633 PR middle-end/86705
13634 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
13635 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
13636 requested variable alignment.
13637 (expand_one_ssa_partition): Likewise.
13638 (expand_one_var): Likewise.
13640 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13642 * config/pdp11/pdp11.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
13643 to speculation_safe_value_not_needed.
13645 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13647 * targhooks.h (speculation_safe_value_not_needed): New prototype.
13648 * targhooks.c (speculation_safe_value_not_needed): New function.
13649 * target.def (have_speculation_safe_value): Update documentation.
13650 * doc/tm.texi: Regenerated.
13652 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13654 * config/aarch64/iterators.md (ALLI_TI): New iterator.
13655 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>): New
13657 (despeculate_copy<ALLI:mode>_insn): New insn.
13658 (despeculate_copyti_insn): New insn.
13659 (despeculate_simple<ALLI:mode>): New insn
13660 (despeculate_simpleti): New insn.
13661 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): New
13663 (TARGET_SPECULATION_SAFE_VALUE): Redefine to
13664 aarch64_speculation_safe_value.
13665 (aarch64_print_operand): Handle const0_rtx in modifier 'H'.
13667 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13669 * config/aarch64/aarch64-speculation.cc: New file.
13670 * config/aarch64/aarch64-passes.def (pass_track_speculation): Add
13671 before pass_reorder_blocks.
13672 * config/aarch64/aarch64-protos.h (make_pass_track_speculation): Add
13674 * config/aarch64/aarch64.c (aarch64_conditional_register_usage): Fix
13675 X14 and X15 when tracking speculation.
13676 * config/aarch64/aarch64.md (register name constants): Add
13677 SPECULATION_TRACKER_REGNUM and SPECULATION_SCRATCH_REGNUM.
13678 (unspec): Add UNSPEC_SPECULATION_TRACKER.
13679 (speculation_barrier): New insn attribute.
13680 (cmp<mode>): Allow SP in comparisons.
13681 (speculation_tracker): New insn.
13682 (speculation_barrier): Add speculation_barrier attribute.
13683 * config/aarch64/t-aarch64: Add make rule for aarch64-speculation.o.
13684 * config.gcc (aarch64*-*-*): Add aarch64-speculation.o to extra_objs.
13685 * doc/invoke.texi (AArch64 Options): Document -mtrack-speculation.
13687 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13689 * config/aarch64/aarch64.md (cb<optab><mode>1): Disable when
13690 aarch64_track_speculation is true.
13691 (tb<optab><mode>1): Likewise.
13692 * config/aarch64/aarch64.c (aarch64_split_compare_regs): Do not
13693 generate CB[N]Z when tracking speculation.
13694 (aarch64_split_compare_and_swap): Likewise.
13695 (aarch64_split_atomic_op): Likewise.
13697 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13699 * config/aarch64/aarch64.opt (mtrack-speculation): New target option.
13701 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13703 * config/aarch64.md (unspecv): Add UNSPECV_SPECULAION_BARRIER.
13704 (speculation_barrier): New insn.
13706 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13708 * config/arm/unspecs.md (unspecv): Add VUNSPEC_SPECULATION_BARRIER.
13709 * config/arm/arm.md (speculation_barrier): New expand.
13710 (speculation_barrier_insn): New pattern.
13712 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
13714 * builtin-types.def (BT_FN_PTR_PTR_VAR): New function type.
13715 (BT_FN_I1_I1_VAR, BT_FN_I2_I2_VAR, BT_FN_I4_I4_VAR): Likewise.
13716 (BT_FN_I8_I8_VAR, BT_FN_I16_I16_VAR): Likewise.
13717 * builtin-attrs.def (ATTR_NOVOPS_NOTHROW_LEAF_LIST): New attribute
13719 * builtins.def (BUILT_IN_SPECULATION_SAFE_VALUE_N): New builtin.
13720 (BUILT_IN_SPECULATION_SAFE_VALUE_PTR): New internal builtin.
13721 (BUILT_IN_SPECULATION_SAFE_VALUE_1): Likewise.
13722 (BUILT_IN_SPECULATION_SAFE_VALUE_2): Likewise.
13723 (BUILT_IN_SPECULATION_SAFE_VALUE_4): Likewise.
13724 (BUILT_IN_SPECULATION_SAFE_VALUE_8): Likewise.
13725 (BUILT_IN_SPECULATION_SAFE_VALUE_16): Likewise.
13726 * builtins.c (expand_speculation_safe_value): New function.
13727 (expand_builtin): Call it.
13728 * doc/cpp.texi: Document predefine __HAVE_SPECULATION_SAFE_VALUE.
13729 * doc/extend.texi: Document __builtin_speculation_safe_value.
13730 * doc/md.texi: Document "speculation_barrier" pattern.
13731 * doc/tm.texi.in: Pull in TARGET_SPECULATION_SAFE_VALUE and
13732 TARGET_HAVE_SPECULATION_SAFE_VALUE.
13733 * doc/tm.texi: Regenerated.
13734 * target.def (have_speculation_safe_value, speculation_safe_value): New
13736 * targhooks.c (default_have_speculation_safe_value): New function.
13737 (default_speculation_safe_value): New function.
13738 * targhooks.h (default_have_speculation_safe_value): Add prototype.
13739 (default_speculation_safe_value): Add prototype.
13741 2018-07-31 David Malcolm <dmalcolm@redhat.com>
13743 * dump-context.h (dump_context::dump_loc): New decl.
13744 * dumpfile.c (dump_context::dump_loc): New member function.
13745 (dump_context::dump_gimple_stmt_loc): Reimplement using dump_loc
13746 and dump_gimple_stmt.
13747 (dump_context::dump_gimple_expr_loc): Likewise, using
13749 (dump_context::dump_generic_expr_loc): Likewise, using
13751 (dump_context::dump_printf_loc_va): Likewise, using
13753 (dump_context::begin_scope): Explicitly using the global function
13754 "dump_loc", rather than the member function.
13756 2018-07-31 Martin Sebor <msebor@redhat.com>
13758 PR tree-optimization/86741
13759 * tree-vrp.c (vrp_prop::check_mem_ref): Avoid incomplete types.
13761 2018-07-31 Andreas Krebbel <krebbel@linux.ibm.com>
13763 * config/s390/s390.c (s390_expand_setmem): Make the unrolling to
13764 depend on whether prefetch instructions will be emitted or not.
13765 Use TARGET_SETMEM_PFD for checking whether prefetch instructions
13766 will be emitted or not.
13767 * config/s390/s390.h (TARGET_SETMEM_PREFETCH_DISTANCE)
13768 (TARGET_SETMEM_PFD): New macros.
13770 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13772 * tree-vectorizer.h (stmt_vec_info): Turn back into a typedef.
13773 (NULL_STMT_VEC_INFO): Delete.
13774 (stmt_vec_info::operator*): Likewise.
13775 (stmt_vec_info::operator gimple *): Likewise.
13776 * tree-vect-loop.c (vectorizable_reduction): Use NULL instead
13777 of NULL_STMT_VEC_INFO.
13778 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
13779 (vect_reassociating_reduction_p): Likewise.
13780 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
13781 (vectorizable_store): Likewise.
13782 * tree-vectorizer.c (vec_info::set_vinfo_for_stmt): Likewise.
13783 (vec_info::free_stmt_vec_infos): Likewise.
13785 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13787 * tree-vectorizer.h (vect_stmt_in_region_p): Delete.
13788 * tree-vectorizer.c (vect_stmt_in_region_p): Likewise.
13790 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13792 * tree-vectorizer.h (vec_info::new_vinfo_for_stmt)
13793 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
13794 (vec_info::free_stmt_vec_info): New private member functions.
13795 (set_stmt_vec_info_vec, free_stmt_vec_infos, vinfo_for_stmt)
13796 (set_vinfo_for_stmt, new_stmt_vec_info, free_stmt_vec_info): Delete.
13797 * tree-parloops.c (gather_scalar_reductions): Remove calls to
13798 set_stmt_vec_info_vec and free_stmt_vec_infos.
13799 * tree-vect-loop.c (_loop_vec_info): Remove call to
13800 set_stmt_vec_info_vec.
13801 * tree-vect-stmts.c (new_stmt_vec_info, set_stmt_vec_info_vec)
13802 (free_stmt_vec_infos, free_stmt_vec_info): Delete in favor of...
13803 * tree-vectorizer.c (vec_info::new_stmt_vec_info)
13804 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
13805 (vec_info::free_stmt_vec_info): ...these new functions. Remove
13806 assignments in {vec_info::,}new_stmt_vec_info that are redundant
13807 with the clearing in the xcalloc.
13808 (stmt_vec_info_vec): Delete.
13809 (vec_info::vec_info): Don't call set_stmt_vec_info_vec.
13810 (vectorize_loops): Likewise.
13811 (vec_info::~vec_info): Remove argument from call to
13812 free_stmt_vec_infos.
13813 (vec_info::add_stmt): Remove vinfo argument from call to
13816 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13818 * tree-vectorizer.h (free_stmt_vec_info): Take a stmt_vec_info
13819 rather than a gimple stmt.
13820 * tree-vect-stmts.c (free_stmt_vec_info): Likewise. Don't free
13821 information for pattern statements when passed the original
13822 statement; instead wait to be passed the pattern statement itself.
13823 Don't call set_vinfo_for_stmt here.
13824 (free_stmt_vec_infos): Update call to free_stmt_vec_info.
13825 * tree-vect-loop.c (_loop_vec_info::~loop_vec_info): Don't free
13826 stmt_vec_infos here.
13827 * tree-vect-slp.c (_bb_vec_info::~bb_vec_info): Likewise.
13828 * tree-vectorizer.c (vec_info::remove_stmt): Nullify the statement's
13829 stmt_vec_infos entry.
13831 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13833 * tree-vectorizer.h (vec_info::replace_stmt): Declare.
13834 * tree-vectorizer.c (vec_info::replace_stmt): New function.
13835 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Use it.
13836 * tree-vect-stmts.c (vectorizable_call): Likewise.
13837 (vectorizable_simd_clone_call): Likewise.
13839 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13841 * tree-vectorizer.h (vec_info::remove_stmt): Declare.
13842 * tree-vectorizer.c (vec_info::remove_stmt): New function.
13843 * tree-vect-loop-manip.c (vect_set_loop_condition): Use it.
13844 * tree-vect-loop.c (vect_transform_loop): Likewise.
13845 * tree-vect-slp.c (vect_schedule_slp): Likewise.
13846 * tree-vect-stmts.c (vect_remove_stores): Likewise.
13848 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13850 * tree-vectorizer.h (vec_info::lookup_dr): New member function.
13851 (vect_dr_stmt): Delete.
13852 * tree-vectorizer.c (vec_info::lookup_dr): New function.
13853 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Use it instead
13855 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
13856 (vect_analyze_data_ref_dependence, vect_record_base_alignments)
13857 (vect_verify_datarefs_alignment, vect_peeling_supportable)
13858 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
13859 (vect_analyze_data_refs): Likewise.
13860 (vect_slp_analyze_data_ref_dependence): Likewise. Take a vec_info
13862 (vect_find_same_alignment_drs): Likewise.
13863 (vect_slp_analyze_node_dependences): Update calls accordingly.
13864 (vect_analyze_data_refs_alignment): Likewise. Use vec_info::lookup_dr
13865 instead of DR_VECT_AUX.
13866 (vect_get_peeling_costs_all_drs): Take a loop_vec_info instead
13867 of a vector data references. Use vec_info::lookup_dr instead of
13869 (vect_peeling_hash_get_lowest_cost): Update calls accordingly.
13870 (vect_enhance_data_refs_alignment): Likewise. Use vec_info::lookup_dr
13871 instead of DR_VECT_AUX.
13873 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13875 * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
13877 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
13879 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
13880 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
13881 (vect_gen_prolog_loop_niters): Likewise.
13883 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13885 * tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
13886 (DR_TARGET_ALIGNMENT, aligned_access_p, known_alignment_for_access_p)
13887 (vect_known_alignment_in_bytes, vect_dr_behavior)
13888 (vect_get_scalar_dr_size): Take references as dr_vec_infos
13889 instead of data_references. Update calls to other routines for
13890 which the same change has been made.
13891 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Take
13892 dr_vec_infos instead of stmt_vec_infos.
13893 (vect_analyze_data_ref_dependence): Update call accordingly.
13894 (vect_slp_analyze_data_ref_dependence)
13895 (vect_record_base_alignments): Use DR_VECT_AUX.
13896 (vect_calculate_target_alignment, vect_compute_data_ref_alignment)
13897 (vect_update_misalignment_for_peel, verify_data_ref_alignment)
13898 (vector_alignment_reachable_p, vect_get_data_access_cost)
13899 (vect_peeling_supportable, vect_analyze_group_access_1)
13900 (vect_analyze_group_access, vect_analyze_data_ref_access)
13901 (vect_vfa_segment_size, vect_vfa_access_size, vect_vfa_align)
13902 (vect_compile_time_alias, vect_small_gap_p)
13903 (vectorizable_with_step_bound_p, vect_duplicate_ssa_name_ptr_info):
13904 (vect_supportable_dr_alignment): Take references as dr_vec_infos
13905 instead of data_references. Update calls to other routines for
13906 which the same change has been made.
13907 (vect_verify_datarefs_alignment, vect_get_peeling_costs_all_drs)
13908 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
13909 (vect_slp_analyze_and_verify_node_alignment)
13910 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
13911 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
13912 (vect_setup_realignment): Use dr_vec_infos. Update calls after
13914 (_vect_peel_info::dr): Replace with...
13915 (_vect_peel_info::dr_info): ...this new field.
13916 (vect_peeling_hash_get_most_frequent)
13917 (vect_peeling_hash_choose_best_peeling): Update accordingly.
13918 (vect_peeling_hash_get_lowest_cost):
13919 (vect_enhance_data_refs_alignment): Likewise. Update calls to other
13920 routines for which the same change has been made.
13921 (vect_peeling_hash_insert): Likewise. Take a dr_vec_info instead of a
13923 * tree-vect-loop-manip.c (get_misalign_in_elems)
13924 (vect_gen_prolog_loop_niters): Use dr_vec_infos. Update calls after
13926 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
13927 * tree-vect-stmts.c (vect_get_store_cost, vect_get_load_cost)
13928 (vect_truncate_gather_scatter_offset, compare_step_with_zero)
13929 (get_group_load_store_type, get_negative_load_store_type)
13930 (vect_get_data_ptr_increment, vectorizable_store)
13931 (vectorizable_load): Likewise.
13932 (ensure_base_align): Take a dr_vec_info instead of a data_reference.
13933 Update calls to other routines for which the same change has been made.
13935 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13937 * tree-vectorizer.h (vec_info::move_dr): New member function.
13938 (dataref_aux): Rename to...
13939 (dr_vec_info): ...this and add "dr" and "stmt" fields.
13940 (_stmt_vec_info::dr_aux): Update accordingly.
13941 (_stmt_vec_info::data_ref_info): Delete.
13942 (STMT_VINFO_GROUPED_ACCESS, DR_GROUP_FIRST_ELEMENT)
13943 (DR_GROUP_NEXT_ELEMENT, DR_GROUP_SIZE, DR_GROUP_STORE_COUNT)
13944 (DR_GROUP_GAP, DR_GROUP_SAME_DR_STMT, REDUC_GROUP_FIRST_ELEMENT):
13945 (REDUC_GROUP_NEXT_ELEMENT, REDUC_GROUP_SIZE): Use dr_aux.dr instead
13947 (STMT_VINFO_DATA_REF): Likewise. Turn into an lvalue.
13948 (STMT_VINFO_DR_INFO): New macro.
13949 (DR_VECT_AUX): Use STMT_VINFO_DR_INKFO and vect_dr_stmt.
13950 (set_dr_misalignment): Update after rename of dataref_aux.
13951 (vect_dr_stmt): Move earlier in file. Return dr_aux.stmt.
13952 * tree-vect-stmts.c (new_stmt_vec_info): Remove redundant
13953 initialization of STMT_VINFO_DATA_REF.
13954 * tree-vectorizer.c (vec_info::move_dr): New function.
13955 * tree-vect-patterns.c (vect_recog_bool_pattern)
13956 (vect_recog_mask_conversion_pattern)
13957 (vect_recog_gather_scatter_pattern): Use it.
13958 * tree-vect-data-refs.c (vect_analyze_data_refs): Initialize
13959 the "dr" and "stmt" fields of dr_vec_info instead of
13960 STMT_VINFO_DATA_REF.
13962 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13964 * tree-vectorizer.h (_stmt_vec_info::pattern_stmt_p): New field.
13965 (is_pattern_stmt_p): Use it.
13966 * tree-vect-patterns.c (vect_init_pattern_stmt): Set pattern_stmt_p
13967 on pattern statements.
13969 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13971 * tree-vect-patterns.c (vect_mark_pattern_stmts): Take the
13972 original stmt as a stmt_vec_info rather than a gimple stmt.
13973 (vect_pattern_recog_1): Take the statement directly as a
13974 stmt_vec_info, rather than via a gimple_stmt_iterator.
13975 Update call to vect_mark_pattern_stmts.
13976 (vect_pattern_recog): Update calls accordingly.
13978 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
13980 * tree-vectorizer.h (vect_get_vec_defs_for_stmt_copy)
13981 (vect_get_vec_def_for_stmt_copy): Take a vec_info rather than
13982 a vect_def_type for the first argument.
13983 * tree-vect-stmts.c (vect_get_vec_defs_for_stmt_copy): Likewise.
13984 (vect_get_vec_def_for_stmt_copy): Likewise. Return the original
13985 operand if it isn't defined by a vectorized statement.
13986 (vect_build_gather_load_calls): Remove the mask_dt argument and
13987 update calls to vect_get_vec_def_for_stmt_copy.
13988 (vectorizable_bswap): Likewise the dt argument.
13989 (vectorizable_call): Update calls to vectorizable_bswap and
13990 vect_get_vec_def_for_stmt_copy.
13991 (vectorizable_simd_clone_call, vectorizable_assignment)
13992 (vectorizable_shift, vectorizable_operation, vectorizable_condition)
13993 (vectorizable_comparison): Update calls to
13994 vect_get_vec_def_for_stmt_copy.
13995 (vectorizable_store): Likewise. Remove now-unnecessary calls to
13996 vect_is_simple_use.
13997 (vect_get_loop_based_defs): Remove dt argument and update call
13998 to vect_get_vec_def_for_stmt_copy.
13999 (vectorizable_conversion): Update calls to vect_get_loop_based_defs
14000 and vect_get_vec_def_for_stmt_copy.
14001 (vectorizable_load): Update calls to vect_build_gather_load_calls
14002 and vect_get_vec_def_for_stmt_copy.
14003 * tree-vect-loop.c (vect_create_epilog_for_reduction)
14004 (vectorizable_reduction, vectorizable_live_operation): Update calls
14005 to vect_get_vec_def_for_stmt_copy.
14007 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14009 * tree-vect-data-refs.c (vect_record_base_alignment): Replace vec_info
14010 and gimple stmt arguments with a stmt_vec_info.
14011 (vect_record_base_alignments): Update calls accordingly.
14012 * tree-vect-slp.c (vect_record_max_nunits): Replace vec_info
14013 and gimple stmt arguments with a stmt_vec_info.
14014 (vect_build_slp_tree_1): Remove vinfo argument and update call
14015 to vect_record_max_nunits.
14016 (vect_build_slp_tree_2): Update calls to vect_build_slp_tree_1
14017 and vect_record_max_nunits.
14019 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14021 * tree-vectorizer.h (nested_in_vect_loop_p): Move further down
14022 file and take a stmt_vec_info instead of a gimple stmt.
14023 (supportable_widening_operation, vect_finish_replace_stmt)
14024 (vect_finish_stmt_generation, vect_get_store_rhs)
14025 (vect_get_vec_def_for_operand_1, vect_get_vec_def_for_operand)
14026 (vect_get_vec_defs, vect_init_vector, vect_transform_stmt)
14027 (vect_remove_stores, vect_analyze_stmt, vectorizable_condition)
14028 (vect_get_smallest_scalar_type, vect_check_gather_scatter)
14029 (vect_create_data_ref_ptr, bump_vector_ptr)
14030 (vect_permute_store_chain, vect_setup_realignment)
14031 (vect_transform_grouped_load, vect_record_grouped_load_vectors)
14032 (vect_create_addr_base_for_vector_ref, vectorizable_live_operation)
14033 (vectorizable_reduction, vectorizable_induction)
14034 (get_initial_def_for_reduction, is_simple_and_all_uses_invariant)
14035 (vect_get_place_in_interleaving_chain): Take stmt_vec_infos rather
14036 than gimple stmts as arguments.
14037 * tree-vect-data-refs.c (vect_get_smallest_scalar_type)
14038 (vect_preserves_scalar_order_p, vect_slp_analyze_node_dependences)
14039 (can_group_stmts_p, vect_check_gather_scatter)
14040 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
14041 (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment)
14042 (vect_permute_load_chain, vect_shift_permute_load_chain)
14043 (vect_transform_grouped_load)
14044 (vect_record_grouped_load_vectors): Likewise.
14045 * tree-vect-loop.c (vect_fixup_reduc_chain)
14046 (get_initial_def_for_reduction, vect_create_epilog_for_reduction)
14047 (vectorize_fold_left_reduction, is_nonwrapping_integer_induction)
14048 (vectorizable_reduction, vectorizable_induction)
14049 (vectorizable_live_operation, vect_loop_kill_debug_uses): Likewise.
14050 * tree-vect-patterns.c (type_conversion_p, adjust_bool_stmts)
14051 (vect_get_load_store_mask): Likewise.
14052 * tree-vect-slp.c (vect_get_place_in_interleaving_chain)
14053 (vect_analyze_slp_instance, vect_mask_constant_operand_p): Likewise.
14054 * tree-vect-stmts.c (vect_mark_relevant)
14055 (is_simple_and_all_uses_invariant)
14056 (exist_non_indexing_operands_for_use_p, process_use)
14057 (vect_init_vector_1, vect_init_vector, vect_get_vec_def_for_operand_1)
14058 (vect_get_vec_def_for_operand, vect_get_vec_defs)
14059 (vect_finish_stmt_generation_1, vect_finish_replace_stmt)
14060 (vect_finish_stmt_generation, vect_truncate_gather_scatter_offset)
14061 (compare_step_with_zero, vect_get_store_rhs, get_group_load_store_type)
14062 (get_negative_load_store_type, get_load_store_type)
14063 (vect_check_load_store_mask, vect_check_store_rhs)
14064 (vect_build_gather_load_calls, vect_get_strided_load_store_ops)
14065 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
14066 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
14067 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14068 (get_group_alias_ptr_type, vectorizable_store, hoist_defs_of_uses)
14069 (vectorizable_load, vectorizable_condition, vectorizable_comparison)
14070 (vect_analyze_stmt, vect_transform_stmt, vect_remove_stores)
14071 (supportable_widening_operation): Likewise.
14073 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14075 * tree-vect-data-refs.c (vect_describe_gather_scatter_call): Take
14076 a stmt_vec_info instead of a gcall.
14077 (vect_check_gather_scatter): Update call accordingly.
14078 * tree-vect-loop-manip.c (iv_phi_p): Take a stmt_vec_info instead
14080 (vect_can_advance_ivs_p, vect_update_ivs_after_vectorizer)
14081 (slpeel_update_phi_nodes_for_loops):): Update calls accordingly.
14082 * tree-vect-loop.c (vect_transform_loop_stmt): Take a stmt_vec_info
14083 instead of a gimple stmt.
14084 (vect_transform_loop): Update calls accordingly.
14085 * tree-vect-slp.c (vect_split_slp_store_group): Take and return
14086 stmt_vec_infos instead of gimple stmts.
14087 (vect_analyze_slp_instance): Update use accordingly.
14088 * tree-vect-stmts.c (read_vector_array, write_vector_array)
14089 (vect_clobber_variable, vect_stmt_relevant_p, permute_vec_elements)
14090 (vect_use_strided_gather_scatters_p, vect_build_all_ones_mask)
14091 (vect_build_zero_merge_argument, vect_get_gather_scatter_ops)
14092 (vect_gen_widened_results_half, vect_get_loop_based_defs)
14093 (vect_create_vectorized_promotion_stmts, can_vectorize_live_stmts):
14094 Take a stmt_vec_info instead of a gimple stmt and pass stmt_vec_infos
14095 down to subroutines.
14097 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14099 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Change the type
14100 of the worklist from a vector of gimple stmts to a vector of
14102 * tree-vect-stmts.c (vect_mark_relevant, process_use)
14103 (vect_mark_stmts_to_be_vectorized): Likewise
14105 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14107 * tree-vect-loop.c (vect_analyze_loop_operations): Look up the
14108 statement before passing it to vect_analyze_stmt.
14109 (vect_create_epilog_for_reduction): Use a stmt_vec_info to walk
14110 the chain of phi vector definitions. Track the exit phi via its
14112 (vectorizable_reduction): Set cond_stmt_vinfo directly from the
14113 STMT_VINFO_REDUC_DEF.
14114 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Use
14115 stmt_vec_infos to handle the statement chains.
14116 (vect_get_slp_defs): Record the first statement in the node
14117 using a stmt_vec_info.
14118 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Look up
14119 statements here and pass their stmt_vec_info down to subroutines.
14120 (vect_init_vector_1): Hoist call to vinfo_for_stmt and pass it
14121 down to vect_finish_stmt_generation.
14122 (vect_init_vector, vect_get_vec_defs, vect_finish_replace_stmt)
14123 (vect_finish_stmt_generation): Call vinfo_for_stmt and pass
14124 stmt_vec_infos to subroutines.
14125 (vect_remove_stores): Use stmt_vec_infos to handle the statement
14128 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14130 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences):
14131 (vect_check_gather_scatter, vect_create_data_ref_ptr, bump_vector_ptr)
14132 (vect_permute_store_chain, vect_setup_realignment)
14133 (vect_permute_load_chain, vect_shift_permute_load_chain)
14134 (vect_transform_grouped_load): Use stmt_vec_info rather than gimple
14135 stmts internally, and when passing values to other vectorizer routines.
14136 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
14137 * tree-vect-loop.c (vect_analyze_scalar_cycles_1)
14138 (vect_analyze_loop_operations, get_initial_def_for_reduction)
14139 (vect_create_epilog_for_reduction, vectorize_fold_left_reduction)
14140 (vectorizable_reduction, vectorizable_induction)
14141 (vectorizable_live_operation, vect_transform_loop_stmt)
14142 (vect_transform_loop): Likewise.
14143 * tree-vect-patterns.c (vect_reassociating_reduction_p)
14144 (vect_recog_widen_op_pattern, vect_recog_mixed_size_cond_pattern)
14145 (vect_recog_bool_pattern, vect_recog_gather_scatter_pattern): Likewise.
14146 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14147 (vect_slp_analyze_node_operations_1): Likewise.
14148 * tree-vect-stmts.c (vect_mark_relevant, process_use)
14149 (exist_non_indexing_operands_for_use_p, vect_init_vector_1)
14150 (vect_mark_stmts_to_be_vectorized, vect_get_vec_def_for_operand)
14151 (vect_finish_stmt_generation_1, get_group_load_store_type)
14152 (get_load_store_type, vect_build_gather_load_calls)
14153 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
14154 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
14155 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14156 (vectorizable_store, vectorizable_load, vectorizable_condition)
14157 (vectorizable_comparison, vect_analyze_stmt, vect_transform_stmt)
14158 (supportable_widening_operation): Likewise.
14159 (vect_get_vector_types_for_stmt): Likewise.
14160 * tree-vectorizer.h (vect_dr_behavior): Likewise.
14162 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14164 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
14165 (vect_slp_analyze_node_dependences, vect_analyze_data_ref_accesses)
14166 (vect_permute_store_chain, vect_permute_load_chain)
14167 (vect_shift_permute_load_chain, vect_transform_grouped_load): Avoid
14168 repeated stmt_vec_info lookups.
14169 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
14170 (vect_update_ivs_after_vectorizer): Likewise.
14171 * tree-vect-loop.c (vect_is_simple_reduction): Likewise.
14172 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
14173 * tree-vect-patterns.c (adjust_bool_stmts): Likewise.
14174 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14175 (vect_bb_slp_scalar_cost): Likewise.
14176 * tree-vect-stmts.c (get_group_alias_ptr_type): Likewise.
14178 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14180 * tree-vect-data-refs.c (vect_check_gather_scatter): Pass the
14181 gcall rather than the generic gimple stmt to gimple_call_internal_fn.
14182 (vect_get_smallest_scalar_type, can_group_stmts_p): Use dyn_cast
14183 to get gassigns and gcalls, rather than operating on generc gimple
14185 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p)
14186 (vect_mark_stmts_to_be_vectorized, vectorizable_store)
14187 (vectorizable_load, vect_analyze_stmt): Likewise.
14188 * tree-vect-loop.c (vectorizable_reduction): Likewise gphi.
14190 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14192 * tree-vectorizer.h (get_earlier_stmt, get_later_stmt): Take and
14193 return stmt_vec_infos rather than gimple stmts. Do not accept
14195 (vect_find_last_scalar_stmt_in_slp): Return a stmt_vec_info instead
14197 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
14198 Update use of get_later_stmt.
14199 (vect_get_constant_vectors): Update call accordingly.
14200 (vect_schedule_slp_instance): Likewise
14201 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Likewise.
14202 (vect_slp_analyze_instance_dependence): Likewise.
14203 (vect_preserves_scalar_order_p): Update use of get_earlier_stmt.
14205 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14207 * tree-vectorizer.h (stmt_info_for_cost::stmt): Replace with...
14208 (stmt_info_for_cost::stmt_info): ...this new field.
14209 (add_stmt_costs): Update accordingly.
14210 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
14211 (vect_get_known_peeling_cost): Likewise.
14212 (vect_estimate_min_profitable_iters): Likewise.
14213 * tree-vect-stmts.c (record_stmt_cost): Likewise.
14215 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14217 * tree-vectorizer.h (_loop_vec_info::may_misalign_stmts): Change
14218 from an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
14219 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
14221 * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
14223 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14225 * tree-vectorizer.h (_stmt_vec_info::same_dr_stmt): Change from
14226 a gimple stmt to a stmt_vec_info.
14227 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
14229 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14231 * tree-vectorizer.h (vec_info::grouped_stores): Change from
14232 an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
14233 (_loop_vec_info::reduction_chains): Likewise.
14234 * tree-vect-loop.c (vect_fixup_scalar_cycles_with_patterns): Update
14236 * tree-vect-slp.c (vect_analyze_slp): Likewise.
14238 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14240 * tree-vectorizer.h (_stmt_vec_info::first_element): Change from
14241 a gimple stmt to a stmt_vec_info.
14242 (_stmt_vec_info::next_element): Likewise.
14243 * tree-vect-data-refs.c (vect_update_misalignment_for_peel)
14244 (vect_slp_analyze_and_verify_node_alignment)
14245 (vect_analyze_group_access_1, vect_analyze_group_access)
14246 (vect_small_gap_p, vect_prune_runtime_alias_test_list)
14247 (vect_create_data_ref_ptr, vect_record_grouped_load_vectors)
14248 (vect_supportable_dr_alignment): Update accordingly.
14249 * tree-vect-loop.c (vect_fixup_reduc_chain): Likewise.
14250 (vect_fixup_scalar_cycles_with_patterns, vect_is_slp_reduction)
14251 (vect_is_simple_reduction, vectorizable_reduction): Likewise.
14252 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
14253 * tree-vect-slp.c (vect_build_slp_tree_1)
14254 (vect_attempt_slp_rearrange_stmts, vect_supported_load_permutation_p)
14255 (vect_split_slp_store_group, vect_analyze_slp_instance)
14256 (vect_analyze_slp, vect_transform_slp_perm_load): Likewise.
14257 * tree-vect-stmts.c (vect_model_store_cost, vect_model_load_cost)
14258 (get_group_load_store_type, get_load_store_type)
14259 (get_group_alias_ptr_type, vectorizable_store, vectorizable_load)
14260 (vect_transform_stmt, vect_remove_stores): Likewise.
14262 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14264 * tree-vectorizer.h (vect_dr_stmt): Return a stmt_vec_info rather
14265 than a gimple stmt.
14266 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
14267 (vect_slp_analyze_data_ref_dependence, vect_record_base_alignments)
14268 (vect_calculate_target_alignmentm, vect_compute_data_ref_alignment)
14269 (vect_update_misalignment_for_peel, vect_verify_datarefs_alignment)
14270 (vector_alignment_reachable_p, vect_get_data_access_cost)
14271 (vect_get_peeling_costs_all_drs, vect_peeling_hash_get_lowest_cost)
14272 (vect_peeling_supportable, vect_enhance_data_refs_alignment)
14273 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
14274 (vect_analyze_group_access_1, vect_analyze_group_access)
14275 (vect_analyze_data_ref_access, vect_analyze_data_ref_accesses)
14276 (vect_vfa_access_size, vect_small_gap_p, vect_analyze_data_refs)
14277 (vect_supportable_dr_alignment): Remove vinfo_for_stmt from the
14278 result of vect_dr_stmt and use the stmt_vec_info instead of
14279 the associated gimple stmt.
14280 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
14281 (vect_gen_prolog_loop_niters): Likewise.
14282 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
14284 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14286 * tree-vectorizer.h (_slp_tree::stmts): Change from a vec<gimple *>
14287 to a vec<stmt_vec_info>.
14288 * tree-vect-slp.c (vect_free_slp_tree): Update accordingly.
14289 (vect_create_new_slp_node): Take a vec<gimple *> instead of a
14290 vec<stmt_vec_info>.
14291 (_slp_oprnd_info::def_stmts): Change from a vec<gimple *>
14292 to a vec<stmt_vec_info>.
14293 (bst_traits::value_type, bst_traits::value_type): Likewise.
14294 (bst_traits::hash): Update accordingly.
14295 (vect_get_and_check_slp_defs): Change the stmts parameter from
14296 a vec<gimple *> to a vec<stmt_vec_info>.
14297 (vect_two_operations_perm_ok_p, vect_build_slp_tree_1): Likewise.
14298 (vect_build_slp_tree): Likewise.
14299 (vect_build_slp_tree_2): Likewise. Update uses of
14300 SLP_TREE_SCALAR_STMTS.
14301 (vect_print_slp_tree): Update uses of SLP_TREE_SCALAR_STMTS.
14302 (vect_mark_slp_stmts, vect_mark_slp_stmts_relevant)
14303 (vect_slp_rearrange_stmts, vect_attempt_slp_rearrange_stmts)
14304 (vect_supported_load_permutation_p, vect_find_last_scalar_stmt_in_slp)
14305 (vect_detect_hybrid_slp_stmts, vect_slp_analyze_node_operations_1)
14306 (vect_slp_analyze_node_operations, vect_slp_analyze_operations)
14307 (vect_bb_slp_scalar_cost, vect_slp_analyze_bb_1)
14308 (vect_get_constant_vectors, vect_get_slp_defs)
14309 (vect_transform_slp_perm_load, vect_schedule_slp_instance)
14310 (vect_remove_slp_scalar_calls, vect_schedule_slp): Likewise.
14311 (vect_analyze_slp_instance): Build up a vec of stmt_vec_infos
14312 instead of gimple stmts.
14313 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Change
14314 the stores parameter for a vec<gimple *> to a vec<stmt_vec_info>.
14315 (vect_slp_analyze_instance_dependence): Update uses of
14316 SLP_TREE_SCALAR_STMTS.
14317 (vect_slp_analyze_and_verify_node_alignment): Likewise.
14318 (vect_slp_analyze_and_verify_instance_alignment): Likewise.
14319 * tree-vect-loop.c (neutral_op_for_slp_reduction): Likewise.
14320 (get_initial_defs_for_reduction): Likewise.
14321 (vect_create_epilog_for_reduction): Likewise.
14322 (vectorize_fold_left_reduction): Likewise.
14323 * tree-vect-stmts.c (vect_prologue_cost_for_slp_op): Likewise.
14324 (vect_model_simple_cost, vectorizable_shift, vectorizable_load)
14325 (can_vectorize_live_stmts): Likewise.
14327 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14329 * tree-vectorizer.h (_loop_vec_info::reductions): Change from an
14330 auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
14331 (vect_force_simple_reduction): Take and return stmt_vec_infos rather
14333 * tree-parloops.c (valid_reduction_p): Take a stmt_vec_info instead
14335 (gather_scalar_reductions): Update after above interface changes.
14336 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
14337 (vect_is_simple_reduction): Take and return stmt_vec_infos rather
14339 (vect_force_simple_reduction): Likewise.
14340 * tree-vect-patterns.c (vect_pattern_recog_1): Update use of
14341 LOOP_VINFO_REDUCTIONS.
14342 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14344 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14346 * tree-vectorizer.h (_stmt_vec_info::reduc_def): Change from
14347 a gimple stmt to a stmt_vec_info.
14348 * tree-vect-loop.c (vect_active_double_reduction_p)
14349 (vect_force_simple_reduction, vectorizable_reduction): Update
14352 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14354 * tree-vectorizer.h (_slp_tree::vec_stmts): Change from a
14355 vec<gimple *> to a vec<stmt_vec_info>.
14356 * tree-vect-loop.c (vect_create_epilog_for_reduction): Change
14357 the reduction_phis argument from a vec<gimple *> to a
14358 vec<stmt_vec_info>.
14359 (vectorizable_reduction): Likewise the phis local variable that
14360 is passed to vect_create_epilog_for_reduction. Update for new type
14361 of SLP_TREE_VEC_STMTS.
14362 (vectorizable_induction): Update for new type of SLP_TREE_VEC_STMTS.
14363 (vectorizable_live_operation): Likewise.
14364 * tree-vect-slp.c (vect_get_slp_vect_defs): Likewise.
14365 (vect_transform_slp_perm_load, vect_schedule_slp_instance): Likewise.
14367 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14369 * tree-vectorizer.h (_stmt_vec_info::vectorized_stmt): Change from
14370 a gimple stmt to a stmt_vec_info.
14371 (vectorizable_condition, vectorizable_live_operation)
14372 (vectorizable_reduction, vectorizable_induction): Pass back the
14373 vectorized statement as a stmt_vec_info.
14374 * tree-vect-data-refs.c (vect_record_grouped_load_vectors): Update
14375 use of STMT_VINFO_VEC_STMT.
14376 * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise,
14377 accumulating the inner phis that feed the STMT_VINFO_VEC_STMT
14378 as stmt_vec_infos rather than gimple stmts.
14379 (vectorize_fold_left_reduction): Change vec_stmt from a gimple stmt
14380 to a stmt_vec_info.
14381 (vectorizable_live_operation): Likewise.
14382 (vectorizable_reduction, vectorizable_induction): Likewise,
14383 updating use of STMT_VINFO_VEC_STMT.
14384 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Update use
14385 of STMT_VINFO_VEC_STMT.
14386 (vect_build_gather_load_calls, vectorizable_bswap, vectorizable_call)
14387 (vectorizable_simd_clone_call, vectorizable_conversion)
14388 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14389 (vectorizable_store, vectorizable_load, vectorizable_condition)
14390 (vectorizable_comparison, can_vectorize_live_stmts): Change vec_stmt
14391 from a gimple stmt to a stmt_vec_info.
14392 (vect_transform_stmt): Update use of STMT_VINFO_VEC_STMT. Pass a
14393 pointer to a stmt_vec_info to the vectorizable_* routines.
14395 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14397 * tree-vectorizer.h (_stmt_vec_info::related_stmt): Change from
14398 a gimple stmt to a stmt_vec_info.
14399 (is_pattern_stmt_p): Update accordingly.
14400 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Likewise.
14401 (vect_record_grouped_load_vectors): Likewise.
14402 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
14403 (vect_fixup_reduc_chain, vect_update_vf_for_slp): Likewise.
14404 (vect_model_reduction_cost): Likewise.
14405 (vect_create_epilog_for_reduction): Likewise.
14406 (vectorizable_reduction, vectorizable_induction): Likewise.
14407 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
14408 Return the stmt_vec_info for the pattern statement.
14409 (vect_set_pattern_stmt): Update use of STMT_VINFO_RELATED_STMT.
14410 (vect_split_statement, vect_mark_pattern_stmts): Likewise.
14411 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
14412 (vect_detect_hybrid_slp, vect_get_slp_defs): Likewise.
14413 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
14414 (vect_get_vec_def_for_operand_1, vectorizable_call): Likewise.
14415 (vectorizable_simd_clone_call, vect_analyze_stmt, new_stmt_vec_info)
14416 (free_stmt_vec_info, vect_is_simple_use): Likewise.
14418 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14420 * tree-vectorizer.h (vect_finish_replace_stmt): Return a stmt_vec_info
14421 (vect_finish_stmt_generation): Likewise.
14422 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
14423 (vect_finish_replace_stmt, vect_finish_stmt_generation): Likewise.
14424 (vect_build_gather_load_calls): Use the return value of the above
14425 functions instead of a separate call to vinfo_for_stmt. Use narrow
14426 scopes for the input gimple stmt and wider scopes for the associated
14427 stmt_vec_info. Use vec_info::lookup_def when setting these
14428 stmt_vec_infos from an SSA_NAME definition.
14429 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
14430 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
14431 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14432 (vectorizable_store, vectorizable_load, vectorizable_condition)
14433 (vectorizable_comparison): Likewise.
14434 * tree-vect-loop.c (vectorize_fold_left_reduction): Likewise.
14435 (vectorizable_reduction): Likewise.
14437 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14439 * tree-vectorizer.h (vect_is_simple_use): Add an optional
14440 stmt_vec_info * parameter before the optional gimple **.
14441 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
14442 (process_use, vect_get_vec_def_for_operand_1): Update callers.
14443 (vect_get_vec_def_for_operand, vectorizable_shift): Likewise.
14444 * tree-vect-loop.c (vectorizable_reduction): Likewise.
14445 (vectorizable_live_operation): Likewise.
14446 * tree-vect-patterns.c (type_conversion_p): Likewise.
14447 (vect_look_through_possible_promotion): Likewise.
14448 (vect_recog_rotate_pattern): Likewise.
14449 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
14451 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14453 * tree-vectorizer.h (stmt_vec_info): Temporarily change from
14454 a typedef to a wrapper class.
14455 (NULL_STMT_VEC_INFO): New macro.
14456 (vec_info::stmt_infos): Change to vec<stmt_vec_info>.
14457 (stmt_vec_info::operator*): New function.
14458 (stmt_vec_info::operator gimple *): Likewise.
14459 (set_vinfo_for_stmt): Use NULL_STMT_VEC_INFO.
14460 (add_stmt_costs): Likewise.
14461 * tree-vect-loop-manip.c (iv_phi_p): Likewise.
14462 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
14463 (vect_get_known_peeling_cost): Likewise.
14464 (vect_estimate_min_profitable_iters): Likewise.
14465 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
14466 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Likewise.
14467 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
14468 (vectorizable_store, free_stmt_vec_infos): Likewise.
14469 (new_stmt_vec_info): Change return type of xcalloc to
14472 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14474 * tree-vectorizer.h (vec_info::lookup_single_use): Declare.
14475 * tree-vectorizer.c (vec_info::lookup_single_use): New function.
14476 * tree-vect-loop.c (vectorizable_reduction): Use it instead of
14477 a single_imm_use-based sequence.
14478 * tree-vect-stmts.c (supportable_widening_operation): Likewise.
14480 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14482 * tree-vectorizer.h (vec_info::lookup_def): Declare.
14483 * tree-vectorizer.c (vec_info::lookup_def): New function.
14484 * tree-vect-patterns.c (vect_get_internal_def): Use it.
14485 (vect_widened_op_tree): Likewise.
14486 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
14487 * tree-vect-loop.c (vect_analyze_loop_operations): Likewise.
14488 (vectorizable_reduction): Likewise.
14489 (vect_valid_reduction_input_p): Take a stmt_vec_info instead
14491 (vect_is_slp_reduction): Update calls accordingly. Use
14492 vec_info::lookup_def.
14493 (vect_is_simple_reduction): Likewise
14494 * tree-vect-slp.c (vect_detect_hybrid_slp_1): Use vec_info::lookup_def.
14496 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14498 * tree-vectorizer.h (vec_info::lookup_stmt): Declare.
14499 * tree-vectorizer.c (vec_info::lookup_stmt): New function.
14500 * tree-vect-loop.c (vect_determine_vf_for_stmt): Use it instead
14502 (vect_determine_vectorization_factor, vect_analyze_scalar_cycles_1)
14503 (vect_compute_single_scalar_iteration_cost, vect_analyze_loop_form)
14504 (vect_update_vf_for_slp, vect_analyze_loop_operations)
14505 (vect_is_slp_reduction, vectorizable_induction)
14506 (vect_transform_loop_stmt, vect_transform_loop): Likewise.
14507 * tree-vect-patterns.c (vect_init_pattern_stmt):
14508 (vect_determine_min_output_precision_1, vect_determine_precisions)
14509 (vect_pattern_recog): Likewise.
14510 * tree-vect-stmts.c (vect_analyze_stmt, vect_transform_stmt): Likewise.
14511 * config/powerpcspe/powerpcspe.c (rs6000_density_test): Likewise.
14512 * config/rs6000/rs6000.c (rs6000_density_test): Likewise.
14513 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
14514 (vect_detect_hybrid_slp_1, vect_detect_hybrid_slp_2)
14515 (vect_detect_hybrid_slp): Likewise. Change the walk_stmt_info
14516 info field from a loop to a loop_vec_info.
14518 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14520 * tree-vectorizer.h (stmt_vec_info): Move typedef earlier in file.
14521 (vec_info::add_stmt): Declare.
14522 * tree-vectorizer.c (vec_info::add_stmt): New function.
14523 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Use it.
14524 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Likewise.
14525 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
14526 (vectorizable_induction): Likewise.
14527 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Likewise.
14528 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
14529 (vectorizable_simd_clone_call, vectorizable_store): Likewise.
14530 (vectorizable_load): Likewise.
14531 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
14532 (vect_recog_bool_pattern, vect_recog_mask_conversion_pattern)
14533 (vect_recog_gather_scatter_pattern): Likewise.
14534 (append_pattern_def_seq): Likewise. Remove a check that is
14535 performed by add_stmt itself.
14537 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14539 * tree-vect-loop.c (vectorizable_reduction): Fix an instance in
14540 which make_ssa_name was called with new_stmt before new_stmt
14543 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14545 * tree-vect-loop.c (vect_valid_reduction_input_p): New function,
14547 (vect_is_slp_reduction): ...here...
14548 (vect_is_simple_reduction): ...and here. Remove repetition of tests
14549 that are already known to be false.
14551 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14553 * tree-vectorizer.h (vect_free_slp_instance): Add a final_p parameter.
14554 * tree-vect-slp.c (vect_free_slp_tree): Likewise. Don't update
14555 STMT_VINFO_NUM_SLP_USES when it's true.
14556 (vect_free_slp_instance): Add a final_p parameter and pass it to
14557 vect_free_slp_tree.
14558 (vect_build_slp_tree_2): Update call to vect_free_slp_instance.
14559 (vect_analyze_slp_instance): Likewise.
14560 (vect_slp_analyze_operations): Likewise.
14561 (vect_slp_analyze_bb_1): Likewise.
14562 * tree-vectorizer.c (vec_info): Likewise.
14563 * tree-vect-loop.c (vect_transform_loop): Likewise.
14565 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14567 * tree-vect-loop.c (vectorizable_reduction): Assert that the
14568 function is not called for second and subsequent members of
14571 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14573 * tree-vect-loop.c (get_initial_def_for_reduction): Move special
14574 cases for nested loops from here to ...
14575 (vect_create_epilog_for_reduction): ...here. Only call
14576 vect_is_simple_use for inner-loop reductions.
14578 2018-07-31 Martin Liska <mliska@suse.cz>
14580 PR gcov-profile/85338
14581 PR gcov-profile/85350
14582 PR gcov-profile/85372
14583 * profile.c (struct location_triplet): New.
14584 (struct location_triplet_hash): Likewise.
14585 (output_location): Do not output a BB that
14586 is already recorded for a line.
14587 (branch_prob): Use streamed_locations.
14589 2018-07-31 Martin Liska <mliska@suse.cz>
14591 PR gcov-profile/85370
14592 * coverage.c (coverage_begin_function): Do not mark target
14593 clones as artificial functions.
14595 2018-07-31 Martin Liska <mliska@suse.cz>
14597 PR gcov-profile/83813
14598 PR gcov-profile/84758
14599 PR gcov-profile/85217
14600 PR gcov-profile/85332
14601 * profile.c (branch_prob): Do not record GOTO expressions
14602 for GIMPLE statements which locations are already streamed.
14604 2018-07-31 Olivier Hainque <hainque@adacore.com>
14606 * gcc.c (handle_spec_function): Accept a soft_matched_part
14607 argument, as do_spec_1. Pass it down to ...
14608 (eval_spec_function): Accept a soft_matched_part argument,
14609 and pass it down to ...
14610 (do_spec_2): Accept a soft_matched_part argument, and pass
14611 it down to do_spec_1.
14612 (do_spec_1): Pass soft_matched_part to handle_spec_function.
14613 (handle_braces): Update call to handle_spec_function.
14614 (driver::set_up_specs): Update calls to do_spec_2.
14615 (compare_debug_dump_opt_spec_function): Likewise.
14616 (compare_debug_self_opt_spec_function): Likewise.
14618 2018-07-31 Olivier Hainque <hainque@adacore.com>
14620 * common.opt (nolibc): New option.
14621 * doc/invoke.texi (Link Options): Document it.
14622 * gcc.c (LINK_GCC_C_SEQUENCE_SPEC): Honor nolibc.
14623 * config/alpha/linux.h: Likewise.
14624 * config/arc/elf.h: Likewise.
14625 * config/arm/uclinux-elf.h: Likewise.
14626 * config/arm/unknown-elf.h: Likewise.
14627 * config/avr/avrlibc.h: Likewise.
14628 * config/bfin/bfin.h: Likewise.
14629 * config/bfin/linux.h: Likewise.
14630 * config/bfin/uclinux.h: Likewise.
14631 * config/darwin.h: Likewise.
14632 * config/darwin10.h: Likewise.
14633 * config/darwin12.h: Likewise.
14634 * config/gnu-user.h: Likewise.
14635 * config/lm32/uclinux-elf.h: Likewise.
14636 * config/pa/pa-hpux11.h: Likewise.
14637 * config/pa/pa64-hpux.h: Likewise.
14638 * config/sparc/sparc.h: Likewise.
14640 2018-07-31 Olivier Hainque <hainque@adacore.com>
14642 * gcc.c (getenv_spec_function): Prepend '/' to value for allowed
14643 undefined variables.
14645 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
14648 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
14649 instead of GEN_INT.
14651 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
14653 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
14654 terminated string literal.
14656 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
14658 PR rtl-optimization/85160
14659 * combine.c (is_just_move): New function.
14660 (try_combine): Allow combining two instructions into two if neither of
14661 the original instructions was a move.
14663 2018-07-30 Alexander Monakov <amonakov@ispras.ru>
14666 * doc/extend.texi (Global Register Variables): Discourage use of type
14668 (Local Register Variables): Likewise.
14670 2018-07-30 Richard Sandiford <richard.sandiford@arm.com>
14672 PR tree-optimization/86506
14673 * hwint.h (ceil_log2): Resync with hwint.c implementation.
14675 2018-07-30 Ilya Leoshkevich <iii@linux.ibm.com>
14678 * lra-constraints.c (spill_hard_reg_in_range): When selecting the
14679 hard_regno, make sure no insn between `from` and `to` clobbers it.
14681 2018-07-30 Cesar Philippidis <cesar@codesourcery.com>
14682 Tom de Vries <tdevries@suse.de>
14684 * config/nvptx/nvptx.c (PTX_GANG_DEFAULT): Rename to ...
14685 (PTX_DEFAULT_RUNTIME_DIM): ... this.
14686 (nvptx_goacc_validate_dims): Set default worker and gang dims to
14687 PTX_DEFAULT_RUNTIME_DIM.
14688 (nvptx_dim_limit): Ignore GOMP_DIM_WORKER.
14690 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
14692 * config/pa/pa.c (pa_output_addr_vec): Align address table.
14693 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
14694 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
14696 2018-07-27 Michael Meissner <meissner@linux.ibm.com>
14698 * config/rs6000/constraints.md (wG constraint): Delete, no longer
14700 * config/rs6000/predicates.md (p9_fusion_reg_operand): Rename
14701 predicate to reflect toc fusion has been deleted.
14702 (toc_fusion_mem_raw): Delete, no longer used.
14703 (toc_fusion_mem_wrapped): Likewise.
14704 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete toc
14706 * config/rs6000/rs6000-protos.h (fusion_wrap_memory_address):
14707 Delete, no longer used.
14708 * config/rs6000/rs6000.c (struct rs6000_reg_addr): Delete fields
14709 meant to be used for toc fusion.
14710 (rs6000_debug_print_mode): Delete toc fusion debugging.
14711 (rs6000_debug_reg_global): Likewise.
14712 (rs6000_init_hard_regno_mode_ok): Delete setting up fields for toc
14713 fusion and secondary reload support that were never used.
14714 (rs6000_option_override_internal): Delete TOC fusion, that was only
14715 partially defined, and it did not work unless you also used the
14717 (rs6000_legitimate_address_p): Delete TOC fusion support.
14718 (rs6000_opt_masks): Likewise.
14719 (fusion_wrap_memory_address): Delete function, no longer used.
14720 (fusion_split_address); Delete TOC fusion support.
14721 * config/rs6000/rs6000.h (TARGET_TOC_FUSION_INT): Delete, no
14722 longer used with toc fusion being deleted.
14723 (TARGET_TOC_FUSION_FP): Likewise.
14724 * config/rs6000/rs6000.md (UNSPEC_FUSION_ADDIS): Delete TOC fusion
14726 (toc fusion spliter): Delete TOC fusion support.
14727 (toc_fusionload_<mode>): Likewise.
14728 (toc_fusionload_di): Likewise.
14729 (fusion_gpr_load_<mode>): Delete generator function, this insn no
14730 longer needs to be named. Rename predicate to delete TOC fusion.
14731 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
14732 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
14733 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
14734 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
14735 (p9 fusion peephole2s): Rename predicate to delete TOC fusion.
14737 2018-07-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
14739 * doc/extend.texi (Basic PowerPC Built-in Functions Available on
14740 ISA 2.05): Replace __uint128_t with __uint128 and __int128_t with
14741 __int128 in built-in function prototypes.
14742 (PowerPC AltiVec Built-in Functions on ISA 2.07): Likewise.
14743 (PowerPC AltiVec Built-in Functions on ISA 3.0): Likewise.
14745 2018-07-27 Martin Sebor <msebor@redhat.com>
14747 PR tree-optimization/86696
14748 * tree-ssa-strlen.c (get_min_string_length): Handle all integer
14749 types, including enums.
14750 (handle_char_store): Be prepared for the above function to fail.
14752 2018-07-26 Qing Zhao <qing.zhao@oracle.com>
14754 * builtins.c (inline_expand_builtin_string_cmp): Disable inlining
14755 when optimization level is lower than 2 or optimize for size.
14757 2018-07-26 Martin Sebor <msebor@redhat.com>
14759 PR tree-optimization/86043
14760 PR tree-optimization/86042
14761 * tree-ssa-strlen.c (handle_builtin_memcpy): Handle strict overlaps.
14762 (get_string_cst_length): Rename...
14763 (get_min_string_length): ...to this. Add argument.
14764 (handle_char_store): Extend to handle multi-character stores by
14766 * tree.c (initializer_zerop): Use new argument. Handle MEM_REF.
14767 * tree.h (initializer_zerop): Add argument.
14769 2018-07-26 Jakub Jelinek <jakub@redhat.com>
14771 PR middle-end/86660
14772 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
14773 declare target to variables if they have always,{to,from,tofrom} map
14776 2018-07-26 Martin Liska <mliska@suse.cz>
14779 * lto-wrapper.c: Add linker_output as prefix
14780 for ltrans_output_file.
14782 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
14784 PR rtl-optimization/85805
14785 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
14786 value for hard registers if that was written in the same mode.
14788 2018-07-26 Martin Liska <mliska@suse.cz>
14790 PR gcov-profile/86536
14791 * gcov.c (format_gcov): Use printf format %.*f directly
14792 and do not handle special values.
14794 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
14796 * common/config/arc/arc-common.c (arc_option_optimization_table):
14797 Update default optimizations for size.
14799 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
14801 * config/arc/arc.md (movsf_insn): Add short instruction selection.
14802 * config/arc/constraints.md (CfZ): New constraint.
14803 * config/arc/fpu.md (addssf3_fpu): Use CfZ constraint.
14804 (subsf3_fpu): Likewise.
14805 (cmpsf_fpu): Likewise.
14806 (cmpsf_fpu_uneq): Likewise.
14808 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
14810 * config/arc/arc.c (compact_memory_operand_p): Check for uncached
14812 (arc_is_uncached_mem_p): uncached applies to both the variable and
14815 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
14817 * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Add additional
14820 2018-07-25 David Malcolm <dmalcolm@redhat.com>
14822 * optinfo-emit-json.cc (class optrecord_json_writer): Convert
14823 field "m_scopes" from vec to auto_vec.
14825 2018-07-25 Martin Liska <mliska@suse.cz>
14827 * config/powerpcspe/powerpcspe-protos.h (rs6000_loop_align): Fix
14830 2018-07-25 Richard Biener <rguenther@suse.de>
14833 * dwarf2out.c (dwarf2out_decl): Do not handle nested functions
14834 special wrt context_die late.
14835 (gen_subprogram_die): Re-use DIEs in local scope.
14837 2018-07-25 Richard Sandiford <richard.sandiford@arm.com>
14839 PR tree-optimization/86644
14840 * hwint.c (ceil_log2): Fix comment. Return 0 for 0.
14842 2018-07-25 Martin Liska <mliska@suse.cz>
14844 PR middle-end/86645
14845 * dumpfile.c: And excluded values with TDF_ALL_VALUES.
14846 * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
14848 2018-07-25 Martin Liska <mliska@suse.cz>
14851 * params.def: Explain ASan abbreviation and provide
14852 a documentation link.
14854 2018-07-24 Martin Sebor <msebor@redhat.com>
14856 PR tree-optimization/86622
14857 PR tree-optimization/86532
14858 * builtins.h (string_length): Declare.
14859 * builtins.c (c_strlen): Correct handling of non-constant offsets.
14860 (check_access): Be prepared for non-constant length ranges.
14861 (string_length): Make extern.
14862 * expr.c (string_constant): Only handle the minor non-constant
14863 array index. Use string_constant to compute the length of
14864 a generic string constant.
14866 2018-07-24 Richard Sandiford <richard.sandiford@arm.com>
14868 PR tree-optimization/86618
14869 * tree-vect-stmts.c (vectorizable_call): Don't take the address
14870 of LOOP_VINFO_MASKS (loop_vinfo) when loop_vinfo is null.
14872 2018-07-24 David Malcolm <dmalcolm@redhat.com>
14874 PR tree-optimization/86636
14875 * json.cc (json::object::set): Fix comment. Add assertions.
14876 (json::array::append): Move here from json.h. Add comment and an
14878 (json::string::string): Likewise.
14879 * json.h (json::array::append): Move to json.cc.
14880 (json::string::string): Likewise.
14881 * optinfo-emit-json.cc
14882 (optrecord_json_writer::impl_location_to_json): Assert that we
14883 aren't attempting to write out UNKNOWN_LOCATION, or an ad-hoc
14884 wrapper around it. Expand the location once, rather than three
14886 (optrecord_json_writer::inlining_chain_to_json): Fix the check for
14887 UNKNOWN_LOCATION, to use LOCATION_LOCUS to look through ad-hoc
14889 (optrecord_json_writer::optinfo_to_json): Likewise, in four
14890 places. Fix some overlong lines.
14892 2018-07-24 Matthew Malcomson <matthew.malcomson@arm.com>
14894 * config/aarch64/aarch64-simd.md
14895 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>): Split into...
14896 (aarch64_<ANY_EXTEND:su>subw<mode>): ... This...
14897 (aarch64_<ANY_EXTEND:su>addw<mode>): ... And this.
14898 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>_internal): Split into...
14899 (aarch64_<ANY_EXTEND:su>subw<mode>_internal): ... This...
14900 (aarch64_<ANY_EXTEND:su>addw<mode>_internal): ... And this.
14901 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>_internal): Split into...
14902 (aarch64_<ANY_EXTEND:su>subw2<mode>_internal): ... This...
14903 (aarch64_<ANY_EXTEND:su>addw2<mode>_internal): ... And this.
14905 2018-07-24 Jakub Jelinek <jakub@redhat.com>
14907 PR middle-end/86627
14908 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
14909 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
14910 and abs_d == d, do the power of two handling if profitable.
14912 2018-07-24 Richard Biener <rguenther@suse.de>
14914 * match.pd: Add BIT_FIELD_REF canonicalizations.
14916 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
14919 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
14921 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
14923 * gimple-fold.c (gimple_fold_builtin_printf): Don't create a not NUL
14924 terminated STRING_CST object.
14926 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
14928 hsa-dump.c (dump_hsa_symbol): Avoid out of scope access to buf.
14930 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
14932 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Adjust.
14933 * config/rs6000/rs6000-protos.h (rs6000_split_v4si_init): Delete.
14934 * config/rs6000/rs6000.c (rs6000_expand_vector_init): Always force
14935 the elements into a register.
14936 (rs6000_split_v4si_init_di_reg): Delete.
14937 (rs6000_split_v4si_init): Delete.
14938 * config/rs6000/vsx.md (unspec): Delete UNSPEC_VSX_VEC_INIT.
14939 (vsx_init_v4si): Rewrite as a define_expand.
14941 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
14943 * config/rs6000/rs6000.md (splitters for rldimi and rlwimi with the
14944 zero_extend argument from memory): New.
14946 2018-07-22 Martin Sebor <msebor@redhat.com>
14949 * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Avoid
14950 diagnosing calls with unknown arguments unless -Walloca-larger-than
14951 is restricted to less than PTRDIFF_MAX bytes.
14953 2018-07-22 Gerald Pfeifer <gerald@pfeifer.com>
14955 * doc/gcov.texi (Invoking Gcov): Editorial changes.
14957 2018-07-20 David Malcolm <dmalcolm@redhat.com>
14959 * pretty-print.c (text_info::set_location): Remove redundant
14960 "line_table" parameter from call to rich_location::set_range.
14962 2018-07-20 Martin Sebor <msebor@redhat.com>
14964 PR middle-end/82063
14965 * builtins.c (expand_builtin_alloca): Adjust.
14966 * calls.c (alloc_max_size): Simplify.
14967 * cgraphunit.c (cgraph_node::expand): Adjust.
14968 * common.opt (larger_than_size, warn_frame_larger_than): Remove
14970 (frame_larger_than_size): Same.
14971 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Change options
14972 to take a HOST_WIDE_INT argument and accept a byte-size suffix.
14974 * doc/invoke.texi (GCC Command Options): Document option arguments.
14975 Explain byte-size arguments and suffixes.
14976 (-Wvla-larger-than, -Wno-alloc-size-larger-than): Update.
14977 (-Wno-alloca-larger-than, -Wno-vla-larger-than): Same.
14978 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Same.
14979 * doc/options.texi (UInteger): Expand.
14980 (Host_Wide_Int, ByteSize): Document new properties.
14981 * final.c (final_start_function_1): Include sizes in an error message.
14982 * function.c (frame_offset_overflow): Same.
14983 * gimple-ssa-warn-alloca.c (pass_walloca::gate): Adjust.
14984 (alloca_call_type_by_arg): Change function argument to HOST_WIDE_INT.
14985 Diagnose unbounded alloca calls only for limits of less than
14987 (alloca_call_type): Adjust. Diagnose possibly out-of-bounds alloca
14988 calls and VLA size only for limits of less than PTRDIFF_MAX. Same
14990 (pass_walloca::execute): Adjust. Diagnose alloca calls in loops
14991 only for limits of less than PTRDIFF_MAX.
14992 * langhooks-def.h (lhd_handle_option): Change function argument
14994 * langhooks.c (lhd_handle_option): Same.
14995 * langhooks.h (handle_option): Same.
14996 * opt-functions.awk (switch_bit_fields): Handle Host_Wide_Int and
14998 (var_type, var_type_struct): Same.
14999 (var_set): Handle ByteSize flag.
15000 * optc-gen.awk: Add comments to output to ease debugging. Make
15001 use of HOST_WIDE_INT where appropriate.
15002 * opts-gen-save.awk: Use %lx to format unsigned long.
15003 * opth-gen.awk: Change function argument to HOST_WIDE_INT.
15004 * opts-common.c (integral_argument): Return HOST_WIDE_INT and add
15005 arguments. Parse bytes-size suffixes.
15006 (enum_arg_to_value): Change function argument to HOST_WIDE_INT.
15007 (enum_value_to_arg): Same.
15008 (decode_cmdline_option): Handle cl_host_wide_int. Adjust.
15009 (handle_option): Adjust.
15010 (generate_option): Change function argument to HOST_WIDE_INT.
15011 (cmdline_handle_error): Adjust.
15012 (read_cmdline_option): Change function argument to HOST_WIDE_INT.
15013 (set_option): Change function argument to HOST_WIDE_INT.
15014 (option_enabled): Handle cl_host_wide_int.
15015 (get_option_state): Handle CLVC_SIZE.
15016 (control_warning_option): Same.
15017 * opts.c (common_handle_option): Change function argument to
15018 HOST_WIDE_INT. Remove handling of OPT_Walloca_larger_than_ and
15019 OPT_Wvla_larger_than_.
15020 * opts.h (enum cl_var_type): Add an enumerator.
15021 * stor-layout.c (layout_decl): Print a more meaningful warning.
15022 * toplev.c (output_stack_usage): Adjust.
15024 2018-07-20 Qing Zhao <qing.zhao@oracle.com>
15026 * builtins.c (expand_builtin_memcmp): Delete the last parameter for
15027 call to inline_expand_builtin_string_cmp.
15028 (expand_builtin_strcmp): Likewise.
15029 (expand_builtin_strncmp): Likewise.
15030 (inline_string_cmp): Delete the last parameter, change char_type_node
15031 to unsigned_char_type_node for strcmp/strncmp, add conversions to the
15033 (inline_expand_builtin_string_cmp): Delete the last parameter, give up
15034 the inlining expansion on target where the type of the call has same or
15035 narrower precision than unsigned char.
15037 2018-07-20 David Malcolm <dmalcolm@redhat.com>
15039 * Makefile.in (OBJS): Add json.o and optinfo-emit-json.o.
15040 (CFLAGS-optinfo-emit-json.o): Define TARGET_NAME.
15041 * common.opt (fsave-optimization-record): New option.
15042 * coretypes.h (struct kv_pair): Move here from dumpfile.c.
15043 * doc/invoke.texi (-fsave-optimization-record): New option.
15044 * dumpfile.c: Include "optinfo-emit-json.h".
15045 (struct kv_pair): Move to coretypes.h.
15046 (optgroup_options): Make non-static.
15047 (dump_context::end_scope): Call
15048 optimization_records_maybe_pop_dump_scope.
15049 * dumpfile.h (optgroup_options): New decl.
15050 * json.cc: New file.
15051 * json.h: New file.
15052 * optinfo-emit-json.cc: New file.
15053 * optinfo-emit-json.h: New file.
15054 * optinfo.cc: Include "optinfo-emit-json.h".
15055 (optinfo::emit): Call optimization_records_maybe_record_optinfo.
15056 (optinfo_enabled_p): Check optimization_records_enabled_p.
15057 (optinfo_wants_inlining_info_p): Likewise.
15058 * optinfo.h: Update comment.
15059 * profile-count.c (profile_quality_as_string): New function.
15060 * profile-count.h (profile_quality_as_string): New decl.
15061 (profile_count::quality): New accessor.
15062 * selftest-run-tests.c (selftest::run_tests): Call json_cc_tests
15063 and optinfo_emit_json_cc_tests.
15064 * selftest.h (selftest::json_cc_tests): New decl.
15065 (selftest::optinfo_emit_json_cc_tests): New decl.
15066 * toplev.c: Include "optinfo-emit-json.h".
15067 (compile_file): Call optimization_records_finish.
15068 (do_compile): Call optimization_records_start.
15069 * tree-ssa-live.c: Include optinfo.h.
15070 (remove_unused_scope_block_p): Retain inlining information if
15071 optinfo_wants_inlining_info_p returns true.
15073 2018-07-20 Richard Biener <rguenther@suse.de>
15076 * dwarf2out.c (dwarf2out_die_ref_for_decl): Test in_lto_p
15077 to cover -flto-partition=none.
15079 2018-07-20 Martin Liska <mliska@suse.cz>
15081 * tree.h (DECL_LOCATION_RANGE): Remove unused macro.
15082 (get_decl_source_range): Remove unused function.
15084 2018-07-20 Richard Biener <rguenther@suse.de>
15086 * tree-ssa-sccvn.h (struct vn_nary_op_s): Add next member.
15087 (struct vn_phi_s): Likewise.
15088 (struct vn_reference_s): Likewise.
15089 * tree-ssa-sccvn.c (vn_nary_op_hasher::equal): Add shortcut
15090 for searching the slot of an entry known to be in the hash itself.
15091 (vn_phi_hasher::equal): Likewise.
15092 (vn_reference_hasher::equal): Likewise.
15093 (last_inserted_ref, last_inserted_phi, last_inserted_nary): New
15095 (optimistic_info, current_info): Remove, keeping only valid_info.
15096 (vn_reference_lookup_1): Remove fallback lookup.
15097 (vn_reference_lookup_2): Likewise.
15098 (vn_nary_op_lookup_1): Likewise.
15099 (vn_phi_lookup): Likewise.
15100 (vn_nary_build_or_lookup_1): Make sure to not chain the built
15102 (vn_reference_insert): Adjust, chain the inserted hash element
15103 at last_inserted_ref.
15104 (vn_reference_insert_pieces): Likewise.
15105 (visit_reference_op_call): Likewise.
15106 (vn_nary_op_insert_into): Chain the inserted hash element at
15107 last_inserted_nary.
15108 (vn_nary_op_insert_pieces): Adjust.
15109 (vn_nary_op_insert): Likewise.
15110 (vn_nary_op_insert_stmt): Likewise.
15111 (vn_phi_insert): Adjust, chain the inserted hash element at
15113 (process_scc): Remove clearing and copying the optimistic
15114 table. Instead remove elements inserted during an optimistic
15115 iteration from the single table we maintain.
15116 (init_scc_vn): Adjust.
15117 (free_scc_vn): Likewise.
15118 (sccvn_dom_walker::record_cond): Likewise.
15119 (sccvn_dom_walker::after_dom_children): Likewise.
15121 2018-07-19 Martin Sebor <msebor@redhat.com>
15123 PR tree-optimization/84047
15124 PR tree-optimization/83776
15125 * tree-vrp.c (vrp_prop::check_mem_ref): New function.
15126 (check_array_bounds): Call it.
15128 2018-07-19 Martin Sebor <msebor@redhat.com>
15130 * align.h (align_flags): Use member initialization.
15132 2018-07-19 David Malcolm <dmalcolm@redhat.com>
15134 * Makefile.in (OBJS): Add optinfo.o.
15135 * coretypes.h (class symtab_node): New forward decl.
15136 (struct cgraph_node): New forward decl.
15137 (class varpool_node): New forward decl.
15138 * dump-context.h: New file.
15139 * dumpfile.c: Include "optinfo.h", "dump-context.h", "cgraph.h",
15141 (refresh_dumps_are_enabled): Use optinfo_enabled_p.
15142 (set_dump_file): Call dumpfile_ensure_any_optinfo_are_flushed.
15143 (set_alt_dump_file): Likewise.
15144 (dump_context::~dump_context): New dtor.
15145 (dump_gimple_stmt): Move implementation to...
15146 (dump_context::dump_gimple_stmt): ...this new member function.
15147 Add the stmt to any pending optinfo, creating one if need be.
15148 (dump_gimple_stmt_loc): Move implementation to...
15149 (dump_context::dump_gimple_stmt_loc): ...this new member function.
15150 Start a new optinfo and add the stmt to it.
15151 (dump_gimple_expr): Move implementation to...
15152 (dump_context::dump_gimple_expr): ...this new member function.
15153 Add the stmt to any pending optinfo, creating one if need be.
15154 (dump_gimple_expr_loc): Move implementation to...
15155 (dump_context::dump_gimple_expr_loc): ...this new member function.
15156 Start a new optinfo and add the stmt to it.
15157 (dump_generic_expr): Move implementation to...
15158 (dump_context::dump_generic_expr): ...this new member function.
15159 Add the tree to any pending optinfo, creating one if need be.
15160 (dump_generic_expr_loc): Move implementation to...
15161 (dump_context::dump_generic_expr_loc): ...this new member
15162 function. Add the tree to any pending optinfo, creating one if
15164 (dump_printf): Move implementation to...
15165 (dump_context::dump_printf_va): ...this new member function. Add
15166 the text to any pending optinfo, creating one if need be.
15167 (dump_printf_loc): Move implementation to...
15168 (dump_context::dump_printf_loc_va): ...this new member function.
15169 Start a new optinfo and add the stmt to it.
15170 (dump_dec): Move implementation to...
15171 (dump_context::dump_dec): ...this new member function. Add the
15172 value to any pending optinfo, creating one if need be.
15173 (dump_context::dump_symtab_node): New member function.
15174 (dump_context::get_scope_depth): New member function.
15175 (dump_context::begin_scope): New member function.
15176 (dump_context::end_scope): New member function.
15177 (dump_context::ensure_pending_optinfo): New member function.
15178 (dump_context::begin_next_optinfo): New member function.
15179 (dump_context::end_any_optinfo): New member function.
15180 (dump_context::s_current): New global.
15181 (dump_context::s_default): New global.
15182 (dump_scope_depth): Delete global.
15183 (dumpfile_ensure_any_optinfo_are_flushed): New function.
15184 (dump_symtab_node): New function.
15185 (get_dump_scope_depth): Reimplement in terms of dump_context.
15186 (dump_begin_scope): Likewise.
15187 (dump_end_scope): Likewise.
15188 (selftest::temp_dump_context::temp_dump_context): New ctor.
15189 (selftest::temp_dump_context::~temp_dump_context): New dtor.
15190 (selftest::verify_item): New function.
15191 (ASSERT_IS_TEXT): New macro.
15192 (ASSERT_IS_TREE): New macro.
15193 (ASSERT_IS_GIMPLE): New macro.
15194 (selftest::test_capture_of_dump_calls): New test.
15195 (selftest::dumpfile_c_tests): Call it.
15196 * dumpfile.h (dump_printf, dump_printf_loc, dump_basic_block)
15197 (dump_generic_expr_loc, dump_generic_expr, dump_gimple_stmt_loc)
15198 (dump_gimple_stmt, dump_dec): Gather these related decls and add a
15199 descriptive comment.
15200 (dump_function, print_combine_total_stats, enable_rtl_dump_file)
15201 (dump_node, dump_bb): Move these unrelated decls.
15202 (class dump_manager): Add leading comment.
15203 * optinfo.cc: New file.
15204 * optinfo.h: New file.
15206 2018-07-19 Michael Collison <michael.collison@arm.com>
15207 Richard Henderson <rth@redhat.com>
15209 * config/aarch64/aarch64.md (subv<GPI>4, usubv<GPI>4): New patterns.
15210 (subti): Handle op1 zero.
15211 (subvti4, usub4ti4): New.
15212 (*sub<GPI>3_compare1_imm): New.
15213 (sub<GPI>3_carryinCV): New.
15214 (*sub<GPI>3_carryinCV_z1_z2, *sub<GPI>3_carryinCV_z1): New.
15215 (*sub<GPI>3_carryinCV_z2, *sub<GPI>3_carryinCV): New.
15217 2018-07-19 Michael Collison <michael.collison@arm.com>
15218 Richard Henderson <rth@redhat.com>
15220 * config/aarch64/aarch64.md: (addv<GPI>4, uaddv<GPI>4): New.
15221 (addti3): Create simpler code if low part is already known to be 0.
15222 (addvti4, uaddvti4): New.
15223 (*add<GPI>3_compareC_cconly_imm): New.
15224 (*add<GPI>3_compareC_cconly): New.
15225 (*add<GPI>3_compareC_imm): New.
15226 (*add<GPI>3_compareC): Rename from add<GPI>3_compare1; do not
15227 handle constants within this pattern..
15228 (*add<GPI>3_compareV_cconly_imm): New.
15229 (*add<GPI>3_compareV_cconly): New.
15230 (*add<GPI>3_compareV_imm): New.
15231 (add<GPI>3_compareV): New.
15232 (add<GPI>3_carryinC, add<GPI>3_carryinV): New.
15233 (*add<GPI>3_carryinC_zero, *add<GPI>3_carryinV_zero): New.
15234 (*add<GPI>3_carryinC, *add<GPI>3_carryinV): New.
15235 ((*add<GPI>3_compareC_cconly_imm): Replace 'ne' operator
15236 with 'comparison' operator.
15237 (*add<GPI>3_compareV_cconly_imm): Ditto.
15238 (*add<GPI>3_compareV_cconly): Ditto.
15239 (*add<GPI>3_compareV_imm): Ditto.
15240 (add<GPI>3_compareV): Ditto.
15241 (add<mode>3_carryinC): Ditto.
15242 (*add<mode>3_carryinC_zero): Ditto.
15243 (*add<mode>3_carryinC): Ditto.
15244 (add<mode>3_carryinV): Ditto.
15245 (*add<mode>3_carryinV_zero): Ditto.
15246 (*add<mode>3_carryinV): Ditto.
15248 2018-07-19 Michael Collison <michael.collison@arm.com>
15249 Richard Henderson <rth@redhat.com>
15251 * config/aarch64/aarch64-modes.def (CC_V): New.
15252 * config/aarch64/aarch64-protos.h
15253 (aarch64_addti_scratch_regs): Declare
15254 (aarch64_subvti_scratch_regs): Declare.
15255 (aarch64_expand_subvti): Declare.
15256 (aarch64_gen_unlikely_cbranch): Declare
15257 * config/aarch64/aarch64.c (aarch64_select_cc_mode): Test
15258 for signed overflow using CC_Vmode.
15259 (aarch64_get_condition_code_1): Handle CC_Vmode.
15260 (aarch64_gen_unlikely_cbranch): New function.
15261 (aarch64_addti_scratch_regs): New function.
15262 (aarch64_subvti_scratch_regs): New function.
15263 (aarch64_expand_subvti): New function.
15265 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15267 * config/aarch64/aarch64-option-extensions.def: New entry for profile
15269 * config/aarch64/aarch64.h (AARCH64_FL_PROFILE): New.
15270 * doc/invoke.texi (aarch64-feature-modifiers): New entry for profile
15273 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15276 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
15277 address check not strict.
15279 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15281 * config/aarch64/aarch64-simd.md (aarch64_simd_mov<VQ:mode>): Replace
15283 (store_pair_lanes<mode>): Likewise.
15284 * config/aarch64/aarch64-protos.h (aarch64_addr_query_type): Add new
15285 enum value 'ADDR_QUERY_LDP_STP_N'.
15286 * config/aarch64/aarch64.c (aarch64_addr_query_type): Likewise.
15287 (aarch64_print_address_internal): Add declaration.
15288 (aarch64_print_ldpstp_address): Remove.
15289 (aarch64_classify_address): Adapt mode for 'ADDR_QUERY_LDP_STP_N'.
15290 (aarch64_print_operand): Change printing of 'y'.
15291 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Use
15292 new enum value 'ADDR_QUERY_LDP_STP_N', don't hardcode mode and use
15293 'true' rather than '1'.
15294 * config/aarch64/constraints.md (Uml): Likewise.
15295 (Uml): Rename to Umn.
15298 2018-07-19 Richard Biener <rguenther@suse.de>
15300 * tree-ssa-sccvn.h (struct vn_phi_s): Make phiargs member
15302 * tree-ssa-sccvn.c: Remove alloc-pool.h use.
15303 (vn_phi_hasher): Derive from nofree_ptr_hash and remove remove method.
15304 (vn_reference_hasher): Likewise.
15305 (struct vn_tables_s): Remove obstack and alloc-pool members.
15306 (vn_tables_obstack, vn_tables_insert_obstack): New global obstacks.
15307 (vn_nary_build_or_lookup_1): Manually build in vn_tables_insert_obstack.
15308 (vn_reference_insert): Allocate from obstack instead of from alloc-pool.
15309 (vn_reference_insert_pieces): Likewise.
15310 (alloc_vn_nary_op_noinit): Adjust.
15311 (vn_nary_op_insert_stmt): Allocate phiargs in-place.
15312 (vn_phi_eq): Adjust.
15313 (shared_lookup_phiargs): Remove.
15314 (vn_phi_lookup): Allocate temporary vn_phi_s on the stack.
15315 (vn_phi_insert): Allocate from obstack instead of from alloc-pool.
15316 (visit_reference_op_call): Likewise.
15317 (copy_nary, copy_phi, copy_reference): Remove.
15318 (process_scc): Rewind the obstack when iterating. Do not
15319 copy the elements to valid_info but just move them from one
15320 hashtable to the other.
15321 (allocate_vn_table): Adjust.
15322 (free_vn_table): Likewise.
15323 (init_scc_vn): Likewise.
15324 (free_scc_vn): Likewise.
15326 2018-07-19 H.J. Lu <hongjiu.lu@intel.com>
15329 * config/i386/i386.c (rest_of_insert_endbranch): Lookup
15330 indirect_return as function type attribute.
15331 (ix86_attribute_table): Change indirect_return to function
15333 * doc/extend.texi: Update indirect_return attribute.
15335 2018-07-19 Aldy Hernandez <aldyh@redhat.com>
15337 * wide-int.h (widest2_int): New.
15338 * gimple-fold.c (arith_overflowed_p): Use it.
15339 * tree.h (widest2_int_cst): New.
15340 * tree-vrp.c (wide_int_binop_overflow): Rename from
15341 vrp_int_const_binop.
15342 Rewrite to work on trees.
15343 (extract_range_from_multiplicative_op_1): Abstract code to...
15344 (wide_int_range_min_max): ...here.
15345 (wide_int_range_cross_product): ...and here.
15346 (extract_range_from_binary_expr_1): Abstract overflow code to...
15347 (wide_int_range_mult_wrapping): ...here.
15348 * tree-vrp.h (wide_int_range_cross_product): New.
15349 (wide_int_range_mult_wrapping): New.
15351 2018-07-19 Andrew Senkevich <andrew.senkevich@intel.com>
15352 Julia Koval <julia.koval@intel.com>
15354 * config/i386/x86-tune-costs.h (skylake_memcpy,
15355 skylake_memset): Replace rep_prefix with unrolling for size 512.
15357 2018-07-18 Kugan Vivekanandarajah <kuganv@linaro.org>
15359 PR middle-end/86544
15360 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): Handle
15361 comparision with EQ_EXPR in last stmt.
15363 2018-07-18 Kelvin Nilsen <kelvin@gcc.gnu.org>
15365 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Rename
15366 this subsection to "PowerPC AltiVec/VSX Built-in Functions".
15367 (PowerPC AltiVec/VSX Built-in Functions): New name for subsection
15368 previously known as "PowerPC AltiVec Built-in Functions". Move
15369 some material to new subsubsections "PowerPC AltiVec Built-in
15370 Functions on ISA 2.06" and "PowerPC AltiVec Built-in Functions on
15372 (PowerPC Altivec Built-in Functions on ISA 2.05): New subsubsection.
15373 (PowerPC Altivec Built-in Functions on ISA 2.06): Likewise.
15374 (PowerPC Altivec Built-in Functions on ISA 2.07): Likewise.
15375 (PowerPC Altivec Built-in Functions on ISA 3.0): Likewise.
15377 2018-07-18 Richard Biener <rguenther@suse.de>
15379 PR tree-optimization/86557
15380 * tree-vect-patterns.c (vect_recog_divmod_pattern): Also handle
15383 2018-07-18 Ilya Leoshkevich <iii@linux.ibm.com>
15385 * config/s390/s390.c (s390_function_profiler): Generate CFI.
15387 2018-07-17 Jeff Law <law@redhat.com>
15389 * config/arm/arm.c (get_label_padding): Update for recent
15390 changes to label_to_alignment.
15392 PR tree-optimization/86010
15393 * tree-ssa-dse.c (compute_trims): Fix typo/thinko.
15395 * config/mips/mips.c (vr4130_align_insns): Update for recent
15396 changes to label_to_alignment.
15398 * config/frv/frv.c (frv_label_align): Update for recent changes
15399 to label_to_alignment.
15401 * config/nios2/nios2.c (nios2_label_align): Update for recent
15402 changes which dropped ALIGN_LABELS_LOG.
15404 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
15406 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
15407 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
15409 2018-07-17 Claudiu Zissulescu <claziss@synopsys.com>
15411 * config/arc/arc.c (arc_label_align): Use align_labels instead of
15412 deprecated align_labels_log.
15414 2018-07-17 Richard Biener <rguenther@suse.de>
15417 * dwarf2out.c (init_sections_and_labels): Always generate
15418 a debug_line_str_section for early LTO debug.
15419 (dwarf2out_finish): Reset debug_line_str_hash output early.
15420 Bump counter for extra dwarf5 .debug_loc labels to not conflict
15422 (dwarf2out_early_finish): Output debug_line_str.
15424 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
15426 * config/s390/s390.c (preferred_la_operand_p): Do not use LA with
15427 index register on z196 or later.
15429 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
15431 * config/s390/s390.c (s390_default_align): Set default function
15433 (s390_override_options_after_change): Call s390_default align.
15434 (s390_option_override_internal): Call s390_default_align.
15435 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define.
15437 2018-07-17 Jakub Jelinek <jakub@redhat.com>
15439 PR middle-end/86542
15440 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
15441 to _looptemp_ clauses, other than the first two.
15443 2018-07-17 Martin Liska <mliska@suse.cz>
15445 * opts.c: Do not enable OPT_falign_* for -Os.
15447 2018-07-17 Martin Liska <mliska@suse.cz>
15449 * align.h (MAX_CODE_ALIGN): New.
15450 (MAX_CODE_ALIGN_VALUE): New.
15451 * common/config/i386/i386-common.c (ix86_handle_option):
15452 (MAX_CODE_ALIGN): Moved to align.h.
15453 * final.c (MAX_CODE_ALIGN): Likewise.
15454 * opts.c (parse_and_check_align_values):
15455 (MAX_CODE_ALIGN): Likewise.
15456 (MAX_CODE_ALIGN_VALUE): Likewise.
15458 2018-07-17 Martin Liska <mliska@suse.cz>
15460 * config/i386/att.h (ASM_OUTPUT_ALIGN): Fix spacing
15461 in order to fulfil coding style.
15462 * config/i386/cygming.h (ASM_OUTPUT_ALIGN): Likewise.
15463 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
15464 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
15465 * config/iq2000/iq2000.h (ASM_OUTPUT_ALIGN): Likewise.
15466 * config/pa/pa.h (ASM_OUTPUT_ALIGN): Likewise.
15467 * config/sparc/sol2.h (ASM_OUTPUT_ALIGN_WITH_NOP): Likewise.
15468 * config/sparc/sparc.h (ASM_OUTPUT_ALIGN): Likewise.
15469 * config/visium/visium.h (ASM_OUTPUT_ALIGN): Likewise.
15470 (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
15472 2018-07-17 Martin Liska <mliska@suse.cz>
15474 * align.h: New file.
15475 * config/alpha/alpha.c (alpha_align_insns_1): Use align_functions
15477 * config/i386/i386.c (ix86_avoid_jump_mispredicts): Use new return type
15478 align_flags of label_to_alignment.
15479 * config/m32r/m32r.h (LOOP_ALIGN): Wrap returned values into
15481 * config/m68k/m68k.c: Do not use removed align_labels_value and
15483 * config/nds32/nds32.h (JUMP_ALIGN): Wrap result into align_flags class.
15484 (LOOP_ALIGN): Likewise.
15485 (LABEL_ALIGN): Likewise.
15486 * config/powerpcspe/powerpcspe.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
15487 Remove not used macro.
15488 (rs6000_loop_align): Change return type to align_flags.
15489 (rs6000_loop_align_max_skip): Remove.
15490 * config/rs6000/rs6000-protos.h (rs6000_loop_align):
15491 Change return type to align_flags.
15492 * config/rs6000/rs6000.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
15493 Remove not used macro.
15494 (rs6000_loop_align): Change return type to align_flags.
15495 (rs6000_loop_align_max_skip): Remove.
15496 * config/rx/rx.h (JUMP_ALIGN): Wrap integer values
15497 * config/rx/rx-protos.h (rx_align_for_label): Make it
15499 * config/rx/rx.c (rx_align_for_label): Change return type
15501 (rx_max_skip_for_label): Remove TARGET_ASM_*_ALIGN_MAX_SKIP
15503 into align_flags class.
15504 (LABEL_ALIGN): Likewise.
15505 (LOOP_ALIGN): Likewise.
15506 * config/s390/s390.c (s390_label_align): Use align_flags
15508 (s390_asm_output_function_label): Likewise.
15509 * config/sh/sh.c (sh_override_options_after_change):
15510 Use align_flags class directly without macros.
15511 (find_barrier): Likewise.
15512 (barrier_align): Likewise.
15513 (sh_loop_align): Likewise.
15514 * config/spu/spu.c (spu_option_override):
15515 Use align_flags_tuple::get_value instead of removed macros.
15516 (spu_sched_init): Likewise.
15517 * config/spu/spu.h (GTY): Likewise.
15518 * config/visium/visium.c (visium_option_override):
15519 Set "8" as default secondary alignment.
15520 * config/visium/visium.h (SUBALIGN_LOG): Define to 3
15521 in order to guarantee secondary alignment of 8.
15522 * coretypes.h: Include align.h header file.
15523 * doc/tm.texi: Remove TARGET_ASM_JUMP_ALIGN_MAX_SKIP,
15524 TARGET_ASM_LOOP_ALIGN_MAX_SKIP, TARGET_ASM_LABEL_ALIGN_MAX_SKIP
15525 and TARGET_ASM_LABEL_ALIGN_AFTER_BARRIER_MAX_SKIP macros.
15526 * doc/tm.texi.in: Likewise.
15527 * final.c (struct label_alignment): Remove not used structure.
15528 (LABEL_ALIGN): Change type to align_flags.
15529 (LOOP_ALIGN): Likewise.
15530 (JUMP_ALIGN): Likewise.
15531 (default_loop_align_max_skip): Remove.
15532 (default_label_align_max_skip): Likewise.
15533 (default_jump_align_max_skip): Likewise.
15534 (default_label_align_after_barrier_max_skip):
15535 (LABEL_TO_ALIGNMENT): Change to access label_align vector.
15536 (LABEL_TO_MAX_SKIP): Remove.
15537 (label_to_alignment): Return align_flags type instead of integer.
15538 (label_to_max_skip): Remove.
15539 (align_fuzz): Use align_flags type.
15540 (compute_alignments): Use align_flags type and use align_flags::max
15541 to combine multiple alignments.
15542 (grow_label_align): Grow vec instead of C array.
15543 (update_alignments): Assign just LABEL_TO_ALIGNMENT.
15544 (shorten_branches): Use align_flags type and use align_flags::max
15545 to combine multiple alignments.
15546 (final_scan_insn_1): Remove usage of secondary alignment that comes
15547 from label alignment, but instead use proper secondary alignment
15548 which is computed in grow_label_align.
15549 * flags.h (struct align_flags_tuple): Move to align.h.
15550 (struct align_flags): Likewise.
15551 (state_align_loops): Rename to align_loops.
15552 (state_align_jumps): Rename to align_jumps.
15553 (state_align_labels): Rename to align_labels.
15554 (state_align_functions): Rename to align_functions.
15555 (align_loops_log): Remove.
15556 (align_jumps_log): Remove.
15557 (align_labels_log): Remove.
15558 (align_functions_log): Remove.
15559 (align_loops_max_skip): Remove.
15560 (align_jumps_max_skip): Remove.
15561 (align_labels_max_skip): Remove.
15562 (align_functions_max_skip): Remove.
15563 (align_loops_value): Remove.
15564 (align_jumps_value): Remove.
15565 (align_labels_value): Remove.
15566 (align_functions_value): Remove.
15567 * output.h (label_to_alignment): Change return type to align_flags.
15568 (label_to_max_skip): Remove.
15569 * target.def: Remove loop_align_max_skip, label_align_max_skip,
15570 jump_align_max_skip macros.
15571 * targhooks.h (default_loop_align_max_skip): Remove.
15572 (default_label_align_max_skip): Likewise.
15573 (default_jump_align_max_skip): Likewise.
15574 (default_label_align_after_barrier_max_skip): Remove.
15575 * toplev.c (read_log_maxskip): Use ::normalize function.
15576 (parse_N_M): Remove not used argument and also call ::normalize.
15577 (parse_alignment_opts): Do not pass unused arguments.
15578 * varasm.c (assemble_start_function): Use directly align_functions
15579 instead of removed macros.
15580 * system.h: Do not poison removed macros.
15582 2018-07-17 Jakub Jelinek <jakub@redhat.com>
15584 PR middle-end/86539
15585 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
15586 and cond temporaries don't have reference type if iterator has
15587 pointer type. For init use &for_pre_body instead of pre_p if
15588 for_pre_body is non-empty.
15590 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
15592 * config/rs6000/rs6000.md (trunc<mode>sf2): Expand truncates of
15593 double-double modes to SFmode directly directly.
15594 (trunc<mode>sf2_fprs): Delete.
15596 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
15598 * config/rs6000/rs6000.c (init_float128_ibm): Use the correct names
15599 for conversions between IFmode and the decimal floating point modes.
15600 (init_float128_ieee): Use the correct names for conversions between
15601 KFmode and the decimal floating point modes.
15603 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
15605 * config/rs6000/rs6000.c (init_float128_ibm): Use more correct names
15606 for the conversions between TDmode and IFmode.
15607 (init_float128_ieee): Use more correct names for the conversions
15608 between TDmode and KFmode.
15610 2018-07-16 Jakub Jelinek <jakub@redhat.com>
15612 PR tree-optimization/86526
15613 * builtins.c (expand_builtin_memcmp): Formatting fixes.
15614 (inline_expand_builtin_string_cmp): Likewise.
15615 (inline_string_cmp): Likewise. Use c_readstr instead of
15616 builtin_memcpy_read_str. Add unit_mode temporary.
15618 2018-07-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
15620 PR middle-end/86528
15621 * builtins.c (check_access): Bail out if range[0] is no INTEGER_CST.
15622 * expr.c (string_constant): Fix the element size of ARRAY_TYPE.
15624 2018-07-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
15626 * doc/extend.texi (PowerPC AltiVec Built-in Functions):
15627 Alphabetize prototypes of built-in functions, separating out
15628 built-in functions that are listed in this section but should be
15629 described elsewhere.
15631 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
15634 * expmed.c (emit_store_flag): Do not emit setcc followed by a
15635 conditional move when trapping comparison was split to a
15636 non-trapping one (and vice versa).
15638 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
15640 * config/s390/s390.c (s390_function_profiler): Generate nops
15641 instead of profiler call sequences.
15642 * config/s390/s390.opt: Add the new option.
15644 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
15646 * config/s390/s390.c (s390_function_profiler): Generate
15647 __mcount_loc section.
15648 * config/s390/s390.opt: Add the new option.
15650 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
15652 * common.opt: Add the new warning.
15653 * config/s390/s390.c (s390_function_profiler): Emit "brasl
15654 %r0,__fentry__" when -mfentry is specified.
15655 (s390_option_override_internal): Disallow -mfentry for 31-bit
15657 * config/s390/s390.opt: Add the new option.
15659 2018-07-16 Richard Biener <rguenther@suse.de>
15662 * dwarf2out.c (dwarf2out_register_external_die): Assign DIE parents
15663 for function-local FUNCTION_DECL and RESULT_DECL immediately.
15665 2018-07-16 Martin Liska <mliska@suse.cz>
15668 * ipa-pure-const.c (malloc_candidate_p): Revert ::get
15671 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
15673 * config/arc/arcHS.md: Update ARCHS scheduling rules.
15675 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
15677 * config/arc/arc-arch.h (arc_tune_attr): Add new tune parameters
15679 * config/arc/arc-cpus.def (hs4x): New cpu.
15681 * config/arc/arc-tables.opt: Regenerate.
15682 * config/arc/arc.c (arc_sched_issue_rate): New function.
15683 (TARGET_SCHED_ISSUE_RATE): Define.
15684 (TARGET_SCHED_EXPOSED_PIPELINE): Likewise.
15685 * config/arc/arc.md (attr type): Add fpu_fuse, fpu_sdiv, fpu_ddiv,
15687 (attr tune): Add ARCHS4x tune values.
15688 (attr tune_dspmpy): Define.
15689 (*tst): Correct instruction type.
15690 * config/arc/arcHS.md: Don't use this automaton for ARCHS4x cpus.
15691 * config/arc/arcHS4x.md: New file.
15692 * config/arc/fpu.md: Update instruction type attributes.
15693 * config/arc/t-multilib: Regenerate.
15695 2018-07-16 Tom de Vries <tdevries@suse.de>
15698 * var-tracking.c (vt_initialize): Fix pre_dec handling.
15700 2018-07-16 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
15702 * config/aarch64/atomics.md (aarch64_store_execlusive<mode>): Add
15705 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
15707 PR tree-optimization/86514
15708 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
15709 conversion to a boolean type from a type with greater precision.
15711 2018-07-16 Tom de Vries <tdevries@suse.de>
15713 * var-tracking.c (vt_initialize): Print adjusted insn slim if
15714 dump_flags request TDF_SLIM.
15716 2018-07-16 Aldy Hernandez <aldyh@redhat.com>
15718 * fold-const.c (int_const_binop_1): Abstract...
15719 (wide_int_binop): ...wide int code here.
15720 (poly_int_binop): ...poly int code here.
15721 Abstract the rest of int_const_binop_1 into int_const_binop.
15722 * fold-const.h (wide_int_binop): New.
15723 * tree-vrp.c (vrp_int_const_binop): Call wide_int_binop.
15724 Remove useless PLUS/MINUS_EXPR case.
15725 (zero_nonzero_bits_from_vr): Move wide int code...
15726 (zero_nonzero_bits_from_bounds): ...here.
15727 (extract_range_from_binary_expr_1): Move mask optimization code...
15728 (range_easy_mask_min_max): ...here.
15729 * tree-vrp.h (zero_nonzero_bits_from_bounds): New.
15730 (range_easy_mask_min_max): New.
15732 2018-07-15 Jeff Law <law@redhat.com>
15735 * config/sh/sh.c (output_mi_thunk): Remove dead conditional
15738 2018-07-14 Jim Wilson <jimw@sifive.com>
15740 * config/riscv/linux.h (TARGET_ASM_FILE_END): New.
15742 2018-07-14 Paul Koning <ni1d@arrl.net>
15744 * config/pdp11/pdp11.c (pdp11_rtx_costs): Bugfixes.
15746 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
15748 * lto-streamer-out.c (copy_function_or_variable): Dump info about
15751 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
15752 Steve Munroe <munroesj52@gmail.com>
15754 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
15755 (_mm_andnot_si128): Likewise.
15756 (_mm_or_si128): Likewise.
15757 (_mm_xor_si128): Likewise.
15759 2018-07-13 Qing Zhao <qing.zhao@oracle.com>
15761 PR middle-end/78809
15762 * builtins.c (expand_builtin_memcmp): Inline the calls first
15763 when result_eq is false.
15764 (expand_builtin_strcmp): Inline the calls first.
15765 (expand_builtin_strncmp): Likewise.
15766 (inline_string_cmp): New routine. Expand a string compare
15767 call by using a sequence of char comparison.
15768 (inline_expand_builtin_string_cmp): New routine. Inline expansion
15769 a call to str(n)cmp/memcmp.
15770 * doc/invoke.texi (--param builtin-string-cmp-inline-length):
15772 * params.def (BUILTIN_STRING_CMP_INLINE_LENGTH): New.
15774 2018-07-13 Richard Earnshaw <rearnsha@arm.com>
15776 * config/arm/driver-arm.c: Include arm-native.h.
15777 (host_detect_local_cpu): Use auto-generated data tables.
15778 (vendors, arm_cpu_table): Delete. Move part information to ...
15779 * config/arm/arm-cpus.in: ... here.
15780 * config/arm/parsecpu.awk (gen_native): New function.
15781 (vendor, part): New CPU fields.
15782 (END): Add support for building the native CPU detection tables.
15783 * config/arm/t-arm (arm-native.h): Add build rule.
15784 (driver-arm.o): Add dependency on arm-native.h.
15786 2018-07-13 Richard Biener <rguenther@suse.de>
15788 PR middle-end/85974
15789 * match.pd (addr1 - addr2): Allow either of the operand to
15792 2018-07-13 Tom de Vries <tdevries@suse.de>
15794 * tree-inline.c (remap_ssa_name): Save and reuse debug exprs generated
15797 2018-07-13 Jackson Woodruff <jackson.woodruff@arm.com>
15799 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp): Use
15800 arrays instead of numbered variables.
15802 2018-07-13 Eric Botcazou <ebotcazou@adacore.com>
15804 * config/sparc/sparc-protos.h (sparc_compute_frame_size): Delete.
15805 * config/sparc/sparc.c (sparc_compute_frame_size): Make static.
15807 2018-07-13 Richard Biener <rguenther@suse.de>
15810 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
15811 instead of get_context_die.
15813 2018-07-13 Kugan Vivekanandarajah <kuganv@linaro.org>
15814 Richard Biener <rguenther@suse.de>
15816 PR middle-end/86489
15817 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Check
15818 that the loop latch destination where phi is defined.
15820 2018-07-12 Kito Cheng <kito.cheng@gmail.com>
15822 * config/riscv/riscv.c (enum riscv_privilege_levels): Add UNKNOWN_MODE.
15823 (riscv_expand_epilogue): Add assertion to check interrupt mode.
15824 (riscv_set_current_function): Extract getting interrupt type to new
15826 (riscv_get_interrupt_type): New function.
15827 (riscv_merge_decl_attributes): New function, checking interrupt type is
15829 (TARGET_MERGE_DECL_ATTRIBUTES): Define.
15831 2018-07-12 Paul Koning <ni1d@arrl.net>
15833 * config/pdp11/pdp11.c (pdp11_output_def): Fix typo in .set
15836 2018-07-12 Paul Koning <ni1d@arrl.net>
15838 * doc/rtl.texi (REG_NONNEG): Remove decrement and branch until
15839 zero reference, add doloop_end instead.
15840 * doc/md.texi (decrement_and_branch_until_zero): Remove.
15841 (Looping patterns): Remove decrement_and_branch_until_zero. Add
15842 detail for doloop_end.
15844 2018-07-12 Martin Sebor <msebor@redhat.com>
15847 * attribs.c (decl_attributes): Reject conflicting attributes before
15848 calling attribute handlers.
15850 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
15852 * dumpfile.c (gcc::dump_manager::get_dump_file_name): Add PART
15854 (gcc::dump_manager::get_dump_file_name): likewise.
15855 (dump_begin): Likewise.
15856 * dumpfile.h (dump_begin): Update prototype.
15857 (gcc::dump_manager::get_dump_file_name,
15858 gcc::dump_manager::get_dump_file_name): Update prototype.
15860 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
15862 * internal-fn.h (vectorizable_internal_fn_p): New function.
15863 * tree-vect-slp.c (compatible_calls_p): Likewise.
15864 (vect_build_slp_tree_1): Remove nops argument. Handle calls
15865 to internal functions.
15866 (vect_build_slp_tree_2): Update call to vect_build_slp_tree_1.
15868 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
15870 * fold-const.h (inverse_conditions_p): Declare.
15871 * fold-const.c (inverse_conditions_p): New function.
15872 * match.pd: Use inverse_conditions_p. Add folds of view_converts
15873 that test the inverse condition of a conditional internal function.
15874 * internal-fn.h (vectorized_internal_fn_supported_p): Declare.
15875 * internal-fn.c (internal_fn_mask_index): Handle conditional
15876 internal functions.
15877 (vectorized_internal_fn_supported_p): New function.
15878 * tree-if-conv.c: Include internal-fn.h and fold-const.h.
15879 (any_pred_load_store): Replace with...
15880 (need_to_predicate): ...this new variable.
15881 (redundant_ssa_names): New variable.
15882 (ifcvt_can_use_mask_load_store): Move initial checks to...
15883 (ifcvt_can_predicate): ...this new function. Handle tree codes
15884 for which a conditional internal function exists.
15885 (if_convertible_gimple_assign_stmt_p): Use ifcvt_can_predicate
15886 instead of ifcvt_can_use_mask_load_store. Update after variable
15888 (predicate_load_or_store): New function, split out from
15889 predicate_mem_writes.
15890 (check_redundant_cond_expr): New function.
15891 (value_available_p): Likewise.
15892 (predicate_rhs_code): Likewise.
15893 (predicate_mem_writes): Rename to...
15894 (predicate_statements): ...this. Use predicate_load_or_store
15895 and predicate_rhs_code.
15896 (combine_blocks, tree_if_conversion): Update after above name changes.
15897 (ifcvt_local_dce): Handle redundant_ssa_names.
15898 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): Handle
15899 general conditional functions.
15900 * tree-vect-stmts.c (vectorizable_call): Likewise.
15902 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
15903 Alan Hayward <alan.hayward@arm.com>
15904 David Sherwood <david.sherwood@arm.com>
15906 * internal-fn.h (can_interpret_as_conditional_op_p): Declare.
15907 * internal-fn.c (can_interpret_as_conditional_op_p): New function.
15908 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Handle conditional
15909 plus and minus and convert them into IFN_COND_FMA-based sequences.
15910 (convert_mult_to_fma): Handle conditional plus and minus.
15912 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
15914 * doc/md.texi (cond_fma, cond_fms, cond_fnma, cond_fnms): Document.
15915 * optabs.def (cond_fma_optab, cond_fms_optab, cond_fnma_optab)
15916 (cond_fnms_optab): New optabs.
15917 * internal-fn.def (COND_FMA, COND_FMS, COND_FNMA, COND_FNMS): New
15918 internal functions.
15919 (FMA): Use DEF_INTERNAL_FLT_FN rather than DEF_INTERNAL_FLT_FLOATN_FN.
15920 * internal-fn.h (get_conditional_internal_fn): Declare.
15921 (get_unconditional_internal_fn): Likewise.
15922 * internal-fn.c (cond_ternary_direct): New macro.
15923 (expand_cond_ternary_optab_fn): Likewise.
15924 (direct_cond_ternary_optab_supported_p): Likewise.
15925 (FOR_EACH_COND_FN_PAIR): Likewise.
15926 (get_conditional_internal_fn): New function.
15927 (get_unconditional_internal_fn): Likewise.
15928 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 5.
15929 (gimple_match_op::gimple_match_op): Add a new overload for 5
15931 (gimple_match_op::set_op): Likewise.
15932 (gimple_resimplify5): Declare.
15933 * genmatch.c (decision_tree::gen): Generate simplifications for
15935 * gimple-match-head.c (gimple_simplify): Define an overload for
15936 5 operands. Handle calls with 5 arguments in the top-level overload.
15937 (convert_conditional_op): Handle conversions from unconditional
15938 internal functions to conditional ones.
15939 (gimple_resimplify5): New function.
15940 (build_call_internal): Pass a fifth operand.
15941 (maybe_push_res_to_seq): Likewise.
15942 (try_conditional_simplification): Try converting conditional
15943 internal functions to unconditional internal functions.
15944 Handle 3-operand unconditional forms.
15945 * match.pd (UNCOND_TERNARY, COND_TERNARY): Operator lists.
15946 Define ternary equivalents of the current rules for binary conditional
15947 internal functions.
15948 * config/aarch64/aarch64.c (aarch64_preferred_else_value): Handle
15949 ternary operations.
15950 * config/aarch64/iterators.md (UNSPEC_COND_FMLA, UNSPEC_COND_FMLS)
15951 (UNSPEC_COND_FNMLA, UNSPEC_COND_FNMLS): New unspecs.
15952 (optab): Handle them.
15953 (SVE_COND_FP_TERNARY): New int iterator.
15954 (sve_fmla_op, sve_fmad_op): New int attributes.
15955 * config/aarch64/aarch64-sve.md (cond_<optab><mode>)
15956 (*cond_<optab><mode>_2, *cond_<optab><mode_4)
15957 (*cond_<optab><mode>_any): New SVE_COND_FP_TERNARY patterns.
15959 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
15961 * target.def (preferred_else_value): New target hook.
15962 * doc/tm.texi.in (TARGET_PREFERRED_ELSE_VALUE): New hook.
15963 * doc/tm.texi: Regenerate.
15964 * targhooks.h (default_preferred_else_value): Declare.
15965 * targhooks.c (default_preferred_else_value): New function.
15966 * internal-fn.h (conditional_internal_fn_code): Declare.
15967 * internal-fn.c (FOR_EACH_CODE_MAPPING): New macro.
15968 (get_conditional_internal_fn): Use it.
15969 (conditional_internal_fn_code): New function.
15970 * gimple-match.h (gimple_match_cond): New struct.
15971 (gimple_match_op): Add a cond member function.
15972 (gimple_match_op::gimple_match_op): Update all forms to take a
15974 * genmatch.c (expr::gen_transform): Use the same condition as res_op
15975 for the suboperation, but don't specify a particular else_value.
15976 * tree-ssa-sccvn.c (vn_nary_simplify, vn_reference_lookup_3)
15977 (visit_nary_op, visit_reference_op_load): Pass
15978 gimple_match_cond::UNCOND to the gimple_match_op constructor.
15979 * gimple-match-head.c: Include tree-eh.h
15980 (convert_conditional_op): New function.
15981 (maybe_resimplify_conditional_op): Likewise.
15982 (gimple_resimplify1): Call maybe_resimplify_conditional_op.
15983 (gimple_resimplify2): Likewise.
15984 (gimple_resimplify3): Likewise.
15985 (gimple_resimplify4): Likewise.
15986 (maybe_push_res_to_seq): Return null for conditional operations.
15987 (try_conditional_simplification): New function.
15988 (gimple_simplify): Call it. Pass conditions to the gimple_match_op
15990 * match.pd: Fold VEC_COND_EXPRs of an IFN_COND_* call to a new
15992 * config/aarch64/aarch64.c (aarch64_preferred_else_value): New
15994 (TARGET_PREFERRED_ELSE_VALUE): Redefine.
15996 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
15998 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
16000 (hash_tree): Do not hash DECL_FCONTEXT
16001 * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
16002 Do not stream DECL_FCONTEXT.
16003 * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
16004 * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
16006 2018-07-12 Richard Biener <rguenther@suse.de>
16009 * dwarf2out.c (gen_block_die): Only output blocks when they have
16010 at least one !DECL_IGNORED_P variable.
16012 2018-07-12 Richard Biener <rguenther@suse.de>
16015 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
16016 Remove -mieee-fp handling.
16018 2018-07-12 Richard Biener <rguenther@suse.de>
16020 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Remove bogus
16021 left-over from last patch.
16023 2018-07-12 Jakub Jelinek <jakub@redhat.com>
16025 PR tree-optimization/86492
16026 * gimple-ssa-store-merging.c
16027 (imm_store_chain_info::coalesce_immediate_stores): Call
16028 check_no_overlap even for the merge_overlapping case. Formatting fix.
16030 2018-07-12 Richard Biener <rguenther@suse.de>
16032 PR middle-end/86479
16033 * fold-const.c (fold_binary_op_with_conditional_arg): Do not
16034 move possibly trapping operations into the conditional.
16036 2018-07-12 Richard Biener <rguenther@suse.de>
16038 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
16039 (vn_lookup_simplify_result): Remove recursion limit applied
16041 (vn_nary_build_or_lookup_1): Adjust.
16042 (try_to_simplify): Likewise.
16043 * gimple-match-head.c (gimple_resimplify1): Instead apply one
16045 (gimple_resimplify2): Likewise.
16046 (gimple_resimplify3): Likewise.
16047 (gimple_resimplify4): Likewise.
16049 2018-07-11 Jakub Jelinek <jakub@redhat.com>
16051 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
16052 Use __mmask64 type instead of __mmask8 for __M argument.
16053 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
16054 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
16056 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
16057 __mmask16 for __M argument.
16058 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
16059 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
16060 to __mmask16 instead of __mmask8.
16061 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
16062 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
16063 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
16064 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
16065 instead of __mmask16 for __U argument.
16066 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
16067 __mmask16 instead of __mmask8 for __U argument.
16068 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
16070 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
16072 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
16074 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
16076 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
16078 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
16080 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
16082 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
16084 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
16086 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
16088 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
16089 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
16090 return type as well as __M argument type and all casts from __mmask8
16092 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
16093 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
16094 return type as well as __M argument type and all casts from __mmask8
16096 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
16097 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
16098 return type as well as __M argument type and all casts from __mmask8
16100 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
16101 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
16102 return type as well as __M argument type and all casts from __mmask8
16104 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
16105 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
16108 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
16110 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
16111 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
16114 2018-07-11 Paul Koning <ni1d@arrl.net>
16116 * doc/md.texi (define_subst): Document how multiple occurrences of
16117 the same argument in the replacement pattern are handled.
16119 2018-07-11 Paul Koning <ni1d@arrl.net>
16121 * doc/extend.texi (Common Variable Attributes): Move "mode" into
16122 alphabetical order.
16123 (Common Type Attributes): Add "mode" attribute.
16125 2018-07-11 Jan Hubicka <hubicka@ucw.cz>
16127 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not
16128 stream DECL_ORIGINAL_TYPE.
16129 (DFS::DFS_write_tree_body): Drop hack handling local external decls.
16130 (hash_tree): Do not walk DECL_ORIGINAL_TYPE.
16131 * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
16132 Do not walk original type.
16133 * tree-streamer-out.c (streamer_write_chain): Drop hack handling
16135 (write_ts_decl_non_common_tree_pointers): Do not stream
16137 * tree.c (free_lang_data_in_decl): Clear DECL_ORIGINAL_TYPE.
16138 (find_decls_types_r): Do not walk DEC_ORIGINAL_TYPE.
16140 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
16142 * tree-ssa-threadupdate.c (thread_through_all_blocks): Do not jump
16143 thread twice from the same starting edge.
16145 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
16147 * vr-values.c (gimple_stmt_nonzero_p): Abstract common code to...
16148 * gimple.c (gimple_call_nonnull_result_p): ...here...
16149 (gimple_call_nonnull_arg): ...and here.
16150 * gimple.h (gimple_call_nonnull_result_p): New.
16151 (gimple_call_nonnull_arg): New.
16153 2018-07-11 Richard Earnshaw <rearnsha@arm.com>
16155 * config/arm/arm-cpus.in: Move information from fpu field of each
16156 cpu definition to the isa field.
16157 * config/arm/parsecpu.awk (fpu): Delete match rule.
16158 (gen_comm_data): Don't add bits from the CPU's FPU entry.
16160 2018-07-11 Richard Biener <rguenther@suse.de>
16163 * dwarf2out.c (init_sections_and_labels): Use
16164 output_asm_line_debug_info consistently.
16165 (dwarf2out_early_finish): Likewise.
16166 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
16169 2018-07-11 Richard Biener <rguenther@suse.de>
16171 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1):
16172 Rework father_bb setting in a way to avoid propagating constants
16173 multiple times on a loop body.
16175 2018-07-10 Mark Wielaard <mark@klomp.org>
16178 * dwarf2out.c (output_macinfo_op): Fix dwarf_FORM typo in gcc_assert.
16180 2018-07-10 Richard Biener <rguenther@suse.de>
16182 * hash-map.h (hash_map::iterator::operator*): Return
16183 references to key and value.
16185 2018-07-10 Jakub Jelinek <jakub@redhat.com>
16188 * gimplify.c (find_combined_omp_for): Add DATA argument, in addition
16189 to finding the inner OMP_FOR/OMP_SIMD stmt find non-trivial wrappers,
16190 BLOCKs with BLOCK_VARs, OMP_PARALLEL in between, OMP_FOR in between.
16191 (gimplify_omp_for): For composite loops, move outer
16192 OMP_{DISTRIBUTE,TASKLOOP,FOR,PARALLEL} right around innermost
16193 OMP_FOR/OMP_SIMD if there are any non-trivial wrappers. For class
16194 iterators add any needed clauses. Allow OMP_FOR_ORIG_DECLS to contain
16195 TREE_LIST for both the original class iterator and the "last" helper
16196 var. Gimplify OMP_FOR_PRE_BODY before the outermost composite
16197 loop, remember has_decl_expr from outer composite loops for the
16198 innermost OMP_SIMD in TREE_PRIVATE bit on OMP_FOR_INIT.
16200 2018-07-09 Martin Sebor <msebor@redhat.com>
16202 PR middle-end/77357
16203 PR middle-end/86428
16204 * builtins.c (c_strlen): Avoid out-of-bounds warnings when
16205 accessing implicitly initialized array elements.
16206 * expr.c (string_constant): Handle string initializers of
16207 character arrays within aggregates.
16208 * gimple-fold.c (fold_array_ctor_reference): Add argument.
16209 Store element offset. As a special case, handle zero size.
16210 (fold_nonarray_ctor_reference): Same.
16211 (fold_ctor_reference): Add argument. Store subobject offset.
16212 * gimple-fold.h (fold_ctor_reference): Add argument.
16214 2018-07-09 Paul Koning <ni1d@arrl.net>
16216 * config/pdp11/pdp11.c (pdp11_addr_cost): New function.
16217 (pdp11_insn_cost): New function.
16218 (pdp11_md_asm_adjust): New function.
16219 (TARGET_INVALID_WITHIN_DOLOOP): Define.
16220 (pdp11_rtx_costs): Update to match machine better.
16221 (output_addr_const_pdp11): Correct format mismatch warnings.
16222 * config/pdp11/pdp11.h (SLOW_BYTE_ACCESS): Correct definition.
16223 * config/pdp11/pdp11.md: General change to add base_cost and/or
16224 length attributes for use by new pdp11_insn_cost function.
16225 (MIN_BRANCH): Correct definition.
16227 (doloop_end): Use standard pattern name for looping pattern.
16228 (doloop_end_nocc): New.
16229 (movsf): Add another constraint alternative.
16230 (zero_extendqihi2): Add constraint alternatives for not in place
16232 (zero_extendhisi2): Remove.
16233 (shift patterns): Add CC handling variants.
16237 (define_peephole2): New peephole to recognize mov that sets CC for
16240 2018-07-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16242 * config/sparc/sparc.c (sparc_fold_builtin) <SPARC_BUILTIN_PDIST,
16243 SPARC_BUILTIN_PDISTN>: Adapt for signature change of wi::neg,
16246 2018-07-09 Jakub Jelinek <jakub@redhat.com>
16249 * real.c (real_nextafter): Return true if result is denormal.
16251 2018-07-09 Martin Liska <mliska@suse.cz>
16253 * common.opt: Add back wrongly removed attribute.
16255 2018-07-09 Richard Biener <rguenther@suse.de>
16258 * dwarf2out.c (gen_block_die): For an early generated DIE
16259 always output high/low PC attributes.
16261 2018-07-09 Tom de Vries <tdevries@suse.de>
16263 * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
16264 * tree-inline.c (remap_ssa_name): Handle default def ssa_name mapping
16265 onto VAR_DECL with abstract origin.
16267 2018-07-07 Jim Wilson <jimw@sifive.com>
16269 * config/riscv/riscv.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): New.
16271 2018-07-07 Tom de Vries <tdevries@suse.de>
16273 * tree-dfa.c (dump_enumerated_decls): Handle cfun->cfg == NULL.
16275 2018-07-07 Aldy Hernandez <aldyh@redhat.com>
16277 * tree-vrp.c (vrp_int_const_binop): Change overflow type to
16279 (combine_bound): Use wide-int overflow calculation instead of
16281 * calls.c (maybe_warn_alloc_args_overflow): Change overflow type to
16283 * fold-const.c (int_const_binop_2): Same.
16284 (extract_muldiv_1): Same.
16285 (fold_div_compare): Same.
16286 (fold_abs_const): Same.
16288 * poly-int.h (add): Same.
16292 * predict.c (predict_iv_comparison): Same.
16293 * profile-count.c (slow_safe_scale_64bit): Same.
16294 * simplify-rtx.c (simplify_const_binary_operation): Same.
16295 * tree-chrec.c (tree_fold_binomial): Same.
16296 * tree-data-ref.c (split_constant_offset_1): Same.
16297 * tree-if-conv.c (idx_within_array_bound): Same.
16298 * tree-scalar-evolution.c (iv_can_overflow_p): Same.
16299 * tree-ssa-phiopt.c (minmax_replacement): Same.
16300 * tree-vect-loop.c (is_nonwrapping_integer_induction): Same.
16301 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Same.
16302 * vr-values.c (vr_values::adjust_range_with_scev): Same.
16303 * wide-int.cc (wi::add_large): Same.
16304 (wi::mul_internal): Same.
16305 (wi::sub_large): Same.
16306 (wi::divmod_internal): Same.
16307 * wide-int.h: Change overflow type to overflow_type for neg, add,
16308 mul, smul, umul, div_trunc, div_floor, div_ceil, div_round,
16309 mod_trunc, mod_ceil, mod_round, add_large, sub_large,
16310 mul_internal, divmod_internal.
16311 (overflow_type): New enum.
16312 (accumulate_overflow): New.
16314 2018-07-06 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
16316 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): New.
16317 (tree_ssa_phiopt_worker): Call cond_removal_in_popcount_pattern.
16319 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
16321 * tree-ssa-loop-niter.c (number_of_iterations_popcount): If popcount
16322 argument is checked for zero before entering loop, avoid checking again.
16324 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
16326 * gimplify.h (generic_expr_could_trap_p): Set as global function.
16327 * gimplify.h (generic_expr_could_trap_p): Likwise.
16328 * tree-scalar-evolution.c (expression_expensive_p): Handle COND_EXPR.
16330 2018-07-06 Jakub Jelinek <jakub@redhat.com>
16332 PR tree-optimization/86401
16333 * fold-const.c (fold_binary_loc) <case BIT_AND_EXPR>: Move the
16334 ((A & N) + B) & M -> (A + B) & M etc. optimization into ...
16335 (fold_bit_and_mask): ... here. New helper function for match.pd.
16336 * fold-const.h (fold_bit_and_mask): Declare.
16337 * match.pd (((A & N) + B) & M -> (A + B) & M): New optimization.
16339 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
16342 * target.def (translate_mode_attribute): New hook.
16343 * targhooks.h (default_translate_mode_attribute): Declare.
16344 * targhooks.c (default_translate_mode_attribute): New function.
16345 * doc/tm.texi.in (TARGET_TRANSLATE_MODE_ATTRIBUTE): New hook.
16346 * doc/tm.texi: Regenerate.
16347 * config/rs6000/rs6000.c (TARGET_TRANSLATE_MODE_ATTRIBUTE): Define.
16348 (rs6000_translate_mode_attribute): New function.
16350 2018-07-06 Paul Koning <ni1d@arrl.net>
16352 * doc/md.texi (define_split): Document DONE and FAIL.
16353 (define_peephole2): Ditto.
16355 2018-07-05 Jeff Law <law@redhat.com>
16357 PR tree-optimization/86010
16358 * tree-ssa-dse.c (compute_trims): More aggressively trim at
16359 both the head and tail of mem* and str* calls.
16361 2018-07-05 Jim Wilson <jimw@sifive.com>
16363 * config.gcc (riscv*-*-*): When setting xlen, handle riscv-*.
16365 2018-07-05 Indu Bhagat <indu.bhagat@oracle.com>
16367 * config/aarch64/aarch64-simd.md: correct flags text for
16368 MIN_EXPR replacement.
16370 2018-07-05 James Clarke <jrtc27@jrtc27.com>
16372 * configure: Regenerated.
16374 2018-07-05 Carl Love <cel@us.ibm.com>
16376 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
16377 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
16378 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
16379 VSX_BUILTIN_DOUBLEL_V4SF.
16381 2018-07-05 Martin Sebor <msebor@redhat.com>
16384 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
16385 than its domain to compute its the upper bound of a char array.
16387 2018-07-05 Nathan Sidwell <nathan@acm.org>
16389 Replace NO_IMPLICIT_EXTERN_C with SYSTEM_IMPLICIT_EXTERN_C.
16390 * doc/cpp.texi: Update comment.
16391 * doc/tm.texi: Rebuilt.
16392 * doc/tm.texi.in (NO_IMPLICIT_EXTERN_C): Replace with ...
16393 (SYSTEM_IMPLICIT_EXTERN_C): ... this, opposite sense.
16394 * doc/extend.texi (Backwards Compatibility): Clarify it is system
16395 headers affected by extern "C".
16396 * system.h: Poison NO_IMPLICIT_EXTERN_C.
16397 * config/alpha/alpha.h, config/arm/uclinux-elf.h,
16398 config/bfin/elf.h, config/cris/cris.h, config/darwin.h,
16399 config/dragonfly.h, config/freebsd.h, config/gnu-user.h,
16400 config/i386/cygming.h, config/i386/djgpp.h, config/i386/nto.h,
16401 config/ia64/hpux.h, config/lm32/lm32.h, config/lm32/uclinux-elf.h,
16402 config/lynx.h, config/mips/elf.h, config/mmix/mmix.h,
16403 config/netbsd.h, config/pa/pa-hpux.h, config/powerpcspe/sysv4.h,
16404 config/riscv/elf.h, config/rs6000/sysv4.h, config/rtems.h,
16405 config/s390/tpf.h, config/sh/newlib.h, config/sol2.h,
16406 config/sparc/openbsd64.h, config/sparc/sp-elf.h,
16407 config/sparc/sp64-elf.h, config/spu/spu.h,
16408 config/stormy16/stormy16.h, config/v850/v850.h,
16409 config/visium/visium.h, config/vx-common.h, config/xtensa/elf.h: Don't
16410 define NO_IMPLICIT_EXTERN_C.
16411 * config/rs6000/aix.h: Set SYSTEM_IMPLICIT_EXTERN_C.
16413 2018-07-05 Tamar Christina <tamar.christina@arm.com>
16416 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
16417 instead of GET_MODE_SIZE when comparing Units.
16419 2018-07-05 Tamar Christina <tamar.christina@arm.com>
16422 * rtlanal.c (set_noop_p): Constrain on mode change,
16423 include hard-reg-set.h
16425 2018-07-05 Tamar Christina <tamar.christina@arm.com>
16427 * config/aarch64/aarch64.c (aarch64_expand_movmem): Fix mode size.
16429 2018-07-05 Jakub Jelinek <jakub@redhat.com>
16432 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
16435 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
16437 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
16439 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
16442 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
16444 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
16446 2018-07-04 Eric Botcazou <ebotcazou@adacore.com>
16448 PR middle-end/86380
16449 * expmed.c (choose_multiplier): Fix incorrect comparison with mask.
16451 2018-07-04 Aldy Hernandez <aldyh@redhat.com>
16453 * tree-vrp.c (extract_range_from_binary_expr_1): Initialize
16454 neg_*_op* variables.
16456 2018-07-04 Martin Liska <mliska@suse.cz>
16458 * tree-switch-conversion.c: Define
16459 max_ratio_for_speed and max_ratio_for_size constants.
16461 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
16462 Martin Liska <mliska@suse.cz>
16464 PR middle-end/66240
16467 * common.opt: Rename align options with 'str_' prefix.
16468 * common/config/i386/i386-common.c (set_malign_value): New
16470 (ix86_handle_option): Use it to set -falign-* options/
16471 * config/aarch64/aarch64-protos.h (struct tune_params): Change
16472 type from int to string.
16473 * config/aarch64/aarch64.c: Update default values from int
16475 * config/alpha/alpha.c (alpha_override_options_after_change):
16477 * config/arm/arm.c (arm_override_options_after_change_1): Likewise.
16478 * config/i386/dragonfly.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16479 max skip conditionally.
16480 * config/i386/freebsd.h (SUBALIGN_LOG): New.
16481 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16482 max skip conditionally.
16483 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16484 max skip conditionally.
16485 * config/i386/gnu-user.h (SUBALIGN_LOG): New.
16486 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16487 max skip conditionally.
16488 * config/i386/i386.c (struct ptt): Change type from int to
16490 (ix86_default_align): Set default values.
16491 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Print
16492 max skip conditionally.
16493 * config/i386/iamcu.h (SUBALIGN_LOG): New.
16494 (ASM_OUTPUT_MAX_SKIP_ALIGN):
16495 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN):
16496 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16497 max skip conditionally.
16498 * config/i386/openbsdelf.h (SUBALIGN_LOG): New.
16499 (ASM_OUTPUT_MAX_SKIP_ALIGN) Print max skip conditionally.:
16500 * config/i386/x86-64.h (SUBALIGN_LOG): New.
16501 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16502 max skip conditionally.
16503 (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
16504 * config/ia64/ia64.c (ia64_option_override): Set default values
16505 for alignment options.
16506 * config/m68k/m68k.c: Handle new str_align_* options.
16507 * config/mips/mips.c (mips_set_compression_mode): Change
16509 (mips_option_override): Set default values for options.
16510 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
16512 * config/rs6000/rs6000.c (rs6000_option_override_internal):
16514 * config/rx/rx.c (rx_option_override): Likewise.
16515 * config/rx/rx.h (JUMP_ALIGN): Use align_jumps_log.
16516 (LABEL_ALIGN): Use align_labels_log.
16517 (LOOP_ALIGN): Use align_loops_align.
16518 * config/s390/s390.c (s390_asm_output_function_label): Use new
16520 * config/sh/sh.c (sh_override_options_after_change):
16521 Change type of constants.
16522 * config/spu/spu.c (spu_sched_init): Likewise.
16523 * config/sparc/sparc.c (sparc_option_override): Set default
16524 values for options.
16525 * config/visium/visium.c (visium_option_override): Likewise.
16526 * config/visium/visium.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Do not
16527 emit p2align format with last argument if it's not needed.
16528 * doc/invoke.texi: Document extended format of -falign-*.
16529 * final.c: Use align_labels alignment.
16530 * flags.h (struct target_flag_state): Change type to use
16532 (struct align_flags_tuple): New.
16533 (struct align_flags): Likewise.
16534 (align_loops_log): Redefine macro to use new types.
16535 (align_loops_max_skip): Redefine macro to use new types.
16536 (align_jumps_log): Redefine macro to use new types.
16537 (align_jumps_max_skip): Redefine macro to use new types.
16538 (align_labels_log): Redefine macro to use new types.
16539 (align_labels_max_skip): Redefine macro to use new types.
16540 (align_functions_log): Redefine macro to use new types.
16541 (align_loops): Redefine macro to use new types.
16542 (align_jumps): Redefine macro to use new types.
16543 (align_labels): Redefine macro to use new types.
16544 (align_functions): Redefine macro to use new types.
16545 (align_functions_max_skip): Redefine macro to use new types.
16546 (align_loops_value): New macro.
16547 (align_jumps_value): New macro.
16548 (align_labels_value): New macro.
16549 (align_functions_value): New macro.
16550 * function.c (invoke_set_current_function_hook): Propagate
16551 alignment values from flags to global variables default in
16553 * ipa-icf.c (sem_function::equals_wpa): Use
16554 cl_optimization_option_eq instead of memcmp.
16555 * lto-streamer.h (cl_optimization_stream_out): Support streaming
16557 (cl_optimization_stream_in): Likewise.
16558 * optc-save-gen.awk: Support strings in cl_optimization.
16559 * opth-gen.awk: Likewise.
16560 * opts.c (finish_options): Remove error checking of invalid
16562 (MAX_CODE_ALIGN): Remove.
16563 (MAX_CODE_ALIGN_VALUE): Likewise.
16564 (parse_and_check_align_values): New function.
16565 (check_alignment_argument): Likewise.
16566 (common_handle_option): Use check_alignment_argument.
16567 * opts.h (parse_and_check_align_values): Declare.
16568 * toplev.c (init_alignments): Remove.
16569 (read_log_maxskip): New.
16570 (parse_N_M): Likewise.
16571 (parse_alignment_opts): Likewise.
16572 (backend_init_target): Remove usage of init_alignments.
16573 * toplev.h (parse_alignment_opts): Declare.
16574 * tree-streamer-in.c (streamer_read_tree_bitfields): Add new
16576 * tree-streamer-out.c (streamer_write_tree_bitfields): Likewise.
16577 * tree.c (cl_option_hasher::equal): New.
16578 * varasm.c: Use new global macros.
16580 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
16582 * config/i386/dragonfly.h: (ASM_OUTPUT_MAX_SKIP_ALIGN):
16583 Use a simpler align directive also if MAXSKIP = ALIGN-1.
16584 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16585 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16586 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16587 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
16588 * config/i386/freebsd.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove "If N
16589 is large, do at least 8 byte alignment" code. Add SUBALIGN_LOG
16590 define. Use a simpler align directive also if MAXSKIP = ALIGN-1.
16591 * config/i386/gnu-user.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16592 * config/i386/iamcu.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16593 * config/i386/openbsdelf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16594 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16596 2018-07-04 Martin Liska <mliska@suse.cz>
16597 Jonathan Wakely <jwakely@redhat.com>
16599 * coverage.c: Use correct type.
16600 * doc/invoke.texi: Language correction.
16602 2018-07-03 H.J. Lu <hongjiu.lu@intel.com>
16605 * config/i386/i386.c (rest_of_insert_endbranch): Also generate
16606 ENDBRANCH for non-tail call which may return via indirect branch.
16607 * doc/extend.texi: Document indirect_return attribute.
16609 2018-07-03 Martin Sebor <msebor@redhat.com>
16611 PR tree-optimization/86274
16612 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
16614 (format_floating): Correct handling of infinities and NaNs.
16616 2018-07-03 Martin Sebor <msebor@redhat.com>
16618 * print-tree.c (print_real_cst): New function.
16619 (print_node_brief): Call it.
16620 (print_node): Ditto.
16622 2018-07-03 Jeff Law <law@redhat.com>
16624 * config/h8300/h8300.md (logical<mode>3_sn, logical<mode>3): Merge
16625 into a single pattern.
16627 * config/h8300/h8300.md (ors code_iterator): New.
16628 (bsetqi_msx, bnotqi_msx patterns and splitters): Consolidate into
16629 a single pattern and single splitter.
16630 (bsethi_msx, bnothi_msx patterns): Consolidate into a single pattern.
16631 (iorqi3_1, xorqi3_1): Likewise.
16632 (iorqi3, xorqi3 expanders): Similarly.
16634 * config/h8300/h8300.md (movmd_internal_normal): Consolidated with
16635 (movmd_internal) into a single pattern using the P mode iterator.
16636 (movmd splitters): Similarly.
16637 (stpcpy_internal_normal, stpcpy_internal): Similarly for thes patterns.
16638 (movsd splitters): Similarly.
16640 * config/h8300/h8300.c (h8300_insn_length_from_table): Consolidate
16641 ADDB, ADDW and ADDL into a single ADD attribute which selects the
16642 right table based on the size of the operand.
16643 * config/h8300/h8300.md (length_table): Corresponding changes. All
16644 references to "addb", "addw" and "addl" changed to "add".
16645 (btst patterns): Merge two variants into a single pattern.
16646 (tstqi, tsthi): Likewise.
16647 (addhi3_incdec, addsi3_incdec): Likewise.
16648 (subhi3_h8300hs, subsi3_h8300hs): Likewise.
16649 (mulhi3, mulsi3): Likewise.
16650 (udivhi3, udivsi3): Likewise.
16651 (divhi3, divsi3): Likewise.
16652 (andorqi3, andorhi3, andorsi3): Likewise.
16654 2018-07-03 Uros Bizjak <ubizjak@gmail.com>
16657 * config/i386/sse.md (uavg<mode>3_ceil): New expander.
16658 (<sse2_avx2>_uavg<mode>3<mask_name>): Simplify expander.
16660 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
16662 PR tree-optimization/85694
16663 * config/aarch64/iterators.md (HADD, RHADD): New int iterators.
16664 (u): Handle UNSPEC_SHADD, UNSPEC_UHADD, UNSPEC_SRHADD and
16666 * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor)
16667 (<u>avg<mode>3_ceil): New patterns.
16669 2018-07-03 David Malcolm <dmalcolm@redhat.com>
16671 * gcc.dg/vect/slp-perm-1.c: Remove "note: " prefix from
16672 scan-tree-dump directive.
16673 * gcc.dg/vect/slp-perm-2.c: Likewise.
16674 * gcc.dg/vect/slp-perm-3.c: Likewise.
16675 * gcc.dg/vect/slp-perm-5.c: Likewise.
16676 * gcc.dg/vect/slp-perm-6.c: Likewise.
16677 * gcc.dg/vect/slp-perm-7.c: Likewise.
16678 * gcc.dg/vect/slp-perm-8.c: Likewise.
16680 2018-07-03 Marek Polacek <polacek@redhat.com>
16682 PR middle-end/86202
16683 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
16685 2018-07-03 Richard Biener <rguenther@suse.de>
16688 * tree-ssa-structalias.c (find_func_clobbers): Properly
16689 handle indirect calls.
16691 2018-07-03 Jeff Law <law@redhat.com>
16693 * config/h8300/h8300.md (HSI, QHSI, QHSIF): New mode iterators.
16694 (shifts): New code iterator.
16695 (movqi, movhi, movsi, movsf expanders): Consolidate into a single
16696 expander. Fix HImode handling on H8/SX.
16697 (addqi3, addhi3, addsi3 expanders): Consolidate into a single expander.
16698 (subqi3, subhi3, subsi3 expanders): Likewise.
16699 (andqi3, andhi3, andsi3 expanders): Likewise.
16700 (iorqi3, iorhi3, iorsi3 expanders): Likewise.
16701 (xorqi3, xorhi3, xorsi3 expanders): Likewise.
16702 (negqi2, neghi2, negsi2, negsf2 expanders): Likewise.
16703 (one_cmplqi2, one_cmplhi2, one_cmplsi2): Likewise.
16704 (zero_extendqihi2, zero_extendqisi2): Likewise.
16705 (extendqihi2, extendqisi2): Likewise.
16706 (rotlqi3, rotlhi3, rotlsi3): Likewise.
16707 (neghi2_h8300, negsi2_h8300): Likewise for these patterns.
16708 (rotlqi3_1, rotlhi3_1): Likewise.
16709 (logicalhi3_sn, logicalsi3_sn): Likewise.
16710 (logicalhi3, logicalsi3): Likewise.
16712 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
16714 * tree-vect-patterns.c (vect_recog_rotate_pattern)
16715 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
16716 (vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast)
16717 (adjust_bool_pattern, vect_recog_bool_pattern): Pass the vector
16718 type to append_pattern_def_seq instead of creating a stmt_vec_info
16720 (build_mask_conversion): Likewise. Remove vinfo argument.
16721 (vect_add_conversion_to_patterm): Likewise, renaming to...
16722 (vect_add_conversion_to_pattern): ...this.
16723 (vect_recog_mask_conversion_pattern): Update call to
16724 build_mask_conversion. Pass the vector type to
16725 append_pattern_def_seq here too.
16726 (vect_recog_gather_scatter_pattern): Update call to
16727 vect_add_conversion_to_pattern.
16729 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
16731 * tree-vect-patterns.c (new_pattern_def_seq): Delete.
16732 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
16733 (vect_recog_widen_op_pattern, vect_recog_over_widening_pattern)
16734 (vect_recog_rotate_pattern, vect_synth_mult_by_constant): Don't set
16735 STMT_VINFO_PATTERN_DEF_SEQ to null here.
16736 (vect_recog_pow_pattern, vect_recog_vector_vector_shift_pattern)
16737 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern): Use
16738 append_pattern_def_seq instead of new_pattern_def_seq.
16739 (vect_recog_divmod_pattern): Do both of the above.
16740 (vect_pattern_recog_1): Assert that STMT_VINO_PATTERN_DEF_SEQ
16743 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
16745 * tree-vect-patterns.c (vect_recog_dot_prod_pattern):
16746 (vect_recog_sad_pattern, vect_recog_widen_op_pattern)
16747 (vect_recog_widen_mult_pattern, vect_recog_pow_pattern):
16748 (vect_recog_widen_sum_pattern, vect_recog_over_widening_pattern)
16749 (vect_recog_average_pattern, vect_recog_cast_forwprop_pattern)
16750 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
16751 (vect_recog_vector_vector_shift_pattern, vect_synth_mult_by_constant)
16752 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
16753 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
16754 (vect_recog_mask_conversion_pattern): Replace vec<gimple *>
16755 parameter with a single stmt_vec_info.
16756 (vect_recog_func_ptr): Likewise.
16757 (vect_recog_gather_scatter_pattern): Likewise, folding in...
16758 (vect_try_gather_scatter_pattern): ...this.
16759 (vect_pattern_recog_1): Remove stmts_to_replace and just pass
16760 the stmt_vec_info of the statement to be matched. Don't clear
16761 STMT_VINFO_RELATED_STMT.
16762 (vect_pattern_recog): Update call accordingly.
16764 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
16766 PR tree-optimization/85694
16767 * doc/md.texi (avgM3_floor, uavgM3_floor, avgM3_ceil)
16768 (uavgM3_ceil): Document new optabs.
16769 * doc/sourcebuild.texi (vect_avg_qi): Document new target selector.
16770 * internal-fn.def (IFN_AVG_FLOOR, IFN_AVG_CEIL): New internal
16772 * optabs.def (savg_floor_optab, uavg_floor_optab, savg_ceil_optab)
16773 (savg_ceil_optab): New optabs.
16774 * tree-vect-patterns.c (vect_recog_average_pattern): New function.
16775 (vect_vect_recog_func_ptrs): Add it.
16776 * tree-vect-stmts.c (vectorizable_call): Get the type of the zero
16777 constant directly from the associated lhs.
16779 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
16781 * tree-vect-patterns.c (vect_split_statement): New function.
16782 (vect_convert_input): Use it to try to split an existing cast.
16784 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
16786 * poly-int.h (print_hex): New function.
16787 * dumpfile.h (dump_dec, dump_hex): Declare.
16788 * dumpfile.c (dump_dec, dump_hex): New poly_wide_int functions.
16789 * tree-vectorizer.h (_stmt_vec_info): Add min_output_precision,
16790 min_input_precision, operation_precision and operation_sign.
16791 * tree-vect-patterns.c (vect_get_range_info): New function.
16792 (vect_same_loop_or_bb_p, vect_single_imm_use)
16793 (vect_operation_fits_smaller_type): Delete.
16794 (vect_look_through_possible_promotion): Add an optional
16795 single_use_p parameter.
16796 (vect_recog_over_widening_pattern): Rewrite to use new
16797 stmt_vec_info infomration. Handle one operation at a time.
16798 (vect_recog_cast_forwprop_pattern, vect_narrowable_type_p)
16799 (vect_truncatable_operation_p, vect_set_operation_type)
16800 (vect_set_min_input_precision): New functions.
16801 (vect_determine_min_output_precision_1): Likewise.
16802 (vect_determine_min_output_precision): Likewise.
16803 (vect_determine_precisions_from_range): Likewise.
16804 (vect_determine_precisions_from_users): Likewise.
16805 (vect_determine_stmt_precisions, vect_determine_precisions): Likewise.
16806 (vect_vect_recog_func_ptrs): Put over_widening first.
16808 (vect_pattern_recog): Call vect_determine_precisions.
16810 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
16812 * tree-vect-patterns.c (vect_mark_pattern_stmts): Remove pattern
16813 statements that have been replaced by further pattern statements.
16814 (vect_pattern_recog_1): Clear STMT_VINFO_PATTERN_DEF_SEQ on failure.
16816 2018-07-03 Richard Biener <rguenther@suse.de>
16818 * tree-vect-stmts.c (vect_is_simple_use): Consolidate dumping,
16819 always set *dt. Dump vectype in vectype overload.
16820 * dumpfile.h (dump_gimple_expr): New function.
16821 (dump_gimple_expr_loc): Likewise.
16822 * dumpfile.c (dump_gimple_expr): New function.
16823 (dump_gimple_expr_loc): Likewise.
16825 2018-07-02 Jeff Law <law@redhat.com>
16827 * config/h8300/h8300.md (movqi_h8300, movqi_h8300hs): Consolidate
16828 the H8/300, H8/300H and H8/S variants into a single pattern.
16829 (movhi_h8300, movqi_h8300hs): Similarly.
16830 (pushqi_h8300hs, pushhi_h8300hs): Consolidate into a single pattern.
16831 (QHI mode iterator): New.
16833 * config/h8300/h8300.md: Remove trailing whitespace.
16835 2018-07-02 Jim Wilson <jimw@sifive.com>
16837 * config/riscv/riscv.c (riscv_expand_epilogue): Use emit_jump_insn
16838 instead of emit_insn for interrupt returns.
16839 * config/riscv/riscv.md (riscv_met): Add (return) to rtl.
16840 (riscv_sret, riscv_uret): Likewise.
16842 2018-07-02 David Malcolm <dmalcolm@redhat.com>
16844 * pretty-print.c (selftest::test_pp_format): Move save and restore
16845 of quotes to class auto_fix_quotes, and add an instance.
16846 * selftest.c: Include "intl.h".
16847 (selftest::auto_fix_quotes::auto_fix_quotes): New ctor.
16848 (selftest::auto_fix_quotes::~auto_fix_quotes): New dtor.
16849 * selftest.h (selftest::auto_fix_quotes): New class.
16851 2018-07-02 Richard Henderson <richard.henderson@linaro.org>
16853 * config/aarch64/aarch64-protos.h, config/aarch64/aarch64.c
16854 (aarch64_sve_prepare_conditional_op): Remove.
16855 * config/aarch64/aarch64-sve.md (cond_<SVE_INT_BINARY><SVE_I>):
16856 Allow aarch64_simd_reg_or_zero as select operand; remove
16857 the aarch64_sve_prepare_conditional_op call.
16858 (cond_<SVE_INT_BINARY_SD><SVE_SDI>): Likewise.
16859 (cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
16860 (*cond_<SVE_INT_BINARY><SVE_I>_z): New pattern.
16861 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_z): New pattern.
16862 (*cond_<SVE_COND_FP_BINARY><SVE_F>_z): New pattern.
16863 (*cond_<SVE_INT_BINARY><SVE_I>_any): New pattern.
16864 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_any): New pattern.
16865 (*cond_<SVE_COND_FP_BINARY><SVE_F>_any): New pattern
16866 and a splitters to match all of the *_any patterns.
16867 * config/aarch64/predicates.md (aarch64_sve_any_binary_operator): New.
16869 * config/aarch64/iterators.md (SVE_INT_BINARY_REV): Remove.
16870 (SVE_COND_FP_BINARY_REV): Remove.
16871 (sve_int_op_rev, sve_fp_op_rev): New.
16872 * config/aarch64/aarch64-sve.md (*cond_<SVE_INT_BINARY><SVE_I>_0): New.
16873 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_0): New.
16874 (*cond_<SVE_COND_FP_BINARY><SVE_F>_0): New.
16875 (*cond_<SVE_INT_BINARY><SVE_I>_2): Rename, add movprfx alternative.
16876 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_2): Similarly.
16877 (*cond_<SVE_COND_FP_BINARY><SVE_F>_2): Similarly.
16878 (*cond_<SVE_INT_BINARY><SVE_I>_3): Similarly; use sve_int_op_rev.
16879 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_3): Similarly.
16880 (*cond_<SVE_COND_FP_BINARY><SVE_F>_3): Similarly; use sve_fp_op_rev.
16882 * config/aarch64/aarch64-sve.md (cond_<SVE_COND_FP_BINARY><SVE_F>):
16883 Remove match_dup 1 from the inner unspec.
16884 (*cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
16886 * config/aarch64/aarch64.md (movprfx): New attr.
16887 (length): Default movprfx to 8.
16888 * config/aarch64/aarch64-sve.md (*mul<SVE_I>3): Add movprfx alt.
16889 (*madd<SVE_I>, *msub<SVE_I): Likewise.
16890 (*<su>mul<SVE_I>3_highpart): Likewise.
16891 (*<SVE_INT_BINARY_SD><SVE_SDI>3): Likewise.
16892 (*v<ASHIFT><SVE_I>3): Likewise.
16893 (*<su><MAXMIN><SVE_I>3): Likewise.
16894 (*<su><MAXMIN><SVE_F>3): Likewise.
16895 (*fma<SVE_F>4, *fnma<SVE_F>4): Likewise.
16896 (*fms<SVE_F>4, *fnms<SVE_F>4): Likewise.
16897 (*div<SVE_F>4): Likewise.
16899 2018-07-02 Richard Sandiford <richard.sandiford@arm.com>
16901 * tree-vect-patterns.c (vect_recog_widen_shift_pattern): Fix typo
16904 2018-07-02 Richard Biener <rguenther@suse.de>
16906 PR tree-optimization/86363
16907 * tree-ssa-sccvn.c (vn_reference_lookup_3): Check the
16908 memset argument refers to a non-variable address.
16910 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
16912 * tree-vrp.c (extract_range_from_binary_expr_1): Abstract a lot of the
16913 {PLUS,MINUS}_EXPR code to...
16914 (adjust_symbolic_bound): ...here,
16915 (combine_bound): ...here,
16916 (set_value_range_with_overflow): ...and here.
16918 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
16920 * tree-vrp.c (extract_range_from_unary_expr): Abstract ABS_EXPR
16922 (extract_range_from_abs_expr): ...here.
16924 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
16926 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
16927 -fno-omit-frame-pointer when not optimizing.
16929 2018-07-02 Martin Liska <mliska@suse.cz>
16932 * ipa-pure-const.c (malloc_candidate_p): Revert usage of ::get.
16933 (propagate_nothrow): Likewise.
16935 2018-07-02 Martin Liska <mliska@suse.cz>
16938 * ipa-inline.c (early_inliner): Revert wrongly added ::get call.
16940 2018-07-02 David Malcolm <dmalcolm@redhat.com>
16942 * dumpfile.c (dump_generic_expr_loc): Undo removal of this
16943 function in r262149, changing "loc" param from source_location to
16944 const dump_location_t &.
16945 * dumpfile.h (dump_generic_expr_loc): Undo removal of this
16946 declaration, as above.
16948 2018-07-01 Paul Koning <ni1d@arrl.net>
16950 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
16951 -munit-asm, -mgnu-asm, -mdec-asm.
16952 * config/pdp11/pdp11-protos.h (pdp11_gen_int_label): New.
16953 (pdp11_output_labelref): New.
16954 (pdp11_output_def): New.
16955 (pdp11_output_addr_vec_elt): New.
16956 * config/pdp11/pdp11.c: Use tab between opcode and operands. Use
16957 %# and %@ format codes.
16958 (pdp11_option_override): New.
16959 (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Define.
16960 (pdp11_output_ident): New.
16961 (pdp11_asm_named_section): New.
16962 (pdp11_asm_init_sections): New.
16963 (pdp11_file_start): New.
16964 (pdp11_file_end): New.
16965 (output_ascii): Use .ascii/.asciz for -mdec-asm.
16966 (pdp11_asm_print_operand): Update %# and %$ for -mdec-asm. Add
16967 %o, like %c but octal.
16968 (pdp11_option_override): New.
16969 * config/pdp11/pdp11.h (TEXT_SECTION_ASM_OP): Update for
16971 (DATA_SECTION_ASM_OP): Ditto.
16972 (READONLY_DATA_SECTION_ASM_OP): New.
16973 (IS_ASM_LOGICAL_LINE_SEPARATOR): New.
16974 (ASM_GENERATE_INTERNAL_LABEL): Use new function.
16975 (ASM_OUTPUT_LABELREF): Ditto.
16976 (ASM_OUTPUT_DEF): Ditto.
16977 (ASM_OUTPUT_EXTERNAL): New.
16978 (ASM_OUTPUT_SOURCE_FILENAME): New.
16979 (ASM_OUTPUT_ADDR_VEC_ELT): Use new function.
16980 (ASM_OUTPUT_SKIP): Update for -mdec-asm.
16981 * config/pdp11/pdp11.md: Use tab between opcode and operands. Use
16982 %# and %@ format codes.
16983 * config/pdp11/pdp11.opt (mgnu-asm): New.
16984 (mdec-asm): Conflicts with -mgnu-asm and -munix-asm.
16985 (munix-asm): Conflicts with -mdec-asm and -mgnu-asm.
16986 * doc/invoke.txt (PDP-11 Options): Add -mgnu-asm.
16988 2018-07-01 Aldy Hernandez <aldyh@redhat.com>
16990 * tree-ssa-threadupdate.c (mark_threaded_blocks): Avoid
16991 dereferencing path[] beyond its length.
16993 (debug_all_paths): New.
16994 (rewire_first_differing_edge): New.
16995 (adjust_paths_after_duplication): New.
16996 (duplicate_thread_path): Call adjust_paths_after_duplication.
16998 (thread_through_all_blocks): Add new argument to
16999 duplicate_thread_path.
17001 2018-06-30 Jim Wilson <jimw@sifive.com>
17003 * config/riscv/predicates.md (p2m1_shift_operand): New.
17004 (high_mask_shift_operand): New.
17005 * config/riscv/riscv.md (lshrsi3_zero_extend_3+1): New combiner
17006 pattern using p2m1_shift_operand.
17007 (lshsi3_zero_extend_3+2): New combiner pattern using
17008 high_mask_shift_operand.
17010 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17012 * tree-vect-patterns.c (vect_get_external_def_edge): New function,
17014 (vect_recog_rotate_pattern): ...here.
17015 (vect_convert_input): Try to insert casts of invariants in the
17017 * tree-vect-loop-manip.c (vect_loop_versioning): Don't require the
17018 preheader to be empty.
17020 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17022 * tree-vect-patterns.c (append_pattern_def_seq): Take an optional
17023 vector type. If given, install it in the new statement's
17024 STMT_VINFO_VECTYPE.
17025 (vect_element_precision): New function.
17026 (vect_unpromoted_value): New struct.
17027 (vect_unpromoted_value::vect_unpromoted_value): New function.
17028 (vect_unpromoted_value::set_op): Likewise.
17029 (vect_look_through_possible_promotion): Likewise.
17030 (vect_joust_widened_integer, vect_joust_widened_type): Likewise.
17031 (vect_widened_op_tree, vect_convert_input): Likewise.
17032 (vect_convert_inputs, vect_convert_output): Likewise.
17033 (vect_recog_dot_prod_pattern): Use vect_look_through_possible_promotion
17034 to handle the optional cast of the multiplication result and
17035 vect_widened_op_tree to detect the widened multiplication itself.
17036 Do not require the input and output of promotion casts to have
17037 the same sign, but base the signedness of the operation on the
17038 input rather than the result. If the pattern includes two
17039 promotions, check that those promotions have the same sign.
17040 Do not restrict the MULT_EXPR handling to a double-width result;
17041 handle quadruple-width results and wider. Use vect_convert_inputs
17042 to convert the inputs to the common type.
17043 (vect_recog_sad_pattern): Use vect_look_through_possible_promotion
17044 to handle the optional cast of the ABS result. Also allow a sign
17045 change or a sign extension between the ABS and MINUS.
17046 Use vect_widened_op_tree to detect the widened subtraction and use
17047 vect_convert_inputs to convert the inputs to the common type.
17048 (vect_handle_widen_op_by_const): Delete.
17049 (vect_recog_widen_op_pattern): New function.
17050 (vect_recog_widen_mult_pattern): Use it.
17051 (vect_recog_widen_shift_pattern): Likewise.
17052 (vect_recog_widen_sum_pattern): Use
17053 vect_look_through_possible_promotion to handle the promoted
17056 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17058 * gimple-iterator.c (gsi_for_stmt): Add a new overload that takes
17059 the containing gimple_seq *.
17060 * gimple-iterator.h (gsi_for_stmt): Declare it.
17061 * tree-vect-patterns.c (vect_recog_dot_prod_pattern)
17062 (vect_recog_sad_pattern, vect_recog_widen_sum_pattern)
17063 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
17064 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
17065 (vect_recog_mask_conversion_pattern): Remove STMT_VINFO_IN_PATTERN_P
17067 (vect_init_pattern_stmt, vect_set_pattern_stmt): New functions,
17069 (vect_mark_pattern_stmts): ...here. Handle cases in which the
17070 statement being replaced is part of an existing pattern
17071 definition sequence, inserting the new pattern statements before
17073 (vect_pattern_recog_1): Don't return a bool. If the statement
17074 is already part of a pattern, instead apply pattern matching
17075 to the pattern definition statements. Don't clear the
17076 STMT_VINFO_RELATED_STMT if is_pattern_stmt_p.
17077 (vect_pattern_recog): Don't break after the first match;
17078 continue processing the pattern definition statements instead.
17079 Don't bail out for STMT_VINFO_IN_PATTERN_P here.
17081 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17083 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
17084 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
17085 (vect_recog_widen_sum_pattern): Use it.
17087 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17089 * tree-vect-loop.c (vectorizable_reduction): Assert that the
17090 phi is not a pattern statement and has not been replaced by
17091 a pattern statement.
17092 * tree-vect-patterns.c (type_conversion_p): Don't check
17093 STMT_VINFO_IN_PATTERN_P.
17094 (vect_recog_vector_vector_shift_pattern): Likewise.
17095 (vect_recog_dot_prod_pattern): Expect vect_is_simple_use to return
17096 the pattern statement rather than the original statement; check
17097 directly for a WIDEN_MULT_EXPR here.
17098 * tree-vect-slp.c (vect_get_and_check_slp_defs): Expect
17099 vect_is_simple_use to return the pattern statement rather
17100 than the original statement; use is_pattern_stmt_p to check
17101 for such a pattern statement.
17102 * tree-vect-stmts.c (process_use): Expect vect_is_simple_use
17103 to return the pattern statement rather than the original statement;
17104 don't do the same transformation here.
17105 (vect_is_simple_use): If the defining statement has been replaced
17106 by a pattern statement, return the pattern statement instead.
17107 Remove the corresponding (local) transformation from the vectype
17110 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17112 * tree-vectorizer.h (vect_is_simple_use): Move the gimple ** to the
17113 end and default to null.
17114 * tree-vect-loop.c (vect_create_epilog_for_reduction)
17115 (vectorizable_reduction): Update calls accordingly, dropping the
17116 gimple ** argument if the passed-back statement isn't needed.
17117 * tree-vect-patterns.c (vect_get_internal_def, type_conversion_p)
17118 (vect_recog_rotate_pattern): Likewise.
17119 (vect_recog_mask_conversion_pattern): Likewise.
17120 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
17121 (vect_mask_constant_operand_p): Likewise.
17122 * tree-vect-stmts.c (is_simple_and_all_uses_invariant, process_use):
17123 (vect_model_simple_cost, vect_get_vec_def_for_operand): Likewise.
17124 (get_group_load_store_type, get_load_store_type): Likewise.
17125 (vect_check_load_store_mask, vect_check_store_rhs): Likewise.
17126 (vectorizable_call, vectorizable_simd_clone_call): Likewise.
17127 (vectorizable_conversion, vectorizable_assignment): Likewise.
17128 (vectorizable_shift, vectorizable_operation): Likewise.
17129 (vectorizable_store, vect_is_simple_cond): Likewise.
17130 (vectorizable_condition, vectorizable_comparison): Likewise.
17131 (get_same_sized_vectype, vect_get_mask_type_for_stmt): Likewise.
17132 (vect_is_simple_use): Rename the def_stmt argument to def_stmt_out
17133 and move it to the end. Cope with null def_stmt_outs.
17135 2018-06-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
17137 * Makefile.in (FLAGS_TO_PASS): Add RANLIB_FOR_TARGET.
17139 2018-06-29 Jeff Law <law@redhat.com>
17141 * config/v850/v850.c (v850_legitimate_address_p): Handle large
17142 displacements for TARGET_V850E2V3 and newer.
17143 (TARGET_LRA_P): Remove. Defaults to LRA now.
17144 * config/v850/v850.md (sign23byte_load): Remove.
17145 (unsign23byte_load, sign23hword_load, unsign23hword_load): Likewise.
17146 (23word_load, 23byte_store, 23hword_store, 23word_store): Likewise.
17148 2018-06-29 Martin Liska <mliska@suse.cz>
17151 * coverage.c (coverage_init): Mangle full path name.
17152 * doc/invoke.texi: Document the change.
17153 * gcov-io.c (mangle_path): New.
17154 * gcov-io.h (mangle_path): Likewise.
17155 * gcov.c (mangle_name): Use mangle_path for path mangling.
17157 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17159 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
17160 if starting source register is not even.
17162 2018-06-29 Martin Liska <mliska@suse.cz>
17164 PR tree-optimization/86263
17165 * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
17166 Make edge redirection.
17168 2018-06-29 David Malcolm <dmalcolm@redhat.com>
17170 * dumpfile.c (dump_loc): Add indentation based on scope depth.
17171 (dump_scope_depth): New variable.
17172 (get_dump_scope_depth): New function.
17173 (dump_begin_scope): New function.
17174 (dump_end_scope): New function.
17175 * dumpfile.h (get_dump_scope_depth): New declaration.
17176 (dump_begin_scope): New declaration.
17177 (dump_end_scope): New declaration.
17178 (class auto_dump_scope): New class.
17179 (AUTO_DUMP_SCOPE): New macro.
17180 * tree-vectorizer.h (DUMP_VECT_SCOPE): Reimplement in terms of
17183 2018-06-29 Richard Biener <rguenther@suse.de>
17185 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Assert
17186 compute_all_dependences succeeds.
17187 * tree-vect-loop.c (vect_get_datarefs_in_loop): Fail early if we
17188 exceed --param loop-max-datarefs-for-datadeps.
17190 2018-06-29 Jakub Jelinek <jakub@redhat.com>
17192 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
17194 2018-06-28 Uros Bizjak <ubizjak@gmail.com>
17197 * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): Use
17198 alternative 0 in preferred_for_speed attribute.
17200 2018-06-28 Paul Koning <ni1d@arrl.net>
17202 * config/pdp11/pdp11-protos.h (pdp11_shift_length): New function.
17203 * config/pdp11/pdp11.c (pdp11_shift_length): New function.
17204 * config/pdp11/pdp11.h (ADJUST_INSN_LENGTH): Remove.
17205 * config/pdp11/pdp11.md: Correct "length" attribute calculation
17206 for shift insn patterns.
17208 2018-06-28 David Malcolm <dmalcolm@redhat.com>
17210 * cgraph.c (cgraph_node::get_body): Replace assignments to
17211 "dump_file" with calls to set_dump_file.
17212 * dumpfile.c (alt_dump_file): Make static, and group with...
17213 (alt_flags): ...this definition.
17214 (dumps_are_enabled): New variable.
17215 (refresh_dumps_are_enabled): New function.
17216 (set_dump_file): New function.
17217 (set_alt_dump_file): New function.
17218 (gcc::dump_manager::dump_start): Replace assignments to
17219 "dump_file" and "alt_dump_file" with calls to set_dump_file and
17221 (gcc::dump_manager::dump_finish): Likewise.
17222 * dumpfile.h (alt_dump_file): Delete decl.
17223 (dumps_are_enabled): New variable decl.
17224 (set_dump_file): New function decl.
17225 (dump_enabled_p): Rewrite in terms of new "dumps_are_enabled"
17227 * tree-nested.c (lower_nested_functions): Replace assignments to
17228 "dump_file" with calls to set_dump_file.
17230 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
17232 * tree-cfg.c (verify_gimple_in_cfg): Call verify_location on the
17233 goto_locus of each outgoing edge of each basic block.
17235 2018-06-28 Richard Biener <rguenther@suse.de>
17237 * dwarf2out.c (decl_scope_table): Remove.
17238 (push_decl_scope): Likewise.
17239 (pop_decl_scope): Likewise.
17240 (gen_type_die_for_member): Do not call push/pop_decl_scope.
17241 (gen_struct_or_union_type_die): Likewise.
17242 (gen_tagged_type_die): Likewise.
17243 (dwarf2out_init): Do not initialize decl_scope_table.
17244 (dwarf2out_c_finalize): Do not free it.
17246 2018-06-28 Richard Biener <rguenther@suse.de>
17248 * dwarf2out.c (gen_subprogram_die): Use is_unit_die when
17249 deciding whether to not re-use a DIE.
17251 2018-06-28 Richard Biener <rguenther@suse.de>
17253 * dwarf2out.c (gen_subprogram_die): Always re-use DIEs with an
17254 DW_AT_abstract_origin attribute.
17256 2018-06-28 Martin Liska <mliska@suse.cz>
17258 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
17259 Use newly introduced constants.
17260 * tree-switch-conversion.h (struct jump_table_cluster):
17261 Define max_ratio_for_size and max_ratio_for_speed.
17263 2018-06-28 Martin Liska <mliska@suse.cz>
17265 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
17266 Add new checking assert to catch invalid state.
17267 (jump_table_cluster::can_be_handled): Handle single case
17269 (jump_table_cluster::is_beneficial): Bail out for such case.
17270 (bit_test_cluster::find_bit_tests):
17271 Add new checking assert to catch invalid state.
17272 (bit_test_cluster::can_be_handled): Handle single case
17274 (bit_test_cluster::is_beneficial): Bail out for such case.
17275 (switch_decision_tree::analyze_switch_statement):
17278 2018-06-28 Martin Liska <mliska@suse.cz>
17280 * common.opt: Introduce -completion option.
17281 * gcc.c (driver_handle_option): Handle it.
17282 (driver::main): Print completions if completion
17284 * opt-suggestions.c (option_proposer::get_completions):
17286 (option_proposer::suggest_completion): Likewise.
17287 (option_proposer::find_param_completions): Likewise.
17288 (verify_autocompletions): Likewise.
17289 (test_completion_valid_options): Likewise.
17290 (test_completion_valid_params): Likewise.
17291 (in_completion_p): Likewise.
17292 (empty_completion_p): Likewise.
17293 (test_completion_partial_match): Likewise.
17294 (test_completion_garbage): Likewise.
17295 (opt_proposer_c_tests): Likewise.
17296 * opt-suggestions.h: Declare new functions.
17297 * opts.c (common_handle_option): Handle OPT__completion_.
17298 * selftest-run-tests.c (selftest::run_tests): Add
17299 opt_proposer_c_tests.
17300 * selftest.c (assert_str_startswith): New.
17301 * selftest.h (assert_str_startswith): Likewise.
17302 (opt_proposer_c_tests): New.
17303 (ASSERT_STR_STARTSWITH): Likewise.
17305 2018-06-28 Martin Liska <mliska@suse.cz>
17307 * Makefile.in: Add opt-suggestions.o.
17308 * gcc-main.c: Include opt-suggestions.h.
17309 * gcc.c (driver::driver): Likewise.
17310 (driver::~driver): Remove m_option_suggestions.
17311 (driver::build_option_suggestions): Moved to option_proposer.
17312 (driver::suggest_option): Likewise.
17313 (driver::handle_unrecognized_options): Use option_proposer.
17314 * gcc.h (class driver): Add new memver m_option_proposer.
17315 * opt-suggestions.c: New file.
17316 * opt-suggestions.h: New file.
17318 2018-06-28 Martin Liska <mliska@suse.cz>
17320 * vec.h (class auto_string_vec): New (moved from auto_argvec).
17321 (auto_string_vec::~auto_string_vec): Likewise.
17323 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
17325 * tree-inline.h (struct copy_body_data): Move remapping_type_depth and
17326 prevent_decl_creation_for_types fields up and add reset_location field.
17327 * tree-inline.c (remap_gimple_stmt): Force input_location on the new
17328 statement if id->reset_location is true.
17329 (copy_edges_for_bb): Do not set goto_locus on the new edges if
17330 id->reset_location is true.
17331 (copy_phis_for_bb): Force input_location on the arguments if
17332 id->reset_location is true.
17333 (expand_call_inline): Set id->reset_location if DECL_IGNORED_P
17334 is set on the function to be inlined.
17336 2018-06-27 Stephan Bergmann <sbergman@redhat.com>
17338 * doc/invoke.texi (Debugging Options): Add -gsplit-dwarf.
17340 2018-06-27 Dimitar Dimitrov <dimitar@dinux.eu>
17342 * lra-eliminations.c (update_reg_eliminate): Mark all spanning hard
17343 registers for Pmode.
17344 * lra-lives.c (check_pseudos_live_through_calls): Mark all spanning
17345 hard registers for the clobbered pseudo.
17347 2018-06-27 Paul Koning <ni1d@arrl.net>
17349 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
17350 mutually exclusive options.
17351 * config/pdp11/constraints.md (h): New constraint.
17352 (O): Update definition to match shift code generation.
17353 (D): New constraint.
17354 * config/pdp11/pdp11-modes.def (CCNZ): Define mode.
17356 * config/pdp11/pdp11-protos.h (int_no_side_effect_operand): New
17358 (output_jump): Change arguments.
17359 (pdp11_fixed_cc_regs): New function.
17360 (pdp11_cc_mode): Ditto.
17361 (pdp11_expand_shift): Ditto.
17362 (pdp11_assemble_shift): Ditto.
17363 (pdp11_small_shift): Ditto.
17364 (pdp11_branch_cost): Remove.
17365 * config/pdp11/pdp11.c (pdp11_assemble_integer): Remove comments
17367 (pdp11_register_move_cost): Update for CC registers.
17368 (pdp11_rtx_costs): Add case for LSHIFTRT.
17369 (pdp11_output_jump): Add CCNZ mode conditional branches.
17370 (notice_update_cc_on_set): Remove.
17371 (pdp11_cc_mode): New function.
17372 (simple_memory_operand): Correct pre/post decrement case.
17373 (no_side_effect_operand): New function.
17374 (pdp11_regno_reg_class): Add CC_REGS class.
17375 (pdp11_fixed_cc_regs): New function.
17376 (pdp11_small_shift): New function.
17377 (pdp11_expand_shift): New function to expand shift insns.
17378 (pdp11_assemble_shift): New function to output shifts.
17379 (pdp11_branch_cost): Remove.
17380 (pdp11_modes_tieable_p): Make QI/HI modes tieable.
17381 * config/pdp11/pdp11.h (SIZE_TYPE): Ensure 16-bit type.
17382 (WCHAR_TYPE): Ditto.
17383 (PTRDIFF_TYPE): Ditto.
17384 (ADJUST_INSN_LENGTH): New macro.
17385 (FIXED_REGISTERS): Add CC registers.
17386 (CALL_USED_REGISTERS): Ditto.
17387 (reg_class): Ditto.
17388 (REG_CLASS_NAMES): Ditto.
17389 (REG_CLASS_CONTENTS): Ditto.
17390 (SELECT_CC_MODE): Use new function.
17391 (TARGET_FLAGS_REGNUM): New macro.
17392 (TARGET_FIXED_CONDITION_CODE_REGS): Ditto.
17393 (cc0_reg_rtx): Remove.
17394 (CC_STATUS_MDEP): Remove.
17395 (CC_STATUS_MDEFP_INIT): Remove.
17396 (CC_IN_FPU): Remove.
17397 (NOTICE_UPDATE_CC): Remove.
17398 (REGISTER_NAMES): Add CC registers.
17399 (BRANCH_COST): Change to constant 1.
17400 * config/pdp11/pdp11.md: Rewrite for CCmode condition code
17402 * config/pdp11/pdp11.opt (mbcopy): Remove.
17403 (mbcopy-builtin): Remove.
17404 (mbranch-cheap): Remove.
17405 (mbranch-expensive): Remove.
17406 * config/pdp11/predicates.md (expand_shift_operand): Update to
17407 match shift code generation.
17408 (ccnz_operator): New predicate.
17409 * doc/invoke.texi (PDP-11 Options): Remove deleted options
17410 -mbcopy, -mbcopy-builtin, -mbranch-cheap, -mbranch-expensive.
17411 Remove non-existent option -mabshi, -mno-abshi. Document mutually
17413 * doc/md.texi (PDP-11): Document new D and h constraints. Update
17414 description of O constraint.
17416 2018-06-27 Jeff Law <law@redhat.com>
17417 Austin Law <austinklaw@gmail.com>
17419 * config/v850/v850.md (addsi3_set_flags): New pattern.
17420 (subsi3_set_flags, negsi2_set_flags, andsi3_set_flags): Likewise.
17421 (iorsi3_set_flags, xorsi3_set_flags, one_cmplsi2_set_flags): Likewise.
17422 (zero_extendhisi2_v850_set_flags): Likewise.
17423 (zero_extendqisi2_v850_set_flags): Likewise.
17424 (ashlsi3_set_flags, ashlsi3_v850e2_set_flags): Likewise.
17425 (lshrsi3_set_flags, lshrsi3_v850e2_set_flags): Likewise.
17426 (ashrsi3_set_flags, ashrsi3_v850e2_set_flags): Likewise.
17428 * config/v850/v850-protos.h (notice_update_cc): Remove.
17429 * config/v850/v850.c (v850_compare_op0, v850_compare_op1): Remove.
17430 (v850_print_operand): Handle 'D' and "d".
17431 (v850_select_cc_mode): Remove ATTRIBUTE_UNUSED for last argument.
17432 Add handling of arithmetic/logical operations compared against zero.
17433 (v850_gen_float_compare): Remove ATTRIBUTE_UNUSED for last argument.
17434 Do not look at v850_compare_op, instead get mode from last argument.
17435 (v850_gen_compare): Remove
17436 (increment_stack): Use addsi3_clobber_flags to avoid splitting failure
17437 after reload for prologue insns.
17438 (expand_prologue): Account for CLOBBER of CC_REGNUM in various
17440 (construct_save_jarl): Likewise.
17441 (TARGET_FLAGS_REGNUM): Define.
17442 * config/v850/v850.h (v850_compare_op0, v850_compare_op1): Remove.
17443 (NOTICE_UPDATE_CC): Remove.
17444 * config/v850/v850.md (v850_tst1): Use (reg:CCZ CC_REGNUM) rather
17445 than cc0. Conditionalize on reload_completed.
17446 (cmpsi_insn, setfcc_insn): Likewise.
17447 (tst1 splitter): Turn into define_and_split which sets the flags
17449 (cstoresi4, cbranchsf4, cbranchdf4, cbranchsi4_insn): Likewise.
17450 (cbranchsi4, branch_normal, branch_invert): Do not expose cc0 here.
17451 (cstoresf4, cstoredf4): Clobber the flags.
17452 (cmpsi, cmpsf, cmpdf): Remove expanders.
17453 (setf_insn): Remove pattern.
17454 (addsi3): Turn into define_and_split which clobbers the flags after
17455 reload and a suitable pattern (addsi3_clobber_flags) for use after
17457 (subsi3, negsi2, andsi3, iorsi3, xorsi3, one_cmplsi2) Likewise.
17458 (ashlsi3, ashlsi3_v850e2, lshrsi3, lsh4si3_v850e2): Likewise.
17459 (ashrsi3, ashrsi3_v850e2): Likewise.
17460 (bins): Clobber the flags.
17461 (movsicc_normal_cc, movsicc_normal, movsicc_tst1): Likewise.
17462 (movsicc_tst1_revesed, sasf, swap and rotate patterns): Likewise.
17463 (fix_loop_counter, call_internal_short, call_internal_long): Likewise.
17464 (call_value_internal_short, call_value_internal_long): Likewise.
17465 (callt_save_interrupt, callt_return_interrupt): Likewise.
17466 (save_interrupt, return_interrupt): Likewise.
17467 (callt_save_all_interrupt, save_all_interrupt): Likewise.
17468 (_save_all_interrupt, callt_restore_all_interrupt): Likewise.
17469 (restore_all_interrupt, _restore_all_interrupt): Likewise.
17470 (All FP comparisons): Only allow after reload has completed.
17472 (divh, divhu): Tweak output template.
17473 (branch_z_normal, branch_z_invert): Remove
17474 (branch_nz_normal, branch_nz_invert): Likewise.
17475 (extendhisi_insn, extendqisi_insn): Do not clobber flags.
17477 * config/v850/v850-modes.def (CCZ, CCNZ): Add new modes.
17478 * config/v850/v850.c (notice_update_cc): Remove.
17479 * config/v850/v850.h (CC_OVERFLOW_UNUSABLE): Remove
17480 (CC_NO_CARRY): Likewise.
17481 (NOTICE_UPDATE_CC): Define to nothing.
17482 * config/v850/v850.md: Remove block comment on cc0 handling
17483 Remove "cc" attribute from all patterns. Remove cc_status handling
17484 from all patterns. Minor formatting fixes.
17486 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17488 * config/aarch64/aarch64-cores.def (cortex-a76): New entry.
17489 (cortex-a76.cortex-a55): Likewise.
17490 * config/aarch64/aarch64-tune.md: Regenerate.
17491 * doc/invoke.texi (AArch64 Options): Document cortex-a76 and
17492 cortex-a76.cortex-a55.
17494 2018-06-27 Jeff Law <law@redhat.com>
17496 * config/v850/t-v850 (MULTILIB_OPTIONS): Remove 8byte-align.
17497 (MULTILIB_DIRNAMES): Similarly.
17499 2018-06-27 Eric Botcazou <ebotcazou@adacore.com>
17501 * gimple.h (gimple_return_retbnd): Delete.
17502 (gimple_return_set_retbnd): Likewise.
17503 * cgraphunit.c (cgraph_node::expand_thunk): Remove call to
17504 gimple_return_set_retbnd.
17505 * gimple-pretty-print.c (dump_gimple_return): Remove call to
17506 gimple_return_retbnd and adjust.
17507 * tree-inline.h (struct copy_body_data): Remove retbnd field.
17508 * tree-inline.c (remap_gimple_stmt): Remove handling of retbnd.
17509 Explicitly return NULL in a couple more cases. Move assertion
17510 on debug statements and remove unreachable code.
17511 (reset_debug_binding): Do not test id->retbnd.
17512 (expand_call_inline): Do not set it.
17514 2018-06-27 Rasmus Villemoes <rv@rasmusvillemoes.dk>
17516 * configure.ac: Add --disable-gcov option.
17517 * configure: Regenerate.
17518 * Makefile.in: Honour @enable_gcov@.
17519 * doc/install.texi: Document --disable-gcov.
17521 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17523 * config/arm/arm-cpus.in (cortex-a76): New entry.
17524 (cortex-a76.cortex-a55): Likewise.
17525 * config/arm/arm-tables.opt: Regenerate.
17526 * config/arm/arm-tune.md: Likewise.
17527 * config/arm/driver-arm.c (arm_cpu_table): Add Cortex-A76 entry.
17528 * doc/invoke.texi (ARM Options): Document cortex-a76 and
17529 cortex-a76.cortex-a55.
17531 2018-06-27 Tamar Christina <tamar.christina@arm.com>
17534 * config/aarch64/aarch64.md (*movhf_aarch64): Add dup v0.4h pattern.
17536 2018-06-27 Siddhesh Poyarekar <siddhesh@sourceware.org>
17538 * config/aarch64/aarch64.h (CALL_USE_REGISTERS): Fix obsolete
17540 (EPILOGUE_USES): Likewise.
17542 2018-06-26 Eric Botcazou <ebotcazou@adacore.com>
17544 * tree-inline.c (remap_location): New function extracted from...
17545 (copy_edges_for_bb): Add ID parameter. Remap goto_locus.
17546 (copy_phis_for_bb): ...here. Call remap_location.
17547 (copy_cfg_body): Adjust call to copy_edges_for_bb.
17549 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
17551 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
17552 unaligned vsx for 16B memset.
17554 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
17557 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
17558 ieee128_float_type_node to long_double_type_node unless
17559 TARGET_LONG_DOUBLE_128 is set.
17561 2018-06-26 David Malcolm <dmalcolm@redhat.com>
17563 * cfgloop.c (get_loop_location): Convert return type from
17564 location_t to dump_user_location_t, replacing INSN_LOCATION lookups
17565 by implicit construction from rtx_insn *, and using
17566 dump_user_location_t::from_function_decl for the fallback case.
17567 * cfgloop.h (get_loop_location): Convert return type from
17568 location_t to dump_user_location_t.
17569 * cgraphunit.c (walk_polymorphic_call_targets): Update call to
17570 dump_printf_loc to pass in a dump_location_t rather than a
17571 location_t, via the gimple stmt.
17572 * coverage.c (get_coverage_counts): Update calls to
17573 dump_printf_loc to pass in dump_location_t rather than a
17575 * doc/optinfo.texi (Dump types): Convert example of
17576 dump_printf_loc from taking "locus" to taking "insn". Update
17577 description of the "_loc" calls to cover dump_location_t.
17578 * dumpfile.c: Include "backend.h", "gimple.h", "rtl.h", and
17580 (dump_user_location_t::dump_user_location_t): New constructors,
17581 from gimple *stmt and rtx_insn *.
17582 (dump_user_location_t::from_function_decl): New function.
17583 (dump_loc): Make static.
17584 (dump_gimple_stmt_loc): Convert param "loc" from location_t to
17585 const dump_location_t &.
17586 (dump_generic_expr_loc): Delete.
17587 (dump_printf_loc): Convert param "loc" from location_t to
17588 const dump_location_t &.
17589 (selftest::test_impl_location): New function.
17590 (selftest::dumpfile_c_tests): New function.
17591 * dumpfile.h: Include "profile-count.h".
17592 (class dump_user_location_t): New class.
17593 (struct dump_impl_location_t): New struct.
17594 (class dump_location_t): New class.
17595 (dump_printf_loc): Convert 2nd param from source_location to
17596 const dump_location_t &.
17597 (dump_generic_expr_loc): Delete.
17598 (dump_gimple_stmt_loc): Convert 2nd param from source_location to
17599 const dump_location_t &.
17600 * gimple-fold.c (fold_gimple_assign): Update call to
17601 dump_printf_loc to pass in a dump_location_t rather than a
17602 location_t, via the gimple stmt.
17603 (gimple_fold_call): Likewise.
17604 * gimple-loop-interchange.cc
17605 (loop_cand::analyze_iloop_reduction_var): Update for change to
17606 check_reduction_path.
17607 (tree_loop_interchange::interchange): Update for change to
17608 find_loop_location.
17609 * graphite-isl-ast-to-gimple.c (scop_to_isl_ast): Update for
17610 change in return-type of find_loop_location.
17611 (graphite_regenerate_ast_isl): Likewise.
17612 * graphite-optimize-isl.c (optimize_isl): Likewise.
17613 * graphite.c (graphite_transform_loops): Likewise.
17614 * ipa-devirt.c (ipa_devirt): Update call to dump_printf_loc to
17615 pass in a dump_location_t rather than a location_t, via the
17617 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
17618 * ipa.c (walk_polymorphic_call_targets): Likewise.
17619 * loop-unroll.c (report_unroll): Convert "locus" param from
17620 location_t to dump_location_t.
17621 (decide_unrolling): Update for change to get_loop_location's
17623 * omp-grid.c (struct grid_prop): Convert field "target_loc" from
17624 location_t to dump_user_location_t.
17625 (grid_find_single_omp_among_assignments_1): Updates calls to
17626 dump_printf_loc to pass in a dump_location_t rather than a
17627 location_t, via the gimple stmt.
17628 (grid_parallel_clauses_gridifiable): Convert "tloc" from
17629 location_t to dump_location_t. Updates calls to dump_printf_loc
17630 to pass in a dump_location_t rather than a location_t, via the
17632 (grid_inner_loop_gridifiable_p): Likewise.
17633 (grid_dist_follows_simple_pattern): Likewise.
17634 (grid_gfor_follows_tiling_pattern): Likewise.
17635 (grid_target_follows_gridifiable_pattern): Likewise.
17636 (grid_attempt_target_gridification): Convert initialization
17637 of local "grid" from memset to zero-initialization; FIXME: does
17638 this require C++11? Update call to dump_printf_loc to pass in a
17639 optinfo_location rather than a location_t, via the gimple stmt.
17640 * profile.c (read_profile_edge_counts): Updates call to
17641 dump_printf_loc to pass in a dump_location_t rather than a
17643 (compute_branch_probabilities): Likewise.
17644 * selftest-run-tests.c (selftest::run_tests): Call
17646 * selftest.h (dumpfile_c_tests): New decl.
17647 * tree-loop-distribution.c (pass_loop_distribution::execute):
17648 Update for change in return type of find_loop_location.
17649 * tree-parloops.c (parallelize_loops): Likewise.
17650 * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Convert
17651 "locus" from location_t to dump_user_location_t.
17652 (canonicalize_loop_induction_variables): Likewise.
17653 * tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_loop): Update
17654 for change in return type of find_loop_location.
17655 * tree-ssa-loop-niter.c (number_of_iterations_exit): Update call
17656 to dump_printf_loc to pass in a dump_location_t rather than a
17657 location_t, via the stmt.
17658 * tree-ssa-sccvn.c (eliminate_dom_walker::before_dom_children):
17660 * tree-vect-loop-manip.c (find_loop_location): Convert return
17661 type from source_location to dump_user_location_t.
17662 (vect_do_peeling): Update for above change.
17663 (vect_loop_versioning): Update for change in type of
17665 * tree-vect-loop.c (check_reduction_path): Convert "loc" param
17666 from location_t to dump_user_location_t.
17667 (vect_estimate_min_profitable_iters): Update for change in type
17669 * tree-vect-slp.c (vect_print_slp_tree): Convert param "loc" from
17670 location_t to dump_location_t.
17671 (vect_slp_bb): Update for change in type of vect_location.
17672 * tree-vectorizer.c (vect_location): Convert from source_location
17673 to dump_user_location_t.
17674 (try_vectorize_loop_1): Update for change in vect_location's type.
17675 (vectorize_loops): Likewise.
17676 (increase_alignment): Likewise.
17677 * tree-vectorizer.h (vect_location): Convert from source_location
17678 to dump_user_location_t.
17679 (find_loop_location): Convert return type from source_location to
17680 dump_user_location_t.
17681 (check_reduction_path): Convert 1st param from location_t to
17682 dump_user_location_t.
17683 * value-prof.c (check_counter): Update call to dump_printf_loc to
17684 pass in a dump_user_location_t rather than a location_t; update
17685 call to error_at for change in type of "locus".
17686 (check_ic_target): Update call to dump_printf_loc to
17687 pass in a dump_user_location_t rather than a location_t, via the
17690 2018-06-26 Robin Dapp <rdapp@linux.vnet.ibm.com>
17692 * config/s390/s390.h (enum processor_flags): Do not use
17693 default tune parameter when -march was specified.
17695 2018-06-26 Jakub Jelinek <jakub@redhat.com>
17698 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
17699 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
17702 2018-06-26 Richard Biener <rguenther@suse.de>
17704 PR tree-optimization/86287
17706 * tree-vect-loop.c (vect_transform_loop_stmt): Fix read-after-free.
17707 (vect_analyze_loop): Initialize n_stmts.
17709 2018-06-26 Richard Biener <rguenther@suse.de>
17711 PR middle-end/86271
17712 * fold-const.c (fold_convertible_p): Pointer extension
17715 2018-06-26 Alexandre Oliva <aoliva@redhat.com>
17718 * dwarf2out.c (loc_list_has_views): Adjust comments.
17719 (dw_loc_list): Split single cross-partition range with
17722 2018-06-25 Jeff Law <law@redhat.com>
17724 * common/config/v850/v850-common.c (TARGET_DEFAULT_TARGET_FLAGS): Turn
17725 on -mbig-switch by default.
17727 * config/v850/predicates.md (const_float_1_operand): Fix match_code
17729 (const_float_0_operand): Remove unused predicate.
17730 * config/v850/v850.md (define_constants): Remove UNSPEC_LOOP.
17731 (define_c_enum unspec): Add LOOP, RCP and RSQRT constants.
17732 (recipsf2): New expander. Original pattern now called
17734 (recipdf2, recipdf2_insn): Similarly.
17735 (rsqrtsf2, rsqrtsf2_insn): Similarly
17736 (rsqrtdf2, rsqrtdf2_insn): Similarly
17738 2018-06-26 Gerald Pfeifer <gerald@pfeifer.com>
17740 * ginclude/stddef.h: Remove an obsolete comment on FreeBSD 5.
17741 Simplify logic for FreeBSD (twice).
17743 2018-06-25 Martin Sebor <msebor@redhat.com>
17745 PR tree-optimization/86204
17746 * tree-ssa-strlen.c (handle_builtin_strlen): Avoid storing
17747 a strnlen result if it's less than the length of the string.
17749 2018-06-25 Martin Sebor <msebor@redhat.com>
17751 PR tree-optimization/85700
17752 * gimple-fold.c (gimple_fold_builtin_strncat): Adjust comment.
17753 * tree-ssa-strlen.c (is_strlen_related_p): Handle integer subtraction.
17754 (maybe_diag_stxncpy_trunc): Distinguish strncat from strncpy.
17756 2018-06-25 Martin Sebor <msebor@redhat.com>
17758 * doc/extend.texi (Zero-length arrays): Update and clarify.
17760 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
17762 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
17763 added IEEE/IBM long double multilib support on PowerPC little
17764 endian Linux systems.
17765 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
17766 (MULTILIB_DEFAULTS): Likewise.
17767 * config/rs6000/rs6000.c (rs6000_option_override_internal):
17769 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
17770 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
17771 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
17773 2018-06-25 Alexander Monakov <amonakov@ispras.ru>
17775 PR middle-end/86311
17776 * sort.cc (REORDER_23): Avoid memcpy with same destination and source.
17777 (REORDER_45): Likewise.
17779 2018-06-25 Jeff Law <law@redhat.com>
17781 * config/v850/v850.md (divmodhi4): Make sure to sign extend the
17782 dividend to 32 bits. Adjust length.
17783 (udivmodhi4): Cleanup output template. Fix length.
17785 2018-06-25 Carl Love <cel@us.ibm.com>
17787 * config/rs6000/vsx.md: Change word selector to prefered location.
17789 2018-06-25 Richard Biener <rguenther@suse.de>
17791 PR tree-optimization/86304
17792 * tree-vectorizer.c (vectorize_loops): Walk over new possibly
17793 epilogue-if-converted loops as well.
17795 2018-06-25 Jan Hubicka <hubicka@ucw.cz>
17797 * lto-section-out.c (lto_begin_section): Do not print section
17798 name for noaddr and unnumbered dumps.
17800 2018-06-25 Richard Biener <rguenther@suse.de>
17802 * tree-vectorizer.h (struct vec_info_shared): New structure
17803 with parts split out from struct vec_info and loop_nest from
17804 struct _loop_vec_info.
17805 (struct vec_info): Adjust accordingly.
17806 (struct _loop_vec_info): Likewise.
17807 (LOOP_VINFO_LOOP_NEST): Adjust.
17808 (LOOP_VINFO_DATAREFS): Likewise.
17809 (LOOP_VINFO_DDRS): Likewise.
17810 (struct _bb_vec_info): Likewise.
17811 (BB_VINFO_DATAREFS): Likewise.
17812 (BB_VINFO_DDRS): Likewise.
17813 (struct _stmt_vec_info): Add dr_aux member.
17814 (DR_VECT_AUX): Adjust to refer to member of DR_STMTs vinfo.
17815 (DR_MISALIGNMENT_UNINITIALIZED): New.
17816 (set_dr_misalignment): Adjust.
17817 (dr_misalignment): Assert misalign isn't DR_MISALIGNMENT_UNINITIALIZED.
17818 (vect_analyze_loop): Adjust prototype.
17819 (vect_analyze_loop_form): Likewise.
17820 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
17821 Compute dependences lazily.
17822 (vect_record_base_alignments): Use shared datarefs/ddrs.
17823 (vect_verify_datarefs_alignment): Likewise.
17824 (vect_analyze_data_refs_alignment): Likewise.
17825 (vect_analyze_data_ref_accesses): Likewise.
17826 (vect_analyze_data_refs): Likewise.
17827 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Add
17828 constructor parameter for shared part.
17829 (vect_analyze_loop_form): Pass in shared part and adjust.
17830 (vect_analyze_loop_2): Pass in storage for the number of
17831 stmts. Move loop nest finding to the caller. Compute
17833 (vect_analyze_loop): Pass in shared part.
17834 (vect_transform_loop): Verify shared datarefs are unchanged.
17835 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Add
17836 constructor parameter for shared part.
17837 (vect_slp_analyze_bb_1): Pass in shared part and adjust.
17838 (vect_slp_bb): Verify shared datarefs are unchanged before
17840 * tree-vect-stmts.c (ensure_base_align): Adjust for DR_AUX
17842 (new_stmt_vec_info): Initialize DR_AUX misalignment to
17843 DR_MISALIGNMENT_UNINITIALIZED.
17844 * tree-vectorizer.c (vec_info::vec_info): Add constructor
17845 parameter for shared part.
17846 (vec_info::~vec_info): Adjust.
17847 (vec_info_shared::vec_info_shared): New.
17848 (vec_info_shared::~vec_info_shared): Likewise.
17849 (vec_info_shared::save_datarefs): Likewise.
17850 (vec_info_shared::check_datarefs): Likewise.
17851 (try_vectorize_loop_1): Construct shared part live for analyses
17852 of a single loop for multiple vector sizes.
17853 * tree-parloops.c (gather_scalar_reductions): Adjust.
17855 2018-06-25 Richard Biener <rguenther@suse.de>
17857 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
17858 DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
17859 (vect_analyze_data_refs): Remove similar code from here and
17860 simplify accordingly.
17862 2018-06-25 Richard Biener <rguenther@suse.de>
17864 * tree-vect-data-refs.c (vect_check_gather_scatter): Fail
17865 for reverse storage order accesses rather than asserting
17866 they cannot happen here.
17868 2018-06-25 Tom de Vries <tdevries@suse.de>
17871 * config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
17872 Use data16 instead of .byte for insn prefix.
17874 2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
17877 * parser.c (make_char_string_pack): Pass this literal chars
17878 through cpp_interpret_string.
17879 (cp_parser_userdef_numeric_literal): Check the result of
17880 make_char_string_pack.
17882 2018-06-24 Maya Rashish <coypu@sdf.org>
17884 * ginclude/stddef.h: Simplify conditions around avoiding
17885 re-definition of __size_t.
17887 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
17889 * lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
17890 unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
17892 2018-06-22 Maya Rashish <coypu@sdf.org>
17894 * doc/invoke.texi (mno-fancy-math-387): Update for changes
17895 made to OpenBSD and NetBSD through the years.
17897 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
17899 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
17900 behavior of vec_pack (vector double, vector double) to match
17901 behavior of vec_float2 (vector double, vector double).
17903 2018-06-22 Olivier Hainque <hainque@adacore.com>
17905 * gimplify.c (gimplify_function_tree): Prevent creation
17906 of a trampoline for the address of the current function
17907 passed to entry/exit instrumentation hooks.
17909 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
17912 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
17915 2018-06-22 Martin Liska <mliska@suse.cz>
17917 PR tree-optimization/86263
17918 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
17919 Bail out if is_enabled is false.
17920 * tree-switch-conversion.h (jump_table_cluster::is_enabled):
17922 (jump_table_cluster::is_enabled): New function.
17924 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
17926 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
17927 BINFO_BASE_ACCESSES and BINFO_VPTR_FIELD.
17928 * tree-streamer-in.c (streamer_read_tree_bitfields): Likewise.
17929 (lto_input_ts_binfo_tree_pointers): Likewise.
17930 * tree-streamer-out.c (streamer_write_tree_bitfields,
17931 write_ts_binfo_tree_pointers): Likewise.
17932 * tree.c (free_lang_data_in_binfo): Clear BINFO_VPTR_FIELD.
17934 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
17936 * tree.c (free_lang_data_in_type): Free all TYPE_VFIELDs.
17938 2018-06-22 Martin Liska <mliska@suse.cz>
17940 * symbol-summary.h (get): Make it pure and inline move
17941 functionality from ::get function.
17942 (get): Remove and inline into ::get and ::get_create.
17943 (get_create): Move code from ::get function.
17945 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
17948 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
17949 -x assembler-with-cpp.
17951 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
17953 * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define
17954 _FILE_OFFSET_BITS=64 for C++.
17956 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
17958 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
17959 conversion insn that shows up when pr85657-3.c is compiled using
17960 IEEE 128-bit long double.
17961 (neg<mode>2_internal): Use the correct mode to check whether the
17962 mode is IBM extended.
17963 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
17964 multiply and divide external functions from being created more
17967 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
17969 * cfgrtl.c (fixup_reorder_chain): Do not emit NOPs in DECL_IGNORED_P
17971 (rtl_merge_blocks): Likewise. Do not emit a NOP if the location of
17972 the edge can be forwarded.
17973 (cfg_layout_merge_blocks): Likewise.
17975 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
17977 * except.c (finish_eh_generation): Commit edge insertions only after
17978 the EH edges have been redirected from post-landing to landing pads.
17980 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
17982 * tree-nested.c (get_frame_type): Use create_tmp_var_raw instead of
17983 create_tmp_var_for to create the FRAME decl.
17984 (finalize_nesting_tree_1): Do not unchain the FRAME decl.
17986 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
17988 * tree-inline.c (copy_edges_for_bb): Minor tweak.
17989 (maybe_move_debug_stmts_to_successors): Also reset the locus of the
17990 debug statement when resetting its value.
17991 (expand_call_inline): Copy the locus of the call onto the assignment
17992 of the return value, if any. Use local variable in more cases.
17994 2018-06-21 Martin Liska <mliska@suse.cz>
17996 * ipa-pure-const.c (propagate_nothrow): Use
17997 funct_state_summaries->get.
17998 (dump_malloc_lattice): Likewise.
17999 (propagate_malloc): Likewise.
18001 2018-06-21 Richard Biener <rguenther@suse.de>
18003 * lto-streamer-out.c (DFS::DFS_write_tree_body): Update outdated
18004 comment. Follow BLOCK_ABSTRACT_ORIGIN unconditionally.
18005 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Update
18007 * tree-streamer-out.c (write_ts_block_tree_pointers): Stream
18008 BLOCK_ABSTRACT_ORIGIN unconditionally.
18010 2018-06-21 David Malcolm <dmalcolm@redhat.com>
18012 * ipa-cp.c (ipcp_driver): Set edge_clone_summaries to NULL after
18014 * ipa-reference.c (ipa_reference_c_finalize): Delete
18015 ipa_ref_opt_sum_summaries and set it to NULL.
18017 2018-06-21 Tom de Vries <tdevries@suse.de>
18019 PR tree-optimization/85859
18020 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
18021 test with comment from bb_no_side_effects_p.
18023 2018-06-21 Richard Biener <rguenther@suse.de>
18025 PR tree-optimization/86232
18026 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Adjust
18027 max for constant niter.
18029 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
18031 * config/aarch64/aarch64-simd.md
18032 (*aarch64_crypto_aes<aes_op>v16qi_xor_combine): New.
18034 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
18036 * config/aarch64/aarch64-simd.md (aarch64_crypto_aes<aes_op>v16qi):
18037 Make opernads of the unspec commutative.
18039 2018-06-21 Richard Biener <rguenther@suse.de>
18041 * tree-data-ref.c (dr_step_indicator): Handle NULL DR_STEP.
18042 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
18043 Avoid calling vect_mark_for_runtime_alias_test with gathers or scatters.
18044 (vect_analyze_data_ref_dependence): Re-order checks to deal with
18046 (vect_record_base_alignments): Do not record base alignment
18047 for gathers or scatters.
18048 (vect_compute_data_ref_alignment): Drop return value that is always
18049 true. Bail out early for gathers or scatters.
18050 (vect_enhance_data_refs_alignment): Bail out early for gathers
18052 (vect_find_same_alignment_drs): Likewise.
18053 (vect_analyze_data_refs_alignment): Remove dead code.
18054 (vect_slp_analyze_and_verify_node_alignment): Likewise.
18055 (vect_analyze_data_refs): For possible gathers or scatters do
18056 not create an alternate DR, just check their possible validity
18057 and mark them. Adjust DECL_NONALIASED handling to not rely
18058 on DR_BASE_ADDRESS.
18059 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Do not
18060 update inits of gathers or scatters.
18061 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern):
18062 Also copy gather/scatter flag to pattern vinfo.
18064 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
18066 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
18067 behavior of vec_packsu (vector unsigned long long, vector unsigned
18068 long long) to match behavior of vec_packs with same signature.
18070 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
18071 Thomas Schwinge <thomas@codesourcery.com>
18072 Cesar Philippidis <cesar@codesourcery.com>
18074 * gimplify.c (gimplify_scan_omp_clauses): Add support for
18075 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
18076 (gimplify_adjust_omp_clauses): Likewise.
18077 (gimplify_oacc_declare_1): Add support for GOMP_MAP_RELEASE, remove
18078 support for GOMP_MAP_FORCE_{ALLOC,TO,FROM,TOFROM}.
18079 (gimplify_omp_target_update): Update handling of acc update and
18081 * omp-low.c (install_var_field): Remove unused parameter
18082 base_pointers_restrict.
18083 (scan_sharing_clauses): Remove base_pointers_restrict parameter.
18084 Update call to install_var_field. Handle OMP_CLAUSE_{IF_PRESENT,
18086 (omp_target_base_pointers_restrict_p): Delete.
18087 (scan_omp_target): Update call to scan_sharing_clauses.
18088 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_{IF_PRESENT,
18090 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
18091 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
18092 (convert_local_omp_clauses): Likewise.
18093 * tree-pretty-print.c (dump_omp_clause): Likewise.
18094 * tree.c (omp_clause_num_ops): Add entries for OMP_CLAUSE_{IF_PRESENT,
18096 (omp_clause_code_name): Likewise.
18098 2018-06-20 Jakub Jelinek <jakub@redhat.com>
18101 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
18104 PR tree-optimization/86231
18105 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
18106 anti-range don't overwrite *vr0min before using it to compute *vr0max.
18108 2018-06-20 Tom de Vries <tdevries@suse.de>
18110 PR tree-optimization/86097
18111 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Also convert *nit to
18112 iv type if signedness of iv type is not the same as that of *nit.
18114 2018-06-20 Jakub Jelinek <jakub@redhat.com>
18116 * cfgrtl.c (rtl_verify_edges): Formatting fix. If bb->preds has any
18117 EDGE_EH edges, verify they are all EDGE_EH.
18119 2018-06-20 Maya Rashish <coypu@sdf.org>
18121 * ginclude/stddef.h: Limit #include <machine/ansi.h> to NetBSD.
18123 2018-06-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18125 * config/aarch64/aarch64-tuning-flags.def (no_ldp_stp_qregs): New.
18126 * config/aarch64/aarch64.c (xgene1_tunings): Add
18127 AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS to tune_flags.
18128 (aarch64_mode_valid_for_sched_fusion_p):
18129 Allow 16-byte modes.
18130 (aarch64_classify_address): Allow 16-byte modes for load_store_pair_p.
18131 * config/aarch64/aarch64-ldpstp.md: Add peepholes for LDP STP of
18133 * config/aarch64/aarch64-simd.md (load_pair<VQ:mode><VQ2:mode>):
18135 (vec_store_pair<VQ:mode><VQ2:mode>): Likewise.
18136 * config/aarch64/iterators.md (VQ2): New mode iterator.
18138 2018-06-20 Martin Liska <mliska@suse.cz>
18140 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
18141 Change default ratio from 10 to 8.
18143 2018-06-20 Martin Liska <mliska@suse.cz>
18145 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
18147 (bit_test_cluster::find_bit_tests): Likewise.
18148 (switch_decision_tree::analyze_switch_statement): Find clusters.
18149 * tree-switch-conversion.h (struct jump_table_cluster): Document
18152 2018-06-20 Martin Liska <mliska@suse.cz>
18154 * tree-switch-conversion.c (switch_conversion::collect):
18155 Record m_uniq property.
18156 (switch_conversion::expand): Bail out for special conditions.
18157 (group_cluster::~group_cluster): New.
18158 (group_cluster::group_cluster): Likewise.
18159 (group_cluster::dump): Likewise.
18160 (jump_table_cluster::emit): New.
18161 (switch_decision_tree::fix_phi_operands_for_edges): New.
18162 (struct case_node): Remove struct.
18163 (jump_table_cluster::can_be_handled): New.
18164 (case_values_threshold): Moved to header.
18165 (reset_out_edges_aux): Likewise.
18166 (jump_table_cluster::is_beneficial): New.
18167 (bit_test_cluster::can_be_handled): Likewise.
18168 (add_case_node): Remove.
18169 (bit_test_cluster::is_beneficial): New.
18170 (case_bit_test::cmp): New.
18171 (bit_test_cluster::emit): New.
18172 (expand_switch_as_decision_tree_p): Remove.
18173 (bit_test_cluster::hoist_edge_and_branch_if_true): New.
18174 (fix_phi_operands_for_edge): Likewise.
18175 (switch_decision_tree::analyze_switch_statement): New.
18176 (compute_cases_per_edge): Move ...
18177 (switch_decision_tree::compute_cases_per_edge): ... here.
18178 (try_switch_expansion): Likewise.
18179 (switch_decision_tree::try_switch_expansion): Likewise.
18180 (record_phi_operand_mapping): Likewise.
18181 (switch_decision_tree::record_phi_operand_mapping): Likewise.
18182 (emit_case_decision_tree): Likewise.
18183 (switch_decision_tree::emit): Likewise.
18184 (balance_case_nodes): Likewise.
18185 (switch_decision_tree::balance_case_nodes): Likewise.
18186 (dump_case_nodes): Likewise.
18187 (switch_decision_tree::dump_case_nodes): Likewise.
18188 (emit_jump): Likewise.
18189 (switch_decision_tree::emit_jump): Likewise.
18190 (emit_cmp_and_jump_insns): Likewise.
18191 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
18192 (emit_case_nodes): Likewise.
18193 (switch_decision_tree::emit_case_nodes): Likewise.
18194 (conditional_probability): Remove.
18195 * tree-switch-conversion.h (enum cluster_type): New.
18197 (struct cluster): Likewise.
18198 (cluster::cluster): Likewise.
18199 (struct simple_cluster): Likewise.
18200 (simple_cluster::simple_cluster): Likewise.
18201 (struct group_cluster): Likewise.
18202 (struct jump_table_cluster): Likewise.
18203 (struct bit_test_cluster): Likewise.
18204 (struct min_cluster_item): Likewise.
18205 (struct case_tree_node): Likewise.
18206 (case_tree_node::case_tree_node): Likewise.
18207 (jump_table_cluster::case_values_threshold): Likewise.
18208 (struct case_bit_test): Likewise.
18209 (struct switch_decision_tree): Likewise.
18210 (struct switch_conversion): Likewise.
18211 (switch_decision_tree::reset_out_edges_aux): Likewise.
18213 2018-06-20 Martin Liska <mliska@suse.cz>
18215 * tree-switch-conversion.c (MAX_CASE_BIT_TESTS): Remove.
18216 (hoist_edge_and_branch_if_true): Likewise.
18217 (expand_switch_using_bit_tests_p): Likewise.
18218 (struct case_bit_test): Likewise.
18219 (case_bit_test_cmp): Likewise.
18220 (emit_case_bit_tests): Likewise.
18221 (switch_conversion::switch_conversion): New class.
18222 (struct switch_conv_info): Remove old struct.
18223 (collect_switch_conv_info): More to ...
18224 (switch_conversion::collect): ... this.
18225 (check_range): Likewise.
18226 (switch_conversion::check_range): Likewise.
18227 (check_all_empty_except_final): Likewise.
18228 (switch_conversion::check_all_empty_except_final): Likewise.
18229 (check_final_bb): Likewise.
18230 (switch_conversion::check_final_bb): Likewise.
18231 (create_temp_arrays): Likewise.
18232 (switch_conversion::create_temp_arrays): Likewise.
18233 (free_temp_arrays): Likewise.
18234 (gather_default_values): Likewise.
18235 (switch_conversion::gather_default_values): Likewise.
18236 (build_constructors): Likewise.
18237 (switch_conversion::build_constructors): Likewise.
18238 (constructor_contains_same_values_p): Likewise.
18239 (switch_conversion::contains_same_values_p): Likewise.
18240 (array_value_type): Likewise.
18241 (switch_conversion::array_value_type): Likewise.
18242 (build_one_array): Likewise.
18243 (switch_conversion::build_one_array): Likewise.
18244 (build_arrays): Likewise.
18245 (switch_conversion::build_arrays): Likewise.
18246 (gen_def_assigns): Likewise.
18247 (switch_conversion::gen_def_assigns): Likewise.
18248 (prune_bbs): Likewise.
18249 (switch_conversion::prune_bbs): Likewise.
18250 (fix_phi_nodes): Likewise.
18251 (switch_conversion::fix_phi_nodes): Likewise.
18252 (gen_inbound_check): Likewise.
18253 (switch_conversion::gen_inbound_check): Likewise.
18254 (process_switch): Use the newly created class.
18255 (switch_conversion::expand): New.
18256 (switch_conversion::~switch_conversion): New.
18257 * tree-switch-conversion.h: New file.
18259 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18261 * tree-vectorizer.h (NUM_PATTERNS, vect_recog_func_ptr): Move to
18262 tree-vect-patterns.c.
18263 * tree-vect-patterns.c (vect_supportable_direct_optab_p): New function.
18264 (vect_recog_dot_prod_pattern): Use it. Remove the type_in argument.
18265 (vect_recog_sad_pattern): Likewise.
18266 (vect_recog_widen_sum_pattern): Likewise.
18267 (vect_recog_pow_pattern): Likewise. Check for a null vectype.
18268 (vect_recog_widen_shift_pattern): Remove the type_in argument.
18269 (vect_recog_rotate_pattern): Likewise.
18270 (vect_recog_mult_pattern): Likewise.
18271 (vect_recog_vector_vector_shift_pattern): Likewise.
18272 (vect_recog_divmod_pattern): Likewise.
18273 (vect_recog_mixed_size_cond_pattern): Likewise.
18274 (vect_recog_bool_pattern): Likewise.
18275 (vect_recog_mask_conversion_pattern): Likewise.
18276 (vect_try_gather_scatter_pattern): Likewise.
18277 (vect_recog_widen_mult_pattern): Likewise. Check for a null vectype.
18278 (vect_recog_over_widening_pattern): Likewise.
18279 (vect_recog_gather_scatter_pattern): Likewise.
18280 (vect_recog_func_ptr): Move from tree-vectorizer.h
18281 (vect_vect_recog_func_ptrs): Move further down the file.
18282 (vect_recog_func): Likewise. Remove the third argument.
18283 (NUM_PATTERNS): Define based on vect_vect_recog_func_ptrs.
18284 (vect_pattern_recog_1): Expect the pattern function to do any
18285 necessary target tests. Also expect it to provide a vector type.
18286 Remove the type_in handling.
18288 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18290 * tree-vect-patterns.c (vect_pattern_detected): New function.
18291 (vect_recog_dot_prod_patternm, vect_recog_sad_pattern)
18292 (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern)
18293 (vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern
18294 (vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern)
18295 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
18296 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
18297 (vect_recog_mask_conversion_pattern)
18298 (vect_try_gather_scatter_pattern): Likewise.
18300 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18302 * tree-vect-patterns.c (vect_get_internal_def): New function.
18303 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
18304 (vect_recog_vector_vector_shift_pattern, check_bool_pattern)
18305 (search_type_for_mask_1): Use it.
18307 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18309 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
18310 redundant WIDEN_SUM_EXPR handling.
18311 (vect_recog_sad_pattern): Likewise.
18313 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18315 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
18316 redundant check that the types of a PLUS_EXPR or MULT_EXPR agree.
18317 (vect_recog_sad_pattern): Likewise PLUS_EXPR, ABS_EXPR and MINUS_EXPR.
18318 (vect_recog_widen_mult_pattern): Likewise MULT_EXPR.
18319 (vect_recog_widen_sum_pattern): Likewise PLUS_EXPR.
18321 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18323 * tree-vect-stmts.c (vectorizable_call): Make sure that we
18324 use the stmt_vec_info of the original bb statement for the
18325 new zero assignment, even if the call is part of a pattern.
18327 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18329 * tree-vectorizer.h (_stmt_vec_info): Note above pattern_def_seq
18330 that the sequence is attached to the original statement rather
18331 than the pattern statement.
18332 * tree-vect-loop.c (vect_determine_vf_for_stmt): Take the
18333 PATTERN_DEF_SEQ from the original statement rather than
18334 the main pattern statement.
18335 * tree-vect-stmts.c (free_stmt_vec_info): Likewise.
18336 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
18337 (vect_mark_pattern_stmts): Don't copy the PATTERN_DEF_SEQ.
18339 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18341 * tree-vect-stmts.c (vect_analyze_stmt): Move the handling of pattern
18342 definition statements before the early exit for statements that aren't
18344 * tree-vect-loop.c (vect_transform_loop_stmt): New function,
18346 (vect_transform_loop): ...here. Process pattern definition
18347 statements without first checking whether the main pattern
18348 statement is live or relevant.
18350 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
18352 * tree-cfgcleanup.c (tree_forwarder_block_p): Do not return false at
18353 -O0 if the locus represent UNKNOWN_LOCATION but have different values.
18355 2018-06-19 Aaron Sawdey <acsawdey@linux.ibm.com>
18357 * config/rs6000/rs6000-string.c (select_block_compare_mode): Check
18358 TARGET_EFFICIENT_OVERLAPPING_UNALIGNED here instead of in caller.
18359 (do_and3, do_and3_mask, do_compb3, do_rotl3): New functions.
18360 (expand_block_compare): Change select_block_compare_mode call.
18361 (expand_strncmp_align_check): Use new functions, fix comment.
18362 (emit_final_str_compare_gpr): New function.
18363 (expand_strn_compare): Refactor and clean up code.
18364 * config/rs6000/vsx.md (vsx_mov<mode>_64bit): Remove *.
18366 2018-06-19 Tony Reix <tony.reix@atos.com>
18367 Damien Bergamini <damien.bergamini@atos.com>
18368 David Edelsohn <dje.gcc@gmail.com>
18370 * collect2.c (static_obj): New variable.
18371 (static_libs): New variable.
18372 (is_in_list): Uncomment declaration.
18373 (main): Track AIX libraries linked statically.
18374 (is_in_list): Uncomment definition.
18375 (scan_prog_file): Don't add AIX shared libraries initializer
18376 to constructor list if linking statically.
18378 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
18380 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
18382 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
18384 2018-06-19 Jan Hubicka <hubicka@ucw.cz>
18386 * tree.c (find_decls_types_r): Remove all non-VAR_DECLs from
18389 2018-06-19 Martin Liska <mliska@suse.cz>
18391 * config/i386/i386.c (ix86_can_inline_p): Do not use
18392 ipa_fn_summaries::get_create.
18393 * ipa-cp.c (ipcp_cloning_candidate_p): Replace get_create with
18395 (devirtualization_time_bonus): Likewise.
18396 (ipcp_propagate_stage): Likewise.
18397 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
18398 (edge_set_predicate): Likewise.
18399 (evaluate_conditions_for_known_args): Likewise.
18400 (evaluate_properties_for_edge): Likewise.
18401 (ipa_call_summary::reset): Tranform to ...
18402 (ipa_call_summary::~ipa_call_summary): ... this.
18403 (ipa_fn_summary::reset): Transform to ...
18404 (ipa_fn_summary::~ipa_fn_summary): ... this.
18405 (ipa_fn_summary_t::remove): Rename to ...
18406 (ipa_fn_summary_t::remove_callees): ... this.
18407 (ipa_fn_summary_t::duplicate): Use placement new
18408 instead of memory copy.
18409 (ipa_call_summary_t::duplicate): Likewise.
18410 (ipa_call_summary_t::remove): Remove.
18411 (dump_ipa_call_summary): Change get_create to get.
18412 (ipa_dump_fn_summary): Dump only when summary exists.
18413 (analyze_function_body): Use symbol_summary::get instead
18415 (compute_fn_summary): Likewise.
18416 (estimate_edge_devirt_benefit): Likewise.
18417 (estimate_edge_size_and_time): Likewise.
18418 (inline_update_callee_summaries): Likewise.
18419 (remap_edge_change_prob): Likewise.
18420 (remap_edge_summaries): Likewise.
18421 (ipa_merge_fn_summary_after_inlining): Likewise.
18422 (write_ipa_call_summary): Likewise.
18423 (ipa_fn_summary_write): Likewise.
18424 (ipa_free_fn_summary): Likewise.
18425 * ipa-fnsummary.h (struct GTY): Add new ctor and copy ctor.
18426 (struct ipa_call_summary): Likewise.
18427 * ipa-icf.c (sem_function::merge): Use symbol_summary::get instead
18429 * ipa-inline-analysis.c (do_estimate_edge_time): Likewise.
18430 (estimate_size_after_inlining): Likewise.
18431 (estimate_growth): Likewise.
18432 (growth_likely_positive): Likewise.
18433 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
18434 (inline_call): Likewise.
18435 * ipa-inline.c (caller_growth_limits): Likewise.
18436 (can_inline_edge_p): Likewise.
18437 (can_inline_edge_by_limits_p): Likewise.
18438 (compute_uninlined_call_time): Likewise.
18439 (compute_inlined_call_time): Likewise.
18440 (want_inline_small_function_p): Likewise.
18441 (edge_badness): Likewise.
18442 (update_caller_keys): Likewise.
18443 (update_callee_keys): Likewise.
18444 (inline_small_functions): Likewise.
18445 (inline_to_all_callers_1): Likewise.
18446 (dump_overall_stats): Likewise.
18447 (early_inline_small_functions): Likewise.
18448 (early_inliner): Likewise.
18449 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
18450 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
18451 * ipa-pure-const.c (malloc_candidate_p): Likewise.
18452 * ipa-split.c (execute_split_functions): Likewise.
18453 * symbol-summary.h: Likewise.
18454 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
18456 2018-06-19 Richard Biener <rguenther@suse.de>
18458 * tree-vectorizer.c (try_vectorize_loop_1): Split out of ...
18459 (vectorize_loops): ... here. Fix dbgcnt handling.
18460 (try_vectorize_loop): Wrap try_vectorize_loop_1.
18462 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
18465 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
18466 ieee128 argument takes up only one (vector) register, not two (floating
18469 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
18471 * gimplify.c (gimplify_init_constructor): Really never clear for an
18472 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
18474 2018-06-19 Richard Biener <rguenther@suse.de>
18476 PR tree-optimization/86179
18477 * tree-vect-patterns.c (vect_pattern_recog_1): Clean up
18478 after failed recognition.
18480 2018-06-18 Martin Sebor <msebor@redhat.com>
18482 PR middle-end/85602
18483 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
18484 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
18485 Handle integer subtraction.
18486 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
18487 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
18489 2018-06-18 David Malcolm <dmalcolm@redhat.com>
18491 * config/frv/frv-protos.h (frv_ifcvt_modify_insn): Strengthen 3rd
18492 param from rtx to rtx_insn *.
18493 * config/frv/frv.c (frv_ifcvt_add_insn): Likewise for "insn"
18495 (frv_ifcvt_modify_insn): Likwise.
18496 (frv_ifcvt_modify_final): Likwise for local "existing_insn",
18497 adding an as_a <rtx_insn *> cast. Likewise for local "insn".
18498 * config/mips/mips.c (r10k_insert_cache_barriers): Add an
18499 as_a <rtx_insn *> cast to local "unprotected_region" once
18500 it's been established that it's not NULL or pc_rtx.
18501 * config/nds32/nds32-relax-opt.c (nds32_group_insns): Strengthen
18502 param "sethi" from rtx to rtx_insn *.
18503 (nds32_group_float_insns): Likewise for param "insn".
18504 * config/vax/vax-protos.h (vax_output_int_add): Likewise for 1st
18506 (vax_output_int_subtract): Likewise.
18507 * config/vax/vax.c (vax_output_int_add): Likewise for param
18509 (vax_output_int_subtract): Likewise.
18510 * emit-rtl.c (set_insn_deleted): Likewise, removing cast.
18511 (emit_pattern_after): Likewise for param "after".
18512 (emit_insn_after): Likewise.
18513 (emit_jump_insn_after): Likewise.
18514 (emit_call_insn_after): Likewise.
18515 (emit_debug_insn_after): Likewise.
18516 (emit_pattern_before): Likewise for param "before".
18517 (emit_insn_before): Likewise.
18518 (emit_jump_insn_before): Likewise.
18519 * final.c (get_insn_template): Likewise for param "insn", removing
18521 * output.h (get_insn_template): Likewise for 2nd param.
18522 * rtl.h (emit_insn_before): Likewise.
18523 (emit_jump_insn_before): Likewise.
18524 (emit_debug_insn_before_noloc): Likewise.
18525 (emit_insn_after): Likewise.
18526 (emit_jump_insn_after): Likewise.
18527 (emit_call_insn_after): Likewise.
18528 (emit_debug_insn_after): Likewise.
18529 (set_insn_deleted): Likewise for param.
18531 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
18534 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
18535 floating point modes, so that IFmode is numerically greater than
18536 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
18537 to declare the ordering. This prevents IFmode from being
18538 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
18539 machine. Include rs6000-modes.h to share the fractional values
18540 between genmodes* and the rest of the compiler.
18541 (IFmode): Likewise.
18542 (KFmode): Likewise.
18543 (TFmode): Likewise.
18544 * config/rs6000/rs6000-modes.h: New file.
18545 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
18546 meaning of rs6000_long_double_size so that 126..128 selects an
18547 appropriate 128-bit floating point type.
18548 (rs6000_option_override_internal): Likewise.
18549 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
18550 (TARGET_LONG_DOUBLE_128): Change the meaning of
18551 rs6000_long_double_size so that 126..128 selects an appropriate
18552 128-bit floating point type.
18553 (LONG_DOUBLE_TYPE_SIZE): Update comment.
18554 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
18555 source and destination to match the standard usage.
18556 (truncifkf2): Likewise.
18557 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
18558 ISA 2.07 to use an explicit clobber, instead of passing in a
18560 (copysign<mode>3_soft): Likewise.
18562 2018-06-18 David Malcolm <dmalcolm@redhat.com>
18564 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
18565 Replace dump_printf_loc call with DUMP_VECT_SCOPE.
18566 (vect_slp_analyze_instance_dependence): Likewise.
18567 (vect_enhance_data_refs_alignment): Likewise.
18568 (vect_analyze_data_refs_alignment): Likewise.
18569 (vect_slp_analyze_and_verify_instance_alignment
18570 (vect_analyze_data_ref_accesses): Likewise.
18571 (vect_prune_runtime_alias_test_list): Likewise.
18572 (vect_analyze_data_refs): Likewise.
18573 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Likewise.
18574 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
18575 (vect_analyze_scalar_cycles_1): Likewise.
18576 (vect_get_loop_niters): Likewise.
18577 (vect_analyze_loop_form_1): Likewise.
18578 (vect_update_vf_for_slp): Likewise.
18579 (vect_analyze_loop_operations): Likewise.
18580 (vect_analyze_loop): Likewise.
18581 (vectorizable_induction): Likewise.
18582 (vect_transform_loop): Likewise.
18583 * tree-vect-patterns.c (vect_pattern_recog): Likewise.
18584 * tree-vect-slp.c (vect_analyze_slp): Likewise.
18585 (vect_make_slp_decision): Likewise.
18586 (vect_detect_hybrid_slp): Likewise.
18587 (vect_slp_analyze_operations): Likewise.
18588 (vect_slp_bb): Likewise.
18589 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise.
18590 (vectorizable_bswap): Likewise.
18591 (vectorizable_call): Likewise.
18592 (vectorizable_simd_clone_call): Likewise.
18593 (vectorizable_conversion): Likewise.
18594 (vectorizable_assignment): Likewise.
18595 (vectorizable_shift): Likewise.
18596 (vectorizable_operation): Likewise.
18597 * tree-vectorizer.h (DUMP_VECT_SCOPE): New macro.
18599 2018-06-18 Martin Sebor <msebor@redhat.com>
18601 PR tree-optimization/81384
18602 * builtin-types.def (BT_FN_SIZE_CONST_STRING_SIZE): New.
18603 * builtins.c (expand_builtin_strnlen): New function.
18604 (expand_builtin): Call it.
18605 (fold_builtin_n): Avoid setting TREE_NO_WARNING.
18606 * builtins.def (BUILT_IN_STRNLEN): New.
18607 * calls.c (maybe_warn_nonstring_arg): Handle BUILT_IN_STRNLEN.
18608 Warn for bounds in excess of maximum object size.
18609 * tree-ssa-strlen.c (maybe_set_strlen_range): Return tree representing
18610 single-value ranges. Handle strnlen.
18611 (handle_builtin_strlen): Handle strnlen.
18612 (strlen_check_and_optimize_stmt): Same.
18613 * doc/extend.texi (Other Builtins): Document strnlen.
18615 2018-06-18 Maya Rashish <coypu@sdf.org>
18617 * config/alpha/openbsd.h (TARGET_DEFAULT): Define.
18618 (LINK_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
18619 (INTMAX_TYPE, UINTMAX_TYPE, WINT_TYPE): Likewise.
18621 * config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Move from
18623 * config/alpha/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Here.
18625 2018-06-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
18627 * tree.c (escaped_string::escape): Replace cast to char * by
18628 const_cast<char *> (unescaped).
18630 2018-06-18 Nick Clifton <nickc@redhat.com>
18633 * tree.c (escaped_string): New class. Converts an unescaped
18634 string into its escaped equivalent.
18635 (warn_deprecated_use): Use the new class to convert the
18636 deprecation message, if present.
18637 (test_escaped_strings): New self test.
18638 (test_c_tests): Add test_escaped_strings.
18639 * doc/extend.texi (deprecated): Add a note that the
18640 deprecation message is affected by the -fmessage-length
18641 option, and that control characters will be escaped.
18642 (#pragma GCC error): Document this pragma.
18643 (#pragma GCC warning): Likewise.
18644 * doc/invoke.texi (-fmessage-length): Document this option's
18645 effect on the #warning and #error preprocessor directives and
18646 the deprecated attribute.
18648 2018-06-18 Eric Botcazou <ebotcazou@adacore.com>
18650 * tree.c (decl_value_expr_lookup): Revert latest change.
18651 (decl_value_expr_insert): Likewise.
18653 2018-06-17 Eric Botcazou <ebotcazou@adacore.com>
18655 * gimplify.c (nonlocal_vlas): Delete.
18656 (nonlocal_vla_vars): Likewise.
18657 (gimplify_var_or_parm_decl): Do not add debug VAR_DECLs for non-local
18659 (gimplify_body): Do not create and destroy nonlocal_vlas.
18660 * tree-nested.c: Include diagnostic.h.
18661 (use_pointer_in_frame): Tweak.
18662 (lookup_field_for_decl): Add assertion and declare the transformation.
18663 (convert_nonlocal_reference_op) <PARM_DECL>: Rework and issue an
18664 internal error when the reference is in a wrong context. Do not
18665 create a debug decl by default.
18666 (note_nonlocal_block_vlas): Delete.
18667 (convert_nonlocal_reference_stmt) <GIMPLE_BIND>: Do not call it.
18668 (convert_local_reference_op) <PARM_DECL>: Skip the frame decl. Do not
18669 create a debug decl by default.
18670 (convert_gimple_call) <GIMPLE_CALL>: Issue an internal error when the
18671 call is in a wrong context.
18672 (fixup_vla_decls): New function.
18673 (finalize_nesting_tree_1): Adjust comment. Call fixup_vla_decls if no
18674 debug variables were created.
18675 * tree.c (decl_value_expr_lookup): Add checking assertion.
18676 (decl_value_expr_insert): Likewise.
18678 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
18680 PR middle-end/82479
18681 * ipa-fnsummary.c (will_be_nonconstant_expr_predicate): Handle CALL_EXPR.
18682 * tree-scalar-evolution.c (interpret_expr): Likewise.
18683 (expression_expensive_p): Likewise.
18684 * tree-ssa-loop-ivopts.c (contains_abnormal_ssa_name_p): Likewise.
18685 * tree-ssa-loop-niter.c (number_of_iterations_popcount): New.
18686 (number_of_iterations_exit_assumptions): Use number_of_iterations_popcount.
18687 (ssa_defined_by_minus_one_stmt_p): New.
18689 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
18691 PR middle-end/64946
18692 * cfgexpand.c (expand_debug_expr): Hande ABSU_EXPR.
18693 * config/i386/i386.c (ix86_add_stmt_cost): Likewise.
18694 * dojump.c (do_jump): Likewise.
18695 * expr.c (expand_expr_real_2): Check operand type's sign.
18696 * fold-const.c (const_unop): Handle ABSU_EXPR.
18697 (fold_abs_const): Likewise.
18698 * gimple-pretty-print.c (dump_unary_rhs): Likewise.
18699 * gimple-ssa-backprop.c (backprop::process_assign_use): Likesie.
18700 (strip_sign_op_1): Likesise.
18701 * match.pd: Add new pattern to generate ABSU_EXPR.
18702 * optabs-tree.c (optab_for_tree_code): Handle ABSU_EXPR.
18703 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
18704 * tree-eh.c (operation_could_trap_helper_p): Likewise.
18705 * tree-inline.c (estimate_operator_cost): Likewise.
18706 * tree-pretty-print.c (dump_generic_node): Likewise.
18707 * tree-vect-patterns.c (vect_recog_sad_pattern): Likewise.
18708 * tree.def (ABSU_EXPR): New.
18710 2018-06-16 Jakub Jelinek <jakub@redhat.com>
18712 PR middle-end/86095
18713 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
18714 documented as preserved for backward compatibility only.
18715 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
18717 PR rtl-optimization/86108
18718 * bb-reorder.c (create_forwarder_block): Renamed to ...
18719 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
18720 jump from new landing pad to the second part.
18721 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
18724 2018-06-15 Jakub Jelinek <jakub@redhat.com>
18726 PR middle-end/85878
18727 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
18728 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
18729 Only call store_expr for halves if the mode is the same.
18731 PR middle-end/86123
18732 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
18733 Fix up comment formatting.
18735 2018-06-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
18737 * typed-splay-tree.h (typed_splay_tree::remove): New function.
18738 (typed_splay_tree::closure,
18739 typed_splay_tree::inner_foreach_fn, typed_splay_tree::m_inner): Deleted.
18740 (typed_splay_tree::typed_splay_tree,
18741 typed_splay_tree::operator =): Declared private.
18742 (typed_splay_tree::splay_tree_key, typed_splay_tree::splay_tree_value,
18743 typed_splay_tree::splay_tree_node_s, typed_splay_tree::KDEL,
18744 typed_splay_tree::VDEL, typed_splay_tree::splay_tree_delete_helper,
18745 typed_splay_tree::rotate_left, typed_splay_tree::rotate_right,
18746 typed_splay_tree::splay_tree_splay,
18747 typed_splay_tree::splay_tree_foreach_helper,
18748 typed_splay_tree::splay_tree_insert,
18749 typed_splay_tree::splay_tree_remove,
18750 typed_splay_tree::splay_tree_lookup,
18751 typed_splay_tree::splay_tree_predecessor,
18752 typed_splay_tree::splay_tree_successor,
18753 typed_splay_tree::splay_tree_min,
18754 typed_splay_tree::splay_tree_max): Took over from splay-tree.c/.h.
18755 (typed_splay_tree::root, typed_splay_tree::comp,
18756 typed_splay_tree::delete_key,
18757 typed_splay_tree::delete_value): New data members.
18758 * typed-splay-tree.c (selftest::test_str_to_int): Add a test for
18759 typed_splay_tree::remove.
18761 2018-06-15 Matthew Fortune <matthew.fortune@mips.com>
18763 * config/mips/mips.h (ASM_SPEC): Pass through -mcrc, -mno-crc,
18764 -mginv and -mno-ginv to the assembler.
18765 * config/mips/mips.opt (-mcrc): New option.
18766 (-mginv): Likewise.
18767 * doc/invoke.text (-mcrc): Document.
18768 (-mginv): Likewise.
18770 2018-06-15 Nick Clifton <nickc@redhat.com>
18773 * tree.c (escaped_string): New class. Converts an unescaped
18774 string into its escaped equivalent.
18775 (warn_deprecated_use): Use the new class to convert the
18776 deprecation message, if present.
18777 (test_escaped_strings): New self test.
18778 (test_c_tests): Add test_escaped_strings.
18779 * doc/extend.texi (deprecated): Add a note that the
18780 deprecation message is affected by the -fmessage-length
18781 option, and that control characters will be escaped.
18782 (#pragma GCC error): Document this pragma.
18783 (#pragma GCC warning): Likewise.
18784 * doc/invoke.texi (-fmessage-length): Document this option's
18785 effect on the #warning and #error preprocessor directives and
18786 the deprecated attribute.
18788 2018-06-15 Richard Biener <rguenther@suse.de>
18790 * tree-vect-slp.c (vect_slp_bb): Dump MSG_OPTIMIZED_LOCATIONS
18791 here, also noting vector size used.
18792 * tree-vectorizer.c (vectorize_loops): Adjust. Note vector
18793 size used in MSG_OPTIMIZED_LOCATIONS dump.
18794 (pass_slp_vectorize::execute): Adjust.
18796 2018-06-15 Claudiu Zissulescu <claziss@synopsys.com>
18799 * config/arc/arc.c (arc_return_address_register): Fix
18802 2018-06-15 Richard Biener <rguenther@suse.de>
18804 PR middle-end/86159
18805 * tree-cfg.c (gimplify_build3): Do not strip sign conversions,
18806 leave useless conversion stripping to force_gimple_operand_gsi.
18807 (gimplify_build2): Likewise.
18808 (gimplify_build1): Likewise.
18810 2018-06-15 Richard Biener <rguenther@suse.de>
18812 PR middle-end/86076
18813 * tree-cfg.c (move_stmt_op): unshare invariant addresses
18814 before adjusting their block.
18816 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
18818 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
18819 multilibs for *-*-rtems*.
18820 * config/riscv/t-rtems: New file.
18822 2018-06-14 Jakub Jelinek <jakub@redhat.com>
18824 PR middle-end/86122
18825 * match.pd ((A +- CST1) +- CST2): Punt if last resort
18826 unsigned_type_for returns NULL.
18829 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
18830 subregs of multi-word pseudos unless the float mode has word size.
18832 2018-06-14 Richard Biener <rguenther@suse.de>
18834 PR middle-end/86139
18835 * tree-vect-generic.c (build_word_mode_vector_type): Remove
18836 duplicate and harmful type_hash_canon.
18837 * tree.c (type_hash_canon): Assert we didn't find ourselves.
18839 2018-06-14 Richard Biener <rguenther@suse.de>
18842 * tree-ssa-struct-alias.c (create_variable_info_for): Handle
18845 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
18847 * config/rtems.h (STDINT_LONG32): Define.
18849 2018-06-13 Matthew Fortune <matthew.fortune@mips.com>
18850 Prachi Godbole <prachi.godbole@imgtec.com>
18852 * config/mips/mips-cpus.def: Define P6600.
18853 * config/mips/mips-tables.opt: Regenerate.
18854 * config/mips/mips.c (mips_ucbranch_type): New enum.
18855 (mips_rtx_cost_data): Add support for P6600.
18856 (mips_issue_rate): Likewise.
18857 (mips_multipass_dfa_lookahead): Likewise.
18858 (mips_avoid_hazard): Likewise.
18859 (mips_reorg_process_insns): Likewise.
18860 (mips_classify_branch_p6600): New function.
18861 * config/mips/mips.h (TUNE_P6600): New define.
18862 (MIPS_ISA_LEVEL_SPEC): Infer mips64r6 from p6600.
18863 (ENABLE_LD_ST_PAIRS): Enable load/store bonding for p6600.
18864 * config/mips/mips.md: Include p6600.md.
18865 (processor): Add p6600.
18866 * config/mips/p6600.md: New file.
18867 * doc/invoke.texi: Add p6600 to supported architectures.
18869 2018-06-13 Martin Sebor <msebor@redhat.com>
18871 PR tree-optimization/86114
18872 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
18874 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
18876 2018-06-13 Richard Biener <rguenther@suse.de>
18878 * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern):
18879 Properly set vector type of the intermediate stmt.
18880 * tree-vect-stmts.c (vectorizable_operation): The destination
18881 var always has vectype_out type.
18883 2018-06-13 Jeff Law <law@redhat.com>
18885 * config/rl78/rl78.c (move_elim_pass): Use TDF_NONE rather than
18886 integer 0 for argument to print_rtl_with_bb.
18887 (rl78_reorg): Likewise.
18889 2018-06-13 David Malcolm <dmalcolm@redhat.com>
18891 * config/arc/arc.c (hwloop_optimize): Strengthen local "end_label"
18892 from rtx to rtx_insn *.
18893 * config/bfin/bfin.c (hwloop_optimize): Likewise for local
18895 (add_sched_insns_for_speculation): Likewise for local "target",
18896 converting usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
18897 * config/c6x/c6x.c (reorg_split_calls): Strengthen param "call_labels"
18898 from rtx_insn ** to rtx_code_label **.
18899 (reorg_emit_nops): Likewise.
18900 (c6x_reorg): Likewise for local "call_labels".
18901 * config/sh/sh-protos.h (get_dest_uid): Strengthen 1st param from
18903 * config/sh/sh.c (dump_table): Strengthen local "lab" from rtx to
18904 rtx_code_label *, adding safe_as_a <rtx_code_label *> casts to
18905 the loops over LABEL_REFS.
18906 (fixup_addr_diff_vecs): Add as_a <rtx_insn *> to usage of
18908 (barrier_align): Convert usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
18909 (get_dest_uid): Strengthen param "label" from rtx to rtx_insn *.
18910 (split_branches): Strengthen local "olabel" from rtx to
18911 rtx_insn *, adding a safe_as_a cast.
18912 * emit-rtl.c (next_real_insn): Strengthen param from "rtx"
18914 (add_insn_after): Likewise for first two params.
18915 (add_insn_before): Likewise.
18916 (remove_insn): Likewise for param.
18917 (emit_pattern_before_noloc): Likewise for second and third params.
18918 (emit_jump_insn_before_noloc): Convert NULL_RTX to NULL.
18919 (emit_call_insn_before_noloc): Likewise.
18920 (emit_debug_insn_before_noloc): Strengthen "before" param from "rtx"
18922 (emit_barrier_before): Likewise.
18923 (emit_label_before): Strengthen "label" param from "rtx" to
18924 "rtx_code_label *". Strengthen "before" param from "rtx" to
18926 (emit_insn_after_1): Strengthen "after" param from "rtx" to
18928 (emit_pattern_after_noloc): Likewise.
18929 (emit_insn_after_noloc): Likewise.
18930 (emit_jump_insn_after_noloc): Likewise.
18931 (emit_call_insn_after_noloc): Likewise.
18932 (emit_debug_insn_after_noloc): Likewise.
18933 (emit_barrier_after): Likewise.
18934 (emit_label_after): Likewise for both params.
18935 (emit_pattern_after_setloc): Likewise for "after" param. Convert
18936 "loc" param from "int" to "location_t".
18937 (emit_insn_after_setloc): Likewise.
18938 (emit_jump_insn_after_setloc): Likewise.
18939 (emit_call_insn_after_setloc): Likewise.
18940 (emit_debug_insn_after_setloc): Likewise.
18941 (emit_pattern_before_setloc): Likewise for "before" param. Convert
18942 "loc" param from "int" to "location_t".
18943 (emit_pattern_before): Convert NULL_RTX to NULL.
18944 (emit_insn_before_setloc): Convert "loc" param from "int" to
18946 (emit_jump_insn_before_setloc): Likewise.
18947 (emit_call_insn_before_setloc): Likewise.
18948 (emit_debug_insn_before_setloc): Strengthen "before" param from rtx to
18949 rtx_insn *. Convert "loc" param from "int" to "location_t".
18950 * rtl.h (emit_insn_before_setloc, emit_jump_insn_before_setloc,
18951 emit_call_insn_before_setloc, emit_debug_insn_before_setloc):
18952 Convert 3rd param from "int" to "location_t".
18953 (emit_barrier_before, emit_barrier_after, next_real_insn):
18954 Strengthen param from rtx to rtx_insn *.
18955 (emit_label_before): Strengthen 1st param from "rtx" to
18956 "rtx_code_label *". Strengthen 2nd param from "rtx" to
18958 (emit_insn_after_noloc, emit_jump_insn_after_noloc,
18959 emit_call_insn_after_noloc, emit_debug_insn_after_noloc):
18960 Strengthen 2nd param from "rtx" to "rtx_insn *".
18961 (emit_insn_after_setloc, emit_jump_insn_after_setloc)
18962 emit_call_insn_after_setloc, emit_debug_insn_after_setloc):
18963 Likewise. Convert 3rd param from "int" to "location_t".
18964 (emit_label_after): Strengthen 1st param from "rtx" to
18965 "rtx_code_label *".
18966 (next_real_insn, remove_insn): Strengthen param from "rtx" to
18968 (add_insn_before, add_insn_after): Strengthen 1st and 2nd params
18969 from "rtx" to "rtx_insn *".
18971 2018-06-13 Jan Hubicka <hubicka@gcc.gnu.org>
18973 * cgraph.c (cgraph_node::get_untransformed_body): Dump function
18974 bodies streamed in with -Q.
18975 * dumpfile.c (dump_files): Add lto-stream-out dump file.
18976 * dumpfile.h (tree_dump_index): Add lto_stream_out.
18977 * gimple-streamer-out.c: Include gimple-pretty-print.h
18978 (output_bb): Dump stmts streamed.
18979 * lto-section-out.c: Include print-tree.h
18980 (lto_begin_section): Dump sections created.
18981 (lto_output_decl_index): Dump decl encoded.
18982 * lto-streamer-out.c: Include print-tree.h
18983 (create_output_block): Dump output block created.
18984 (DFS::DFS_write_tree_body): Dump DFS SCCs streamed.
18985 (output_function): Dump function output.
18986 (output_constructor): Dump constructor streamed.
18987 (write_global_stream): Output indexes encoded.
18988 (produce_asm_for_decls): Dump streams encoded.
18989 * lto-streamer.c (streamer_dump_file): New global var.
18990 * lto-streamer.h (streamer_dump_file): Declare.
18991 * passes.c (ipa_write_summaries): Initialize streamer dump.
18992 * varpool.c (varpool_node::get_constructor): Dump constructors streamed
18995 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
18998 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
18999 offsets for register save directives. Emit a second batch of save
19000 directives, if need be, when the function accesses prior frames.
19002 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19004 * config/arc/fpu.md (fmasf4): Force operand to register.
19005 (fnmasf4): Likewise.
19007 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19009 * config/arc/arc-protos.h (arc_pad_return): Remove.
19010 * config/arc/arc.c (machine_function): Remove force_short_suffix
19012 (arc_print_operand): Adjust printing of '&'.
19013 (arc_verify_short): Remove conditional printing of short suffix.
19014 (arc_final_prescan_insn): Remove reference to size_reason.
19015 (pad_return): New function.
19016 (arc_reorg): Call pad_return.
19017 (arc_pad_return): Remove.
19018 (arc_init_machine_status): Remove reference to force_short_suffix.
19019 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
19020 (attr length): When attribute iscompact is true force to 2
19021 regardless; in the case of maybe check if we want to force the
19022 instruction to have 4 bytes length.
19023 (nopv): Change it to generate 4 byte long nop as well.
19024 (blockage): New pattern.
19025 (simple_return): Remove call to arc_pad_return.
19026 (p_return_i): Likewise.
19028 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19030 * config/arc/elf.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
19032 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19034 * config/arc/builtins.def (SYNC): SYNC instruction is valid on all
19037 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19039 * config/arc/arc.c (atomic_exchangesi): EX instruction is default
19040 for ARC700 and ARCv2.
19042 2018-06-13 Chenghua Xu <paul.hua.gm@gmail.com>
19045 * config/mips/loongson.md (vec_setv4hi): Gen_lowpart for
19046 operands[2] instead of operands[1].
19049 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
19051 * lra-constraints.c (simplify_operand_subreg): In the paradoxical
19052 case, check whether the outer register overlaps an unallocatable
19053 register, not just whether it fits the required class.
19055 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
19057 * poly-int.h (can_div_trunc_p): Add new overload in which all values
19059 * alias.c (get_addr): Extend CONST_INT handling to poly_int_rtx_p.
19060 (memrefs_conflict_p): Likewise.
19061 (init_alias_analysis): Likewise.
19062 * cfgexpand.c (expand_debug_expr): Likewise.
19063 * combine.c (combine_simplify_rtx, force_int_to_mode): Likewise.
19064 * cse.c (fold_rtx): Likewise.
19065 * explow.c (adjust_stack, anti_adjust_stack): Likewise.
19066 * expr.c (emit_block_move_hints): Likewise.
19067 (clear_storage_hints, push_block, emit_push_insn): Likewise.
19068 (store_expr_with_bounds, reduce_to_bit_field_precision): Likewise.
19069 (emit_group_load_1): Use rtx_to_poly_int64 for group offsets.
19070 (emit_group_store): Likewise.
19071 (find_args_size_adjust): Use strip_offset. Use rtx_to_poly_int64
19072 to read the PRE/POST_MODIFY increment.
19073 * calls.c (store_one_arg): Use strip_offset.
19074 * rtlanal.c (rtx_addr_can_trap_p_1): Extend CONST_INT handling to
19076 (set_noop_p): Use rtx_to_poly_int64 for the elements selected
19078 * simplify-rtx.c (avoid_constant_pool_reference): Use strip_offset.
19079 (simplify_binary_operation_1): Extend CONST_INT handling to
19081 * var-tracking.c (compute_cfa_pointer): Take a poly_int64 rather
19082 than a HOST_WIDE_INT.
19083 (hard_frame_pointer_adjustment): Change from HOST_WIDE_INT to
19085 (adjust_mems, add_stores): Update accodingly.
19086 (vt_canonicalize_addr): Track polynomial offsets.
19087 (emit_note_insn_var_location): Likewise.
19088 (vt_add_function_parameter): Likewise.
19089 (vt_initialize): Likewise.
19091 2018-06-12 Jeff Law <law@redhat.com>
19093 * config.gcc (alpha*-*-freebsd*): Remove.
19094 * config/alpha/freebsd.h: Remove.
19096 2018-06-12 David Malcolm <dmalcolm@redhat.com>
19099 * spellcheck-tree.c (levenshtein_distance): Rename to...
19100 (get_edit_distance): ...this, and update for underlying renaming.
19101 * spellcheck-tree.h (levenshtein_distance): Rename to...
19102 (get_edit_distance): ...this.
19103 * spellcheck.c (levenshtein_distance): Rename to...
19104 (get_edit_distance): ...this. Convert from Levenshtein distance
19105 to Damerau-Levenshtein distance by supporting transpositions of
19106 adjacent characters. Rename "v1" to "v_next" and "v0" to
19108 (selftest::levenshtein_distance_unit_test_oneway): Rename to...
19109 (selftest::test_edit_distance_unit_test_oneway): ...this, and
19110 update for underlying renaming.
19111 (selftest::levenshtein_distance_unit_test): Rename to...
19112 (selftest::test_get_edit_distance_unit): ...this, and update for
19113 underlying renaming.
19114 (selftest::test_find_closest_string): Add example from PR 69968
19115 where transposition helps
19116 (selftest::test_metric_conditions): Update for renaming.
19117 (selftest::test_metric_conditions): Likewise.
19118 (selftest::spellcheck_c_tests): Likewise.
19119 * spellcheck.h (levenshtein_distance): Rename both overloads to...
19120 (get_edit_distance): ...this.
19121 (best_match::consider): Update for renaming.
19123 2018-06-12 Martin Sebor <msebor@redhat.com>
19125 PR tree-optimization/85259
19126 * builtins.c (compute_objsize): Handle constant offsets.
19127 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return
19128 true iff a warning has been issued.
19129 * gimple.h (gimple_nonartificial_location): New function.
19130 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Call
19131 gimple_nonartificial_location and handle -Wno-system-headers.
19132 (handle_builtin_stxncpy): Same.
19134 2018-06-12 Martin Sebor <msebor@redhat.com>
19137 * fold-const.c (operand_equal_p): Handle SAVE_EXPR.
19139 2018-06-12 Will Schmidt <will_schmidt@vnet.ibm.com>
19141 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
19142 BUILTIN_VEC_XST entries for pointer to double and long long.
19144 2018-06-12 H.J. Lu <hongjiu.lu@intel.com>
19147 * config/i386/gnu-user.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
19149 * config/i386/gnu-user64.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
19152 2018-06-12 Martin Liska <mliska@suse.cz>
19154 * doc/options.texi: Document IntegerRange.
19156 2018-06-12 Martin Liska <mliska@suse.cz>
19158 * config/i386/i386.opt: Make MPX-related options as Deprecated.
19159 * opt-functions.awk: Handle Deprecated flag.
19160 * opts-common.c (decode_cmdline_option): Handle cl_deprecated
19162 (read_cmdline_option): Report warning for a deprecated option.
19163 * opts.h (struct cl_option): Add new field cl_deprecated.
19164 (CL_ERR_DEPRECATED): New.
19166 2018-06-12 Martin Liska <mliska@suse.cz>
19168 * doc/options.texi: Document Deprecated option flag.
19170 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19172 * config/arc/arc-arch.h (arc_extras): New enum.
19173 (arc_cpu_t):Add field extra.
19174 (arc_cpu_types): Consider the extras.
19175 * config/arc/arc-cpus.def: Add extras info.
19176 * config/arc/arc-opts.h (processor_type): Consider extra field.
19177 * config/arc/arc.c (arc_override_options): Handle extra field.
19179 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19181 * config/arc/arc-arch.h: Update ARC_OPTX macro.
19182 * config/arc/arc-options.def (ARC_OPTX): Introduce a new doc
19184 * config/arc/arc.c (arc_init): Update pic warning.
19185 (irq_range): Update irq range parsing warnings.
19186 (arc_override_options): Update various warning messages.
19187 (arc_handle_aux_attribute): Likewise.
19189 2018-06-12 Robert Suchanek <robert.suchanek@mips.com>
19191 * config/mips/i6400.md (i6400_fpu_fadd): Remove frint.
19193 2018-06-12 Jozef Lawrynowicz <jozef.l@mittosystems.com>
19195 * doc/sourcebuild.texi: Document usage of line number 0 in verify
19196 compiler messages directives.
19198 2018-06-12 Matthew Fortune <mfortune@gmail.com>
19200 * config/mips/mips-cpus.def: New MIPS_CPU for i6500.
19201 * config/mips/mips-tables.opt: Regenerate.
19202 * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Mark i6500 as
19204 * doc/invoke.texi: Document -march=i6500.
19206 2018-06-12 Prachi Godbole <prachi.godbole@imgtec.com>
19208 * config/mips/i6400.md (i6400_gpmuldiv): Remove cpu_unit.
19209 (i6400_gpmul): Add cpu_unit.
19210 (i6400_gpdiv): Likewise.
19211 (i6400_msa_add_d): Update reservations.
19212 (i6400_msa_int_add) Likewise.
19213 (i6400_msa_short_logic3) Likewise.
19214 (i6400_msa_short_logic2) Likewise.
19215 (i6400_msa_short_logic) Likewise.
19216 (i6400_msa_move) Likewise.
19217 (i6400_msa_cmp) Likewise.
19218 (i6400_msa_short_float2) Likewise.
19219 (i6400_msa_div_d) Likewise.
19220 (i6400_msa_long_logic1) Likewise.
19221 (i6400_msa_long_logic2) Likewise.
19222 (i6400_msa_mult) Likewise.
19223 (i6400_msa_long_float2) Likewise.
19224 (i6400_msa_long_float4) Likewise.
19225 (i6400_msa_long_float5) Likewise.
19226 (i6400_msa_long_float8) Likewise.
19227 (i6400_fpu_fadd): Include frint type.
19228 (i6400_fpu_store): New define_insn_reservation.
19229 (i6400_fpu_load): Likewise.
19230 (i6400_fpu_move): Likewise.
19231 (i6400_fpu_fcmp): Likewise.
19232 (i6400_fpu_fmadd): Likewise.
19233 (i6400_int_mult): Include imul3nc type and update reservation.
19234 (i6400_int_div): Include idiv3 type and update reservation.
19235 (i6400_int_load): Update to check type not move_type.
19236 (i6400_int_store): Likewise.
19237 (i6400_int_prefetch): Set zero latency.
19239 2018-06-12 Eric Botcazou <ebotcazou@adacore.com>
19241 * gcc.c: Document new %@{...} sequence.
19242 (LINK_COMMAND_SPEC): Use it for the -L switches.
19243 (cpp_unique_options): Use it for the -I switches.
19244 (at_file_argbuf): New global variable.
19245 (in_at_file): Likewise.
19246 (alloc_args): Create at_file_argbuf.
19247 (clear_args): Truncate at_file_argbuf.
19248 (store_arg): If in_at_file, push the argument onto at_file_argbuf.
19249 (open_at_file): New function.
19250 (close_at_file): Likewise.
19251 (create_at_file): Delete.
19252 (do_spec_1) <'i'>: Use open_at_file/close_at_file.
19255 (validate_switches_from_spec): Deal with %@{...} sequence.
19256 (validate_switches): Likewise.
19257 (driver::finalize): Call clear_args.
19259 2018-06-11 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
19261 * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0.
19263 2018-06-11 Martin Sebor <msebor@redhat.com>
19265 * doc/invoke.texi (-Wall): List -Wc++17-compat.
19266 (Wno-class-memaccess): Add @opindex.
19267 (Wno-templates, Wno-multiple-inheritance): Same.
19268 (Wno-virtual-inheritance, Wno-namespaces): Same.
19269 (Wno-pedantic, Wno-chkp, Wcoverage-mismatch): Same.
19270 (Wno-format-overflow, Wno-format-truncation): Same.
19271 (Wno-unused-local-typedefs, Walloc-size-larger-than): Same.
19272 (Wno-alloc-size-larger-than, Wframe-larger-than): Same
19273 (Wno-stack-usage, Wno-c++-compat, Wno-c++11-compat): Same.
19274 (Wno-c++14-compat, Wno-c++17-compat, Wno-openmp-simd): Same.
19275 (Wno-unsuffixed-float-constants, Wno-addr-space-convert): Same.
19276 (Wno-misspelled-isr): Same.
19278 2018-06-11 Martin Sebor <msebor@redhat.com>
19280 * PR tree-optimization/86083
19281 * tree-ssa-strlen.c (handle_char_store): Use tree_expr_nonzero_p.
19283 2018-06-11 Zhouyi Zhou <zhouzhouyi@gmail.com>
19285 * tree-eh.c (lower_eh_constructs_2): Add a comma to comment.
19287 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
19290 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
19291 on the correct operand.
19292 (*movdi_internal64): Ditto.
19294 2018-06-11 Martin Liska <mliska@suse.cz>
19296 PR tree-optimization/86089
19297 * tree-ssa-strlen.c (get_string_length): Move back removed hunk.
19299 2018-06-11 Julia Koval <julia.koval@intel.com>
19301 * config/i386/vaesintrin.h (_mm_aesdec_epi128, _mm_aesdeclast_epi128)
19302 _mm_aesenc_epi128, _mm_aesenclast_epi128: Remove.
19303 * config/i386/vpclmulqdqintrin.h (_mm_clmulepi64_epi128): Remove.
19305 2018-06-11 Olivier Hainque <hainque@adacore.com>
19307 * dwarf2out.c (gen_compile_unit_die): Fallout to DW_LANG_Ada83
19308 for Ada with strict dwarf2.
19310 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
19313 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
19316 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
19318 * dumpfile.c (FIRST_ME_AUTO_NUMBERED_DUMP): Bump to 4.
19320 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
19322 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
19325 2018-06-08 Martin Liska <mliska@suse.cz>
19327 * tree-cfg.h (debug_function): Fix argument type to match
19330 2018-06-08 Martin Liska <mliska@suse.cz>
19332 * config/powerpcspe/powerpcspe.c (rs6000_xcoff_visibility):
19333 Remove usage of MPX-related (and removed) fields.
19334 * config/rs6000/rs6000.c (rs6000_xcoff_visibility): Likewise.
19336 2018-06-08 David Malcolm <dmalcolm@redhat.com>
19338 * cfg.c (debug): Use TDF_NONE rather than 0.
19339 * cfghooks.c (debug): Likewise.
19340 * dumpfile.c (DUMP_FILE_INFO): Likewise; also for OPTGROUP.
19341 (struct dump_option_value_info): Convert to...
19342 (struct kv_pair): ...this template type.
19343 (dump_options): Convert to kv_pair<dump_flags_t>; use TDF_NONE
19345 (optinfo_verbosity_options): Likewise.
19346 (optgroup_options): Convert to kv_pair<optgroup_flags_t>; use
19348 (gcc::dump_manager::dump_register): Use optgroup_flags_t rather
19349 than int for "optgroup_flags" param.
19350 (dump_generic_expr_loc): Use dump_flags_t rather than int for
19352 (dump_dec): Likewise.
19353 (dump_finish): Use TDF_NONE rather than 0.
19354 (gcc::dump_manager::opt_info_enable_passes): Use optgroup_flags_t
19355 rather than int for "optgroup_flags" param. Use TDF_NONE rather
19356 than 0. Update for change to option_ptr.
19357 (opt_info_switch_p_1): Convert "optgroup_flags" param from int *
19358 to optgroup_flags_t *. Use TDF_NONE and OPTGROUP_NONE rather than
19359 0. Update for changes to optinfo_verbosity_options and
19361 (opt_info_switch_p): Convert optgroup_flags from int to
19363 (dump_basic_block): Use dump_flags_t rather than int
19364 for "dump_kind" param.
19365 * dumpfile.h (TDF_ADDRESS, TDF_SLIM, TDF_RAW, TDF_DETAILS,
19366 TDF_STATS, TDF_BLOCKS, TDF_VOPS, TDF_LINENO, TDF_UID)
19367 TDF_STMTADDR, TDF_GRAPH, TDF_MEMSYMS, TDF_RHS_ONLY, TDF_ASMNAME,
19368 TDF_EH, TDF_NOUID, TDF_ALIAS, TDF_ENUMERATE_LOCALS, TDF_CSELIB,
19369 TDF_SCEV, TDF_GIMPLE, TDF_FOLDING, MSG_OPTIMIZED_LOCATIONS,
19370 MSG_MISSED_OPTIMIZATION, MSG_NOTE, MSG_ALL, TDF_COMPARE_DEBUG,
19371 TDF_NONE): Convert from macros to...
19372 (enum dump_flag): ...this new enum.
19373 (dump_flags_t): Update to use enum.
19374 (operator|, operator&, operator~, operator|=, operator&=):
19375 Implement for dump_flags_t.
19376 (OPTGROUP_NONE, OPTGROUP_IPA, OPTGROUP_LOOP, OPTGROUP_INLINE,
19377 OPTGROUP_OMP, OPTGROUP_VEC, OPTGROUP_OTHER, OPTGROUP_ALL):
19378 Convert from macros to...
19379 (enum optgroup_flag): ...this new enum.
19380 (optgroup_flags_t): New typedef.
19381 (operator|, operator|=): Implement for optgroup_flags_t.
19382 (struct dump_file_info): Convert field "alt_flags" to
19383 dump_flags_t. Convert field "optgroup_flags" to
19385 (dump_basic_block): Use dump_flags_t rather than int for param.
19386 (dump_generic_expr_loc): Likewise.
19387 (dump_dec): Likewise.
19388 (dump_register): Convert param "optgroup_flags" to
19390 (opt_info_enable_passes): Likewise.
19391 * early-remat.c (early_remat::dump_edge_list): Use TDF_NONE rather
19393 * gimple-pretty-print.c (debug): Likewise.
19394 * gimple-ssa-store-merging.c (bswap_replace): Likewise.
19395 (merged_store_group::apply_stores): Likewise.
19396 * gimple-ssa-strength-reduction.c (insert_initializers): Likewise.
19397 * gimple.c (verify_gimple_pp): Likewise.
19398 * graphite-poly.c (print_pbb_body): Likewise.
19399 * passes.c (pass_manager::register_one_dump_file): Convert
19400 local "optgroup_flags" to optgroup_flags_t.
19401 * print-tree.c (print_node): Use TDF_NONE rather than 0.
19403 (debug_body): Likewise.
19404 * tree-pass.h (struct pass_data): Convert field "optgroup_flags"
19405 to optgroup_flags_t.
19406 * tree-pretty-print.c (print_struct_decl): Use TDF_NONE rather
19408 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Likewise.
19409 (convert_mult_to_fma): Likewise.
19410 * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
19411 * tree-ssa-sccvn.c (vn_eliminate): Likewise.
19412 * tree-vect-data-refs.c (dump_lower_bound): Convert param
19413 "dump_kind" to dump_flags_t.
19415 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
19417 * config/rs6000/rs6000.c (min, max): Delete.
19419 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
19421 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete mention of
19422 -mabi=spe and -mabi=no-spe.
19424 2018-06-08 Martin Liska <mliska@suse.cz>
19426 * ipa-pure-const.c (propagate_pure_const): Use ::get at places
19427 where we expect an existing summary.
19429 2018-06-08 Martin Liska <mliska@suse.cz>
19431 * ipa-inline-analysis.c (simple_edge_hints): Use ::get method.
19432 * ipa-inline.h (estimate_edge_growth): Likewise.
19434 2018-06-08 Martin Liska <mliska@suse.cz>
19436 * cgraph.c (function_version_hasher::hash): Use
19437 cgraph_node::get_uid ().
19438 (function_version_hasher::equal):
19439 * cgraph.h (cgraph_node::get_uid): New method.
19440 * ipa-inline.c (update_caller_keys): Use
19441 cgraph_node::get_uid ().
19442 (update_callee_keys): Likewise.
19443 * ipa-utils.c (searchc): Likewise.
19444 (ipa_reduced_postorder): Likewise.
19445 * lto-cgraph.c (input_node): Likewise.
19446 * passes.c (is_pass_explicitly_enabled_or_disabled): Likewise.
19447 * symbol-summary.h (symtab_insertion): Likewise.
19448 (symtab_removal): Likewise.
19449 (symtab_duplication): Likewise.
19450 * tree-pretty-print.c (dump_function_header): Likewise.
19451 * tree-sra.c (convert_callers_for_node): Likewise.
19453 2018-06-08 Martin Liska <mliska@suse.cz>
19455 * cgraph.c (symbol_table::create_edge): Always assign a new
19457 (symbol_table::free_edge): Do not recycle numbers.
19458 * cgraph.h (cgraph_edge::get): New method.
19459 * symbol-summary.h (symtab_removal): Use it.
19460 (symtab_duplication): Likewise.
19461 (call_summary::hashable_uid): Remove.
19463 2018-06-08 Martin Liska <mliska@suse.cz>
19465 * ipa-inline-analysis.c (inline_edge_removal_hook): Remove.
19466 (initialize_growth_caches): Remove.
19467 (free_growth_caches): Likewise.
19468 (do_estimate_edge_time): Use edge_growth_cache.
19469 (do_estimate_edge_size): Likewise.
19470 (do_estimate_edge_hints): Likewise.
19471 * ipa-inline.c (reset_edge_caches): Likewise.
19472 (recursive_inlining): Likewise.
19473 (inline_small_functions): Likewise.
19474 * ipa-inline.h (initialize_growth_caches): Remove.
19475 (estimate_edge_size): Likewise.
19476 (estimate_edge_time): Likewise.
19477 (estimate_edge_hints): Likewise.
19478 (reset_edge_growth_cache): Likewise.
19479 * symbol-summary.h (call_summary::remove): New method.
19481 2018-06-08 Martin Liska <mliska@suse.cz>
19483 * ipa-cp.c (class edge_clone_summary): New summary.
19484 (grow_edge_clone_vectors): Remove.
19485 (ipcp_edge_duplication_hook): Remove.
19486 (class edge_clone_summary_t): New call_summary class.
19487 (ipcp_edge_removal_hook): Remove.
19488 (edge_clone_summary_t::duplicate): New function.
19489 (get_next_cgraph_edge_clone): Use edge_clone_summaries.
19490 (create_specialized_node): Likewise.
19491 (ipcp_driver): Initialize edge_clone_summaries and do not
19494 2018-06-08 Martin Liska <mliska@suse.cz>
19496 * symbol-summary.h (get): New function.
19497 (call_summary::m_initialize_when_cloning): New class member.
19499 2018-06-08 Martin Liska <mliska@suse.cz>
19501 * cgraph.c (cgraph_node::remove): Do not recycle uid.
19502 * cgraph.h (symbol_table::release_symbol): Do not pass uid.
19503 (symbol_table::allocate_cgraph_symbol): Do not set uid.
19504 * passes.c (uid_hash_t): Record removed_nodes by their uids.
19505 (remove_cgraph_node_from_order): Use the removed_nodes set.
19506 (do_per_function_toporder): Likwise.
19507 * symbol-summary.h (symtab_insertion): Use cgraph_node::uid
19508 instead of summary_uid.
19509 (symtab_removal): Likewise.
19510 (symtab_duplication): Likewise.
19512 2018-06-08 Martin Liska <mliska@suse.cz>
19514 * ipa-cp.c (ipcp_store_bits_results): Use
19515 ipcp_transformation_sum.
19516 (ipcp_store_vr_results): Likewise.
19517 * ipa-prop.c (ipcp_grow_transformations_if_necessary): Renamed
19519 (ipcp_transformation_initialize): ... this.
19520 (ipa_set_node_agg_value_chain):
19521 (ipa_node_params_t::duplicate): Use ipcp_transformation_sum.
19522 (write_ipcp_transformation_info): Likewise.
19523 (read_ipcp_transformation_info): Likewise.
19524 (ipcp_update_bits): Likewise.
19525 (ipcp_update_vr): Likewise.
19526 (ipcp_transform_function): Likewise.
19527 * ipa-prop.h: Rename ipcp_transformation_summary to
19528 ipcp_transformation.
19529 (class ipcp_transformation_t): New function summary.
19530 (ipcp_get_transformation_summary): Use ipcp_transformation_sum.
19531 (ipa_get_agg_replacements_for_node): Likewise.
19533 2018-06-08 Martin Liska <mliska@suse.cz>
19535 * ipa-pure-const.c (struct funct_state_d): Do it class instead
19537 (class funct_state_summary_t): New function_summary class.
19538 (has_function_state): Remove.
19539 (get_function_state): Likewise.
19540 (set_function_state): Likewise.
19541 (add_new_function): Likewise.
19542 (funct_state_summary_t::insert): New function.
19543 (duplicate_node_data): Remove.
19544 (remove_node_data): Remove.
19545 (funct_state_summary_t::duplicate): New function.
19546 (register_hooks): Create new funct_state_summaries.
19547 (pure_const_generate_summary): Use it.
19548 (pure_const_write_summary): Likewise.
19549 (pure_const_read_summary): Likewise.
19550 (propagate_pure_const): Likewise.
19551 (propagate_nothrow): Likewise.
19552 (dump_malloc_lattice): Likewise.
19553 (propagate_malloc): Likewise.
19554 (execute): Do not register hooks, just remove summary
19556 (pass_ipa_pure_const::pass_ipa_pure_const): Simplify
19559 2018-06-08 Martin Liska <mliska@suse.cz>
19561 * ipa-reference.c (remove_node_data): Remove.
19562 (duplicate_node_data): Likewise.
19563 (class ipa_ref_var_info_summary_t): New class.
19564 (class ipa_ref_opt_summary_t): Likewise.
19565 (get_reference_vars_info): Use ipa_ref_var_info_summaries.
19566 (get_reference_optimization_summary): Use
19567 ipa_ref_opt_sum_summaries.
19568 (set_reference_vars_info): Remove.
19569 (set_reference_optimization_summary): Likewise.
19570 (ipa_init): Create summaries.
19571 (init_function_info): Use function summary.
19572 (ipa_ref_opt_summary_t::duplicate): New function.
19573 (ipa_ref_opt_summary_t::remove): New function.
19574 (get_read_write_all_from_node): Fix GNU coding style.
19575 (propagate): Use function summary.
19576 (write_node_summary_p): Fix GNU coding style.
19577 (stream_out_bitmap): Likewise.
19578 (ipa_reference_read_optimization_summary): Use function summary.
19579 (ipa_reference_c_finalize): Do not release hooks.
19581 2018-06-08 Martin Liska <mliska@suse.cz>
19583 * ipa-fnsummary.c (dump_ipa_call_summary): Use ::get method.
19584 (analyze_function_body): Extract multiple calls of get_create.
19585 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
19586 * ipa-inline.c (recursive_inlining): Use ::get method.
19587 * ipa-inline.h (estimate_edge_growth): Likewise.
19589 2018-06-08 Martin Liska <mliska@suse.cz>
19591 * hsa-common.h (enum hsa_function_kind): Rename HSA_NONE to
19593 (hsa_function_summary::hsa_function_summary): Use the new enum
19595 (hsa_gpu_implementation_p): Use hsa_summaries::get.
19596 * hsa-gen.c (hsa_get_host_function): Likewise.
19597 (get_brig_function_name): Likewise.
19598 * ipa-hsa.c (process_hsa_functions): Likewise.
19599 (ipa_hsa_write_summary): Likewise.
19600 * symbol-summary.h (symtab_duplication): Use ::get function/
19601 (get): New function.
19603 2018-06-08 Martin Liska <mliska@suse.cz>
19605 * config/i386/i386.c (ix86_can_inline_p): Use get_create instead
19607 * hsa-common.c (hsa_summary_t::link_functions): Likewise.
19608 (hsa_register_kernel): Likewise.
19609 * hsa-common.h (hsa_gpu_implementation_p): Likewise.
19610 * hsa-gen.c (hsa_get_host_function): Likewise.
19611 (get_brig_function_name): Likewise.
19612 (generate_hsa): Likewise.
19613 (pass_gen_hsail::execute): Likewise.
19614 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
19615 (devirtualization_time_bonus): Likewise.
19616 (ipcp_propagate_stage): Likewise.
19617 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
19618 (edge_set_predicate): Likewise.
19619 (evaluate_conditions_for_known_args): Likewise.
19620 (evaluate_properties_for_edge): Likewise.
19621 (ipa_fn_summary::reset): Likewise.
19622 (ipa_fn_summary_t::duplicate): Likewise.
19623 (dump_ipa_call_summary): Likewise.
19624 (ipa_dump_fn_summary): Likewise.
19625 (analyze_function_body): Likewise.
19626 (compute_fn_summary): Likewise.
19627 (estimate_edge_devirt_benefit): Likewise.
19628 (estimate_edge_size_and_time): Likewise.
19629 (estimate_calls_size_and_time): Likewise.
19630 (estimate_node_size_and_time): Likewise.
19631 (inline_update_callee_summaries): Likewise.
19632 (remap_edge_change_prob): Likewise.
19633 (remap_edge_summaries): Likewise.
19634 (ipa_merge_fn_summary_after_inlining): Likewise.
19635 (ipa_update_overall_fn_summary): Likewise.
19636 (read_ipa_call_summary): Likewise.
19637 (inline_read_section): Likewise.
19638 (write_ipa_call_summary): Likewise.
19639 (ipa_fn_summary_write): Likewise.
19640 (ipa_free_fn_summary): Likewise.
19641 * ipa-hsa.c (process_hsa_functions): Likewise.
19642 (ipa_hsa_write_summary): Likewise.
19643 (ipa_hsa_read_section): Likewise.
19644 * ipa-icf.c (sem_function::merge): Likewise.
19645 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
19646 (do_estimate_edge_time): Likewise.
19647 (estimate_size_after_inlining): Likewise.
19648 (estimate_growth): Likewise.
19649 (growth_likely_positive): Likewise.
19650 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
19651 (inline_call): Likewise.
19652 * ipa-inline.c (caller_growth_limits): Likewise.
19653 (can_inline_edge_p): Likewise.
19654 (can_inline_edge_by_limits_p): Likewise.
19655 (compute_uninlined_call_time): Likewise.
19656 (compute_inlined_call_time): Likewise.
19657 (want_inline_small_function_p): Likewise.
19658 (edge_badness): Likewise.
19659 (update_caller_keys): Likewise.
19660 (update_callee_keys): Likewise.
19661 (recursive_inlining): Likewise.
19662 (inline_small_functions): Likewise.
19663 (inline_to_all_callers_1): Likewise.
19664 (dump_overall_stats): Likewise.
19665 (early_inline_small_functions): Likewise.
19666 (early_inliner): Likewise.
19667 * ipa-inline.h (estimate_edge_growth): Likewise.
19668 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
19669 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
19670 * ipa-prop.h (IPA_NODE_REF): Likewise.
19671 (IPA_EDGE_REF): Likewise.
19672 * ipa-pure-const.c (malloc_candidate_p): Likewise.
19673 (propagate_malloc): Likewise.
19674 * ipa-split.c (execute_split_functions): Likewise.
19675 * symbol-summary.h: Rename get to get_create.
19677 (get_create): Likewise.
19678 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
19680 2018-06-08 Martin Liska <mliska@suse.cz>
19682 * symbol-summary.h (release): Move definition out of class
19684 (symtab_removal): Likewise.
19685 (symtab_duplication): Likewise.
19687 2018-06-08 Martin Liska <mliska@suse.cz>
19689 * symbol-summary.h (function_summary): Move constructor
19690 implementation out of class declaration.
19691 (release): Likewise.
19692 (symtab_insertion): Likewise.
19693 (symtab_removal): Likewise.
19694 (symtab_duplication): Likewise.
19697 2018-06-08 Martin Liska <mliska@suse.cz>
19699 * Makefile.in: Remove support for MPX (macros, related functions,
19700 fields in cgraph_node, ...).
19701 * builtin-types.def (BT_BND): Likewise.
19702 (BT_FN_BND_CONST_PTR): Likewise.
19703 (BT_FN_CONST_PTR_BND): Likewise.
19704 (BT_FN_VOID_PTR_BND): Likewise.
19705 (BT_FN_BND_CONST_PTR_SIZE): Likewise.
19706 (BT_FN_VOID_CONST_PTR_BND_CONST_PTR): Likewise.
19707 * builtins.c (expand_builtin_memcpy_with_bounds): Likewise.
19708 (expand_builtin_mempcpy_with_bounds): Likewise.
19709 (expand_builtin_memset_with_bounds): Likewise.
19710 (expand_builtin_memset_args): Likewise.
19711 (std_expand_builtin_va_start): Likewise.
19712 (expand_builtin): Likewise.
19713 (expand_builtin_with_bounds): Likewise.
19714 * builtins.def (DEF_BUILTIN_CHKP): Likewise.
19715 (DEF_LIB_BUILTIN_CHKP): Likewise.
19716 (DEF_EXT_LIB_BUILTIN_CHKP): Likewise.
19717 (DEF_CHKP_BUILTIN): Likewise.
19718 (BUILT_IN_MEMCPY): Likewise.
19719 (BUILT_IN_MEMMOVE): Likewise.
19720 (BUILT_IN_MEMPCPY): Likewise.
19721 (BUILT_IN_MEMSET): Likewise.
19722 (BUILT_IN_STPCPY): Likewise.
19723 (BUILT_IN_STRCAT): Likewise.
19724 (BUILT_IN_STRCHR): Likewise.
19725 (BUILT_IN_STRCPY): Likewise.
19726 (BUILT_IN_STRLEN): Likewise.
19727 (BUILT_IN_MEMCPY_CHK): Likewise.
19728 (BUILT_IN_MEMMOVE_CHK): Likewise.
19729 (BUILT_IN_MEMPCPY_CHK): Likewise.
19730 (BUILT_IN_MEMSET_CHK): Likewise.
19731 (BUILT_IN_STPCPY_CHK): Likewise.
19732 (BUILT_IN_STRCAT_CHK): Likewise.
19733 (BUILT_IN_STRCPY_CHK): Likewise.
19734 * calls.c (store_bounds): Likewise.
19735 (emit_call_1): Likewise.
19736 (special_function_p): Likewise.
19737 (maybe_warn_nonstring_arg): Likewise.
19738 (initialize_argument_information): Likewise.
19739 (finalize_must_preallocate): Likewise.
19740 (compute_argument_addresses): Likewise.
19741 (expand_call): Likewise.
19742 * cfgexpand.c (expand_call_stmt): Likewise.
19743 (expand_return): Likewise.
19744 (expand_gimple_stmt_1): Likewise.
19745 (pass_expand::execute): Likewise.
19746 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
19747 (cgraph_node::remove): Likewise.
19748 (cgraph_node::dump): Likewise.
19749 (cgraph_node::verify_node): Likewise.
19750 * cgraph.h (chkp_function_instrumented_p): Likewise.
19751 (symtab_node::get_alias_target): Likewise.
19752 (cgraph_node::can_remove_if_no_direct_calls_and_refs_p): Likewise.
19753 (cgraph_local_p): Likewise.
19754 * cgraphbuild.c (cgraph_edge::rebuild_edges): Likewise.
19755 (cgraph_edge::rebuild_references): Likewise.
19756 * cgraphunit.c (varpool_node::finalize_decl): Likewise.
19757 (walk_polymorphic_call_targets): Likewise.
19758 (cgraph_node::expand_thunk): Likewise.
19759 (symbol_table::output_weakrefs): Likewise.
19760 * common/config/i386/i386-common.c (OPTION_MASK_ISA2_GENERAL_REGS_ONLY_UNSET): Likewise.
19761 (ix86_handle_option): Likewise.
19762 * config/i386/constraints.md: Likewise.
19763 * config/i386/i386-builtin-types.def (BND): Likewise.
19767 * config/i386/i386-builtin.def (BDESC_END): Likewise.
19768 (BDESC_FIRST): Likewise.
19770 * config/i386/i386-c.c (ix86_target_macros_internal): Likewise.
19771 * config/i386/i386-protos.h (ix86_bnd_prefixed_insn_p): Likewise.
19772 * config/i386/i386.c (enum reg_class): Likewise.
19773 (ix86_target_string): Likewise.
19774 (ix86_option_override_internal): Likewise.
19775 (ix86_conditional_register_usage): Likewise.
19776 (ix86_valid_target_attribute_inner_p): Likewise.
19777 (ix86_set_indirect_branch_type): Likewise.
19778 (ix86_set_current_function): Likewise.
19779 (ix86_function_arg_regno_p): Likewise.
19780 (init_cumulative_args): Likewise.
19781 (ix86_function_arg_advance): Likewise.
19782 (ix86_function_arg): Likewise.
19783 (ix86_pass_by_reference): Likewise.
19784 (ix86_function_value_regno_p): Likewise.
19785 (ix86_function_value_1): Likewise.
19786 (ix86_function_value_bounds): Likewise.
19787 (ix86_return_in_memory): Likewise.
19788 (ix86_setup_incoming_vararg_bounds): Likewise.
19789 (ix86_va_start): Likewise.
19790 (indirect_thunk_need_prefix): Likewise.
19791 (print_reg): Likewise.
19792 (ix86_print_operand): Likewise.
19793 (ix86_expand_call): Likewise.
19794 (ix86_output_function_return): Likewise.
19795 (reg_encoded_number): Likewise.
19796 (BDESC_VERIFYS): Likewise.
19797 (ix86_init_mpx_builtins): Likewise.
19798 (ix86_init_builtins): Likewise.
19799 (ix86_emit_cmove): Likewise.
19800 (ix86_emit_move_max): Likewise.
19801 (ix86_expand_builtin): Likewise.
19802 (ix86_builtin_mpx_function): Likewise.
19803 (ix86_get_arg_address_for_bt): Likewise.
19804 (ix86_load_bounds): Likewise.
19805 (ix86_store_bounds): Likewise.
19806 (ix86_load_returned_bounds): Likewise.
19807 (ix86_store_returned_bounds): Likewise.
19808 (ix86_class_likely_spilled_p): Likewise.
19809 (ix86_hard_regno_mode_ok): Likewise.
19810 (x86_order_regs_for_local_alloc): Likewise.
19811 (ix86_mitigate_rop): Likewise.
19812 (ix86_bnd_prefixed_insn_p): Likewise.
19813 (ix86_mpx_bound_mode): Likewise.
19814 (ix86_make_bounds_constant): Likewise.
19815 (ix86_initialize_bounds): Likewise.
19816 (TARGET_LOAD_BOUNDS_FOR_ARG): Likewise.
19817 (TARGET_STORE_BOUNDS_FOR_ARG): Likewise.
19818 (TARGET_LOAD_RETURNED_BOUNDS): Likewise.
19819 (TARGET_STORE_RETURNED_BOUNDS): Likewise.
19820 (TARGET_CHKP_BOUND_MODE): Likewise.
19821 (TARGET_BUILTIN_CHKP_FUNCTION): Likewise.
19822 (TARGET_CHKP_FUNCTION_VALUE_BOUNDS): Likewise.
19823 (TARGET_CHKP_MAKE_BOUNDS_CONSTANT): Likewise.
19824 (TARGET_CHKP_INITIALIZE_BOUNDS): Likewise.
19825 * config/i386/i386.h (TARGET_MPX): Likewise.
19826 (TARGET_MPX_P): Likewise.
19827 (VALID_BND_REG_MODE): Likewise.
19828 (FIRST_BND_REG): Likewise.
19829 (LAST_BND_REG): Likewise.
19830 (enum reg_class): Likewise.
19831 (BND_REG_P): Likewise.
19832 (BND_REGNO_P): Likewise.
19833 (BNDmode): Likewise.
19834 (ADJUST_INSN_LENGTH): Likewise.
19835 * config/i386/i386.md: Likewise.
19836 * config/i386/i386.opt: Likewise.
19837 * config/i386/linux-common.h (LIBMPX_LIBS): Likewise.
19838 (defined): Likewise.
19839 (LINK_MPX): Likewise.
19840 (MPX_SPEC): Likewise.
19841 (LIBMPX_SPEC): Likewise.
19842 (LIBMPXWRAPPERS_SPEC): Likewise.
19843 (CHKP_SPEC): Likewise.
19844 * config/i386/predicates.md: Likewise.
19845 * dbxout.c (dbxout_type): Likewise.
19846 * doc/extend.texi: Likewise.
19847 * doc/invoke.texi: Likewise.
19848 * doc/md.texi: Likewise.
19849 * doc/tm.texi: Likewise.
19850 * doc/tm.texi.in: Likewise.
19851 * dwarf2out.c (is_base_type): Likewise.
19852 (gen_formal_types_die): Likewise.
19853 (gen_subprogram_die): Likewise.
19854 (gen_type_die_with_usage): Likewise.
19855 (gen_decl_die): Likewise.
19856 (dwarf2out_late_global_decl): Likewise.
19857 * expr.c (expand_assignment): Likewise.
19858 (emit_storent_insn): Likewise.
19859 (store_expr_with_bounds): Likewise.
19860 (store_expr): Likewise.
19861 (expand_expr_real_1): Likewise.
19862 * expr.h (store_expr_with_bounds): Likewise.
19863 * function.c (use_register_for_decl): Likewise.
19864 (struct bounds_parm_data): Likewise.
19865 (assign_parms_augmented_arg_list): Likewise.
19866 (assign_parm_find_entry_rtl): Likewise.
19867 (assign_parm_is_stack_parm): Likewise.
19868 (assign_parm_load_bounds): Likewise.
19869 (assign_bounds): Likewise.
19870 (assign_parms): Likewise.
19871 (expand_function_start): Likewise.
19872 * gcc.c (CHKP_SPEC): Likewise.
19873 * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
19874 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Likewise.
19875 (wrestrict_dom_walker::check_call): Likewise.
19876 * gimple.c (gimple_build_call_from_tree): Likewise.
19877 * gimple.h (enum gf_mask): Likewise.
19878 (gimple_call_with_bounds_p): Likewise.
19879 (gimple_call_set_with_bounds): Likewise.
19880 * gimplify.c (gimplify_init_constructor): Likewise.
19881 * ipa-cp.c (initialize_node_lattices): Likewise.
19882 (propagate_constants_across_call): Likewise.
19883 (find_more_scalar_values_for_callers_subset): Likewise.
19884 * ipa-hsa.c (process_hsa_functions): Likewise.
19885 * ipa-icf-gimple.c (func_checker::compare_gimple_call): Likewise.
19886 * ipa-icf.c (sem_function::merge): Likewise.
19887 * ipa-inline.c (early_inliner): Likewise.
19888 * ipa-pure-const.c (warn_function_noreturn): Likewise.
19889 (warn_function_cold): Likewise.
19890 (propagate_pure_const): Likewise.
19891 * ipa-ref.h (enum GTY): Likewise.
19892 * ipa-split.c (find_retbnd): Likewise.
19893 (consider_split): Likewise.
19894 (split_function): Likewise.
19895 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
19896 * ipa.c (walk_polymorphic_call_targets): Likewise.
19897 (symbol_table::remove_unreachable_nodes): Likewise.
19898 (process_references): Likewise.
19899 (cgraph_build_static_cdtor_1): Likewise.
19900 * lto-cgraph.c (lto_output_node): Likewise.
19901 (output_refs): Likewise.
19902 (compute_ltrans_boundary): Likewise.
19903 (input_overwrite_node): Likewise.
19904 (input_node): Likewise.
19905 (input_cgraph_1): Likewise.
19906 * params.def (PARAM_CHKP_MAX_CTOR_SIZE): Likewise.
19907 * passes.c (pass_manager::execute_early_local_passes): Likewise.
19908 (class pass_chkp_instrumentation_passes): Likewise.
19909 (make_pass_chkp_instrumentation_passes): Likewise.
19910 * passes.def: Likewise.
19911 * rtl.h (struct GTY): Likewise.
19912 (CALL_EXPR_WITH_BOUNDS_P): Likewise.
19913 * stor-layout.c (layout_type): Likewise.
19914 * symtab.c: Likewise.
19915 * target.def: Likewise.
19916 * targhooks.c (default_chkp_bound_type): Likewise.
19917 (default_chkp_bound_mode): Likewise.
19918 (default_builtin_chkp_function): Likewise.
19919 (default_chkp_function_value_bounds): Likewise.
19920 (default_chkp_make_bounds_constant): Likewise.
19921 (default_chkp_initialize_bounds): Likewise.
19922 * targhooks.h (default_chkp_bound_type): Likewise.
19923 (default_chkp_bound_mode): Likewise.
19924 (default_builtin_chkp_function): Likewise.
19925 (default_chkp_function_value_bounds): Likewise.
19926 (default_chkp_make_bounds_constant): Likewise.
19927 (default_chkp_initialize_bounds): Likewise.
19928 * toplev.c (compile_file): Likewise.
19929 (process_options): Likewise.
19930 * tree-core.h (DEF_BUILTIN): Likewise.
19931 (DEF_BUILTIN_CHKP): Likewise.
19932 * tree-inline.c (declare_return_variable): Likewise.
19933 (remap_gimple_stmt): Likewise.
19934 (copy_bb): Likewise.
19935 (initialize_inlined_parameters): Likewise.
19936 (expand_call_inline): Likewise.
19937 * tree-pass.h (make_pass_ipa_chkp_versioning): Likewise.
19938 (make_pass_ipa_chkp_early_produce_thunks): Likewise.
19939 (make_pass_ipa_chkp_produce_thunks): Likewise.
19940 (make_pass_chkp): Likewise.
19941 (make_pass_chkp_opt): Likewise.
19942 (make_pass_chkp_instrumentation_passes): Likewise.
19943 * tree-pretty-print.c (dump_generic_node): Likewise.
19944 * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Likewise.
19945 * tree-ssa-dce.c (propagate_necessity): Likewise.
19946 (eliminate_unnecessary_stmts): Likewise.
19947 * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
19948 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
19949 * tree-ssa-sccvn.h: Likewise.
19950 * tree-ssa-strlen.c (get_string_length): Likewise.
19951 (valid_builtin_call): Likewise.
19952 (adjust_last_stmt): Likewise.
19953 (handle_builtin_strchr): Likewise.
19954 (handle_builtin_strcpy): Likewise.
19955 (handle_builtin_stxncpy): Likewise.
19956 (handle_builtin_memcpy): Likewise.
19957 (handle_builtin_strcat): Likewise.
19958 (strlen_check_and_optimize_stmt): Likewise.
19959 * tree-stdarg.c (expand_ifn_va_arg_1): Likewise.
19960 * tree-streamer-in.c: Likewise.
19961 * tree-streamer.c (record_common_node): Likewise.
19962 * tree.c (tree_code_size): Likewise.
19963 (wide_int_to_tree_1): Likewise.
19964 (type_contains_placeholder_1): Likewise.
19965 (build_common_tree_nodes): Likewise.
19966 * tree.def (POINTER_BOUNDS_TYPE): Likewise.
19967 * tree.h (POINTER_BOUNDS_TYPE_P): Likewise.
19968 (POINTER_BOUNDS_P): Likewise.
19969 (BOUNDED_TYPE_P): Likewise.
19970 (BOUNDED_P): Likewise.
19971 (CALL_WITH_BOUNDS_P): Likewise.
19972 (pointer_bounds_type_node): Likewise.
19973 * value-prof.c (gimple_ic): Likewise.
19974 * var-tracking.c (vt_add_function_parameters): Likewise.
19975 * varasm.c (make_decl_rtl): Likewise.
19976 (assemble_start_function): Likewise.
19977 (output_constant): Likewise.
19978 (maybe_assemble_visibility): Likewise.
19979 * varpool.c (ctor_for_folding): Likewise.
19980 * chkp-builtins.def: Remove.
19981 * ipa-chkp.c: Remove.
19982 * ipa-chkp.h: Remove.
19983 * rtl-chkp.c: Remove.
19984 * rtl-chkp.h: Remove.
19985 * tree-chkp-opt.c: Remove.
19986 * tree-chkp.c: Remove.
19987 * tree-chkp.h: Remove.
19989 2018-06-07 Carl Love <cel@us.ibm.com>
19991 * config/rs6000/vsx.md (vextract_fp_from_shorth,
19992 vextract_fp_from_shortl): Add BE support.
19994 2018-06-07 Paul Koning <ni1d@arrl.net>
19996 * compare-elim.c (try_merge_compare): Don't merge compare if
19997 address contains a side effect.
19998 (try_eliminate_compare): Likewise.
20000 2018-06-07 Olga Makhotina <olga.makhotina@intel.com>
20002 * config.gcc: Support "tremont".
20003 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "tremont".
20004 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
20006 * config/i386/i386.c (m_TREMONT): Define.
20007 (processor_target_table): Add "tremont".
20008 (PTA_TREMONT): Define.
20009 (ix86_lea_outperforms): Add TARGET_TREMONT.
20010 (get_builtin_code_for_version): Handle PROCESSOR_TREMONT.
20011 (fold_builtin_cpu): Add M_INTEL_TREMONT, replace M_INTEL_GOLDMONT
20012 and M_INTEL_GOLDMONT_PLUS.
20013 (fold_builtin_cpu): Add "tremont".
20014 (ix86_add_stmt_cost): Add TARGET_TREMONT.
20015 (ix86_option_override_internal): Add "tremont".
20016 * config/i386/i386.h (processor_costs): Define TARGET_TREMONT.
20017 (processor_type): Add PROCESSOR_TREMONT.
20018 * config/i386/x86-tune.def: Add m_TREMONT.
20019 * doc/invoke.texi: Add tremont as x86 -march=/-mtune= CPU type.
20021 2018-06-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
20023 * config/msp430/msp430.c (msp430_mcu_name): Set the "i" in the
20024 symbol defined for msp430i* devices to be lower case.
20026 2018-06-07 Richard Biener <rguenther@suse.de>
20028 * graphite-sese-to-poly.c (extract_affine): Avoid unneded
20029 wrapping. Properly wrap the result of a BIT_NOT_EXPR.
20030 Properly wrap signed arithmetic if overflow wraps.
20032 2018-06-07 Jakub Jelinek <jakub@redhat.com>
20034 PR tree-optimization/69615
20035 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If rhs2 is lhs
20036 of a cast from a same precision integral SSA_NAME in a bb dominated
20037 by first_bb, retry with rhs2 set to the rhs1 of the cast. Don't emit
20038 cast to utype if rhs2 has already a compatible type.
20040 2018-06-07 Richard Biener <rguenther@suse.de>
20042 PR tree-optimization/85935
20043 * graphite-scop-detection.c (find_params_in_bb): Analyze
20044 condition operands with respect to the correct loop. Assert
20045 the analysis doesn't fail.
20047 2018-06-04 Carl Love <cel@us.ibm.com>
20049 * config/rs6000/vsx.md (first_match_index_<mode>): Calculate index
20050 using natural element order. Use gen_lshrsi3 instead of gen_ashrsi3
20051 as it is slightly cheaper.
20052 (first_match_or_eos_index_<mode>):
20053 Calculate index using natural element order.
20054 (first_match_index_<mode>):
20055 Calculate index using natural element order.
20056 (first_match_or_eos_index_<mode>):
20057 Calculate index using natural order.
20058 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
20059 for BE and LE modes.
20060 * config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
20061 P9V_BUILTIN_VCLZLSBB_V16QI.
20062 * config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
20065 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
20067 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
20068 indentation and line wrap for many prototypes. Add missing
20069 @smallexample directives around block of prototypes for vec_xl and
20072 2018-06-05 Michael Meissner <meissner@linux.ibm.com>
20074 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
20075 track if we pass or return IEEE 128-bit floating point.
20076 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
20077 C++ mangling that is compatible with GCC 8.1.
20078 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
20079 (init_cumulative_args): Note if we pass or return IEEE 128-bit
20080 floating point types.
20081 (rs6000_function_arg_advance_1): Likewise.
20082 (rs6000_mangle_type): Optionally generate mangled names that match
20083 what GCC 8.1 generated for IEEE 128-bit floating point types.
20084 (rs6000_globalize_decl_name): If we have an external function that
20085 passes or returns IEEE 128-bit types, generate a weak reference
20086 from the mangled name used in GCC 8.1 to the current mangled
20088 (rs6000_init_builtins): Make __ibm128 use the long double type if
20089 long double is IBM extended double. Make __float128 use the long
20090 double type if long double is IEEE 128-bit.
20093 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
20094 macro for __ibm128 built-in functions.
20095 (PACK_IF): Add __ibm128 pack/unpack functions.
20096 (UNPACK_IF): Likewise.
20097 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
20098 enable long double built-in functions if long double is IEEE
20099 128-bit floating point.
20100 (rs6000_invalid_builtin): Update long double built-in function
20102 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
20103 functions, adjust the built-in function to use the long double
20104 built-in function if __ibm128 and long double are the same type.
20105 * doc/extend.texi (PowerPC builtins): Update documention for
20106 __builtin_{,un}pack_longdouble. Add documentation for
20107 __builtin_{,un}pack_ibm128.
20109 2018-06-06 Jim Wilson <jimw@sifive.com>
20111 * config/riscv/riscv.c (enum riscv_privilege_levels): New.
20112 (struct machine_function): New field interrupt_mode.
20113 (riscv_handle_type_attribute): New function. Add forward declaration.
20114 (riscv_attribute_table) <interrupt>: Use riscv_handle_type_attribute.
20115 (riscv_expand_epilogue): Check interrupt_mode field.
20116 (riscv_set_current_function): Check interrupt attribute args and
20117 set interrupt_mode field.
20118 * config/riscv/riscv.md (UNSPECV_SRET, UNSPECV_URET): New.
20119 (riscv_sret, riscv_uret): New.
20120 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: Document
20121 new arguments to interrupt attribute.
20123 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
20126 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
20127 Don't handle -mcpu=power8 if -mpower9-vector is also used.
20129 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
20131 * config/rs6000/rs6000-builtin.def (VSX_BUILTIN_VEC_LD,
20132 VSX_BUILTIN_VEC_ST): Add comment to explain non-traditional uses.
20133 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
20134 several redundant entries.
20136 2018-06-06 David Malcolm <dmalcolm@redhat.com>
20138 * config/i386/i386-protos.h (ix86_expand_call): Strengthen return
20139 type from "rtx" to "rtx_insn *".
20140 * config/i386/i386.c (ix86_expand_split_stack_prologue): Likewise
20141 for local "call_insn", removing cast.
20142 (ix86_expand_call): Likewise, introducing a "call_insn" local.
20144 2018-06-06 Eric Botcazou <ebotcazou@adacore.com>
20146 PR tree-optimization/86066
20147 * gimple-ssa-store-merging.c (process_store): Do not bypass BIT_NOT_EXPR
20148 for BIT_INSERT_EXPR stores.
20150 2018-06-06 Richard Biener <rguenther@suse.de>
20152 PR tree-optimization/86062
20153 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
20154 component refs ontop
20155 of to be offsetted base.
20157 2018-06-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
20159 * config/msp430/msp430.c (msp430_attr): Allow interrupt handlers
20160 to be static and remove check on interrupt attribute name.
20162 2018-06-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
20164 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
20165 volatile qualifier from vec_lvsl and vec_lvsr argument prototypes.
20167 2018-06-05 Steve Ellcey <sellcey@cavium.com>
20170 * config/aarch64/aarch64-protos.h (aarch64_err_no_fpadvsimd): Remove
20172 * config/aarch64/aarch64-protos..c (aarch64_err_no_fpadvsimd):
20173 Remove second argument, change how error is called.
20174 (aarch64_layout_arg): Remove second argument from
20175 aarch64_err_no_fpadvsimd call.
20176 (aarch64_init_cumulative_args): Ditto.
20177 (aarch64_gimplify_va_arg_expr): Ditto.
20178 * config/aarch64/aarch64.md (mov<mode>): Ditto.
20180 2018-06-05 Uros Bizjak <ubizjak@gmail.com>
20182 * config/i386/i386.md (simple_return_indirect_internal): New expander.
20183 (*simple_return_indirect_internal<mode>): Rename from
20184 simple_return_indirect_internal. Use W mode iterator.
20185 (rstorssp): New expander.
20186 (*rstorssp<mode>): Rename from rstorssp. Use P mode iterator.
20187 (clrssbsy): New expander.
20188 (*clrssbsy<mode>): Rename from clrssbsy. Use P mode iterator.
20190 2018-06-05 Andre Vieira <andre.simoesdiasvieira@arm.com>
20192 * config/arm/arm_cmse.h (cmse_nsfptr_create): Change typeof to
20194 (cmse_check_pointed_object): Likewise.
20196 2018-06-05 Martin Liska <mliska@suse.cz>
20198 PR gcov-profile/47618
20199 * doc/invoke.texi: Document how -fprofile-dir format
20202 2018-06-05 Richard Biener <rguenther@suse.de>
20204 * tree-cfgcleanup.c (cleanup_control_flow_pre): For edge
20205 removal pretend DOM info isn't available so we do not update
20206 it and only remove edges, not dominated blocks. Actually free
20207 DOM info in case we removed something. Remove unreachable blocks.
20208 (mfb_keep_latches): Work with either DOM info or marked backedges.
20209 (cleanup_tree_cfg_noloop): Do not remove unreachable blocks
20210 first. Mark backedges if DOM info isn't available.
20211 (Re-)compute DOM info after cleanup_control_flow_pre.
20213 2018-06-05 Richard Biener <rguenther@suse.de>
20215 * tree-cfg.c (struct locus_discrim_map): Store line, not location.
20216 (locus_discrim_hasher::hash): Adjust.
20217 (locus_discrim_hasher::equal): Likewise.
20218 (next_discriminator_for_locus): Work on line directly.
20219 (same_line_p): Pass in expanded locus1 as well.
20220 (assign_discriminators): Avoid redundant location expansions.
20222 2018-06-05 Richard Biener <rguenther@suse.de>
20224 PR tree-optimization/86046
20225 * tree-ssa.c (maybe_optimize_var): Clear DECL_GIMPLE_REG_P
20226 if required after clearing TREE_ADDRESSABLE.
20228 2018-06-05 Richard Biener <rguenther@suse.de>
20230 PR tree-optimization/86047
20231 * tree-ssa-loop.c (for_each_index): Glob handling of all
20232 decls and constants and really handle all of them.
20234 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20237 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
20238 qualifier_void_pointer and qualifier_const_void_pointer.
20239 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
20240 (arm_init_builtins): Handle the above.
20241 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
20242 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
20243 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
20246 2018-06-05 Martin Liska <mliska@suse.cz>
20248 * auto-profile.c (read_autofdo_file): Do not use
20249 gcov_ctr_summary struct.
20250 (afdo_callsite_hot_enough_for_early_inline): Likewise.
20251 * coverage.c (struct counts_entry): Likewise.
20252 (read_counts_file): Read just single summary entry.
20253 (get_coverage_counts): Use gcov_summary struct.
20254 * coverage.h (get_coverage_counts): Likewise.
20255 * gcov-dump.c (dump_working_sets): Likewise.
20256 (tag_summary): Dump just single summary.
20257 * gcov-io.c (gcov_write_summary): Write just histogram
20259 (gcov_read_summary): Read just single summary.
20260 (compute_working_sets): Use gcov_summary struct.
20261 * gcov-io.h (GCOV_TAG_SUMMARY_LENGTH): Remove usage
20262 of GCOV_COUNTERS_SUMMABLE.
20263 (GCOV_COUNTERS_SUMMABLE): Remove.
20264 (GCOV_FIRST_VALUE_COUNTER): Replace with
20265 GCOV_COUNTER_V_INTERVAL.
20266 (struct gcov_ctr_summary): Remove.
20267 (struct gcov_summary): Directly use fields of former
20269 (compute_working_sets): Use gcov_summary struct.
20270 * gcov.c (read_count_file): Do not use ctrs fields.
20271 * lto-cgraph.c (merge_profile_summaries): Use gcov_summary
20273 * lto-streamer.h (struct GTY): Make profile_info gcov_summary
20275 * profile.c: Likewise.
20276 * profile.h: Likewise.
20278 2018-06-05 Martin Liska <mliska@suse.cz>
20280 PR gcov-profile/84846
20281 * gcov.c (output_lines): Print working directory only
20282 in intermediate format.
20284 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
20286 * config/s390/s390-builtin-types.def: Add void function type.
20287 * config/s390/s390-builtins.def: Use the function type for the
20290 2018-06-04 Jim Wilson <jimw@sifive.com>
20292 * config/riscv/riscv-protos.h (riscv_expand_epilogue): Change bool arg
20294 * config/riscv/riscv.c (riscv_for_each_saved_reg): New args epilogue
20295 and maybe_eh_return. Change regno to unsigned int. Use new args to
20296 handle EH_RETURN_DATA_REGNO registers properly.
20297 (riscv_expand_prologue): Pass new args to riscv_for_each_saved_reg.
20298 (riscv_expand_epilogue): Update comment. Change argument name and
20299 type. Update code to use new name and type. Pass new args to
20300 riscv_for_each_saved_reg. Only use EH_RETURN_STACKADJ_RTX when
20302 * config/riscv/riscv.md (NORMAL_RETURN): New.
20303 (SIBCALL_RETURN, EXCEPTION_RETURN): New.
20304 (epilogue, sibcall_epilogue): Update riscv_expand_epilogue arg.
20305 (eh_return): Call gen_eh_return_internal and emit barrier.
20306 (eh_return_internal): Call riscv_expand_epilogue.
20308 2018-06-04 Eric Botcazou <ebotcazou@adacore.com>
20310 * gimple-ssa-store-merging.c (struct merged_store_group): Move up
20311 bit_insertion field and declare can_be_merged_into method.
20312 (merged_store_group::can_be_merged_into): New method.
20313 (imm_store_chain_info::coalesce_immediate): Call it to decide whether
20314 consecutive non-overlapping stores can be merged. Turn MEM_REF stores
20315 into BIT_INSERT_EXPR stores if the group contains a non-MEM_REF store.
20317 2018-06-04 Richard Biener <rguenther@suse.de>
20319 PR tree-optimization/85955
20320 * builtins.c (fold_builtin_sincos): Convert pointers to
20321 destination to appropriate type before dereferencing.
20323 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
20325 * config/rs6000/rs6000.md (abs<mode>2 for FLOAT128): Handle IFmode.
20327 2018-06-04 Richard Sandiford <richard.sandiford@linaro.org>
20329 * expr.c (expand_expr_real_1): Force the operand into memory if
20330 its TYPE_MODE is BLKmode and if there is no integer mode for
20331 the number of bits being extracted.
20333 2018-06-04 Jakub Jelinek <jakub@redhat.com>
20337 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
20338 Use vptestnm rather than vptestm in (=Yc,v,C) variant.
20340 2018-06-04 Richard Biener <rguenther@suse.de>
20342 * tree-cfgcleanup.c (cleanup_tree_cfg_1): Fold into...
20343 (cleanup_tree_cfg_noloop): ... single caller. Do
20344 start_recording_case_labels later.
20346 2018-06-04 Sebastian Peryt <sebastian.peryt@intel.com>
20348 * config/i386/cldemoteintrin.h: Change define from _X86INTRIN_H_INCLUDED
20349 to _IMMINTRIN_H_INCLUDED.
20350 * config/i386/pconfigintrin.h: Ditto.
20351 * config/i386/waitpkgintrin.h: Ditto.
20352 * config/i386/immintrin.h: Add includes for sgxintrin.h,
20353 pconfigintrin.h, waitpkgintrin.h and cldemoteintrin.h.
20354 * config/i386/x86intrin.h: Remove includes for mintrin.h, xmmintrin.h,
20355 emmintrin.h, pmmintrin.h, tmmintrin.h, smmintrin.h, wmmintrin.h,
20356 bmiintrin.h, bmi2intrin.h, lzcntintrin.h, sgxintrin.h, pconfigintrin.h,
20357 waitpkgintrin.h and cldemoteintrin.h.
20359 2018-06-04 Richard Biener <rguenther@suse.de>
20361 PR tree-optimization/86038
20362 * tracer.c (find_best_successor): Check probability for
20363 being initialized, bail out if not.
20365 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
20368 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
20369 of bits to ignore when comparing architectures.
20371 2018-06-04 Jakub Jelinek <jakub@redhat.com>
20373 PR tree-optimization/69615
20374 * fold-const.c (merge_ranges): If range1 is - [x, x] and x is the
20375 maximum or minimum of the type, try to merge it also as if
20376 range1 is + [-, x - 1] or + [x + 1, -].
20379 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
20381 2018-06-03 Eric Botcazou <ebotcazou@adacore.com>
20383 PR tree-optimization/86034
20384 * gimple-ssa-store-merging.c (output_merged_store): Convert the RHS to
20385 the unsigned bitfield type in a bit insertion sequence if it does not
20386 have a larger precision than the bitfield size.
20387 (process_store): Also bypass widening conversions for BIT_INSERT_EXPR.
20389 2018-06-03 Kito Cheng <kito.cheng@gmail.com>
20391 * config/nds32/nds32-peephole2.md: Add new patterns for code size.
20393 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
20395 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3J.
20396 * config/nds32/nds32.c (nds32_option_override): Consider ARCH_V3J.
20397 * config/nds32/nds32.h (TARGET_ISA_V3): Add ARCH_V3J checking.
20398 * config/nds32/nds32.opt (march): Add enum value Value(ARCH_V3J).
20400 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
20402 * common/config/nds32/nds32-common.c (nds32_option_optimization_table):
20403 Disable -fdelete-null-pointer-checks for ELF toolchain.
20405 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
20406 Kito Cheng <kito.cheng@gmail.com>
20408 * config.gcc (nds32*): Use nds32-linux.opt and nds32-elf.opt.
20409 (nds32le-*-*, nds32be-*-*): Integrate checking process.
20410 (nds32*-*-*): Add glibc and uclibc conditions.
20411 * common/config/nds32/nds32-common.c (nds32_except_unwind_info): New.
20412 (TARGET_EXCEPT_UNWIND_INFO): Define.
20413 * config/nds32/elf.h: New file.
20414 * config/nds32/linux.h: New file.
20415 * config/nds32/nds32-elf.opt: New file.
20416 * config/nds32/nds32-linux.opt: New file.
20417 * config/nds32/nds32-fp-as-gp.c
20418 (pass_nds32_fp_as_gp::gate): Consider TARGET_LINUX_ABI.
20419 * config/nds32/nds32.c (nds32_conditional_register_usage): Consider
20421 (nds32_asm_file_end): Ditto.
20422 (nds32_print_operand): Ditto.
20423 (nds32_insert_attributes): Ditto.
20424 (nds32_init_libfuncs): New function.
20425 (TARGET_HAVE_TLS): Define.
20426 (TARGET_INIT_LIBFUNCS): Define.
20427 * config/nds32/nds32.h (TARGET_DEFAULT_RELAX): Apply different relax
20429 (TARGET_ELF): Apply different mcmodel setting.
20430 (LINK_SPEC, LIB_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): The content has
20431 been migrated into elf.h and linux.h files.
20432 * config/nds32/nds32.md (add_pc): Consider TARGET_LINUX_ABI.
20433 * config/nds32/nds32.opt (mvh): Consider TARGET_LINUX_ABI.
20434 (mcmodel): The content has been migrated into nds32-elf.opt and
20435 nds32-linux.opt files.
20436 * config/nds32/t-elf: New file.
20437 * config/nds32/t-linux: New file.
20439 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
20440 Shiva Chen <shiva0217@gmail.com>
20442 * config/nds32/constants.md (unspec_volatile_element): Add
20443 UNSPEC_VOLATILE_OMIT_FP_BEGIN and UNSPEC_VOLATILE_OMIT_FP_END.
20444 * config/nds32/nds32-fp-as-gp.c: New implementation of fp_as_gp
20446 * config/nds32/nds32-protos.h (nds32_naked_function_p): Declare.
20447 (make_pass_nds32_fp_as_gp): Declare.
20448 * config/nds32/nds32.c (nds32_register_passes): Add fp_as_gp as one
20450 (nds32_asm_function_end_prologue): Remove unused asm output.
20451 (nds32_asm_function_begin_epilogue): Remove unused asm output.
20452 (nds32_asm_file_start): Output necessary fp_as_gp information.
20453 (nds32_option_override): Adjust register usage.
20454 (nds32_expand_prologue): Consider fp_as_gp situation.
20455 (nds32_expand_prologue_v3push): Consider fp_as_gp situation.
20456 * config/nds32/nds32.md (prologue): Check fp_as_gp_p and naked_p.
20459 (simple_return): Ditto.
20460 (omit_fp_begin): Output special directive for fp_as_gp.
20461 (omit_fp_end): Output special directive for fp_as_gp.
20462 * config/nds32/nds32.opt (mfp-as-gp, mno-fp-as-gp, mforce-fp-as-gp,
20463 mforbid-fp-as-gp): New options.
20465 2018-06-01 Mark Wielaard <mark@klomp.org>
20467 * dwarf2out.c (dwarf2out_finish): Remove generation of
20468 DW_AT_loclists_base.
20470 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
20472 * gimple-ssa-store-merging.c: Include gimple-fold.h.
20473 (struct store_immediate_info): Document BIT_INSERT_EXPR stores.
20474 (struct merged_store_group): Add bit_insertion field.
20475 (dump_char_array): Use standard hexadecimal format.
20476 (merged_store_group::merged_store_group): Set bit_insertion to false.
20477 (merged_store_group::apply_stores): Use optimal buffer size. Deal
20478 with BIT_INSERT_EXPR stores. Move up code updating the mask and
20479 also print the mask in the dump file.
20480 (pass_store_merging::gate): Minor tweak.
20481 (imm_store_chain_info::coalesce_immediate): Fix wrong association
20482 of stores with groups in dump. Allow coalescing of BIT_INSERT_EXPR
20483 stores with INTEGER_CST stores.
20484 (count_multiple_uses) <BIT_INSERT_EXPR>: New case.
20485 (imm_store_chain_info::output_merged_store): Add try_bitpos variable
20486 and use it throughout. Generate bit insertion sequences if need be.
20487 (pass_store_merging::process_store): Remove redundant condition.
20488 Record stores from a SSA name to a bit-field with BIT_INSERT_EXPR.
20490 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
20492 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
20493 the 128-bit floating point types. Fix function comment.
20495 2018-06-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20497 * config/aarch64/aarch64-simd.md
20498 (aarch64_simd_vec_unpack<su>_lo_<mode>): Use UXTL and SXTL assembler
20500 (aarch64_simd_vec_unpack<su>_hi_<mode>): Use UXTL2 and SXTL2 assembler
20503 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
20505 PR tree-optimization/85989
20506 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
20508 (backprop::intersect_uses): Check it when deciding whether this
20509 is a backedge reference.
20510 (backprop::process_block): Add each phi to m_visited_phis
20511 after visiting it, then clear it at the end.
20513 2018-06-01 Richard Biener <rguenther@suse.de>
20515 * tree-vectorizer.h (vect_dr_stmt): New function.
20516 (vect_get_load_cost): Adjust.
20517 (vect_get_store_cost): Likewise.
20518 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence):
20519 Use vect_dr_stmt instead of DR_SMTT.
20520 (vect_record_base_alignments): Likewise.
20521 (vect_calculate_target_alignment): Likewise.
20522 (vect_compute_data_ref_alignment): Likewise and make static.
20523 (vect_update_misalignment_for_peel): Likewise.
20524 (vect_verify_datarefs_alignment): Likewise.
20525 (vector_alignment_reachable_p): Likewise.
20526 (vect_get_data_access_cost): Likewise. Pass down
20527 vinfo to vect_get_load_cost/vect_get_store_cost instead of DR.
20528 (vect_get_peeling_costs_all_drs): Likewise.
20529 (vect_peeling_hash_get_lowest_cost): Likewise.
20530 (vect_enhance_data_refs_alignment): Likewise.
20531 (vect_find_same_alignment_drs): Likewise.
20532 (vect_analyze_data_refs_alignment): Likewise.
20533 (vect_analyze_group_access_1): Likewise.
20534 (vect_analyze_group_access): Likewise.
20535 (vect_analyze_data_ref_access): Likewise.
20536 (vect_analyze_data_ref_accesses): Likewise.
20537 (vect_vfa_segment_size): Likewise.
20538 (vect_small_gap_p): Likewise.
20539 (vectorizable_with_step_bound_p): Likewise.
20540 (vect_prune_runtime_alias_test_list): Likewise.
20541 (vect_analyze_data_refs): Likewise.
20542 (vect_supportable_dr_alignment): Likewise.
20543 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
20544 (vect_gen_prolog_loop_niters): Likewise.
20545 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
20546 * tree-vect-patterns.c (vect_recog_bool_pattern): Do not
20548 (vect_recog_mask_conversion_pattern): Likewise.
20549 (vect_try_gather_scatter_pattern): Likewise.
20550 * tree-vect-stmts.c (vect_model_store_cost): Pass stmt_info
20551 to vect_get_store_cost.
20552 (vect_get_store_cost): Get stmt_info instead of DR.
20553 (vect_model_load_cost): Pass stmt_info to vect_get_load_cost.
20554 (vect_get_load_cost): Get stmt_info instead of DR.
20556 2018-06-01 Richard Biener <rguenther@suse.de>
20558 PR middle-end/86017
20559 * gimple-fold.c (var_decl_component_p): Also allow offsetted
20560 vars wrapped in MEM_REFs.
20562 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
20564 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
20565 Fix subreg tests so that we only return a choice between
20566 GENERAL_REGS and FP_REGS if the original classes included both.
20568 2018-06-01 Richard Biener <rguenther@suse.de>
20571 * tree-ssa-structalias.c (get_function_part_constraint):
20572 Handle NULL fi->decl.
20573 (find_func_aliases_for_call): Properly handle indirect
20574 fi from direct call.
20575 (find_func_clobbers): Likewise.
20576 (ipa_pta_execute): Likewise.
20577 (create_variable_info_for): For functions that are ifunc_resolver
20578 resolve to a varinfo that contains the result of the resolver call.
20579 (associate_varinfo_to_alias): Do not treat ifunc resolvers as
20582 2018-05-31 Michael Collison <michael.collison@arm.com>
20584 * config/aarch64/aarch64.md:
20585 (*fix_to_zero_extenddfdi2): New pattern.
20586 * gcc.target/aarch64/fix_extend1.c: New testcase.
20588 2018-05-31 Qing Zhao <qing.zhao@oracle.com>
20590 PR middle-end/78809
20591 PR middle-end/83026
20592 * builtins.c (expand_builtin): Add the handling of BUILT_IN_STRCMP_EQ
20593 and BUILT_IN_STRNCMP_EQ.
20594 * builtins.def: Add new builtins BUILT_IN_STRCMP_EQ and
20595 BUILT_IN_STRNCMP_EQ.
20596 * gimple-fold.c (gimple_fold_builtin_string_compare): Add the
20597 handling of BUILTIN_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
20598 (gimple_fold_builtin): Likewise.
20599 * tree-ssa-strlen.c (compute_string_length): New function.
20600 (determine_min_obsize): New function.
20601 (handle_builtin_string_cmp): New function to handle calls to
20602 string compare functions.
20603 (strlen_optimize_stmt): Add handling to builtin string compare
20605 * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
20606 Add the handling of BUILT_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
20607 * tree.c (build_common_builtin_nodes): Add new defines of
20608 BUILT_IN_STRNCMP_EQ and BUILT_IN_STRCMP_EQ.
20610 2018-05-31 Jakub Jelinek <jakub@redhat.com>
20613 * bb-reorder.c (pass_partition_blocks::gate): Return false for
20614 functions with naked attribute.
20616 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
20618 * config/i386/sse.md (avx_vec_concat<mode>):
20619 Substitute concat_tg_mode mode attribute with xtg_mode.
20620 (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Ditto.
20621 (concat_tg_mode): Remove mode attribute.
20623 2018-05-31 Martin Sebor <msebor@redhat.com>
20626 * calls.c (alloc_max_size): Correct a logic error/typo.
20627 Treat excessive arguments as infinite. Warn for invalid arguments.
20628 * doc/invoke.texi (-Walloc-size-larger-than): Update.
20630 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
20633 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
20634 and movx for Haswell.
20636 2018-05-31 Chung-Lin Tang <cltang@codesourcery.com>
20637 Cesar Philippidis <cesar@codesourcery.com>
20639 PR middle-end/85879
20640 * gimplify.c (gimplify_adjust_omp_clauses): Add 'remove = true'
20641 when emitting error on private/firstprivate reductions.
20642 * omp-low.c (lower_omp_target): Avoid reference-type processing
20643 on pointers for firstprivate clause.
20645 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
20647 * config/aarch64/aarch64-simd-builtins.def (ld1x3): New.
20650 * config/aarch64/aarch64-simd.md
20651 (aarch64_ld1x3<VALLDIF:mode>): New pattern.
20652 (aarch64_ld1_x3_<mode>): Likewise
20653 (aarch64_st1x2<VALLDIF:mode>): Likewise
20654 (aarch64_st1_x2_<mode>): Likewise
20655 (aarch64_st1x3<VALLDIF:mode>): Likewise
20656 (aarch64_st1_x3_<mode>): Likewise
20657 * config/aarch64/arm_neon.h (vld1_u8_x3): New function.
20658 (vld1_s8_x3): Likewise.
20659 (vld1_u16_x3): Likewise.
20660 (vld1_s16_x3): Likewise.
20661 (vld1_u32_x3): Likewise.
20662 (vld1_s32_x3): Likewise.
20663 (vld1_u64_x3): Likewise.
20664 (vld1_s64_x3): Likewise.
20665 (vld1_f16_x3): Likewise.
20666 (vld1_f32_x3): Likewise.
20667 (vld1_f64_x3): Likewise.
20668 (vld1_p8_x3): Likewise.
20669 (vld1_p16_x3): Likewise.
20670 (vld1_p64_x3): Likewise.
20671 (vld1q_u8_x3): Likewise.
20672 (vld1q_s8_x3): Likewise.
20673 (vld1q_u16_x3): Likewise.
20674 (vld1q_s16_x3): Likewise.
20675 (vld1q_u32_x3): Likewise.
20676 (vld1q_s32_x3): Likewise.
20677 (vld1q_u64_x3): Likewise.
20678 (vld1q_s64_x3): Likewise.
20679 (vld1q_f16_x3): Likewise.
20680 (vld1q_f32_x3): Likewise.
20681 (vld1q_f64_x3): Likewise.
20682 (vld1q_p8_x3): Likewise.
20683 (vld1q_p16_x3): Likewise.
20684 (vld1q_p64_x3): Likewise.
20685 (vst1_s64_x2): Likewise.
20686 (vst1_u64_x2): Likewise.
20687 (vst1_f64_x2): Likewise.
20688 (vst1_s8_x2): Likewise.
20689 (vst1_p8_x2): Likewise.
20690 (vst1_s16_x2): Likewise.
20691 (vst1_p16_x2): Likewise.
20692 (vst1_s32_x2): Likewise.
20693 (vst1_u8_x2): Likewise.
20694 (vst1_u16_x2): Likewise.
20695 (vst1_u32_x2): Likewise.
20696 (vst1_f16_x2): Likewise.
20697 (vst1_f32_x2): Likewise.
20698 (vst1_p64_x2): Likewise.
20699 (vst1q_s8_x2): Likewise.
20700 (vst1q_p8_x2): Likewise.
20701 (vst1q_s16_x2): Likewise.
20702 (vst1q_p16_x2): Likewise.
20703 (vst1q_s32_x2): Likewise.
20704 (vst1q_s64_x2): Likewise.
20705 (vst1q_u8_x2): Likewise.
20706 (vst1q_u16_x2): Likewise.
20707 (vst1q_u32_x2): Likewise.
20708 (vst1q_u64_x2): Likewise.
20709 (vst1q_f16_x2): Likewise.
20710 (vst1q_f32_x2): Likewise.
20711 (vst1q_f64_x2): Likewise.
20712 (vst1q_p64_x2): Likewise.
20713 (vst1_s64_x3): Likewise.
20714 (vst1_u64_x3): Likewise.
20715 (vst1_f64_x3): Likewise.
20716 (vst1_s8_x3): Likewise.
20717 (vst1_p8_x3): Likewise.
20718 (vst1_s16_x3): Likewise.
20719 (vst1_p16_x3): Likewise.
20720 (vst1_s32_x3): Likewise.
20721 (vst1_u8_x3): Likewise.
20722 (vst1_u16_x3): Likewise.
20723 (vst1_u32_x3): Likewise.
20724 (vst1_f16_x3): Likewise.
20725 (vst1_f32_x3): Likewise.
20726 (vst1_p64_x3): Likewise.
20727 (vst1q_s8_x3): Likewise.
20728 (vst1q_p8_x3): Likewise.
20729 (vst1q_s16_x3): Likewise.
20730 (vst1q_p16_x3): Likewise.
20731 (vst1q_s32_x3): Likewise.
20732 (vst1q_s64_x3): Likewise.
20733 (vst1q_u8_x3): Likewise.
20734 (vst1q_u16_x3): Likewise.
20735 (vst1q_u32_x3): Likewise.
20736 (vst1q_u64_x3): Likewise.
20737 (vst1q_f16_x3): Likewise.
20738 (vst1q_f32_x3): Likewise.
20739 (vst1q_f64_x3): Likewise.
20740 (vst1q_p64_x3): Likewise.
20742 2018-05-30 Jozef Lawrynowicz <jozef.l@mittosystems.com>
20744 * config/msp430/msp430.c (msp430_output_labelref): Prepend
20745 user_label_prefix to name.
20747 * tree-core.h: Update comment about the format of NAME string
20748 passed to handler in attribute_spec.
20750 * config/msp430/msp430.md: Remove erroneous subreg expression from
20751 zero_extendqisi2 insn pattern. Remove msp430x ISA restriction on
20752 zero_extend{q,h}isi2.
20754 2018-05-30 Borislav Petkov <bp@suse.de>
20756 * doc/extend.texi: Document some architecture specific
20757 constraints and sort entries.
20759 2018-05-30 Martin Sebor <msebor@redhat.com>
20761 PR middle-end/85369
20762 * builtins.c (expand_builtin_stpcpy_1): New function.
20763 (expand_builtin_stpcpy): Call it, and call maybe_warn_nonstring_arg
20764 only if the former succeeds.
20766 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
20768 * config/aarch64/aarch64-cores.def (saphira) : Add support for ARMv8.4
20771 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
20773 * doc/invoke.texi (-flinker-output): Document
20775 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
20777 * passes.c (ipa_write_summaries): Only modify statements if body
20779 * cgraphunit.c (ipa_passes): Also produce intermeidate code when
20780 incrementally linking.
20781 (ipa_passes): Likewise.
20782 * lto-cgraph.c (lto_output_node): When incrementally linking do not
20783 pass down resolution info.
20784 * common.opt (flag_incremental_link): Update info.
20785 * gcc.c (plugin specs): Turn flinker-output=* to
20786 -plugin-opt=-linker-output-known
20787 * toplev.c (compile_file): Also cut compilation when doing incremental
20789 * flag-types. (enum lto_partition_model): Add
20790 LTO_LINKER_OUTPUT_NOLTOREL.
20791 (invoke.texi): Add -flinker-output docs.
20792 * ipa.c (symbol_table::remove_unreachable_nodes): Handle LTO incremental
20793 link same way as WPA; do not stream in dead initializers.
20795 * dwarf2out.c (dwarf2out_die_ref_for_decl,
20796 darf2out_register_external_decl): Support incremental link.
20798 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
20800 * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_.
20802 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
20804 * lto-wrapper.c (debug_objcopy): Add rename parameter; pass
20805 it down to simple_object_copy_lto_debug_sections.
20806 (run_gcc): Determine incremental LTO link time and configure
20807 lto1 into non-wpa mode, disable renaming of debug sections.
20809 2018-05-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
20811 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
20812 descriptions of various incorrectly documented functions.
20814 2018-05-30 Andre Vieira <andre.simoesdiasvieira@arm.com>
20817 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
20818 address check not strict.
20820 2018-05-30 Richard Biener <rguenther@suse.de>
20822 PR tree-optimization/85964
20823 * tracer.c (better_p): Drop initialized count check, we only
20824 call the function with initialized counts now.
20825 (find_best_successor): Do find a best edge if one
20826 has uninitialized count.
20827 (find_best_predecessor): Likewise. Do BB frequency check only
20828 if count is initialized.
20830 2017-05-30 Jackson Woodruff <jackson.woodruff@arm.com>
20832 * config/aarch64/aarch64.c (aarch64_host_wide_int_compare): New.
20833 (aarch64_ldrstr_offset_compare): New.
20834 (aarch64_operands_adjust_ok_for_ldpstp): Update to consider all
20835 load/store orderings.
20836 (aarch64_gen_adjusted_ldpstp): Likewise.
20838 2018-05-30 Wilco Dijkstra <wdijkstr@arm.com>
20840 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
20841 Check for subset of GENERAL_REGS and FP_REGS.
20842 * config/aarch64/aarch64-simd.md (aarch64_get_lane): Increase cost of
20845 2018-05-30 Richard Sandiford <richard.sandiford@linaro.org>
20847 * alias.c (adjust_offset_for_component_ref): Use poly_int_tree_p
20848 and wi::to_poly_offset. Add the current offset and then check
20849 whether the sum fits, rather than using an unchecked addition of
20850 a checked term. Check for a shwi rather than a uhwi.
20851 * expr.c (get_bit_range): Use tree_to_poly_uint64.
20852 (store_constructor): Use poly_int_tree_p.
20853 (expand_expr_real_1): Likewise.
20854 * function.c (assign_temp): Likewise.
20855 * fold-const.c (const_binop): Use poly_int_tree_p and
20856 wi::to_poly_offset.
20857 (fold_indirect_ref_1): Likewise. Use multiple_p to attempt an exact
20859 * ipa-icf-gimple.c (func_checker::compare_operand): Use
20860 to_poly_offset for MEM offsets.
20861 * ipa-icf.c (sem_variable::equals): Likewise.
20862 * stor-layout.c (compute_record_mode): Use poly_int_tree_p.
20863 * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Use
20864 wi::to_poly_offset for BIT_FIELD_REF offsets.
20865 (vn_reference_maybe_forwprop_address): Use poly_int_tree_p and
20866 wi::to_poly_offset.
20867 * var-tracking.c (emit_note_insn_var_location): Use
20868 tree_to_poly_uint64.
20870 2018-05-29 Jim Wilson <jimw@sifive.com>
20872 * config/riscv/riscv.c (riscv_interrupt_type): Fix comment typo.
20874 2018-05-29 Uros Bizjak <ubizjak@gmail.com>
20877 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
20878 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
20880 (sse4_1_round<mode>2): Use nonimmediate_operand
20881 for operand 1 predicate.
20883 2018-05-29 Martin Sebor <msebor@redhat.com>
20884 Richard Biener <rguenther@suse.de>
20887 * calls.c (get_size_range): Call determine_value_range instead
20888 of get_value_range..
20889 * tree-vrp.h (determine_value_range): Declared new function.
20890 * tree-vrp.c (determine_value_range_1, determine_value_range): New.
20892 2018-05-29 Richard Biener <rguenther@suse.de>
20894 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Make
20895 sure to use non-pattern stmts for get_earlier_stmt arguments.
20896 * tree-vectorizer.h (get_earlier_stmt): Assert we do not get
20897 called on pattern stmts.
20898 (get_later_stmt): Likewise.
20900 2018-05-29 Martin Liska <mliska@suse.cz>
20902 PR gcov-profile/85759
20903 * doc/gcov.texi: Document GCOV_ERROR_FILE and GCOV_EXIT_AT_ERROR
20906 2018-05-29 Jakub Jelinek <jakub@redhat.com>
20908 * tree-cfg.c (verify_gimple_assign_unary): Add checking for
20910 (verify_gimple_assign_binary): Check TYPE_VECTOR_SUBPARTS for
20914 * tree.def (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
20915 VEC_PACK_FLOAT_EXPR): New tree codes.
20916 * tree-pretty-print.c (op_code_prio): Handle
20917 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR.
20918 (dump_generic_node): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
20919 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
20920 * tree-inline.c (estimate_operator_cost): Likewise.
20921 * gimple-pretty-print.c (dump_binary_rhs): Handle VEC_PACK_FLOAT_EXPR.
20922 * fold-const.c (const_binop): Likewise.
20923 (const_unop): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR and
20924 VEC_UNPACK_FIX_TRUNC_LO_EXPR.
20925 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
20926 (verify_gimple_assign_binary): Handle VEC_PACK_FLOAT_EXPR.
20927 * cfgexpand.c (expand_debug_expr): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
20928 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
20929 * expr.c (expand_expr_real_2): Likewise.
20930 * optabs.def (vec_packs_float_optab, vec_packu_float_optab,
20931 vec_unpack_sfix_trunc_hi_optab, vec_unpack_sfix_trunc_lo_optab,
20932 vec_unpack_ufix_trunc_hi_optab, vec_unpack_ufix_trunc_lo_optab): New
20934 * optabs.c (expand_widen_pattern_expr): For
20935 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR use
20936 sign from result type rather than operand's type.
20937 (expand_binop_directly): For vec_packu_float_optab and
20938 vec_packs_float_optab allow result type to be different from operand's
20940 * optabs-tree.c (optab_for_tree_code): Handle
20941 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
20942 VEC_PACK_FLOAT_EXPR. Formatting fixes.
20943 * tree-vect-generic.c (expand_vector_operations_1): Handle
20944 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
20945 VEC_PACK_FLOAT_EXPR.
20946 * tree-vect-stmts.c (supportable_widening_operation): Handle
20948 (supportable_narrowing_operation): Handle FLOAT_EXPR.
20949 * config/i386/i386.md (fixprefix, floatprefix): New code attributes.
20950 * config/i386/sse.md (*float<floatunssuffix>v2div2sf2): Rename to ...
20951 (float<floatunssuffix>v2div2sf2): ... this. Formatting fix.
20952 (vpckfloat_concat_mode, vpckfloat_temp_mode, vpckfloat_op_mode): New
20954 (vec_pack<floatprefix>_float_<mode>): New expander.
20955 (vunpckfixt_mode, vunpckfixt_model, vunpckfixt_extract_mode): New mode
20957 (vec_unpack_<fixprefix>fix_trunc_lo_<mode>,
20958 vec_unpack_<fixprefix>fix_trunc_hi_<mode>): New expanders.
20959 * doc/md.texi (vec_packs_float_@var{m}, vec_packu_float_@var{m},
20960 vec_unpack_sfix_trunc_hi_@var{m}, vec_unpack_sfix_trunc_lo_@var{m},
20961 vec_unpack_ufix_trunc_hi_@var{m}, vec_unpack_ufix_trunc_lo_@var{m}):
20963 * doc/generic.texi (VEC_UNPACK_FLOAT_HI_EXPR,
20964 VEC_UNPACK_FLOAT_LO_EXPR): Fix pasto in description.
20965 (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
20966 VEC_PACK_FLOAT_EXPR): Document.
20968 2018-05-29 Richard Biener <rguenther@suse.de>
20970 * tree-vectorizer.h (struct vec_info): Add stmt_vec_infos
20972 (stmt_vec_info_vec): Make pointer.
20973 (init_stmt_vec_info_vec): Remove.
20974 (free_stmt_vec_info_vec): Likewise.
20975 (set_stmt_vec_info_vec): New function.
20976 (free_stmt_vec_infos): Likewise.
20977 (vinfo_for_stmt): Adjust for stmt_vec_info_vec indirection.
20978 (set_vinfo_for_stmt): Likewise.
20979 (get_earlier_stmt): Likewise.
20980 (get_later_stmt): Likewise.
20981 * tree-vectorizer.c (stmt_vec_info_vec): Make pointer.
20982 (vec_info::vec_info): Allocate stmt_vec_infos and set the global.
20983 (vec_info::~vec_info): Free stmt_vec_infos.
20984 (vectorize_loops): Set the global stmt_vec_info_vec to NULL.
20985 Remove old init_stmt_vec_info_vec/free_stmt_vec_info_vec calls.
20986 (pass_slp_vectorize::execute): Likewise.
20987 * tree-vect-stmts.c (init_stmt_vec_info_vec): Remove.
20988 (free_stmt_vec_info_vec): Likewise.
20989 (set_stmt_vec_info_vec): New function.
20990 (free_stmt_vec_infos): Likewise.
20991 * tree-vect-loop.c (_loop_vec_info::~_loop_vec_info): Set
20992 the global stmt_vec_info_vec.
20993 * tree-parloops.c (gather_scalar_reductions): Use
20994 set_stmt_vec_info_vec/free_stmt_vec_infos and maintain a local
20997 2018-05-29 Richard Biener <rguenther@suse.de>
20999 * dominance.c (iterate_fix_dominators): Push/pop TV_DOMINANCE.
21001 2018-05-29 Martin Liska <mliska@suse.cz>
21002 David Malcolm <dmalcolm@redhat.com>
21004 * vec.c (test_reverse): New.
21005 (vec_c_tests): Add new test.
21006 * vec.h (vl_ptr>::reverse): New function.
21008 2018-05-29 Gerald Pfeifer <gerald@pfeifer.com>
21010 * config.gcc: Identify FreeBSD 3.x and 4.x as unsupported.
21012 * config/freebsd-spec.h (FBSD_LIB_SPEC): Only consider FreeBSD 5
21015 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
21017 * tree-dump.c (dump_node): Use splay_tree_delete_pointers.
21019 2018-05-28 Richard Biener <rguenther@suse.de>
21021 PR tree-optimization/85933
21022 * tree-vect-data-refs.c (vect_record_base_alignments): Only
21023 look at stmts marked as vectorizable.
21025 2018-05-28 Richard Biener <rguenther@suse.de>
21027 PR tree-optimization/85934
21028 * tree-vect-generic.c (expand_vector_operations_1): Hoist
21029 vector boolean check before scalar optimization.
21031 2018-05-28 Jakub Jelinek <jakub@redhat.com>
21033 * doc/invoke.texi (ARM Options): Use @item instead of @itemx
21036 2018-05-28 Mark Wielaard <mark@klomp.org>
21038 * dwarf2asm.c (dw2_asm_output_delta_uleb128): Add brackets around lab2
21039 if it is an expression containing a minus sign.
21041 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
21043 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
21045 2018-05-27 Paul Koning <ni1d@arrl.net>
21047 * config/pdp11/pdp11.md (truncsihi2): Remove.
21049 2018-05-27 Monk Chiang <sh.chiang04@gmail.com>
21050 Chung-Ju Wu <jasonwucj@gmail.com>
21052 * config/nds32/nds32-intrinsic.md (unaligned_storedi): Modify patterns
21054 (unaligned_store_dw): Ditto.
21055 * config/nds32/nds32-memory-manipulation.c
21056 (nds32_expand_movmemsi_loop_known_size): Refactoring implementation.
21057 (nds32_gen_dup_4_byte_to_word_value): Rename to ...
21058 (nds32_gen_dup_4_byte_to_word_value_aux): ... this.
21059 (emit_setmem_word_loop): Rename to ...
21060 (emit_setmem_doubleword_loop): ... this.
21061 (nds32_gen_dup_4_byte_to_word_value): New function.
21062 (nds32_gen_dup_8_byte_to_double_word_value): New function.
21063 (nds32_expand_setmem_loop): Refine implementation.
21064 (nds32_expand_setmem_loop_v3m): Ditto.
21065 * config/nds32/nds32-multiple.md (unaligned_store_update_base_dw): New
21068 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
21070 * config/nds32/nds32.md (bswapsi2, bswaphi2): New patterns.
21072 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
21074 * config/nds32/nds32.c (nds32_attribute_table): Add "no_prologue".
21075 (nds32_init_machine_status): Initialize machine->attr_naked_p and
21076 machine->attr_no_prologue_p.
21077 (nds32_compute_stack_frame): Check "naked" and "no_prologue" attributes.
21078 (nds32_naked_function_p): Handle "naked" and "no_prologue" attributes.
21079 (nds32_expand_epilogue): Consider attr_naked_p.
21080 (nds32_expand_epilogue_v3pop): Likewise.
21081 (nds32_can_use_return_insn): Likewise.
21082 * config/nds32/nds32.h (machine_function): Add attr_naked_p and
21083 attr_no_prologue_p fields.
21084 * config/nds32/nds32.opt (mret-in-naked-func): New option.
21086 2018-05-27 Jakub Jelinek <jakub@redhat.com>
21089 * config/i386/i386.md (fixunssuffix, floatunssuffix): New code
21091 * config/i386/sse.md
21092 (<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>):
21094 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
21096 (<floatsuffix>float<sselongvecmodelower><mode>2<mask_name><round_name>):
21098 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
21100 (*<floatsuffix>floatv2div2sf2): Rename to ...
21101 (*float<floatunssuffix>v2div2sf2): ... this.
21102 (<floatsuffix>floatv2div2sf2_mask): Rename to ...
21103 (float<floatunssuffix>v2div2sf2_mask): ... this.
21104 (*<floatsuffix>floatv2div2sf2_mask_1): Rename to ...
21105 (*float<floatunssuffix>v2div2sf2_mask_1): ... this.
21106 (<fixsuffix>fix_truncv8dfv8si2<mask_name><round_saeonly_name>): Rename
21108 (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
21110 (<fixsuffix>fix_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
21112 (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
21114 (<fixsuffix>fix_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
21116 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
21118 (<fixsuffix>fix_truncv2sfv2di2<mask_name>): Rename to ...
21119 (fix<fixunssuffix>_truncv2sfv2di2<mask_name>): ... this.
21120 (vec_pack_ufix_trunc_<mode>): Use gen_fixuns_truncv8dfv8si2 instead of
21121 gen_ufix_truncv8dfv8si2.
21122 * config/i386/i386-builtin.def (__builtin_ia32_cvttpd2uqq256_mask,
21123 __builtin_ia32_cvttpd2uqq128_mask, __builtin_ia32_cvttps2uqq256_mask,
21124 __builtin_ia32_cvttps2uqq128_mask, __builtin_ia32_cvtuqq2ps256_mask,
21125 __builtin_ia32_cvtuqq2ps128_mask, __builtin_ia32_cvtuqq2pd256_mask,
21126 __builtin_ia32_cvtuqq2pd128_mask, __builtin_ia32_cvttpd2udq512_mask,
21127 __builtin_ia32_cvtuqq2ps512_mask, __builtin_ia32_cvtuqq2pd512_mask,
21128 __builtin_ia32_cvttps2uqq512_mask, __builtin_ia32_cvttpd2uqq512_mask):
21129 Use fixuns instead ufix or floatuns instead ufloat in CODE_FOR_ names.
21131 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
21135 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
21137 2018-05-25 Jim Wilson <jimw@sifive.com>
21139 * config/riscv/riscv-protos.h (riscv_epilogue_uses): New.
21140 * config/riscv/riscv.c (struct machine_function): Add
21141 interrupt_handler_p and attribute_checked_p fields.
21142 (riscv_attribute_table): Add interrupt.
21143 (riscv_interrupt_type_p): New.
21144 (riscv_save_reg_p): Save extra regs for interrupt handler.
21145 (riscv_use_save_libcall): Return false for interrupt handler.
21146 (riscv_first_stack_step): Add forward declaration.
21147 (riscv_compute_frame_info): New local interrupt_save_t1. Set it
21148 for interrupt handler with large frame. Use it for saved reg list.
21149 (riscv_expand_prologue): Move flag_stack_usage_info support to
21150 eliminate duplication.
21151 (riscv_expand_epilogue): Generate mret for interrupt handler.
21152 (riscv_epilogue_uses): New.
21153 (riscv_can_use_return_insn): Return false for interrupt handler.
21154 (riscv_function_ok_for_sibcall): Likewise.
21155 (riscv_set_current_function): Add interrupt handler support.
21156 * config/riscv/riscv.h (EPILOGUE_USES): Call riscv_epilogue_uses.
21157 * config/riscv/riscv.md (UNSPECV_MRET): New.
21159 (riscv_frflags, riscv_fsflags): Use tab after opcode.
21161 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: New.
21163 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
21165 PR tree-optimization/85712
21166 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
21167 this candidate has already been replaced in-situ by a copy.
21169 2018-05-25 Jason Merrill <jason@redhat.com>
21171 PR c++/80485 - inline function non-zero address.
21172 * symtab.c (nonzero_address): Check DECL_COMDAT.
21174 2018-05-25 Uros Bizjak <ubizjak@gmail.com>
21177 * config/alpha/alpha.md (ashlsi3): New insn pattern.
21178 (*ashlsi_se): Rename from *ashldi_se. Define as sign
21179 extension of SImode operation. Use const123_operand predicate.
21180 (*saddsi_1): Remove.
21181 (*saddl_se_1): Ditto.
21182 (*ssubsi_1): Ditto.
21183 (*ssubl_se_1): Ditto.
21184 * config/alpha/predicates.md (const123_operand): New predicate.
21185 * config/alpha/constraints.md (P): Use IN_RANGE.
21187 2018-05-25 Richard Biener <rguenther@suse.de>
21189 * tree-ssa-alias.h (refs_may_alias_p): Add tbaa_p bool parameter,
21191 (ref_maybe_used_by_stmt_p): Likewise.
21192 (stmt_may_clobber_ref_p): Likewise.
21193 (stmt_may_clobber_ref_p_1): Likewise.
21194 * tree-ssa-alias.c (refs_may_alias_p): Add tbaa_p bool parameter
21196 (ref_maybe_used_by_stmt_p): Likewise.
21197 (stmt_may_clobber_ref_p): Likewise.
21198 (stmt_may_clobber_ref_p_1): Likewise.
21199 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Use
21200 the alias oracle to disambiguate DRs with stmts DR analysis
21202 (vect_analyze_data_refs): Do not give up on not analyzable
21203 DRs for BB vectorization. Remove code truncating the dataref
21206 2018-05-25 Jakub Jelinek <jakub@redhat.com>
21209 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
21210 Add (=Yk,v,C) variant using vptestm insn. Use TARGET_AVX512BW
21211 in test instead of TARGET_AVX512F for VI12_AVX512VL iterator.
21213 2018-05-25 Richard Biener <rguenther@suse.de>
21215 * tree-vect-data-refs.c (vect_find_stmt_data_reference): New
21216 function, combining stmt data ref gathering and fatal analysis
21218 (vect_analyze_data_refs): Remove now redudnant code and simplify.
21219 * tree-vect-loop.c (vect_get_datarefs_in_loop): Factor out from
21220 vect_analyze_loop_2 and use vect_find_stmt_data_reference.
21221 * tree-vect-slp.c (vect_slp_bb): Use vect_find_stmt_data_reference.
21222 * tree-vectorizer.h (vect_find_stmt_data_reference): Declare.
21224 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21226 PR tree-optimization/85720
21227 * tree-loop-distribution.c (break_alias_scc_partitions): Don't merge
21228 SCC if all partitions are builtins.
21229 (version_loop_by_alias_check): New parameter. Generate cancelable
21230 runtime alias check if all partitions are builtins.
21231 (distribute_loop): Update call to above function.
21233 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21235 * tree-outof-ssa.c (tree-ssa.h, tree-dfa.h): Include header files.
21236 (create_default_def, for_all_parms): Moved from tree-ssa-coalesce.c.
21237 (parm_default_def_partition_arg): Ditto.
21238 (set_parm_default_def_partition): Ditto.
21239 (get_parm_default_def_partitions): Ditto and make it static.
21240 (get_undefined_value_partitions): Ditto and make it static.
21241 (remove_ssa_form): Refactor call to init_var_map here.
21242 * tree-ssa-coalesce.c (build_ssa_conflict_graph): Support live range
21243 computation for loop region.
21244 (coalesce_partitions, compute_optimized_partition_bases): Ditto.
21245 (register_default_def): Delete.
21246 (for_all_parms, create_default_def): Move to tree-outof-ssa.c.
21247 (parm_default_def_partition_arg): Ditto.
21248 (set_parm_default_def_partition): Ditto.
21249 (get_parm_default_def_partitions): Ditto and make it static.
21250 (get_undefined_value_partitions): Ditto and make it static.
21251 (coalesce_with_default, coalesce_with_default): Update comment.
21252 (create_coalesce_list_for_region): New func factored out from
21253 create_outofssa_var_map.
21254 (populate_coalesce_list_for_outofssa): New func factored out from
21255 create_outofssa_var_map and coalesce_ssa_name.
21256 (create_outofssa_var_map): Delete.
21257 (coalesce_ssa_name): Refactor to support live range computation.
21258 * tree-ssa-coalesce.h (coalesce_ssa_name): Change decl.
21259 (get_parm_default_def_partitions): Delete.
21260 (get_undefined_value_partitions): Ditto.
21261 * tree-ssa-live.c (init_var_map, delete_var_map): Support live range
21262 computation for loop region.
21263 (new_tree_live_info, loe_visit_block): Ditto.
21264 (live_worklist, set_var_live_on_entry): Ditto.
21265 (calculate_live_on_exit, verify_live_on_entry): Ditto.
21266 * tree-ssa-live.h (struct _var_map): New fields.
21267 (init_var_map): Change decl.
21268 (region_contains_p): New.
21270 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21272 * tree-ssa-live.h (live_merge_and_clear): Delete.
21274 2018-05-25 Richard Biener <rguenther@suse.de>
21277 * tree-dump.c (dequeue_and_dump): Remove access to removed
21278 operand 2 of a SWITCH_EXPR.
21280 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21282 * doc/sourcebuild.texi (vect_double_cond_arith): Include
21283 multiplication and division.
21284 * doc/md.texi (cond_mul@var{m}, cond_div@var{m}, cond_mod@var{m})
21285 (cond_udiv@var{m}, cond_umod@var{m}): Document.
21286 * optabs.def (cond_smul_optab, cond_sdiv_optab, cond_smod_optab)
21287 (cond_udiv_optab, cond_umod_optab): New optabs.
21288 * internal-fn.def (IFN_COND_MUL, IFN_COND_DIV, IFN_COND_MOD)
21289 (IFN_COND_RDIV): New internal functions.
21290 * internal-fn.c (get_conditional_internal_fn): Handle TRUNC_DIV_EXPR,
21291 TRUNC_MOD_EXPR and RDIV_EXPR.
21292 * match.pd (UNCOND_BINARY, COND_BINARY): Handle them.
21293 * config/aarch64/iterators.md (UNSPEC_COND_MUL, UNSPEC_COND_DIV):
21295 (SVE_INT_BINARY): Include mult.
21296 (SVE_COND_FP_BINARY): Include UNSPEC_MUL and UNSPEC_DIV.
21297 (optab, sve_int_op): Handle mult.
21298 (optab, sve_fp_op, commutative): Handle UNSPEC_COND_MUL and
21300 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New pattern
21301 for SVE_INT_BINARY_SD.
21303 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21305 * config/aarch64/iterators.md (SVE_INT_BINARY_SD): New code iterator.
21306 (optab, sve_int_op): Handle div and udiv.
21307 * config/aarch64/aarch64-sve.md (<optab><mode>3): New expander
21308 for SVE_INT_BINARY_SD.
21309 (*<optab><mode>3): New insn for the same.
21311 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21313 * tree-vect-patterns.c: Include predict.h.
21314 (vect_recog_divmod_pattern): Restrict check for division support
21315 to when optimizing for size.
21317 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21319 * doc/sourcebuild.texi (vect_double_cond_arith: Document.
21320 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 4.
21321 (gimple_match_op::gimple_match_op): Add an overload for 4 operands.
21322 (gimple_match_op::set_op): Likewise.
21323 (gimple_resimplify4): Declare.
21324 * genmatch.c (get_operand_type): Handle CFN_COND_* functions.
21325 (expr::gen_transform): Likewise.
21326 (decision_tree::gen): Generate a simplification routine for 4 operands.
21327 * gimple-match-head.c (gimple_simplify): Add an overload for
21328 4 operands. In the top-level function, handle up to 4 call
21329 arguments and call gimple_resimplify4.
21330 (gimple_resimplify4): New function.
21331 (build_call_internal): Pass a fourth operand.
21332 (maybe_push_to_seq): Likewise.
21333 * match.pd (UNCOND_BINARY, COND_BINARY): New operator lists.
21334 Fold VEC_COND_EXPRs of an operation and a default value into
21335 an IFN_COND_* function if possible.
21336 * config/aarch64/iterators.md (UNSPEC_COND_MAX, UNSPEC_COND_MIN):
21338 (SVE_COND_FP_BINARY): Include them.
21339 (optab, sve_fp_op): Handle them.
21340 (SVE_INT_BINARY_REV): New code iterator.
21341 (SVE_COND_FP_BINARY_REV): New int iterator.
21342 (commutative): New int attribute.
21343 * config/aarch64/aarch64-protos.h (aarch64_sve_prepare_conditional_op):
21345 * config/aarch64/aarch64.c (aarch64_sve_prepare_conditional_op): New
21347 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Use it.
21348 (*cond_<optab><mode>): New patterns for reversed operands.
21350 2018-05-25 Richard Biener <rguenther@suse.de>
21352 * tree-vectorizer.h (STMT_VINFO_GROUP_*, GROUP_*): Remove.
21353 (DR_GROUP_*): New, assert we have non-NULL ->data_ref_info.
21354 (REDUC_GROUP_*): New, assert we have NULL ->data_ref_info.
21355 (STMT_VINFO_GROUPED_ACCESS): Adjust.
21356 * tree-vect-data-refs.c (everywhere): Adjust users.
21357 * tree-vect-loop.c (everywhere): Likewise.
21358 * tree-vect-slp.c (everywhere): Likewise.
21359 * tree-vect-stmts.c (everywhere): Likewise.
21360 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
21362 2018-05-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
21364 * configure.ac (gcc_cv_as_section_has_e): Move to common section.
21366 (gcc_cv_as_section_exclude): ... this.
21367 Try Solaris as #exclude syntax.
21368 * configure: Regenerate.
21369 * config.in: Regenerate.
21370 * config/i386/i386.c (i386_solaris_elf_named_section): Handle
21372 * config/sparc/sparc.c (sparc_solaris_elf_asm_named_section)
21373 [HAVE_GAS_SECTION_EXCLUDE]: Handle SECTION_EXCLUDE.
21375 * varasm.c (default_elf_asm_named_section): Don't check if
21376 HAVE_GAS_SECTION_EXCLUDE is defined.
21378 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21380 * doc/md.texi: Update the documentation of the cond_* optabs
21381 to mention the new final operand. Fix GET_MODE_NUNITS call.
21382 Describe the scalar case too.
21383 * internal-fn.def (IFN_EXTRACT_LAST): Change type to fold_left.
21384 * internal-fn.c (expand_cond_unary_optab_fn): Expect 3 operands
21386 (expand_cond_binary_optab_fn): Expect 4 operands instead of 3.
21387 (get_conditional_internal_fn): Update comment.
21388 * tree-vect-loop.c (vectorizable_reduction): Pass the original
21389 accumulator value as a final argument to conditional functions.
21390 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Turn into
21391 a define_expand and add an "else" operand. Assert for now that
21392 the else operand is equal to operand 2. Use SVE_INT_BINARY and
21393 SVE_COND_FP_BINARY instead of SVE_COND_INT_OP and SVE_COND_FP_OP.
21394 (*cond_<optab><mode>): New patterns.
21395 * config/aarch64/iterators.md (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX)
21396 (UNSPEC_COND_SMIN, UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
21397 (UNSPEC_COND_EOR): Delete.
21398 (optab): Remove associated mappings.
21399 (SVE_INT_BINARY): New code iterator.
21400 (sve_int_op): Remove int attribute and add "minus" to the code
21402 (SVE_COND_INT_OP): Delete.
21403 (SVE_COND_FP_OP): Rename to...
21404 (SVE_COND_FP_BINARY): ...this.
21406 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21408 * optabs.c (can_reuse_operands_p): New function.
21409 (maybe_legitimize_operands): Try to reuse the results for
21412 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
21414 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
21415 Add {q} suffix to insn mnemonic.
21417 2018-05-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
21419 * config/msp430/msp430.c (TARGET_WARN_FUNC_RETURN): Define.
21420 (msp430_warn_func_return): New.
21422 2018-05-24 Roger Sayle <roger@nextmovesoftware.com>
21424 * fold-const.c (tree_nonzero_bits): New function.
21425 * fold-const.h (tree_nonzero_bits): Likewise.
21426 * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
21427 friends. POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.
21429 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
21433 * varasm.c (assemble_alias): Check ifunc_resolver only on
21436 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
21439 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
21440 when memory input operand is handled.
21442 2018-05-24 Luis Machado <luis.machado@linaro.org>
21444 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
21446 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
21448 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
21450 * match.pd: Delay FMA folds until after vectorization.
21452 2018-05-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
21455 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
21456 address check not strict.
21458 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
21460 * gimple-match.h (gimple_match_op): New class.
21461 (mprts_hook): Replace parameters with a gimple_match_op *.
21462 (maybe_build_generic_op): Likewise.
21463 (gimple_simplified_result_is_gimple_val): Replace parameters with
21464 a const gimple_match_op *.
21465 (gimple_simplify): Replace code_helper * and tree * parameters with
21466 a gimple_match_op * parameter.
21467 (gimple_resimplify1): Replace code_helper *, tree and tree *
21468 parameters with a gimple_match_op * parameter.
21469 (gimple_resimplify2): Likewise.
21470 (gimple_resimplify3): Likewise.
21471 (maybe_push_res_to_seq): Replace code_helper, tree and tree *
21472 parameters with a gimple_match_op * parameter.
21473 * gimple-match-head.c (gimple_simplify): Change prototypes of
21474 auto-generated functions to take a gimple_match_op * instead of
21475 separate code_helper * and tree * parameters. Make the same
21476 change in the top-level overload and update calls to the
21477 gimple_resimplify routines. Update calls to the auto-generated
21478 functions and to maybe_push_res_to_seq in the publicly-facing
21479 operation-specific gimple_simplify overloads.
21480 (gimple_match_op::MAX_NUM_OPS): Define.
21481 (gimple_resimplify1): Replace rcode and ops with a single res_op
21482 parameter. Update call to gimple_simplify.
21483 (gimple_resimplify2): Likewise.
21484 (gimple_resimplify3): Likewise.
21485 (mprts_hook): Replace parameters with a gimple_match_op *.
21486 (maybe_build_generic_op): Likewise.
21487 (build_call_internal): Replace type, nargs and ops with
21488 a gimple_match_op *.
21489 (maybe_push_res_to_seq): Replace res_code, type and ops parameters
21490 with a single gimple_match_op *. Update calls to mprts_hook,
21491 build_call_internal and gimple_simplified_result_is_gimple_val.
21492 Factor out code that is common to the tree_code and combined_fn cases.
21493 * genmatch.c (expr::gen_transform): Replace tem_code and
21494 tem_ops with a gimple_match_op called tem_op. Update calls
21495 to the gimple_resimplify functions and maybe_push_res_to_seq.
21496 (dt_simplify::gen_1): Manipulate res_op instead of res_code and
21497 res_ops. Update call to the gimple_resimplify functions.
21498 (dt_simplify::gen): Pass res_op instead of res_code and res_ops.
21499 (decision_tree::gen): Make the functions take a gimple_match_op *
21500 called res_op instead of separate res_code and res_ops parameters.
21501 Update call accordingly.
21502 * gimple-fold.c (replace_stmt_with_simplification): Replace rcode
21503 and ops with a single res_op parameter. Update calls to
21504 maybe_build_generic_op and maybe_push_res_to_seq.
21505 (fold_stmt_1): Update calls to gimple_simplify and
21506 replace_stmt_with_simplification.
21507 (gimple_fold_stmt_to_constant_1): Update calls to gimple_simplify
21508 and gimple_simplified_result_is_gimple_val.
21509 * tree-cfgcleanup.c (cleanup_control_expr_graph): Update call to
21511 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Replace parameters
21512 with a gimple_match_op *.
21513 (vn_nary_build_or_lookup): Likewise. Update call to
21514 vn_nary_build_or_lookup_1.
21515 (vn_nary_build_or_lookup_1): Replace rcode, type and ops with a
21516 gimple_match_op *. Update calls to the gimple_resimplify routines
21517 and to gimple_simplified_result_is_gimple_val.
21518 (vn_nary_simplify): Update call to vn_nary_build_or_lookup_1.
21519 Use gimple_match_op::MAX_NUM_OPS instead of a hard-coded 3.
21520 (vn_reference_lookup_3): Update call to vn_nary_build_or_lookup.
21521 (visit_nary_op): Likewise.
21522 (visit_reference_op_load): Likewise.
21524 2018-05-23 Luis Machado <luis.machado@linaro.org>
21526 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Use correct type
21527 modifier for printing the step amount.
21529 2018-05-23 Jozef Lawrynowicz <jozef.l@somniumtech.com>
21532 * tree.c (build_common_tree_nodes): Dont set TYPE_SIZE for __intN
21535 2018-05-23 Segher Boessenkool <segher@kernel.crashing.org>
21537 * doc/sourcebuild.texi (Endianness): New subsubsection.
21539 2018-05-23 Luis Machado <luis.machado@linaro.org>
21541 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
21542 <prefetch_dynamic_strides>: New const bool field.
21543 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
21544 prefetch_dynamic_strides.
21545 (exynosm1_prefetch_tune): Likewise.
21546 (thunderxt88_prefetch_tune): Likewise.
21547 (thunderx_prefetch_tune): Likewise.
21548 (thunderx2t99_prefetch_tune): Likewise.
21549 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides to
21551 (aarch64_override_options_internal): Update to set
21552 PARAM_PREFETCH_DYNAMIC_STRIDES.
21553 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
21554 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
21555 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
21556 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
21557 prefetch-dynamic-strides setting.
21559 2018-05-23 Luis Machado <luis.machado@linaro.org>
21561 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
21562 <minimum_stride>: New const int field.
21563 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
21564 minimum_stride field defaulting to -1.
21565 (exynosm1_prefetch_tune): Likewise.
21566 (thunderxt88_prefetch_tune): Likewise.
21567 (thunderx_prefetch_tune): Likewise.
21568 (thunderx2t99_prefetch_tune): Likewise.
21569 (qdf24xx_prefetch_tune) <minimum_stride>: Set to 2048.
21570 <default_opt_level>: Set to 3.
21571 (aarch64_override_options_internal): Update to set
21572 PARAM_PREFETCH_MINIMUM_STRIDE.
21573 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
21574 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
21575 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
21576 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
21577 stride is constant and is below the minimum stride threshold.
21579 2018-05-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21581 * config/arm/arm-cpus.in (mode26): Delete.
21582 (armv4): Delete mode26 reference.
21583 * config/arm/arm.c (arm_configure_build_target): Delete use of
21586 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
21588 * config/i386/i386.md (*floatuns<SWI48:mode><MODEF:mode>2_avx512):
21590 (floatunssi<mode>2): Also enable for AVX512F and TARGET_SSE_MATH.
21591 Rewrite expander pattern. Emit gen_floatunssi<mode>2_i387_with_xmm
21593 (floatunsdisf2): Rewrite expander pattern. Hanlde TARGET_AVX512F.
21594 (floatunsdidf2): Ditto.
21596 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
21598 * config/i386/i386.md (fixuns_trunc<mode>di2): New insn pattern.
21599 (fixuns_trunc<mode>si2_avx512f): Ditto.
21600 (*fixuns_trunc<mode>si2_avx512f_zext): Ditto.
21601 (fixuns_trunc<mode>si2): Also enable for AVX512F and TARGET_SSE_MATH.
21602 Emit fixuns_trunc<mode>si2_avx512f for AVX512F targets.
21604 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
21606 PR rtl-optimization/79985
21607 * df-scan.c (df_insn_refs_collect): Remove special case for
21608 global registers and asm statements.
21610 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
21612 * extend.texi (Global Register Variables): Rewrite the bullet list.
21613 Note that the register is available for allocation. Note that access
21614 via inline asm must use constraints. Add note about async-signal
21615 handlers. Remove paragraph about automagic register selection.
21617 2018-05-23 Richard Biener <rguenther@suse.de>
21619 * tree-ssa-sccvn.c (vn_reference_lookup_3): Remove restriction
21620 of fixed offset from memset VN.
21622 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
21624 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
21625 first_interp field.
21626 (alloc_cand_and_find_basis): Initialize first_interp field.
21627 (slsr_process_mul): Modify first_interp field.
21628 (slsr_process_add): Likewise.
21629 (slsr_process_cast): Modify first_interp field for each new
21631 (slsr_process_copy): Likewise.
21632 (dump_candidate): Dump first_interp field.
21633 (replace_mult_candidate): Process all interpretations, not just
21635 (replace_rhs_if_not_dup): Likewise.
21636 (replace_one_candidate): Likewise.
21638 2018-05-23 Wilco Dijkstra <wdijkstr@arm.com>
21640 * config/aarch64/aarch64.c (aarch64_use_frame_pointer):
21642 (aarch64_needs_frame_chain): New function.
21643 (aarch64_parse_override_string): Set aarch64_use_frame_pointer.
21645 2018-05-23 Sudakshina Das <sudi.das@arm.com>
21648 * common/config/aarch64/aarch64-common.c (aarch64_handle_option):
21649 Check val before adding MASK_STRICT_ALIGN to opts->x_target_flags.
21650 * config/aarch64/aarch64.opt (mstrict-align): Remove RejectNegative.
21651 * config/aarch64/aarch64.c (aarch64_attributes): Mark allow_neg
21652 as true for strict-align.
21653 (aarch64_can_inline_p): Perform checks even when callee has no
21654 attributes to check for strict alignment.
21655 * doc/extend.texi (AArch64 Function Attributes): Document
21657 * doc/invoke.texi: (AArch64 Options): Likewise.
21659 2018-05-23 Richard Sandiford <richard.sandiford@linaro.org>
21661 PR tree-optimization/85853
21662 * tree-vect-slp.c (vect_slp_analyze_node_operations): Split out
21663 the handling of the root of the node to...
21664 (vect_slp_analyze_node_operations_1): ...this new function,
21665 and run the whole thing with the child nodes' def types
21666 set according to their SLP node's def type.
21668 2018-05-23 Richard Biener <rguenther@suse.de>
21670 PR middle-end/85874
21671 * tree-data-ref.c (create_runtime_alias_checks): Defer
21672 and ignore overflow warnings.
21674 2018-05-23 Yury Gribov <tetra2005@gmail.com>
21676 PR tree-optimization/85822
21677 * tree-vrp.c (is_masked_range_test): Fix handling of negative
21680 2018-05-23 Richard Biener <rguenther@suse.de>
21682 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
21683 memset constants via native_interpret_expr.
21685 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
21688 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
21690 (cgraph_node::create_alias): Likewise.
21691 (cgraph_node::get_availability): Check ifunc_resolver instead
21692 of looking up ifunc attribute.
21693 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
21694 * varasm.c (do_assemble_alias): Likewise.
21695 (assemble_alias): Likewise.
21696 (default_binds_local_p_3): Likewise.
21697 * cgraph.h (cgraph_node): Add ifunc_resolver.
21698 (cgraph_node::only_called_directly_or_aliased_p): Return false
21699 for IFUNC resolver.
21700 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
21702 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
21703 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
21704 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
21705 instead of looking up ifunc attribute.
21707 2018-05-22 Luis Machado <luis.machado@linaro.org>
21709 * config/aarch64/aarch64.md (*ashift<mode>_extv_bfiz): New pattern.
21711 2018-05-22 Martin Sebor <msebor@redhat.com>
21713 PR middle-end/85359
21714 * builtins.c (expand_builtin_strcpy): Call maybe_warn_nonstring_arg
21715 only when expasion succeeds.
21716 (expand_builtin_strcmp): Same.
21717 (expand_builtin_strncmp): Same.
21719 2018-05-22 Martin Sebor <msebor@redhat.com>
21721 * calls.c (maybe_warn_nonstring_arg): Fix a typo in a comment.
21723 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
21724 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21726 * config/aarch64/aarch64-ldpstp.md: Replace uses of
21727 aarch64_mem_pair_operand with memory_operand and delete operand swapping
21729 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
21730 Add check for legitimate_address.
21731 (aarch64_gen_adjusted_ldpstp): Swap operands where appropriate.
21732 (aarch64_swap_ldrstr_operands): New.
21733 * config/aarch64/aarch64-protos.h (aarch64_swap_ldrstr_operands):
21736 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
21737 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21739 * config/aarch64/aarch64.md: New patterns to generate stp
21741 (store_pair_sw, store_pair_dw): New patterns to generate stp for
21742 single words and double words.
21743 (load_pair_sw, load_pair_dw): Likewise.
21744 (store_pair_sf, store_pair_df, store_pair_si, store_pair_di):
21746 (load_pair_sf, load_pair_df, load_pair_si, load_pair_di):
21748 * config/aarch64/aarch64-ldpstp.md: Modify peephole
21749 for different mode ldpstp and add peephole for merged zero stores.
21750 Likewise for loads.
21751 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
21753 (aarch64_gen_store_pair): Rename calls to match new patterns.
21754 (aarch64_gen_load_pair): Rename calls to match new patterns.
21755 * config/aarch64/aarch64-simd.md (load_pair<mode>): Rename to...
21756 (load_pair<DREG:mode><DREG2:mode>): ... This.
21757 (store_pair<mode>): Rename to...
21758 (vec_store_pair<DREG:mode><DREG2:mode>): ... This.
21759 * config/aarch64/iterators.md (DREG, DREG2, DX2, SX, SX2, DSX):
21760 New mode iterators.
21761 (V_INT_EQUIV): Handle SImode.
21762 * config/aarch64/predicates.md (aarch64_reg_zero_or_fp_zero):
21765 2018-05-22 Martin Sebor <msebor@redhat.com>
21768 * calls.c (maybe_warn_nonstring_arg): Use string length to set
21769 or ajust the presumed bound on an operation to avoid unnecessary
21772 2018-05-22 Martin Sebor <msebor@redhat.com>
21774 PR tree-optimization/85826
21775 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Avoid
21776 assuming that a DECL necesarily has a constant size.
21778 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
21780 PR middle-end/85862
21781 * internal-fn.c (expand_direct_optab_fn): Cope with a null lhs.
21783 2018-05-22 Richard Biener <rguenther@suse.de>
21785 PR tree-optimization/85834
21786 * tree-ssa-sccvn.c (vn_reference_lookup_3): Properly handle
21787 non-constant and non-zero memset arguments.
21789 2018-05-22 Martin Liska <mliska@suse.cz>
21792 * ipa-icf.c (sem_item::add_type): Do not ICE for incomplete types.
21794 2018-05-22 Richard Biener <rguenther@suse.de>
21796 PR tree-optimization/85863
21797 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
21798 comparisons when vectype is specified.
21799 (vectorizable_condition): Do not specify vectype for
21800 vect_is_simple_cond when SLP vectorizing.
21802 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
21805 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
21806 define __ibm128 as long double.
21807 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
21808 as a distinct type when IEEE 128-bit support is enabled.
21809 (init_float128_ieee): Fix up conversions between IFmode and IEEE
21810 128-bit types to use the correct functions.
21811 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
21812 convert between 128-bit floating point types that have different
21813 modes but the same representation, instead of using gen_lowpart to
21815 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
21817 (IFKF_reg): New attributes to give the register constraints for
21819 (extend<mode>tf2_internal): New insns to mark an explicit
21820 conversion between 128-bit floating point types that have a
21821 different mode but share the same representation.
21823 2018-05-21 Richard Sandiford <richard.sandiford@linaro.org>
21825 PR tree-optimization/85814
21826 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
21827 a null return from get_strinfo when unsharing the next
21828 strinfo in the chain.
21830 2018-05-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
21833 * varasm.c (weak_finish): Clean up weak_decls.
21835 2018-05-21 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21837 * config/aarch64/aarch64.md ("unspec"): Define UNSPEC_SABAL,
21838 UNSPEC_SABDL2, UNSPEC_SADALP, UNSPEC_UABAL, UNSPEC_UABDL2,
21839 UNSPEC_UADALP values.
21840 * config/aarch64/iterators.md (ABAL): New int iterator.
21843 (sur): Add mappings for the above.
21844 * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>_3):
21846 (aarch64_<sur>abal<mode>_4): Likewise.
21847 (aarch64_<sur>adalp<mode>_3): Likewise.
21848 (<sur>sadv16qi): New define_expand.
21850 2018-05-21 Alexander Nesterovskiy <alexander.nesterovskiy@intel.com>
21852 * config/i386/i386.md (*movsf_internal): AVX falsedep fix.
21853 (*movdf_internal): Ditto.
21854 (*rcpsf2_sse): Ditto.
21855 (*rsqrtsf2_sse): Ditto.
21856 (*sqrt<mode>2_sse): Ditto.
21858 2018-05-21 Tamar Christina <tamar.christina@arm.com>
21860 * config/aarch64/aarch64-simd.md (aarch64_eor3qv8hi): Change to
21862 (aarch64_bcaxqv8hi): Change to bcaxq<mode>4.
21863 * config/aarch64/aarch64-simd-builtins.def (veor3q_u8, veor3q_u32,
21864 veor3q_u64, veor3q_s8, veor3q_s16, veor3q_s32, veor3q_s64, vbcaxq_u8,
21865 vbcaxq_u32, vbcaxq_u64, vbcaxq_s8, vbcaxq_s16, vbcaxq_s32,
21867 * config/aarch64/arm_neon.h: Likewise.
21868 * config/aarch64/iterators.md (VQ_I): New.
21870 2018-05-21 Alexey Brodkin <abrodkin@synopsys.com>
21872 * config.gcc: Add arc/t-multilib-linux to tmake_file for
21874 * config/arc/t-multilib-linux: Specify MULTILIB_OPTIONS and
21877 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
21879 * config/nds32/constraints.md (S): New constraint.
21880 * config/nds32/nds32.md (call_internal): Use constraint S.
21881 (call_value_internal): Likewise.
21882 (sibcall_internal): Likewise.
21883 (sibcall_value_internal): Likewise.
21885 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
21886 Chung-Ju Wu <jasonwucj@gmail.com>
21888 * config/nds32/nds32.c (nds32_register_move_cost): Take garywolf cpu
21889 into consideration.
21891 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
21892 Chung-Ju Wu <jasonwucj@gmail.com>
21894 * config/nds32/nds32-cost.c (rtx_cost_model_t): New structure.
21895 (insn_size_16bit, insn_size_32bit): New variables for cost evaluation.
21896 (nds32_rtx_costs_impl): Simplify.
21897 (nds32_address_cost_impl): Simplify.
21898 (nds32_init_rtx_costs): New function.
21899 (nds32_rtx_costs_speed_prefer): Likewise.
21900 (nds32_rtx_costs_size_prefer): Likewise.
21901 (nds32_address_cost_speed_prefer): Likewise.
21902 (nds32_address_cost_speed_fwprop): Likewise.
21903 (nds32_address_cost_size_prefer): Likewise.
21904 * config/nds32/nds32-protos.h (nds32_init_rtx_costs): Declare.
21905 * config/nds32/nds32.c (nds32_option_override): Use
21906 nds32_init_rtx_costs function.
21908 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
21910 * config/nds32/nds32.c (nds32_asm_file_start): Output pipeline model.
21911 * config/nds32/nds32.h (TARGET_PIPELINE_N7): Define.
21912 (TARGET_PIPELINE_N8): Likewise.
21913 (TARGET_PIPELINE_N10): Likewise.
21914 (TARGET_PIPELINE_N13): Likewise.
21915 (TARGET_PIPELINE_GRAYWOLF): Likewise.
21917 2018-05-19 Monk Chiang <sh.chiang04@gmail.com>
21919 * config/nds32/nds32-fpu.md: Update copyright year.
21921 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
21923 * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
21925 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
21927 * config/nds32/nds32.c
21928 (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
21929 * config/nds32/nds32.opt (minline-asm-r15): New option.
21931 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
21933 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS): Add
21935 * config/nds32/nds32.md (abssi2): New pattern.
21937 2018-05-19 Uros Bizjak <ubizjak@gmail.com>
21939 * config/i386/i386.md (rex64namesuffix): New mode attribute.
21940 * config/i386/sse.md (sse_cvtsi2ss<rex64namesuffix><round_name>):
21941 Merge insn pattern from sse_cvtsi2ss<round_name> and
21942 sse_cvtsi2ssq<round_name> using SWI48 mode iterator.
21943 (sse_cvtss2si<rex64namesuffix><round_name>): Merge insn pattern
21944 from sse_cvtss2si<round_name> and sse_cvtss2siq<round_name>
21945 using SWI48 mode iterator.
21946 (sse_cvtss2si<rex64namesuffix>_2): Merge insn pattern from
21947 sse_cvtss2si_2 and sse_cvtss2siq_2 using SWI48 mode iterator.
21948 (sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Merge insn
21949 pattern from sse_cvttss2si<round_saeonly_name>
21950 and sse_cvttss2siq<round_saeonly_name> using SWI48 mode iterator.
21951 (avx512f_vcvtss2usi<rex64namesuffix><round_name>): Merge insn pattern
21952 from avx512f_vcvtss2usi<round_name> and avx512f_vcvtss2usiq<round_name>
21953 using SWI48 mode iterator.
21954 (avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>): Merge
21955 insn pattern from avx512f_vcvttss2usi<round_saeonly_name> and
21956 avx512f_vcvttss2usiq<round_saeonly_name> using SWI48 mode iterator.
21957 (avx512f_vcvtsd2usi<rex64namesuffix><round_name>): Merge insn pattern
21958 from avx512f_vcvtsd2usi<round_name> and avx512f_vcvtsd2usiq<round_name>
21959 using SWI48 mode iterator.
21960 (avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>): Merge
21961 insn pattern from avx512f_vcvttsd2usi<round_saeonly_name> and
21962 avx512f_vcvttsd2usiq<round_saeonly_name> using SWI48 mode iterator.
21963 (sse2_cvtsd2si<rex64namesuffix><round_name>): Merge insn pattern from
21964 sse2_cvtsd2si<round_name> and sse2_cvtsd2siq<round_name> using
21965 SWI48 mode iterator.
21966 (sse2_cvtsd2si<rex64namesuffix>_2): Merge insn pattern from
21967 sse2_cvtsd2si_2 and sse2_cvtsd2siq_2 using SWI48 mode iterator.
21968 (sse_cvttsd2si<rex64namesuffix><round_saeonly_name>): Merge insn
21969 pattern from sse_cvttsd2si<round_saeonly_name>
21970 and sse_cvttsd2siq<round_saeonly_name> using SWI48 mode iterator.
21972 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
21974 * config/nds32/nds32-md-auxiliary.c
21975 (nds32_valid_smw_lwm_base_p): Refine.
21976 (nds32_output_smw_single_word): Refine.
21977 (nds32_output_smw_double_word): New.
21978 * config/nds32/nds32-protos.h (nds32_output_smw_double_word): New.
21980 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
21982 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Refine.
21983 (nds32_output_stack_pop): Refine.
21984 (nds32_expand_unaligned_load): Refine.
21985 (nds32_expand_unaligned_store): Refine.
21987 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
21988 Chung-Ju Wu <jasonwucj@gmail.com>
21990 * config/nds32/constants.md: Add TP_REGNUM constant.
21991 (unspec_element): Add UNSPEC_GOTINIT, UNSPEC_GOT, UNSPEC_GOTOFF,
21992 UNSPEC_PLT, UNSPEC_TLSGD, UNSPEC_TLSLD, UNSPEC_TLSIE, UNSPEC_TLSLE and
21994 * config/nds32/nds32-doubleword.md: Consider flag_pic.
21995 * config/nds32/nds32-dspext.md (mov<mode>): Expand TLS and PIC cases.
21996 * config/nds32/nds32-predicates.c (nds32_const_unspec_p): New.
21997 * config/nds32/nds32-md-auxiliary.c: Implementation that support TLS
21998 and PIC code generation.
21999 * config/nds32/nds32-protos.h: Declarations that support TLS and PIC
22001 * config/nds32/nds32-relax-opt.c: Consider TLS and PIC for relax
22003 * config/nds32/nds32.md: Support TLS and PIC.
22004 * config/nds32/nds32.c: Support TLS and PIC.
22005 * config/nds32/nds32.h (nds32_relax_insn_type): New enum type.
22006 * config/nds32/predicates.md (nds32_nonunspec_symbolic_operand): New
22009 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22011 * config/nds32/nds32-predicates.c (const_vector_to_hwint): Use machine
22012 mode with E_ prefix.
22014 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
22015 Chung-Ju Wu <jasonwucj@gmail.com>
22017 * config/nds32/constants.md (unspec_element): Add UNSPEC_ICT.
22018 * config/nds32/nds32-md-auxiliary.c
22019 (symbolic_reference_mentioned_p): New.
22020 (nds32_legitimize_ict_address): New.
22021 (nds32_expand_ict_move): New.
22022 (nds32_indirect_call_referenced_p): New.
22023 (nds32_symbol_binds_local_p): Delete.
22024 (nds32_long_call_p): Modify.
22025 * config/nds32/nds32-opts.h (nds32_ict_model_type): New enum type.
22026 * config/nds32/nds32-protos.h
22027 (symbolic_reference_mentioned_p): Declare.
22028 (nds32_legitimize_ict_address): Declare.
22029 (nds32_expand_ict_move): Declare.
22030 (nds32_indirect_call_referenced_p): Declare.
22031 * config/nds32/nds32-relax-opt.c (nds32_ict_const_p): New.
22032 (nds32_relax_group): Use nds32_ict_const_p as condition.
22033 * config/nds32/nds32.c (nds32_attribute_table): Add "indirect_call".
22034 (nds32_asm_file_start): Output ict_model directive in asm code.
22035 (nds32_legitimate_address_p): Consider indirect call.
22036 (nds32_print_operand): Consider indirect call.
22037 (nds32_print_operand_address): Consider indirect call.
22038 (nds32_insert_attributes): Handle "indirect_call" attribute.
22039 (TARGET_LEGITIMATE_ADDRESS_P): Define.
22040 (TARGET_LEGITIMATE_CONSTANT_P): Define.
22041 (TARGET_CANNOT_FORCE_CONST_MEM): Define.
22042 (TARGET_DELEGITIMIZE_ADDRESS): Define.
22043 (TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA): Define.
22044 * config/nds32/nds32.h (SYMBOLIC_CONST_P): Define.
22045 (TARGET_ICT_MODEL_SMALL): Define.
22046 (TARGET_ICT_MODEL_LARGE): Define.
22047 * config/nds32/nds32.md (movsi): Consider ict model.
22048 (call, call_value): Consider ict model.
22049 (sibcall, sibcall_value): Consider ict model.
22050 * config/nds32/nds32.opt (mict-model): New option.
22051 * config/nds32/predicates.md (nds32_symbolic_operand): Consider ict
22054 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
22055 Monk Chiang <sh.chiang04@gmail.com>
22056 Jim Wilson <jimw@sifive.com>
22058 * common/config/riscv/riscv-common.c (riscv_parse_arch_string):
22059 Add support to parse rv32e*. Clear MASK_RVE for rv32i and rv64i.
22060 * config.gcc (riscv*-*-*): Add support for rv32e* and ilp32e.
22061 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): Define
22062 __riscv_32e when TARGET_RVE. Handle ABI_ILP32E as soft-float ABI.
22063 * config/riscv/riscv-opts.h (riscv_abi_type): Add ABI_ILP32E.
22064 * config/riscv/riscv.c (riscv_compute_frame_info): When TARGET_RVE,
22065 compute save_libcall_adjustment properly.
22066 (riscv_option_override): Call error if TARGET_RVE and not ABI_ILP32E.
22067 (riscv_conditional_register_usage): Handle TARGET_RVE and ABI_ILP32E.
22068 * config/riscv/riscv.h (UNITS_PER_FP_ARG): Handle ABI_ILP32E.
22069 (STACK_BOUNDARY, ABI_STACK_BOUNDARY): Handle TARGET_RVE.
22070 (GP_REG_LAST, MAX_ARGS_IN_REGISTERS): Likewise.
22071 (ABI_SPEC): Handle mabi=ilp32e.
22072 * config/riscv/riscv.opt (abi_type): Add ABI_ILP32E.
22073 (RVE): Add RVE mask.
22074 * doc/invoke.texi (RISC-V options) <-mabi>: Add ilp32e info.
22075 <-march>: Add rv32e as an example.
22077 2018-05-18 Marc Glisse <marc.glisse@inria.fr>
22080 * tree-ssa-structalias.c (create_variable_info_for_1): Extra argument.
22081 (intra_create_variable_infos): Handle C++ constructors.
22083 2018-05-18 Martin Liska <mliska@suse.cz>
22085 * passes.def: Remove a redundant pass.
22087 2018-05-18 Eric Botcazou <ebotcazou@adacore.com>
22090 * config/sparc/sparc.c (sparc_expand_builtin): Always initialize op[0].
22092 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22094 * config/arm/arm-cpus.in (armv3m, mode32): Delete features.
22096 (ARMv2, ARMv3, ARMv3m): Delete fgroups.
22098 (armv2, armv2a, armv3, armv3m): Delete architectures.
22099 (arm2, arm250, arm3, arm6, arm60, arm600, arm610, arm620,
22100 arm7, arm7d, arm7di, arm70, arm700, arm700i, arm710, arm720,
22101 arm710c, arm7100, arm7500, arm7500fe, arm7m, arm7dm, arm7dmi):
22103 * config/arm/arm.md (maddsidi4): Remove check for arm_arch3m.
22104 (*mulsidi3adddi): Likewise.
22105 (mulsidi3): Likewise.
22106 (*mulsidi3_nov6): Likewise.
22107 (umulsidi3): Likewise.
22108 (umulsidi3_nov6): Likewise.
22109 (umaddsidi4): Likewise.
22110 (*umulsidi3adddi): Likewise.
22111 (smulsi3_highpart): Likewise.
22112 (*smulsi3_highpart_nov6): Likewise.
22113 (umulsi3_highpart): Likewise.
22114 (*umulsi3_highpart_nov6): Likewise.
22115 * config/arm/arm.h (arm_arch3m): Delete.
22116 * config/arm/arm.c (arm_arch3m): Delete.
22117 (arm_option_override_internal): Update armv3-related comment.
22118 (arm_configure_build_target): Delete use of isa_bit_mode32.
22119 (arm_option_reconfigure_globals): Delete set of arm_ach3m.
22120 (arm_rtx_costs_internal): Delete check of arm_arch3m.
22121 * config/arm/arm-fixed.md (mulsq3): Delete check for arm_arch3m.
22122 (mulsa3): Likewise.
22123 (mulusa3): Likewise.
22124 * config/arm/arm-protos.h (arm_arch3m): Delete.
22125 * config/arm/arm-tables.opt: Regenerate.
22126 * config/arm/arm-tune.md: Likewise.
22127 * config/arm/t-arm-elf (all_early_nofp): Delete mentions of
22128 deleted architectures.
22130 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22132 * config/arm/arm-cpus.in (armv5, armv5e): Delete features.
22133 (armv5t, armv5te): New features.
22134 (ARMv5, ARMv5e): Delete fgroups.
22135 (ARMv5t, ARMv5te): Adjust for above changes.
22136 (ARMv6m): Likewise.
22137 (armv5, armv5e): Delete arches.
22138 * config/arm/arm.md (*call_reg_armv5): Use arm_arch5t instead of
22140 (*call_reg_arm): Likewise.
22141 (*call_value_reg_armv5): Likewise.
22142 (*call_value_reg_arm): Likewise.
22143 (*call_symbol): Likewise.
22144 (*call_value_symbol): Likewise.
22145 (*sibcall_insn): Likewise.
22146 (*sibcall_value_insn): Likewise.
22147 (clzsi2): Likewise.
22148 (prefetch): Likewise.
22149 (define_split and define_peephole2 dependent on arm_arch5):
22151 * config/arm/arm.h (TARGET_LDRD): Use arm_arch5te instead of
22153 (TARGET_ARM_QBIT): Likewise.
22154 (TARGET_DSP_MULTIPLY): Likewise.
22155 (enum base_architecture): Delete BASE_ARCH_5, BASE_ARCH_5E.
22156 (arm_arch5, arm_arch5e): Delete.
22157 (arm_arch5t, arm_arch5te): Declare.
22158 * config/arm/arm.c (arm_arch5, arm_arch5e): Delete.
22159 (arm_arch5t): Declare.
22160 (arm_option_reconfigure_globals): Update for the above.
22161 (arm_options_perform_arch_sanity_checks): Update comment, replace
22162 use of arm_arch5 with arm_arch5t.
22163 (use_return_insn): Likewise.
22164 (arm_emit_call_insn): Likewise.
22165 (output_return_instruction): Likewise.
22166 (arm_final_prescan_insn): Likewise.
22167 (arm_coproc_builtin_available): Likewise.
22168 * config/arm/arm-c.c (arm_cpu_builtins): Replace arm_arch5 and
22169 arm_arch5e with arm_arch5t and arm_arch5te.
22170 * config/arm/arm-protos.h (arm_arch5, arm_arch5e): Delete.
22171 (arm_arch5t, arm_arch5te): Declare.
22172 * config/arm/arm-tables.opt: Regenerate.
22173 * config/arm/t-arm-elf: Remove references to armv5, armv5e.
22174 * config/arm/t-multilib: Likewise.
22175 * config/arm/thumb1.md (*call_reg_thumb1_v5): Check arm_arch5t
22176 instead of arm_arch5.
22177 (*call_reg_thumb1): Likewise.
22178 (*call_value_reg_thumb1_v5): Likewise.
22179 (*call_value_reg_thumb1): Likewise.
22180 * config/arm/vxworks.h (TARGET_OS_CPP_BUILTINS): Remove now
22182 * doc/invoke.texi (ARM Options): Remove references to armv5, armv5e.
22184 2018-05-18 Martin Liska <mliska@suse.cz>
22186 PR gcov-profile/84846
22187 * doc/gcov.texi: Document -t option of gcov tool.
22189 2018-05-18 Martin Liska <mliska@suse.cz>
22191 PR gcov-profile/84846
22192 * gcov.c (print_usage): Add new -t option.
22193 (process_args): Handle the option.
22194 (generate_results): Use stdout as output when requested by
22197 2018-05-18 Martin Liska <mliska@suse.cz>
22199 PR gcov-profile/84846
22200 * coverage.c (coverage_init): Write PWD to .gcno file.
22201 * doc/gcov.texi: Document how working directory is printed.
22202 * gcov-dump.c (dump_gcov_file): Print PWD.
22203 * gcov.c (output_intermediate_file): Likewise.
22204 (read_graph_file): Read PWD string.
22205 (output_lines): Print PWD.
22207 2018-05-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
22209 PR middle-end/85817
22210 * ipa-pure-const.c (malloc_candidate_p): Remove the check integer_zerop
22211 for retval and return false if all args to phi are zero.
22213 2018-05-18 Richard Biener <rguenther@suse.de>
22215 * gimple-ssa-evrp.c (class evrp_folder): Add simplify_stmt_using_ranges
22217 (evrp_dom_walker::before_dom_children): Call it.
22219 2018-05-18 Richard Biener <rguenther@suse.de>
22221 * tree-dfa.c (get_ref_base_and_extent): Use range-info to refine
22222 results when processing array refs with variable index.
22224 2018-05-18 Toon Moene <toon@moene.org>
22226 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
22227 directly after that of -floop-interchange. Indicate that both
22228 options are enabled by default when specifying -O3.
22230 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22232 * config/aarch64/aarch64-simd.md (vec_set<mode>): Use VALL_F16 mode
22233 iterator. Delete separate integer-mode vec_set<mode> expander.
22234 (aarch64_simd_vec_setv2di): Delete.
22235 (vec_setv2di): Delete.
22236 (aarch64_simd_vec_set<mode>): Delete all other patterns with that name.
22237 Use VALL_F16 mode iterator. Add LD1 alternative and use vwcore for
22238 the "w, r" alternative.
22240 2018-05-18 Martin Liska <mliska@suse.cz>
22242 * passes.def: Add pass_lower_switch and pass_lower_switch_O0.
22243 * tree-pass.h (make_pass_lower_switch_O0): New function.
22244 * tree-switch-conversion.c (node_has_low_bound): Remove.
22245 (node_has_high_bound): Likewise.
22246 (node_is_bounded): Likewise.
22247 (class pass_lower_switch): Make it a template type and create
22249 (pass_lower_switch::execute): Add template argument.
22250 (make_pass_lower_switch): New function.
22251 (make_pass_lower_switch_O0): New function.
22252 (do_jump_if_equal): Remove.
22253 (emit_case_nodes): Simplify to just handle all 3 cases and leave
22254 all the hard work to tree optimization passes.
22256 2018-05-18 Martin Liska <mliska@suse.cz>
22258 * dbgcnt.c (limit_low): Renamed from limit.
22259 (limit_high): New variable.
22260 (dbg_cnt_is_enabled): Check for upper limit.
22261 (dbg_cnt): Adjust dumping.
22262 (dbg_cnt_set_limit_by_index): Add new argument for high
22264 (dbg_cnt_set_limit_by_name): Likewise.
22265 (dbg_cnt_process_single_pair): Parse new format.
22266 (dbg_cnt_process_opt): Use strtok.
22267 (dbg_cnt_list_all_counters): Remove 'value' and add
22269 * doc/invoke.texi: Document changes.
22271 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
22273 * doc/sourcebuild.texi (scalar_all_fma): Document.
22274 * tree.def (FMA_EXPR): Delete.
22275 * internal-fn.def (FMA, FMS, FNMA, FNMS): New internal functions.
22276 * internal-fn.c (ternary_direct): New macro.
22277 (expand_ternary_optab_fn): Likewise.
22278 (direct_ternary_optab_supported_p): Likewise.
22279 * Makefile.in (build/genmatch.o): Depend on case-fn-macros.h.
22280 * builtins.c (fold_builtin_fma): Delete.
22281 (fold_builtin_3): Don't call it.
22282 * cfgexpand.c (expand_debug_expr): Remove FMA_EXPR handling.
22283 * expr.c (expand_expr_real_2): Likewise.
22284 * fold-const.c (operand_equal_p): Likewise.
22285 (fold_ternary_loc): Likewise.
22286 * gimple-pretty-print.c (dump_ternary_rhs): Likewise.
22287 * gimple.c (DEFTREECODE): Likewise.
22288 * gimplify.c (gimplify_expr): Likewise.
22289 * optabs-tree.c (optab_for_tree_code): Likewise.
22290 * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
22291 * tree-eh.c (operation_could_trap_p): Likewise.
22292 (stmt_could_throw_1_p): Likewise.
22293 * tree-inline.c (estimate_operator_cost): Likewise.
22294 * tree-pretty-print.c (dump_generic_node): Likewise.
22295 (op_code_prio): Likewise.
22296 * tree-ssa-loop-im.c (stmt_cost): Likewise.
22297 * tree-ssa-operands.c (get_expr_operands): Likewise.
22298 * tree.c (commutative_ternary_tree_code, add_expr): Likewise.
22299 * fold-const-call.h (fold_fma): Delete.
22300 * fold-const-call.c (fold_const_call_ssss): Handle CFN_FMS,
22301 CFN_FNMA and CFN_FNMS.
22302 (fold_fma): Delete.
22303 * genmatch.c (combined_fn): New enum.
22304 (commutative_ternary_tree_code): Remove FMA_EXPR handling.
22305 (commutative_op): New function.
22306 (commutate): Use it. Handle more than 2 operands.
22307 (dt_operand::gen_gimple_expr): Use commutative_op.
22308 (parser::parse_expr): Allow :c to be used with non-binary
22309 operators if the commutative operand is known.
22310 * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Handle
22311 CFN_FMS, CFN_FNMA and CFN_FNMS.
22312 (backprop::process_assign_use): Remove FMA_EXPR handling.
22313 * hsa-gen.c (gen_hsa_insns_for_operation_assignment): Likewise.
22314 (gen_hsa_fma): New function.
22315 (gen_hsa_insn_for_internal_fn_call): Use it for IFN_FMA, IFN_FMS,
22316 IFN_FNMA and IFN_FNMS.
22317 * match.pd: Add folds for IFN_FMS, IFN_FNMA and IFN_FNMS.
22318 * gimple-fold.h (follow_all_ssa_edges): Declare.
22319 * gimple-fold.c (follow_all_ssa_edges): New function.
22320 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Use the
22321 gimple_build interface and use follow_all_ssa_edges to fold the result.
22322 (convert_mult_to_fma): Use direct_internal_fn_suppoerted_p
22323 instead of checking for optabs directly.
22324 * config/i386/i386.c (ix86_add_stmt_cost): Recognize FMAs as calls
22325 rather than FMA_EXPRs.
22326 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Create a
22327 call to IFN_FMA instead of an FMA_EXPR.
22329 2018-05-17 Jim Wilson <jimw@sifive.com>
22331 * expr.c (do_tablejump): When converting index to Pmode, if we have a
22332 sign extended promoted subreg, and the range does not have the sign bit
22333 set, then do a sign extend.
22335 * config/riscv/riscv.c (riscv_extend_comparands): In unsigned QImode
22336 test, check for sign extended subreg and/or constant operands, and
22337 do a sign extend in that case.
22339 2018-05-17 Steve Ellcey <sellcey@cavium.com>
22341 * config/aarch64/thunderx2t99.md (thunderx2t99_ls_both): Delete.
22342 (thunderx2t99_multiple): Delete psuedo-units from used cpus.
22344 (thunderx2t99_alu_shift): Remove alu_shift_reg, alus_shift_reg.
22345 Change logics_shift_reg to logics_shift_imm.
22346 (thunderx2t99_fp_loadpair_basic): Delete.
22347 (thunderx2t99_fp_storepair_basic): Delete.
22348 (thunderx2t99_asimd_int): Add neon_sub and neon_sub_q types.
22349 (thunderx2t99_asimd_polynomial): Delete.
22350 (thunderx2t99_asimd_fp_simple): Add neon_fp_mul_s_scalar_q
22351 and neon_fp_mul_d_scalar_q.
22352 (thunderx2t99_asimd_fp_conv): Add *int_to_fp* types.
22353 (thunderx2t99_asimd_misc): Delete neon_dup and neon_dup_q.
22354 (thunderx2t99_asimd_recip_step): Add missing *sqrt* types.
22355 (thunderx2t99_asimd_lut): Add missing tbl types.
22356 (thunderx2t99_asimd_ext): Delete.
22357 (thunderx2t99_asimd_load1_1_mult): Delete.
22358 (thunderx2t99_asimd_load1_2_mult): Delete.
22359 (thunderx2t99_asimd_load1_ldp): New.
22360 (thunderx2t99_asimd_load1): New.
22361 (thunderx2t99_asimd_load2): Add missing *load2* types.
22362 (thunderx2t99_asimd_load3): New.
22363 (thunderx2t99_asimd_load4): New.
22364 (thunderx2t99_asimd_store1_1_mult): Delete.
22365 (thunderx2t99_asimd_store1_2_mult): Delete.
22366 (thunderx2t99_asimd_store2_mult): Delete.
22367 (thunderx2t99_asimd_store2_onelane): Delete.
22368 (thunderx2t99_asimd_store_stp): New.
22369 (thunderx2t99_asimd_store1): New.
22370 (thunderx2t99_asimd_store2): New.
22371 (thunderx2t99_asimd_store3): New.
22372 (thunderx2t99_asimd_store4): New.
22374 2018-05-17 Jerome Lambourg <lambourg@adacore.com>
22376 * config/arm/arm_cmse.h (cmse_nsfptr_create, cmse_is_nsfptr): Remove
22377 #include <stdint.h>. Replace intptr_t with __INTPTR_TYPE__.
22379 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
22380 Segher Boessenkool <segher@kernel.crashing.org>
22383 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest
22386 2018-05-17 Richard Biener <rguenther@suse.de>
22388 * tree-ssa-dse.c (dse_classify_store): Fix iterator increment
22389 for pruning loop and prune defs feeding only already visited PHIs.
22391 2018-05-17 Richard Biener <rguenther@suse.de>
22393 * tree-ssa-sccvn.c (vn_reference_lookup_3): Improve memset handling.
22395 2018-05-17 Bin Cheng <bin.cheng@arm.com>
22396 Richard Biener <rguenther@suse.de>
22398 PR tree-optimization/85793
22399 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
22400 for VMAT_ELEMENTWISE.
22402 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
22404 * internal-fn.h (lookup_internal_fn): Declare
22405 * internal-fn.c (lookup_internal_fn): New function.
22406 * gimple.c (gimple_build_call_from_tree): Handle calls to
22407 internal functions.
22408 * gimple-pretty-print.c (dump_gimple_call): Print "." before
22409 internal function names.
22410 * tree-pretty-print.c (dump_generic_node): Likewise.
22411 * tree-ssa-scopedtables.c (expr_hash_elt::print): Likewise.
22413 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
22415 * gimple-fold.h (gimple_build): Make the function forms take
22416 combined_fn rather than built_in_function.
22417 (gimple_simplify): Likewise.
22418 * gimple-match-head.c (gimple_simplify): Likewise.
22419 * gimple-fold.c (gimple_build): Likewise.
22420 * tree-vect-loop.c (get_initial_def_for_reduction): Use gimple_build
22421 rather than gimple_build_call_internal.
22422 (get_initial_defs_for_reduction): Likewise.
22423 (vect_create_epilog_for_reduction): Likewise.
22424 (vectorizable_live_operation): Likewise.
22426 2018-05-17 Martin Liska <mliska@suse.cz>
22428 * gimple-ssa-sprintf.c (format_directive): Do not use
22429 space in between 'G_' and '('.
22431 2018-05-17 Jakub Jelinek <jakub@redhat.com>
22434 * config/i386/i386.c (ix86_fold_builtin): Handle masked shifts
22435 even if the mask is not all ones.
22438 * config/i386/i386.c (ix86_fold_builtin): Fold shift builtins by
22440 (ix86_gimple_fold_builtin): Likewise.
22443 * config/i386/i386.c: Include tree-vector-builder.h.
22444 (ix86_vector_shift_count): New function.
22445 (ix86_fold_builtin): Fold shift builtins by scalar count.
22446 (ix86_gimple_fold_builtin): Likewise.
22448 * config/i386/avx512fintrin.h (_mm512_set_epi16, _mm512_set_epi8,
22449 _mm512_setzero): New intrinsics.
22451 2018-05-17 James Greenhalgh <james.greenhalgh@arm.com>
22452 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22454 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify
22455 code generation for cases where splatting a value is not useful.
22456 * simplify-rtx.c (simplify_ternary_operation): Simplify
22457 vec_merge across a vec_duplicate and a paradoxical subreg forming
22458 a vector mode to a vec_concat.
22460 2018-05-17 Olga Makhotina <olga.makhotina@intel.com>
22462 * config.gcc: Support "goldmont-plus".
22463 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
22465 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
22466 PROCESSOR_GOLDMONT_PLUS.
22467 * config/i386/i386.c (m_GOLDMONT_PLUS): Define.
22468 (processor_target_table): Add "goldmont-plus".
22469 (PTA_GOLDMONT_PLUS): Define.
22470 (ix86_lea_outperforms): Add TARGET_GOLDMONT_PLUS.
22471 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT_PLUS.
22472 (fold_builtin_cpu): Add M_INTEL_GOLDMONT_PLUS.
22473 (fold_builtin_cpu): Add "goldmont-plus".
22474 (ix86_add_stmt_cost): Add TARGET_GOLDMONT_PLUS.
22475 (ix86_option_override_internal): Add "goldmont-plus".
22476 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT_PLUS.
22477 (processor_type): Add PROCESSOR_GOLDMONT_PLUS.
22478 * config/i386/x86-tune.def: Add m_GOLDMONT_PLUS.
22479 * doc/invoke.texi: Add goldmont-plus as x86 -march=/-mtune= CPU type.
22481 2018-05-17 Richard Biener <rguenther@suse.de>
22483 PR tree-optimization/85757
22484 * tree-ssa-dse.c (dse_classify_store): Record a PHI def and
22485 remove defs that only feed that PHI from further processing.
22487 2018-05-16 Jim Wilson <jimw@sifive.com>
22489 * config/riscv/riscv.md (<optab>si3_mask, <optab>si3_mask_1): Prepend
22491 (<optab>di3_mask, <optab>di3_mask_1): Likewise.
22493 2018-05-16 Mark Wielaard <mark@klomp.org>
22495 * dwarf2out.c (count_index_strings): New function.
22496 (output_indirect_strings): Call count_index_strings and generate
22497 header for dwarf_version >= 5.
22499 2018-05-16 Mark Wielaard <mark@klomp.org>
22501 * dwarf2out.c (dwarf_FORM): New function.
22502 (set_indirect_string): Use dwarf_FORM.
22503 (reset_indirect_string): Likewise.
22504 (size_of_die): Likewise.
22505 (value_format): Likewise.
22506 (output_die): Likewise.
22507 (add_skeleton_AT_string): Likewise.
22508 (output_macinfo_op): Likewise.
22509 (index_string): Likewise.
22510 (output_index_string_offset): Likewise.
22511 (output_index_string): Likewise.
22512 (count_index_strings): Likewise.
22514 2018-05-16 Carl Love <cel@us.ibm.com>
22516 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
22517 dcbt and dcbtstt with TH=16 if operands[2] is 0 and Power 8 or newer.
22519 2018-05-16 Martin Jambor <mjambor@suse.cz>
22521 * ipa-prop.c (ipa_free_all_edge_args): Remove.
22522 * ipa-prop.h (ipa_free_all_edge_args): Likewise.
22524 2018-05-16 Wilco Dijkstra <wdijkstr@arm.com>
22526 * config/aarch64/aarch64.md (fma<mode>4): Change into expand pattern.
22527 (fnma<mode>4): Likewise.
22528 (fms<mode>4): Likewise.
22529 (fnms<mode>4): Likewise.
22530 (aarch64_fma<mode>4): Rename insn, reorder accumulator operand.
22531 (aarch64_fnma<mode>4): Likewise.
22532 (aarch64_fms<mode>4): Likewise.
22533 (aarch64_fnms<mode>4): Likewise.
22534 (aarch64_fnmadd<mode>4): Likewise.
22536 2018-05-16 Jason Merrill <jason@redhat.com>
22538 * tree.c (warn_deprecated_use): Return bool. Simplify logic.
22540 2018-05-16 Richard Biener <rguenther@suse.de>
22542 * tree-vectorizer.h (struct stmt_info_for_cost): Add where member.
22543 (dump_stmt_cost): Declare.
22544 (add_stmt_cost): Dump cost we add.
22545 (add_stmt_costs): New function.
22546 (vect_model_simple_cost, vect_model_store_cost, vect_model_load_cost):
22547 No longer exported.
22548 (vect_analyze_stmt): Adjust prototype.
22549 (vectorizable_condition): Likewise.
22550 (vectorizable_live_operation): Likewise.
22551 (vectorizable_reduction): Likewise.
22552 (vectorizable_induction): Likewise.
22553 * tree-vect-loop.c (vect_analyze_loop_operations): Create local
22554 cost vector to pass to vectorizable_ and record afterwards.
22555 (vect_model_reduction_cost): Take cost vector argument and adjust.
22556 (vect_model_induction_cost): Likewise.
22557 (vectorizable_reduction): Likewise.
22558 (vectorizable_induction): Likewise.
22559 (vectorizable_live_operation): Likewise.
22560 * tree-vect-slp.c (vect_create_new_slp_node): Initialize
22561 SLP_TREE_NUMBER_OF_VEC_STMTS.
22562 (vect_analyze_slp_cost_1): Remove.
22563 (vect_analyze_slp_cost): Likewise.
22564 (vect_slp_analyze_node_operations): Take visited args and
22565 a target cost vector. Avoid processing already visited stmt sets.
22566 (vect_slp_analyze_operations): Use a local cost vector to gather
22567 costs and register those of non-discarded instances.
22568 (vect_bb_vectorization_profitable_p): Use add_stmt_costs.
22569 (vect_schedule_slp_instance): Remove copying of
22570 SLP_TREE_NUMBER_OF_VEC_STMTS. Instead assert that it is not
22572 * tree-vect-stmts.c (record_stmt_cost): Remove path directly
22573 adding cost. Record cost entry location.
22574 (vect_prologue_cost_for_slp_op): Function to compute cost of
22575 a constant or invariant generated for SLP vect in the prologue,
22576 split out from vect_analyze_slp_cost_1.
22577 (vect_model_simple_cost): Make static. Adjust for SLP costing.
22578 (vect_model_promotion_demotion_cost): Likewise.
22579 (vect_model_store_cost): Likewise, make static.
22580 (vect_model_load_cost): Likewise.
22581 (vectorizable_bswap): Add cost vector arg and adjust.
22582 (vectorizable_call): Likewise.
22583 (vectorizable_simd_clone_call): Likewise.
22584 (vectorizable_conversion): Likewise.
22585 (vectorizable_assignment): Likewise.
22586 (vectorizable_shift): Likewise.
22587 (vectorizable_operation): Likewise.
22588 (vectorizable_store): Likewise.
22589 (vectorizable_load): Likewise.
22590 (vectorizable_condition): Likewise.
22591 (vectorizable_comparison): Likewise.
22592 (can_vectorize_live_stmts): Likewise.
22593 (vect_analyze_stmt): Likewise.
22594 (vect_transform_stmt): Adjust calls to vectorizable_*.
22595 * tree-vectorizer.c: Include gimple-pretty-print.h.
22596 (dump_stmt_cost): New function.
22598 2018-05-16 Richard Biener <rguenther@suse.de>
22600 * params.def (PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE): New param.
22601 * doc/invoke.texi (dse-max-alias-queries-per-store): Document.
22602 * tree-ssa-dse.c: Include tree-ssa-loop.h.
22603 (check_name): New callback.
22604 (dse_classify_store): Track cycles via a visited bitmap of PHI
22605 defs and simplify handling of in-loop and across loop dead stores
22606 and properly fail for loop-variant refs. Handle byte-tracking with
22607 multiple defs. Use PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE for
22610 2018-05-16 Richard Sandiford <richard.sandiford@linaro.org>
22612 * tree-vectorizer.h (vect_get_vector_types_for_stmt): Declare.
22613 (vect_get_mask_type_for_stmt): Likewise.
22614 * tree-vect-slp.c (vect_two_operations_perm_ok_p): New function,
22616 (vect_build_slp_tree_1): ...here. Use vect_get_vector_types_for_stmt
22617 to determine the statement's vector type and the vector type that
22618 should be used for calculating nunits. Deal with cases in which
22619 the type has to be deferred.
22620 (vect_slp_analyze_node_operations): Use vect_get_vector_types_for_stmt
22621 and vect_get_mask_type_for_stmt to calculate STMT_VINFO_VECTYPE.
22622 * tree-vect-loop.c (vect_determine_vf_for_stmt_1)
22623 (vect_determine_vf_for_stmt): New functions, split out from...
22624 (vect_determine_vectorization_factor): ...here.
22625 * tree-vect-stmts.c (vect_get_vector_types_for_stmt)
22626 (vect_get_mask_type_for_stmt): New functions, split out from
22627 vect_determine_vectorization_factor.
22629 2018-05-16 Richard Biener <rguenther@suse.de>
22631 * tree-cfg.c (verify_gimple_assign_ternary): Properly
22632 verify the [VEC_]COND_EXPR embedded comparison.
22634 2018-05-15 Martin Sebor <msebor@redhat.com>
22636 PR tree-optimization/85753
22637 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Handle
22638 RECORD_TYPE in addition to ARRAY_TYPE.
22640 2018-05-15 Martin Sebor <msebor@redhat.com>
22642 PR middle-end/85643
22643 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
22645 2018-05-15 Richard Biener <rguenther@suse.de>
22647 * tree-ssa-dse.c (dse_classify_store): Remove use_stmt parameter,
22648 add by_clobber_p one. Change algorithm to collect all defs
22649 representing uses we need to walk and try reducing them to
22650 a single one before failing.
22651 (dse_dom_walker::dse_optimize_stmt): Adjust.
22653 2018-05-13 Mark Wielaard <mark@klomp.org>
22655 * dwarf2out.c (dwarf_OP): Handle DW_OP_addrx and DW_OP_constx.
22656 (size_of_loc_descr): Likewise.
22657 (output_loc_operands): Likewise.
22658 (output_loc_operands_raw): Likewise.
22659 (dw_addr_op): Use dwarf_OP () for DW_OP_constx and DW_OP_addrx.
22660 (resolve_addr_in_expr): Handle DW_OP_addrx and DW_OP_constx.
22661 (hash_loc_operands): Likewise.
22662 (compare_loc_operands): Likewise.
22664 2018-05-14 Mark Wielaard <mark@klomp.org>
22666 * dwarf2out.c (count_index_addrs): New function.
22667 (dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
22669 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
22671 PR tree-optimization/83648
22672 * ipa-pure-const.c (malloc_candidate_p): Allow function with NULL
22673 return value as malloc candidate.
22675 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
22678 * ipa-pure-const.c (warn_function_malloc): Pass value of known_finite
22679 param as true in call to suggest_attribute.
22681 2018-05-14 Segher Boessenkool <segher@kernel.crashing.org>
22683 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete @itemx for
22684 -mreadonly-in-sdata.
22686 2018-05-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22688 * config/aarch64/aarch64-simd.md (*aarch64_crypto_aese_fused):
22690 (aarch64_crypto_aesd_fused): Likewise.
22692 2018-05-14 Wilco Dijkstra <wdijkstr@arm.com>
22694 * config/aarch64/aarch64.md (mov<mode>): Remove '*' in alternatives.
22695 (movsi_aarch64): Likewise.
22696 (load_pairsi): Likewise.
22697 (load_pairdi): Likewise.
22698 (store_pairsi): Likewise.
22699 (store_pairdi): Likewise.
22700 (load_pairsf): Likewise.
22701 (load_pairdf): Likewise.
22702 (store_pairsf): Likewise.
22703 (store_pairdf): Likewise.
22704 (zero_extend): Likewise.
22705 (trunc): Swap alternatives.
22706 (fcvt_target): Add '?' to prefer w over r.
22708 2018-05-14 Jakub Jelinek <jakub@redhat.com>
22711 * config/i386/i386.md: Disallow non-commutative arithmetics in
22712 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
22713 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
22714 in the peephole2 before it.
22716 2018-05-14 Sebastian Peryt <sebastian.peryt@intel.com>
22718 * common/config/i386/i386-common.c (OPTION_MASK_ISA_CLDEMOTE_SET,
22719 OPTION_MASK_ISA_CLDEMOTE_UNSET): New defines.
22720 (ix86_handle_option): Handle -mcldemote.
22721 * config.gcc: New header.
22722 * config/i386/cldemoteintrin.h: New file.
22723 * config/i386/cpuid.h (bit_CLDEMOTE): New bit.
22724 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
22726 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
22727 OPTION_MASK_ISA_CLDEMOTE.
22728 * config/i386/i386.c (ix86_target_string): Add -mcldemote.
22729 (ix86_valid_target_attribute_inner_p): Ditto.
22730 (enum ix86_builtins): Add IX86_BUILTIN_CLDEMOTE.
22731 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_cldemote.
22732 (ix86_expand_builtin): Expand IX86_BUILTIN_CLDEMOTE.
22733 * config/i386/i386.h (TARGET_CLDEMOTE, TARGET_CLDEMOTE_P): New.
22734 * config/i386/i386.md (UNSPECV_CLDEMOTE): New.
22736 * config/i386/i386.opt: Add -mcldemote.
22737 * config/i386/x86intrin.h: New header.
22738 * doc/invoke.texi: Add -mcldemote.
22740 2018-05-14 Richard Biener <rguenther@suse.de>
22742 * doc/match-and-simplify.texi: Adjust :s documentation.
22744 2018-05-14 Alexander Monakov <amonakov@ispras.ru>
22746 * sort.cc (REORDER_23): Pass the type for the temporaries instead of
22747 intended memcpy size.
22748 (REORDER_45): Likewise.
22750 2018-05-13 Alexander Monakov <amonakov@ispras.ru>
22752 * sort.cc: New file.
22753 * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
22754 * vec.c (qsort_chk): Use gcc_qsort.
22755 * Makefile.in (OBJS-libcommon): Add sort.o.
22756 (build/sort.o): New target. Use it...
22757 (BUILD_RTL): ... here, and...
22758 (build/gencfn-macros): ... here, and...
22759 (build/genmatch): ... here.
22761 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
22762 Chung-Ju Wu <jasonwucj@gmail.com>
22764 * config.gcc (nds32*-*-*): Check that n15 is valid to --with-cpu.
22765 * config/nds32/nds32-graywolf.md: New file.
22766 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_GRAYWOLF.
22767 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n15
22769 * config/nds32/nds32-protos.h: More declarations for n15 pipeline.
22770 * config/nds32/nds32-utils.c: More implementations for n15 pipeline.
22771 * config/nds32/nds32.md (pipeline_model): Add graywolf.
22772 * config/nds32/nds32.opt (mcpu): Support n15 pipeline cpus.
22773 * config/nds32/pipelines.md: Include n15 settings.
22775 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
22776 Chung-Ju Wu <jasonwucj@gmail.com>
22778 * config.gcc (nds32*-*-*): Check that n12/n13 are valid to --with-cpu.
22779 * config/nds32/nds32-n13.md: New file.
22780 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N12 and CPU_N13.
22781 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n12/n13
22783 * config/nds32/nds32-protos.h: More declarations for n12/n13 pipeline.
22784 * config/nds32/nds32.md (pipeline_model): Add n13.
22785 * config/nds32/nds32.opt (mcpu): Support n12/n13 pipeline cpus.
22786 * config/nds32/pipelines.md: Include n13 settings.
22788 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
22789 Chung-Ju Wu <jasonwucj@gmail.com>
22791 * config.gcc (nds32*-*-*): Check that n10/d10 are valid to --with-cpu.
22792 * config/nds32/nds32-n10.md: New file.
22793 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N10.
22794 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n10
22796 * config/nds32/nds32-protos.h: More declarations for n10 pipeline.
22797 * config/nds32/nds32-utils.c: More implementations for n10 pipeline.
22798 * config/nds32/nds32.md (pipeline_model): Add n10.
22799 * config/nds32/nds32.opt (mcpu): Support n10 pipeline cpus.
22800 * config/nds32/pipelines.md: Include n10 settings.
22802 2018-05-13 Monk Chiang <sh.chiang04@gmail.com>
22803 Kito Cheng <kito.cheng@gmail.com>
22804 Chung-Ju Wu <jasonwucj@gmail.com>
22806 * config.gcc (nds32be-*-*): Handle --with-ext-dsp.
22807 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
22808 Add enum values for DSP extension instructions.
22809 * config/nds32/constraints.md (Iu06, IU06, CVp5, CVs5, CVs2, CVhi):
22811 * config/nds32/iterators.md (shifts, shiftrt, sat_plus, all_plus,
22812 sat_minus, all_minus, plus_minus, extend, sumax, sumin, sumin_max):
22813 New code iterators.
22814 (su, zs, uk, opcode, add_rsub, add_sub): New code attributes.
22815 * config/nds32/nds32-dspext.md: New file for DSP implementation.
22816 * config/nds32/nds32-intrinsic.c: Implementation of DSP extension.
22817 * config/nds32/nds32-intrinsic.md: Likewise.
22818 * config/nds32/nds32_intrinsic.h: Likewise.
22819 * config/nds32/nds32-md-auxiliary.c: Likewise.
22820 * config/nds32/nds32-memory-manipulation.c: Consider DSP extension.
22821 * config/nds32/nds32-predicates.c (const_vector_to_hwint): New.
22822 (nds32_valid_CVp5_p, nds32_valid_CVs5_p): New.
22823 (nds32_valid_CVs2_p, nds32_valid_CVhi_p): New.
22824 * config/nds32/nds32-protos.h: New declarations for DSP extension.
22825 * config/nds32/nds32-utils.c (extract_mac_non_acc_rtx): New case
22826 TYPE_DMAC in switch statement.
22827 * config/nds32/nds32.c: New checking and implementation for DSP
22828 extension instructions.
22829 * config/nds32/nds32.h: Likewise.
22830 * config/nds32/nds32.md: Likewise.
22831 * config/nds32/nds32.opt (mhw-abs, mext-dsp): New options.
22832 * config/nds32/predicates.md: Implement new predicates for DSP
22835 2018-05-11 Michael Meissner <meissner@linux.vnet.ibm.com>
22837 * config/rs6000/rs6000.md (mov<mode>_softfloat, FMOVE32):
22838 Reformat alternatives and attributes so it is easier to identify
22839 which constraints/attributes go with which instruction.
22840 (mov<mode>_hardfloat32, FMOVE64): Likewise.
22841 (mov<mode>_softfloat32, FMOVE64): Likewise.
22842 (mov<mode>_hardfloat64, FMOVE64): Likewise.
22843 (mov<mode>_softfloat64, FMOVE64): Likewise.
22845 2018-05-11 Kelvin Nilsen <kelvin@gcc.gnu.org>
22847 * doc/extend.texi (PowerPC Built-in Functions): Rename this
22849 (Basic PowerPC Built-in Functions): The new name of the
22850 subsection previously known as "PowerPC Built-in Functions".
22851 (Basic PowerPC Built-in Functions Available on all Configurations):
22853 (Basic PowerPC Built-in Functions Available on ISA 2.05): Likewise.
22854 (Basic PowerPC Built-in Functions Available on ISA 2.06): Likewise.
22855 (Basic PowerPC Built-in Functions Available on ISA 2.07): Likewise.
22856 (Basic PowerPC Built-in Functions Available on ISA 3.0): Likewise.
22858 2018-05-11 Martin Jambor <mjambor@suse.cz>
22861 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
22864 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
22867 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
22869 2018-05-11 Sebastian Peryt <sebastian.peryt@intel.com>
22871 * common/config/i386/i386-common.c (OPTION_MASK_ISA_WAITPKG_SET,
22872 OPTION_MASK_ISA_WAITPKG_UNSET): New defines.
22873 (ix86_handle_option): Handle -mwaitpkg.
22874 * config.gcc: New header.
22875 * config/i386/cpuid.h (bit_WAITPKG): New bit.
22876 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mwaitpkg.
22877 * config/i386/i386-builtin-types.def ((UINT8, UNSIGNED, UINT64)): New
22879 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
22880 OPTION_MASK_ISA_WAITPKG.
22881 * config/i386/i386.c (ix86_target_string): Add -mwaitpkg.
22882 (ix86_option_override_internal): Add PTA_WAITPKG.
22883 (ix86_valid_target_attribute_inner_p): Add -mwaitpkg.
22884 (enum ix86_builtins): Add IX86_BUILTIN_UMONITOR, IX86_BUILTIN_UMWAIT,
22885 IX86_BUILTIN_TPAUSE.
22886 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_umonitor,
22887 __builtin_ia32_umwait and __builtin_ia32_tpause.
22888 (ix86_expand_builtin): Expand IX86_BUILTIN_UMONITOR,
22889 IX86_BUILTIN_UMWAIT, IX86_BUILTIN_TPAUSE.
22890 * config/i386/i386.h (TARGET_WAITPKG, TARGET_WAITPKG_P): New.
22891 * config/i386/i386.md (UNSPECV_UMWAIT, UNSPECV_UMONITOR,
22892 UNSPECV_TPAUSE): New.
22893 (umwait, umwait_rex64, umonitor_<mode>, tpause, tpause_rex64): New.
22894 * config/i386/i386.opt: Add -mwaitpkg.
22895 * config/i386/waitpkgintrin.h: New file.
22896 * config/i386/x86intrin.h: New header.
22897 * doc/invoke.texi: Add -mwaitpkg.
22899 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
22902 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
22904 (cortex-m0): Use armv6s-m isa.
22905 (cortex-m0plus): Likewise.
22906 (cortex-m1): Likewise.
22907 (cortex-m0.small-multiply): Likewise.
22908 (cortex-m0plus.small-multiply): Likewise.
22909 (cortex-m1.small-multiply): Likewise.
22911 2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
22912 Jakub Jelinek <jakub@redhat.com>
22914 PR tree-optimization/85692
22915 * tree-ssa-forwprop.c (simplify_vector_constructor): Try two
22916 source permute as well.
22918 2018-05-11 Martin Liska <mliska@suse.cz>
22921 * doc/extend.texi: Document LLVM style format for no_sanitize
22924 2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
22926 * config/rs6000/rs6000.c (mode_supports_dq_form): Rename
22927 mode_supports_vsx_dform_quad to mode_supports_dq_form.
22928 (mode_supports_vsx_dform_quad): Likewise.
22929 (mode_supports_vmx_dform): Move these functions to be next to the
22930 other mode_supports functions.
22931 (mode_supports_dq_form): Likewise.
22932 (quad_address_p): Change calls of mode_supports_vsx_dform_quad to
22933 mode_supports_dq_form.
22934 (reg_offset_addressing_ok_p): Likewise.
22935 (offsettable_ok_by_alignment): Likewise.
22936 (rs6000_legitimate_offset_address_p): Likewise.
22937 (legitimate_lo_sum_address_p): Likewise.
22938 (rs6000_legitimize_address): Likewise.
22939 (rs6000_legitimize_reload_address): Likewise.
22940 (rs6000_secondary_reload_inner): Likewise.
22941 (rs6000_preferred_reload_class): Likewise.
22942 (rs6000_output_move_128bit): Likewise.
22944 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
22946 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
22947 Generate SImode target register for null target.
22948 <case IX86_BUILTIN_XGETBV>: Ditto.
22949 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
22950 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
22952 2018-05-10 Carl Love <cel@us.ibm.com>
22954 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
22955 dcbtt and dcbtstt if operands[2] is 0.
22957 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
22960 * config/i386/sse.md (usadv64qi): New expander.
22962 2018-05-10 Segher Boessenkool <segher@kernel.crashing.org>
22964 * config/rs6000/altivec.md (altivec_vmrghb, altivec_vmrghh,
22965 altivec_vmrghw, altivec_vmrglb, altivec_vmrglh, altivec_vmrglw): Remove
22966 -maltivec=be support.
22967 (vec_widen_umult_even_v16qi, vec_widen_smult_even_v16qi,
22968 vec_widen_umult_even_v8hi, vec_widen_smult_even_v8hi,
22969 vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
22970 vec_widen_umult_odd_v16qi, vec_widen_smult_odd_v16qi,
22971 vec_widen_umult_odd_v8hi, vec_widen_smult_odd_v8hi,
22972 vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si, altivec_vpkpx,
22973 altivec_vpks<VI_char>ss, altivec_vpks<VI_char>us,
22974 altivec_vpku<VI_char>us, altivec_vpku<VI_char>um, altivec_vsum2sws,
22975 altivec_vsumsws): Adjust.
22976 (altivec_vspltb *altivec_vspltb_internal, altivec_vsplth,
22977 *altivec_vsplth_internal, altivec_vspltw, *altivec_vspltw_internal,
22978 altivec_vspltsf, *altivec_vspltsf_internal): Remove -maltivec=be
22980 (altivec_vperm_<mode>, altivec_vperm_<mode>_uns,
22981 altivec_vupkhs<VU_char>, altivec_vupkls<VU_char>, altivec_vupkhpx,
22982 altivec_vupklpx, altivec_lvsl, altivec_lvsr): Adjust.
22983 (altivec_lve<VI_char>x): Delete expand.
22984 (*altivec_lve<VI_char>x_internal): Rename to...
22985 (altivec_lve<VI_char>x): ... this.
22986 (altivec_lvxl_<mode>): Delete expand.
22987 (*altivec_lvxl_<mode>_internal): Rename to ...
22988 (altivec_lvxl_<mode>): ... this.
22989 (altivec_stvxl_<mode>): Delete expand.
22990 (*altivec_stvxl_<mode>_internal): Rename to ...
22991 (altivec_stvxl_<mode>): ... this.
22992 (altivec_stve<VI_char>x): Delete expand.
22993 (*altivec_stve<VI_char>x_internal): Rename to ...
22994 (altivec_stve<VI_char>x): ... this.
22995 (doublee<mode>2, unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2,
22996 doubleh<mode>2, unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2,
22997 reduc_plus_scal_<mode>): Adjust.
22998 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust
23000 (rs6000_cpu_cpp_builtins): Adjust.
23001 (altivec_resolve_overloaded_builtin): Remove -maltivec=be support.
23002 * config/rs6000/rs6000-protos.h (altivec_expand_lvx_be,
23003 altivec_expand_stvx_be, altivec_expand_stvex_be): Delete.
23004 * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
23005 -maltivec=be support.
23006 (rs6000_split_vec_extract_var): Adjust.
23007 (rs6000_split_v4si_init): Adjust.
23008 (swap_selector_for_mode): Delete.
23009 (altivec_expand_lvx_be, altivec_expand_stvx_be,
23010 altivec_expand_stvex_be): Delete.
23011 (altivec_expand_lv_builtin, altivec_expand_stv_builtin): Remove
23012 -maltivec=be support.
23013 (rs6000_gimple_fold_builtin): Ditto.
23014 (rs6000_generate_float2_double_code, rs6000_generate_float2_code):
23016 * config/rs6000/rs6000.h (VECTOR_ELT_ORDER_BIG): Delete.
23017 (TARGET_DIRECT_MOVE_64BIT): Adjust.
23018 * config/rs6000/rs6000.md (split for extendsidi2 for vectors): Adjust.
23019 * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Delete.
23020 * config/rs6000/vsx.md (floate<mode>, unsfloatev2di, floato<mode>,
23021 unsfloatov2di, vsignedo_v2df, vsignede_v2df, vunsignedo_v2df,
23022 vunsignede_v2df, vsx_extract_<mode>_p9, *vsx_extract_si,
23023 *vsx_extract_<mode>_p8, *vsx_extract_si_<uns>float_df,
23024 *vsx_extract_si_<uns>float_<mode>, vsx_set_<mode>_p9, vsx_set_v4sf_p9,
23025 *vsx_insert_extract_v4sf_p9, *vsx_insert_extract_v4sf_p9_2, and an
23026 anonymous split): Adjust.
23027 (vsx_mergel_<mode>, vsx_mergeh_<mode>): Remove -maltivec=be support.
23028 (vsx_xxspltd_<mode>, extract4b, insert4b): Adjust.
23030 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
23032 * configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
23033 when --with-gxx-include-dir is also specified.
23034 * configure: Regenerate.
23036 2018-05-09 Jim Wilson <jimw@sifive.com>
23039 * config.gcc (riscv*-*-*): Handle --with-multilib-list.
23040 * config/riscv/t-withmultilib: New.
23041 * config/riscv/withmultilib.h: New.
23042 * doc/install.texi: Document RISC-V --with-multilib-list support.
23044 2018-05-09 Richard Biener <rguenther@suse.de>
23046 * tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
23048 (vect_bb_vectorization_profitable_p): Adjust. Compute
23049 actual scalar cost using the cost vector and the add_stmt_cost
23052 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23054 PR rtl-optimization/85645
23055 * config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
23056 in the REG_CFA_REGISTER note for LR, don't leave it empty.
23058 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23060 PR rtl-optimization/85645
23061 * shrink-wrap.c (spread_components): Return a boolean saying if
23062 anything was changed.
23063 (try_shrink_wrapping_separate): Iterate spread_components until
23064 nothing changes anymore.
23066 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23068 PR rtl-optimization/85645
23069 * regrename.c (build_def_use): Also kill the chains that include the
23070 destination of a REG_CFA_REGISTER note.
23072 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23074 PR rtl-optimization/85645
23075 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
23076 insn that has a REG_CFA_REGISTER note.
23078 2018-05-09 Richard Sandiford <richard.sandiford@linaro.org>
23080 * cfgexpand.c (expand_clobber): New function.
23081 (expand_gimple_stmt_1): Use it.
23082 * tree-vect-stmts.c (vect_clobber_variable): New function,
23084 (vectorizable_simd_clone_call): ...here.
23085 (vectorizable_store): Emit a clobber either side of an
23086 IFN_STORE_LANES sequence.
23087 (vectorizable_load): Emit a clobber after an IFN_LOAD_LANES sequence.
23089 2018-05-09 Tom de Vries <tom@codesourcery.com>
23092 * config/nvptx/nvptx.md (define_insn "trap", define_insn "trap_if_true")
23093 (define_insn "trap_if_false"): Add exit after trap.
23095 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
23097 PR rtl-optimization/85638
23098 * bb-reorder.c: Include common/common-target.h.
23099 (create_forwarder_block): New function extracted from...
23100 (fix_up_crossing_landing_pad): ...here. Rename into...
23101 (dw2_fix_up_crossing_landing_pad): ...this.
23102 (sjlj_fix_up_crossing_landing_pad): New function.
23103 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
23104 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
23105 from both partitions and exit the loop after one iteration.
23107 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
23110 * doc/extend.texi (PowerPC Built-in Functions): Rename this
23112 (Basic PowerPC Built-in Functions): The new name of the
23113 subsection previously known as "PowerPC Built-in Functions".
23114 (Basic PowerPC Built-in Functions Available on all Configurations):
23116 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
23118 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
23120 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
23122 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
23125 2018-05-08 Jim Wilson <jimw@sifive.com>
23127 * config/riscv/linux.h (MUSL_ABI_SUFFIX): Delete unnecessary backslash.
23128 (LD_EMUL_SUFFIX): New.
23129 (LINK_SPEC): Use it.
23131 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
23133 * doc/extend.texi (PowerPC Built-in Functions): Rename this
23135 (Basic PowerPC Built-in Functions): The new name of the
23136 subsection previously known as "PowerPC Built-in Functions".
23137 (Basic PowerPC Built-in Functions Available on all Configurations):
23139 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
23141 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
23143 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
23145 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
23148 2018-05-08 Jakub Jelinek <jakub@redhat.com>
23151 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
23152 after cmpelim optimization.
23154 2018-05-08 Olga Makhotina <olga.makhotina@intel.com>
23156 * config.gcc: Support "goldmont".
23157 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "goldmont".
23158 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
23159 PROCESSOR_GOLDMONT.
23160 * config/i386/i386.c (m_GOLDMONT): Define.
23161 (processor_target_table): Add "goldmont".
23162 (PTA_GOLDMONT): Define.
23163 (ix86_lea_outperforms): Add TARGET_GOLDMONT.
23164 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT.
23165 (fold_builtin_cpu): Add M_INTEL_GOLDMONT.
23166 (fold_builtin_cpu): Add "goldmont".
23167 (ix86_add_stmt_cost): Add TARGET_GOLDMONT.
23168 (ix86_option_override_internal): Add "goldmont".
23169 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT.
23170 (processor_type): Add PROCESSOR_GOLDMONT.
23171 * config/i386/i386.md: Add CPU "glm".
23172 * config/i386/glm.md: New file.
23173 * config/i386/x86-tune.def: Add m_GOLDMONT.
23174 * doc/invoke.texi: Add goldmont as x86 -march=/-mtune= CPU type.
23176 2018-05-08 Jakub Jelinek <jakub@redhat.com>
23179 * config/i386/i386.c (ix86_expand_sse2_abs): Handle E_V2DImode and
23181 * config/i386/sse.md (abs<mode>2): Use VI_AVX2 iterator instead of
23182 VI1248_AVX512VL_AVX512BW. Handle V2DImode and V4DImode if not
23183 TARGET_AVX512VL using ix86_expand_sse2_abs. Formatting fixes.
23186 * config/i386/i386.c (ix86_fold_builtin): Handle
23187 IX86_BUILTIN_{,P}MOVMSK{PS,PD,B}{,128,256}.
23190 * config/i386/sse.md (ssequaterinsnmode): New mode attribute.
23191 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): New pattern.
23193 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
23196 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
23197 (check_arch): Likewise.
23198 (check_fpu): Return the result rather than printing it.
23199 (end arch): Fix operator precedence.
23200 (end cpu): Likewise.
23201 (END): Print the result from check_fpu.
23203 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
23204 Alan Hayward <alan.hayward@arm.com>
23205 David Sherwood <david.sherwood@arm.com>
23207 * config/aarch64/aarch64-sve.md (*pred_cmp<cmp_op><mode>_combine)
23208 (*pred_cmp<cmp_op><mode>, *fcm<cmp_op><mode>_and_combine)
23209 (*fcmuo<mode>_and_combine, *fcm<cmp_op><mode>_and)
23210 (*fcmuo<mode>_and): New patterns.
23212 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
23214 * config/aarch64/iterators.md (UNSPEC_COND_LO, UNSPEC_COND_LS)
23215 (UNSPEC_COND_HI, UNSPEC_COND_HS, UNSPEC_COND_UO): Delete.
23216 (SVE_INT_CMP, SVE_FP_CMP): New code iterators.
23217 (cmp_op, sve_imm_con): New code attributes.
23218 (SVE_COND_INT_CMP, imm_con): Delete.
23219 (cmp_op): Remove above unspecs from int attribute.
23220 * config/aarch64/aarch64-sve.md (*vec_cmp<cmp_op>_<mode>): Rename
23222 (*cmp<cmp_op><mode>): ...this. Use UNSPEC_MERGE_PTRUE instead of
23223 comparison-specific unspecs.
23224 (*vec_cmp<cmp_op>_<mode>_ptest): Rename to...
23225 (*cmp<cmp_op><mode>_ptest): ...this and adjust likewise.
23226 (*vec_cmp<cmp_op>_<mode>_cc): Rename to...
23227 (*cmp<cmp_op><mode>_cc): ...this and adjust likewise.
23228 (*vec_fcm<cmp_op><mode>): Rename to...
23229 (*fcm<cmp_op><mode>): ...this and adjust likewise.
23230 (*vec_fcmuo<mode>): Rename to...
23231 (*fcmuo<mode>): ...this and adjust likewise.
23232 (*pred_fcm<cmp_op><mode>): New pattern.
23233 * config/aarch64/aarch64.c (aarch64_emit_unop, aarch64_emit_binop)
23234 (aarch64_emit_sve_ptrue_op, aarch64_emit_sve_ptrue_op_cc): New
23236 (aarch64_unspec_cond_code): Remove handling of LTU, GTU, LEU, GEU
23238 (aarch64_gen_unspec_cond, aarch64_emit_unspec_cond): Delete.
23239 (aarch64_emit_sve_predicated_cond): New function.
23240 (aarch64_expand_sve_vec_cmp_int): Use aarch64_emit_sve_ptrue_op_cc.
23241 (aarch64_emit_unspec_cond_or): Replace with...
23242 (aarch64_emit_sve_or_conds): ...this new function. Use
23243 aarch64_emit_sve_ptrue_op for the individual comparisons and
23244 aarch64_emit_binop to OR them together.
23245 (aarch64_emit_inverted_unspec_cond): Replace with...
23246 (aarch64_emit_sve_inverted_cond): ...this new function. Use
23247 aarch64_emit_sve_ptrue_op for the comparison and
23248 aarch64_emit_unop to invert the result.
23249 (aarch64_expand_sve_vec_cmp_float): Update after the above
23250 changes. Use aarch64_emit_sve_ptrue_op for native comparisons.
23252 2018-05-07 Nathan Sidwell <nathan@acm.org>
23254 * doc/invoke.texi (C++ Dialect Options): Remove -ffor-scope.
23255 * doc/extend.texi (Deprecated Features): Remove -fno-for-scope
23256 (Backwards Compatibility): Likewise.
23258 2018-05-07 Luis Machado <luis.machado@linaro.org>
23262 2018-05-07 Luis Machado <luis.machado@linaro.org>
23264 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23265 <prefetch_dynamic_strides>: New const bool field.
23266 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23267 prefetch_dynamic_strides.
23268 (exynosm1_prefetch_tune): Likewise.
23269 (thunderxt88_prefetch_tune): Likewise.
23270 (thunderx_prefetch_tune): Likewise.
23271 (thunderx2t99_prefetch_tune): Likewise.
23272 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
23274 (aarch64_override_options_internal): Update to set
23275 PARAM_PREFETCH_DYNAMIC_STRIDES.
23276 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
23277 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
23278 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
23279 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
23280 prefetch-dynamic-strides setting.
23282 2018-05-07 Luis Machado <luis.machado@linaro.org>
23284 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23285 <minimum_stride>: New const int field.
23286 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23287 minimum_stride field.
23288 (exynosm1_prefetch_tune): Likewise.
23289 (thunderxt88_prefetch_tune): Likewise.
23290 (thunderx_prefetch_tune): Likewise.
23291 (thunderx2t99_prefetch_tune): Likewise.
23292 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
23293 (aarch64_override_options_internal): Update to set
23294 PARAM_PREFETCH_MINIMUM_STRIDE.
23295 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
23296 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
23297 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
23298 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
23299 stride is constant and is below the minimum stride threshold.
23301 2018-05-07 Luis Machado <luis.machado@linaro.org>
23303 * config/aarch64/aarch64.c (qdf24xx_prefetch_tune) <l2_cache_size>: Set
23306 2018-05-07 Luis Machado <luis.machado@linaro.org>
23308 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23309 <prefetch_dynamic_strides>: New const bool field.
23310 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23311 prefetch_dynamic_strides.
23312 (exynosm1_prefetch_tune): Likewise.
23313 (thunderxt88_prefetch_tune): Likewise.
23314 (thunderx_prefetch_tune): Likewise.
23315 (thunderx2t99_prefetch_tune): Likewise.
23316 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
23318 (aarch64_override_options_internal): Update to set
23319 PARAM_PREFETCH_DYNAMIC_STRIDES.
23320 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
23321 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
23322 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
23323 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
23324 prefetch-dynamic-strides setting.
23326 2018-05-07 Luis Machado <luis.machado@linaro.org>
23328 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23329 <minimum_stride>: New const int field.
23330 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23331 minimum_stride field.
23332 (exynosm1_prefetch_tune): Likewise.
23333 (thunderxt88_prefetch_tune): Likewise.
23334 (thunderx_prefetch_tune): Likewise.
23335 (thunderx2t99_prefetch_tune): Likewise.
23336 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
23337 (aarch64_override_options_internal): Update to set
23338 PARAM_PREFETCH_MINIMUM_STRIDE.
23339 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
23340 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
23341 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
23342 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
23343 stride is constant and is below the minimum stride threshold.
23345 2018-05-06 Jakub Jelinek <jakub@redhat.com>
23348 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
23349 the type is addressable. Don't force op into register if it has
23352 2018-05-05 Roland McGrath <mcgrathr@google.com>
23355 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
23356 any section for which we don't know a specific type it should have,
23357 regardless of name. Previously this was done only for the exact
23358 names ".init_array", ".fini_array", and ".preinit_array".
23359 (default_elf_asm_named_section): Add comment about
23360 relationship with default_section_type_flags and SECTION_NOTYPE.
23361 (get_section): Don't consider it a type conflict if one side has
23362 SECTION_NOTYPE and the other doesn't, as long as neither has the
23363 SECTION_BSS et al used in the default_section_type_flags logic.
23365 2018-05-05 Tom de Vries <tom@codesourcery.com>
23368 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_3): Define.
23369 (workaround_barsyncs): New function.
23370 (nvptx_reorg): Use workaround_barsyncs.
23371 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
23372 (define_expand "nvptx_membar_cta"): New define_expand.
23373 (define_insn "*nvptx_membar_cta"): New insn.
23375 2018-05-04 Pekka Jääskeläinen <pekka.jaaskelainen@parmance.com>
23377 * brig-builtins.def: Add consts to ptrs etc. in BRIG builtin defs.
23378 To improve optimization opportunities.
23379 * builtin-types.def: The new needed builtin types for the above.
23381 2018-05-04 Richard Biener <rguenther@suse.de>
23383 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
23384 * gimple-ssa-store-merging.c
23385 (imm_store_chain_info::output_merged_store): Remove redundant create,
23386 release split_store vector contents on failure.
23387 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
23388 scalar stmt vector on cache hit.
23390 2018-05-04 Segher Boessenkool <segher@kernel.crashing.org>
23392 * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
23394 * config.gcc (powerpc-xilinx-eabi*): Remove.
23395 * config/rs6000/predicates.md (easy_fp_constant): Remove Xilinx FP
23397 (fusion_addis_mem_combo_load): Ditto.
23398 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove Xilinx
23400 (rs6000_cpu_cpp_builtins): Ditto.
23401 * config/rs6000/rs6000-linux.c
23402 (rs6000_linux_float_exceptions_rounding_supported_p): Ditto.
23403 * config/rs6000/rs6000-opts.h (enum fpu_type_t): Delete.
23404 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove Xilinx FP
23406 (rs6000_setup_reg_addr_masks): Ditto.
23407 (rs6000_init_hard_regno_mode_ok): Ditto.
23408 (rs6000_option_override_internal): Ditto.
23409 (legitimate_lo_sum_address_p): Ditto.
23410 (rs6000_legitimize_address): Ditto.
23411 (rs6000_legitimize_reload_address): Ditto.
23412 (rs6000_legitimate_address_p): Ditto.
23413 (abi_v4_pass_in_fpr): Ditto.
23414 (setup_incoming_varargs): Ditto.
23415 (rs6000_gimplify_va_arg): Ditto.
23416 (rs6000_split_multireg_move): Ditto.
23417 (rs6000_savres_strategy): Ditto.
23418 (rs6000_emit_prologue_components): Ditto.
23419 (rs6000_emit_epilogue_components): Ditto.
23420 (rs6000_emit_prologue): Ditto.
23421 (rs6000_emit_epilogue): Ditto.
23422 (rs6000_elf_file_end): Ditto.
23423 (rs6000_function_value): Ditto.
23424 (rs6000_libcall_value): Ditto.
23425 * config/rs6000/rs6000.h: Ditto.
23426 (TARGET_MINMAX_SF, TARGET_MINMAX_DF): Delete, merge to ...
23427 (TARGET_MINMAX): ... this. New.
23428 (TARGET_SF_FPR, TARGET_DF_FPR, TARGET_SF_INSN, TARGET_DF_INSN): Delete.
23429 * config/rs6000/rs6000.md: Remove Xilinx FP support.
23430 (*movsi_internal1_single): Delete.
23431 * config/rs6000/rs6000.opt (msingle-float, mdouble-float, msimple-fpu,
23432 mfpu=, mxilinx-fpu): Delete.
23433 * config/rs6000/singlefp.h: Delete.
23434 * config/rs6000/sysv4.h: Remove Xilinx FP support.
23435 * config/rs6000/t-rs6000: Ditto.
23436 * config/rs6000/t-xilinx: Delete.
23437 * config/rs6000/titan.md: Adjust for fp_type removal.
23438 * config/rs6000/vsx.md: Remove Xilinx FP support.
23439 (VStype_simple): Delete.
23440 (VSfptype_simple, VSfptype_mul, VSfptype_div, VSfptype_sqrt): Delete.
23441 * config/rs6000/xfpu.h: Delete.
23442 * config/rs6000/xfpu.md: Delete.
23443 * config/rs6000/xilinx.h: Delete.
23444 * config/rs6000/xilinx.opt: Delete.
23445 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove
23446 -msingle-float, -mdouble-float, -msimple-fpu, -mfpu=, and -mxilinx-fpu.
23448 2018-05-04 Tom de Vries <tom@codesourcery.com>
23451 * builtins.c (expand_builtin_goacc_parlevel_id_size): Handle null target
23454 2018-05-04 Richard Biener <rguenther@suse.de>
23456 PR middle-end/85627
23457 * tree-complex.c (update_complex_assignment): We are always in SSA form.
23458 (expand_complex_div_wide): Likewise.
23459 (expand_complex_operations_1): Likewise.
23460 (expand_complex_libcall): Preserve EH info of the original stmt.
23461 (tree_lower_complex): Handle removed blocks.
23462 * tree.c (build_common_builtin_nodes): Do not set ECF_NOTRHOW
23463 on complex multiplication and division libcall builtins.
23465 2018-05-04 Richard Biener <rguenther@suse.de>
23467 PR middle-end/85574
23468 * fold-const.c (negate_expr_p): Restrict negation of operand
23469 zero of a division to when we know that can happen without
23471 (fold_negate_expr_1): Likewise.
23473 2018-05-04 Jakub Jelinek <jakub@redhat.com>
23476 * real.h (real_nextafter): Declare.
23477 * real.c (real_nextafter): New function.
23478 * fold-const-call.c (fold_const_nextafter): New function.
23479 (fold_const_call_sss): Call it for CASE_CFN_NEXTAFTER and
23480 CASE_CFN_NEXTTOWARD.
23481 (fold_const_call_1): For CASE_CFN_NEXTTOWARD call fold_const_call_sss
23482 even when arg1_mode is different from arg0_mode.
23484 2018-05-03 Nathan Sidwell <nathan@acm.org>
23486 * doc/extend.texi (Deprecated Features): Remove
23487 -ffriend-injection.
23488 (Backwards Compatibility): Likewise.
23489 * doc/invoke.texi (C++ Language Options): Likewise.
23490 (C++ Dialect Options): Likewise.
23492 2018-05-03 Jakub Jelinek <jakub@redhat.com>
23495 * config/i386/avx512fintrin.h (_mm512_mullox_epi64,
23496 _mm512_mask_mullox_epi64): New intrinsics.
23498 2018-05-03 Tom de Vries <tom@codesourcery.com>
23501 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
23502 dump files): Add offload-tree.
23504 2018-05-03 Richard Biener <rguenther@suse.de>
23506 PR tree-optimization/85615
23507 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
23508 to loops not nested in BBs loop father to avoid creating multi-entry
23511 2018-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
23513 PR tree-optimization/70291
23514 * tree-complex.c (expand_complex_libcall): Add type, inplace_p
23515 arguments. Change return type to tree. Emit libcall as a new
23516 statement rather than replacing existing one when inplace_p is true.
23517 (expand_complex_multiplication_components): New function.
23518 (expand_complex_multiplication): Expand floating-point complex
23519 multiplication using the above.
23520 (expand_complex_division): Rename inner_type parameter to type.
23521 Update expand_complex_libcall call-site.
23522 (expand_complex_operations_1): Update expand_complex_multiplication
23523 and expand_complex_division call-sites.
23525 2018-05-02 Jakub Jelinek <jakub@redhat.com>
23528 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
23529 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
23530 *<shift_insn><dwi>3_doubleword_mask_1): In condition require that
23531 the highest significant bit of the shift count mask is clear. In
23532 check whether and[sq]i3 is needed verify that all significant bits
23533 of the shift count other than the highest are set.
23535 2018-05-02 Tom de Vries <tom@codesourcery.com>
23538 * builtins.def (DEF_GOACC_BUILTIN_ONLY): Define.
23539 * omp-builtins.def (BUILT_IN_GOACC_PARLEVEL_ID)
23540 (BUILT_IN_GOACC_PARLEVEL_SIZE): New builtin.
23541 * builtins.c (expand_builtin_goacc_parlevel_id_size): New function.
23542 (expand_builtin): Call expand_builtin_goacc_parlevel_id_size.
23543 * doc/extend.texi (Other Builtins): Add __builtin_goacc_parlevel_id and
23544 __builtin_goacc_parlevel_size.
23546 2018-05-02 Richard Biener <rguenther@suse.de>
23548 PR tree-optimization/85597
23549 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
23550 do not use split vect_get_vec_defs call but call vect_get_slp_defs
23553 2018-05-02 Tom de Vries <tom@codesourcery.com>
23556 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
23557 dump files): Add ltrans-tree.
23559 2018-05-02 Tom de Vries <tom@codesourcery.com>
23562 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
23563 dump files): Add wpa-ipa.
23565 2018-05-02 Segher Boessenkool <segher@kernel.crashing.org>
23567 * config.gcc (powerpc*-*-*): Remove paired.h. Unsupport the
23568 powerpc*-*-linux*paired* target.
23569 * config/rs6000/750cl.h: Delete.
23570 * config/rs6000/paired.h: Delete.
23571 * config/rs6000/paired.md: Delete.
23572 * config/rs6000/predicates.md (easy_vector_constant): Remove paired
23574 * config/rs6000/rs6000-builtin.def: Remove paired float support.
23575 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
23576 comment. Remove paired float support.
23577 * config/rs6000/rs6000-modes.def: Remove V2SF and V2SI.
23578 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
23580 * config/rs6000/rs6000-protos.h (paired_expand_vector_init,
23581 paired_emit_vector_cond_expr, paired_expand_vector_move): Delete
23583 * config/rs6000/rs6000.c: Remove paired float support.
23584 (paired_expand_vector_init, paired_expand_vector_move,
23585 paired_emit_vector_compare, paired_emit_vector_cond_expr,
23586 (paired_expand_lv_builtin, paired_expand_stv_builtin,
23587 paired_expand_builtin, paired_expand_predicate_builtin,
23588 paired_init_builtins): Delete.
23589 * config/rs6000/rs6000.h: Remove paired float support.
23590 * config/rs6000/rs6000.md: Remove paired float support.
23591 (move_from_CR_ov_bit): Delete.
23592 * config/rs6000/rs6000.opt (mpaired): Delete.
23593 * config/rs6000/t-rs6000: Remove paired.md from MD_INCLUDES.
23594 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mpaired.
23596 2018-05-02 Richard Biener <rguenther@suse.de>
23598 PR middle-end/85567
23599 * gimplify.c (gimplify_save_expr): When in SSA form allow
23600 SAVE_EXPRs to compute to SSA vars.
23602 2018-05-02 Jakub Jelinek <jakub@redhat.com>
23605 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
23606 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
23607 *<shift_insn><dwi>3_doubleword_mask_1): If and[sq]i3 is needed, don't
23608 clobber operands[2], instead use a new pseudo. Formatting fixes.
23610 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
23612 PR tree-optimization/85586
23613 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
23614 exit early for statements in the same group if the accesses are
23617 2018-05-02 Tom de Vries <tom@codesourcery.com>
23620 * lto-wrapper.c (compile_offload_image): Add "could not find mkoffload"
23623 2018-05-01 Marc Glisse <marc.glisse@inria.fr>
23625 PR tree-optimization/85143
23626 * match.pd (A<B&A<C): Extend to BIT_IOR_EXPR.
23628 2018-05-01 Tom de Vries <tom@codesourcery.com>
23631 * config/nvptx/mkoffload.c (main): Suggest using -B in "offload compiler
23632 not found" error message.
23634 2018-05-01 Tom de Vries <tom@codesourcery.com>
23637 * vec.h (VEC_ORDERED_REMOVE_IF, VEC_ORDERED_REMOVE_IF_FROM_TO): Define.
23638 * vec.c (test_ordered_remove_if): New function.
23639 (vec_c_tests): Call test_ordered_remove_if.
23640 * dwarf2cfi.c (connect_traces): Use VEC_ORDERED_REMOVE_IF_FROM_TO.
23641 * lto-streamer-out.c (prune_offload_funcs): Use VEC_ORDERED_REMOVE_IF.
23642 * tree-vect-patterns.c (vect_pattern_recog_1): Use
23643 VEC_ORDERED_REMOVE_IF.
23645 2018-05-01 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
23647 PR tree-optimization/82665
23648 * vr-values.c (vr_values::extract_range_from_binary_expr): Handle
23649 pointer subtraction where arguments come from a memchr call.
23651 2018-05-01 Jakub Jelinek <jakub@redhat.com>
23653 * configure.ac (LD_AS_NEEDED_OPTION, LD_NO_AS_NEEDED_OPTION): Use
23654 --push-state --as-needed and --pop-state instead of --as-needed and
23655 --no-as-needed if ld supports it.
23656 * configure: Regenerated.
23659 * doc/install.texi2html: Replace _002d with - and _002a with * in
23660 generated html files using sed.
23662 2018-04-30 David Malcolm <dmalcolm@redhat.com>
23665 * gcc-rich-location.c (blank_line_before_p): New function.
23666 (use_new_line): New function.
23667 (gcc_rich_location::add_fixit_insert_formatted): New function.
23668 * gcc-rich-location.h
23669 (gcc_rich_location::add_fixit_insert_formatted): New function.
23671 2018-04-30 David Malcolm <dmalcolm@redhat.com>
23673 * selftest.c (assert_streq): Rename "expected" and "actual" to
23674 "val1" and "val2". Extend NULL-handling to cover both inputs
23675 symmetrically, while still requiring both to be non-NULL for a pass.
23676 * selftest.h (assert_streq): Rename "expected" and "actual" to
23678 (ASSERT_EQ): Likewise.
23679 (ASSERT_EQ_AT): Likewise.
23680 (ASSERT_KNOWN_EQ): Likewise.
23681 (ASSERT_KNOWN_EQ_AT): Likewise.
23682 (ASSERT_NE): Likewise.
23683 (ASSERT_MAYBE_NE): Likewise.
23684 (ASSERT_MAYBE_NE_AT): Likewise.
23685 (ASSERT_STREQ): Likewise. Clarify that both must be non-NULL for
23686 the assertion to pass.
23687 (ASSERT_STREQ_AT): Likewise.
23689 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
23691 * doc/invoke.texi (-fpie, -fPIE): Fix grammar and clarify
23692 interaction with -pie.
23694 2018-04-30 David Malcolm <dmalcolm@redhat.com>
23696 * selftest.h: Fix alphabetization of per-source-file selftest
23699 2018-04-30 Jason Merrill <jason@redhat.com>
23701 PR c++/61982 - dead stores to destroyed objects.
23702 * gimplify.c (gimplify_modify_expr): Simplify complex lvalue on LHS
23705 2018-04-30 Jason Merrill <jason@redhat.com>
23707 * tree.c (build_clobber): New.
23708 * tree.h: Declare it.
23709 * gimplify.c (gimplify_bind_expr, gimplify_target_expr): Use it.
23711 2018-04-30 David Malcolm <dmalcolm@redhat.com>
23713 * diagnostic-show-locus.c (layout::layout): Update for
23714 location_get_source_line returning a char_span.
23715 (struct char_span): Move to input.h.
23716 (struct correction): Update for fields in char_span becoming
23718 (struct source_line): Update for location_get_source_line
23719 returning a char_span.
23720 (layout::print_line): Likewise.
23721 * edit-context.c (edited_file::print_content): Likewise.
23722 (edited_file::print_diff_hunk): Likewise.
23723 (edited_file::print_run_of_changed_lines): Likewise.
23724 (edited_file::get_num_lines): Likewise.
23725 (edited_line::edited_line): Likewise.
23726 * final.c (asm_show_source): Likewise.
23727 * input.c (location_get_source_line): Convert return type
23728 from const char * to char_span, losing the final "line_len"
23730 (dump_location_info): Update for the above.
23731 (get_substring_ranges_for_loc): Likewise. Use a char_span
23732 when handling the literal within the line.
23733 (test_reading_source_line): Update for location_get_source_line
23734 returning a char_span.
23735 * input.h (class char_span): Move here from
23736 diagnostic-show-locus.c, converting from a struct to a class.
23737 Make data members private.
23738 (char_span::operator bool): New.
23739 (char_span::length): New.
23740 (char_span::get_buffer): New.
23741 (char_span::operator[]): New.
23742 (char_span::subspan): Make const.
23743 (char_span::xstrdup): New.
23744 (location_get_source_line): Convert return type from const char *
23745 to char_span, losing the final "line_size" param.
23747 2018-04-30 Jan Hubicka <jh@suse.cz>
23749 * lto-wrapper.c (ltrans_priorities): New static var.
23750 (cmp_priority): New.
23751 (run_gcc): Read priorities and if doing parallel build order
23752 the Makefile by them.
23754 2018-04-30 David Malcolm <dmalcolm@redhat.com>
23756 * input.h (builtins_location_check): Convert to a STATIC_ASSERT.
23758 2018-04-30 Richard Biener <rguenther@suse.de>
23760 * tree-cfg.c (verify_address): Remove base argument, add
23761 flag whether to check TREE_ADDRESSABLE and do that.
23762 (verify_expr): Remove.
23763 (verify_types_in_gimple_reference): Add pieces from verify_expr.
23764 (verify_gimple_assign_single): Likewise.
23765 (verify_gimple_switch): Likewise.
23766 (verify_expr_location_1): Dereference tp once. Add (disabled)
23767 piece from verify_expr.
23768 (verify_gimple_in_cfg): Do not call verify_expr on all ops.
23770 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
23772 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
23774 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
23776 * config/arc/arc-protos.h (prepare_extend_operands): Remove.
23777 (small_data_pattern): Likewise.
23778 (arc_rewrite_small_data): Likewise.
23779 * config/arc/arc.c (LEGITIMATE_SMALL_DATA_OFFSET_P): Remove.
23780 (LEGITIMATE_SMALL_DATA_ADDRESS_P): Likewise.
23781 (get_symbol_alignment): New function.
23782 (legitimate_small_data_address_p): Likewise.
23783 (legitimate_scaled_address): Update, call
23784 legitimate_small_data_address_p.
23785 (output_sdata): New static variable.
23786 (arc_print_operand): Update how we handle small data operands.
23787 (arc_print_operand_address): Likewise.
23788 (arc_legitimate_address_p): Update, use
23789 legitimate_small_data_address_p.
23790 (arc_rewrite_small_data_p): Remove.
23791 (arc_rewrite_small_data_1): Likewise.
23792 (arc_rewrite_small_data): Likewise.
23793 (small_data_pattern): Likewise.
23794 (compact_sda_memory_operand): Update to use
23795 legitimate_small_data_address_p and get_symbol_alignment.
23796 (prepare_move_operands): Don't rewite sdata pattern.
23797 (prepare_extend_operands): Remove.
23798 * config/arc/arc.md (zero_extendqihi2): Don't rewrite sdata
23800 (zero_extendqisi2): Likewise.
23801 (zero_extendhisi2): Likewise.
23802 (extendqihi2): Likewise.
23803 (extendqisi2): Likewise.
23804 (extendhisi2): Likewise.
23805 (addsi3): Likewise.
23806 (subsi3): Likewise.
23807 (andsi3): Likewise.
23808 * config/arc/constraints.md (Usd): Change it to memory constraint.
23810 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
23812 * config/arc/arc.c (arc_split_move): Allow signed 6-bit constants
23813 as source of std instructions.
23814 * config/arc/arc.md (movsi_insn): Update pattern predicate to
23815 allow 6-bit constants as source for store instructions.
23816 (movdi_insn): Update instruction pattern to allow 6-bit constants
23817 as source for store instructions.
23819 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
23821 * doc/invoke.texi (-fdebug-types-section): Fix grammar.
23823 2018-04-30 Nathan Sidwell <nathan@acm.org>
23824 Sandra Loosemore <sandra@codesourcery.com>
23826 * dumpfile.c (dump_open): Allow '-' for stdout.
23827 * doc/invoke.texi (Developer Options): Document dump filename
23828 determination early. Document stdin/stdout selection.
23830 2018-04-30 Andrew Sadek <andrew.sadek.se@gmail.com>
23832 Microblaze Target: PIC data text relative
23834 * config/microblaze/microblaze.opt: add new option -mpic-data-text-rel.
23835 * config/microblaze/microblaze-protos.h (microblaze_constant_address_p):
23837 * config/microblaze/microblaze.h (microblaze_constant_address_p):
23838 CONSTANT_ADDRESS_P definition to microblaze_constant_address_p.
23839 * config/microblaze/microblaze.c (TARGET_PIC_DATA_TEXT_REL):
23840 New addressing mode for data-text relative position indepenedent code.
23841 (microblaze_classify_unspec): add 'UNSPEC_TEXT' case ->
23842 'ADDRESS_SYMBOLIC_TXT_REL'.
23843 (microblaze_classify_address): Add handling for UNSPEC + CONST_INT.
23844 (microblaze_legitimate_pic_operand): Exclude function calls from
23845 pic operands in case of TARGET_PIC_DATA_TEXT_REL option.
23846 (microblaze_legitimize_address): Generate 'UNSPEC_TEXT' for all possible
23848 (microblaze_address_insns): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
23849 (print_operand): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
23850 (print_operand_address): Add 'ADDRESS_SYMBOLIC_TXT_REL' case + handling
23851 for 'address + offset'.
23852 (microblaze_expand_prologue): Add new function prologue call for
23854 (microblaze_asm_generate_pic_addr_dif_vec): Override new target hook
23855 'TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC' to disable address diff vector
23856 table in case of TARGET_PIC_DATA_TEXT_REL.
23857 (expand_pic_symbol_ref): Add handling for 'UNSPEC_TEXT'.
23858 * config/microblaze/microblaze.md (TARGET_PIC_DATA_TEXT_REL):
23859 Add new macros 'UNSPEC_TEXT',
23860 'UNSPEC_SET_TEXT' + add rule for setting r20 in function prologue
23861 + exclude function calls from 'UNSPEC_PLT' in case of data text
23863 * doc/tm.texi.in (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
23864 new target hook for generating address diff vector tables in case of
23866 * doc/tm.texi : Regenerate.
23867 * stmt.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Append new condition
23868 'targetm.asm_out.generate_pic_addr_diff_vec' to flag_pic in case
23869 of addr diff vector generation.
23870 * target.def (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
23871 target hook definition.
23872 * targhooks.h, targhooks.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC):
23873 Add default function for generate_pic_addr_diff_vec -> flag_pic.
23874 * doc/invoke.texi (Add new pic option): Add new microblaze pic
23875 option for data text relative.
23877 2018-04-30 Richard Biener <rguenther@suse.de>
23879 * tree-chrec.h (evolution_function_is_constant_p): Remove
23881 * tree-cfg.c (tree_node_can_be_shared): Re-order checks.
23883 2018-04-30 Richard Biener <rguenther@suse.de>
23886 * dwarf2out.c (gen_producer_string): Ignore -fchecking[=].
23888 2018-04-30 Richard Biener <rguenther@suse.de>
23890 PR tree-optimization/28364
23891 PR tree-optimization/85275
23892 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
23893 copying first exit test.
23895 2018-04-28 Mark Wielaard <mark@klomp.org>
23897 * dwarf2out.c (dwarf2out_finish): Add .debug_addr table header for
23898 dwarf_version >= 5.
23899 (dwarf_AT): Handle DW_AT_addr_base.
23900 (add_top_level_skeleton_die_attrs): Use dwarf_AT for DW_AT_addr_base.
23902 2018-04-28 Uros Bizjak <ubizjak@gmail.com>
23905 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask): New pattern.
23906 (*ashl<dwi>3_doubleword_mask_1): Ditto.
23907 (*<shift_insn><dwi>3_doubleword_mask): Ditto.
23908 (*<shift_insn><dwi>3_doubleword_mask_1): Ditto.
23910 2018-04-28 Richard Biener <rguenther@suse.de>
23912 * tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
23913 (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
23914 to reflect use. Only add interesting stmts.
23916 2018-04-27 Martin Jambor <mjambor@suse.cz>
23919 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
23920 the jump function allows for passing through aggregate values.
23922 2018-04-27 David Malcolm <dmalcolm@redhat.com>
23924 * input.h (in_system_header_at): Convert from macro to inline
23926 (from_macro_expansion_at): Likewise.
23927 (from_macro_definition_at): Likewise.
23929 2018-04-27 Jeff Law <law@redhat.com>
23931 * config.gcc: Mark tile* targets as deprecated/obsolete.
23933 2018-04-27 Richard Biener <rguenther@suse.de>
23935 * config/aarch64/aarch64.c: Simplify ap.__stack advance and
23938 2018-04-27 Richard Biener <rguenther@suse.de>
23940 * tree-cfg.c (verify_expr): Make dead code hit gcc_unreachable.
23942 2018-04-27 Uros Bizjak <ubizjak@gmail.com>
23944 * config/i386/i386.md (*movti_internal): Substitute Ye constraint
23945 with Yd constraint. Set "preferred_for_speed" attribute from
23946 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for alternatives
23947 with Yd constraint.
23948 (*movdi_internal): Ditto.
23949 (movti_interunit splitters): Remove
23950 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC from insn condition.
23951 (movdi_interunit splitters): Ditto.
23952 * config/i386/constraints.md (Ye): Remove.
23953 (Yd): Do not depend on TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC.
23955 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
23958 * config/aarch64/constraints.md (Usg): Limit to 31.
23959 (Usj): Limit to 63.
23961 2018-04-27 Jakub Jelinek <jakub@redhat.com>
23963 PR tree-optimization/85529
23964 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
23965 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
23966 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
23967 zero extension or masking of the MSB bit.
23968 (optimize_range_tests): Add FIRST_BB argument, pass it through
23969 to optimize_range_tests_var_bound.
23970 (maybe_optimize_range_tests, reassociate_bb): Adjust
23971 optimize_range_tests callers.
23973 2018-04-26 Richard Biener <rguenther@suse.de>
23974 Jakub Jelinek <jakub@redhat.com>
23976 * cgraph.h (symbol_table): Just declare debug method here.
23977 * symtab.c (symbol_table::debug): Define.
23979 2018-04-26 Eric Botcazou <ebotcazou@adacore.com>
23981 * loop-invariant.c (may_assign_reg_p): Return false for frame pointer.
23983 2018-04-26 Uros Bizjak <ubizjak@gmail.com>
23985 * config/i386/i386.md ("isa" attribute): Add x64_sse2.
23986 ("enabled" attribute): Handle x64_sse2 "isa" attribute.
23987 (*movdi_internal): Substitute Yi and Yj constraint with x
23988 and Ym and Yn constraint with y constraint. Update "isa"
23989 attribute and set "preferred_for_speed" attribute from
23990 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for updated alternatives.
23991 (*movsi_internal): Ditto.
23992 (*movdf_internal): Ditto.
23993 (*movsf_internal): Ditto.
23994 (*zero_extendsidi2): Ditto.
23995 * config/i386/sse.md (vec_set<mode>_0): Ditto.
23996 (sse2_loadld): Ditto.
23997 (*vec_extract<ssevecmodelower>_0): Ditto.
23998 (*vec_extractv4si_0_zext_sse4): Ditto.
23999 (vec_concatv2di): Ditto.
24000 (*vec_dup<mode>): Ditto.
24001 * config/i386/mmx.md (*mov<mode>_internal): Ditto.
24002 * config/i386/constraints.md (Yi): Remove.
24007 2018-04-26 Nathan Sidwell <nathan@acm.org>
24009 * dumpfile.c (dump_open): New.
24010 (dump_open_alternate_stream, dump_start, dump_begin): Call it.
24011 (dump_finish): Detect stdio/stderr by value not name.
24013 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
24015 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
24017 2018-04-26 Tom de Vries <tom@codesourcery.com>
24020 * config/nvptx/nvptx.c (verify_neutering_jumps)
24021 (verify_neutering_labels): New function
24022 (nvptx_single): Use verify_neutering_jumps and verify_neutering_labels.
24024 2018-04-26 Tom de Vries <tom@codesourcery.com>
24027 * config/nvptx/nvptx.c (needs_neutering_p): New function.
24028 (nvptx_single): Use needs_neutering_p to skip over insns that do not
24031 2018-04-26 Richard Biener <rguenther@suse.de>
24032 Tom de Vries <tom@codesourcery.com>
24035 * lto-streamer-out.c (output_function): Fixup loops if required to match
24036 discovery done in the reader.
24038 2018-04-26 Richard Biener <rguenther@suse.de>
24040 PR tree-optimization/85116
24041 * tree-ssa-loop-ch.c (do_while_loop_p): A do-while loop should
24042 have a loop exit from the single latch predecessor. Remove
24043 case of header with just condition.
24044 (ch_base::copy_headers): Exclude infinite loops from any
24046 (pass_ch::execute): Record exits.
24048 2018-04-26 Richard Biener <rguenther@suse.de>
24050 * tree-vect-data-refs.c (vect_get_data_access_cost): Get
24051 prologue cost vector and pass it to vect_get_load_cost.
24052 (vect_get_peeling_costs_all_drs): Likewise.
24053 (vect_peeling_hash_get_lowest_cost): Likewise.
24054 (vect_enhance_data_refs_alignment): Likewise.
24056 2018-04-26 Richard Biener <rguenther@suse.de>
24058 PR middle-end/85450
24059 * tree-cfg.c (verify_gimple_assign_unary): Restore proper
24060 checking of integer<->pointer conversions.
24061 * omp-expand.c (expand_omp_for_static_nochunk): Avoid
24062 sign-/zero-extending pointer types.
24063 (expand_omp_for_static_chunk): Likewise.
24065 2018-03-22 Hans-Peter Nilsson <hp@axis.com>
24066 Jean Lee <xiaoyur347@gmail.com>
24068 * config/mips/mips.c (mips_asan_shadow_offset): New function.
24069 (TARGET_ASAN_SHADOW_OFFSET): Define.
24070 * config/mips/mips.h (FRAME_GROWS_DOWNWARD): Augment to also be
24071 true for -fsanitize=address.
24073 2018-04-25 Mark Wielaard <mark@klomp.org>
24075 * dwarf2out.c (file_info_cmp): Sort longer dir prefixes before
24078 2018-04-25 Jakub Jelinek <jakub@redhat.com>
24080 * config/i386/i386.md (*x86_mov<mode>cc_0_m1): Use type "alu1" rather
24081 than "alu", remove explicit "memory" and "imm_disp" attributes.
24082 (*x86_mov<mode>cc_0_m1_se, *x86_mov<mode>cc_0_m1_neg): Likewise.
24084 PR middle-end/85414
24085 * simplify-rtx.c (simplify_unary_operation_1) <case SIGN_EXTEND,
24086 case ZERO_EXTEND>: Pass SUBREG_REG (op) rather than op to
24087 gen_lowpart_no_emit.
24089 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
24092 * config/i386/i386.c (ix86_expand_builtin): Change memory
24093 operand to XI, extend p0 to Pmode.
24094 * config/i386/i386.md: Change unspec volatile and operand
24095 1 mode to XI, change operand 0 mode to P.
24097 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24099 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
24100 GET_MODE_MASK before any checking.
24101 (nds32_can_use_bset_p): Likewise.
24102 (nds32_can_use_btgl_p): Likewise.
24104 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24106 * config/nds32/nds32-doubleword.md: New define_split pattern for
24107 illegal register number.
24109 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24111 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
24113 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24115 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
24117 2018-04-25 Richard Biener <rguenther@suse.de>
24119 * lto-streamer.h (LTO_major_version): Bump to 8.
24121 2018-04-25 Jakub Jelinek <jakub@redhat.com>
24123 * BASE-VER: Set to 9.0.0.
24125 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
24127 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
24128 in __abskf2 and __powikf2.
24130 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24133 * config/aarch64/constraints.md (Usg, Usj): New constraints.
24134 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
24135 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
24136 Use the above on operand 2. Reindent.
24137 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
24139 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
24142 * common/config/i386/i386-common.c (ix86_handle_option): Don't
24144 * config/i386/i386.opt (mcet): Removed.
24145 * doc/install.texi: Remove -mcet documentation.
24146 * doc/invoke.texi: Likewise.
24148 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
24151 * doc/install.texi: Remove -mcet from bootstrap-cet.
24153 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24156 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
24157 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
24161 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
24162 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
24163 containing a CONST_VECTOR.
24165 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
24167 * doc/install.texi: Update newlib dependency for nvptx.
24169 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24172 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
24173 instead of INTVAL when shifting x left.
24175 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
24177 PR tree-optimization/85478
24178 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
24179 vect_grouped_store_supported for single element vectors.
24181 2018-04-24 Richard Biener <rguenther@suse.de>
24184 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
24185 load cost increase to the case of non-constant step.
24187 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24190 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
24191 destination if any_malformed_asm.
24193 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
24195 PR middle-end/85496
24196 * expr.c (store_field): In the bitfield case, if the value comes from
24197 a function call and is returned in registers by means of a PARALLEL,
24198 do not change the mode of the temporary unless BLKmode and VOIDmode.
24200 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
24202 PR rtl-optimization/85423
24203 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
24204 dependencies to debug insns when the previous insn is non-debug.
24206 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
24208 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
24209 enums into a single definition.
24210 (fls): Fix predicates and printing.
24213 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
24215 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
24216 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
24217 and short u6 immediate.
24218 (check_if_valid_sleep_operand): Remove.
24219 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
24221 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24223 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
24224 flag_always_save_lp condition.
24225 * config/nds32/nds32.opt (malways-save-lp): New option.
24227 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24229 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
24230 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
24231 * config/nds32/nds32.h
24232 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
24233 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
24235 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24237 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
24238 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
24240 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24241 Chung-Ju Wu <jasonwucj@gmail.com>
24243 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
24245 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
24246 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
24248 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24250 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
24252 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24254 * config/nds32/nds32-protos.h (nds32_data_alignment,
24255 nds32_local_alignment): Declare.
24256 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
24257 nds32_local_alignment): New functions.
24258 (TARGET_CONSTANT_ALIGNMENT): Define.
24259 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
24261 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24263 * config/nds32/nds32.c
24264 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
24265 (TARGET_MODES_TIEABLE_P): Likewise.
24267 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24269 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
24270 level Ofast and Og.
24272 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
24273 Chung-Ju Wu <jasonwucj@gmail.com>
24275 * config/nds32/constants.md (unspec_volatile_element): Add enum values
24276 for unaligned access.
24277 * config/nds32/nds32-intrinsic.c: Implementation of expanding
24279 * config/nds32/nds32-intrinsic.md: Likewise.
24280 * config/nds32/nds32_intrinsic.h: Likewise.
24281 * config/nds32/nds32.h (nds32_builtins): Likewise.
24282 * config/nds32/nds32.opt (munaligned-access): New option.
24283 * config/nds32/nds32.c (nds32_asm_file_start): Display
24284 flag_unaligned_access status.
24286 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
24288 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
24289 -mno-relax is present.
24290 * config/riscv/linux.h (LINK_SPEC): Ditto.
24292 2018-04-20 Martin Sebor <msebor@redhat.com>
24295 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
24297 (gimple_fold_builtin_stxcpy_chk): Same.
24298 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
24300 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
24303 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
24304 __powikf2 when long double is IEEE 128-bit.
24306 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
24308 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
24309 step to make sure stack always aligned.
24311 2018-04-20 Carl Love <cel@us.ibm.com>
24314 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
24315 size check for arg0.
24317 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
24318 Tom de Vries <tom@codesourcery.com>
24321 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
24322 Emit insns for calls too.
24323 (nvptx_find_par): Always look for worker-level predecessor insn.
24324 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
24326 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
24327 (nvptx_process_pars): Propagate frames for calls.
24329 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
24332 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
24334 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
24335 (ix86_handle_option): Don't handle OPT_mibt.
24336 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
24338 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
24340 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
24341 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
24342 (ix86_target_macros): Define __CET__ with flag_cf_protection
24343 for -fcf-protection.
24344 * config/i386/i386.c (isa2_opts): Remove -mibt.
24345 * config/i386/i386.h (TARGET_IBT): Removed.
24346 (TARGET_IBT_P): Likewise.
24347 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
24348 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
24349 * config/i386/i386.opt (mcet): Update help message.
24350 (mshstk): Likewise.
24352 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
24353 -mcet as an alias for -mshstk.
24355 2018-04-20 Richard Biener <rguenther@suse.de>
24357 PR middle-end/85475
24358 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
24359 complexity by forcing a single use of the multiply operand.
24361 2018-04-20 Martin Jambor <mjambor@suse.cz>
24364 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
24365 recursion dependency to only apply to non-clones.
24367 2018-04-20 Martin Jambor <mjambor@suse.cz>
24370 * ipa-cp.c (create_specialized_node): Check that clones of
24371 self-recursive edges exist during IPA-CP.
24373 2018-04-19 Toon Moene <toon@moene.org>
24375 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
24378 2018-04-19 Jakub Jelinek <jakub@redhat.com>
24380 PR tree-optimization/85467
24381 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
24382 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
24383 VECTOR_CST element to type.
24385 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
24388 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
24389 * config/i386/i386.md (builtin_setjmp_setup): Removed.
24390 (builtin_longjmp): Likewise.
24391 (save_stack_nonlocal): New pattern.
24392 (restore_stack_nonlocal): Likewise.
24394 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
24397 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
24398 Replace ASM_OUTPUT_LABEL with fprintf.
24400 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
24403 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
24404 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
24405 * config/i386/i386-c.c (ix86_target_macros_internal): Also
24406 define __IBT__ and __SHSTK__ for -fcf-protection.
24407 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
24409 (ix86_trampoline_init): Likewise.
24410 (x86_output_mi_thunk): Likewise.
24411 (ix86_notrack_prefixed_insn_p): Likewise.
24412 (ix86_option_override_internal): Don't disallow -fcf-protection.
24413 * config/i386/i386.md (rdssp<mode>): Also enable for
24415 (incssp<mode>): Likewise.
24416 (nop_endbr): Likewise.
24417 * config/i386/i386.opt (mcet): Change help message to built-in
24420 (mshstk): Likewise.
24421 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
24422 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
24423 enable CET built-in functions.
24425 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
24427 * common/config/i386/i386-common.c
24428 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
24429 OPTION_MASK_ISA_MOVDIRI_UNSET,
24430 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
24431 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
24432 * config.gcc (movdirintrin.h): New header.
24433 * config/i386/cpuid.h (bit_MOVDIRI,
24434 bit_MOVDIR64B): New bits.
24435 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
24437 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
24438 (VOID, PVOID, PCVOID)): New function types.
24439 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
24440 __builtin_ia32_directstoreu_u64,
24441 __builtin_ia32_movdir64b): New builtins.
24442 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
24443 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
24445 (ix86_valid_target_attribute_inner_p): Ditto.
24446 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
24447 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
24448 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
24449 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
24450 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
24451 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
24452 (movdiri<mode>, movdir64b_<mode>): New.
24453 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
24454 * config/i386/immintrin.h: Include movdirintrin.h.
24455 * config/i386/movdirintrin.h: New file.
24456 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
24458 2018-04-19 Richard Biener <rguenther@suse.de>
24460 PR middle-end/85455
24461 * cfg.c (clear_bb_flags): When loop state says we have
24462 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
24464 2018-04-19 Richard Biener <rguenther@suse.de>
24466 PR tree-optimization/84737
24467 * tree-vect-data-refs.c (vect_copy_ref_info): New function
24468 copying restrict info.
24469 (vect_setup_realignment): Use it.
24470 * tree-vectorizer.h (vect_copy_ref_info): Declare.
24471 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
24472 the first DR to all generated stores.
24473 (vectorizable_load): Likewise for loads.
24475 2018-04-19 Jakub Jelinek <jakub@redhat.com>
24477 PR tree-optimization/85446
24478 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
24479 the integral and pointer types to have the same precision.
24481 * doc/install.texi: Document --disable-cet being the default and
24484 2018-04-18 Martin Liska <mliska@suse.cz>
24486 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
24489 2018-04-18 Martin Liska <mliska@suse.cz>
24492 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
24495 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
24496 arguments if they are comparable.
24498 2018-04-18 Martin Liska <mliska@suse.cz>
24501 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
24504 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
24507 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
24510 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
24511 ENDBR after calling __morestack.
24513 2018-04-18 David Malcolm <dmalcolm@redhat.com>
24516 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
24517 by using gcc_base_ver to generate a gcc_driver_version, and use
24518 it when generating GCC_DRIVER_NAME.
24519 * configure: Regenerate.
24521 2018-04-18 Jakub Jelinek <jakub@redhat.com>
24524 * config.gcc: Obsolete powerpc*-*-*spe*.
24526 2018-04-17 Jakub Jelinek <jakub@redhat.com>
24529 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
24530 (stabstr_D): Change type of unum from unsigned int to
24531 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
24534 2018-04-17 Jim Wilson <jimw@sifive.com>
24537 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
24538 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
24539 Set arg_pointer_offset after using pretend_args_size.
24541 2018-04-17 Jakub Jelinek <jakub@redhat.com>
24543 PR rtl-optimization/85431
24544 * dse.c (record_store): Ignore zero width stores.
24547 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
24548 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
24549 __builtin_stack_restore rather than after it.
24550 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
24551 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
24552 argument instead of virtual_dynamic_stack_rtx.
24554 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
24556 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
24558 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
24559 Add note to error message to explain internal mapping of overloaded
24560 built-in function name to non-overloaded built-in function name.
24561 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
24564 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
24567 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
24568 where the inputs overlap with the output.
24570 2018-04-17 Jakub Jelinek <jakub@redhat.com>
24572 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
24573 (=v, v) alternative and explicit "memory" attribute.
24574 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
24575 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
24577 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
24578 "sselog1" type instead of "sselog".
24579 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
24580 "sselog". Remove explicit "memory" attribute.
24581 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
24582 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
24584 (vec_extract_hi_v32hi): Merge all alternatives into one, use
24585 "sselog1" type instead of "sselog". Remove explicit "memory"
24587 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
24588 use "sselog1" type instead of "sselog". Remove explicit "memory"
24590 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
24591 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
24593 (vec_extract_hi_v64qi): Merge all alternatives into one, use
24594 "sselog1" type instead of "sselog". Remove explicit "memory"
24596 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
24597 use "sselog1" type instead of "sselog". Remove explicit "memory"
24601 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
24603 PR middle-end/85414
24604 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
24607 2018-04-17 Martin Jambor <mjambor@suse.cz>
24610 * ipa-cp.c (create_specialized_node): Call
24611 expand_all_artificial_thunks if necessary.
24613 2018-04-17 Martin Liska <mliska@suse.cz>
24616 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
24617 in message, remote space in between '_G' and '('.
24619 2018-04-17 Jakub Jelinek <jakub@redhat.com>
24622 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
24623 avx512f_vmcmp<mode>3<round_saeonly_name>,
24624 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
24625 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
24626 avx512f_rndscale<mode><round_saeonly_name>,
24627 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
24628 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
24629 Use %<iptr>2 instead of %2 for -masm=intel.
24630 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
24631 avx512f_vcvttss2usi<round_saeonly_name>,
24632 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
24634 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
24635 avx512f_vcvttsd2usi<round_saeonly_name>,
24636 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
24637 Use %q1 instead of %1 for -masm=intel.
24638 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
24639 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
24640 of %3 for -masm=intel.
24641 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
24643 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
24645 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
24647 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
24648 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
24650 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
24652 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
24653 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
24654 %g1 and one with %0 and %1.
24655 (avx512er_vmrcp28<mode><round_saeonly_name>,
24656 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
24657 %1 for -masm=intel.
24658 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
24659 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
24660 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
24661 of %0 and %{%4%} for -masm=intel.
24662 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
24663 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
24664 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
24665 order of %0 and %{%5%}%{z%} for -masm=intel.
24667 2018-04-17 Jan Hubicka <jh@suse.cz>
24670 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
24672 2018-04-17 Martin Liska <mliska@suse.cz>
24675 * multiple_target.c (create_dispatcher_calls): Set apostrophes
24676 for target_clone error message. Make default implementation
24677 clone to be a local declaration.
24678 (separate_attrs): Add new argument and check for an empty
24680 (expand_target_clones): Handle it.
24681 (ipa_target_clone): Make redirection just for target_clones
24684 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
24685 Tom de Vries <tom@codesourcery.com>
24687 PR middle-end/84955
24688 * omp-expand.c (expand_oacc_for): Add dummy false branch for
24689 tiled basic blocks without omp continue statements.
24691 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
24694 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
24695 vec_extract expression as having side effects to make sure it gets
24698 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
24701 * config/i386/i386.c (get_builtin_code_for_version): Check
24704 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
24707 * config.gcc: Support "skylake".
24708 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
24710 * config/i386/i386.c (m_SKYLAKE): Define.
24711 (processor_target_table): Add "skylake".
24712 (ix86_option_override_internal): Add "skylake".
24713 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
24714 PROCESSOR_CANNONLAKE.
24715 (get_builtin_code_for_version): Fix priority for
24716 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
24717 PROCESSOR_SKYLAKE-AVX512.
24718 * config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
24719 (processor_type): Add PROCESSOR_SKYLAKE.
24721 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
24722 Jason Merrill <jason@redhat.com>
24725 * convert.c (convert_to_integer_1): Use direct recursion for
24726 enumeral types and types with a precision less than the number
24727 of bits in their mode.
24729 2018-04-16 Julia Koval <julia.koval@intel.com>
24732 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
24733 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
24735 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
24738 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
24739 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
24740 and -mno-direct-move.
24742 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
24745 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
24746 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
24747 Ensure negative shifts result in {0}.
24749 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
24751 PR rtl-optimization/79916
24752 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
24753 regs (if any) to define how to gnerate SD moves when LRA is in
24756 2018-04-13 Jakub Jelinek <jakub@redhat.com>
24758 PR rtl-optimization/85393
24759 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
24760 * except.c (expand_dw2_landing_pad_for_region): Make static.
24761 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
24762 a label and unconditional jump to old_bb, rather than
24763 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
24766 PR rtl-optimization/85376
24767 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
24768 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
24769 instead of a specific value.
24771 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
24772 Bin Cheng <bin.cheng@arm.com>
24774 PR tree-optimization/82965
24775 PR tree-optimization/83991
24776 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
24777 by_profile_only parameter.
24778 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
24779 information if the loop was predicted to iterate too many times.
24780 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
24782 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
24785 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
24788 2018-04-13 Martin Liska <mliska@suse.cz>
24789 Jakub Jelinek <jakub@redhat.com>
24791 PR middle-end/81657
24792 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
24793 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
24794 * builtins.c (expand_builtin_memory_copy_args): Use
24795 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
24796 handle dest_addr == pc_rtx.
24798 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
24801 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
24802 asked to not generate direct moves.
24803 (fix_trunc<mode>si2_stfiwx): Similar.
24804 (fix_trunc<mode>si2_internal): Similar.
24806 2018-04-12 Jakub Jelinek <jakub@redhat.com>
24809 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
24810 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
24811 lookup if dest in some wider mode is known to be const0_rtx and
24812 if so, record permanent equivalence for it to be ZERO_EXTEND of
24813 the narrower mode destination.
24815 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
24817 * lto-streamer-out.c (output_function): Revert 259346.
24818 * omp-expand.c (expand_oacc_for): Likewise.
24820 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
24822 PR rtl-optimization/85354
24823 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
24824 * sel-sched.c (sel_global_init): ... here.
24826 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
24829 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
24830 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
24831 mode for PE-COFF targets.
24832 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
24833 (i386_pe_asm_lto_end): Likewise.
24834 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
24835 (TARGET_ASM_LTO_END): Likewise.
24836 * config/i386/winnt.c (saved_debug_info_level): New static variable.
24837 (i386_pe_asm_lto_start): New function.
24838 (i386_pe_asm_lto_end): Likewise.
24840 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
24841 Richard Biener <rguenther@suse.de>
24843 PR middle-end/84955
24844 * lto-streamer-out.c (output_function): Fix CFG loop state before
24846 * omp-expand.c (expand_oacc_for): Handle calls to internal
24847 functions like regular functions.
24849 2018-04-12 Richard Biener <rguenther@suse.de>
24852 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
24853 for the early LTO debug to properly generate references to it
24854 during DIE emission. Do not re-use that for the skeleton for
24856 (dwarf2out_early_finish): Likewise.
24858 2018-04-12 Jakub Jelinek <jakub@redhat.com>
24861 * config/i386/sse.md
24862 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
24863 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
24864 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
24865 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
24866 and output is a reg, avoid creating invalid lowpart subreg, but
24867 instead split into a 512-bit move. Don't split if not AVX512VL,
24868 input is xmm16+ reg and output is a mem.
24869 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
24870 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
24871 xmm16+ reg and output is a mem.
24873 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
24875 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
24876 also for flag_dwarf2_cfi_asm.
24878 2018-04-12 Jakub Jelinek <jakub@redhat.com>
24880 PR rtl-optimization/85342
24881 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
24882 a bool scalar var inside of the loop instead. Don't try to update
24883 recog_data.operand after failed apply_change_group.
24885 2018-04-12 Tom de Vries <tom@codesourcery.com>
24888 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
24889 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
24890 array with flexible array member as array without given dimension.
24891 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
24892 argument for undefined param to true.
24894 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
24897 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
24898 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
24899 from PowerPC section.
24900 * config/rs6000/sysv4.opt (mcall-): Improve help text.
24901 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
24902 help text that is too long.
24903 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
24904 help text that is too long.
24905 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
24906 help text that is too long.
24908 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
24910 * config/alpha/alpha.md (stack_probe_internal): Rename
24911 from "probe_stack". Update all callers.
24913 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
24915 PR rtl-optimization/84566
24916 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
24917 sched_macro_fuse_insns.
24919 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
24922 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
24923 (compute_block_dependences): ... from here.
24925 2018-04-11 Jakub Jelinek <jakub@redhat.com>
24927 PR tree-optimization/85331
24928 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
24929 from int to HOST_WIDE_INT.
24931 2018-04-11 Martin Jambor <mjambor@suse.cz>
24934 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
24935 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
24936 not the same as the source val.
24937 (cgraph_edge_brings_value_p): New parameter.
24938 (gather_edges_for_value): Pass destination value to
24939 cgraph_edge_brings_value_p.
24940 (perhaps_add_new_callers): Likewise.
24941 (get_info_about_necessary_edges): Likewise and exclude values brought
24942 only by self-recursive edges.
24943 (create_specialized_node): Redirect only clones of self-calling edges.
24944 (+self_recursive_pass_through_p): New function.
24945 (find_more_scalar_values_for_callers_subset): Use it.
24946 (find_aggregate_values_for_callers_subset): Likewise.
24947 (known_aggs_to_agg_replacement_list): Removed.
24948 (decide_whether_version_node): Re-calculate known constants for all
24949 remaining context clones.
24951 2018-04-11 Richard Biener <rguenther@suse.de>
24954 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
24955 from early DWARF output.
24956 (dwarf2out_early_finish): Output line info unconditionally into
24957 early DWARF and add reference to it.
24959 2018-04-11 Jakub Jelinek <jakub@redhat.com>
24962 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
24963 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
24964 other than V2DFmode using iptr mode attribute.
24965 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
24967 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
24969 PR rtl-optimization/84659
24970 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
24972 2018-04-11 Jakub Jelinek <jakub@redhat.com>
24975 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
24977 (output_loc_list): Pass address of a dummy size variable even in the
24978 locview handling loop.
24979 (index_location_lists): Add comment on why skip_loc_list_entry can't
24982 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
24985 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
24988 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
24991 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
24992 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
24993 and -mstring-compare-inline-limit.
24995 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
24998 * config/rs6000/rs6000.md (allocate_stack): Put the residual size
24999 for stack clash protection in a register whenever we need it to be in
25002 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
25004 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
25005 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
25007 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
25010 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
25012 (mlong-double-): Ditto.
25013 * config/rs6000/sysv4.opt (msdata=): Ditto.
25014 (mtls-size=): Ditto.
25016 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
25018 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
25019 erroneous entries for
25020 "vector int vec_ldl (int, long int *)", and
25021 "vector unsigned int vec_ldl (int, unsigned long int *)".
25022 Add comments and entries for
25023 "vector bool char vec_ldl (int, bool char *)",
25024 "vector bool short vec_ldl (int, bool short *)",
25025 "vector bool int vec_ldl (int, bool int *)",
25026 "vector bool long long vec_ldl (int, bool long long *)",
25027 "vector pixel vec_ldl (int, pixel *)",
25028 "vector long long vec_ldl (int, long long *)",
25029 "vector unsigned long long vec_ldl (int, unsigned long long *)".
25030 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
25031 type tree bool_long_long_type_node and correct definition of
25032 bool_V2DI_type_node to make reference to this new type tree.
25033 (rs6000_mangle_type): Replace erroneous reference to
25034 bool_long_type_node with bool_long_long_type_node.
25035 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
25036 comments to emphasize sign distinctions for char and int types and
25037 replace RS6000_BTI_bool_long constant with
25038 RS6000_BTI_bool_long_long constant. Also add comment to restrict
25039 use of RS6000_BTI_pixel.
25040 (bool_long_type_node): Remove this macro definition.
25041 (bool_long_long_type_node): New macro definition
25043 2018-04-10 Jakub Jelinek <jakub@redhat.com>
25045 PR rtl-optimization/85300
25046 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
25047 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
25048 simplify_unary_operation fails.
25050 2018-04-10 Martin Liska <mliska@suse.cz>
25052 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
25053 cgraph_edge and ipa_ref.
25055 2018-04-10 Jakub Jelinek <jakub@redhat.com>
25059 * config/i386/sse.md
25060 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
25061 computation of the VEC_MERGE selector from mask.
25062 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
25063 Fix decoding of the VEC_MERGE selector into mask.
25065 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
25067 PR tree-optimization/85286
25068 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
25070 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
25072 * final.c (final_1): Set insn_last_address as well as
25073 insn_current_address.
25075 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25078 * explow.c (emit_stack_probe): Call validize_mem on memory location
25079 before passing it to gen_probe_stack. Create address operand and
25080 legitimize it for the probe_stack_address case.
25082 2018-04-09 Jan Hubicka <jh@suse.cz>
25085 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
25086 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
25087 * tree.c (free_lang_data_in_type): Fix handling of binfos;
25089 (free_lang_data): Rebuild type inheritance graph.
25091 2018-04-09 Martin Sebor <msebor@redhat.com>
25093 * invoke.texi (-finline-small-functions): Mention other optimization
25095 (-findirect-inlining, -fpartial-inlining): Same.
25096 (-finline-functions-called-once): Same.
25097 (-freorder-blocks-and-partition): Same.
25099 2018-04-09 Jan Hubicka <jh@suse.cz>
25102 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
25103 jumps; choose last target that matches the criteria (i.e.
25104 no partition changes for non-crossing jumps).
25105 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
25106 support for redirecting crossing jumps to non-crossing.
25108 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
25110 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
25111 also for naked functions.
25113 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
25115 * config/arc/arc.md (add_shift): New pattern.
25116 (add_shift2): Likewise.
25117 (sub_shift): Likewise.
25118 (sub_shift_cmp0_noout): Likewise.
25119 (compare_si_ashiftsi): Likewise.
25120 (xbfu_cmp0_noout): New combine pattern.
25121 (xbfu_cmp0"): Likewise.
25122 (movsi_set_cc_insn): Place the predicable variant first.
25123 (commutative_binary_cmp0_noout): Remove clobber.
25124 (commutative_binary_cmp0): New pattern.
25125 (noncommutative_binary_cmp0): Likewise.
25126 (noncommutative_binary_cmp0_noout): Likewise.
25127 (noncommutative_binary_comparison_result_used): Removed.
25128 (rsub_cmp0): New pattern.
25129 (rsub_cmp0_noout): Likewise.
25130 (extzvsi): Changed, keep only meaningful variants.
25131 (SQH, SEZ): New iterators.
25132 (SQH_postfix): New mode attribute.
25133 (SEZ_prefix): New code attribute.
25134 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
25135 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
25136 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
25137 of numerical value.
25138 (noncommutative_operator): Check the availability of barrel
25141 2018-04-09 Richard Biener <rguenther@suse.de>
25143 PR tree-optimization/85284
25144 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
25145 Only use the niter constraining form of simple_iv when the exit
25146 is always executed.
25148 2018-04-09 Tom de Vries <tom@codesourcery.com>
25151 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
25152 (define_expand "*memory_barrier"): New define_expand.
25153 (define_insn "memory_barrier"): New insn.
25155 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25157 PR rtl-optimization/80463
25158 PR rtl-optimization/83972
25159 PR rtl-optimization/83480
25161 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
25162 correct producer for the insn.
25163 (tidy_control_flow): Fixup seqnos in case of debug insns.
25165 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25167 PR rtl-optimization/83913
25169 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
25170 different sched-times when merging exprs.
25172 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25174 PR rtl-optimization/83962
25176 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
25177 tidy_fallthru_edge and tidy_control_flow.
25179 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25181 PR rtl-optimization/83530
25183 * sel-sched.c (force_next_insn): New global variable.
25184 (remove_insn_for_debug): When force_next_insn is true, also leave only
25185 next insn in the ready list.
25186 (sel_sched_region): When the region wasn't scheduled, make another pass
25187 over it with force_next_insn set to 1.
25189 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
25191 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
25193 * config/nds32/constants.md (unspec_volatile_element): Add enum values
25194 for interrupt control.
25195 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
25196 functions for interrupt control.
25197 * config/nds32/nds32-intrinsic.md: Likewise.
25198 * config/nds32/nds32_intrinsic.h: Likewise.
25199 * config/nds32/nds32.h (nds32_builtins): Likewise.
25201 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
25203 * config/nds32/nds32.c (nds32_init_machine_status,
25204 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
25205 strict_aligned_p field.
25206 (nds32_expand_to_rtl_hook): New function.
25207 (TARGET_EXPAND_TO_RTL_HOOK): Define.
25208 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
25210 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25211 Chung-Ju Wu <jasonwucj@gmail.com>
25213 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
25214 * config/nds32/nds32-n7.md: New file.
25215 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
25216 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
25218 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
25219 * config/nds32/nds32.md (pipeline_model): Add n7.
25220 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
25221 * config/nds32/pipelines.md: Include n7 settings.
25223 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25224 Chung-Ju Wu <jasonwucj@gmail.com>
25226 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
25227 * config/nds32/nds32-e8.md: New file.
25228 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
25229 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
25231 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
25232 * config/nds32/nds32.md (pipeline_model): Add e8.
25233 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
25234 * config/nds32/pipelines.md: Include e8 settings.
25236 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25237 Chung-Ju Wu <jasonwucj@gmail.com>
25239 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
25240 * config/nds32/nds32-n8.md: New file.
25241 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
25242 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
25244 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
25245 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
25246 * config/nds32/nds32.md (pipeline_model): Add n8.
25247 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
25248 * config/nds32/pipelines.md: Include n8 settings.
25250 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25251 Chung-Ju Wu <jasonwucj@gmail.com>
25253 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
25254 * config/nds32/nds32-n9-2r1w.md: New file.
25255 * config/nds32/nds32-n9-3r2w.md: New file.
25256 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
25257 nds32_register_ports): New or modify for cpu n9.
25258 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
25260 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
25261 * config/nds32/nds32-utils.c: New file.
25262 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
25263 TARGET_MUL_SLOW): Define.
25264 * config/nds32/nds32.md (pipeline_model): New attribute.
25265 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
25266 New options that support cpu n9.
25267 * config/nds32/pipelines.md: Include n9 settings.
25268 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
25270 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
25272 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
25273 information if necessary.
25274 (output_cond_branch_compare_zero): Likewise.
25275 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
25276 (nds32_target_alignment): Refine for alignment.
25277 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
25278 (FUNCTION_BOUNDARY): Modify.
25279 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
25281 * config/nds32/nds32.opt (malways-align, malign-functions): New.
25283 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
25285 * config/nds32/constants.md (unspec_volatile_element): Add values for
25286 TLB operation and data prefetch.
25287 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
25288 functions for TLB operation and data prefetch.
25289 * config/nds32/nds32-intrinsic.md: Likewise.
25290 * config/nds32/nds32_intrinsic.h: Likewise.
25291 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
25292 (nds32_print_operand): Likewise.
25293 * config/nds32/nds32.h (nds32_builtins): Likewise.
25295 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
25296 Andrew Pinski <pinsika@gcc.gnu.org>
25298 PR middle-end/82976
25299 * match.pd: Use constant_boolean_node of correct type instead of
25300 boolean_true_node or boolean_false_node for simplifying
25301 pointer comparisons to zero.
25303 2018-04-07 Jakub Jelinek <jakub@redhat.com>
25305 PR tree-optimization/80021
25306 * tree.c (verify_type_variant): Make error call in verify_variant_match
25307 translatable and remove final full stop.
25309 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
25311 * config/nds32/constants.md (unspec_volatile_element): Add
25312 UNSPEC_VOLATILE_EH_RETURN.
25313 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
25314 nds32_output_stack_pop): Support dwarf exception handling process.
25315 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
25316 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
25317 exception handling process.
25318 (nds32_compute_stack_frame): Likewise.
25319 (nds32_return_addr_rtx): Likewise.
25320 (nds32_initial_elimination_offset): Likewise.
25321 (nds32_expand_prologue): Likewise.
25322 (nds32_expand_epilogue): Likewise.
25323 (nds32_dynamic_chain_address): New function.
25324 * config/nds32/nds32.h (machine_function): Add fields for dwarf
25325 exception handling.
25326 (DYNAMIC_CHAIN_ADDRESS): Define.
25327 (EH_RETURN_DATA_REGNO): Define.
25328 (EH_RETURN_STACKADJ_RTX): Define.
25329 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
25330 patterns for dwarf exception handling.
25332 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
25334 * config/nds32/nds32.h: Clean up obsolete macros.
25336 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25338 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
25339 Add enum values for particular instructions.
25340 * config/nds32/nds32-intrinsic.c: Implementation of expanding
25341 particular intrinsic functions.
25342 * config/nds32/nds32-intrinsic.md: Likewise.
25343 * config/nds32/nds32_intrinsic.h: Likewise.
25344 * config/nds32/nds32.h (nds32_builtins): Likewise.
25345 * config/nds32/nds32.md (type): Add pbsad and pbsada.
25346 (btst, ave): New patterns for particular instructions.
25348 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25350 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
25351 Add enum values for atomic load/store and memory sync.
25352 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
25354 * config/nds32/nds32-intrinsic.md: Likewise.
25355 * config/nds32/nds32_intrinsic.h: Likewise.
25356 * config/nds32/nds32.h (nds32_builtins): Likewise.
25358 2018-04-07 Jakub Jelinek <jakub@redhat.com>
25360 PR tree-optimization/85257
25361 * fold-const.c (native_encode_vector): If not all elts could fit
25362 and off is -1, return 0 rather than offset.
25363 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
25364 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
25365 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
25366 adjust buffer in native_interpret_expr call.
25368 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25370 * config/nds32/constants.md (unspec_volatile_element): Add cache
25371 control enum values.
25372 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
25373 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
25374 * config/nds32/nds32.c (nds32_cctl_names): New.
25375 (nds32_print_operand): Handle cache control register names.
25376 * config/nds32/nds32.h (nds32_builtins): New enum values.
25377 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
25379 * config/nds32/nds32.md (type): Add mmu.
25380 * config/nds32/pipelines.md (simple_insn): Add mmu.
25382 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
25384 * config/nds32/nds32.md (type): Remove call.
25385 * config/nds32/pipelines.md (simple_insn): Likewise.
25387 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25389 * config/nds32/constants.md (unspec_volatile_element): Add
25390 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
25391 UNSPEC_VOLATILE_FMFCFG.
25392 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
25393 description for fmfcfg and fmfcsr.
25394 (bdesc_1arg): Add fmtcsr.
25395 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
25396 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
25397 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
25398 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
25399 unspec_fmfcfg): New patterns.
25400 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
25401 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
25402 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
25403 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
25404 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
25405 __nds32__fmfcfg): Define.
25407 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25409 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
25410 intrinsic register names.
25411 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
25412 intrinsic register enum values and macros.
25414 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
25416 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
25417 for load/store addressing form.
25418 (nds32_print_operand_address): Likewise.
25420 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
25423 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
25424 based on LABEL_REF. Remove useless assertion.
25425 (pic_address_needs_scratch): Fix formatting.
25426 (sparc_legitimize_pic_address): Minor tweaks.
25427 (sparc_delegitimize_address): Adjust assertion accordingly.
25428 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
25429 into symbolic_operand.
25430 (movsi_high_pic_label_ref): Likewise.
25431 (movsi_lo_sum_pic_label_ref): Likewise.
25432 (movdi_pic_label_ref): Likewise.
25433 (movdi_high_pic_label_ref): Likewise.
25434 (movdi_lo_sum_pic_label_ref): Likewise.
25436 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
25438 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
25439 custom LIB_SPEC setup.
25441 2018-04-06 Ruslan Bukin <br@bsdpad.com>
25442 Kito Cheng <kito.cheng@gmail.com>
25444 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
25445 * config/riscv/freebsd.h: New.
25447 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
25449 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
25450 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
25453 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
25454 Kito Cheng <kito.cheng@gmail.com>
25456 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
25457 nds32_output_call, nds32_symbol_binds_local_p): New functions.
25458 * config/nds32/nds32-protos.h (nds32_output_call,
25459 nds32_output_return): Declare.
25460 * config/nds32/nds32.md: Refine all the call and return patterns.
25462 2018-04-06 Jakub Jelinek <jakub@redhat.com>
25465 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
25466 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
25468 PR rtl-optimization/84872
25469 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
25470 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
25471 EDGE_CROSSING edge.
25473 2018-04-06 Tamar Christina <tamar.christina@arm.com>
25475 * expr.c (copy_blkmode_to_reg): Revert 254862.
25476 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
25478 2018-04-06 Richard Biener <rguenther@suse.de>
25480 PR middle-end/85244
25481 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
25482 after seeing a component reference with an adjacent field. Treat
25483 refs to arrays at struct end of external decls similar to
25484 refs to unconstrained commons.
25486 2018-04-06 Jakub Jelinek <jakub@redhat.com>
25489 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
25490 look through SAVE_EXPRs with non-side-effects argument. Adjust
25492 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
25495 2018-04-06 Richard Biener <rguenther@suse.de>
25497 PR middle-end/85180
25498 * alias.c (find_base_term): New wrapper around find_base_term
25499 unwinding CSELIB_VAL_PTR changes.
25500 (find_base_term): Do not restore CSELIB_VAL_PTR during the
25503 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
25505 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
25507 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
25508 constant definitions.
25509 ("nop"): lr 0,0 -> nopr r0
25510 ("nop_lr0", "nop_lr1"): New insn definitions.
25512 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
25514 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
25515 NDS32_V3PUSH_AVAILABLE_P macro.
25517 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
25518 Chung-Ju Wu <jasonwucj@gmail.com>
25520 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
25521 (nds32*-*-*): Add float and fpu_config into supported_defaults.
25522 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
25523 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
25524 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
25525 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
25526 * config/nds32/constraints.md: New constraints and checking for hard
25527 float configuration.
25528 * config/nds32/iterators.md: New mode iterator and attribute for hard
25529 float configuration.
25530 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
25532 * config/nds32/nds32-fpu.md: New file.
25533 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
25534 deal with hard float code generation.
25535 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
25537 (abi_type, float_reg_number): New enum type.
25538 * config/nds32/nds32-predicates.c: New predicates for hard float.
25539 * config/nds32/nds32-protos.h: Declare functions for hard float.
25540 * config/nds32/nds32.c: Implementation for hard float configuration.
25541 * config/nds32/nds32.h: Definitions for hard float configuration.
25542 * config/nds32/nds32.md: Include hard float machine description and
25543 modify patterns for hard float configuration.
25544 * config/nds32/nds32.opt: New options for hard float configuration.
25545 * config/nds32/predicates.md: New predicates for hard float
25548 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
25550 * common/config/nds32/nds32-common.c
25551 (nds32_option_optimization_table): Enable -mreleax-hint by default.
25553 2018-04-05 Jakub Jelinek <jakub@redhat.com>
25555 PR middle-end/85195
25556 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
25557 CONSTRUCTOR_ELT (ctor, ...)->value.
25559 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
25562 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
25564 2018-04-05 Tom de Vries <tom@codesourcery.com>
25567 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
25570 2018-04-05 Shiva Chen <shiva0217@gmail.com>
25571 Kito Cheng <kito.cheng@gmail.com>
25573 * config/nds32/constraints.md (U33): Fine-tune checking condition.
25574 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
25575 * config/nds32/nds32.h (nds32_16bit_address_type): Add
25576 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
25578 2018-04-05 Shiva Chen <shiva0217@gmail.com>
25579 Kito Cheng <kito.cheng@gmail.com>
25581 * config/nds32/constraints.md (Ufe): New memory constraint.
25582 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
25583 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
25584 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
25586 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
25587 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
25589 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
25591 * config/nds32/nds32.md: Use optimize_size in the condition for
25592 alu-shift instructions.
25594 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
25596 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
25598 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
25600 * config/nds32/nds32.md (negsi2): Refine pattern.
25602 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
25603 Chung-Ju Wu <jasonwucj@gmail.com>
25605 * config/nds32/iterators.md (shift_rotate): New code iterator.
25606 (shift): New code attribute.
25607 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
25608 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
25609 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
25610 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
25611 bit-wise operations.
25612 (andsi3, *andsi3): Ditto.
25613 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
25614 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
25615 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
25616 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
25617 nds32_ior_operand, nds32_xor_operand): New predicates.
25619 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
25621 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
25622 (addsi3, subsi3): ... this.
25624 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
25626 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
25628 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
25630 * config/nds32/nds32.md: Adjust indention.
25632 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
25634 * config/nds32/nds32.md (feature): New attribute.
25636 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
25638 * config/nds32/nds32.md (subtype): New attribute.
25640 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
25643 * config/arm/arm-builtins.c (arm_expand_builtin): Change
25644 expansion to perform a bitwise AND of the argument followed by a
25645 boolean negation of the result.
25647 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
25649 PR rtl-optimization/84878
25650 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
25651 the basic block. Assert the use reference is not artificial and that
25652 it has an associated insn.
25654 2018-04-04 Michael Matz <matz@suse.de>
25656 * builtins.c (compute_objsize): Pass correct operand
25657 to array_at_struct_end_p.
25659 2018-04-04 Richard Biener <rguenther@suse.de>
25662 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
25663 from contexts for DINFO_LEVEL_TERSE and below.
25665 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
25667 * config/nds32/nds32-doubleword.md (move_<mode>): Require
25668 resiter_operand condition.
25669 * config/nds32/nds32.md (*move<mode>): Ditto.
25671 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
25672 Monk Chiang <sh.chiang04@gmail.com>
25674 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
25676 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
25678 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
25680 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
25681 Kito Cheng <kito.cheng@gmail.com>
25683 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
25684 nds32_cond_code_str, output_cond_branch,
25685 output_cond_branch_compare_zero, nds32_expand_cbranch,
25686 nds32_expand_cstore, nds32_expand_movcc,
25687 nds32_output_cbranchsi4_equality_zero,
25688 nds32_output_cbranchsi4_equality_reg,
25689 nds32_output_cbranchsi4_equality_reg_or_const_int,
25690 nds32_output_cbranchsi4_greater_less_zero: New functions.
25691 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
25692 nds32_expand_cstore, nds32_expand_movcc,
25693 nds32_output_cbranchsi4_equality_zero,
25694 nds32_output_cbranchsi4_equality_reg,
25695 nds32_output_cbranchsi4_equality_reg_or_const_int,
25696 nds32_output_cbranchsi4_greater_less_zero): Declare.
25697 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
25698 nds32_rimm11s_operand): New predicates.
25699 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
25700 * config/nds32/nds32.md: Rewrite all the branch and conditional move
25703 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
25705 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
25706 * config/nds32/nds32.md: Ditto.
25707 * config/nds32/pipelines.md: Ditto.
25709 2018-04-04 Richard Biener <rguenther@suse.de>
25711 PR tree-optimization/85168
25712 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
25713 propagating abnormals.
25715 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
25717 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
25719 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
25720 Kito Cheng <kito.cheng@gmail.com>
25722 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
25723 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
25724 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
25725 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
25726 * config/nds32/nds32.md (sibcall_internal): New.
25727 (sibcall_register): Remove.
25728 (sibcall_immediate): Remove.
25729 (sibcall_value_internal): New.
25730 (sibcall_value_register): Remove.
25731 (sibcall_value_immediate): Remove.
25732 * config/nds32/predicates.md (nds32_general_register_operand): New.
25733 (nds32_call_address_operand): New.
25735 2018-04-03 Jakub Jelinek <jakub@redhat.com>
25737 PR rtl-optimization/85167
25738 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
25739 bb_defs if *split_p, instead preinitialize it to NULL.
25741 PR tree-optimization/85156
25742 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
25743 evaluating the argument multiple times.
25745 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
25747 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
25749 (_mm_cvtpd_ps): Likewise.
25750 (_mm_cvttpd_epi32): Likewise.
25751 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
25752 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
25753 vector, pixel, and bool following altivec.h include.
25755 2018-04-03 Martin Sebor <msebor@redhat.com>
25757 * doc/extend.texi (Common Function Attributes): Clarify.
25758 (const attribute): Likewise.
25759 (pure attribute): Likewise.
25761 2018-04-03 Jakub Jelinek <jakub@redhat.com>
25764 * config/i386/i386.c (ix86_expand_vector_set): Use
25765 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
25767 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
25769 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
25770 instructions when changing rounding bits to preserve precision bits
25771 in the x87 control word.
25773 2018-04-03 Martin Liska <mliska@suse.cz>
25775 PR tree-optimization/82491
25776 * rtl.h (strip_offset_and_add): Replace += suboffset with
25777 poly_uint64 () + suboffset.
25779 2018-03-29 Martin Liska <mliska@suse.cz>
25780 Martin Jambor <mjambor@suse.cz>
25783 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
25784 param_type is not an integral or pointer type.
25786 2018-04-03 Richard Biener <rguenther@suse.de>
25788 * sese.h (recompute_all_dominators): Remove.
25790 2018-04-02 Martin Sebor <msebor@redhat.com>
25792 * doc/invoke.texi (-Wrestrict): Fix typos.
25794 2018-04-02 Jim Wilson <jimw@sifive.com>
25796 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
25797 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
25798 (<optab>di3, <optab>si3_extend): Likewise.
25799 (<optab>si3_mask, <optab>si3_mask_1): New.
25800 (<optab>di3_mask, <optab>di3_mask_1): New.
25801 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
25802 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
25803 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
25805 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
25807 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
25810 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
25812 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
25813 (nds32_canonicalize_comparison): New function.
25815 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
25816 Kito Cheng <kito.cheng@gmail.com>
25817 Kuan-Lin Chen <kuanlinchentw@gmail.com>
25819 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
25820 * config/nds32/constants.md (unspec_volatile_element): Add
25821 UNSPEC_VOLATILE_RELAX_GROUP.
25822 * config/nds32/nds32-relax-opt.c: New file.
25823 * config/nds32/nds32-predicates.c
25824 (nds32_symbol_load_store_p): New function.
25825 * config/nds32/nds32-protos.h
25826 (nds32_symbol_load_store_p): Declare function.
25827 (make_pass_nds32_relax_opt): Declare new rtl pass function.
25828 * config/nds32/nds32.c
25829 (nds32_register_pass): New function to register pass.
25830 (nds32_register_passes): New function to register passes.
25831 * config/nds32/nds32.md (relax_group): New pattern.
25832 * config/nds32/nds32.opt (mrelax-hint): New option.
25833 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
25835 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
25837 * config/nds32/t-nds32: Modify files dependency.
25839 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
25841 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
25842 (PROFILE_HOOK): Define its implementation.
25844 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
25846 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
25847 type and 32-bit size.
25849 2018-04-01 Jakub Jelinek <jakub@redhat.com>
25851 PR middle-end/85090
25852 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
25853 (V_128_256): New mode iterator.
25854 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
25855 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
25856 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
25858 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
25859 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
25861 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
25864 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
25865 NaN inputs correctly.
25867 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
25870 * config/rs6000/vsx.md (??r): New mode attribute.
25871 (*vsx_mov<mode>_64bit): Use it.
25872 (*vsx_mov<mode>_32bit): Likewise.
25874 2018-03-30 Martin Sebor <msebor@redhat.com>
25876 PR tree-optimization/84818
25877 * builtins.c (check_access): Use warning_n.
25879 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
25882 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
25884 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
25887 2018-03-30 Julia Koval <julia.koval@intel.com>
25890 * x86-tune.def (movx, partial_reg_dependency): Enable for
25893 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
25895 PR inline-asm/84985
25896 * lra-constraints.c (process_alt_operands): Move setting
25897 this_alternative_matches below.
25899 2018-03-29 Martin Liska <mliska@suse.cz>
25902 * doc/invoke.texi: Document how LTO works with debug info.
25903 Describe auto-load support of binutils. Mention 'x86-64'
25904 as valid option value of -march option.
25906 2018-03-29 Jakub Jelinek <jakub@redhat.com>
25908 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
25911 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
25912 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
25913 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
25916 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
25919 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
25920 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
25921 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
25922 for RS6000_BTM_POWERPC64.
25923 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
25924 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
25925 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
25928 (DIVDEU): Likewise.
25930 2018-03-28 Carl Love <cel@us.ibm.com>
25933 2017-09-27 Carl Love <cel@us.ibm.com>
25935 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
25936 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
25937 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
25940 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25942 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
25943 instead of __vector bool.
25944 (_mm_max_pu8): Likewise.
25945 (_mm_min_pi16): Likewise.
25947 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
25950 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
25951 (DIVWEUO): Likewise.
25952 (DIVDEO): Likewise.
25953 (DIVDEUO): Likewise.
25954 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
25955 DIVWEUO and DIVDEUO.
25956 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
25957 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
25958 (div_extend): Likewise.
25959 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
25961 (__builtin_divweuo): Likewise.
25962 (__builtin_divdeo): Likewise.
25963 (__builtin_divdeuo): Likewise.
25965 2018-03-28 Jakub Jelinek <jakub@redhat.com>
25968 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
25969 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
25971 PR tree-optimization/82004
25972 * gimple-match-head.c (optimize_pow_to_exp): New function.
25973 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
25974 Don't fold to exp if optimize_pow_to_exp is false.
25976 2018-03-28 Martin Liska <mliska@suse.cz>
25979 * calls.c (initialize_argument_information): Fix trailing space.
25980 * common.opt: Fix typo and provide better explanation for
25981 -fsanitize-coverage option.
25982 * config/i386/i386.opt: Fix typo.
25984 2018-03-28 Jakub Jelinek <jakub@redhat.com>
25985 Martin Liska <mliska@suse.cz>
25988 * gimplify.c (asan_poison_variable): Don't do the check for
25989 gimplify_omp_ctxp here.
25990 (gimplify_decl_expr): Do it here.
25991 (gimplify_target_expr): Likewise.
25993 2018-03-28 Martin Liska <mliska@suse.cz>
25996 * config/i386/i386.c (ix86_function_arg_advance): Do not call
25997 chkp_type_bounds_count if MPX is not enabled.
25999 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
26001 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
26003 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
26006 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
26007 function to create the function decl for complex long double
26008 multiply and divide for -mabi=ieeelongdouble.
26009 (init_float128_ieee): Call it.
26011 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
26014 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
26015 -fcf-protection=branch -mibt.
26016 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
26018 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
26021 * config/arm/arm.c (arm_valid_symbolic_address): Handle
26022 arm_word_relocations.
26024 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
26027 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
26028 extern array declarations.
26030 2018-03-27 Richard Biener <rguenther@suse.de>
26032 PR middle-end/84067
26033 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
26034 explicit single_use checks.
26036 2018-03-27 Richard Biener <rguenther@suse.de>
26038 PR tree-optimization/85082
26039 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
26042 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
26044 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
26045 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
26046 Turn on fasynchronous-unwind-tables and funwind-tables.
26048 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
26051 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
26052 (*bmi_blsr_<mode>_ccz): Ditto.
26054 2018-03-26 Tom de Vries <tom@codesourcery.com>
26056 PR tree-optimization/85063
26057 * omp-general.c (offloading_function_p): New function. Factor out
26059 * omp-offload.c (pass_omp_target_link::gate): ... here.
26060 * omp-general.h (offloading_function_p): Declare.
26061 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
26062 with attribute omp declare target for offloading functions.
26064 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
26066 PR tree-optimization/84005
26067 * tree-data-ref.h (get_base_for_alignment): Declare.
26068 * tree-data-ref.c (get_base_for_alignment_1): New function.
26069 (get_base_for_alignment): Likewise.
26070 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
26071 get_base_for_alignment to find a suitable base object, instead
26072 of always using drb->base_address.
26074 2018-03-23 Jakub Jelinek <jakub@redhat.com>
26076 PR inline-asm/85022
26077 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
26078 known size by default.
26080 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
26082 PR inline-asm/85030
26083 * lra-constraints.c (process_alt_operands): Don't match BLKmode
26084 and non BLKmode operands.
26086 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26089 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
26090 Clean up attributes.
26092 2018-03-23 Richard Biener <rguenther@suse.de>
26095 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
26096 we are going to emit early debug for LTO.
26098 2018-03-23 Jakub Jelinek <jakub@redhat.com>
26100 PR inline-asm/85034
26101 * function.c (match_asm_constraints_1): Don't optimize if input
26102 doesn't satisfy general_operand predicate for output's mode.
26104 PR inline-asm/85022
26105 * alias.c (write_dependence_p): Don't require for x_canonicalized
26106 non-VOIDmode if x has VOIDmode.
26109 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
26110 just don't try to optimize it rather than assert it never happens.
26112 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
26114 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
26115 macro expansions for definition of ST_INTERNAL_<mode> and
26116 LD_INTERNAL_<mode> builtins.
26117 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
26119 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
26121 (altivec_expand_st_builtin): Likewise.
26122 (altivec_expand_builtin): Remove calls to deleted functions.
26123 (rs6000_address_for_altivec): Delete this function.
26124 * config/rs6000/vector.md: Remove expands for
26125 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
26127 2018-03-22 Sudakshina Das <sudi.das@arm.com>
26130 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
26131 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
26132 re-computing once computed.
26133 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
26134 (arm_init_machine_status): Initialize
26135 machine->static_chain_stack_bytes.
26137 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
26140 * doc/extend.texi: Add four new prototypes for vec_ld.
26141 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
26142 definitions for more logical presentation.
26143 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
26144 entries for V1TI variants of __builtin_altivec_ld builtin.
26145 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
26146 handling of V1TI variant of LVX icode pattern.
26147 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
26148 (rs6000_gimple_fold_builtin): Likewise.
26149 (altivec_init_builtins): Add code to define
26150 __builtin_altivec_lvx_v1ti function.
26152 2018-03-22 Jakub Jelinek <jakub@redhat.com>
26154 PR inline-asm/84941
26155 * function.c (match_asm_constraints_1): Don't do the optimization
26156 if input isn't a REG, SUBREG, MEM or constant.
26158 2018-03-22 Tom de Vries <tom@codesourcery.com>
26160 PR tree-optimization/84956
26161 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
26162 bb_has_abnormal_pred.
26164 2018-03-22 Jakub Jelinek <jakub@redhat.com>
26167 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
26168 DECL_INITIAL (decl) to decl at the end.
26169 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
26170 adjust the comment.
26172 2018-03-21 Joseph Myers <joseph@codesourcery.com>
26174 * doc/extend.texi (__builtin_tgmath): Document when complex
26175 integer types are treated as _Complex _Float64.
26177 2018-03-21 Tom de Vries <tom@codesourcery.com>
26179 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
26181 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26183 PR tree-optimization/84960
26184 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
26185 if it is ENTRY block, move them into single succ of ENTRY in that case.
26187 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
26189 PR tree-optimization/84811
26190 * poly-int.h (poly_span_traits): Remove the T3 parameter and
26191 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
26192 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
26193 (known_subrange_p): Update accordingly. Cast each value involved
26194 in the size comparison, rather than casting the result of the
26197 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26199 PR tree-optimization/84982
26200 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
26201 by flipping the least significant bit rather than all bits from
26202 bitpos to bitpos + bitsize - 1.
26204 2018-03-21 Nathan Sidwell <nathan@acm.org>
26206 * doc/extend.texi (Deprecated Features): Remove mention of
26207 long-deleted deprecations.
26209 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
26212 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
26213 * configure: Regenerate.
26215 2018-03-21 Tom de Vries <tom@codesourcery.com>
26217 PR tree-optimization/83126
26218 * tree-parloops.c (num_phis): New function.
26219 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
26221 2018-03-21 Nathan Sidwell <nathan@acm.org>
26223 * doc/extend.texi (Deprecated Features): Update deprecated flags,
26224 mention anon-struct/union members and trailing attributes.
26226 2018-03-21 Bin Cheng <bin.cheng@arm.com>
26228 PR tree-optimization/84969
26229 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
26230 builtin memset partitions if they set different rhs values.
26232 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26234 PR rtl-optimization/84989
26235 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
26236 VEC_DUPLICATE with scalar result mode.
26238 2018-03-21 Martin Liska <mliska@suse.cz>
26241 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
26242 not intended return statement.
26244 2018-03-21 Martin Liska <mliska@suse.cz>
26247 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
26248 (chkp_find_bound_slots_1): Limit number of iterations.
26250 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
26253 * Minor grammar fixes for x86 options.
26255 2018-03-20 Jakub Jelinek <jakub@redhat.com>
26258 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
26259 holding REG_CFA_RESTORE notes, instead turn them into a USE.
26261 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
26264 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
26265 (altivec_lvx_<mode>_1op): Likewise.
26266 (altivec_stvx_<mode>_2op): Likewise.
26267 (altivec_stvx_<mode>_1op): Likewise.
26268 (altivec_lvx_<VM2:mode>): New define_expand.
26269 (altivec_stvx_<VM2:mode>): Likewise.
26270 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
26271 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
26272 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
26273 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
26274 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
26275 (rs6000_gen_lvx): Likewise.
26276 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
26277 (altivec_expand_stv_builtin): Likewise.
26278 (altivec_expand_builtin): Likewise.
26279 * config/rs6000/vector.md: Likewise.
26281 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26284 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
26287 2018-03-20 Richard Biener <rguenther@suse.de>
26290 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
26291 sign-conversions as zero, fall back to standard scalar_stmt
26294 2018-03-20 Martin Liska <mliska@suse.cz>
26297 * predict.c (rebuild_frequencies): Handle case when we have
26298 PROFILE_ABSENT, but flag_guess_branch_prob is false.
26300 2018-03-20 Jakub Jelinek <jakub@redhat.com>
26303 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
26304 flag_section_anchors.
26305 * varasm.c (use_blocks_for_decl_p): Remove hack for
26306 dw2_force_const_mem.
26309 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
26311 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
26312 be created, use lowpart_subreg of operands[0] rather than operands[0]
26314 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
26315 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
26316 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
26317 and n constraint instead of aarch64_shift_imm_di and Usd.
26318 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
26319 (*aarch64_<optab>_reg_minus<mode>3): ... this.
26321 2018-03-20 Sudakshina Das <sudi.das@arm.com>
26324 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
26325 to favor GPR over NEON registers.
26326 (<shift>di3_neon): Likewise.
26328 2018-03-20 Tom de Vries <tom@codesourcery.com>
26331 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
26332 (nvptx_process_pars): Emit bar.sync asap and alap.
26334 2018-03-20 Tom de Vries <tom@codesourcery.com>
26337 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
26338 seen_label if seen_label is already set.
26340 2018-03-20 Jakub Jelinek <jakub@redhat.com>
26343 * config/i386/i386.c (fold_builtin_cpu): For features above 31
26344 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
26345 Use 1U instead of 1. Formatting fixes.
26348 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
26349 instead of TREE_TYPE (s1) for the return value.
26351 2018-03-19 Jakub Jelinek <jakub@redhat.com>
26353 PR tree-optimization/84946
26354 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
26355 bitsize + bitsize in poly_uint64 rather than poly_int64.
26358 * dwarf2asm.c: Include fold-const.c.
26359 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
26360 of decl rather than decl itself.
26362 PR rtl-optimization/84643
26363 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
26365 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
26368 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
26369 calling assemble_variable.
26371 2018-03-19 Sudakshina Das <sudi.das@arm.com>
26374 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
26375 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
26377 2018-03-19 Jim Wilson <jimw@sifive.com>
26380 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
26381 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
26382 (riscv_first_stack_step): Likewise.
26383 (riscv_option_override): Use STACK_BOUNDARY instead of
26384 MIN_STACK_BOUNDARY.
26385 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
26386 MIN_STACK_BOUNDARY.
26387 (BIGGEST_ALIGNMENT): Set to 128.
26388 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
26389 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
26392 2018-03-19 Richard Biener <rguenther@suse.de>
26394 PR tree-optimization/84933
26395 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
26396 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
26398 2018-03-19 Richard Biener <rguenther@suse.de>
26400 PR tree-optimization/84859
26401 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
26402 (cond_if_else_store_replacement): Perform sinking operation on
26403 single-store BBs regardless of MAX_STORES_TO_SINK setting.
26404 Generalize what a BB with a single eligible store is.
26406 2018-03-19 Richard Biener <rguenther@suse.de>
26408 PR tree-optimization/84929
26409 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
26410 chrec_is_positive against non-chrec arg.
26412 2018-03-19 Tamar Christina <tamar.christina@arm.com>
26415 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
26417 2018-03-18 Martin Liska <mliska@suse.cz>
26419 PR rtl-optimization/84635
26420 * regrename.c (build_def_use): Use matches_mode only when
26423 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
26425 PR tree-optimization/84913
26426 * tree-vect-loop.c (vectorizable_reduction): Don't try to
26427 vectorize chains of COND_EXPRs.
26429 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
26431 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
26433 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
26435 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
26437 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
26439 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
26441 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
26442 Kito Cheng <kito.cheng@gmail.com>
26444 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
26445 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
26446 (nds32_adjust_reg_alloc_order): New function.
26447 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
26449 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
26451 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
26452 nds32_print_operand, nds32_print_operand_address): Use
26453 HOST_WIDE_INT_PRINT_DEC instead.
26455 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
26457 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
26459 2018-03-17 Jakub Jelinek <jakub@redhat.com>
26462 * config/i386/i386.c (initial_ix86_tune_features,
26463 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
26464 unsigned long long.
26465 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
26466 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
26467 rather than 1u << ix86_tune. Formatting fix.
26468 (ix86_option_override_internal): Change ix86_arch_mask from
26469 unsigned int to unsigned HOST_WIDE_INT, initialize to
26470 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
26471 (ix86_function_specific_restore): Likewise.
26473 2018-03-16 Jakub Jelinek <jakub@redhat.com>
26476 * postreload.c (reload_combine_recognize_pattern): Perform
26477 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
26478 truncate_int_for_mode the result for the destination's mode.
26481 * hsa-gen.c (mem_type_for_type): Fix comment typo.
26482 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
26484 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
26487 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
26490 * lra-assigns.c (lra_split_hard_reg_for): Don't use
26491 regno_allocno_class_array and sorted_pseudos.
26492 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
26493 insns where regno is used.
26495 2018-03-16 Martin Liska <mliska@suse.cz>
26498 * multiple_target.c (create_dispatcher_calls): Redirect
26499 reference in the symbol table.
26501 2018-03-16 Martin Liska <mliska@suse.cz>
26504 * multiple_target.c (create_dispatcher_calls): Redirect also
26507 2018-03-16 Jakub Jelinek <jakub@redhat.com>
26511 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
26512 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
26513 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
26515 2018-03-16 Julia Koval <julia.koval@intel.com>
26517 * doc/invoke.texi (Skylake Server): Add CLWB.
26518 Cannonlake): Remove CLWB.
26520 2018-03-16 Jakub Jelinek <jakub@redhat.com>
26522 PR tree-optimization/84841
26523 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
26525 (FLOAT_ONE_CONST_TYPE): Define.
26526 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
26527 (sort_by_operand_rank): Put entries with higher constant_type last
26528 rather than first to match comments.
26530 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
26532 * config/nios2/nios2.md (movsi_internal): Fix thinko in
26535 2018-03-15 Jakub Jelinek <jakub@redhat.com>
26538 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
26539 check and use address of target always.
26541 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
26544 * config/i386/i386.c (indirect_thunk_needed): Update comments.
26545 (indirect_thunk_bnd_needed): Likewise.
26546 (indirect_thunks_used): Likewise.
26547 (indirect_thunks_bnd_used): Likewise.
26548 (indirect_return_needed): New.
26549 (indirect_return_bnd_needed): Likewise.
26550 (output_indirect_thunk_function): Add a bool argument for
26552 (output_indirect_thunk_function): Don't generate alias for
26553 function return thunk.
26554 (ix86_code_end): Call output_indirect_thunk_function to generate
26555 function return thunks.
26556 (ix86_output_function_return): Set indirect_return_bnd_needed
26557 and indirect_return_needed instead of indirect_thunk_bnd_needed
26558 and indirect_thunk_needed.
26560 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
26562 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
26563 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
26564 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
26566 2018-03-15 David Malcolm <dmalcolm@redhat.com>
26567 Paul Hua <paul.hua.gm@gmail.com>
26570 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
26572 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
26574 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
26575 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
26576 resp. SFmode cases.
26578 2018-03-15 Tamar Christina <tamar.christina@arm.com>
26581 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
26582 instead of GET_MODE_SIZE when comparing Units.
26584 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
26587 * varasm.c (hash_section): Return an unchangeble hash value
26588 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
26589 Return !aarch64_can_use_per_function_literal_pools_p ().
26591 2018-03-15 Jakub Jelinek <jakub@redhat.com>
26594 * optabs.c (emit_conditional_move): Pass address of cmode's copy
26595 rather than address of cmode as last argument to prepare_cmp_insn.
26597 2018-03-15 Julia Koval <julia.koval@intel.com>
26599 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
26600 F_AVX512VNNI, F_AVX512BITALG): New.
26602 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
26605 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
26606 insn for floating-point loads and stores.
26608 2018-03-14 Carl Love <cel@us.ibm.com>
26610 * config/rs6000/rs6000-c.c: Add macro definitions for
26611 ALTIVEC_BUILTIN_VEC_PERMXOR.
26612 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
26613 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
26614 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
26615 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
26617 * config/doc/extend.texi: Add prototypes for vec_permxor.
26619 2018-03-14 David Malcolm <dmalcolm@redhat.com>
26622 * diagnostic-show-locus.c (class layout_point): Convert m_line
26623 from int to linenum_type.
26624 (line_span::comparator): Use linenum "compare" function when
26625 comparing line numbers.
26626 (test_line_span): New function.
26627 (layout_range::contains_point): Convert param "row" from int to
26629 (layout_range::intersects_line_p): Likewise.
26630 (layout::will_show_line_p): Likewise.
26631 (layout::print_source_line): Likewise.
26632 (layout::should_print_annotation_line_p): Likewise.
26633 (layout::print_annotation_line): Likewise.
26634 (layout::print_leading_fixits): Likewise.
26635 (layout::annotation_line_showed_range_p): Likewise.
26636 (struct line_corrections): Likewise for field m_row.
26637 (line_corrections::line_corrections): Likewise for param "row".
26638 (layout::print_trailing_fixits): Likewise.
26639 (layout::get_state_at_point): Likewise.
26640 (layout::get_x_bound_for_row): Likewise.
26641 (layout::print_line): Likewise.
26642 (diagnostic_show_locus): Likewise for locals "last_line" and "row".
26643 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
26644 * input.c (selftest::test_linenum_comparisons): New function.
26645 (selftest::input_c_tests): Call it.
26646 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
26647 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
26648 * selftest.h (ASSERT_GT): New macro.
26649 (ASSERT_GT_AT): New macro.
26650 (ASSERT_LT): New macro.
26651 (ASSERT_LT_AT): New macro.
26653 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
26655 PR rtl-optimization/84780
26656 * combine.c (distribute_links): Don't make a link based on pc_rtx.
26658 2018-03-14 Martin Liska <mliska@suse.cz>
26660 * tree.c (record_node_allocation_statistics): Use
26661 get_stats_node_kind.
26662 (get_stats_node_kind): New function extracted from
26663 record_node_allocation_statistics.
26664 (free_node): Use get_stats_node_kind.
26666 2018-03-14 Richard Biener <rguenther@suse.de>
26668 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
26669 that the value-set of ANTIC_IN doesn't grow.
26672 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
26674 (BB_VISITED_WITH_VISITED_SUCCS): New define.
26675 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
26677 2018-03-14 Julia Koval <julia.koval@intel.com>
26679 * config.gcc (icelake-client, icelake-server): New.
26681 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
26682 (initial_ix86_arch_features): Ditto.
26683 (PTA_SKYLAKE): Add SGX.
26684 (PTA_ICELAKE): Remove.
26685 (PTA_ICELAKE_CLIENT): New.
26686 (PTA_ICELAKE_SERVER): New.
26687 (ix86_option_override_internal): Split up icelake on icelake client and
26689 (get_builtin_code_for_version): Ditto.
26690 (fold_builtin_cpu): Ditto.
26691 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
26692 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
26693 * config/i386/i386.h (processor_type): Ditto.
26694 * doc/invoke.texi: Ditto.
26696 2018-03-14 Jakub Jelinek <jakub@redhat.com>
26699 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
26700 INTEGER_CST offset, add it together with bitpos / 8 and
26701 sign extend based on POINTER_SIZE.
26705 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
26708 * config/i386/constraints.md (Yc): New register constraint.
26709 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
26710 Use Yc constraint for alternative 2 of operand 0. Remove
26711 preferred_for_speed attribute.
26713 2018-03-14 Richard Biener <rguenther@suse.de>
26715 PR tree-optimization/84830
26716 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
26717 with the old one to avoid oscillations.
26719 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
26722 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
26724 (assign_by_spills): Return a flag of reload assignment failure.
26725 Do not process the reload assignment failures. Do not spill other
26726 reload pseudos if they has the same reg class. Update n if
26728 (lra_assign): Add a return arg. Set up from the result of
26729 assign_by_spills call.
26730 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
26731 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
26732 usage_insns if it is not NULL.
26733 (spill_hard_reg_in_range): New function.
26734 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
26735 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
26736 function prototypes.
26737 (lra_assign): Change prototype.
26738 * lra.c (lra): Add code to deal with fails by splitting hard reg
26741 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
26743 * config/riscv/riscv.opt (mrelax): New option.
26744 * config/riscv/riscv.c (riscv_file_start): Emit ".option
26745 "norelax" when riscv_mrelax is disabled.
26746 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
26748 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
26751 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
26752 reassociation for int modes.
26754 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
26756 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
26757 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
26759 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
26760 * config/aarch64/aarch64-sve.md
26761 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
26762 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
26763 (*extend<mode><Vwide>2): Rename to...
26764 (aarch64_sve_extend<mode><Vwide>2): ...this.
26765 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
26766 renaming the old pattern to...
26767 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
26769 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
26770 define_expand, renaming the old pattern to...
26771 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
26772 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
26773 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
26774 account when deciding which SVE instruction the optab should use.
26775 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
26777 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
26779 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
26780 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
26781 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
26782 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
26783 (tlsdesc_small_<mode>): Turn a define_expand and use
26784 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
26785 (tlsdesc_small_advsimd_<mode>): ...this.
26786 (tlsdesc_small_sve_<mode>): New pattern.
26788 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
26790 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
26791 (UNSPEC_UMUL_HIGHPART): New constants.
26792 (MUL_HIGHPART): New int iteraor.
26793 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
26794 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
26796 (*<su>mul<mode>3_highpart): New define_insn.
26798 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
26801 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
26804 2018-03-13 Martin Liska <mliska@suse.cz>
26807 * (sem_item_optimizer::sem_item_optimizer): Initialize new
26809 (sem_item_optimizer::~sem_item_optimizer): Release it.
26810 (sem_item_optimizer::merge_classes): Register variable aliases.
26811 (sem_item_optimizer::fixup_pt_set): New function.
26812 (sem_item_optimizer::fixup_points_to_sets): Likewise.
26813 * ipa-icf.h: Declare new variables and functions.
26815 2018-03-13 Jakub Jelinek <jakub@redhat.com>
26817 PR middle-end/84834
26818 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
26819 integer_pow2p@2 and test integer_pow2p in condition.
26820 (A < 0 ? C : 0): Similarly for @1.
26822 PR middle-end/84831
26823 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
26824 characters starting at p contain '\0' character, don't look beyond
26828 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
26829 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
26832 * reg-stack.c (change_stack): Change update_end var from int to
26833 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
26834 also call set_block_for_insn on the newly added insns and rescan.
26837 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
26838 on the last operand.
26841 * tree.c (stabilize_reference_1): Return save_expr (e) for
26842 STATEMENT_LIST even if it doesn't have side-effects.
26844 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
26846 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
26848 2018-03-12 Renlin Li <renlin.li@arm.com>
26850 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
26851 aarch64_output_scalar_simd_mov_immediate.
26853 2018-03-12 Martin Sebor <msebor@redhat.com>
26855 PR tree-optimization/83456
26856 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
26857 for perfectly overlapping calls to memcpy.
26858 (gimple_fold_builtin_memory_chk): Same.
26859 (gimple_fold_builtin_strcpy): Handle no-warning.
26860 (gimple_fold_builtin_stxcpy_chk): Same.
26861 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
26863 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
26865 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
26866 parameter. Use it for SFmode.
26867 (rs6000_function_arg_advance_1): Adjust.
26868 (rs6000_function_arg): Adjust.
26869 (rs6000_gimplify_va_arg): Pass false for that new parameter.
26871 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
26873 PR rtl-optimization/84169
26874 PR rtl-optimization/84780
26875 * combine.c (can_combine_p): Check for a 2-insn combination whether
26876 the destination register is used between the two insns, too.
26878 2018-03-12 Richard Biener <rguenther@suse.de>
26880 PR tree-optimization/84803
26881 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
26882 for refs DR analysis didn't process.
26884 2018-03-12 Richard Biener <rguenther@suse.de>
26886 PR tree-optimization/84777
26887 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
26888 force-vectorize loops ignore whether we are optimizing for size.
26890 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
26892 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
26893 (TARGET_MD_ASM_ADJUST): Define.
26895 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
26896 Kito Cheng <kito.cheng@gmail.com>
26897 Chung-Ju Wu <jasonwucj@gmail.com>
26899 * config/nds32/nds32.c (nds32_compute_stack_frame,
26900 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
26901 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
26902 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
26903 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
26904 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
26905 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
26906 * config/nds32/nds32.md (prologue, epilogue): Use macro
26907 NDS32_V3PUSH_AVAILABLE_P to do checking.
26909 2018-03-11 Jakub Jelinek <jakub@redhat.com>
26912 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
26913 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
26914 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
26915 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
26916 addition of most attributes on !orig_type_die or the attribute not
26917 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
26919 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
26920 Chung-Ju Wu <jasonwucj@gmail.com>
26922 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
26923 __NDS32_VH__ macro.
26924 * config/nds32/nds32.opt (mvh): New option.
26926 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
26927 Chung-Ju Wu <jasonwucj@gmail.com>
26929 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
26931 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
26932 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
26935 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
26936 Chung-Ju Wu <jasonwucj@gmail.com>
26938 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
26940 * config/nds32/nds32-multiple.md (strlensi): New pattern.
26941 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
26943 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
26944 Kito Cheng <kito.cheng@gmail.com>
26945 Chung-Ju Wu <jasonwucj@gmail.com>
26947 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
26948 UNSPEC_FFMISM and UNSPEC_FLMISM.
26949 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
26950 for ffb, ffmism and flmism.
26951 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
26952 (unspec_ffmism): Ditto.
26953 (unspec_flmism): Ditto.
26954 (nds32_expand_builtin_impl): Check if string extension is available.
26955 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
26956 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
26958 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
26961 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
26964 * lra-assigns.c (assign_by_spills): Return a flag of reload
26965 assignment failure. Do not process the reload assignment
26966 failures. Do not spill other reload pseudos if they has the same
26968 (lra_assign): Add a return arg. Set up from the result of
26969 assign_by_spills call.
26970 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
26971 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
26972 usage_insns if it is not NULL.
26973 (spill_hard_reg_in_range): New function.
26974 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
26975 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
26976 function prototypes.
26977 (lra_assign): Change prototype.
26978 * lra.c (lra): Add code to deal with fails by splitting hard reg
26981 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
26984 * config/i386/i386.opt: Replace Enforcment with Enforcement.
26986 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
26989 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
26990 (dw_val_node): Add val_symbolic_view.
26991 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
26992 (symview_upper_bound): New.
26993 (new_line_info_table): Initialize symviews_since_reset.
26994 (dwarf2out_source_line): Count symviews_since_reset and set
26995 symview_upper_bound.
26996 (dw_val_equal_p): Handle symview.
26997 (add_AT_symview): New.
26998 (print_dw_val): Handle symview.
26999 (attr_checksum, attr_checksum_ordered): Likewise.
27000 (same_dw_val_p, size_of_die): Likewise.
27001 (value_format, output_die): Likewise.
27002 (add_high_low_attributes): Use add_AT_symview for entry_view.
27003 (dwarf2out_finish): Reset symview_upper_bound, clear
27006 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
27009 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
27010 Add strict argument and use it.
27011 (rs6000_split_multireg_move): Update for new strict argument.
27012 (mem_operand_gpr): Disallow all non-offsettable addresses.
27013 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
27015 2018-03-09 Jakub Jelinek <jakub@redhat.com>
27018 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
27019 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
27020 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
27023 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
27024 decl, use remap_type if we want to use the type.
27026 2018-03-09 Martin Sebor <msebor@redhat.com>
27028 PR tree-optimization/84526
27029 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
27031 (builtin_access::generic_overlap): Be prepared to handle non-array
27034 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
27036 PR rtl-optimization/84682
27037 * lra-constraints.c (process_address_1): Check is_address flag
27038 for address constraints.
27039 (process_alt_operands): Likewise.
27040 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
27041 preprocess_constraints.
27042 * recog.h (preprocess_constraints): Add oploc parameter.
27044 * recog.c (preprocess_constraints): Test address_operand for
27045 CT_ADDRESS constraints.
27047 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
27050 * lra-assigns.c (assign_by_spills): Return a flag of reload
27051 assignment failure. Do not process the reload assignment
27052 failures. Do not spill other reload pseudos if they has the same
27054 (lra_assign): Add a return arg. Set up from the result of
27055 assign_by_spills call.
27056 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
27057 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
27058 usage_insns if it is not NULL.
27059 (spill_hard_reg_in_range): New function.
27060 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
27061 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
27062 function prototypes.
27063 (lra_assign): Change prototype.
27064 * lra.c (lra): Add code to deal with fails by splitting hard reg
27067 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27070 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
27071 Accept complain bool parameter. Only emit errors if it is true.
27072 (arm_parse_cpu_option_name): Likewise.
27073 (arm_target_thumb_only): Adjust callers of the above.
27074 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
27075 prototype to take a default true bool parameter.
27076 (arm_parse_arch_option_name): Likewise.
27078 2018-03-09 David Malcolm <dmalcolm@redhat.com>
27079 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
27083 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
27084 * configure: Regenerate.
27085 * configure.ac ("linker --version-script option"): New.
27086 ("linker soname option"): New.
27088 2018-03-09 Richard Biener <rguenther@suse.de>
27090 PR tree-optimization/84775
27091 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
27092 immediate uses of predicate stmts and mark them modified.
27095 PR tree-optimization/84178
27096 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
27098 (version_loop_for_if_conversion): Delay update_ssa call.
27099 (tree_if_conversion): Delay update_ssa until after predicate
27102 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
27105 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
27106 when the function accesses prior frames.
27108 2018-03-08 Jakub Jelinek <jakub@redhat.com>
27111 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
27112 gen_llsym, otherwise call maybe_gen_llsym.
27114 PR inline-asm/84742
27115 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
27116 has ',' character inside of it.
27118 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27121 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
27122 as clobbering CC_REGNUM.
27124 2018-03-08 Richard Biener <rguenther@suse.de>
27126 PR middle-end/84552
27127 * tree-scalar-evolution.c: Include tree-into-ssa.h.
27128 (follow_copies_to_constant): Do not follow SSA names registered
27131 2018-03-08 Richard Biener <rguenther@suse.de>
27133 PR tree-optimization/84178
27134 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
27136 (version_loop_for_if_conversion): Delay update_ssa call.
27137 (tree_if_conversion): Delay update_ssa until after predicate
27140 2018-03-08 David Malcolm <dmalcolm@redhat.com>
27142 PR tree-optimization/84178
27143 * tree-if-conv.c (release_bb_predicate): Remove the
27144 the assertion that the stmts have NULL use_ops.
27145 Discard the statements, asserting that they haven't
27146 yet been added to a BB.
27148 2018-03-08 Richard Biener <rguenther@suse.de>
27150 PR tree-optimization/84746
27151 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
27152 (phi_translate): Pass in destination ANTIC_OUT set.
27153 (phi_translate_1): Likewise. For a simplified result lookup
27154 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
27155 (phi_translate_set): Adjust.
27156 (do_pre_regular_insertion): Likewise.
27157 (do_pre_partial_partial_insertion): Likewise.
27159 2018-03-08 Martin Liska <mliska@suse.cz>
27161 PR gcov-profile/84735
27162 * doc/gcov.texi: Document usage of profile files.
27163 * gcov-io.h: Document changes in the format.
27165 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
27169 * dwarf2out.c (struct dw_line_info_table): Update comments for
27171 (FORCE_RESET_NEXT_VIEW): New.
27172 (FORCE_RESETTING_VIEW_P): New.
27173 (RESETTING_VIEW_P): Check for -1 too.
27174 (ZERO_VIEW_P): Likewise.
27175 (new_line_info_table): Force-reset next view.
27176 (dwarf2out_begin_function): Likewise.
27177 (dwarf2out_source_line): Simplify zero_view_p initialization.
27178 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
27179 view directly. Omit view when omitting .loc at line 0.
27181 2018-03-08 Jakub Jelinek <jakub@redhat.com>
27183 PR tree-optimization/84740
27184 * tree-switch-conversion.c (process_switch): Call build_constructors
27185 only if info.phi_count is non-zero.
27187 PR tree-optimization/84739
27188 * tree-tailcall.c (find_tail_calls): Check call arguments against
27189 DECL_ARGUMENTS (current_function_decl) rather than
27190 DECL_ARGUMENTS (func) when checking for tail recursion.
27192 2018-03-07 Jakub Jelinek <jakub@redhat.com>
27194 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
27195 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
27196 Volker Reichelt's entry and add entries for people that perform
27197 GCC fuzzy testing and report numerous bugs.
27199 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
27202 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
27203 readonly data in sdata, if that is disabled.
27204 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
27205 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
27206 -mreadonly-in-sdata option.
27208 2018-03-07 Martin Sebor <msebor@redhat.com>
27210 PR tree-optimization/84468
27211 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
27212 basic block when looking for nul assignment.
27214 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
27217 * except.h (output_function_exception_table): Adjust prototype.
27218 * except.c (output_function_exception_table): Remove FNNAME parameter
27219 and add SECTION parameter. Ouput one part of the table at a time.
27220 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
27221 the first part of the exception table and emit unwind directives.
27222 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
27223 (i386_pe_seh_cold_init): Likewise.
27224 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
27225 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
27226 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
27227 (ix86_output_call_insn): Emit a nop in one more case for SEH.
27228 * config/i386/winnt.c: Include except.h.
27229 (struct seh_frame_state): Add reg_offset, after_prologue and
27230 in_cold_section fields.
27231 (i386_pe_seh_end_prologue): Set seh->after_prologue.
27232 (i386_pe_seh_cold_init): New function.
27233 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
27234 to seh->in_cold_section.
27235 (seh_emit_push): Record the offset of the push.
27236 (seh_emit_save): Record the offet of the save.
27237 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
27238 Test seh->after_prologue to disregard the epilogue.
27239 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
27240 (i386_pe_end_cold_function): New function.
27242 2018-03-07 Jakub Jelinek <jakub@redhat.com>
27245 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
27246 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
27249 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
27251 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
27252 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
27254 PR middle-end/84723
27255 * multiple_target.c: Include tree-inline.h and intl.h.
27256 (expand_target_clones): Diagnose and fail if node->definition and
27257 !tree_versionable_function_p (node->decl).
27259 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
27261 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
27263 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
27264 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
27265 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
27267 2018-03-06 Jakub Jelinek <jakub@redhat.com>
27270 * combine.c (try_combine): Use reg_or_subregno instead of handling
27271 just paradoxical SUBREGs and REGs.
27273 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
27275 * config/arc/arc.c (arc_finalize_pic): Remove function.
27276 (arc_must_save_register): We use single base PIC register, remove
27277 checks to save/restore the PIC register.
27278 (arc_expand_prologue): Likewise.
27279 * config/arc/arc-protos.h (arc_set_default_type_attributes):
27281 (arc_verify_short): Likewise.
27282 (arc_attr_type): Likewise.
27283 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
27284 (walk_stores): Likewise.
27285 (arc_address_cost): Make it static.
27286 (arc_verify_short): Likewise.
27287 (branch_dest): Likewise.
27288 (arc_attr_type): Likewise.
27289 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
27290 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
27291 (arc_final_prescan_insn): Remove inserting the nops due to
27292 hardware hazards. It is done in reorg step.
27293 (insn_length_variant_t): Remove.
27294 (insn_length_parameters_t): Likewise.
27295 (arc_insn_length_parameters): Likewise.
27296 (arc_get_insn_variants): Likewise.
27297 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
27299 2018-03-06 Jakub Jelinek <jakub@redhat.com>
27301 PR inline-asm/84683
27302 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
27305 PR tree-optimization/84687
27306 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
27308 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
27310 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
27312 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
27313 Rename to ppc_speculation_barrier.
27314 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
27315 __builtin_ppc_speculation_barrier.
27317 2018-03-05 Jakub Jelinek <jakub@redhat.com>
27320 * combine.c (combine_simplify_rtx): Don't try to simplify if
27321 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
27324 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
27326 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
27327 to 32 bytes when compiling for POWER9.
27329 2018-03-05 Jakub Jelinek <jakub@redhat.com>
27332 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
27333 regparm >= 3 with no arg reg available also for calls with
27334 flag_force_indirect_call. Pass decl to ix86_function_regparm.
27337 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
27339 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
27341 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
27344 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
27346 2018-03-05 Richard Biener <rguenther@suse.de>
27348 PR tree-optimization/84486
27349 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
27350 When inserting a __builtin_assume_aligned call set the LHS
27351 SSA name alignment info accordingly.
27353 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
27355 PR tree-optimization/84114
27356 * config/aarch64/aarch64.c (aarch64_reassociation_width)
27357 Avoid reassociation of FLOAT_MODE addition.
27359 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
27361 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
27362 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
27363 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
27364 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
27365 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
27366 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
27367 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
27369 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
27370 __builtin_ia32_wbinvd): New builtins.
27371 (SPECIAL_ARGS2): New.
27372 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
27373 (SPECIAL_ARGS2): New.
27374 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
27375 (ix86_valid_target_attribute_inner_p): Ditto.
27376 (ix86_init_mmx_sse_builtins): Add special_args2.
27377 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
27378 TARGET_WBNOINVD_P): New.
27379 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
27380 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
27381 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
27382 * config/i386/immintrin.h (_wbinvd): New intrinsic.
27383 * config/i386/pconfigintrin.h: New file.
27384 * config/i386/wbnoinvdintrin.h: Ditto.
27385 * config/i386/x86intrin.h: Add headers pconfigintrin.h and
27387 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
27389 2018-03-05 Richard Biener <rguenther@suse.de>
27391 PR tree-optimization/84670
27392 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
27394 (BB_VISITED_WITH_VISITED_SUCCS): New define.
27395 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
27396 (compute_antic_aux): Only assert the number of values in ANTIC_IN
27397 doesn't grow if all successors (recursively) were visited at least
27400 2018-03-05 Richard Biener <rguenther@suse.de>
27402 PR tree-optimization/84650
27403 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
27404 if executed in the loop pipeline.
27406 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
27408 * doc/configfiles.texi (Configuration Files): Move info about
27409 conditionalizing $target-protos.h to...
27410 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
27411 differs from $target-protos.h.
27413 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
27414 Chung-Ju Wu <jasonwucj@gmail.com>
27416 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
27417 * config/nds32/nds32-multiple.md (setmemsi): Define.
27418 * config/nds32/nds32-memory-manipulation.c
27419 (nds32_gen_dup_4_byte_to_word_value): New.
27420 (emit_setmem_word_loop): New.
27421 (emit_setmem_byte_loop): New.
27422 (nds32_expand_setmem_loop): New.
27423 (nds32_expand_setmem_loop_v3m): New.
27424 (nds32_expand_setmem_unroll): New.
27425 (nds32_expand_setmem): New.
27427 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
27428 Chung-Ju Wu <jasonwucj@gmail.com>
27430 * config/nds32/nds32-memory-manipulation.c
27431 (nds32_emit_load_store): New.
27432 (nds32_emit_post_inc_load_store): New.
27433 (nds32_emit_mem_move): New.
27434 (nds32_emit_mem_move_block): New.
27435 (nds32_expand_movmemsi_loop_unknown_size): New.
27436 (nds32_expand_movmemsi_loop_known_size): New.
27437 (nds32_expand_movmemsi_loop): New.
27438 (nds32_expand_movmemsi_unroll): New.
27439 (nds32_expand_movmemqi): Rename ...
27440 (nds32_expand_movmemsi): ... to this.
27441 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
27442 (movmemsi): ... to this.
27443 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
27444 (nds32_expand_movmemsi): ... to this.
27446 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
27447 Monk Chiang <sh.chiang04@gmail.com>
27448 Chung-Ju Wu <jasonwucj@gmail.com>
27450 * config/nds32/nds32-protos.h
27451 (nds32_expand_load_multiple): New arguments.
27452 (nds32_expand_store_multiple): Ditto.
27453 (nds32_valid_multiple_load_store): Rename ...
27454 (nds32_valid_multiple_load_store_p): ... to this.
27455 * config/nds32/nds32-memory-manipulation.c
27456 (nds32_expand_load_multiple): Refine implementation.
27457 (nds32_expand_store_multiple): Ditto.
27458 * config/nds32/nds32-multiple.md
27459 (load_multiple): Update nds32_expand_load_multiple interface.
27460 (store_multiple): Update nds32_expand_store_multiple interface.
27461 * config/nds32/nds32-predicates.c
27462 (nds32_valid_multiple_load_store): Rename ...
27463 (nds32_valid_multiple_load_store_p): ... to this and refine
27465 * config/nds32/predicates.md
27466 (nds32_load_multiple_and_update_address_operation): New predicate.
27467 (nds32_store_multiple_and_update_address_operation): New predicate.
27469 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
27470 Chung-Ju Wu <jasonwucj@gmail.com>
27472 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
27473 (combo): New attribute.
27474 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
27476 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
27478 * config/nds32/nds32.opt: Change -mcmodel= default value.
27480 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
27481 Monk Chiang <sh.chiang04@gmail.com>
27482 Chung-Ju Wu <jasonwucj@gmail.com>
27484 * config/nds32/constants.md (unspec_element): New enum.
27485 * config/nds32/constraints.md (Umw): New constraint.
27486 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
27487 * config/nds32/nds32-intrinsic.md: Likewise.
27488 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
27489 (nds32_valid_smw_lwm_base_p): New.
27490 (nds32_output_smw_single_word): New.
27491 (nds32_output_lmw_single_word): New.
27492 (nds32_expand_unaligned_load): New.
27493 (nds32_expand_unaligned_store): New.
27494 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
27495 (nds32_output_smw_single_word): Declare.
27496 (nds32_output_lmw_single_word): Declare.
27497 (nds32_expand_unaligned_load): Declare.
27498 (nds32_expand_unaligned_store): Declare.
27499 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
27500 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
27501 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
27502 NDS32_BUILTIN_UASTORE_DW.
27503 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
27506 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
27507 Kito Cheng <kito.cheng@gmail.com>
27508 Chung-Ju Wu <jasonwucj@gmail.com>
27510 * config/nds32/nds32-intrinsic.c
27511 (nds32_expand_builtin_null_ftype_reg): Delete.
27512 (nds32_expand_builtin_reg_ftype_imm): Ditto.
27513 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
27514 (nds32_read_argument): New.
27515 (nds32_legitimize_target): Ditto.
27516 (nds32_legitimize_argument): Ditto.
27517 (nds32_check_constant_argument): Ditto.
27518 (nds32_expand_unop_builtin): Ditto.
27519 (nds32_expand_unopimm_builtin): Ditto.
27520 (nds32_expand_binop_builtin): Ditto.
27521 (nds32_builtin_decl_impl): Ditto.
27522 (builtin_description): Ditto.
27523 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
27524 (nds32_init_builtins_impl): Ditto.
27525 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
27526 (nds32_builtin_decl): New.
27527 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
27528 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
27530 2018-03-02 Jeff Law <law@redhat.com>
27532 * reorg.c (stop_search_p): Handle DEBUG_INSN.
27533 (redundant_insn, fill_simple_delay_slots): Likewise.
27534 (fill_slots_from_thread): Likewise.
27535 * resource.c (mark_referenced_resources): Likewise.
27536 (mark_set_resources, find_dead_or_set_registers): Likewise.
27538 2018-03-02 Jakub Jelinek <jakub@redhat.com>
27540 * substring-locations.h (format_warning_va): Formatting fix for
27541 ATTRIBUTE_GCC_DIAG.
27542 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
27544 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
27545 * substring-locations.c: Include intl.h.
27546 (format_warning_va): Turned into small wrapper around
27547 format_warning_n_va, renamed to ...
27548 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
27549 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
27551 (format_warning_at_substring_n): New function.
27552 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
27553 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
27554 format_warning_at_substring with just a shorter name instead of
27555 const function pointer.
27556 (fmtwarn_n): New function.
27557 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
27558 appropriate, get rid of all the fmtstr temporaries, move conditionals
27559 with G_() wrapped string literals directly into fmtwarn arguments,
27560 cast dir.len to (int), formatting fixes.
27562 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
27564 * doc/invoke.texi: Remove "Cilk Plus" references.
27566 2018-03-02 Jakub Jelinek <jakub@redhat.com>
27567 Richard Biener <rguenther@suse.de>
27570 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
27571 for error or warning attributes if CALL_FROM_THUNK_P is set.
27574 2018-03-02 Jakub Jelinek <jakub@redhat.com>
27577 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
27578 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
27581 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
27582 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
27584 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
27585 instead of -1U in last predictors element's probability member.
27587 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
27590 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
27591 arguments if they are comparable.
27593 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
27595 PR tree-optimization/84634
27596 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
27597 masks and masked_loop_p with a single loop_masks, making sure it's
27598 null for bb vectorization.
27600 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
27602 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
27603 (vect_analyze_data_ref_access): Use loop->safe_len rather than
27604 loop->force_vectorize to check whether there is no alias.
27606 2018-03-02 Jakub Jelinek <jakub@redhat.com>
27609 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
27611 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
27613 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
27614 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
27615 instead of a loop around prev_real_insn.
27616 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
27619 PR inline-asm/84625
27620 * config/i386/i386.c (ix86_print_operand): Use conditional
27621 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
27624 2018-03-02 Richard Biener <rguenther@suse.de>
27626 PR tree-optimization/84427
27627 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
27628 (bitmap_set_subtract_values): Rewrite to handle multiple
27631 (prune_clobbered_mems): Likewise.
27632 (phi_translate): Take edge instead of pred/phiblock.
27633 (phi_translate_1): Likewise.
27634 (phi_translate_set): Likewise. Insert all translated
27635 exprs for a value into the set, keeping possibly multiple
27636 expressions per value.
27637 (compute_antic_aux): Adjust for phi_translate changes.
27638 When intersecting union the expressions and prune those
27639 not in the final value set, keeping possibly multiple
27640 expressions per value. Do not use value-insertion
27641 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
27642 all expressions. Add verification that the value-sets
27643 only shrink during iteration.
27644 (compute_partial_antic_aux): Adjust for the phi_translate changes.
27645 (do_pre_regular_insertion): Likewise.
27646 (do_pre_partial_partial_insertion): Likewise.
27648 2018-03-02 Richard Biener <rguenther@suse.de>
27651 * config/darwin.c (saved_debug_info_level): New static global.
27652 (darwin_asm_lto_start): Disable debug info generation for LTO out.
27653 (darwin_asm_lto_end): Restore debug info generation settings.
27655 2018-03-01 Martin Liska <mliska@suse.cz>
27658 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
27659 volatile arguments.
27661 2018-03-01 Richard Biener <rguenther@suse.de>
27664 * dwarf2out.c (gen_variable_die): Properly handle late VLA
27665 type annotation with LTO when debug was disabled at compile-time.
27667 2018-03-01 Matthew Fortune <mfortune@gmail.com>
27669 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
27671 (mips_final_postscan_insn): Likewise.
27673 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
27675 PR rtl-optimization/84528
27676 * alias.c (init_alias_target): Add commentary.
27677 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
27678 a unique base value if the frame pointer is not eliminated
27679 to the stack pointer.
27681 2018-03-01 Tom de Vries <tom@codesourcery.com>
27683 PR rtl-optimization/83327
27684 * lra-int.h (hard_regs_spilled_into): Declare.
27685 * lra.c (hard_regs_spilled_into): Define.
27686 (init_reg_info): Init hard_regs_spilled_into.
27687 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
27688 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
27689 (process_bb_lives): Handle hard_regs_spilled_into.
27690 (lra_create_live_ranges_1): Before doing liveness propagation, clear
27691 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
27693 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
27695 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
27696 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
27697 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
27698 * config/rs6000/aix72.h: New file.
27700 2018-02-28 Jakub Jelinek <jakub@redhat.com>
27702 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
27703 instead of warning_at with conditional singular and plural messages
27707 * stor-layout.c (update_alignment_for_field): For
27708 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
27709 && !DECL_PACKED (field), do the alignment update, just use
27710 only desired_align instead of MAX (type_align, desired_align)
27712 (place_field): Don't do known_align < desired_align handling
27713 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
27714 is non-NULL, instead do it after rli->prev_field handling and
27715 only if not within a bitfield word. For DECL_PACKED (field)
27716 use type_align of BITS_PER_UNIT.
27718 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
27720 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
27721 superfluous parentheses and trailing spaces.
27723 2018-02-28 Richard Biener <rguenther@suse.de>
27725 PR tree-optimization/84584
27726 * graphite-scop-detection.c (scop_detection::add_scop): Discard
27727 SCoPs with fake exit edge.
27729 2018-02-28 Martin Liska <mliska@suse.cz>
27732 * timevar.c (timer::print): Fix format to properly print 100%
27735 2018-02-28 Richard Biener <rguenther@suse.de>
27737 PR middle-end/84607
27738 * genmatch.c (capture_info::walk_match): Do not mark
27739 captured expressions without operands as expr_p given
27740 they act more like predicates and should be subject to
27741 "lost tail" side-effect preserving.
27743 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
27745 PR rtl-optimization/81611
27746 * auto-inc-dec.c (attempt_change): Move dead note from
27747 mem_insn if it's the next use of regno
27748 (find_address): Take address use of reg holding
27749 non-incremented value. Add parm to limit search to the named
27751 (merge_in_block): Attempt to use a mem insn that is the next
27752 use of the original regno.
27754 2018-02-27 Martin Sebor <msebor@redhat.com>
27757 * doc/invoke.texi (-Wmissing-attributes): New option.
27758 * print-tree.c (print_node): Handle DECL_UNINLINABLE.
27760 2018-02-27 Martin Sebor <msebor@redhat.com>
27762 PR translation/84207
27763 * diagnostic-core.h (warning_n, error_n, inform_n): Change
27764 n argument to unsigned HOST_WIDE_INT.
27765 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
27766 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
27767 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
27768 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
27770 2018-02-27 Richard Biener <rguenther@suse.de>
27772 PR tree-optimization/84512
27773 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
27774 Do not use the estimate returned from record_stmt_cost for
27775 the scalar iteration cost but sum properly using add_stmt_cost.
27777 2018-02-27 Richard Biener <rguenther@suse.de>
27779 PR tree-optimization/84466
27780 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
27781 Adjust last change to less strictly validate use operands.
27783 2018-02-27 Martin Liska <mliska@suse.cz>
27785 PR gcov-profile/84548
27786 * gcov.c (process_file): Allow partial overlap and consider it
27787 also as group functions.
27788 (output_lines): Properly calculate range of lines for a group.
27790 2018-02-27 Martin Liska <mliska@suse.cz>
27792 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
27793 'ggc' suffixes. Change first column width.
27794 (timer::print): Fix formatting of the column.
27796 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
27798 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
27799 preserve inline entry blocks for the sake of debug inline
27800 entry point markers alone.
27801 (remove_unused_locals): Suggest in comments a better place to
27802 force the preservation of inline entry blocks that are
27803 otherwise unused, but do not preserve them.
27805 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
27807 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
27809 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
27812 * config/i386/constraints.md (Bs): Replace
27813 ix86_indirect_branch_register with
27814 TARGET_INDIRECT_BRANCH_REGISTER.
27816 * config/i386/i386.md (indirect_jump): Likewise.
27817 (tablejump): Likewise.
27818 (*sibcall_memory): Likewise.
27819 (*sibcall_value_memory): Likewise.
27820 Peepholes of indirect call and jump via memory: Likewise.
27821 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
27822 (*sibcall_value_GOT_32): Likewise.
27823 * config/i386/predicates.md (indirect_branch_operand): Likewise.
27824 (GOT_memory_operand): Likewise.
27825 (call_insn_operand): Likewise.
27826 (sibcall_insn_operand): Likewise.
27827 (GOT32_symbol_operand): Likewise.
27828 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
27830 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
27832 PR rtl-optimization/83496
27833 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
27834 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
27835 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
27836 redundant insn, if any.
27837 (relax_delay_slots): Likewise.
27838 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
27840 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
27842 PR tree-optimization/83965
27843 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
27844 that grouped statements are part of a reduction chain. Return
27845 true if the statement is not marked as a reduction itself but
27846 is part of a group.
27847 (vect_recog_dot_prod_pattern): Don't check whether the statement
27848 is part of a group here.
27849 (vect_recog_sad_pattern): Likewise.
27850 (vect_recog_widen_sum_pattern): Likewise.
27852 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
27855 * final.c (rest_of_clean_state): Also look for calls inside sequences.
27857 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
27860 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
27862 (ix86_output_indirect_function_return): New prototype.
27863 (ix86_split_simple_return_pop_internal): Likewise.
27864 * config/i386/i386.c (indirect_return_via_cx): New.
27865 (indirect_return_via_cx_bnd): Likewise.
27866 (indirect_thunk_name): Handle return va CX_REG.
27867 (output_indirect_thunk_function): Create alias for
27868 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
27869 (ix86_output_indirect_jmp): Remove the bool argument.
27870 (ix86_output_indirect_function_return): New function.
27871 (ix86_split_simple_return_pop_internal): Likewise.
27872 * config/i386/i386.md (*indirect_jump): Don't pass false
27873 to ix86_output_indirect_jmp.
27874 (*tablejump_1): Likewise.
27875 (simple_return_pop_internal): Change it to define_insn_and_split.
27876 Call ix86_split_simple_return_pop_internal to split it for
27877 -mfunction-return=.
27878 (simple_return_indirect_internal): Call
27879 ix86_output_indirect_function_return instead of
27880 ix86_output_indirect_jmp.
27882 2018-02-26 Jakub Jelinek <jakub@redhat.com>
27885 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
27886 memset and value initialization afterwards.
27888 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
27890 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
27892 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
27895 * common/config/aarch64/aarch64-common.c
27896 (aarch_option_optimization_table[]): Switch
27897 off fomit-frame-pointer
27899 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
27900 Chung-Ju Wu <jasonwucj@gmail.com>
27902 * config/nds32/nds32-multiple.md (load_multiple): Disallow
27904 (store_multiple): Ditto.
27906 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
27908 * config.gcc: Add --with-cpu support for nds32 target.
27909 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
27910 * config/nds32/nds32.opt: Add -mcpu= option.
27912 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
27914 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
27915 isel=yes): Warn for these deprecated options.
27917 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
27919 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
27920 ISA_2_5_MASKS_EMBEDDED.
27922 2018-02-23 Jakub Jelinek <jakub@redhat.com>
27924 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
27925 p->max as pointers rather than using iterative_hash_expr.
27927 2018-02-23 Carl Love <cel@us.ibm.com>
27929 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
27930 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
27932 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
27933 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
27934 P8V_BUILTIN_VEC_VUNSIGNED2.
27936 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
27939 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
27940 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
27942 * lra-constraints.c (curr_insn_transform): Set up
27943 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
27945 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
27946 * lra-eliminations.c (spill_pseudos): Ditto.
27947 (process_insn_for_elimination): Ditto.
27948 * lra-lives.c (reg_early_clobber_p): Use the new macros.
27949 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
27950 LRA_NON_CLOBBERED_ALT.
27952 2018-02-22 Martin Sebor <msebor@redhat.com>
27954 PR tree-optimization/84480
27955 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
27956 to maybe_diag_stxncpy_trunc. Call it.
27957 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
27958 from gimple_fold_builtin_strcpy. Print inlining stack.
27959 (handle_builtin_stxncpy): Print inlining stack.
27960 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
27962 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
27965 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
27966 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
27967 and -fcheck-pointer-bounds are used together.
27968 (indirect_thunk_prefix): New enum.
27969 (indirect_thunk_need_prefix): New function.
27970 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
27971 "_nt" instead of "_bnd" for NOTRACK prefix.
27972 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
27973 (output_indirect_thunk_function): Likewise.
27975 (ix86_code_end): Update output_indirect_thunk_function calls.
27976 (ix86_output_indirect_branch_via_reg): Replace
27977 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
27978 (ix86_output_indirect_branch_via_push): Likewise.
27979 (ix86_output_function_return): Likewise.
27980 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
27981 incompatible with -fcf-protection=branch and
27982 -fcheck-pointer-bounds.
27984 2018-02-22 Steve Ellcey <sellcey@cavium.com>
27987 * config/aarch64/aarch64.c (aarch64_print_address_internal):
27988 Change gcc_assert call to output_operand_lossage.
27990 2018-02-22 Steve Ellcey <sellcey@cavium.com>
27992 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
27994 2018-02-22 DJ Delorie <dj@redhat.com>
27995 Sebastian Perta <sebastian.perta@renesas.com>
27996 Oleg Endo <olegendo@gcc.gnu.org>
27998 * config/rx/rx.c (rx_rtx_costs): New function.
27999 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
28001 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
28003 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
28005 2018-02-22 Martin Liska <mliska@suse.cz>
28008 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
28009 Add "native" as a possible value.
28011 2018-02-22 Martin Liska <mliska@suse.cz>
28014 * config/i386/i386.c (ix86_option_override_internal):
28015 Add "native" as a possible value for -march and -mtune.
28017 2018-02-22 Jakub Jelinek <jakub@redhat.com>
28020 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
28021 to all type variants.
28023 PR tree-optimization/84503
28024 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
28025 width as info->bitpos + info->bitsize - start.
28026 (merged_store_group::merge_overlapping): Simplify width computation.
28027 (check_no_overlap): New function.
28028 (imm_store_chain_info::try_coalesce_bswap): Compute expected
28029 start + width and last_order of the group, fail if check_no_overlap
28031 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
28032 to group if check_no_overlap fails.
28034 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
28036 * config/rs6000/altivec.md: Delete contraint arguments to
28037 define_expand, define_split, and define_peephole2, and in
28038 define_insn_and_split if always unused.
28039 * config/rs6000/darwin.md: Ditto.
28040 * config/rs6000/dfp.md: Ditto.
28041 * config/rs6000/rs6000.md: Ditto.
28042 * config/rs6000/sync.md: Ditto.
28043 * config/rs6000/vector.md: Ditto.
28044 * config/rs6000/vsx.md: Ditto.
28046 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
28048 * config/rs6000/altivec.md: Write output control strings as braced
28049 blocks instead of double-quoted strings.
28050 * config/rs6000/darwin.md: Ditto.
28051 * config/rs6000/rs6000.md: Ditto.
28052 * config/rs6000/vector.md: Ditto.
28053 * config/rs6000/vsx.md: Ditto.
28055 2018-02-21 Jason Merrill <jason@redhat.com>
28057 PR c++/84314 - ICE with templates and fastcall attribute.
28058 * attribs.c (build_type_attribute_qual_variant): Remove assert.
28060 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
28062 * ipa-cp.c (determine_versionability): Fix comment typos.
28064 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
28067 * ipa-cp.c (determine_versionability): Do not version functions caling
28070 2018-02-21 Martin Liska <mliska@suse.cz>
28073 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
28074 Add "native" as a possible value.
28075 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
28076 the macro when native cpu detection is available.
28078 2018-02-21 Martin Liska <mliska@suse.cz>
28081 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
28082 Add "native" as a possible value.
28083 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
28084 when native cpu detection is available.
28086 2018-02-21 Jakub Jelinek <jakub@redhat.com>
28087 Martin Sebor <msebor@redhat.com>
28089 PR tree-optimization/84478
28090 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
28092 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
28093 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
28094 support which is conservatively correct, for 2 only stay conservative
28095 for maxlen. Formatting and comment capitalization fixes. Add STRICT
28096 argument to the 2 argument get_range_strlen, adjust 6 arg
28097 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
28099 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
28100 (gimple_fold_builtin_strlen): Pass true as last argument to
28103 2018-02-20 Martin Sebor <msebor@redhat.com>
28105 PR middle-end/84095
28106 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
28107 (builtin_memref::set_base_and_offset): Same. Handle inner references.
28108 (builtin_memref::builtin_memref): Factor out parts into
28109 set_base_and_offset and call it.
28111 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
28113 PR middle-end/84406
28114 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
28115 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
28116 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
28117 search at the associated MODE_INT.
28119 2018-02-20 Jeff Law <law@redhat.com>
28121 PR middle-end/82123
28122 PR tree-optimization/81592
28123 PR middle-end/79257
28124 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
28125 for range data rather than using global data.
28126 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
28127 range data rather than using global data.
28128 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
28129 pass it to children as needed.
28130 (struct directive::fmtresult): Similarly.
28131 (struct directive::set_width): Similarly.
28132 (struct directive::set_precision): Similarly.
28133 (format_integer, format_directive, parse_directive): Similarly.
28134 (format_none): Accept unnamed vr_values parameter.
28135 (format_percent, format_floating, format_character): Similarly.
28136 (format_string, format_plain): Similarly.
28137 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
28138 the EVRP range analyzer for range data rather than using global data.
28139 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
28140 gimple-ssa-evrp-analyze.h
28141 (class sprintf_dom_walker): Add after_dom_children member function.
28142 Add evrp_range_analyzer member.
28143 (sprintf_dom_walker::before_dom_children): Call into the EVRP
28144 range analyzer as needed.
28145 (sprintf_dom_walker::after_dom_children): New member function.
28146 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
28148 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
28149 (evrp_range_analyzer::pop_to_marker): Likewise.
28151 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
28153 PR tree-optimization/84419
28154 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
28155 with the required type if its current type is compatible but
28158 2018-02-20 Jakub Jelinek <jakub@redhat.com>
28160 PR middle-end/82004
28161 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
28162 after vectorization.
28164 2018-02-20 Martin Liska <mliska@suse.cz>
28167 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
28168 possible values if we don't have a hint.
28170 2018-02-20 Martin Liska <mliska@suse.cz>
28174 * final.c (shorten_branches): Build align_tab array with one
28176 * opts.c (finish_options): Add alignment option limit check.
28177 (MAX_CODE_ALIGN): Likewise.
28178 (MAX_CODE_ALIGN_VALUE): Likewise.
28179 * doc/invoke.texi: Document maximum allowed option value for
28180 all -falign-* options.
28182 2018-02-19 Jakub Jelinek <jakub@redhat.com>
28185 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
28186 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
28187 * var-tracking.c (emit_note_insn_var_location): Remove all references
28188 to NOTE_INSN_CALL_ARG_LOCATION.
28189 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
28190 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
28191 Use copy_rtx_if_shared.
28192 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
28193 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
28194 (dwarf2out_var_location): Remove handling of
28195 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
28197 * final.c (final_scan_insn): Remove all references to
28198 NOTE_INSN_CALL_ARG_LOCATION.
28199 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
28200 before dumping final insns.
28201 * except.c (emit_note_eh_region_end): Remove all references to
28202 NOTE_INSN_CALL_ARG_LOCATION.
28203 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
28204 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
28205 * config/arc/arc.c (hwloop_optimize): Likewise.
28206 * config/arm/arm.c (create_fix_barrier): Likewise.
28207 * config/s390/s390.c (s390_chunkify_start): Likewise.
28208 * config/sh/sh.c (find_barrier): Likewise.
28209 * config/i386/i386.c (rest_of_insert_endbranch,
28210 ix86_seh_fixup_eh_fallthru): Likewise.
28211 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
28212 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
28213 * config/frv/frv.c (frv_function_prologue): Likewise.
28214 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
28216 (note_outside_basic_block_p): Remove all references to
28217 NOTE_INSN_CALL_ARG_LOCATION.
28218 * gengtype.c (adjust_field_rtx_def): Likewise.
28219 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
28221 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
28222 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
28225 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
28228 PR tree-optimization/84452
28229 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
28230 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
28233 2018-02-19 Martin Liska <mliska@suse.cz>
28236 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
28238 2018-02-19 Martin Liska <mliska@suse.cz>
28239 Richard Sandiford <richard.sandiford@linaro.org>
28241 PR tree-optimization/82491
28242 * gimple-fold.c (get_base_constructor): Make earlier bail out
28245 2018-02-19 Carl Love <cel@us.ibm.com>
28247 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
28248 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
28250 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
28251 P8V_BUILTIN_VEC_NEG.
28253 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
28255 * config/rl78/rl78.md (movdf): New define expand.
28257 2018-02-19 Martin Liska <mliska@suse.cz>
28260 * doc/invoke.texi: Fix typo.
28261 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
28263 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
28265 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
28266 handle rs6000_single_float and rs6000_double_float specially for
28269 2018-02-16 Jeff Law <law@redhat.com>
28271 * config/rx/rx.c (add_pop_cfi_notes): New function.;
28272 (pop_regs): Use it.
28274 2018-02-16 Jakub Jelinek <jakub@redhat.com>
28277 * ipa-inline.c (inline_small_functions): Fix a typo.
28279 2018-02-16 Nathan Sidwell <nathan@acm.org>
28281 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
28283 2018-02-16 Carl Love <cel@us.ibm.com>
28285 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
28286 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
28287 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
28288 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
28289 expansion to P8V_BUILTIN_VEC_FLOAT2.
28291 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
28293 PR rtl-optimization/70023
28294 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
28295 src_regno into account.
28297 2018-02-16 Carl Love <cel@us.ibm.com>
28299 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
28300 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
28301 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
28302 * config/rs6000/rs6000.c: Remove case statements for
28303 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
28304 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
28305 and P9V_BUILTIN_VEC_VINSERT4B.
28306 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
28307 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
28308 * config/rs6000/vsx.md:
28309 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
28312 2018-02-16 Carl Love <cel@us.ibm.com>
28314 * config/rs6000/altivec.h: Add builtin names vec_extract4b
28316 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
28318 * config/rs6000/rs6000-c.c: Add the definitions for
28319 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
28320 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
28321 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
28322 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
28323 definition for insert4b and define insn *insert3b_internal.
28324 * doc/extend.texi: Add documentation for vec_extract4b.
28326 2018-02-16 Nathan Sidwell <nathan@acm.org>
28328 * doc/extend.texi (Backwards Compatibility): Mention friend
28329 injection. Note for-scope is deprecated.
28330 * doc/invoke.texi (-ffriend-injection): Deprecate.
28332 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
28334 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
28335 that moved to I2, also allow destinations that are a paradoxical
28336 subreg (instead of a normal reg).
28338 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
28341 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
28344 2018-02-16 Richard Biener <rguenther@suse.de>
28346 PR tree-optimization/84037
28347 PR tree-optimization/84016
28349 * config/i386/i386.c (ix86_builtin_vectorization_cost):
28350 Adjust vec_construct for the fact we need additional higher latency
28351 128bit inserts for AVX256 and AVX512 vector builds.
28352 (ix86_add_stmt_cost): Scale vector construction cost for
28355 2018-02-16 Richard Biener <rguenther@suse.de>
28357 PR tree-optimization/84417
28358 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
28359 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
28360 (non_rewritable_lvalue_p): Likewise, use poly-ints.
28362 2018-02-16 Martin Liska <mliska@suse.cz>
28365 * internal-fn.def (ASAN_CHECK): Set proper flags.
28366 (ASAN_MARK): Likewise.
28368 2018-02-16 Julia Koval <julia.koval@intel.com>
28370 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
28371 from PTA_CANNONLAKE.
28373 2018-02-16 Jakub Jelinek <jakub@redhat.com>
28376 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
28377 Use ++iter rather than iter++ for std::list iterators.
28378 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
28379 defer deleting them until all nodes in the forest are processed. Do
28380 free even leaf nodes. Change to_process into auto_vec.
28383 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
28384 * vec.h (vec_default_construct): Use memset instead of placement new
28385 if BROKEN_VALUE_INITIALIZATION is defined.
28386 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
28387 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
28390 PR rtl-optimization/83723
28391 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
28392 * lra.c (lra_substitute_pseudo): Likewise. If true, use
28393 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
28395 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
28397 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
28399 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
28401 PR rtl-optimization/81443
28402 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
28403 from inner REGs to paradoxical SUBREGs.
28405 2018-02-16 Richard Biener <rguenther@suse.de>
28407 PR tree-optimization/84399
28408 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
28409 For operands we can analyze at their definition make sure we can
28410 analyze them at each use as well.
28412 2018-02-16 Richard Biener <rguenther@suse.de>
28414 PR tree-optimization/84190
28415 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
28416 volatile accesses if the decl isn't volatile.
28418 2018-02-15 Jason Merrill <jason@redhat.com>
28420 PR c++/84314 - ICE with templates and fastcall attribute.
28421 * attribs.c (build_type_attribute_qual_variant): Don't clobber
28422 TYPE_CANONICAL on an existing type.
28424 2018-02-15 Jakub Jelinek <jakub@redhat.com>
28426 PR tree-optimization/84383
28427 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
28428 dstoff nor call operand_equal_p if dstbase is NULL.
28430 PR tree-optimization/84334
28431 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
28432 also a CONSTANT_CLASS_P, punt.
28434 2018-02-14 Jim Wilson <jimw@sifive.com>
28436 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
28437 first SMALL_OPERAND check. New local min_second_step. Move assert
28438 to where locals are set. Add TARGET_RVC support.
28439 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
28441 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
28443 * doc/invoke.texi: Correct -Wformat-overflow code sample.
28445 2018-02-14 Martin Sebor <msebor@redhat.com>
28447 PR tree-optimization/83698
28448 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
28449 arrays constrain the offset range to their bounds.
28450 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
28451 (builtin_access::overlap): Avoid setting the size of overlap if it's
28453 (maybe_diag_overlap): Also consider arrays when deciding what values
28454 of offsets to include in diagnostics.
28456 2018-02-14 Martin Sebor <msebor@redhat.com>
28459 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
28460 that correspond to the kind of a declaration.
28462 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
28465 * config/pa/pa.md: Load address of PIC label using the linkage table
28466 if the label is nonlocal.
28468 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
28470 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
28471 warning message if user requests -maltivec=be.
28472 * doc/invoke.texi: Document deprecation of -maltivec=be.
28474 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
28477 * config/rs6000/rs6000-c.c: Update definitions for
28478 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
28479 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
28481 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
28484 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
28485 add _get_ssp intrinsics. Remove argument from
28486 __builtin_ia32_rdssp[d|q].
28487 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
28488 * config/i386/i386-builtin.def: Remove argument from
28489 __builtin_ia32_rdssp[d|q].
28490 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
28491 ix86_expand_special_args_builtin for _rdssp[d|q].
28492 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
28493 Clear register before usage.
28494 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
28495 Add documentation for new _get_ssp and _inc_ssp intrinsics.
28497 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
28499 PR tree-optimization/84357
28500 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
28501 operand 1 of an ARRAY_REF too.
28503 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
28506 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
28507 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
28509 (set_of_reg): New struct.
28510 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
28511 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
28512 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
28514 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
28515 Split into bitclr, bitset, bitinvert patterns if appropriate.
28516 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
28517 use rx_fuse_in_memory_bitop.
28518 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
28519 to named insn, correct maximum insn length.
28521 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
28524 * machmode.def: Define a complex mode for PARTIAL_INT.
28525 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
28527 * doc/rtl.texi: Document CSPImode.
28528 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
28530 (msp430_hard_regno_nregs_with_padding): Likewise.
28532 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
28535 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
28537 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
28539 PR rtl-optimization/84169
28540 * combine.c (try_combine): New variable split_i2i3. Set it to true if
28541 we generated a parallel as new i3 and we split that to new i2 and i3
28542 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
28543 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
28544 those to i2, not i1. Partially rewrite this scan code.
28546 2018-02-13 Jakub Jelinek <jakub@redhat.com>
28549 * stor-layout.c (place_field): For variable length fields, adjust
28550 offset_align afterwards not just based on the field's alignment,
28551 but also on the size.
28553 PR middle-end/84309
28554 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
28555 of exps and logs in the use_exp2 case.
28557 2018-02-13 Jeff Law <law@redhat.com>
28559 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
28560 entry for "vector".
28562 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
28565 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
28569 * common.opt (gas-loc-support, gas-locview-support): New.
28570 (ginline-points, ginternal-reset-location-views): New.
28571 * doc/invoke.texi: Document them. Use @itemx where intended.
28572 (gvariable-location-views): Adjust.
28573 * target.def (reset_location_view): New.
28574 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
28575 (TARGET_RESET_LOCATION_VIEW): New.
28576 * doc/tm.texi: Rebuilt.
28577 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
28578 (dwarf2out_default_as_locview_support): New.
28579 (output_asm_line_debug_info): Use option variables.
28580 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
28581 (output_loc_list): Likewise.
28582 (add_high_low_attributes): Check option variables.
28583 Don't output entry view attribute in strict mode.
28584 (gen_inlined_subroutine_die): Check option variables.
28585 (dwarf2out_inline_entry): Likewise.
28586 (init_sections_and_labels): Likewise.
28587 (dwarf2out_early_finish): Likewise.
28588 (maybe_reset_location_view): New, from...
28589 (dwarf2out_var_location): ... here. Call it.
28590 * debug.h (dwarf2out_default_as_loc_support): Declare.
28591 (dwarf2out_default_as_locview_support): Declare.
28592 * hooks.c (hook_int_rtx_insn_0): New.
28593 * hooks.h (hook_int_rtx_insn_0): Declare.
28594 * toplev.c (process_options): Take -gas-loc-support and
28595 -gas-locview-support from dwarf2out. Enable
28596 -gvariable-location-views by default only with locview
28597 assembler support. Enable -ginternal-reset-location-views by
28598 default only if the target defines the corresponding hook.
28599 Enable -ginline-points by default if location views are
28600 enabled; force it disabled if statement frontiers are
28602 * tree-inline.c (expand_call_inline): Check option variables.
28603 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
28605 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
28607 PR tree-optimization/84321
28608 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
28609 handling. Also check whether the anti-range contains any values
28610 that satisfy the mask; switch to a VR_RANGE if not.
28612 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
28615 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
28617 2018-02-13 Martin Jambor <mjambor@suse.cz>
28620 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
28621 of call statements, also set location of a load to a temporary.
28623 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
28625 * config/rl78/rl78.c (add_vector_labels): New function.
28626 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
28627 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
28628 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
28629 which checks that no arguments are passed.
28630 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
28631 * doc/extend.texi: Documentation for the new attribute.
28633 2018-02-13 Andreas Schwab <schwab@suse.de>
28635 * config/riscv/linux.h (CPP_SPEC): Define.
28637 2018-02-13 Jakub Jelinek <jakub@redhat.com>
28640 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
28641 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
28642 OPTION_MASK_ISA_AES as first argument to def_builtin_const
28643 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
28644 instead of OPTION_MASK_ISA_PCLMUL as first argument to
28645 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
28646 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
28647 temporarily for AES and PCLMUL builtins.
28649 PR tree-optimization/84339
28650 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
28651 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
28654 PR middle-end/84309
28655 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
28656 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
28657 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
28659 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
28661 * omp-simd-clone.h: New file.
28662 * omp-simd-clone.c: Include omp-simd-clone.h.
28663 (expand_simd_clones): No longer static.
28664 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
28665 cgraph.h and omp-simd-clone.h.
28666 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
28667 (vect_recog_widen_shift_pattern): Formatting fix.
28668 (vect_pattern_recog_1): Don't check optab for calls.
28671 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
28672 operands[2] into a REG before using gen_lowpart on it.
28674 2018-02-12 Jeff Law <law@redhat.com>
28677 * config/sh/sh.c (find_barrier): Consider a sibling call
28680 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
28681 successfully back substituting a reg.
28683 2018-02-12 Richard Biener <rguenther@suse.de>
28685 PR tree-optimization/84037
28686 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
28687 parameter, move visited init to caller.
28688 (vect_slp_analyze_operations): Separate cost from validity
28689 check, initialize visited once for all instances.
28690 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
28692 * tree-vect-stmts.c (vect_model_simple_cost): Make early
28694 (vect_model_promotion_demotion_cost): Likewise.
28695 (vectorizable_bswap): Guard cost modeling with !slp_node
28696 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
28698 (vectorizable_call): Likewise.
28699 (vectorizable_conversion): Likewise.
28700 (vectorizable_assignment): Likewise.
28701 (vectorizable_shift): Likewise.
28702 (vectorizable_operation): Likewise.
28703 (vectorizable_store): Likewise.
28704 (vectorizable_load): Likewise.
28705 (vectorizable_condition): Likewise.
28706 (vectorizable_comparison): Likewise.
28708 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
28711 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
28712 (ASAN_MARK): Fix fnspec to account for return value, change pointer
28713 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
28715 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
28717 PR middle-end/83665
28718 * params.def (inline-min-speedup): Increase from 8 to 15.
28719 (max-inline-insns-auto): Decrease from 40 to 30.
28720 * ipa-split.c (consider_split): Add some buffer for function to
28721 be considered inlining candidate.
28722 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
28725 2018-02-12 Richard Biener <rguenther@suse.de>
28727 PR tree-optimization/84037
28728 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
28729 matched stmts if we cannot swap the non-matched ones.
28731 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
28733 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
28734 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
28735 _mm_maskz_scalef_round_ss): New intrinsics.
28736 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
28737 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
28738 __builtin_ia32_scalefss_round): Remove.
28739 (__builtin_ia32_scalefsd_mask_round,
28740 __builtin_ia32_scalefss_mask_round): New intrinsics.
28741 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
28742 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
28743 ((match_operand:VF_128 2 "<round_nimm_predicate>"
28744 "<round_constraint>")): Changed to ...
28745 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
28746 "<round_scalar_constraint>")): ... this.
28747 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
28748 %0, %1, %2<round_op3>}"): Changed to ...
28749 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
28750 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
28751 %2<round_scalar_mask_op3>}"): ... this.
28752 * config/i386/subst.md (round_scalar_nimm_predicate): New.
28754 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
28756 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
28757 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
28758 (_mm_maskz_sqrt_round_ss): New intrinsics.
28759 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
28760 (__builtin_ia32_sqrtsd_mask_round)
28761 (__builtin_ia32_sqrtss_mask_round): New builtins.
28762 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
28763 (__builtin_ia32_sqrtss_round): Remove.
28764 (__builtin_ia32_sqrtsd_mask_round)
28765 (__builtin_ia32_sqrtss_mask_round): New builtins.
28766 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
28767 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
28768 ((match_operand:VF_128 1 "vector_operand"
28769 "xBm,<round_constraint>")): Changed to ...
28770 ((match_operand:VF_128 1 "vector_operand"
28771 "xBm,<round_scalar_constraint>")): ... this.
28772 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
28773 %0, %2, %<iptr>1<round_op3>}): Changed to ...
28774 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
28775 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
28776 %<iptr>1<round_scalar_mask_op3>}): ... this.
28777 ((set_attr "prefix" "<round_prefix>")): Changed to ...
28778 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
28780 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
28783 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
28784 Cast vec_cmpeq result to correct type.
28785 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
28786 Cast vec_cmpgt result to correct type.
28788 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
28790 * final.c (final_scan_insn_1): Renamed from...
28791 (final_scan_insn): ... this. New wrapper, to recover
28792 seen from the outermost call in recursive ones.
28793 * config/sparc/sparc.c (output_return): Drop seen from call.
28794 (output_sibcall): Likewise.
28795 * config/visium/visium.c (output_branch): Likewise.
28797 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
28799 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
28802 2018-02-10 Alan Modra <amodra@gmail.com>
28805 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
28806 Specify LR as an input.
28808 2018-02-10 Jakub Jelinek <jakub@redhat.com>
28811 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
28812 remove_member_access_dummy_vars): New functions.
28813 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
28814 lower_omp_1, execute_lower_omp): Use them.
28816 PR rtl-optimization/84308
28817 * shrink-wrap.c (spread_components): Release todo vector.
28819 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
28821 PR rtl-optimization/57193
28822 * ira-color.c (struct allocno_color_data): Add member
28823 conflict_allocno_hard_prefs.
28824 (update_conflict_allocno_hard_prefs): New.
28825 (bucket_allocno_compare_func): Add a preference based on
28826 conflict_allocno_hard_prefs.
28827 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
28828 (color_allocnos): Remove a dead code. Initiate
28829 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
28831 2018-02-09 Jakub Jelinek <jakub@redhat.com>
28834 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
28835 constraint from =wa to wa. Avoid a subreg on the output operand,
28836 instead use a pseudo and subreg it in a move.
28837 (p9_xxbrd_<mode>): Changed to ...
28838 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
28839 (p9_xxbrd_v2df): New expander.
28840 (p9_xxbrw_<mode>): Changed to ...
28841 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
28842 (p9_xxbrw_v4sf): New expander.
28844 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
28846 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
28848 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
28851 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
28852 multiply in 32-bit mode.
28853 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
28854 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
28857 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
28859 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
28860 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
28861 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
28862 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
28864 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
28867 * dwarf2out.c (is_trivial_indirect_ref): New function.
28868 (dwarf2out_late_global_decl): Do not generate a location
28869 attribute for variables that have a non-trivial DECL_VALUE_EXPR
28870 and that are not defined in the current unit.
28872 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
28874 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
28875 instead of a libcall for UNORDERED.
28877 2018-02-09 Tamar Christina <tamar.christina@arm.com>
28880 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
28881 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
28883 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
28886 * config/s390/s390.c (s390_set_current_function): Invoke
28887 s390_indirect_branch_settings also if fndecl didn't change.
28889 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
28891 * config/rs6000/rs6000.md (blockage): Set length to zero.
28893 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
28895 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
28897 2018-02-09 Jakub Jelinek <jakub@redhat.com>
28900 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
28901 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
28905 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
28906 PARALLEL incoming that failed vt_get_decl_and_offset check.
28908 PR middle-end/84237
28909 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
28910 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
28912 (get_variable_section): For decls in named .bss* sections pass true as
28913 second argument to bss_initializer_p.
28915 2018-02-09 Marek Polacek <polacek@redhat.com>
28916 Jakub Jelinek <jakub@redhat.com>
28919 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
28920 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
28921 Sync some changes from cxx_fold_indirect_ref.
28923 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
28925 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
28927 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
28928 (BLOCK_INLINE_ENTRY_LABEL): New.
28929 (dwarf2out_var_location): Disregard inline entry markers.
28930 (inline_entry_data): New struct.
28931 (inline_entry_data_hasher): New hashtable type.
28932 (inline_entry_data_hasher::hash): New.
28933 (inline_entry_data_hasher::equal): New.
28934 (inline_entry_data_table): New variable.
28935 (add_high_low_attributes): Add DW_AT_entry_pc and
28936 DW_AT_GNU_entry_view attributes if a pending entry is found
28937 in inline_entry_data_table. Add old entry_pc attribute only
28938 if debug nonbinding markers are disabled.
28939 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
28940 markers are enabled.
28941 (block_within_block_p, dwarf2out_inline_entry): New.
28942 (dwarf2out_finish): Check that no entries remained in
28943 inline_entry_data_table.
28944 * final.c (reemit_insn_block_notes): Handle inline entry notes.
28945 (final_scan_insn, notice_source_line): Likewise.
28946 (rest_of_clean_state): Skip inline entry markers.
28947 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
28949 * gimple.c (gimple_build_debug_inline_entry): New.
28950 * gimple.h (enum gimple_debug_subcode): Add
28951 GIMPLE_DEBUG_INLINE_ENTRY.
28952 (gimple_build_debug_inline_entry): Declare.
28953 (gimple_debug_inline_entry_p): New.
28954 (gimple_debug_nonbind_marker_p): Adjust.
28955 * insn-notes.def (INLINE_ENTRY): New.
28956 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
28957 inline entry marker notes.
28958 (print_insn): Likewise.
28959 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
28960 (INSN_DEBUG_MARKER_KIND): Likewise.
28961 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
28962 * tree-inline.c (expand_call_inline): Build and insert
28963 debug_inline_entry stmt.
28964 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
28965 inline entry blocks early, if nonbind markers are enabled.
28966 (dump_scope_block): Dump fragment info.
28967 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
28968 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
28969 (gimple_build_debug_inline_entry): New.
28970 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
28971 Enable/disable inline entry points too.
28972 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
28973 (DEBUG_INSN): Describe inline entry markers.
28975 * common.opt (gvariable-location-views): New.
28976 (gvariable-location-views=incompat5): New.
28977 * config.in: Rebuilt.
28978 * configure: Rebuilt.
28979 * configure.ac: Test assembler for view support.
28980 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
28981 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
28982 * dwarf2out.c (var_loc_view): New typedef.
28983 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
28984 (dwarf2out_locviews_in_attribute): New.
28985 (dwarf2out_locviews_in_loclist): New.
28986 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
28987 (enum dw_line_info_opcode): Add LI_adv_address.
28988 (struct dw_line_info_table): Add view.
28989 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
28990 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
28991 (zero_view_p): New variable.
28992 (ZERO_VIEW_P): New macro.
28993 (output_asm_line_debug_info): New.
28994 (struct var_loc_node): Add view.
28995 (add_AT_view_list, AT_loc_list): New.
28996 (add_var_loc_to_decl): Add view param. Test it against last.
28997 (new_loc_list): Add view params. Record them.
28998 (AT_loc_list_ptr): Handle loc and view lists.
28999 (view_list_to_loc_list_val_node): New.
29000 (print_dw_val): Handle dw_val_class_view_list.
29001 (size_of_die): Likewise.
29002 (value_format): Likewise.
29003 (loc_list_has_views): New.
29004 (gen_llsym): Set vl_symbol too.
29005 (maybe_gen_llsym, skip_loc_list_entry): New.
29006 (dwarf2out_maybe_output_loclist_view_pair): New.
29007 (output_loc_list): Output view list or entries too.
29008 (output_view_list_offset): New.
29009 (output_die): Handle dw_val_class_view_list.
29010 (output_dwarf_version): New.
29011 (output_compilation_unit_header): Use it.
29012 (output_skeleton_debug_sections): Likewise.
29013 (output_rnglists, output_line_info): Likewise.
29014 (output_pubnames, output_aranges): Update version comments.
29015 (output_one_line_info_table): Output view numbers in asm comments.
29016 (dw_loc_list): Determine current endview, pass it to new_loc_list.
29017 Call maybe_gen_llsym.
29018 (loc_list_from_tree_1): Adjust.
29019 (add_AT_location_description): Create view list attribute if
29020 needed, check it's absent otherwise.
29021 (convert_cfa_to_fb_loc_list): Adjust.
29022 (maybe_emit_file): Call output_asm_line_debug_info for test.
29023 (dwarf2out_var_location): Reset views as needed. Precompute
29024 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
29025 attribute. Set view.
29026 (new_line_info_table): Reset next view.
29027 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
29028 (dwarf2out_source_line): Likewise. Output view resets and labels to
29029 the assembler, or select appropriate line info opcodes.
29030 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
29031 (optimize_string_length): Catch it. Adjust.
29032 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
29033 dw_val_class_view_list, and remove it if no longer needed.
29034 (hash_loc_list): Hash view numbers.
29035 (loc_list_hasher::equal): Compare them.
29036 (optimize_location_lists): Check whether a view list symbol is
29037 needed, and whether the locview attribute is present, and
29038 whether they match. Remove the locview attribute if no longer
29040 (index_location_lists): Call skip_loc_list_entry for test.
29041 (dwarf2out_finish): Call output_asm_line_debug_info for test.
29042 Use output_dwarf_version.
29043 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
29044 (struct dw_val_node): Add val_view_list.
29045 * final.c (SEEN_NEXT_VIEW): New.
29046 (set_next_view_needed): New.
29047 (clear_next_view_needed): New.
29048 (maybe_output_next_view): New.
29049 (final_start_function): Rename to...
29050 (final_start_function_1): ... this. Take pointer to FIRST,
29051 add SEEN parameter. Emit param bindings in the initial view.
29052 (final_start_function): Reintroduce SEEN-less interface.
29053 (final): Rename to...
29054 (final_1): ... this. Take SEEN parameter. Output final pending
29055 next view at the end.
29056 (final): Reintroduce seen-less interface.
29057 (final_scan_insn): Output pending next view before switching
29058 sections or ending a block. Mark the next view as needed when
29059 outputting variable locations. Notify debug backend of section
29060 changes, and of location view changes.
29061 (rest_of_handle_final): Adjust.
29062 * toplev.c (process_options): Autodetect value for debug variable
29063 location views option. Warn on incompat5 without -gdwarf-5.
29064 * doc/invoke.texi (gvariable-location-views): New.
29065 (gvariable-location-views=incompat5): New.
29066 (gno-variable-location-views): New.
29068 2018-02-08 David Malcolm <dmalcolm@redhat.com>
29070 PR tree-optimization/84136
29071 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
29072 that the result of find_edge is non-NULL.
29074 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
29077 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
29078 storing integer register in SImode. Fix cost of 256 and 512
29079 byte aligned SSE register store.
29081 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
29083 * config/i386/i386.c (ix86_multiplication_cost): Fix
29084 multiplication cost for TARGET_AVX512DQ.
29086 2018-02-08 Marek Polacek <polacek@redhat.com>
29088 PR tree-optimization/84238
29089 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
29092 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29094 PR tree-optimization/84265
29095 * tree-vect-stmts.c (vectorizable_store): Don't treat
29096 VMAT_CONTIGUOUS accesses as grouped.
29097 (vectorizable_load): Likewise.
29099 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29101 PR tree-optimization/81635
29102 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
29103 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
29104 (test_round_for_mask): New functions.
29105 (wide_int_cc_tests): Call test_round_for_mask.
29106 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
29107 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
29108 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
29109 range returned by get_range_info.
29111 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
29114 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
29115 * symtab.c: Include builtins.h
29116 (symtab_node::output_to_lto_symbol_table_p): Move here
29117 from lto-streamer-out.c:output_symbol_p.
29118 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
29119 (output_symbol_p): Move all logic to symtab.c
29120 (produce_symtab): Update.
29122 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
29124 * config/s390/s390-opts.h (enum indirect_branch): Define.
29125 * config/s390/s390-protos.h (s390_return_addr_from_memory)
29126 (s390_indirect_branch_via_thunk)
29127 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
29128 (enum s390_indirect_branch_type): Define.
29129 * config/s390/s390.c (struct s390_frame_layout, struct
29130 machine_function): Remove.
29131 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
29132 (indirect_branch_table_label_no, indirect_branch_table_name):
29134 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
29135 (enum s390_indirect_branch_option): Define.
29136 (s390_return_addr_from_memory): New function.
29137 (s390_handle_string_attribute): New function.
29138 (s390_attribute_table): Add new attribute handler.
29139 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
29140 (s390_indirect_branch_via_thunk): New function.
29141 (s390_indirect_branch_via_inline_thunk): New function.
29142 (s390_function_ok_for_sibcall): When jumping via thunk disallow
29143 sibling call optimization for non z10 compiles.
29144 (s390_emit_call): Force indirect branch target to be a single
29145 register. Add r1 clobber for non-z10 compiles.
29146 (s390_emit_epilogue): Emit return jump via return_use expander.
29147 (s390_reorg): Handle JUMP_INSNs as execute targets.
29148 (s390_option_override_internal): Perform validity checks for the
29149 new command line options.
29150 (s390_indirect_branch_attrvalue): New function.
29151 (s390_indirect_branch_settings): New function.
29152 (s390_set_current_function): Invoke s390_indirect_branch_settings.
29153 (s390_output_indirect_thunk_function): New function.
29154 (s390_code_end): Implement target hook.
29155 (s390_case_values_threshold): Implement target hook.
29156 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
29158 * config/s390/s390.h (struct s390_frame_layout)
29159 (struct machine_function): Move here from s390.c.
29160 (TARGET_INDIRECT_BRANCH_NOBP_RET)
29161 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
29162 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
29163 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
29164 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
29165 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
29166 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
29167 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
29168 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
29169 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
29170 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
29171 (mnemonic attribute): Add values which aren't recognized
29173 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
29174 pattern for branch conversion. Fix mnemonic attribute.
29175 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
29176 indirect branch via thunk if requested.
29177 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
29178 ("*indirect_jump"): Disable for branch conversion using out of
29180 ("indirect_jump_via_thunk<mode>_z10")
29181 ("indirect_jump_via_thunk<mode>")
29182 ("indirect_jump_via_inlinethunk<mode>_z10")
29183 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
29184 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
29185 ("casesi_jump_via_inlinethunk<mode>_z10")
29186 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
29187 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
29188 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
29189 ("*indirect2_jump"): Disable for branch conversion.
29190 ("casesi_jump"): Turn into expander and expand patterns for branch
29192 ("return_use"): New expander.
29193 ("*return"): Emit return via thunk and rename it to ...
29194 ("*return<mode>"): ... this one.
29195 * config/s390/s390.opt: Add new options and and enum for the
29198 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29200 * lra-constraints.c (match_reload): Unconditionally use
29201 gen_lowpart_SUBREG, rather than selecting between that
29202 and equivalent gen_rtx_SUBREG code.
29204 2018-02-08 Richard Biener <rguenther@suse.de>
29206 PR tree-optimization/84233
29207 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
29208 changed flag instead of boguously re-using phi_inserted.
29210 2018-02-08 Martin Jambor <mjambor@suse.cz>
29212 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
29213 static local variables.
29215 2018-02-08 Richard Biener <rguenther@suse.de>
29217 PR tree-optimization/84278
29218 * tree-vect-stmts.c (vectorizable_store): When looking for
29219 smaller vector types to perform grouped strided loads/stores
29220 make sure the mode is supported by the target.
29221 (vectorizable_load): Likewise.
29223 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
29225 * config/aarch64/aarch64.c (aarch64_components_for_bb):
29226 Increase LDP/STP opportunities by adding adjacent callee-saves.
29228 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
29230 PR rtl-optimization/84068
29231 PR rtl-optimization/83459
29232 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
29234 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
29236 PR tree-optimization/84224
29237 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
29238 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
29239 non-zero arguments.
29241 2018-02-07 Iain Sandoe <iain@codesourcery.com>
29244 * config/rs6000/altivec.md (*restore_world): Remove LR use.
29245 * config/rs6000/predicates.md (restore_world_operation): Adjust op
29246 count, remove one USE.
29248 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
29250 * doc/install.texi (Configuration): Document the
29251 --with-long-double-format={ibm,ieee} PowerPC configuration
29255 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
29256 Convert from define_expand to be define_insn_and_split. Rework
29257 float/double/_Float128 conversions to QI/HI/SImode to work with
29258 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
29259 conversions to QI/HImode types did a store and then a load to
29260 truncate the value. For conversions to VSX registers, don't split
29261 the insn, instead emit the code directly. Use the code iterator
29262 any_fix to combine signed and unsigned conversions.
29263 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
29264 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
29265 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
29266 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
29267 (fix_<mode>di2_hw): Likewise.
29268 (fixuns_<mode>di2_hw): Likewise.
29269 (fix_<mode>si2_hw): Likewise.
29270 (fixuns_<mode>si2_hw): Likewise.
29271 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
29272 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
29273 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
29274 fix<uns>_trunc<SFDF:mode>si2_p8.
29275 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer used.
29276 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
29277 (fix<uns>_<mode>_mem): Likewise.
29278 (fctiw<u>z_<mode>_mem): Likewise.
29279 (fix<uns>_<mode>_mem): Likewise.
29280 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
29281 the register allocator from doing a direct move to the GPRs to do
29282 a store, and instead use the ISA 3.0 store byte/half-word from
29283 vector register instruction. For IEEE 128-bit floating point,
29284 also optimize stores of 32-bit ints.
29285 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
29287 2018-02-07 Alan Hayward <alan.hayward@arm.com>
29289 * genextract.c (push_pathstr_operand): New function to support
29291 (walk_rtx): Call push_pathstr_operand.
29292 (print_path): Support [a-zA-Z].
29294 2018-02-07 Richard Biener <rguenther@suse.de>
29296 PR tree-optimization/84037
29297 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
29298 (cse_and_gimplify_to_preheader): Declare.
29299 (vect_get_place_in_interleaving_chain): Likewise.
29300 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
29302 (_loop_vec_info::~_loop_vec_info): Delete it.
29303 (cse_and_gimplify_to_preheader): New function.
29304 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
29305 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
29306 (vectorizable_load): Likewise. For grouped stores always base
29307 the IV on the first element.
29308 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
29309 condition before gimplifying.
29311 2018-02-07 Jakub Jelinek <jakub@redhat.com>
29313 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
29314 *DIV_EXPR and *MOD_EXPR.
29316 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
29319 * config/i386/i386.c (ix86_option_override_internal): Mask out
29320 the CF_SET bit when checking -fcf-protection.
29322 2018-02-07 Tom de Vries <tom@codesourcery.com>
29325 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
29328 2018-02-07 Richard Biener <rguenther@suse.de>
29330 PR tree-optimization/84204
29331 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
29334 PR tree-optimization/84205
29335 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
29336 special-case isl_ast_op_zdiv_r.
29338 PR tree-optimization/84223
29339 * graphite-scop-detection.c (gather_bbs::before_dom_children):
29340 Only add conditions from within the region.
29341 (gather_bbs::after_dom_children): Adjust.
29343 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
29346 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
29347 * config/avr/avr.md: Only post-reload split REG-REG moves if
29348 either register is GENERAL_REG_P.
29350 2018-02-07 Jakub Jelinek <jakub@redhat.com>
29352 PR tree-optimization/84235
29353 * tree-ssa-scopedtables.c
29354 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
29355 if the subtraction is performed in floating point type where NaNs are
29356 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
29357 build 1. Formatting fix.
29359 2018-02-06 Jakub Jelinek <jakub@redhat.com>
29362 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
29363 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
29364 and skip it regardless of bb boundaries. Use CALL_P macro,
29365 don't test INSN_P (insn) together with CALL_P or JUMP_P check
29366 unnecessarily, formatting fix.
29368 2018-02-06 Michael Collison <michael.collison@arm.com>
29370 * config/arm/thumb2.md:
29371 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
29372 (*thumb_mov_notscc): Ditto.
29374 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
29377 * config/rs6000/rs6000.md (su code attribute): Use "u" for
29378 unsigned_fix, not "s".
29380 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
29382 * configure.ac (gcc_fn_eh_frame_ro): New function.
29383 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
29384 correct .eh_frame permissions.
29385 * configure: Regenerate.
29387 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
29389 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
29390 irrelevant options.
29392 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
29394 * config/rs6000/rs6000.c (rs6000_option_override_internal):
29395 Display warning message for -mno-speculate-indirect-jumps.
29397 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
29399 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
29401 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
29403 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
29405 PR tree-optimization/84225
29406 * tree-eh.c (find_trapping_overflow): Only call
29407 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
29409 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
29412 * config/i386/i386.c: Reimplement the check of possible options
29413 -mibt/-mshstk conbination. Change error messages.
29414 * doc/invoke.texi: Fix a typo: remove extra '='.
29416 2018-02-06 Marek Polacek <polacek@redhat.com>
29418 PR tree-optimization/84228
29419 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
29421 2018-02-06 Tamar Christina <tamar.christina@arm.com>
29424 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
29425 emitted arch directives.
29426 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
29427 __ARM_FEATURE_COPROC before changing architectures.
29429 2018-02-06 Richard Biener <rguenther@suse.de>
29431 * config/i386/i386.c (print_reg): Fix typo.
29432 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
29434 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
29436 * configure: Regenerate.
29438 2018-02-05 Martin Sebor <msebor@redhat.com>
29440 PR tree-optimization/83369
29441 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
29444 2018-02-05 Martin Liska <mliska@suse.cz>
29446 * doc/invoke.texi: Cherry-pick upstream r323995.
29448 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
29450 * ira.c (ira_init_register_move_cost): Adjust comment.
29452 2018-02-05 Martin Liska <mliska@suse.cz>
29454 PR gcov-profile/84137
29455 * doc/gcov.texi: Fix typo in documentation.
29457 2018-02-05 Martin Liska <mliska@suse.cz>
29459 PR gcov-profile/83879
29460 * doc/gcov.texi: Document necessity of --dynamic-list-data when
29461 using dlopen functionality.
29463 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
29465 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
29466 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
29467 _mm_maskz_range_ss, _mm_mask_range_round_ss,
29468 _mm_maskz_range_round_ss): New intrinsics.
29469 (__builtin_ia32_rangesd128_round)
29470 (__builtin_ia32_rangess128_round): Remove.
29471 (__builtin_ia32_rangesd128_mask_round,
29472 __builtin_ia32_rangess128_mask_round): New builtins.
29473 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
29474 __builtin_ia32_rangess128_round): Remove.
29475 (__builtin_ia32_rangesd128_mask_round,
29476 __builtin_ia32_rangess128_mask_round): New builtins.
29477 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
29478 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
29479 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
29480 "<round_saeonly_constraint>")): Changed to ...
29481 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
29482 "<round_saeonly_scalar_constraint>")): ... this.
29483 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
29484 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
29485 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
29486 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
29487 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
29489 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
29491 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
29493 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
29494 Remove all values except native, 8540 and 8548.
29496 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
29498 * config/i386/i386.c (ix86_output_function_return): Pass
29499 INVALID_REGNUM, instead of -1, as invalid register number to
29500 indirect_thunk_name and output_indirect_thunk.
29502 2018-02-02 Julia Koval <julia.koval@intel.com>
29504 * config.gcc: Add -march=icelake.
29505 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
29506 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
29507 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
29508 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
29509 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
29510 (processor_target_table): Add icelake.
29511 (ix86_option_override_internal): Handle new PTAs.
29512 (get_builtin_code_for_version): Handle icelake.
29513 (M_INTEL_COREI7_ICELAKE): New.
29514 (fold_builtin_cpu): Handle icelake.
29515 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
29516 * doc/invoke.texi: Add -march=icelake.
29518 2018-02-02 Julia Koval <julia.koval@intel.com>
29520 * config/i386/i386.c (ix86_option_override_internal): Change flags type
29521 to wide_int_bitmask.
29522 * wide-int-bitmask.h: New.
29524 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
29527 * config/i386/i386.md: Replace Pmode with word_mode in
29528 builtin_setjmp_setup and builtin_longjmp to support x32.
29530 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
29534 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
29536 (rs6000_supported_cpu_names): New static variable.
29537 (linux_cpu_translation_table): Likewise.
29538 (elf_platform) <cpu>: Define new static variable and use it.
29539 Translate kernel AT_PLATFORM name to canonical name if needed.
29540 Error if platform name is unknown.
29542 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
29545 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
29547 2018-02-01 Jeff Law <law@redhat.com>
29550 * config/i386/i386.c (release_scratch_register_on_entry): Add new
29551 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
29552 the scratch if RELEASE_VIA_POP is false.
29553 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
29554 If we have to save a temporary register, decrement SIZE appropriately.
29555 Pass new arguments to release_scratch_register_on_entry.
29556 (ix86_adjust_stack_and_probe): Likewise.
29557 (ix86_emit_probe_stack_range): Pass new arguments to
29558 release_scratch_register_on_entry.
29560 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
29562 PR rtl-optimization/84157
29563 * combine.c (change_zero_ext): Use REG_P predicate in
29564 front of HARD_REGISTER_P predicate.
29566 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
29568 * config/avr/avr.c (avr_option_override): Move disabling of
29569 -fdelete-null-pointer-checks to...
29570 * common/config/avr/avr-common.c (avr_option_optimization_table):
29573 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
29575 PR tree-optimization/81635
29576 * tree-data-ref.c (split_constant_offset_1): For types that
29577 wrap on overflow, try to use range info to prove that wrapping
29580 2018-02-01 Renlin Li <renlin.li@arm.com>
29583 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
29584 TAILCALL_ADDR_REGS.
29585 (aarch64_register_move_cost): Likewise.
29586 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
29587 TAILCALL_ADDR_REGS.
29588 (REG_CLASS_NAMES): Likewise.
29589 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
29590 TAILCALL_ADDR_REGS. Remove IP registers.
29591 * config/aarch64/aarch64.md (Ucs): Update register constraint.
29593 2018-02-01 Richard Biener <rguenther@suse.de>
29595 * domwalk.h (dom_walker::dom_walker): Add additional constructor
29596 for specifying RPO order and allow NULL for that.
29597 * domwalk.c (dom_walker::dom_walker): Likewise.
29598 (dom_walker::walk): Handle NULL RPO order.
29599 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
29601 (rewrite_update_dom_walker): Likewise.
29602 (mark_def_dom_walker): Likewise.
29604 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
29606 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
29607 (aarch64_maybe_expand_sve_subreg_move): Declare.
29608 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
29609 * config/aarch64/predicates.md (aarch64_any_register_operand): New
29611 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
29612 that are semantically a reverse operation.
29613 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
29614 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
29615 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
29617 (aarch64_can_change_mode_class): For big-endian, forbid changes
29618 between two SVE modes if they have different element sizes.
29620 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
29622 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
29623 the TImode handling for big-endian targets.
29625 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
29627 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
29628 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
29630 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
29631 Remove BSWAP handing for big-endian targets and use the form of
29632 LD1RQ appropariate for the mode.
29634 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
29636 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
29637 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
29638 duplicated element.
29640 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
29643 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
29644 check for operands that need to go through aarch64_sve_reload_be.
29646 2018-02-01 Jakub Jelinek <jakub@redhat.com>
29648 PR tree-optimization/81661
29649 PR tree-optimization/84117
29650 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
29651 * tree-eh.c: Include gimplify.h.
29652 (find_trapping_overflow, replace_trapping_overflow,
29653 rewrite_to_non_trapping_overflow): New functions.
29654 * tree-vect-loop.c: Include tree-eh.h.
29655 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
29656 * tree-data-ref.c: Include tree-eh.h.
29657 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
29659 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
29661 PR rtl-optimization/84123
29662 * combine.c (change_zero_ext): Check if hard register satisfies
29663 can_change_dest_mode before calling gen_lowpart_SUBREG.
29665 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
29668 * ira.c (ira_init_register_move_cost): Remove assert.
29670 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
29672 PR rtl-optimization/84071
29673 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
29674 * doc/tm.texi: Regenerate.
29676 2018-01-31 Richard Biener <rguenther@suse.de>
29678 PR tree-optimization/84132
29679 * tree-data-ref.c (analyze_miv_subscript): Properly
29680 check whether evolution_function_is_affine_multivariate_p
29681 before calling gcd_of_steps_may_divide_p.
29683 2018-01-31 Julia Koval <julia.koval@intel.com>
29686 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
29687 * config/i386/i386.md (rdpid_rex64) New.
29688 (rdpid): Make 32bit only.
29690 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
29693 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
29694 an IDENTIFIER_NODE for FUNCTION_TYPE's.
29696 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
29699 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
29701 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
29703 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
29705 PR rtl-optimization/84071
29706 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
29707 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
29709 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
29711 * config/arc/arc.c (arc_handle_aux_attribute): New function.
29712 (arc_attribute_table): Add 'aux' attribute.
29713 (arc_in_small_data_p): Consider aux like variables.
29714 (arc_is_aux_reg_p): New function.
29715 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
29716 (arc_get_aux_arg): New function.
29717 (prepare_move_operands): Handle aux-register access.
29718 (arc_handle_aux_attribute): New function.
29719 * doc/extend.texi (ARC Variable attributes): Add subsection.
29721 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
29723 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
29724 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
29725 (arc_attribute_table): Add 'uncached' attribute.
29726 (arc_print_operand): Print '.di' flag for uncached memory
29728 (arc_in_small_data_p): Do not consider for small data the uncached
29730 (arc_is_uncached_mem_p): New function.
29731 * config/arc/predicates.md (compact_store_memory_operand): Check
29732 for uncached memory accesses.
29733 (nonvol_nonimm_operand): Likewise.
29734 * doc/extend.texi (ARC Type Attribute): New subsection.
29736 2018-01-31 Jakub Jelinek <jakub@redhat.com>
29739 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
29740 falign-loops=): Add Optimization flag.
29742 2018-01-30 Jeff Law <law@redhat.com>
29745 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
29746 INT_REGISTERS_SAVED. Check it prior to calling
29747 get_scratch_register_on_entry.
29748 (ix86_adjust_stack_and_probe): Similarly.
29749 (ix86_emit_probe_stack_range): Similarly.
29750 (ix86_expand_prologue): Corresponding changes.
29752 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
29755 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
29756 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
29758 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
29761 * lra-constraints.c (curr_insn_transform): Process AND in the
29764 2018-01-30 Jakub Jelinek <jakub@redhat.com>
29766 PR rtl-optimization/83986
29767 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
29768 dependence against last_pending_memory_flush in addition to
29769 pending_jump_insns.
29771 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
29773 PR tree-optimization/81611
29774 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
29777 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
29780 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
29783 2018-01-30 Richard Biener <rguenther@suse.de>
29784 Jakub Jelinek <jakub@redhat.com>
29786 PR tree-optimization/84111
29787 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
29788 inner loops added during recursion, as they don't have up-to-date
29791 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
29794 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
29795 (can_inline_edge_by_limits_p): ... here.
29796 (can_early_inline_edge_p, check_callers,
29797 update_caller_keys, update_callee_keys, recursive_inlining,
29798 add_new_edges_to_heap, speculation_useful_p,
29799 inline_small_functions,
29800 inline_small_functions, flatten_function,
29801 inline_to_all_callers_1): Update.
29803 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
29805 * profile-count.c (profile_count::combine_with_ipa_count): Handle
29808 2018-01-30 Richard Biener <rguenther@suse.de>
29810 PR tree-optimization/83008
29811 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
29812 invariant and constant vector uses in stmts when they need
29813 more than one stmt.
29815 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
29818 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
29819 * configure: Regenerate.
29821 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
29823 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
29825 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
29826 Use gen_rtx_REG rather than gen_lowpart.
29828 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
29830 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
29831 rather than 0 when creating partial subregs.
29833 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
29835 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
29838 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
29841 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
29842 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
29843 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
29844 flags. This restores the settings used before the 2017-07-24.
29845 Turning off pre increment/decrement/modify allows IVOPTS to
29846 optimize DF/SF loops where the index is an int.
29848 2018-01-29 Richard Biener <rguenther@suse.de>
29849 Kelvin Nilsen <kelvin@gcc.gnu.org>
29852 * tree-vect-stmts.c (vectorizable_call): Don't call
29853 targetm.vectorize_builtin_md_vectorized_function if callee is
29856 2018-01-22 Carl Love <cel@us.ibm.com>
29858 * doc/extend.tex: Fix typo in second arg in
29859 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
29861 2018-01-29 Richard Biener <rguenther@suse.de>
29863 PR tree-optimization/84086
29864 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
29865 (flush_ssaname_freelist): When SSA names were released reset
29866 the SCEV hash table.
29868 2018-01-29 Richard Biener <rguenther@suse.de>
29870 PR tree-optimization/84057
29871 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
29872 removed paths when removing edges.
29874 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
29876 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
29877 -mfunction-return=@var{choice}.
29879 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
29881 PR diagnostic/84034
29882 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
29883 Handle CR like TAB.
29884 (layout::print_source_line): Likewise.
29885 (test_get_line_width_without_trailing_whitespace): Add test cases.
29887 2018-01-27 Jakub Jelinek <jakub@redhat.com>
29889 PR middle-end/84040
29890 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
29893 2018-01-26 Jim Wilson <jimw@sifive.com>
29895 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
29897 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
29900 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
29902 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
29903 and CMP + SUB-immediate -> SUBS.
29905 2018-01-26 Martin Sebor <msebor@redhat.com>
29907 PR tree-optimization/83896
29908 * tree-ssa-strlen.c (get_string_len): Rename...
29909 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
29910 Avoid assuming length is constant.
29911 (handle_char_store): Use HOST_WIDE_INT for string length.
29913 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
29916 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
29917 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
29919 2018-01-26 Richard Biener <rguenther@suse.de>
29921 PR rtl-optimization/84003
29922 * dse.c (record_store): Only record redundant stores when
29923 the earlier store aliases at least all accesses the later one does.
29925 2018-01-26 Jakub Jelinek <jakub@redhat.com>
29927 PR rtl-optimization/83985
29928 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
29929 REG_CFA_RESTORE insns.
29930 (delete_unmarked_insns): Don't ignore separate shrink wrapping
29931 REG_CFA_RESTORE insns here.
29934 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
29935 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
29937 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
29939 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
29940 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
29941 (arc_init): Likewise.
29942 (arc_override_options): Likewise.
29943 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
29945 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
29947 * config/arc/arc.h (TARGET_DBNZ): Define.
29948 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
29949 properly set the tune attribute.
29950 (dbnz): Use TARGET_DBNZ guard.
29951 * config/arc/arc.opt (mtune): Add core3 option.
29953 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
29955 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
29956 recognize new pic like addresses.
29957 (arc_delegitimize_address): Clean up.
29959 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
29961 * config/arc/arc-arches.def: Option mrf16 valid for all
29963 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
29964 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
29965 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
29966 * config/arc/arc-tables.opt: Regenerate.
29967 * config/arc/arc.c (arc_conditional_register_usage): Handle
29968 reduced register file case.
29969 (arc_file_start): Set must have build attributes.
29970 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
29971 mrf16 option value.
29972 * config/arc/arc.opt (mrf16): Add new option.
29973 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
29974 * config/arc/genmultilib.awk: Handle new mrf16 option.
29975 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
29976 * config/arc/t-multilib: Regenerate.
29977 * doc/invoke.texi (ARC Options): Document mrf16 option.
29979 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
29981 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
29982 * config/arc/arc.c (arc_handle_secure_attribute): New function.
29983 (arc_attribute_table): Add 'secure_call' attribute.
29984 (arc_print_operand): Print secure call operand.
29985 (arc_function_ok_for_sibcall): Don't optimize tail calls when
29987 (arc_is_secure_call_p): New function. * config/arc/arc.md
29988 (call_i): Add support for sjli instruction.
29989 (call_value_i): Likewise.
29990 * config/arc/constraints.md (Csc): New constraint.
29992 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
29993 John Eric Martin <John.Martin@emmicro-us.com>
29995 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
29996 * config/arc/arc.c (_arc_jli_section): New struct.
29997 (arc_jli_section): New type.
29998 (rc_jli_sections): New static variable.
29999 (arc_handle_jli_attribute): New function.
30000 (arc_attribute_table): Add jli_always and jli_fixed attribute.
30001 (arc_file_end): New function.
30002 (TARGET_ASM_FILE_END): Define.
30003 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
30004 (arc_add_jli_section): New function.
30005 (jli_call_scan): Likewise.
30006 (arc_reorg): Call jli_call_scan.
30007 (arc_output_addsi): Remove 'S' from printing asm operand.
30008 (arc_is_jli_call_p): New function.
30009 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
30011 (movhi_insn): Likewise.
30012 (movsi_insn): Likewise.
30013 (movsi_set_cc_insn): Likewise.
30014 (loadqi_update): Likewise.
30015 (load_zeroextendqisi_update): Likewise.
30016 (load_signextendqisi_update): Likewise.
30017 (loadhi_update): Likewise.
30018 (load_zeroextendhisi_update): Likewise.
30019 (load_signextendhisi_update): Likewise.
30020 (loadsi_update): Likewise.
30021 (loadsf_update): Likewise.
30022 (movsicc_insn): Likewise.
30023 (bset_insn): Likewise.
30024 (bxor_insn): Likewise.
30025 (bclr_insn): Likewise.
30026 (bmsk_insn): Likewise.
30027 (bicsi3_insn): Likewise.
30028 (cmpsi_cc_c_insn): Likewise.
30029 (movsi_ne): Likewise.
30030 (movsi_cond_exec): Likewise.
30031 (clrsbsi2): Likewise.
30032 (norm_f): Likewise.
30042 (call_i): Remove 'S' asm letter, add jli instruction.
30043 (call_value_i): Likewise.
30044 * config/arc/arc.op (mjli-always): New option.
30045 * config/arc/constraints.md (Cji): New constraint.
30046 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
30048 (subsf3_fpx): Likewise.
30049 (mulsf3_fpx): Likewise.
30050 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
30052 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
30053 function attrbutes.
30054 * doc/invoke.texi (ARC): Document mjli-always option.
30056 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
30058 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
30059 avoid addition with 0 and use incw and decw where possible.
30061 2018-01-26 Richard Biener <rguenther@suse.de>
30063 PR tree-optimization/81082
30064 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
30065 association if it requires casting to unsigned.
30066 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
30067 from fold_plusminus_mult_expr to catch important cases late when
30068 range info is available.
30070 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
30072 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
30073 * configure.ac (hidden_linkonce): New test.
30074 * configure: Regenerate.
30075 * config.in: Regenerate.
30077 2018-01-26 Julia Koval <julia.koval@intel.com>
30079 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
30080 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
30081 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
30082 _mm_mask_bitshuffle_epi64_mask): Fix type.
30083 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
30084 USI_FTYPE_V4DI_V4DI_USI): Remove.
30085 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
30086 __builtin_ia32_vpshufbitqmb256_mask,
30087 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
30088 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
30089 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
30091 2018-01-26 Alan Modra <amodra@gmail.com>
30094 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
30095 UNSPEC_VBPERMQ. Sort other unspecs.
30097 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
30099 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
30101 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
30103 PR middle-end/83055
30104 * predict.c (drop_profile): Do not push/pop cfun; update also
30106 (handle_missing_profiles): Fix logic looking for zero profiles.
30108 2018-01-25 Jakub Jelinek <jakub@redhat.com>
30110 PR middle-end/83977
30111 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
30112 on functions with #pragma omp declare simd or functions with simd
30114 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
30115 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
30116 Remove trailing \n from warning_at calls.
30118 2018-01-25 Tom de Vries <tom@codesourcery.com>
30121 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
30122 for neutered workers.
30124 2018-01-24 Joseph Myers <joseph@codesourcery.com>
30127 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
30128 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
30130 2018-01-24 Jeff Law <law@redhat.com>
30133 * i386.c (get_probe_interval): Move to earlier point.
30134 (ix86_compute_frame_layout): If -fstack-clash-protection and
30135 the frame is larger than the probe interval, then use pushes
30136 to save registers rather than reg->mem moves.
30137 (ix86_expand_prologue): Remove conditional for int_registers_saved
30140 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
30143 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
30144 min/max for never referenced object.
30146 2018-01-24 Jakub Jelinek <jakub@redhat.com>
30148 PR middle-end/83977
30149 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
30151 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
30152 attributes from DECL_ATTRIBUTES (decl) without affecting
30153 DECL_ATTRIBUTES (current_function_decl).
30154 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
30155 functions with non-NULL DECL_ABSTRACT_ORIGIN.
30157 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
30159 PR tree-optimization/83979
30160 * fold-const.c (fold_comparison): Use constant_boolean_node
30161 instead of boolean_{true,false}_node.
30163 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
30165 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
30168 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
30170 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
30171 Simplify the clause that sets the length attribute.
30172 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
30173 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
30174 clause that sets the length attribute.
30175 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
30177 2018-01-24 Tom de Vries <tom@codesourcery.com>
30180 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
30181 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
30182 Add strict parameter.
30183 (prevent_branch_around_nothing): Insert dummy insn between branch to
30184 label and label with no ptx insn inbetween.
30185 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
30187 2018-01-24 Tom de Vries <tom@codesourcery.com>
30190 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
30191 for neutered threads in warp.
30192 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
30194 2018-01-24 Richard Biener <rguenther@suse.de>
30196 PR tree-optimization/83176
30197 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
30200 2018-01-24 Richard Biener <rguenther@suse.de>
30202 PR tree-optimization/82819
30203 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
30204 code generating pluses that are no-ops in the target precision.
30206 2018-01-24 Richard Biener <rguenther@suse.de>
30208 PR middle-end/84000
30209 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
30211 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
30213 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
30214 to merge probabilities.
30215 * predict.c (probably_never_executed): Also mark as cold functions
30216 with global 0 profile and guessed local profile.
30217 * profile-count.c (profile_probability::combine_with_count): New
30219 * profile-count.h (profile_probability::operator*,
30220 profile_probability::operator*=, profile_probability::operator/,
30221 profile_probability::operator/=): Reduce precision to adjusted
30222 and set value to guessed on contradictory divisions.
30223 (profile_probability::combine_with_freq): Remove.
30224 (profile_probability::combine_wiht_count): Declare.
30225 (profile_count::force_nonzero):: Set to adjusted.
30226 (profile_count::probability_in):: Set quality to adjusted.
30227 * tree-ssa-tail-merge.c (replace_block_by): Use
30228 combine_with_count.
30230 2018-01-23 Andrew Waterman <andrew@sifive.com>
30231 Jim Wilson <jimw@sifive.com>
30233 * config/riscv/riscv.c (riscv_stack_boundary): New.
30234 (riscv_option_override): Set riscv_stack_boundary. Handle
30235 riscv_preferred_stack_boundary_arg.
30236 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
30237 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
30238 (STACK_BOUNDARY): Set to riscv_stack_boundary.
30239 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
30240 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
30241 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
30243 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
30246 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
30247 of struct ix86_frame.
30248 (ix86_expand_epilogue): Likewise. Add a local variable for
30249 the reg_save_offset field in struct ix86_frame.
30251 2018-01-23 Bin Cheng <bin.cheng@arm.com>
30253 PR tree-optimization/82604
30254 * tree-loop-distribution.c (enum partition_kind): New enum item
30255 PKIND_PARTIAL_MEMSET.
30256 (partition_builtin_p): Support above new enum item.
30257 (generate_code_for_partition): Ditto.
30258 (compute_access_range): Differentiate cases that equality can be
30259 proven at all loops, the innermost loops or no loops.
30260 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
30261 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
30262 (finalize_partitions, distribute_loop): Don't fuse partition of
30263 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
30264 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
30265 parloop is enabled.
30267 2018-01-23 Martin Liska <mliska@suse.cz>
30269 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
30270 order to ignore the predictor.
30271 (PRED_POLYMORPHIC_CALL): Likewise.
30272 (PRED_RECURSIVE_CALL): Likewise.
30274 2018-01-23 Martin Liska <mliska@suse.cz>
30276 * tree-profile.c (tree_profiling): Print function header to
30277 aware reader which function we are working on.
30278 * value-prof.c (gimple_find_values_to_profile): Do not print
30279 not interesting value histograms.
30281 2018-01-23 Martin Liska <mliska@suse.cz>
30283 * profile-count.h (enum profile_quality): Add
30284 profile_uninitialized as the first value. Do not number values
30285 as they are zero based.
30286 (profile_count::verify): Update sanity check.
30287 (profile_probability::verify): Likewise.
30289 2018-01-23 Nathan Sidwell <nathan@acm.org>
30291 * doc/invoke.texi (ffor-scope): Deprecate.
30293 2018-01-23 David Malcolm <dmalcolm@redhat.com>
30295 PR tree-optimization/83510
30296 * domwalk.c (set_all_edges_as_executable): New function.
30297 (dom_walker::dom_walker): Convert bool param
30298 "skip_unreachable_blocks" to enum reachability. Move setup of
30299 edge flags to set_all_edges_as_executable and only do it when
30300 reachability is REACHABLE_BLOCKS.
30301 * domwalk.h (enum dom_walker::reachability): New enum.
30302 (dom_walker::dom_walker): Convert bool param
30303 "skip_unreachable_blocks" to enum reachability.
30304 (set_all_edges_as_executable): New decl.
30305 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
30306 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
30308 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
30309 but converting true to REACHABLE_BLOCKS.
30310 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
30312 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
30313 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
30314 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
30316 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
30317 if check_all_array_refs will be called.
30319 2018-01-23 David Malcolm <dmalcolm@redhat.com>
30321 * tree.c (selftest::test_location_wrappers): Add more test
30324 2018-01-23 David Malcolm <dmalcolm@redhat.com>
30326 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
30327 (selftest::test_bit_in_range): Likewise.
30329 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
30332 * doc/sourcebuild.texi (vect_float): Say that the selector
30333 only describes the situation when -funsafe-math-optimizations is on.
30334 (vect_float_strict): Document.
30336 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
30338 PR tree-optimization/83965
30339 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
30340 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
30341 instead of checking only for a reduction.
30342 (vect_recog_widen_sum_pattern): Likewise.
30344 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
30346 * predict.c (probably_never_executed): Only use precise profile info.
30347 (compute_function_frequency): Skip after inlining hack since we now
30348 have quality checking.
30350 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
30352 * profile-count.h (profile_probability::very_unlikely,
30353 profile_probability::unlikely, profile_probability::even): Set
30354 precision to guessed.
30356 2018-01-23 Richard Biener <rguenther@suse.de>
30358 PR tree-optimization/83963
30359 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
30360 Properly terminate dominator walk when crossing the exit edge not
30361 when visiting its source block.
30363 2018-01-23 Jakub Jelinek <jakub@redhat.com>
30366 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
30367 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
30369 2018-01-22 Jakub Jelinek <jakub@redhat.com>
30371 PR tree-optimization/83957
30372 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
30373 semicolon after for body surrounded by braces.
30375 PR tree-optimization/83081
30376 * profile-count.h (profile_probability::split): New method.
30377 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
30378 Use profile_probability::split.
30379 (do_compare_rtx_and_jump): Fix adjustment of probabilities
30380 when splitting a single conditional jump into 2.
30382 2018-01-22 David Malcolm <dmalcolm@redhat.com>
30384 PR tree-optimization/69452
30385 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
30388 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30390 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
30391 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
30392 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
30394 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30396 * config/rl78/rl78-protos.h (rl78_split_movdi): New function
30398 * config/rl78/rl78.md (movdi): New define_expand.
30399 * config/rl78/rl78.c (rl78_split_movdi): New function.
30401 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
30404 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
30406 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
30407 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
30408 128-bit to produce an UNSPEC move to get the double word with the
30409 signbit and then a shift directly to do signbit.
30410 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
30411 implementation with a new version that just does either a direct
30412 move or a regular move. Move memory interface to separate insns.
30413 Move insns so they are next to the expander.
30414 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
30415 with signbit move. Split big and little endian case.
30416 (signbit<mode>2_dm_mem_le): Likewise.
30417 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
30418 (signbit<mode>2_dm2): Likewise.
30420 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30422 * config/rl78/rl78.md (anddi3): New define_expand.
30424 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30426 * config/rl78/rl78.md (umindi3): New define_expand.
30428 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30430 * config/rl78/rl78.md (smindi3): New define_expand.
30432 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30434 * config/rl78/rl78.md (smaxdi3): New define_expand.
30436 2018-01-22 Carl Love <cel@us.ibm.com>
30438 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
30439 LVX_V1TI): Add macro expansion.
30440 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
30441 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
30442 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
30443 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
30444 Change check to determine if the instruction is a byte reversing
30445 entry. Fix typo in comment.
30446 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
30447 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
30448 Add def_builtin calls for new builtins.
30449 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
30450 Add define_insn expansion.
30452 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30454 * config/rl78/rl78.md (umaxdi3): New define_expand.
30456 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30458 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
30459 for non-QImode registers.
30461 2018-01-22 Richard Biener <rguenther@suse.de>
30463 PR tree-optimization/83963
30464 * graphite-scop-detection.c (scop_detection::get_sese): Delay
30465 including the loop exit block.
30466 (scop_detection::merge_sese): Likewise.
30467 (scop_detection::add_scop): Do it here instead.
30469 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
30471 * doc/sourcebuild.texi (arm_softfloat): Document.
30473 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
30476 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
30477 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
30478 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
30480 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
30481 David Edelsohn <dje.gcc@gmail.com>
30484 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
30485 Change "crset eq" to "crset 2".
30486 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
30487 (*call_indirect_aix<mode>_nospec): Likewise.
30488 (*call_value_indirect_aix<mode>_nospec): Likewise.
30489 (*call_indirect_elfv2<mode>_nospec): Likewise.
30490 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
30491 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
30492 change assembly output from . to $.
30493 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
30494 (indirect_jump<mode>_nospec): Change assembly output from . to $.
30495 (*tablejump<mode>_internal1_nospec): Likewise.
30497 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
30500 * config/sh/sh_optimize_sett_clrt.cc:
30501 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
30503 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
30505 PR tree-optimization/83940
30506 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
30507 offset_dt to vect_constant_def rather than vect_unknown_def_type.
30508 (vect_check_load_store_mask): Add a mask_dt_out parameter and
30509 use it to pass back the definition type.
30510 (vect_check_store_rhs): Likewise rhs_dt_out.
30511 (vect_build_gather_load_calls): Add a mask_dt argument and use
30512 it instead of a call to vect_is_simple_use.
30513 (vectorizable_store): Update calls to vect_check_load_store_mask
30514 and vect_check_store_rhs. Use the dt returned by the latter instead
30515 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
30516 instead of calls to vect_is_simple_use. Pass the scalar rather
30517 than the vector operand to vect_is_simple_use when handling
30518 second and subsequent copies of an rhs value.
30519 (vectorizable_load): Update calls to vect_check_load_store_mask
30520 and vect_build_gather_load_calls. Use the cached mask_dt and
30521 gs_info.offset_dt instead of calls to vect_is_simple_use.
30523 2018-01-20 Jakub Jelinek <jakub@redhat.com>
30525 PR middle-end/83945
30526 * tree-emutls.c: Include gimplify.h.
30527 (lower_emutls_2): New function.
30528 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
30529 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
30530 it before further processing.
30533 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
30534 UINTVAL (trueop1) instead of INTVAL (op1).
30536 2018-01-19 Jakub Jelinek <jakub@redhat.com>
30540 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
30541 INCOMING_FRAME_SP_OFFSET if not defined.
30542 (scan_trace): Add ENTRY argument. If true and
30543 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
30544 emit a note to adjust the CFA offset.
30545 (create_cfi_notes): Adjust scan_trace callers.
30546 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
30547 INCOMING_FRAME_SP_OFFSET in the CIE.
30548 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
30549 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
30551 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
30552 * doc/tm.texi: Regenerated.
30554 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
30556 PR rtl-optimization/83147
30557 * lra-constraints.c (remove_inheritance_pseudos): Use
30558 lra_substitute_pseudo_within_insn.
30560 2018-01-19 Tom de Vries <tom@codesourcery.com>
30561 Cesar Philippidis <cesar@codesourcery.com>
30564 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
30566 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
30569 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
30570 spaces for function labels.
30572 2018-01-19 Martin Liska <mliska@suse.cz>
30574 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
30575 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
30576 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
30577 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
30578 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
30579 (PRED_CONST_RETURN): Change from 69 to 65.
30580 (PRED_NULL_RETURN): Change from 91 to 71.
30581 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
30582 (PRED_LOOP_GUARD): Change from 66 to 73.
30584 2018-01-19 Martin Liska <mliska@suse.cz>
30586 * predict.c (predict_insn_def): Add new assert.
30587 (struct branch_predictor): Change type to signed integer.
30588 (test_prediction_value_range): Amend test to cover
30589 PROB_UNINITIALIZED.
30590 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
30591 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
30592 (PRED_LOOP_ITERATIONS_MAX): Likewise.
30593 (PRED_LOOP_IV_COMPARE): Likewise.
30594 * predict.h (PROB_UNINITIALIZED): Define new constant.
30596 2018-01-19 Martin Liska <mliska@suse.cz>
30598 * predict.c (dump_prediction): Add new format for
30599 analyze_brprob.py script which is enabled with -details
30601 * profile-count.h (precise_p): New function.
30603 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
30605 PR tree-optimization/83922
30606 * tree-vect-loop.c (vect_verify_full_masking): Return false if
30607 there are no statements that need masking.
30608 (vect_active_double_reduction_p): New function.
30609 (vect_analyze_loop_operations): Use it when handling phis that
30610 are not in the loop header.
30612 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
30614 PR tree-optimization/83914
30615 * tree-vect-loop.c (vectorizable_induction): Don't convert
30616 init_expr or apply the peeling adjustment for inductions
30617 that are nested within the vectorized loop.
30619 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
30621 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
30624 2018-01-18 Jakub Jelinek <jakub@redhat.com>
30628 * function.h (gimplify_parameters): Add gimple_seq * argument.
30629 * function.c: Include gimple.h and options.h.
30630 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
30631 for the added local temporaries if needed.
30632 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
30633 if there are any parameter cleanups, wrap whole body into a
30634 try/finally with the cleanups.
30636 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
30639 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
30640 Use GET_MODE_CLASS for scalar floating point.
30642 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
30646 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
30647 Fix call of call_cgraph_insertion_hooks.
30649 2018-01-18 Martin Sebor <msebor@redhat.com>
30651 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
30653 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
30656 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
30659 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
30662 * common.opt: (-ffile-prefix-map): New option.
30663 * opts.c (common_handle_option): Defer it.
30664 * opts-global.c (handle_common_deferred_options): Handle it.
30665 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
30666 * file-prefix-map.h: New file.
30667 (remap_debug_filename, add_debug_prefix_map): ...here.
30668 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
30669 * final.c (debug_prefix_map, add_debug_prefix_map
30670 remap_debug_filename): Move to...
30671 * file-prefix-map.c: New file.
30672 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
30673 generalize, get rid of alloca(), use strrchr() instead of strchr().
30674 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
30675 Implement in terms of add_prefix_map().
30676 (remap_macro_filename, remap_debug_filename): Implement in term of
30678 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
30679 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
30680 * dbxout.c: Include file-prefix-map.h.
30681 * varasm.c: Likewise.
30682 * vmsdbgout.c: Likewise.
30683 * xcoffout.c: Likewise.
30684 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
30685 * doc/cppopts.texi (-fmacro-prefix-map): Document.
30686 * doc/invoke.texi (-ffile-prefix-map): Document.
30687 (-fdebug-prefix-map): Update description.
30689 2018-01-18 Martin Liska <mliska@suse.cz>
30691 * config/i386/i386.c (indirect_thunk_name): Document that also
30693 (output_indirect_thunk): Document why both instructions
30694 (pause and lfence) are generated.
30696 2018-01-18 Richard Biener <rguenther@suse.de>
30698 PR tree-optimization/83887
30699 * graphite-scop-detection.c
30700 (scop_detection::get_nearest_dom_with_single_entry): Remove.
30701 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
30702 (scop_detection::merge_sese): Re-implement with a flood-fill
30703 algorithm that properly finds a SESE region if it exists.
30705 2018-01-18 Jakub Jelinek <jakub@redhat.com>
30708 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
30709 pointer_diff optimizations use view_convert instead of convert.
30711 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
30713 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
30714 Generate different code for -mno-speculate-indirect-jumps.
30715 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
30716 (*call_indirect_aix<mode>): Disable for
30717 -mno-speculate-indirect-jumps.
30718 (*call_indirect_aix<mode>_nospec): New define_insn.
30719 (*call_value_indirect_aix<mode>): Disable for
30720 -mno-speculate-indirect-jumps.
30721 (*call_value_indirect_aix<mode>_nospec): New define_insn.
30722 (*sibcall_nonlocal_sysv<mode>): Generate different code for
30723 -mno-speculate-indirect-jumps.
30724 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
30726 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
30728 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
30729 long double type, set the flags for noting the default long double
30730 type, even if we don't pass or return a long double type.
30732 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
30735 * ipa-inline.c (flatten_function): Do not overwrite final inlining
30738 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
30740 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
30741 support for merge[hl].
30742 (fold_mergehl_helper): New helper function.
30743 (tree-vector-builder.h): New #include for tree_vector_builder usage.
30744 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
30745 (altivec_vmrglw_direct): Add xxmrglw insn.
30747 2018-01-17 Andrew Waterman <andrew@sifive.com>
30749 * config/riscv/riscv.c (riscv_conditional_register_usage): If
30750 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
30752 2018-01-17 David Malcolm <dmalcolm@redhat.com>
30755 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
30756 call the lto_location_cache before reading the
30757 DECL_SOURCE_LOCATION of the types.
30759 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
30760 Richard Sandiford <richard.sandiford@linaro.org>
30762 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
30763 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
30764 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
30765 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
30766 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
30768 * config/aarch64/constraints.md (aarch64_movti_operand):
30770 * config/aarch64/predicates.md (Uti): Add new constraint.
30772 2018-01-17 Carl Love <cel@us.ibm.com>
30774 * config/rs6000/vsx.md (define_expand xl_len_r,
30775 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
30776 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
30778 (define_expand, define_insn): Move the shift left from the
30779 define_insn to the define_expand for lxvl and stxvl instructions.
30780 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
30781 and XL_LEN_R definitions to PURE.
30783 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
30785 * config/i386/i386.c (indirect_thunk_name): Declare regno
30786 as unsigned int. Compare regno with INVALID_REGNUM.
30787 (output_indirect_thunk): Ditto.
30788 (output_indirect_thunk_function): Ditto.
30789 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
30790 in the call to output_indirect_thunk_function.
30792 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
30794 PR middle-end/83884
30795 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
30796 rather than the size of inner_type to determine the stack slot size
30797 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
30799 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
30802 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
30805 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
30807 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
30808 endian Linux systems to optionally enable multilibs for selecting
30809 the long double type if the user configured an explicit type.
30810 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
30811 have no long double multilibs if not defined.
30812 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
30813 warn if the user used -mabi={ieee,ibm}longdouble and we built
30814 multilibs for long double.
30815 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
30816 appropriate multilib option.
30817 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
30819 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
30820 for building long double multilibs.
30821 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
30823 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
30825 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
30828 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
30830 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
30833 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
30836 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
30839 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
30841 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
30842 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
30844 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
30846 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
30847 different rtl trees depending on TARGET_64BIT.
30848 (rs6000_gen_lvx): Likewise.
30850 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
30852 * config/visium/visium.md (nop): Tweak comment.
30853 (hazard_nop): Likewise.
30855 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
30857 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
30858 -mspeculate-indirect-jumps.
30859 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
30860 for -mno-speculate-indirect-jumps.
30861 (*call_indirect_elfv2<mode>_nospec): New define_insn.
30862 (*call_value_indirect_elfv2<mode>): Disable for
30863 -mno-speculate-indirect-jumps.
30864 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
30865 (indirect_jump): Emit different RTL for
30866 -mno-speculate-indirect-jumps.
30867 (*indirect_jump<mode>): Disable for
30868 -mno-speculate-indirect-jumps.
30869 (*indirect_jump<mode>_nospec): New define_insn.
30870 (tablejump): Emit different RTL for
30871 -mno-speculate-indirect-jumps.
30872 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
30873 (tablejumpsi_nospec): New define_expand.
30874 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
30875 (tablejumpdi_nospec): New define_expand.
30876 (*tablejump<mode>_internal1): Disable for
30877 -mno-speculate-indirect-jumps.
30878 (*tablejump<mode>_internal1_nospec): New define_insn.
30879 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
30882 2018-01-16 Artyom Skrobov tyomitch@gmail.com
30884 * caller-save.c (insert_save): Drop unnecessary parameter. All
30887 2018-01-16 Jakub Jelinek <jakub@redhat.com>
30888 Richard Biener <rguenth@suse.de>
30891 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
30892 return early, inline manually is_gimple_sizepos. Make sure if we
30893 call gimplify_expr we don't end up with a gimple constant.
30894 * tree.c (variably_modified_type_p): Don't return true for
30895 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
30896 * gimplify.h (is_gimple_sizepos): Remove.
30898 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
30900 PR tree-optimization/83857
30901 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
30902 vectorizable_live_operation for pure SLP statements.
30903 (vectorizable_live_operation): Handle PHIs.
30905 2018-01-16 Richard Biener <rguenther@suse.de>
30907 PR tree-optimization/83867
30908 * tree-vect-stmts.c (vect_transform_stmt): Precompute
30909 nested_in_vect_loop_p since the scalar stmt may get invalidated.
30911 2018-01-16 Jakub Jelinek <jakub@redhat.com>
30914 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
30915 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
30916 If off is not INTEGER_CST, issue a may not be aligned warning
30917 rather than isn't aligned. Use isn%'t rather than isn't.
30918 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
30920 <case MULT_EXPR>: Improve the case when bottom and one of the
30921 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
30922 operand, in that case check if the other operand is multiple of
30923 bottom divided by the INTEGER_CST operand.
30925 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
30928 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
30929 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
30930 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
30931 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
30932 * config/pa/pa.c (pa_function_arg_advance): Likewise.
30933 (pa_function_arg, pa_arg_partial_bytes): Likewise.
30934 (pa_function_arg_size): New function.
30936 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
30938 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
30939 in a separate statement.
30941 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
30943 PR tree-optimization/83847
30944 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
30945 group gathers and scatters.
30947 2018-01-16 Jakub Jelinek <jakub@redhat.com>
30949 PR rtl-optimization/86620
30950 * params.def (max-sched-ready-insns): Bump minimum value to 1.
30952 PR rtl-optimization/83213
30953 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
30954 to last if both are JUMP_INSNs.
30956 PR tree-optimization/83843
30957 * gimple-ssa-store-merging.c
30958 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
30959 store_immediate_info for bswap/nop orig_stores.
30961 2018-01-15 Andrew Waterman <andrew@sifive.com>
30963 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
30965 <UDIV>: Increase cost if !TARGET_DIV.
30967 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
30969 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
30970 (define_attr "cr_logical_3op"): New.
30971 (cceq_ior_compare): Adjust.
30972 (cceq_ior_compare_complement): Adjust.
30973 (*cceq_rev_compare): Adjust.
30974 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
30975 (is_cracked_insn): Adjust.
30976 (insn_must_be_first_in_group): Adjust.
30977 * config/rs6000/40x.md: Adjust.
30978 * config/rs6000/440.md: Adjust.
30979 * config/rs6000/476.md: Adjust.
30980 * config/rs6000/601.md: Adjust.
30981 * config/rs6000/603.md: Adjust.
30982 * config/rs6000/6xx.md: Adjust.
30983 * config/rs6000/7450.md: Adjust.
30984 * config/rs6000/7xx.md: Adjust.
30985 * config/rs6000/8540.md: Adjust.
30986 * config/rs6000/cell.md: Adjust.
30987 * config/rs6000/e300c2c3.md: Adjust.
30988 * config/rs6000/e500mc.md: Adjust.
30989 * config/rs6000/e500mc64.md: Adjust.
30990 * config/rs6000/e5500.md: Adjust.
30991 * config/rs6000/e6500.md: Adjust.
30992 * config/rs6000/mpc.md: Adjust.
30993 * config/rs6000/power4.md: Adjust.
30994 * config/rs6000/power5.md: Adjust.
30995 * config/rs6000/power6.md: Adjust.
30996 * config/rs6000/power7.md: Adjust.
30997 * config/rs6000/power8.md: Adjust.
30998 * config/rs6000/power9.md: Adjust.
30999 * config/rs6000/rs64.md: Adjust.
31000 * config/rs6000/titan.md: Adjust.
31002 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31004 * config/i386/predicates.md (indirect_branch_operand): Rewrite
31005 ix86_indirect_branch_register logic.
31007 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31009 * config/i386/constraints.md (Bs): Update
31010 ix86_indirect_branch_register check. Don't check
31011 ix86_indirect_branch_register with GOT_memory_operand.
31013 * config/i386/predicates.md (GOT_memory_operand): Don't check
31014 ix86_indirect_branch_register here.
31015 (GOT32_symbol_operand): Likewise.
31017 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31019 * config/i386/predicates.md (constant_call_address_operand):
31020 Rewrite ix86_indirect_branch_register logic.
31021 (sibcall_insn_operand): Likewise.
31023 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31025 * config/i386/constraints.md (Bs): Replace
31026 ix86_indirect_branch_thunk_register with
31027 ix86_indirect_branch_register.
31029 * config/i386/i386.md (indirect_jump): Likewise.
31030 (tablejump): Likewise.
31031 (*sibcall_memory): Likewise.
31032 (*sibcall_value_memory): Likewise.
31033 Peepholes of indirect call and jump via memory: Likewise.
31034 * config/i386/i386.opt: Likewise.
31035 * config/i386/predicates.md (indirect_branch_operand): Likewise.
31036 (GOT_memory_operand): Likewise.
31037 (call_insn_operand): Likewise.
31038 (sibcall_insn_operand): Likewise.
31039 (GOT32_symbol_operand): Likewise.
31041 2018-01-15 Jakub Jelinek <jakub@redhat.com>
31043 PR middle-end/83837
31044 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
31045 type rather than type addr's type points to.
31046 (expand_omp_atomic_mutex): Likewise.
31047 (expand_omp_atomic): Likewise.
31049 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31052 * config/i386/i386.c (output_indirect_thunk_function): Use
31053 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
31054 for __x86_return_thunk.
31056 2018-01-15 Richard Biener <rguenther@suse.de>
31058 PR middle-end/83850
31059 * expmed.c (extract_bit_field_1): Fix typo.
31061 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
31064 * config/arm/iterators.md (VF): New mode iterator.
31065 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
31066 Remove integer-related logic from pattern.
31067 (neon_vabd<mode>_3): Likewise.
31069 2018-01-15 Jakub Jelinek <jakub@redhat.com>
31071 PR middle-end/82694
31072 * common.opt (fstrict-overflow): No longer an alias.
31073 (fwrapv-pointer): New option.
31074 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
31075 also for pointer types based on flag_wrapv_pointer.
31076 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
31077 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
31078 opts->x_flag_wrapv got set.
31079 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
31080 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
31081 POINTER_TYPE_OVERFLOW_UNDEFINED.
31082 * match.pd: Likewise in address comparison pattern.
31083 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
31085 2018-01-15 Richard Biener <rguenther@suse.de>
31088 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
31089 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
31090 Reset type names to their identifier if their TYPE_DECL doesn't
31091 have linkage (and thus is used for ODR and devirt).
31092 (save_debug_info_for_decl): Remove.
31093 (save_debug_info_for_type): Likewise.
31094 (add_tree_to_fld_list): Adjust.
31095 * tree-pretty-print.c (dump_generic_node): Make dumping of
31096 type names more robust.
31098 2018-01-15 Richard Biener <rguenther@suse.de>
31100 * BASE-VER: Bump to 8.0.1.
31102 2018-01-14 Martin Sebor <msebor@redhat.com>
31105 * builtins.c (check_access): Avoid warning when the no-warning bit
31108 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
31110 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
31111 * ira-color (allocno_hard_regs_compare): Likewise.
31113 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
31116 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
31117 Use .pushsection/.popsection.
31119 2018-01-14 Martin Sebor <msebor@redhat.com>
31122 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
31124 2018-01-14 Jakub Jelinek <jakub@redhat.com>
31126 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
31127 entry from extra_headers.
31128 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
31129 extra_headers, make the list bitwise identical to the i?86-*-* one.
31131 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31133 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
31134 -mcmodel=large with -mindirect-branch=thunk,
31135 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
31136 -mfunction-return=thunk-extern.
31137 * doc/invoke.texi: Document -mcmodel=large is incompatible with
31138 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
31139 -mfunction-return=thunk and -mfunction-return=thunk-extern.
31141 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31143 * config/i386/i386.c (print_reg): Print the name of the full
31144 integer register without '%'.
31145 (ix86_print_operand): Handle 'V'.
31146 * doc/extend.texi: Document 'V' modifier.
31148 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31150 * config/i386/constraints.md (Bs): Disallow memory operand for
31151 -mindirect-branch-register.
31153 * config/i386/predicates.md (indirect_branch_operand): Likewise.
31154 (GOT_memory_operand): Likewise.
31155 (call_insn_operand): Likewise.
31156 (sibcall_insn_operand): Likewise.
31157 (GOT32_symbol_operand): Likewise.
31158 * config/i386/i386.md (indirect_jump): Call convert_memory_address
31159 for -mindirect-branch-register.
31160 (tablejump): Likewise.
31161 (*sibcall_memory): Likewise.
31162 (*sibcall_value_memory): Likewise.
31163 Disallow peepholes of indirect call and jump via memory for
31164 -mindirect-branch-register.
31165 (*call_pop): Replace m with Bw.
31166 (*call_value_pop): Likewise.
31167 (*sibcall_pop_memory): Replace m with Bs.
31168 * config/i386/i386.opt (mindirect-branch-register): New option.
31169 * doc/invoke.texi: Document -mindirect-branch-register option.
31171 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31173 * config/i386/i386-protos.h (ix86_output_function_return): New.
31174 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
31175 set function_return_type.
31176 (indirect_thunk_name): Add ret_p to indicate thunk for function
31178 (output_indirect_thunk_function): Pass false to
31179 indirect_thunk_name.
31180 (ix86_output_indirect_branch_via_reg): Likewise.
31181 (ix86_output_indirect_branch_via_push): Likewise.
31182 (output_indirect_thunk_function): Create alias for function
31183 return thunk if regno < 0.
31184 (ix86_output_function_return): New function.
31185 (ix86_handle_fndecl_attribute): Handle function_return.
31186 (ix86_attribute_table): Add function_return.
31187 * config/i386/i386.h (machine_function): Add
31188 function_return_type.
31189 * config/i386/i386.md (simple_return_internal): Use
31190 ix86_output_function_return.
31191 (simple_return_internal_long): Likewise.
31192 * config/i386/i386.opt (mfunction-return=): New option.
31193 (indirect_branch): Mention -mfunction-return=.
31194 * doc/extend.texi: Document function_return function attribute.
31195 * doc/invoke.texi: Document -mfunction-return= option.
31197 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31199 * config/i386/i386-opts.h (indirect_branch): New.
31200 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
31201 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
31202 with local indirect jump when converting indirect call and jump.
31203 (ix86_set_indirect_branch_type): New.
31204 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
31205 (indirectlabelno): New.
31206 (indirect_thunk_needed): Likewise.
31207 (indirect_thunk_bnd_needed): Likewise.
31208 (indirect_thunks_used): Likewise.
31209 (indirect_thunks_bnd_used): Likewise.
31210 (INDIRECT_LABEL): Likewise.
31211 (indirect_thunk_name): Likewise.
31212 (output_indirect_thunk): Likewise.
31213 (output_indirect_thunk_function): Likewise.
31214 (ix86_output_indirect_branch_via_reg): Likewise.
31215 (ix86_output_indirect_branch_via_push): Likewise.
31216 (ix86_output_indirect_branch): Likewise.
31217 (ix86_output_indirect_jmp): Likewise.
31218 (ix86_code_end): Call output_indirect_thunk_function if needed.
31219 (ix86_output_call_insn): Call ix86_output_indirect_branch if
31221 (ix86_handle_fndecl_attribute): Handle indirect_branch.
31222 (ix86_attribute_table): Add indirect_branch.
31223 * config/i386/i386.h (machine_function): Add indirect_branch_type
31224 and has_local_indirect_jump.
31225 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
31227 (tablejump): Likewise.
31228 (*indirect_jump): Use ix86_output_indirect_jmp.
31229 (*tablejump_1): Likewise.
31230 (simple_return_indirect_internal): Likewise.
31231 * config/i386/i386.opt (mindirect-branch=): New option.
31232 (indirect_branch): New.
31235 (thunk-inline): Likewise.
31236 (thunk-extern): Likewise.
31237 * doc/extend.texi: Document indirect_branch function attribute.
31238 * doc/invoke.texi: Document -mindirect-branch= option.
31240 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
31243 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
31245 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
31247 * ipa-inline.c (want_inline_small_function_p): Return false if
31248 inlining has already failed with CIF_FINAL_ERROR.
31249 (update_caller_keys): Call want_inline_small_function_p before
31251 (update_callee_keys): Likewise.
31253 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
31255 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
31257 (rs6000_quadword_masked_address_p): Likewise.
31258 (quad_aligned_load_p): Likewise.
31259 (quad_aligned_store_p): Likewise.
31260 (const_load_sequence_p): Add comment to describe the outer-most loop.
31261 (mimic_memory_attributes_and_flags): New function.
31262 (rs6000_gen_stvx): Likewise.
31263 (replace_swapped_aligned_store): Likewise.
31264 (rs6000_gen_lvx): Likewise.
31265 (replace_swapped_aligned_load): Likewise.
31266 (replace_swapped_load_constant): Capitalize argument name in
31267 comment describing this function.
31268 (rs6000_analyze_swaps): Add a third pass to search for vector loads
31269 and stores that access quad-word aligned addresses and replace
31270 with stvx or lvx instructions when appropriate.
31271 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
31272 New function prototype.
31273 (rs6000_quadword_masked_address_p): Likewise.
31274 (rs6000_gen_lvx): Likewise.
31275 (rs6000_gen_stvx): Likewise.
31276 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
31277 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
31278 when memory address is aligned.
31279 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
31280 this split to select lvx instruction when memory address is aligned.
31281 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
31282 instruction when memory address is aligned.
31283 (*vsx_le_perm_load_v16qi): Likewise.
31284 (four unnamed splitters): Modify to select the stvx instruction
31285 when memory is aligned.
31287 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
31289 * predict.c (determine_unlikely_bbs): Handle correctly BBs
31290 which appears in the queue multiple times.
31292 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31293 Alan Hayward <alan.hayward@arm.com>
31294 David Sherwood <david.sherwood@arm.com>
31296 * tree-vectorizer.h (vec_lower_bound): New structure.
31297 (_loop_vec_info): Add check_nonzero and lower_bounds.
31298 (LOOP_VINFO_CHECK_NONZERO): New macro.
31299 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
31300 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
31301 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
31302 fields. Make seg_len the distance travelled, not including the
31304 (dr_direction_indicator): Declare.
31305 (dr_zero_step_indicator): Likewise.
31306 (dr_known_forward_stride_p): Likewise.
31307 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
31309 (runtime_alias_check_p): Allow runtime alias checks with
31311 (operator ==): Compare access_size and align.
31312 (prune_runtime_alias_test_list): Rework for new distinction between
31313 the access_size and seg_len.
31314 (create_intersect_range_checks_index): Likewise. Cope with polynomial
31316 (get_segment_min_max): New function.
31317 (create_intersect_range_checks): Use it.
31318 (dr_step_indicator): New function.
31319 (dr_direction_indicator): Likewise.
31320 (dr_zero_step_indicator): Likewise.
31321 (dr_known_forward_stride_p): Likewise.
31322 * tree-loop-distribution.c (data_ref_segment_size): Return
31323 DR_STEP * (niters - 1).
31324 (compute_alias_check_pairs): Update call to the dr_with_seg_len
31326 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
31327 (vect_preserves_scalar_order_p): New function, split out from...
31328 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
31329 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
31330 (vect_vfa_access_size): New function.
31331 (vect_vfa_align): Likewise.
31332 (vect_compile_time_alias): Take access_size_a and access_b arguments.
31333 (dump_lower_bound): New function.
31334 (vect_check_lower_bound): Likewise.
31335 (vect_small_gap_p): Likewise.
31336 (vectorizable_with_step_bound_p): Likewise.
31337 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
31338 depencies if the vectorization factor is 1. Convert the checks
31339 for nonzero steps into checks on the bounds of DR_STEP. Try using
31340 a bunds check for variable steps if the minimum required step is
31341 relatively small. Update calls to the dr_with_seg_len
31342 constructor and to vect_compile_time_alias.
31343 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
31345 (vect_loop_versioning): Call it.
31346 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
31348 (vect_estimate_min_profitable_iters): Account for any bounds checks.
31350 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31351 Alan Hayward <alan.hayward@arm.com>
31352 David Sherwood <david.sherwood@arm.com>
31354 * doc/sourcebuild.texi (vect_scatter_store): Document.
31355 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
31357 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
31359 * genopinit.c (main): Add supports_vec_scatter_store and
31360 supports_vec_scatter_store_cached to target_optabs.
31361 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
31362 IFN_MASK_SCATTER_STORE.
31363 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
31365 * internal-fn.h (internal_store_fn_p): Declare.
31366 (internal_fn_stored_value_index): Likewise.
31367 * internal-fn.c (scatter_store_direct): New macro.
31368 (expand_scatter_store_optab_fn): New function.
31369 (direct_scatter_store_optab_supported_p): New macro.
31370 (internal_store_fn_p): New function.
31371 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
31372 IFN_MASK_SCATTER_STORE.
31373 (internal_fn_mask_index): Likewise.
31374 (internal_fn_stored_value_index): New function.
31375 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
31376 for scatter stores.
31377 * optabs-query.h (supports_vec_scatter_store_p): Declare.
31378 * optabs-query.c (supports_vec_scatter_store_p): New function.
31379 * tree-vectorizer.h (vect_get_store_rhs): Declare.
31380 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
31381 true for scatter stores.
31382 (vect_gather_scatter_fn_p): Handle scatter stores too.
31383 (vect_check_gather_scatter): Consider using scatter stores if
31384 supports_vec_scatter_store_p.
31385 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
31386 scatter stores too.
31387 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
31388 internal_fn_stored_value_index.
31389 (check_load_store_masking): Handle scatter stores too.
31390 (vect_get_store_rhs): Make public.
31391 (vectorizable_call): Use internal_store_fn_p.
31392 (vectorizable_store): Handle scatter store internal functions.
31393 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
31394 when deciding whether the end of the group has been reached.
31395 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
31396 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
31397 (mask_scatter_store<mode>): New insns.
31399 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31400 Alan Hayward <alan.hayward@arm.com>
31401 David Sherwood <david.sherwood@arm.com>
31403 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
31404 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
31405 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
31407 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
31408 Use vect_truncate_gather_scatter_offset if we can't treat the
31409 operation as a normal gather load or scatter store.
31410 (get_group_load_store_type): Take the gather_scatter_info
31411 as argument. Try using a gather load or scatter store for
31412 single-element groups.
31413 (get_load_store_type): Update calls to get_group_load_store_type
31414 and vect_use_strided_gather_scatters_p.
31416 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31417 Alan Hayward <alan.hayward@arm.com>
31418 David Sherwood <david.sherwood@arm.com>
31420 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
31421 optional tree argument.
31422 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
31424 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
31425 but continue to use the current value as a fallback.
31426 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
31427 to compare the updates.
31428 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
31429 (get_load_store_type): Use it when handling a strided access.
31430 (vect_get_strided_load_store_ops): New function.
31431 (vect_get_data_ptr_increment): Likewise.
31432 (vectorizable_load): Handle strided gather loads. Always pass
31433 a step to vect_create_data_ref_ptr and bump_vector_ptr.
31435 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31436 Alan Hayward <alan.hayward@arm.com>
31437 David Sherwood <david.sherwood@arm.com>
31439 * doc/md.texi (gather_load@var{m}): Document.
31440 (mask_gather_load@var{m}): Likewise.
31441 * genopinit.c (main): Add supports_vec_gather_load and
31442 supports_vec_gather_load_cached to target_optabs.
31443 * optabs-tree.c (init_tree_optimization_optabs): Use
31444 ggc_cleared_alloc to allocate target_optabs.
31445 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
31446 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
31448 * internal-fn.h (internal_load_fn_p): Declare.
31449 (internal_gather_scatter_fn_p): Likewise.
31450 (internal_fn_mask_index): Likewise.
31451 (internal_gather_scatter_fn_supported_p): Likewise.
31452 * internal-fn.c (gather_load_direct): New macro.
31453 (expand_gather_load_optab_fn): New function.
31454 (direct_gather_load_optab_supported_p): New macro.
31455 (direct_internal_fn_optab): New function.
31456 (internal_load_fn_p): Likewise.
31457 (internal_gather_scatter_fn_p): Likewise.
31458 (internal_fn_mask_index): Likewise.
31459 (internal_gather_scatter_fn_supported_p): Likewise.
31460 * optabs-query.c (supports_at_least_one_mode_p): New function.
31461 (supports_vec_gather_load_p): Likewise.
31462 * optabs-query.h (supports_vec_gather_load_p): Declare.
31463 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
31464 and memory_type field.
31465 (NUM_PATTERNS): Bump to 15.
31466 * tree-vect-data-refs.c: Include internal-fn.h.
31467 (vect_gather_scatter_fn_p): New function.
31468 (vect_describe_gather_scatter_call): Likewise.
31469 (vect_check_gather_scatter): Try using internal functions for
31470 gather loads. Recognize existing calls to a gather load function.
31471 (vect_analyze_data_refs): Consider using gather loads if
31472 supports_vec_gather_load_p.
31473 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
31474 (vect_get_gather_scatter_offset_type): Likewise.
31475 (vect_convert_mask_for_vectype): Likewise.
31476 (vect_add_conversion_to_patterm): Likewise.
31477 (vect_try_gather_scatter_pattern): Likewise.
31478 (vect_recog_gather_scatter_pattern): New pattern recognizer.
31479 (vect_vect_recog_func_ptrs): Add it.
31480 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
31481 internal_fn_mask_index and internal_gather_scatter_fn_p.
31482 (check_load_store_masking): Take the gather_scatter_info as an
31483 argument and handle gather loads.
31484 (vect_get_gather_scatter_ops): New function.
31485 (vectorizable_call): Check internal_load_fn_p.
31486 (vectorizable_load): Likewise. Handle gather load internal
31488 (vectorizable_store): Update call to check_load_store_masking.
31489 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
31490 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
31491 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
31492 (aarch64_gather_scale_operand_d): New predicates.
31493 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
31494 (mask_gather_load<mode>): New insns.
31496 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31497 Alan Hayward <alan.hayward@arm.com>
31498 David Sherwood <david.sherwood@arm.com>
31500 * optabs.def (fold_left_plus_optab): New optab.
31501 * doc/md.texi (fold_left_plus_@var{m}): Document.
31502 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
31503 * internal-fn.c (fold_left_direct): Define.
31504 (expand_fold_left_optab_fn): Likewise.
31505 (direct_fold_left_optab_supported_p): Likewise.
31506 * fold-const-call.c (fold_const_fold_left): New function.
31507 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
31508 * tree-parloops.c (valid_reduction_p): New function.
31509 (gather_scalar_reductions): Use it.
31510 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
31511 (vect_finish_replace_stmt): Declare.
31512 * tree-vect-loop.c (fold_left_reduction_fn): New function.
31513 (needs_fold_left_reduction_p): New function, split out from...
31514 (vect_is_simple_reduction): ...here. Accept reductions that
31515 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
31516 (vect_force_simple_reduction): Also store the reduction type in
31517 the assignment's STMT_VINFO_REDUC_TYPE.
31518 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
31519 (merge_with_identity): New function.
31520 (vect_expand_fold_left): Likewise.
31521 (vectorize_fold_left_reduction): Likewise.
31522 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
31523 scalar phi in place for it. Check for target support and reject
31524 cases that would reassociate the operation. Defer the transform
31525 phase to vectorize_fold_left_reduction.
31526 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
31527 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
31528 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
31530 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31532 * tree-if-conv.c (predicate_mem_writes): Remove redundant
31533 call to ifc_temp_var.
31535 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31536 Alan Hayward <alan.hayward@arm.com>
31537 David Sherwood <david.sherwood@arm.com>
31539 * target.def (legitimize_address_displacement): Take the original
31540 offset as a poly_int.
31541 * targhooks.h (default_legitimize_address_displacement): Update
31543 * targhooks.c (default_legitimize_address_displacement): Likewise.
31544 * doc/tm.texi: Regenerate.
31545 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
31546 as an argument, moving assert of ad->disp == ad->disp_term to...
31547 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
31548 Try calling targetm.legitimize_address_displacement before expanding
31549 the address rather than afterwards, and adjust for the new interface.
31550 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
31551 Match the new hook interface. Handle SVE addresses.
31552 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
31553 new hook interface.
31555 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31557 * Makefile.in (OBJS): Add early-remat.o.
31558 * target.def (select_early_remat_modes): New hook.
31559 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
31560 * doc/tm.texi: Regenerate.
31561 * targhooks.h (default_select_early_remat_modes): Declare.
31562 * targhooks.c (default_select_early_remat_modes): New function.
31563 * timevar.def (TV_EARLY_REMAT): New timevar.
31564 * passes.def (pass_early_remat): New pass.
31565 * tree-pass.h (make_pass_early_remat): Declare.
31566 * early-remat.c: New file.
31567 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
31569 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
31571 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31572 Alan Hayward <alan.hayward@arm.com>
31573 David Sherwood <david.sherwood@arm.com>
31575 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
31576 vfm1 with a bound_epilog parameter.
31577 (vect_do_peeling): Update calls accordingly, and move the prologue
31578 call earlier in the function. Treat the base bound_epilog as 0 for
31579 fully-masked loops and retain vf - 1 for other loops. Add 1 to
31580 this base when peeling for gaps.
31581 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
31582 with fully-masked loops.
31583 (vect_estimate_min_profitable_iters): Handle the single peeled
31584 iteration in that case.
31586 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31587 Alan Hayward <alan.hayward@arm.com>
31588 David Sherwood <david.sherwood@arm.com>
31590 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
31591 single-element interleaving even if the size is not a power of 2.
31592 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
31593 accesses for single-element interleaving if the group size is
31596 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31597 Alan Hayward <alan.hayward@arm.com>
31598 David Sherwood <david.sherwood@arm.com>
31600 * doc/md.texi (fold_extract_last_@var{m}): Document.
31601 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
31602 * optabs.def (fold_extract_last_optab): New optab.
31603 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
31604 * internal-fn.c (fold_extract_direct): New macro.
31605 (expand_fold_extract_optab_fn): Likewise.
31606 (direct_fold_extract_optab_supported_p): Likewise.
31607 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
31608 * tree-vect-loop.c (vect_model_reduction_cost): Handle
31609 EXTRACT_LAST_REDUCTION.
31610 (get_initial_def_for_reduction): Do not create an initial vector
31611 for EXTRACT_LAST_REDUCTION reductions.
31612 (vectorizable_reduction): Leave the scalar phi in place for
31613 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
31614 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
31615 epilogue code for EXTRACT_LAST_REDUCTION and defer the
31616 transform phase to vectorizable_condition.
31617 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
31619 (vect_finish_stmt_generation): ...here.
31620 (vect_finish_replace_stmt): New function.
31621 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
31622 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
31624 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
31626 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31627 Alan Hayward <alan.hayward@arm.com>
31628 David Sherwood <david.sherwood@arm.com>
31630 * doc/md.texi (extract_last_@var{m}): Document.
31631 * optabs.def (extract_last_optab): New optab.
31632 * internal-fn.def (EXTRACT_LAST): New internal function.
31633 * internal-fn.c (cond_unary_direct): New macro.
31634 (expand_cond_unary_optab_fn): Likewise.
31635 (direct_cond_unary_optab_supported_p): Likewise.
31636 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
31637 loops using EXTRACT_LAST.
31638 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
31639 (extract_last_<mode>): ...this optab.
31640 (vec_extract<mode><Vel>): Update accordingly.
31642 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31643 Alan Hayward <alan.hayward@arm.com>
31644 David Sherwood <david.sherwood@arm.com>
31646 * target.def (empty_mask_is_expensive): New hook.
31647 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
31648 * doc/tm.texi: Regenerate.
31649 * targhooks.h (default_empty_mask_is_expensive): Declare.
31650 * targhooks.c (default_empty_mask_is_expensive): New function.
31651 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
31652 if the target says that empty masks are expensive.
31653 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
31655 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
31657 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31658 Alan Hayward <alan.hayward@arm.com>
31659 David Sherwood <david.sherwood@arm.com>
31661 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
31662 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
31663 (vect_use_loop_mask_for_alignment_p): New function.
31664 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
31665 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
31666 niters_skip argument. Make sure that the first niters_skip elements
31667 of the first iteration are inactive.
31668 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
31669 Update call to vect_set_loop_masks_directly.
31670 (get_misalign_in_elems): New function, split out from...
31671 (vect_gen_prolog_loop_niters): ...here.
31672 (vect_update_init_of_dr): Take a code argument that specifies whether
31673 the adjustment should be added or subtracted.
31674 (vect_update_init_of_drs): Likewise.
31675 (vect_prepare_for_masked_peels): New function.
31676 (vect_do_peeling): Skip prologue peeling if we're using a mask
31677 instead. Update call to vect_update_inits_of_drs.
31678 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
31680 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
31681 alignment. Do not include the number of peeled iterations in
31682 the minimum threshold in that case.
31683 (vectorizable_induction): Adjust the start value down by
31684 LOOP_VINFO_MASK_SKIP_NITERS iterations.
31685 (vect_transform_loop): Call vect_prepare_for_masked_peels.
31686 Take the number of skipped iterations into account when calculating
31688 * tree-vect-stmts.c (vect_gen_while_not): New function.
31690 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31691 Alan Hayward <alan.hayward@arm.com>
31692 David Sherwood <david.sherwood@arm.com>
31694 * doc/sourcebuild.texi (vect_fully_masked): Document.
31695 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
31696 default value to 0.
31697 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
31699 (vect_analyze_loop_2): ...here. Don't check the vectorization
31700 factor against the number of loop iterations if the loop is
31703 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31704 Alan Hayward <alan.hayward@arm.com>
31705 David Sherwood <david.sherwood@arm.com>
31707 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
31708 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
31709 (dump_groups): Update accordingly.
31710 (iv_use::mem_type): New member variable.
31711 (address_p): New function.
31712 (record_use): Add a mem_type argument and initialize the new
31714 (record_group_use): Add a mem_type argument. Use address_p.
31715 Remove obsolete null checks of base_object. Update call to record_use.
31716 (find_interesting_uses_op): Update call to record_group_use.
31717 (find_interesting_uses_cond): Likewise.
31718 (find_interesting_uses_address): Likewise.
31719 (get_mem_type_for_internal_fn): New function.
31720 (find_address_like_use): Likewise.
31721 (find_interesting_uses_stmt): Try find_address_like_use before
31722 calling find_interesting_uses_op.
31723 (addr_offset_valid_p): Use the iv mem_type field as the type
31724 of the addressed memory.
31725 (add_autoinc_candidates): Likewise.
31726 (get_address_cost): Likewise.
31727 (split_small_address_groups_p): Use address_p.
31728 (split_address_groups): Likewise.
31729 (add_iv_candidate_for_use): Likewise.
31730 (autoinc_possible_for_pair): Likewise.
31731 (rewrite_groups): Likewise.
31732 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
31733 (determine_group_iv_cost): Update after split of USE_ADDRESS.
31734 (get_alias_ptr_type_for_ptr_address): New function.
31735 (rewrite_use_address): Rewrite address uses in calls that were
31736 identified by find_address_like_use.
31738 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31739 Alan Hayward <alan.hayward@arm.com>
31740 David Sherwood <david.sherwood@arm.com>
31742 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
31744 * gimple-expr.h (is_gimple_addressable: Likewise.
31745 * gimple-expr.c (is_gimple_address): Likewise.
31746 * internal-fn.c (expand_call_mem_ref): New function.
31747 (expand_mask_load_optab_fn): Use it.
31748 (expand_mask_store_optab_fn): Likewise.
31750 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31751 Alan Hayward <alan.hayward@arm.com>
31752 David Sherwood <david.sherwood@arm.com>
31754 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
31755 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
31756 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
31757 (cond_umax@var{mode}): Document.
31758 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
31759 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
31760 (cond_umin_optab, cond_umax_optab): New optabs.
31761 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
31762 (COND_IOR, COND_XOR): New internal functions.
31763 * internal-fn.h (get_conditional_internal_fn): Declare.
31764 * internal-fn.c (cond_binary_direct): New macro.
31765 (expand_cond_binary_optab_fn): Likewise.
31766 (direct_cond_binary_optab_supported_p): Likewise.
31767 (get_conditional_internal_fn): New function.
31768 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
31769 Cope with reduction statements that are vectorized as calls rather
31771 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
31772 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
31773 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
31774 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
31775 (UNSPEC_COND_EOR): New unspecs.
31776 (optab): Add mappings for them.
31777 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
31778 (sve_int_op, sve_fp_op): New int attributes.
31780 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31781 Alan Hayward <alan.hayward@arm.com>
31782 David Sherwood <david.sherwood@arm.com>
31784 * optabs.def (while_ult_optab): New optab.
31785 * doc/md.texi (while_ult@var{m}@var{n}): Document.
31786 * internal-fn.def (WHILE_ULT): New internal function.
31787 * internal-fn.h (direct_internal_fn_supported_p): New override
31788 that takes two types as argument.
31789 * internal-fn.c (while_direct): New macro.
31790 (expand_while_optab_fn): New function.
31791 (convert_optab_supported_p): Likewise.
31792 (direct_while_optab_supported_p): New macro.
31793 * wide-int.h (wi::udiv_ceil): New function.
31794 * tree-vectorizer.h (rgroup_masks): New structure.
31795 (vec_loop_masks): New typedef.
31796 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
31797 and fully_masked_p.
31798 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
31799 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
31800 (vect_max_vf): New function.
31801 (slpeel_make_loop_iterate_ntimes): Delete.
31802 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
31803 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
31804 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
31805 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
31806 internal-fn.h, stor-layout.h and optabs-query.h.
31807 (vect_set_loop_mask): New function.
31808 (add_preheader_seq): Likewise.
31809 (add_header_seq): Likewise.
31810 (interleave_supported_p): Likewise.
31811 (vect_maybe_permute_loop_masks): Likewise.
31812 (vect_set_loop_masks_directly): Likewise.
31813 (vect_set_loop_condition_masked): Likewise.
31814 (vect_set_loop_condition_unmasked): New function, split out from
31815 slpeel_make_loop_iterate_ntimes.
31816 (slpeel_make_loop_iterate_ntimes): Rename to..
31817 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
31818 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
31819 (vect_do_peeling): Update call accordingly.
31820 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
31822 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
31823 mask_compare_type, can_fully_mask_p and fully_masked_p.
31824 (release_vec_loop_masks): New function.
31825 (_loop_vec_info): Use it to free the loop masks.
31826 (can_produce_all_loop_masks_p): New function.
31827 (vect_get_max_nscalars_per_iter): Likewise.
31828 (vect_verify_full_masking): Likewise.
31829 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
31830 retries, and free the mask rgroups before retrying. Check loop-wide
31831 reasons for disallowing fully-masked loops. Make the final decision
31832 about whether use a fully-masked loop or not.
31833 (vect_estimate_min_profitable_iters): Do not assume that peeling
31834 for the number of iterations will be needed for fully-masked loops.
31835 (vectorizable_reduction): Disable fully-masked loops.
31836 (vectorizable_live_operation): Likewise.
31837 (vect_halve_mask_nunits): New function.
31838 (vect_double_mask_nunits): Likewise.
31839 (vect_record_loop_mask): Likewise.
31840 (vect_get_loop_mask): Likewise.
31841 (vect_transform_loop): Handle the case in which the final loop
31842 iteration might handle a partial vector. Call vect_set_loop_condition
31843 instead of slpeel_make_loop_iterate_ntimes.
31844 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
31845 (check_load_store_masking): New function.
31846 (prepare_load_store_mask): Likewise.
31847 (vectorizable_store): Handle fully-masked loops.
31848 (vectorizable_load): Likewise.
31849 (supportable_widening_operation): Use vect_halve_mask_nunits for
31851 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
31852 (vect_gen_while): New function.
31853 * config/aarch64/aarch64.md (umax<mode>3): New expander.
31854 (aarch64_uqdec<mode>): New insn.
31856 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31857 Alan Hayward <alan.hayward@arm.com>
31858 David Sherwood <david.sherwood@arm.com>
31860 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
31861 (reduc_xor_scal_optab): New optabs.
31862 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
31863 (reduc_xor_scal_@var{m}): Document.
31864 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
31865 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
31866 internal functions.
31867 * fold-const-call.c (fold_const_call): Handle them.
31868 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
31869 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
31870 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
31871 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
31872 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
31873 (UNSPEC_XORV): New unspecs.
31874 (optab): Add entries for them.
31875 (BITWISEV): New int iterator.
31876 (bit_reduc_op): New int attributes.
31878 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31879 Alan Hayward <alan.hayward@arm.com>
31880 David Sherwood <david.sherwood@arm.com>
31882 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
31883 * internal-fn.def (VEC_SHL_INSERT): New internal function.
31884 * optabs.def (vec_shl_insert_optab): New optab.
31885 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
31886 (duplicate_and_interleave): Likewise.
31887 * tree-vect-loop.c: Include internal-fn.h.
31888 (neutral_op_for_slp_reduction): New function, split out from
31889 get_initial_defs_for_reduction.
31890 (get_initial_def_for_reduction): Handle option 2 for variable-length
31891 vectors by loading the neutral value into a vector and then shifting
31892 the initial value into element 0.
31893 (get_initial_defs_for_reduction): Replace the code argument with
31894 the neutral value calculated by neutral_op_for_slp_reduction.
31895 Use gimple_build_vector for constant-length vectors.
31896 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
31897 but the first group_size elements have a neutral value.
31898 Use duplicate_and_interleave otherwise.
31899 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
31900 Update call to get_initial_defs_for_reduction. Handle SLP
31901 reductions for variable-length vectors by creating one vector
31902 result for each scalar result, with the elements associated
31903 with other scalar results stubbed out with the neutral value.
31904 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
31905 Require IFN_VEC_SHL_INSERT for double reductions on
31906 variable-length vectors, or SLP reductions that have
31907 a neutral value. Require can_duplicate_and_interleave_p
31908 support for variable-length unchained SLP reductions if there
31909 is no neutral value, such as for MIN/MAX reductions. Also require
31910 the number of vector elements to be a multiple of the number of
31911 SLP statements when doing variable-length unchained SLP reductions.
31912 Update call to vect_create_epilog_for_reduction.
31913 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
31914 and remove initial values.
31915 (duplicate_and_interleave): Make public.
31916 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
31917 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
31919 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31920 Alan Hayward <alan.hayward@arm.com>
31921 David Sherwood <david.sherwood@arm.com>
31923 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
31924 (can_duplicate_and_interleave_p): New function.
31925 (vect_get_and_check_slp_defs): Take the vector of statements
31926 rather than just the current one. Remove excess parentheses.
31927 Restriction rejectinon of vect_constant_def and vect_external_def
31928 for variable-length vectors to boolean types, or types for which
31929 can_duplicate_and_interleave_p is false.
31930 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
31931 (duplicate_and_interleave): New function.
31932 (vect_get_constant_vectors): Use gimple_build_vector for
31933 constant-length vectors and suitable variable-length constant
31934 vectors. Use duplicate_and_interleave for other variable-length
31935 vectors. Don't defer the update when inserting new statements.
31937 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31938 Alan Hayward <alan.hayward@arm.com>
31939 David Sherwood <david.sherwood@arm.com>
31941 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
31942 min_profitable_iters doesn't go negative.
31944 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31945 Alan Hayward <alan.hayward@arm.com>
31946 David Sherwood <david.sherwood@arm.com>
31948 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
31949 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
31950 * optabs.def (vec_mask_load_lanes_optab): New optab.
31951 (vec_mask_store_lanes_optab): Likewise.
31952 * internal-fn.def (MASK_LOAD_LANES): New internal function.
31953 (MASK_STORE_LANES): Likewise.
31954 * internal-fn.c (mask_load_lanes_direct): New macro.
31955 (mask_store_lanes_direct): Likewise.
31956 (expand_mask_load_optab_fn): Handle masked operations.
31957 (expand_mask_load_lanes_optab_fn): New macro.
31958 (expand_mask_store_optab_fn): Handle masked operations.
31959 (expand_mask_store_lanes_optab_fn): New macro.
31960 (direct_mask_load_lanes_optab_supported_p): Likewise.
31961 (direct_mask_store_lanes_optab_supported_p): Likewise.
31962 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
31964 (vect_load_lanes_supported): Likewise.
31965 * tree-vect-data-refs.c (strip_conversion): New function.
31966 (can_group_stmts_p): Likewise.
31967 (vect_analyze_data_ref_accesses): Use it instead of checking
31968 for a pair of assignments.
31969 (vect_store_lanes_supported): Take a masked_p parameter.
31970 (vect_load_lanes_supported): Likewise.
31971 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
31972 vect_store_lanes_supported and vect_load_lanes_supported.
31973 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
31974 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
31975 parameter. Don't allow gaps for masked accesses.
31976 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
31977 and vect_load_lanes_supported.
31978 (get_load_store_type): Take a masked_p parameter and update
31979 call to get_group_load_store_type.
31980 (vectorizable_store): Update call to get_load_store_type.
31981 Handle IFN_MASK_STORE_LANES.
31982 (vectorizable_load): Update call to get_load_store_type.
31983 Handle IFN_MASK_LOAD_LANES.
31985 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31986 Alan Hayward <alan.hayward@arm.com>
31987 David Sherwood <david.sherwood@arm.com>
31989 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
31991 * config/aarch64/aarch64-protos.h
31992 (aarch64_sve_struct_memory_operand_p): Declare.
31993 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
31994 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
31995 (VPRED, vpred): Handle SVE structure modes.
31996 * config/aarch64/constraints.md (Utx): New constraint.
31997 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
31998 (aarch64_sve_struct_nonimmediate_operand): New predicates.
31999 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
32000 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
32001 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
32002 structure modes. Split into pieces after RA.
32003 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
32004 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
32006 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
32007 SVE structure modes.
32008 (aarch64_classify_address): Likewise.
32009 (sizetochar): Move earlier in file.
32010 (aarch64_print_operand): Handle SVE register lists.
32011 (aarch64_array_mode): New function.
32012 (aarch64_sve_struct_memory_operand_p): Likewise.
32013 (TARGET_ARRAY_MODE): Redefine.
32015 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32016 Alan Hayward <alan.hayward@arm.com>
32017 David Sherwood <david.sherwood@arm.com>
32019 * target.def (array_mode): New target hook.
32020 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
32021 * doc/tm.texi: Regenerate.
32022 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
32023 * hooks.c (hook_optmode_mode_uhwi_none): New function.
32024 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
32025 targetm.array_mode.
32026 * stor-layout.c (mode_for_array): Likewise. Support polynomial
32029 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32030 Alan Hayward <alan.hayward@arm.com>
32031 David Sherwood <david.sherwood@arm.com>
32033 * fold-const.c (fold_binary_loc): Check the argument types
32034 rather than the result type when testing for a vector operation.
32036 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32038 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
32039 * doc/tm.texi: Regenerate.
32041 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32042 Alan Hayward <alan.hayward@arm.com>
32043 David Sherwood <david.sherwood@arm.com>
32045 * doc/invoke.texi (-msve-vector-bits=): Document new option.
32046 (sve): Document new AArch64 extension.
32047 * doc/md.texi (w): Extend the description of the AArch64
32048 constraint to include SVE vectors.
32049 (Upl, Upa): Document new AArch64 predicate constraints.
32050 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
32052 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
32053 (msve-vector-bits=): New option.
32054 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
32055 SVE when these are disabled.
32056 (sve): New extension.
32057 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
32058 modes. Adjust their number of units based on aarch64_sve_vg.
32059 (MAX_BITSIZE_MODE_ANY_MODE): Define.
32060 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
32061 aarch64_addr_query_type.
32062 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
32063 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
32064 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
32065 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
32066 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
32067 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
32068 (aarch64_simd_imm_zero_p): Delete.
32069 (aarch64_check_zero_based_sve_index_immediate): Declare.
32070 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
32071 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
32072 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
32073 (aarch64_sve_float_mul_immediate_p): Likewise.
32074 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
32075 rather than an rtx.
32076 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
32077 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
32078 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
32079 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
32080 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
32081 (aarch64_regmode_natural_size): Likewise.
32082 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
32083 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
32085 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
32086 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
32087 for VG and the SVE predicate registers.
32088 (V_ALIASES): Add a "z"-prefixed alias.
32089 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
32090 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
32091 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
32092 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
32093 (REG_CLASS_NAMES): Add entries for them.
32094 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
32095 and the predicate registers.
32096 (aarch64_sve_vg): Declare.
32097 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
32098 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
32099 (REGMODE_NATURAL_SIZE): Define.
32100 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
32102 * config/aarch64/aarch64.c: Include cfgrtl.h.
32103 (simd_immediate_info): Add a constructor for series vectors,
32104 and an associated step field.
32105 (aarch64_sve_vg): New variable.
32106 (aarch64_dbx_register_number): Handle VG and the predicate registers.
32107 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
32108 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
32109 (VEC_ANY_DATA, VEC_STRUCT): New constants.
32110 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
32111 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
32112 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
32113 (aarch64_get_mask_mode): New functions.
32114 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
32115 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
32116 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
32117 predicate modes and predicate registers. Explicitly restrict
32118 GPRs to modes of 16 bytes or smaller. Only allow FP registers
32119 to store a vector mode if it is recognized by
32120 aarch64_classify_vector_mode.
32121 (aarch64_regmode_natural_size): New function.
32122 (aarch64_hard_regno_caller_save_mode): Return the original mode
32124 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
32125 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
32126 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
32127 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
32129 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
32130 does not overlap dest if the function is frame-related. Handle
32132 (aarch64_split_add_offset): New function.
32133 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
32134 them aarch64_add_offset.
32135 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
32136 and update call to aarch64_sub_sp.
32137 (aarch64_add_cfa_expression): New function.
32138 (aarch64_expand_prologue): Pass extra temporary registers to the
32139 functions above. Handle the case in which we need to emit new
32140 DW_CFA_expressions for registers that were originally saved
32141 relative to the stack pointer, but now have to be expressed
32142 relative to the frame pointer.
32143 (aarch64_output_mi_thunk): Pass extra temporary registers to the
32145 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
32146 IP0 and IP1 values for SVE frames.
32147 (aarch64_expand_vec_series): New function.
32148 (aarch64_expand_sve_widened_duplicate): Likewise.
32149 (aarch64_expand_sve_const_vector): Likewise.
32150 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
32151 Handle SVE constants. Use emit_move_insn to move a force_const_mem
32152 into the register, rather than emitting a SET directly.
32153 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
32154 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
32155 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
32156 (offset_9bit_signed_scaled_p): New functions.
32157 (aarch64_replicate_bitmask_imm): New function.
32158 (aarch64_bitmask_imm): Use it.
32159 (aarch64_cannot_force_const_mem): Reject expressions involving
32160 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
32161 (aarch64_classify_index): Handle SVE indices, by requiring
32162 a plain register index with a scale that matches the element size.
32163 (aarch64_classify_address): Handle SVE addresses. Assert that
32164 the mode of the address is VOIDmode or an integer mode.
32165 Update call to aarch64_classify_symbol.
32166 (aarch64_classify_symbolic_expression): Update call to
32167 aarch64_classify_symbol.
32168 (aarch64_const_vec_all_in_range_p): New function.
32169 (aarch64_print_vector_float_operand): Likewise.
32170 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
32171 "vN" for FP registers with SVE modes. Handle (const ...) vectors
32172 and the FP immediates 1.0 and 0.5.
32173 (aarch64_print_address_internal): Handle SVE addresses.
32174 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
32175 (aarch64_regno_regclass): Handle predicate registers.
32176 (aarch64_secondary_reload): Handle big-endian reloads of SVE
32178 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
32179 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
32180 (aarch64_convert_sve_vector_bits): New function.
32181 (aarch64_override_options): Use it to handle -msve-vector-bits=.
32182 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
32183 rather than an rtx.
32184 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
32185 Handle SVE vector and predicate modes. Accept VL-based constants
32186 that need only one temporary register, and VL offsets that require
32187 no temporary registers.
32188 (aarch64_conditional_register_usage): Mark the predicate registers
32189 as fixed if SVE isn't available.
32190 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
32191 Return true for SVE vector and predicate modes.
32192 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
32193 rather than an unsigned int. Handle SVE modes.
32194 (aarch64_preferred_simd_mode): Update call accordingly. Handle
32196 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
32198 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
32199 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
32200 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
32201 (aarch64_sve_float_mul_immediate_p): New functions.
32202 (aarch64_sve_valid_immediate): New function.
32203 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
32204 Explicitly reject structure modes. Check for INDEX constants.
32205 Handle PTRUE and PFALSE constants.
32206 (aarch64_check_zero_based_sve_index_immediate): New function.
32207 (aarch64_simd_imm_zero_p): Delete.
32208 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
32209 vector modes. Accept constants in the range of CNT[BHWD].
32210 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
32211 ask for an Advanced SIMD mode.
32212 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
32213 (aarch64_simd_vector_alignment): Handle SVE predicates.
32214 (aarch64_vectorize_preferred_vector_alignment): New function.
32215 (aarch64_simd_vector_alignment_reachable): Use it instead of
32217 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
32218 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
32220 (MAX_VECT_LEN): Delete.
32221 (expand_vec_perm_d): Add a vec_flags field.
32222 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
32223 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
32224 (aarch64_evpc_ext): Don't apply a big-endian lane correction
32226 (aarch64_evpc_rev): Rename to...
32227 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
32228 (aarch64_evpc_rev_global): New function.
32229 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
32230 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
32232 (aarch64_evpc_sve_tbl): New function.
32233 (aarch64_expand_vec_perm_const_1): Update after rename of
32234 aarch64_evpc_rev. Handle SVE permutes too, trying
32235 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
32236 than aarch64_evpc_tbl.
32237 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
32238 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
32239 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
32240 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
32241 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
32242 (aarch64_expand_sve_vcond): New functions.
32243 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
32244 of aarch64_vector_mode_p.
32245 (aarch64_dwarf_poly_indeterminate_value): New function.
32246 (aarch64_compute_pressure_classes): Likewise.
32247 (aarch64_can_change_mode_class): Likewise.
32248 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
32249 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
32250 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
32251 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
32252 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
32253 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
32254 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
32255 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
32257 (Dn, Dl, Dr): Accept const as well as const_vector.
32258 (Dz): Likewise. Compare against CONST0_RTX.
32259 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
32260 of "vector" where appropriate.
32261 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
32262 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
32263 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
32264 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
32265 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
32266 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
32267 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
32268 (v_int_equiv): Extend to SVE modes.
32269 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
32271 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
32272 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
32273 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
32274 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
32275 (SVE_COND_FP_CMP): New int iterators.
32276 (perm_hilo): Handle the new unpack unspecs.
32277 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
32279 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
32280 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
32281 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
32282 (aarch64_equality_operator, aarch64_constant_vector_operand)
32283 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
32284 (aarch64_sve_nonimmediate_operand): Likewise.
32285 (aarch64_sve_general_operand): Likewise.
32286 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
32287 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
32288 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
32289 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
32290 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
32291 (aarch64_sve_float_arith_immediate): Likewise.
32292 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
32293 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
32294 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
32295 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
32296 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
32297 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
32298 (aarch64_sve_float_arith_operand): Likewise.
32299 (aarch64_sve_float_arith_with_sub_operand): Likewise.
32300 (aarch64_sve_float_mul_operand): Likewise.
32301 (aarch64_sve_vec_perm_operand): Likewise.
32302 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
32303 (aarch64_mov_operand): Accept const_poly_int and const_vector.
32304 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
32305 as well as const_vector.
32306 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
32307 in file. Use CONST0_RTX and CONSTM1_RTX.
32308 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
32309 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
32310 Use aarch64_simd_imm_zero.
32311 * config/aarch64/aarch64-sve.md: New file.
32312 * config/aarch64/aarch64.md: Include it.
32313 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
32314 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
32315 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
32316 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
32317 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
32318 (sve): New attribute.
32319 (enabled): Disable instructions with the sve attribute unless
32321 (movqi, movhi): Pass CONST_POLY_INT operaneds through
32322 aarch64_expand_mov_immediate.
32323 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
32324 CNT[BHSD] immediates.
32325 (movti): Split CONST_POLY_INT moves into two halves.
32326 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
32327 Split additions that need a temporary here if the destination
32328 is the stack pointer.
32329 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
32330 (*add<mode>3_poly_1): New instruction.
32331 (set_clobber_cc): New expander.
32333 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32335 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
32336 parameter and use it instead of GET_MODE_SIZE (innermode). Use
32337 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
32338 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
32339 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
32340 Change innermode from fixed_mode_size to machine_mode.
32341 (simplify_subreg): Update call accordingly. Handle a constant-sized
32342 subreg of a variable-length CONST_VECTOR.
32344 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32345 Alan Hayward <alan.hayward@arm.com>
32346 David Sherwood <david.sherwood@arm.com>
32348 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
32349 (add_offset_to_base): New function, split out from...
32350 (create_mem_ref): ...here. When handling a scale other than 1,
32351 check first whether the address is valid without the offset.
32352 Add it into the base if so, leaving the index and scale as-is.
32354 2018-01-12 Jakub Jelinek <jakub@redhat.com>
32357 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
32358 fold_for_warn before checking if arg2 is INTEGER_CST.
32360 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
32362 * config/rs6000/predicates.md (load_multiple_operation): Delete.
32363 (store_multiple_operation): Delete.
32364 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
32365 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
32366 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
32367 guarded by TARGET_STRING.
32368 (rs6000_output_load_multiple): Delete.
32369 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
32370 OPTION_MASK_STRING / TARGET_STRING handling.
32371 (print_operand) <'N', 'O'>: Add comment that these are unused now.
32372 (const rs6000_opt_masks) <"string">: Change mask to 0.
32373 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
32374 (MASK_STRING): Delete.
32375 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
32377 (load_multiple): Delete.
32384 (store_multiple): Delete.
32391 (movmemsi_8reg): Delete.
32392 (corresponding unnamed define_insn): Delete.
32393 (movmemsi_6reg): Delete.
32394 (corresponding unnamed define_insn): Delete.
32395 (movmemsi_4reg): Delete.
32396 (corresponding unnamed define_insn): Delete.
32397 (movmemsi_2reg): Delete.
32398 (corresponding unnamed define_insn): Delete.
32399 (movmemsi_1reg): Delete.
32400 (corresponding unnamed define_insn): Delete.
32401 * config/rs6000/rs6000.opt (mno-string): New.
32402 (mstring): Replace by deprecation warning stub.
32403 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
32405 2018-01-12 Jakub Jelinek <jakub@redhat.com>
32407 * regrename.c (regrename_do_replace): If replacing the same
32408 reg multiple times, try to reuse last created gen_raw_REG.
32411 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
32412 main to workaround a bug in GDB.
32414 2018-01-12 Tom de Vries <tom@codesourcery.com>
32417 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
32419 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
32421 PR rtl-optimization/80481
32422 * ira-color.c (get_cap_member): New function.
32423 (allocnos_conflict_by_live_ranges_p): Use it.
32424 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
32425 (setup_slot_coalesced_allocno_live_ranges): Ditto.
32427 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
32430 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
32431 (*saddl_se_1): Ditto.
32432 (*ssubsi_1): Ditto.
32433 (*ssubl_se_1): Ditto.
32435 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
32437 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
32438 rather than wi::to_widest for DR_INITs.
32439 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
32440 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
32441 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
32443 (vect_analyze_group_access_1): Note that here.
32445 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
32447 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
32448 polynomial type sizes.
32450 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
32452 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
32453 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
32454 (gimple_add_tmp_var): Likewise.
32456 2018-01-12 Martin Liska <mliska@suse.cz>
32458 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
32459 (gimple_alloc_sizes): Likewise.
32460 (dump_gimple_statistics): Use PRIu64 in printf format.
32461 * gimple.h: Change uint64_t to int.
32463 2018-01-12 Martin Liska <mliska@suse.cz>
32465 * tree-core.h: Use uint64_t instead of int.
32466 * tree.c (tree_node_counts): Likewise.
32467 (tree_node_sizes): Likewise.
32468 (dump_tree_statistics): Use PRIu64 in printf format.
32470 2018-01-12 Martin Liska <mliska@suse.cz>
32472 * Makefile.in: As qsort_chk is implemented in vec.c, add
32473 vec.o to linkage of gencfn-macros.
32474 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
32475 passing the info to record_node_allocation_statistics.
32476 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
32478 * ggc-common.c (struct ggc_usage): Add operator== and use
32479 it in operator< and compare function.
32480 * mem-stats.h (struct mem_usage): Likewise.
32481 * vec.c (struct vec_usage): Remove operator< and compare
32482 function. Can be simply inherited.
32484 2018-01-12 Martin Jambor <mjambor@suse.cz>
32487 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
32488 * tree-ssa-math-opts.c: Include domwalk.h.
32489 (convert_mult_to_fma_1): New function.
32490 (fma_transformation_info): New type.
32491 (fma_deferring_state): Likewise.
32492 (cancel_fma_deferring): New function.
32493 (result_of_phi): Likewise.
32494 (last_fma_candidate_feeds_initial_phi): Likewise.
32495 (convert_mult_to_fma): Added deferring logic, split actual
32496 transformation to convert_mult_to_fma_1.
32497 (math_opts_dom_walker): New type.
32498 (math_opts_dom_walker::after_dom_children): New method, body moved
32499 here from pass_optimize_widening_mul::execute, added deferring logic
32501 (pass_optimize_widening_mul::execute): Moved most of code to
32502 math_opts_dom_walker::after_dom_children.
32503 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
32504 * config/i386/i386.c (ix86_option_override_internal): Added
32505 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
32507 2018-01-12 Richard Biener <rguenther@suse.de>
32510 * dwarf2out.c (gen_variable_die): Do not reset old_die for
32511 inline instance vars.
32513 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
32516 * config/rx/rx.c (rx_is_restricted_memory_address):
32517 Handle SUBREG case.
32519 2018-01-12 Richard Biener <rguenther@suse.de>
32521 PR tree-optimization/80846
32522 * target.def (split_reduction): New target hook.
32523 * targhooks.c (default_split_reduction): New function.
32524 * targhooks.h (default_split_reduction): Declare.
32525 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
32526 target requests first reduce vectors by combining low and high
32528 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
32529 (get_vectype_for_scalar_type_and_size): Export.
32530 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
32531 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
32532 * doc/tm.texi: Regenerate.
32533 * config/i386/i386.c (ix86_split_reduction): Implement
32534 TARGET_VECTORIZE_SPLIT_REDUCTION.
32536 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
32539 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
32540 in PIC mode except for TARGET_VXWORKS_RTP.
32541 * config/sparc/sparc.c: Include cfgrtl.h.
32542 (TARGET_INIT_PIC_REG): Define.
32543 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
32544 (sparc_pic_register_p): New predicate.
32545 (sparc_legitimate_address_p): Use it.
32546 (sparc_legitimize_pic_address): Likewise.
32547 (sparc_delegitimize_address): Likewise.
32548 (sparc_mode_dependent_address_p): Likewise.
32549 (gen_load_pcrel_sym): Remove 4th parameter.
32550 (load_got_register): Adjust call to above. Remove obsolete stuff.
32551 (sparc_expand_prologue): Do not call load_got_register here.
32552 (sparc_flat_expand_prologue): Likewise.
32553 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
32554 (sparc_use_pseudo_pic_reg): New function.
32555 (sparc_init_pic_reg): Likewise.
32556 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
32557 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
32559 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
32561 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
32562 Add item for branch_cost.
32564 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
32566 PR rtl-optimization/83565
32567 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
32568 not extend the result to a larger mode for rotate operations.
32569 (num_sign_bit_copies1): Likewise.
32571 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
32574 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
32576 Use values-Xc.o for -pedantic.
32577 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
32579 2018-01-12 Martin Liska <mliska@suse.cz>
32582 * ipa-devirt.c (final_warning_record::grow_type_warnings):
32584 (possible_polymorphic_call_targets): Use it.
32585 (ipa_devirt): Likewise.
32587 2018-01-12 Martin Liska <mliska@suse.cz>
32589 * profile-count.h (enum profile_quality): Use 0 as invalid
32590 enum value of profile_quality.
32592 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
32594 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
32595 -mext-string options.
32597 2018-01-12 Richard Biener <rguenther@suse.de>
32599 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
32600 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
32601 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
32603 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
32605 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
32607 * configure.ac (--with-long-double-format): Add support for the
32608 configuration option to change the default long double format on
32610 * config.gcc (powerpc*-linux*-*): Likewise.
32611 * configure: Regenerate.
32612 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
32613 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
32614 used without modification.
32616 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
32618 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
32619 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
32620 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
32621 MISC_BUILTIN_SPEC_BARRIER.
32622 (rs6000_init_builtins): Likewise.
32623 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
32625 (speculation_barrier): New define_insn.
32626 * doc/extend.texi: Document __builtin_speculation_barrier.
32628 2018-01-11 Jakub Jelinek <jakub@redhat.com>
32631 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
32632 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
32633 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
32635 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
32636 integral modes instead of "ss" and "sd".
32637 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
32638 vectors with 32-bit and 64-bit elements.
32639 (vecdupssescalarmodesuffix): New mode attribute.
32640 (vec_dup<mode>): Use it.
32642 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
32645 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
32646 frame if argument is passed on stack.
32648 2018-01-11 Jakub Jelinek <jakub@redhat.com>
32651 * ree.c (combine_reaching_defs): Optimize also
32652 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
32653 reg2=any_extend(exp); reg1=reg2;, formatting fix.
32655 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
32657 PR middle-end/83189
32658 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
32660 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
32662 PR middle-end/83718
32663 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
32664 after they are computed.
32666 2018-01-11 Bin Cheng <bin.cheng@arm.com>
32668 PR tree-optimization/83695
32669 * gimple-loop-linterchange.cc
32670 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
32671 reset cached scev information after interchange.
32672 (pass_linterchange::execute): Remove call to scev_reset_htab.
32674 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
32676 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
32677 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
32678 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
32679 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
32680 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
32681 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
32682 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
32683 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
32684 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
32685 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
32686 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
32687 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
32688 (V_lane_reg): Likewise.
32689 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
32691 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
32692 (vfmal_lane_low<mode>_intrinsic,
32693 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
32694 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
32695 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
32696 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
32697 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
32698 vfmsl_lane_high<mode>_intrinsic): New define_insns.
32700 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
32702 * config/arm/arm-cpus.in (fp16fml): New feature.
32703 (ALL_SIMD): Add fp16fml.
32704 (armv8.2-a): Add fp16fml as an option.
32705 (armv8.3-a): Likewise.
32706 (armv8.4-a): Add fp16fml as part of fp16.
32707 * config/arm/arm.h (TARGET_FP16FML): Define.
32708 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
32710 * config/arm/arm-modes.def (V2HF): Define.
32711 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
32712 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
32713 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
32714 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
32715 vfmsl_low, vfmsl_high): New set of builtins.
32716 * config/arm/iterators.md (PLUSMINUS): New code iterator.
32717 (vfml_op): New code attribute.
32718 (VFMLHALVES): New int iterator.
32719 (VFML, VFMLSEL): New mode attributes.
32720 (V_reg): Define mapping for V2HF.
32721 (V_hi, V_lo): New mode attributes.
32722 (VF_constraint): Likewise.
32723 (vfml_half, vfml_half_selector): New int attributes.
32724 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
32726 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
32727 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
32729 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
32730 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
32731 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
32732 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
32734 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
32735 Document new effective target and option set.
32737 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
32739 * config/arm/arm-cpus.in (armv8_4): New feature.
32740 (ARMv8_4a): New fgroup.
32741 (armv8.4-a): New arch.
32742 * config/arm/arm-tables.opt: Regenerate.
32743 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
32744 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
32745 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
32746 Add matching rules for -march=armv8.4-a and extensions.
32747 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
32749 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
32752 * config/rx/rx.md (BW): New mode attribute.
32753 (sync_lock_test_and_setsi): Add mode suffix to insn output.
32755 2018-01-11 Richard Biener <rguenther@suse.de>
32757 PR tree-optimization/83435
32758 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
32759 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
32760 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
32762 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
32763 Alan Hayward <alan.hayward@arm.com>
32764 David Sherwood <david.sherwood@arm.com>
32766 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
32768 (aarch64_classify_address): Initialize it. Track polynomial offsets.
32769 (aarch64_print_address_internal): Use it to check for a zero offset.
32771 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
32772 Alan Hayward <alan.hayward@arm.com>
32773 David Sherwood <david.sherwood@arm.com>
32775 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
32776 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
32777 Return a poly_int64 rather than a HOST_WIDE_INT.
32778 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
32779 rather than a HOST_WIDE_INT.
32780 * config/aarch64/aarch64.h (aarch64_frame): Protect with
32781 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
32782 hard_fp_offset, frame_size, initial_adjust, callee_offset and
32783 final_offset from HOST_WIDE_INT to poly_int64.
32784 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
32785 to_constant when getting the number of units in an Advanced SIMD
32787 (aarch64_builtin_vectorized_function): Check for a constant number
32789 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
32791 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
32792 attribute instead of GET_MODE_NUNITS.
32793 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
32794 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
32795 GET_MODE_SIZE for fixed-size registers.
32796 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
32797 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
32798 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
32799 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
32800 (aarch64_print_operand, aarch64_print_address_internal)
32801 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
32802 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
32803 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
32804 Handle polynomial GET_MODE_SIZE.
32805 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
32806 wider than SImode without modification.
32807 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
32808 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
32809 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
32810 passing and returning SVE modes.
32811 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
32812 rather than GEN_INT.
32813 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
32814 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
32815 (aarch64_allocate_and_probe_stack_space): Likewise.
32816 (aarch64_layout_frame): Cope with polynomial offsets.
32817 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
32818 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
32819 polynomial offsets.
32820 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
32821 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
32822 poly_int64 rather than a HOST_WIDE_INT.
32823 (aarch64_get_separate_components, aarch64_process_components)
32824 (aarch64_expand_prologue, aarch64_expand_epilogue)
32825 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
32826 (aarch64_anchor_offset): New function, split out from...
32827 (aarch64_legitimize_address): ...here.
32828 (aarch64_builtin_vectorization_cost): Handle polynomial
32829 TYPE_VECTOR_SUBPARTS.
32830 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
32832 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
32833 number of elements from the PARALLEL rather than the mode.
32834 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
32835 rather than GET_MODE_BITSIZE.
32836 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
32837 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
32838 (aarch64_expand_vec_perm_const_1): Handle polynomial
32839 d->perm.length () and d->perm elements.
32840 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
32841 Apply to_constant to d->perm elements.
32842 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
32843 polynomial CONST_VECTOR_NUNITS.
32844 (aarch64_move_pointer): Take amount as a poly_int64 rather
32846 (aarch64_progress_pointer): Avoid temporary variable.
32847 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
32848 the mode attribute instead of GET_MODE.
32850 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
32851 Alan Hayward <alan.hayward@arm.com>
32852 David Sherwood <david.sherwood@arm.com>
32854 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
32855 x exists before using it.
32856 (aarch64_add_constant_internal): Rename to...
32857 (aarch64_add_offset_1): ...this. Replace regnum with separate
32858 src and dest rtxes. Handle the case in which they're different,
32859 including when the offset is zero. Replace scratchreg with an rtx.
32860 Use 2 additions if there is no spare register into which we can
32861 move a 16-bit constant.
32862 (aarch64_add_constant): Delete.
32863 (aarch64_add_offset): Replace reg with separate src and dest
32864 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
32865 Use aarch64_add_offset_1.
32866 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
32867 an rtx rather than an int. Take the delta as a poly_int64
32868 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
32869 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
32870 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
32871 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
32872 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
32873 and aarch64_add_sp.
32874 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
32875 aarch64_add_constant.
32877 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
32879 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
32880 Use scalar_float_mode.
32882 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
32884 * config/aarch64/aarch64-simd.md
32885 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
32886 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
32887 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
32888 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
32889 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
32890 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
32891 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
32892 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
32893 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
32894 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
32896 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
32899 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
32900 targ_options->x_arm_arch_string is non NULL.
32902 2018-01-11 Tamar Christina <tamar.christina@arm.com>
32904 * config/aarch64/aarch64.h
32905 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
32907 2018-01-11 Sudakshina Das <sudi.das@arm.com>
32910 * expmed.c (emit_store_flag_force): Swap if const op0
32911 and change VOIDmode to mode of op0.
32913 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
32915 PR rtl-optimization/83761
32916 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
32917 than bytes to mode_for_size.
32919 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
32921 PR middle-end/83189
32922 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
32923 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
32926 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
32928 PR middle-end/83575
32929 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
32930 when in layout mode.
32931 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
32932 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
32935 2018-01-10 Michael Collison <michael.collison@arm.com>
32937 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
32938 * config/aarch64/aarch64-option-extension.def: Add
32939 AARCH64_OPT_EXTENSION of 'fp16fml'.
32940 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
32941 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
32942 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
32943 * config/aarch64/constraints.md (Ui7): New constraint.
32944 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
32945 (VFMLA_SEL_W): Ditto.
32948 (VFMLA16_LOW): New int iterator.
32949 (VFMLA16_HIGH): Ditto.
32950 (UNSPEC_FMLAL): New unspec.
32951 (UNSPEC_FMLSL): Ditto.
32952 (UNSPEC_FMLAL2): Ditto.
32953 (UNSPEC_FMLSL2): Ditto.
32954 (f16mac): New code attribute.
32955 * config/aarch64/aarch64-simd-builtins.def
32956 (aarch64_fmlal_lowv2sf): Ditto.
32957 (aarch64_fmlsl_lowv2sf): Ditto.
32958 (aarch64_fmlalq_lowv4sf): Ditto.
32959 (aarch64_fmlslq_lowv4sf): Ditto.
32960 (aarch64_fmlal_highv2sf): Ditto.
32961 (aarch64_fmlsl_highv2sf): Ditto.
32962 (aarch64_fmlalq_highv4sf): Ditto.
32963 (aarch64_fmlslq_highv4sf): Ditto.
32964 (aarch64_fmlal_lane_lowv2sf): Ditto.
32965 (aarch64_fmlsl_lane_lowv2sf): Ditto.
32966 (aarch64_fmlal_laneq_lowv2sf): Ditto.
32967 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
32968 (aarch64_fmlalq_lane_lowv4sf): Ditto.
32969 (aarch64_fmlsl_lane_lowv4sf): Ditto.
32970 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
32971 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
32972 (aarch64_fmlal_lane_highv2sf): Ditto.
32973 (aarch64_fmlsl_lane_highv2sf): Ditto.
32974 (aarch64_fmlal_laneq_highv2sf): Ditto.
32975 (aarch64_fmlsl_laneq_highv2sf): Ditto.
32976 (aarch64_fmlalq_lane_highv4sf): Ditto.
32977 (aarch64_fmlsl_lane_highv4sf): Ditto.
32978 (aarch64_fmlalq_laneq_highv4sf): Ditto.
32979 (aarch64_fmlsl_laneq_highv4sf): Ditto.
32980 * config/aarch64/aarch64-simd.md:
32981 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
32982 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
32983 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
32984 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
32985 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
32986 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
32987 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
32988 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
32989 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
32990 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
32991 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
32992 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
32993 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
32994 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
32995 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
32996 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
32997 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
32998 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
32999 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
33000 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
33001 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
33002 (vfmlsl_low_u32): Ditto.
33003 (vfmlalq_low_u32): Ditto.
33004 (vfmlslq_low_u32): Ditto.
33005 (vfmlal_high_u32): Ditto.
33006 (vfmlsl_high_u32): Ditto.
33007 (vfmlalq_high_u32): Ditto.
33008 (vfmlslq_high_u32): Ditto.
33009 (vfmlal_lane_low_u32): Ditto.
33010 (vfmlsl_lane_low_u32): Ditto.
33011 (vfmlal_laneq_low_u32): Ditto.
33012 (vfmlsl_laneq_low_u32): Ditto.
33013 (vfmlalq_lane_low_u32): Ditto.
33014 (vfmlslq_lane_low_u32): Ditto.
33015 (vfmlalq_laneq_low_u32): Ditto.
33016 (vfmlslq_laneq_low_u32): Ditto.
33017 (vfmlal_lane_high_u32): Ditto.
33018 (vfmlsl_lane_high_u32): Ditto.
33019 (vfmlal_laneq_high_u32): Ditto.
33020 (vfmlsl_laneq_high_u32): Ditto.
33021 (vfmlalq_lane_high_u32): Ditto.
33022 (vfmlslq_lane_high_u32): Ditto.
33023 (vfmlalq_laneq_high_u32): Ditto.
33024 (vfmlslq_laneq_high_u32): Ditto.
33025 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
33026 (AARCH64_FL_FOR_ARCH8_4): New.
33027 (AARCH64_ISA_F16FML): New ISA flag.
33028 (TARGET_F16FML): New feature flag for fp16fml.
33029 (doc/invoke.texi): Document new fp16fml option.
33031 2018-01-10 Michael Collison <michael.collison@arm.com>
33033 * config/aarch64/aarch64-builtins.c:
33034 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
33035 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33036 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
33037 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
33038 (AARCH64_ISA_SHA3): New ISA flag.
33039 (TARGET_SHA3): New feature flag for sha3.
33040 * config/aarch64/iterators.md (sha512_op): New int attribute.
33041 (CRYPTO_SHA512): New int iterator.
33042 (UNSPEC_SHA512H): New unspec.
33043 (UNSPEC_SHA512H2): Ditto.
33044 (UNSPEC_SHA512SU0): Ditto.
33045 (UNSPEC_SHA512SU1): Ditto.
33046 * config/aarch64/aarch64-simd-builtins.def
33047 (aarch64_crypto_sha512hqv2di): New builtin.
33048 (aarch64_crypto_sha512h2qv2di): Ditto.
33049 (aarch64_crypto_sha512su0qv2di): Ditto.
33050 (aarch64_crypto_sha512su1qv2di): Ditto.
33051 (aarch64_eor3qv8hi): Ditto.
33052 (aarch64_rax1qv2di): Ditto.
33053 (aarch64_xarqv2di): Ditto.
33054 (aarch64_bcaxqv8hi): Ditto.
33055 * config/aarch64/aarch64-simd.md:
33056 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
33057 (aarch64_crypto_sha512su0qv2di): Ditto.
33058 (aarch64_crypto_sha512su1qv2di): Ditto.
33059 (aarch64_eor3qv8hi): Ditto.
33060 (aarch64_rax1qv2di): Ditto.
33061 (aarch64_xarqv2di): Ditto.
33062 (aarch64_bcaxqv8hi): Ditto.
33063 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
33064 (vsha512h2q_u64): Ditto.
33065 (vsha512su0q_u64): Ditto.
33066 (vsha512su1q_u64): Ditto.
33067 (veor3q_u16): Ditto.
33068 (vrax1q_u64): Ditto.
33069 (vxarq_u64): Ditto.
33070 (vbcaxq_u16): Ditto.
33071 * config/arm/types.md (crypto_sha512): New type attribute.
33072 (crypto_sha3): Ditto.
33073 (doc/invoke.texi): Document new sha3 option.
33075 2018-01-10 Michael Collison <michael.collison@arm.com>
33077 * config/aarch64/aarch64-builtins.c:
33078 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
33079 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33080 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
33081 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
33082 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
33083 (AARCH64_ISA_SM4): New ISA flag.
33084 (TARGET_SM4): New feature flag for sm4.
33085 * config/aarch64/aarch64-simd-builtins.def
33086 (aarch64_sm3ss1qv4si): Ditto.
33087 (aarch64_sm3tt1aq4si): Ditto.
33088 (aarch64_sm3tt1bq4si): Ditto.
33089 (aarch64_sm3tt2aq4si): Ditto.
33090 (aarch64_sm3tt2bq4si): Ditto.
33091 (aarch64_sm3partw1qv4si): Ditto.
33092 (aarch64_sm3partw2qv4si): Ditto.
33093 (aarch64_sm4eqv4si): Ditto.
33094 (aarch64_sm4ekeyqv4si): Ditto.
33095 * config/aarch64/aarch64-simd.md:
33096 (aarch64_sm3ss1qv4si): Ditto.
33097 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
33098 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
33099 (aarch64_sm4eqv4si): Ditto.
33100 (aarch64_sm4ekeyqv4si): Ditto.
33101 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
33102 (sm3part_op): Ditto.
33103 (CRYPTO_SM3TT): Ditto.
33104 (CRYPTO_SM3PART): Ditto.
33105 (UNSPEC_SM3SS1): New unspec.
33106 (UNSPEC_SM3TT1A): Ditto.
33107 (UNSPEC_SM3TT1B): Ditto.
33108 (UNSPEC_SM3TT2A): Ditto.
33109 (UNSPEC_SM3TT2B): Ditto.
33110 (UNSPEC_SM3PARTW1): Ditto.
33111 (UNSPEC_SM3PARTW2): Ditto.
33112 (UNSPEC_SM4E): Ditto.
33113 (UNSPEC_SM4EKEY): Ditto.
33114 * config/aarch64/constraints.md (Ui2): New constraint.
33115 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
33116 * config/arm/types.md (crypto_sm3): New type attribute.
33117 (crypto_sm4): Ditto.
33118 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
33119 (vsm3tt1aq_u32): Ditto.
33120 (vsm3tt1bq_u32): Ditto.
33121 (vsm3tt2aq_u32): Ditto.
33122 (vsm3tt2bq_u32): Ditto.
33123 (vsm3partw1q_u32): Ditto.
33124 (vsm3partw2q_u32): Ditto.
33125 (vsm4eq_u32): Ditto.
33126 (vsm4ekeyq_u32): Ditto.
33127 (doc/invoke.texi): Document new sm4 option.
33129 2018-01-10 Michael Collison <michael.collison@arm.com>
33131 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
33132 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
33133 (AARCH64_FL_FOR_ARCH8_4): New.
33134 (AARCH64_FL_V8_4): New flag.
33135 (doc/invoke.texi): Document new armv8.4-a option.
33137 2018-01-10 Michael Collison <michael.collison@arm.com>
33139 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33140 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
33141 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
33142 * config/aarch64/aarch64-option-extension.def: Add
33143 AARCH64_OPT_EXTENSION of 'sha2'.
33144 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
33145 (crypto): Disable sha2 and aes if crypto disabled.
33146 (crypto): Enable aes and sha2 if enabled.
33147 (simd): Disable sha2 and aes if simd disabled.
33148 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
33150 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
33151 (TARGET_SHA2): New feature flag for sha2.
33152 (TARGET_AES): New feature flag for aes.
33153 * config/aarch64/aarch64-simd.md:
33154 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
33155 conditional on TARGET_AES.
33156 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
33157 (aarch64_crypto_sha1hsi): Make pattern conditional
33159 (aarch64_crypto_sha1hv4si): Ditto.
33160 (aarch64_be_crypto_sha1hv4si): Ditto.
33161 (aarch64_crypto_sha1su1v4si): Ditto.
33162 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
33163 (aarch64_crypto_sha1su0v4si): Ditto.
33164 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
33165 (aarch64_crypto_sha256su0v4si): Ditto.
33166 (aarch64_crypto_sha256su1v4si): Ditto.
33167 (doc/invoke.texi): Document new aes and sha2 options.
33169 2018-01-10 Martin Sebor <msebor@redhat.com>
33171 PR tree-optimization/83781
33172 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
33175 2018-01-11 Martin Sebor <msebor@gmail.com>
33176 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
33178 PR tree-optimization/83501
33179 PR tree-optimization/81703
33181 * tree-ssa-strlen.c (get_string_cst): Rename...
33182 (get_string_len): ...to this. Handle global constants.
33183 (handle_char_store): Adjust.
33185 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
33186 Jim Wilson <jimw@sifive.com>
33188 * config/riscv/riscv-protos.h (riscv_output_return): New.
33189 * config/riscv/riscv.c (struct machine_function): New naked_p field.
33190 (riscv_attribute_table, riscv_output_return),
33191 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
33192 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
33193 (riscv_compute_frame_info): Only compute frame->mask if not a naked
33195 (riscv_expand_prologue): Add early return for naked function.
33196 (riscv_expand_epilogue): Likewise.
33197 (riscv_function_ok_for_sibcall): Return false for naked function.
33198 (riscv_set_current_function): New.
33199 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
33200 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
33201 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
33202 * doc/extend.texi (RISC-V Function Attributes): New.
33204 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
33206 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
33207 check for 128-bit long double before checking TCmode.
33208 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
33209 128-bit long doubles before checking TFmode or TCmode.
33210 (FLOAT128_IBM_P): Likewise.
33212 2018-01-10 Martin Sebor <msebor@redhat.com>
33214 PR tree-optimization/83671
33215 * builtins.c (c_strlen): Unconditionally return zero for the empty
33217 Use -Warray-bounds for warnings.
33218 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
33219 for non-constant array indices with COMPONENT_REF, arrays of
33220 arrays, and pointers to arrays.
33221 (gimple_fold_builtin_strlen): Determine and set length range for
33222 non-constant character arrays.
33224 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
33226 PR middle-end/81897
33227 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
33230 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
33232 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
33234 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
33237 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
33238 VECTOR_MEM_ALTIVEC_OR_VSX_P.
33239 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
33240 indexed_or_indirect_operand predicate.
33241 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
33242 (*vsx_le_perm_load_v8hi): Likewise.
33243 (*vsx_le_perm_load_v16qi): Likewise.
33244 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
33245 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
33246 (*vsx_le_perm_store_v8hi): Likewise.
33247 (*vsx_le_perm_store_v16qi): Likewise.
33248 (eight unnamed splitters): Likewise.
33250 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
33252 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
33253 * config/rs6000/emmintrin.h: Likewise.
33254 * config/rs6000/mmintrin.h: Likewise.
33255 * config/rs6000/xmmintrin.h: Likewise.
33257 2018-01-10 David Malcolm <dmalcolm@redhat.com>
33260 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
33262 * tree.c (tree_nop_conversion): Return true for location wrapper
33264 (maybe_wrap_with_location): New function.
33265 (selftest::check_strip_nops): New function.
33266 (selftest::test_location_wrappers): New function.
33267 (selftest::tree_c_tests): Call it.
33268 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
33269 (maybe_wrap_with_location): New decl.
33270 (EXPR_LOCATION_WRAPPER_P): New macro.
33271 (location_wrapper_p): New inline function.
33272 (tree_strip_any_location_wrapper): New inline function.
33274 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
33277 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
33278 stack_realign_offset for the largest alignment of stack slot
33280 (ix86_find_max_used_stack_alignment): New function.
33281 (ix86_finalize_stack_frame_flags): Use it. Set
33282 max_used_stack_alignment if we don't realign stack.
33283 * config/i386/i386.h (machine_function): Add
33284 max_used_stack_alignment.
33286 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
33288 * config/arm/arm.opt (-mbranch-cost): New option.
33289 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
33292 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
33295 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
33296 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
33298 2018-01-10 Richard Biener <rguenther@suse.de>
33301 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
33302 early out so it also covers the case where we have a non-NULL
33305 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
33307 PR tree-optimization/83753
33308 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
33309 for non-strided grouped accesses if the number of elements is 1.
33311 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
33314 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
33315 * i386.h (TARGET_USE_GATHER): Define.
33316 * x86-tune.def (X86_TUNE_USE_GATHER): New.
33318 2018-01-10 Martin Liska <mliska@suse.cz>
33321 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
33322 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
33324 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
33325 CLEANUP_NO_PARTITIONING is not set.
33327 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
33329 * doc/rtl.texi: Remove documentation of (const ...) wrappers
33330 for vectors, as a partial revert of r254296.
33331 * rtl.h (const_vec_p): Delete.
33332 (const_vec_duplicate_p): Don't test for vector CONSTs.
33333 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
33334 * expmed.c (make_tree): Likewise.
33337 * common.md (E, F): Use CONSTANT_P instead of checking for
33339 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
33340 checking for CONST_VECTOR.
33342 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
33344 PR middle-end/83575
33345 * predict.c (force_edge_cold): Handle in more sane way edges
33346 with no prediction.
33348 2018-01-09 Carl Love <cel@us.ibm.com>
33350 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
33352 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
33353 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
33354 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
33355 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
33356 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
33357 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
33358 * config/rs6000/rs6000-protos.h: Add extern defition for
33359 rs6000_generate_float2_double_code.
33360 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
33362 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
33363 (float2_v2df): Add define_expand.
33365 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
33368 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
33369 op_mode in the force_to_mode call.
33371 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
33373 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
33374 instead of checking each element individually.
33375 (aarch64_evpc_uzp): Likewise.
33376 (aarch64_evpc_zip): Likewise.
33377 (aarch64_evpc_ext): Likewise.
33378 (aarch64_evpc_rev): Likewise.
33379 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
33380 instead of checking each element individually. Return true without
33382 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
33383 whether all selected elements come from the same input, instead of
33384 checking each element individually. Remove calls to gen_rtx_REG,
33385 start_sequence and end_sequence and instead assert that no rtl is
33388 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
33390 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
33391 order of HIGH and CONST checks.
33393 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
33395 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
33396 if the destination isn't an SSA_NAME.
33398 2018-01-09 Richard Biener <rguenther@suse.de>
33400 PR tree-optimization/83668
33401 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
33403 (canonicalize_loop_form): ... here, renamed from ...
33404 (canonicalize_loop_closed_ssa_form): ... this and amended to
33405 swap successor edges for loop exit blocks to make us use
33406 the RPO order we need for initial schedule generation.
33408 2018-01-09 Joseph Myers <joseph@codesourcery.com>
33410 PR tree-optimization/64811
33411 * match.pd: When optimizing comparisons with Inf, avoid
33412 introducing or losing exceptions from comparisons with NaN.
33414 2018-01-09 Martin Liska <mliska@suse.cz>
33417 * asan.c (shadow_mem_size): Add gcc_assert.
33419 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
33421 Don't save registers in main().
33424 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
33425 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
33426 * config/avr/avr.c (avr_set_current_function): Don't error if
33427 naked, OS_task or OS_main are specified at the same time.
33428 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
33430 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
33432 * common/config/avr/avr-common.c (avr_option_optimization_table):
33433 Switch on -mmain-is-OS_task for optimizing compilations.
33435 2018-01-09 Richard Biener <rguenther@suse.de>
33437 PR tree-optimization/83572
33438 * graphite.c: Include cfganal.h.
33439 (graphite_transform_loops): Connect infinite loops to exit
33440 and remove fake edges at the end.
33442 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
33444 * ipa-inline.c (edge_badness): Revert accidental checkin.
33446 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
33449 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
33450 symbols; not inline clones.
33452 2018-01-09 Jakub Jelinek <jakub@redhat.com>
33455 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
33456 hard registers. Formatting fixes.
33458 PR preprocessor/83722
33459 * gcc.c (try_generate_repro): Pass
33460 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
33461 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
33464 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
33465 Kito Cheng <kito.cheng@gmail.com>
33467 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
33468 (riscv_leaf_function_p): Delete.
33469 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
33471 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
33473 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
33475 (do_ifelse): New function.
33476 (do_isel): New function.
33477 (do_sub3): New function.
33478 (do_add3): New function.
33479 (do_load_mask_compare): New function.
33480 (do_overlap_load_compare): New function.
33481 (expand_compare_loop): New function.
33482 (expand_block_compare): Call expand_compare_loop() when appropriate.
33483 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
33484 option description.
33485 (-mblock-compare-inline-loop-limit): New option.
33487 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
33490 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
33491 Reverse order of second and third operands in first alternative.
33492 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
33493 of first and second elements in UNSPEC_VPERMR vector.
33494 (altivec_expand_vec_perm_le): Likewise.
33496 2018-01-08 Jeff Law <law@redhat.com>
33498 PR rtl-optimizatin/81308
33499 * tree-switch-conversion.c (cfg_altered): New file scoped static.
33500 (process_switch): If group_case_labels makes a change, then set
33502 (pass_convert_switch::execute): If a switch is converted, then
33503 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
33505 PR rtl-optimization/81308
33506 * recog.c (split_all_insns): Conditionally cleanup the CFG after
33509 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
33511 PR target/83663 - Revert r255946
33512 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
33513 generation for cases where splatting a value is not useful.
33514 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
33515 across a vec_duplicate and a paradoxical subreg forming a vector
33516 mode to a vec_concat.
33518 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
33520 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
33521 -march=armv8.3-a variants.
33522 * config/arm/t-multilib: Likewise.
33523 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
33525 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
33527 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
33529 (cceq_ior_compare_complement): Give it a name so I can use it, and
33530 change boolean_or_operator predicate to boolean_operator so it can
33531 be used to generate a crand.
33532 (eqne): New code iterator.
33533 (bd/bd_neg): New code_attrs.
33534 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
33535 a single define_insn.
33536 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
33537 decrement (bdnzt/bdnzf/bdzt/bdzf).
33538 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
33539 with the new names of the branch decrement patterns, and added the
33540 names of the branch decrement conditional patterns.
33542 2018-01-08 Richard Biener <rguenther@suse.de>
33544 PR tree-optimization/83563
33545 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
33548 2018-01-08 Richard Biener <rguenther@suse.de>
33550 PR middle-end/83713
33551 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
33553 2018-01-08 Richard Biener <rguenther@suse.de>
33555 PR tree-optimization/83685
33556 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
33557 references to abnormals.
33559 2018-01-08 Richard Biener <rguenther@suse.de>
33562 * dwarf2out.c (output_indirect_strings): Handle empty
33563 skeleton_debug_str_hash.
33564 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
33566 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
33568 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
33569 (emit_store_direct): Likewise.
33570 (arc_trampoline_adjust_address): Likewise.
33571 (arc_asm_trampoline_template): New function.
33572 (arc_initialize_trampoline): Use asm_trampoline_template.
33573 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
33574 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
33575 * config/arc/arc.md (flush_icache): Delete pattern.
33577 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
33579 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
33580 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
33583 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
33586 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
33587 by not USED_FOR_TARGET.
33588 (make_pass_resolve_sw_modes): Likewise.
33590 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
33592 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
33595 2018-01-08 Richard Biener <rguenther@suse.de>
33597 PR middle-end/83580
33598 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
33600 2018-01-08 Richard Biener <rguenther@suse.de>
33602 PR middle-end/83517
33603 * match.pd ((t * 2) / 2) -> t): Add missing :c.
33605 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
33607 PR middle-end/81897
33608 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
33609 basic blocks with a small number of successors.
33610 (convert_control_dep_chain_into_preds): Improve handling of
33612 (dump_predicates): Split apart into...
33613 (dump_pred_chain): ...here...
33614 (dump_pred_info): ...and here.
33615 (can_one_predicate_be_invalidated_p): Add debugging printfs.
33616 (can_chain_union_be_invalidated_p): Improve check for invalidation
33618 (uninit_uses_cannot_happen): Avoid unnecessary if
33619 convert_control_dep_chain_into_preds yielded nothing.
33621 2018-01-06 Martin Sebor <msebor@redhat.com>
33623 PR tree-optimization/83640
33624 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
33625 subtracting negative offset from size.
33626 (builtin_access::overlap): Adjust offset bounds of the access to fall
33627 within the size of the object if possible.
33629 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
33631 PR rtl-optimization/83699
33632 * expmed.c (extract_bit_field_1): Restrict the vector usage of
33633 extract_bit_field_as_subreg to cases in which the extracted
33634 value is also a vector.
33636 * lra-constraints.c (process_alt_operands): Test for the equivalence
33637 substitutions when detecting a possible reload cycle.
33639 2018-01-06 Jakub Jelinek <jakub@redhat.com>
33642 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
33643 by default if flag_selective_schedling{,2}. Formatting fixes.
33645 PR rtl-optimization/83682
33646 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
33647 if it has non-VECTOR_MODE element mode.
33648 (vec_duplicate_p): Likewise.
33650 PR middle-end/83694
33651 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
33652 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
33654 2018-01-05 Jakub Jelinek <jakub@redhat.com>
33657 * config/i386/i386-builtin.def
33658 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
33659 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
33660 Require also OPTION_MASK_ISA_AVX512F in addition to
33661 OPTION_MASK_ISA_GFNI.
33662 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
33663 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
33664 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
33665 to OPTION_MASK_ISA_GFNI.
33666 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
33667 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
33668 OPTION_MASK_ISA_AVX512BW.
33669 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
33670 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
33671 addition to OPTION_MASK_ISA_GFNI.
33672 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
33673 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
33674 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
33675 to OPTION_MASK_ISA_GFNI.
33676 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
33677 a requirement for all ISAs rather than any of them with a few
33679 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
33681 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
33682 bitmasks to be enabled with 3 exceptions, instead of requiring any
33683 enabled ISA with lots of exceptions.
33684 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
33685 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
33686 Change avx512bw in isa attribute to avx512f.
33687 * config/i386/sgxintrin.h: Add license boilerplate.
33688 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
33689 to __AVX512F__ and __AVX512VL to __AVX512VL__.
33690 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
33691 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
33693 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
33694 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
33695 temporarily sse2 rather than sse if not enabled already.
33698 * config/i386/sse.md (VI248_VLBW): Rename to ...
33699 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
33700 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
33701 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
33702 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
33703 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
33704 mode iterator instead of VI248_VLBW.
33706 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
33708 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
33709 (record_modified): Skip clobbers; add debug output.
33710 (param_change_prob): Use sreal frequencies.
33712 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
33714 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
33715 punt for user-aligned variables.
33717 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
33719 * tree-chrec.c (chrec_contains_symbols): Return true for
33722 2018-01-05 Sudakshina Das <sudi.das@arm.com>
33725 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
33726 of (x|y) == x for BICS pattern.
33728 2018-01-05 Jakub Jelinek <jakub@redhat.com>
33730 PR tree-optimization/83605
33731 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
33732 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
33735 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
33737 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
33738 * config/epiphany/rtems.h: New file.
33740 2018-01-04 Jakub Jelinek <jakub@redhat.com>
33741 Uros Bizjak <ubizjak@gmail.com>
33744 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
33745 QIreg_operand instead of register_operand predicate.
33746 * config/i386/i386.c (ix86_rop_should_change_byte_p,
33747 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
33748 comments instead of -fmitigate[-_]rop.
33750 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
33753 * cgraphunit.c (symbol_table::compile): Switch to text_section
33754 before calling assembly_start debug hook.
33755 * run-rtl-passes.c (run_rtl_passes): Likewise.
33758 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
33760 * tree-vrp.c (extract_range_from_binary_expr_1): Check
33761 range_int_cst_p rather than !symbolic_range_p before calling
33762 extract_range_from_multiplicative_op_1.
33764 2018-01-04 Jeff Law <law@redhat.com>
33766 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
33767 redundant test in assertion.
33769 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
33771 * doc/rtl.texi: Document machine_mode wrapper classes.
33773 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
33775 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
33776 using tree_to_uhwi.
33778 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
33780 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
33781 the VEC_PERM_EXPR fold to fail.
33783 2018-01-04 Jakub Jelinek <jakub@redhat.com>
33786 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
33787 to switched_sections.
33789 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
33792 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
33793 test for d.testing.
33795 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
33798 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
33799 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
33801 2018-01-04 Jakub Jelinek <jakub@redhat.com>
33804 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
33805 is BLKmode and bitpos not zero or mode change is needed.
33807 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
33810 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
33813 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
33816 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
33817 instead of MULT rtx. Update all corresponding splitters.
33818 (*saddl_se): Ditto.
33819 (*ssub<modesuffix>): Ditto.
33820 (*ssubl_se): Ditto.
33821 (*cmp_sadd_di): Update split patterns.
33822 (*cmp_sadd_si): Ditto.
33823 (*cmp_sadd_sidi): Ditto.
33824 (*cmp_ssub_di): Ditto.
33825 (*cmp_ssub_si): Ditto.
33826 (*cmp_ssub_sidi): Ditto.
33827 * config/alpha/predicates.md (const23_operand): New predicate.
33828 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
33829 Look for ASHIFT, not MULT inner operand.
33830 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
33832 2018-01-04 Martin Liska <mliska@suse.cz>
33834 PR gcov-profile/83669
33835 * gcov.c (output_intermediate_file): Add version to intermediate
33837 * doc/gcov.texi: Document new field 'version' in intermediate
33838 file format. Fix location of '-k' option of gcov command.
33840 2018-01-04 Martin Liska <mliska@suse.cz>
33843 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
33845 2018-01-04 Jakub Jelinek <jakub@redhat.com>
33847 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
33849 2018-01-03 Martin Sebor <msebor@redhat.com>
33851 PR tree-optimization/83655
33852 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
33853 checking calls with invalid arguments.
33855 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33857 * tree-vect-stmts.c (vect_get_store_rhs): New function.
33858 (vectorizable_mask_load_store): Delete.
33859 (vectorizable_call): Return false for masked loads and stores.
33860 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
33861 instead of gimple_assign_rhs1.
33862 (vectorizable_load): Handle IFN_MASK_LOAD.
33863 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
33865 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33867 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
33869 (vectorizable_mask_load_store): ...here.
33870 (vectorizable_load): ...and here.
33872 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33874 * tree-vect-stmts.c (vect_build_all_ones_mask)
33875 (vect_build_zero_merge_argument): New functions, split out from...
33876 (vectorizable_load): ...here.
33878 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33880 * tree-vect-stmts.c (vect_check_store_rhs): New function,
33882 (vectorizable_mask_load_store): ...here.
33883 (vectorizable_store): ...and here.
33885 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33887 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
33889 (vectorizable_mask_load_store): ...here.
33891 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33893 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
33894 (vect_model_store_cost): Take a vec_load_store_type instead of a
33896 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
33897 (vect_model_store_cost): Take a vec_load_store_type instead of a
33899 (vectorizable_mask_load_store): Update accordingly.
33900 (vectorizable_store): Likewise.
33901 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
33903 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33905 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
33906 IFN_MASK_LOAD calls here rather than...
33907 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
33909 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33910 Alan Hayward <alan.hayward@arm.com>
33911 David Sherwood <david.sherwood@arm.com>
33913 * expmed.c (extract_bit_field_1): For vector extracts,
33914 fall back to extract_bit_field_as_subreg if vec_extract
33917 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33918 Alan Hayward <alan.hayward@arm.com>
33919 David Sherwood <david.sherwood@arm.com>
33921 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
33922 they are variable or constant sized.
33923 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
33924 slots for constant-sized data.
33926 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33927 Alan Hayward <alan.hayward@arm.com>
33928 David Sherwood <david.sherwood@arm.com>
33930 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
33931 handling COND_EXPRs with boolean comparisons, try to find a better
33932 basis for the mask type than the boolean itself.
33934 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33936 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
33937 is calculated and how it can be overridden.
33938 * genmodes.c (max_bitsize_mode_any_mode): New variable.
33939 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
33941 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
33944 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33945 Alan Hayward <alan.hayward@arm.com>
33946 David Sherwood <david.sherwood@arm.com>
33948 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
33949 Remove the mode argument.
33950 (aarch64_simd_valid_immediate): Remove the mode and inverse
33952 * config/aarch64/iterators.md (bitsize): New iterator.
33953 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
33954 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
33955 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
33956 aarch64_simd_valid_immediate.
33957 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
33958 (aarch64_reg_or_bic_imm): Likewise.
33959 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
33960 with an insn_type enum and msl with a modifier_type enum.
33961 Replace element_width with a scalar_mode. Change the shift
33962 to unsigned int. Add constructors for scalar_float_mode and
33963 scalar_int_mode elements.
33964 (aarch64_vect_float_const_representable_p): Delete.
33965 (aarch64_can_const_movi_rtx_p)
33966 (aarch64_simd_scalar_immediate_valid_for_move)
33967 (aarch64_simd_make_constant): Update call to
33968 aarch64_simd_valid_immediate.
33969 (aarch64_advsimd_valid_immediate_hs): New function.
33970 (aarch64_advsimd_valid_immediate): Likewise.
33971 (aarch64_simd_valid_immediate): Remove mode and inverse
33972 arguments. Rewrite to use the above. Use const_vec_duplicate_p
33973 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
33974 and aarch64_float_const_representable_p on the result.
33975 (aarch64_output_simd_mov_immediate): Remove mode argument.
33976 Update call to aarch64_simd_valid_immediate and use of
33977 simd_immediate_info.
33978 (aarch64_output_scalar_simd_mov_immediate): Update call
33981 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
33982 Alan Hayward <alan.hayward@arm.com>
33983 David Sherwood <david.sherwood@arm.com>
33985 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
33986 (mode_nunits): Likewise CONST_MODE_NUNITS.
33987 * machmode.def (ADJUST_NUNITS): Document.
33988 * genmodes.c (mode_data::need_nunits_adj): New field.
33989 (blank_mode): Update accordingly.
33990 (adj_nunits): New variable.
33991 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
33993 (emit_mode_size_inline): Set need_bytesize_adj for all modes
33994 listed in adj_nunits.
33995 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
33996 listed in adj_nunits. Don't emit case statements for such modes.
33997 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
33998 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
33999 nothing if adj_nunits is nonnull.
34000 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
34001 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
34002 (emit_mode_fbit): Update use of print_maybe_const_decl.
34003 (emit_move_size): Likewise. Treat the array as non-const
34005 (emit_mode_adjustments): Handle adj_nunits.
34007 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34009 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
34010 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
34011 (VECTOR_MODES): Use it.
34012 (make_vector_modes): Take the prefix as an argument.
34014 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34015 Alan Hayward <alan.hayward@arm.com>
34016 David Sherwood <david.sherwood@arm.com>
34018 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
34019 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
34020 for MODE_VECTOR_BOOL.
34021 * machmode.def (VECTOR_BOOL_MODE): Document.
34022 * genmodes.c (VECTOR_BOOL_MODE): New macro.
34023 (make_vector_bool_mode): New function.
34024 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
34026 * lto-streamer-in.c (lto_input_mode_table): Likewise.
34027 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
34029 * stor-layout.c (int_mode_for_mode): Likewise.
34030 * tree.c (build_vector_type_for_mode): Likewise.
34031 * varasm.c (output_constant_pool_2): Likewise.
34032 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
34033 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
34034 for MODE_VECTOR_BOOL.
34035 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
34036 of mode class checks.
34037 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
34038 instead of a list of mode class checks.
34039 (expand_vector_scalar_condition): Likewise.
34040 (type_for_widest_vector_mode): Handle BImode as an inner mode.
34042 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34043 Alan Hayward <alan.hayward@arm.com>
34044 David Sherwood <david.sherwood@arm.com>
34046 * machmode.h (mode_size): Change from unsigned short to
34048 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
34049 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
34050 or if measurement_type is not polynomial.
34051 (fixed_size_mode::includes_p): Check for constant-sized modes.
34052 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
34053 return a poly_uint16 rather than an unsigned short.
34054 (emit_mode_size): Change the type of mode_size from unsigned short
34055 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
34056 (emit_mode_adjustments): Cope with polynomial vector sizes.
34057 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
34059 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
34061 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
34062 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
34063 * caller-save.c (setup_save_areas): Likewise.
34064 (replace_reg_with_saved_mem): Likewise.
34065 * calls.c (emit_library_call_value_1): Likewise.
34066 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
34067 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
34068 (gen_lowpart_for_combine): Likewise.
34069 * convert.c (convert_to_integer_1): Likewise.
34070 * cse.c (equiv_constant, cse_insn): Likewise.
34071 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
34072 (cselib_subst_to_values): Likewise.
34073 * dce.c (word_dce_process_block): Likewise.
34074 * df-problems.c (df_word_lr_mark_ref): Likewise.
34075 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
34076 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
34077 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
34078 (rtl_for_decl_location): Likewise.
34079 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
34080 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
34081 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
34082 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
34083 (expand_expr_real_1): Likewise.
34084 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
34085 (pad_below): Likewise.
34086 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
34087 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
34088 * ira.c (get_subreg_tracking_sizes): Likewise.
34089 * ira-build.c (ira_create_allocno_objects): Likewise.
34090 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
34091 (ira_sort_regnos_for_alter_reg): Likewise.
34092 * ira-costs.c (record_operand_costs): Likewise.
34093 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
34094 (resolve_simple_move): Likewise.
34095 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
34096 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
34097 (lra_constraints): Likewise.
34098 (CONST_POOL_OK_P): Reject variable-sized modes.
34099 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
34100 (add_pseudo_to_slot, lra_spill): Likewise.
34101 * omp-low.c (omp_clause_aligned_alignment): Likewise.
34102 * optabs-query.c (get_best_extraction_insn): Likewise.
34103 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
34104 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
34105 (expand_mult_highpart, valid_multiword_target_p): Likewise.
34106 * recog.c (offsettable_address_addr_space_p): Likewise.
34107 * regcprop.c (maybe_mode_change): Likewise.
34108 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
34109 * regrename.c (build_def_use): Likewise.
34110 * regstat.c (dump_reg_info): Likewise.
34111 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
34112 (find_reloads, find_reloads_subreg_address): Likewise.
34113 * reload1.c (eliminate_regs_1): Likewise.
34114 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
34115 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
34116 (simplify_binary_operation_1, simplify_subreg): Likewise.
34117 * targhooks.c (default_function_arg_padding): Likewise.
34118 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
34119 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
34120 (verify_gimple_assign_ternary): Likewise.
34121 * tree-inline.c (estimate_move_cost): Likewise.
34122 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
34123 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
34124 (get_address_cost_ainc): Likewise.
34125 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
34126 (vect_supportable_dr_alignment): Likewise.
34127 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
34128 (vectorizable_reduction): Likewise.
34129 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
34130 (vectorizable_operation, vectorizable_load): Likewise.
34131 * tree.c (build_same_sized_truth_vector_type): Likewise.
34132 * valtrack.c (cleanup_auto_inc_dec): Likewise.
34133 * var-tracking.c (emit_note_insn_var_location): Likewise.
34134 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
34135 (ADDR_VEC_ALIGN): Likewise.
34137 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34138 Alan Hayward <alan.hayward@arm.com>
34139 David Sherwood <david.sherwood@arm.com>
34141 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
34143 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
34144 or if measurement_type is polynomial.
34145 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
34146 * combine.c (make_extraction): Likewise.
34147 * dse.c (find_shift_sequence): Likewise.
34148 * dwarf2out.c (mem_loc_descriptor): Likewise.
34149 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
34150 (extract_bit_field, extract_low_bits): Likewise.
34151 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
34152 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
34153 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
34154 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
34155 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
34156 * reload.c (find_reloads): Likewise.
34157 * reload1.c (alter_reg): Likewise.
34158 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
34159 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
34160 * tree-if-conv.c (predicate_mem_writes): Likewise.
34161 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
34162 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
34163 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
34164 * valtrack.c (dead_debug_insert_temp): Likewise.
34165 * varasm.c (mergeable_constant_section): Likewise.
34166 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
34168 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34169 Alan Hayward <alan.hayward@arm.com>
34170 David Sherwood <david.sherwood@arm.com>
34172 * expr.c (expand_assignment): Cope with polynomial mode sizes
34173 when assigning to a CONCAT.
34175 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34176 Alan Hayward <alan.hayward@arm.com>
34177 David Sherwood <david.sherwood@arm.com>
34179 * machmode.h (mode_precision): Change from unsigned short to
34181 (mode_to_precision): Return a poly_uint16 rather than an unsigned
34183 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
34184 or if measurement_type is not polynomial.
34185 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
34186 in which the mode is already known to be a scalar_int_mode.
34187 * genmodes.c (emit_mode_precision): Change the type of mode_precision
34188 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
34190 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
34191 for GET_MODE_PRECISION.
34192 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
34193 for GET_MODE_PRECISION.
34194 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
34196 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
34197 (expand_field_assignment, make_extraction): Likewise.
34198 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
34199 (get_last_value): Likewise.
34200 * convert.c (convert_to_integer_1): Likewise.
34201 * cse.c (cse_insn): Likewise.
34202 * expr.c (expand_expr_real_1): Likewise.
34203 * lra-constraints.c (simplify_operand_subreg): Likewise.
34204 * optabs-query.c (can_atomic_load_p): Likewise.
34205 * optabs.c (expand_atomic_load): Likewise.
34206 (expand_atomic_store): Likewise.
34207 * ree.c (combine_reaching_defs): Likewise.
34208 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
34209 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
34210 * tree.h (type_has_mode_precision_p): Likewise.
34211 * ubsan.c (instrument_si_overflow): Likewise.
34213 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34214 Alan Hayward <alan.hayward@arm.com>
34215 David Sherwood <david.sherwood@arm.com>
34217 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
34218 polynomial numbers of units.
34219 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
34220 (valid_vector_subparts_p): New function.
34221 (build_vector_type): Remove temporary shim and take the number
34222 of units as a poly_uint64 rather than an int.
34223 (build_opaque_vector_type): Take the number of units as a
34224 poly_uint64 rather than an int.
34225 * tree.c (build_vector_from_ctor): Handle polynomial
34226 TYPE_VECTOR_SUBPARTS.
34227 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
34228 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
34229 (build_vector_from_val): If the number of units is variable,
34230 use build_vec_duplicate_cst for constant operands and
34231 VEC_DUPLICATE_EXPR otherwise.
34232 (make_vector_type): Remove temporary is_constant ().
34233 (build_vector_type, build_opaque_vector_type): Take the number of
34234 units as a poly_uint64 rather than an int.
34235 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
34237 * cfgexpand.c (expand_debug_expr): Likewise.
34238 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
34239 (store_constructor, expand_expr_real_1): Likewise.
34240 (const_scalar_mask_from_tree): Likewise.
34241 * fold-const-call.c (fold_const_reduction): Likewise.
34242 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
34243 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
34244 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
34245 (fold_relational_const): Likewise.
34246 (native_interpret_vector): Likewise. Change the size from an
34247 int to an unsigned int.
34248 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
34249 TYPE_VECTOR_SUBPARTS.
34250 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
34251 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
34252 duplicating a non-constant operand into a variable-length vector.
34253 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
34254 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
34255 * ipa-icf.c (sem_variable::equals): Likewise.
34256 * match.pd: Likewise.
34257 * omp-simd-clone.c (simd_clone_subparts): Likewise.
34258 * print-tree.c (print_node): Likewise.
34259 * stor-layout.c (layout_type): Likewise.
34260 * targhooks.c (default_builtin_vectorization_cost): Likewise.
34261 * tree-cfg.c (verify_gimple_comparison): Likewise.
34262 (verify_gimple_assign_binary): Likewise.
34263 (verify_gimple_assign_ternary): Likewise.
34264 (verify_gimple_assign_single): Likewise.
34265 * tree-pretty-print.c (dump_generic_node): Likewise.
34266 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
34267 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
34268 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
34269 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
34270 (vect_shift_permute_load_chain): Likewise.
34271 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
34272 (expand_vector_condition, optimize_vector_constructor): Likewise.
34273 (lower_vec_perm, get_compute_type): Likewise.
34274 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
34275 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
34276 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
34277 (vect_recog_mask_conversion_pattern): Likewise.
34278 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
34279 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
34280 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
34281 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
34282 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
34283 (vectorizable_shift, vectorizable_operation, vectorizable_store)
34284 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
34285 (supportable_widening_operation): Likewise.
34286 (supportable_narrowing_operation): Likewise.
34287 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
34289 * varasm.c (output_constant): Likewise.
34291 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34292 Alan Hayward <alan.hayward@arm.com>
34293 David Sherwood <david.sherwood@arm.com>
34295 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
34296 so that both the length == 3 and length != 3 cases set up their
34297 own permute vectors. Add comments explaining why we know the
34298 number of elements is constant.
34299 (vect_permute_load_chain): Likewise.
34301 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34302 Alan Hayward <alan.hayward@arm.com>
34303 David Sherwood <david.sherwood@arm.com>
34305 * machmode.h (mode_nunits): Change from unsigned char to
34307 (ONLY_FIXED_SIZE_MODES): New macro.
34308 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
34309 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
34310 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
34312 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
34313 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
34314 or if measurement_type is not polynomial.
34315 * genmodes.c (ZERO_COEFFS): New macro.
34316 (emit_mode_nunits_inline): Make mode_nunits_inline return a
34318 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
34319 Use ZERO_COEFFS when emitting initializers.
34320 * data-streamer.h (bp_pack_poly_value): New function.
34321 (bp_unpack_poly_value): Likewise.
34322 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
34323 for GET_MODE_NUNITS.
34324 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
34325 for GET_MODE_NUNITS.
34326 * tree.c (make_vector_type): Remove temporary shim and make
34327 the real function take the number of units as a poly_uint64
34328 rather than an int.
34329 (build_vector_type_for_mode): Handle polynomial nunits.
34330 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
34331 * emit-rtl.c (const_vec_series_p_1): Likewise.
34332 (gen_rtx_CONST_VECTOR): Likewise.
34333 * fold-const.c (test_vec_duplicate_folding): Likewise.
34334 * genrecog.c (validate_pattern): Likewise.
34335 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
34336 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
34337 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
34338 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
34339 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
34340 * rtlanal.c (subreg_get_info): Likewise.
34341 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
34342 (vect_grouped_load_supported): Likewise.
34343 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
34344 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
34345 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
34346 (simplify_const_unary_operation, simplify_binary_operation_1)
34347 (simplify_const_binary_operation, simplify_ternary_operation)
34348 (test_vector_ops_duplicate, test_vector_ops): Likewise.
34349 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
34350 instead of CONST_VECTOR_NUNITS.
34351 * varasm.c (output_constant_pool_2): Likewise.
34352 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
34353 explicit-encoded elements in the XVEC for variable-length vectors.
34355 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34357 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
34359 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34360 Alan Hayward <alan.hayward@arm.com>
34361 David Sherwood <david.sherwood@arm.com>
34363 * coretypes.h (fixed_size_mode): Declare.
34364 (fixed_size_mode_pod): New typedef.
34365 * builtins.h (target_builtins::x_apply_args_mode)
34366 (target_builtins::x_apply_result_mode): Change type to
34367 fixed_size_mode_pod.
34368 * builtins.c (apply_args_size, apply_result_size, result_vector)
34369 (expand_builtin_apply_args_1, expand_builtin_apply)
34370 (expand_builtin_return): Update accordingly.
34372 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34374 * cse.c (hash_rtx_cb): Hash only the encoded elements.
34375 * cselib.c (cselib_hash_rtx): Likewise.
34376 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
34377 CONST_VECTOR encoding.
34379 2018-01-03 Jakub Jelinek <jakub@redhat.com>
34380 Jeff Law <law@redhat.com>
34383 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
34384 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
34385 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
34386 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
34389 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
34390 explicitly probe *sp in a noreturn function if there were any callee
34391 register saves or frame pointer is needed.
34393 2018-01-03 Jakub Jelinek <jakub@redhat.com>
34396 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
34397 BLKmode for ternary, binary or unary expressions.
34400 * var-tracking.c (delete_vta_debug_insn): New inline function.
34401 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
34402 insns from get_insns () to NULL instead of each bb separately.
34403 Use delete_vta_debug_insn. No longer static.
34404 (vt_debug_insns_local, variable_tracking_main_1): Adjust
34405 delete_vta_debug_insns callers.
34406 * rtl.h (delete_vta_debug_insns): Declare.
34407 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
34408 instead of variable_tracking_main.
34410 2018-01-03 Martin Sebor <msebor@redhat.com>
34412 PR tree-optimization/83603
34413 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
34414 arguments past the endof the argument list in functions declared
34415 without a prototype.
34416 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
34417 Avoid checking when arguments are null.
34419 2018-01-03 Martin Sebor <msebor@redhat.com>
34422 * doc/extend.texi (attribute const): Fix a typo.
34423 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
34424 issuing -Wsuggest-attribute for void functions.
34426 2018-01-03 Martin Sebor <msebor@redhat.com>
34428 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
34429 offset_int::from instead of wide_int::to_shwi.
34430 (maybe_diag_overlap): Remove assertion.
34431 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
34432 * gimple-ssa-sprintf.c (format_directive): Same.
34433 (parse_directive): Same.
34434 (sprintf_dom_walker::compute_format_length): Same.
34435 (try_substitute_return_value): Same.
34437 2018-01-03 Jeff Law <law@redhat.com>
34439 PR middle-end/83654
34440 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
34441 non-constant residual for zero at runtime and avoid probing in
34442 that case. Reorganize code for trailing problem to mirror handling
34445 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
34447 PR tree-optimization/83501
34448 * tree-ssa-strlen.c (get_string_cst): New.
34449 (handle_char_store): Call get_string_cst.
34451 2018-01-03 Martin Liska <mliska@suse.cz>
34453 PR tree-optimization/83593
34454 * tree-ssa-strlen.c: Include tree-cfg.h.
34455 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
34456 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
34457 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
34459 (strlen_dom_walker::before_dom_children): Call
34460 gimple_purge_dead_eh_edges. Dump tranformation with details
34462 (strlen_dom_walker::before_dom_children): Update call by adding
34463 new argument cleanup_eh.
34464 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
34466 2018-01-03 Martin Liska <mliska@suse.cz>
34469 * cif-code.def (VARIADIC_THUNK): New enum value.
34470 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
34473 2018-01-03 Jan Beulich <jbeulich@suse.com>
34475 * sse.md (mov<mode>_internal): Tighten condition for when to use
34476 vmovdqu<ssescalarsize> for TI and OI modes.
34478 2018-01-03 Jakub Jelinek <jakub@redhat.com>
34480 Update copyright years.
34482 2018-01-03 Martin Liska <mliska@suse.cz>
34485 * ipa-visibility.c (function_and_variable_visibility): Skip
34486 functions with noipa attribure.
34488 2018-01-03 Jakub Jelinek <jakub@redhat.com>
34490 * gcc.c (process_command): Update copyright notice dates.
34491 * gcov-dump.c (print_version): Ditto.
34492 * gcov.c (print_version): Ditto.
34493 * gcov-tool.c (print_version): Ditto.
34494 * gengtype.c (create_file): Ditto.
34495 * doc/cpp.texi: Bump @copying's copyright year.
34496 * doc/cppinternals.texi: Ditto.
34497 * doc/gcc.texi: Ditto.
34498 * doc/gccint.texi: Ditto.
34499 * doc/gcov.texi: Ditto.
34500 * doc/install.texi: Ditto.
34501 * doc/invoke.texi: Ditto.
34503 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34505 * vector-builder.h (vector_builder::m_full_nelts): Change from
34506 unsigned int to poly_uint64.
34507 (vector_builder::full_nelts): Update prototype accordingly.
34508 (vector_builder::new_vector): Likewise.
34509 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
34510 (vector_builder::operator ==): Likewise.
34511 (vector_builder::finalize): Likewise.
34512 * int-vector-builder.h (int_vector_builder::int_vector_builder):
34513 Take the number of elements as a poly_uint64 rather than an
34515 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
34516 from unsigned int to poly_uint64.
34517 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
34518 (vec_perm_indices::new_vector): Likewise.
34519 (vec_perm_indices::length): Likewise.
34520 (vec_perm_indices::nelts_per_input): Likewise.
34521 (vec_perm_indices::input_nelts): Likewise.
34522 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
34523 number of elements per input as a poly_uint64 rather than an
34524 unsigned int. Use the original encoding for variable-length
34525 vectors, rather than clamping each individual element.
34526 For the second and subsequent elements in each pattern,
34527 clamp the step and base before clamping their sum.
34528 (vec_perm_indices::series_p): Handle polynomial element counts.
34529 (vec_perm_indices::all_in_range_p): Likewise.
34530 (vec_perm_indices_to_tree): Likewise.
34531 (vec_perm_indices_to_rtx): Likewise.
34532 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
34533 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
34534 (tree_vector_builder::new_binary_operation): Handle polynomial
34535 element counts. Return false if we need to know the number
34536 of elements at compile time.
34537 * fold-const.c (fold_vec_perm): Punt if the number of elements
34538 isn't known at compile time.
34540 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34542 * vec-perm-indices.h (vec_perm_builder): Change element type
34543 from HOST_WIDE_INT to poly_int64.
34544 (vec_perm_indices::element_type): Update accordingly.
34545 (vec_perm_indices::clamp): Handle polynomial element_types.
34546 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
34547 (vec_perm_indices::all_in_range_p): Likewise.
34548 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
34550 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
34551 polynomial vec_perm_indices element types.
34552 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
34553 * fold-const.c (fold_vec_perm): Likewise.
34554 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
34555 * tree-vect-generic.c (lower_vec_perm): Likewise.
34556 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
34557 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
34558 element type to HOST_WIDE_INT.
34560 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34561 Alan Hayward <alan.hayward@arm.com>
34562 David Sherwood <david.sherwood@arm.com>
34564 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
34565 rather than an int. Use plus_constant.
34566 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
34567 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
34569 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34570 Alan Hayward <alan.hayward@arm.com>
34571 David Sherwood <david.sherwood@arm.com>
34573 * calls.c (emit_call_1, expand_call): Change struct_value_size from
34574 a HOST_WIDE_INT to a poly_int64.
34576 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34577 Alan Hayward <alan.hayward@arm.com>
34578 David Sherwood <david.sherwood@arm.com>
34580 * calls.c (load_register_parameters): Cope with polynomial
34581 mode sizes. Require a constant size for BLKmode parameters
34582 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
34583 forces a parameter to be padded at the lsb end in order to
34584 fill a complete number of words, require the parameter size
34585 to be ordered wrt UNITS_PER_WORD.
34587 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34588 Alan Hayward <alan.hayward@arm.com>
34589 David Sherwood <david.sherwood@arm.com>
34591 * reload1.c (spill_stack_slot_width): Change element type
34592 from unsigned int to poly_uint64_pod.
34593 (alter_reg): Treat mode sizes as polynomial.
34595 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34596 Alan Hayward <alan.hayward@arm.com>
34597 David Sherwood <david.sherwood@arm.com>
34599 * reload.c (complex_word_subreg_p): New function.
34600 (reload_inner_reg_of_subreg, push_reload): Use it.
34602 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34603 Alan Hayward <alan.hayward@arm.com>
34604 David Sherwood <david.sherwood@arm.com>
34606 * lra-constraints.c (process_alt_operands): Reject matched
34607 operands whose sizes aren't ordered.
34608 (match_reload): Refer to this check here.
34610 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34611 Alan Hayward <alan.hayward@arm.com>
34612 David Sherwood <david.sherwood@arm.com>
34614 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
34615 that the mode size is in the set {1, 2, 4, 8, 16}.
34617 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34618 Alan Hayward <alan.hayward@arm.com>
34619 David Sherwood <david.sherwood@arm.com>
34621 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
34622 Use plus_constant instead of gen_rtx_PLUS.
34624 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34625 Alan Hayward <alan.hayward@arm.com>
34626 David Sherwood <david.sherwood@arm.com>
34628 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
34629 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
34630 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
34631 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
34632 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
34633 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
34634 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
34635 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
34636 * config/i386/i386.c (ix86_push_rounding): ...this new function.
34637 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
34639 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
34640 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
34641 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
34642 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
34643 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
34644 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
34645 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
34646 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
34647 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
34648 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
34650 * expr.c (emit_move_resolve_push): Treat the input and result
34651 of PUSH_ROUNDING as a poly_int64.
34652 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
34653 (emit_push_insn): Likewise.
34654 * lra-eliminations.c (mark_not_eliminable): Likewise.
34655 * recog.c (push_operand): Likewise.
34656 * reload1.c (elimination_effects): Likewise.
34657 * rtlanal.c (nonzero_bits1): Likewise.
34658 * calls.c (store_one_arg): Likewise. Require the padding to be
34659 known at compile time.
34661 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34662 Alan Hayward <alan.hayward@arm.com>
34663 David Sherwood <david.sherwood@arm.com>
34665 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
34666 Use plus_constant instead of gen_rtx_PLUS.
34668 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34669 Alan Hayward <alan.hayward@arm.com>
34670 David Sherwood <david.sherwood@arm.com>
34672 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
34673 rather than an int.
34675 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34676 Alan Hayward <alan.hayward@arm.com>
34677 David Sherwood <david.sherwood@arm.com>
34679 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
34680 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
34681 via stack temporaries. Treat the mode size as polynomial too.
34683 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34684 Alan Hayward <alan.hayward@arm.com>
34685 David Sherwood <david.sherwood@arm.com>
34687 * expr.c (expand_expr_real_2): When handling conversions involving
34688 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
34689 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
34690 as a poly_uint64 too.
34692 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34693 Alan Hayward <alan.hayward@arm.com>
34694 David Sherwood <david.sherwood@arm.com>
34696 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
34698 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34699 Alan Hayward <alan.hayward@arm.com>
34700 David Sherwood <david.sherwood@arm.com>
34702 * combine.c (can_change_dest_mode): Handle polynomial
34703 REGMODE_NATURAL_SIZE.
34704 * expmed.c (store_bit_field_1): Likewise.
34705 * expr.c (store_constructor): Likewise.
34706 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
34707 and polynomial REGMODE_NATURAL_SIZE.
34708 (gen_lowpart_common): Likewise.
34709 * reginfo.c (record_subregs_of_mode): Likewise.
34710 * rtlanal.c (read_modify_subreg_p): Likewise.
34712 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34713 Alan Hayward <alan.hayward@arm.com>
34714 David Sherwood <david.sherwood@arm.com>
34716 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
34717 numbers of elements.
34719 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34720 Alan Hayward <alan.hayward@arm.com>
34721 David Sherwood <david.sherwood@arm.com>
34723 * match.pd: Cope with polynomial numbers of vector elements.
34725 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34726 Alan Hayward <alan.hayward@arm.com>
34727 David Sherwood <david.sherwood@arm.com>
34729 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
34730 in a POINTER_PLUS_EXPR.
34732 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34733 Alan Hayward <alan.hayward@arm.com>
34734 David Sherwood <david.sherwood@arm.com>
34736 * omp-simd-clone.c (simd_clone_subparts): New function.
34737 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
34738 (ipa_simd_modify_function_body): Likewise.
34740 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34741 Alan Hayward <alan.hayward@arm.com>
34742 David Sherwood <david.sherwood@arm.com>
34744 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
34745 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
34746 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
34747 (expand_vector_condition, vector_element): Likewise.
34748 (subparts_gt): New function.
34749 (get_compute_type): Use subparts_gt.
34750 (count_type_subparts): Delete.
34751 (expand_vector_operations_1): Use subparts_gt instead of
34752 count_type_subparts.
34754 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34755 Alan Hayward <alan.hayward@arm.com>
34756 David Sherwood <david.sherwood@arm.com>
34758 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
34759 (vect_compile_time_alias): ...this new function. Do the calculation
34760 on poly_ints rather than trees.
34761 (vect_prune_runtime_alias_test_list): Update call accordingly.
34763 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34764 Alan Hayward <alan.hayward@arm.com>
34765 David Sherwood <david.sherwood@arm.com>
34767 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
34769 (vect_schedule_slp_instance): Likewise.
34771 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34772 Alan Hayward <alan.hayward@arm.com>
34773 David Sherwood <david.sherwood@arm.com>
34775 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
34776 constant and extern definitions for variable-length vectors.
34777 (vect_get_constant_vectors): Note that the number of units
34778 is known to be constant.
34780 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34781 Alan Hayward <alan.hayward@arm.com>
34782 David Sherwood <david.sherwood@arm.com>
34784 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
34785 of units as polynomial. Choose between WIDE and NARROW based
34788 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34789 Alan Hayward <alan.hayward@arm.com>
34790 David Sherwood <david.sherwood@arm.com>
34792 * tree-vect-stmts.c (simd_clone_subparts): New function.
34793 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
34795 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34796 Alan Hayward <alan.hayward@arm.com>
34797 David Sherwood <david.sherwood@arm.com>
34799 * tree-vect-stmts.c (vectorizable_call): Treat the number of
34800 vectors as polynomial. Use build_index_vector for
34801 IFN_GOMP_SIMD_LANE.
34803 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34804 Alan Hayward <alan.hayward@arm.com>
34805 David Sherwood <david.sherwood@arm.com>
34807 * tree-vect-stmts.c (get_load_store_type): Treat the number of
34808 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
34809 for variable-length vectors.
34810 (vectorizable_mask_load_store): Treat the number of units as
34811 polynomial, asserting that it is constant if the condition has
34812 already been enforced.
34813 (vectorizable_store, vectorizable_load): Likewise.
34815 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34816 Alan Hayward <alan.hayward@arm.com>
34817 David Sherwood <david.sherwood@arm.com>
34819 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
34820 of units as polynomial. Punt if we can't tell at compile time
34821 which vector contains the final result.
34823 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34824 Alan Hayward <alan.hayward@arm.com>
34825 David Sherwood <david.sherwood@arm.com>
34827 * tree-vect-loop.c (vectorizable_induction): Treat the number
34828 of units as polynomial. Punt on SLP inductions. Use an integer
34829 VEC_SERIES_EXPR for variable-length integer reductions. Use a
34830 cast of such a series for variable-length floating-point
34833 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34834 Alan Hayward <alan.hayward@arm.com>
34835 David Sherwood <david.sherwood@arm.com>
34837 * tree.h (build_index_vector): Declare.
34838 * tree.c (build_index_vector): New function.
34839 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
34840 of units as polynomial, forcibly converting it to a constant if
34841 vectorizable_reduction has already enforced the condition.
34842 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
34843 to create a {1,2,3,...} vector.
34844 (vectorizable_reduction): Treat the number of units as polynomial.
34845 Choose vectype_in based on the largest scalar element size rather
34846 than the smallest number of units. Enforce the restrictions
34849 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34850 Alan Hayward <alan.hayward@arm.com>
34851 David Sherwood <david.sherwood@arm.com>
34853 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
34854 number of units as polynomial.
34856 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34857 Alan Hayward <alan.hayward@arm.com>
34858 David Sherwood <david.sherwood@arm.com>
34860 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
34861 * target.def (autovectorize_vector_sizes): Return the vector sizes
34862 by pointer, using vector_sizes rather than a bitmask.
34863 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
34864 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
34865 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
34867 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
34868 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
34869 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
34870 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
34871 * omp-general.c (omp_max_vf): Likewise.
34872 * omp-low.c (omp_clause_aligned_alignment): Likewise.
34873 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
34874 * tree-vect-loop.c (vect_analyze_loop): Likewise.
34875 * tree-vect-slp.c (vect_slp_bb): Likewise.
34876 * doc/tm.texi: Regenerate.
34877 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
34879 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
34880 the vector size as a poly_uint64 rather than an unsigned int.
34881 (current_vector_size): Change from an unsigned int to a poly_uint64.
34882 (get_vectype_for_scalar_type): Update accordingly.
34883 * tree.h (build_truth_vector_type): Take the size and number of
34884 units as a poly_uint64 rather than an unsigned int.
34885 (build_vector_type): Add a temporary overload that takes
34886 the number of units as a poly_uint64 rather than an unsigned int.
34887 * tree.c (make_vector_type): Likewise.
34888 (build_truth_vector_type): Take the number of units as a poly_uint64
34889 rather than an unsigned int.
34891 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34892 Alan Hayward <alan.hayward@arm.com>
34893 David Sherwood <david.sherwood@arm.com>
34895 * target.def (get_mask_mode): Take the number of units and length
34896 as poly_uint64s rather than unsigned ints.
34897 * targhooks.h (default_get_mask_mode): Update accordingly.
34898 * targhooks.c (default_get_mask_mode): Likewise.
34899 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
34900 * doc/tm.texi: Regenerate.
34902 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34903 Alan Hayward <alan.hayward@arm.com>
34904 David Sherwood <david.sherwood@arm.com>
34906 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
34907 * omp-general.c (omp_max_vf): Likewise.
34908 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
34909 (expand_omp_simd): Handle polynomial safelen.
34910 * omp-low.c (omplow_simd_context): Add a default constructor.
34911 (omplow_simd_context::max_vf): Change from int to poly_uint64.
34912 (lower_rec_simd_input_clauses): Update accordingly.
34913 (lower_rec_input_clauses): Likewise.
34915 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34916 Alan Hayward <alan.hayward@arm.com>
34917 David Sherwood <david.sherwood@arm.com>
34919 * tree-vectorizer.h (vect_nunits_for_cost): New function.
34920 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
34921 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
34922 (vect_analyze_slp_cost): Likewise.
34923 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
34924 (vect_model_load_cost): Likewise.
34926 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34927 Alan Hayward <alan.hayward@arm.com>
34928 David Sherwood <david.sherwood@arm.com>
34930 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
34931 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
34932 from an unsigned int * to a poly_uint64_pod *.
34933 (calculate_unrolling_factor): New function.
34934 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
34936 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34937 Alan Hayward <alan.hayward@arm.com>
34938 David Sherwood <david.sherwood@arm.com>
34940 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
34941 from an unsigned int to a poly_uint64.
34942 (_loop_vec_info::slp_unrolling_factor): Likewise.
34943 (_loop_vec_info::vectorization_factor): Change from an int
34945 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
34946 (vect_get_num_vectors): New function.
34947 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
34948 (vect_get_num_copies): Use vect_get_num_vectors.
34949 (vect_analyze_data_ref_dependences): Change max_vf from an int *
34950 to an unsigned int *.
34951 (vect_analyze_data_refs): Change min_vf from an int * to a
34953 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
34954 than an unsigned HOST_WIDE_INT.
34955 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
34956 (vect_analyze_data_ref_dependence): Change max_vf from an int *
34957 to an unsigned int *.
34958 (vect_analyze_data_ref_dependences): Likewise.
34959 (vect_compute_data_ref_alignment): Handle polynomial vf.
34960 (vect_enhance_data_refs_alignment): Likewise.
34961 (vect_prune_runtime_alias_test_list): Likewise.
34962 (vect_shift_permute_load_chain): Likewise.
34963 (vect_supportable_dr_alignment): Likewise.
34964 (dependence_distance_ge_vf): Take the vectorization factor as a
34965 poly_uint64 rather than an unsigned HOST_WIDE_INT.
34966 (vect_analyze_data_refs): Change min_vf from an int * to a
34968 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
34969 vfm1 as a poly_uint64 rather than an int. Make the same change
34970 for the returned bound_scalar.
34971 (vect_gen_vector_loop_niters): Handle polynomial vf.
34972 (vect_do_peeling): Likewise. Update call to
34973 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
34974 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
34976 * tree-vect-loop.c (vect_determine_vectorization_factor)
34977 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
34978 (vect_get_known_peeling_cost): Likewise.
34979 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
34980 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
34981 (vect_transform_loop): Likewise. Use the lowest possible VF when
34982 updating the upper bounds of the loop.
34983 (vect_min_worthwhile_factor): Make static. Return an unsigned int
34984 rather than an int.
34985 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
34986 polynomial unroll factors.
34987 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
34988 (vect_make_slp_decision): Likewise.
34989 (vect_supported_load_permutation_p): Likewise, and polynomial
34991 (vect_analyze_slp_cost): Handle polynomial vf.
34992 (vect_slp_analyze_node_operations): Likewise.
34993 (vect_slp_analyze_bb_1): Likewise.
34994 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
34995 than an unsigned HOST_WIDE_INT.
34996 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
34997 (vectorizable_load): Handle polynomial vf.
34998 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
35000 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
35002 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35003 Alan Hayward <alan.hayward@arm.com>
35004 David Sherwood <david.sherwood@arm.com>
35006 * match.pd: Handle bit operations involving three constants
35007 and try to fold one pair.
35009 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35011 * tree-vect-loop-manip.c: Include gimple-fold.h.
35012 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
35013 niters_maybe_zero parameters. Handle other cases besides a step of 1.
35014 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
35015 Add a path that uses a step of VF instead of 1, but disable it
35017 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
35018 and niters_no_overflow parameters. Update calls to
35019 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
35020 Create a new SSA name if the latter choses to use a ste other
35021 than zero, and return it via niters_vector_mult_vf_var.
35022 * tree-vect-loop.c (vect_transform_loop): Update calls to
35023 vect_do_peeling, vect_gen_vector_loop_niters and
35024 slpeel_make_loop_iterate_ntimes.
35025 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
35026 (vect_gen_vector_loop_niters): Update declarations after above changes.
35028 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
35030 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
35031 128-bit round to integer instructions.
35032 (ceil<mode>2): Likewise.
35033 (btrunc<mode>2): Likewise.
35034 (round<mode>2): Likewise.
35036 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
35038 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
35039 unaligned VSX load/store on P8/P9.
35040 (expand_block_clear): Allow the use of unaligned VSX
35041 load/store on P8/P9.
35043 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
35045 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
35047 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
35048 swap associated with both a load and a store.
35050 2018-01-02 Andrew Waterman <andrew@sifive.com>
35052 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
35053 * config/riscv/riscv.md (clear_cache): Use it.
35055 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
35057 * web.c: Remove out-of-date comment.
35059 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35061 * expr.c (fixup_args_size_notes): Check that any existing
35062 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
35063 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
35064 (emit_single_push_insn): ...here.
35066 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35068 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
35069 (const_vector_encoded_nelts): New function.
35070 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
35071 (const_vector_int_elt, const_vector_elt): Declare.
35072 * emit-rtl.c (const_vector_int_elt_1): New function.
35073 (const_vector_elt): Likewise.
35074 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
35075 of CONST_VECTOR_ELT.
35077 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35079 * expr.c: Include rtx-vector-builder.h.
35080 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
35081 directly on the tree encoding.
35082 (const_vector_from_tree): Likewise.
35083 * optabs.c: Include rtx-vector-builder.h.
35084 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
35085 sequence of "u" values.
35086 * vec-perm-indices.c: Include rtx-vector-builder.h.
35087 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
35088 directly on the vec_perm_indices encoding.
35090 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35092 * doc/rtl.texi (const_vector): Describe new encoding scheme.
35093 * Makefile.in (OBJS): Add rtx-vector-builder.o.
35094 * rtx-vector-builder.h: New file.
35095 * rtx-vector-builder.c: Likewise.
35096 * rtl.h (rtx_def::u2): Add a const_vector field.
35097 (CONST_VECTOR_NPATTERNS): New macro.
35098 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
35099 (CONST_VECTOR_DUPLICATE_P): Likewise.
35100 (CONST_VECTOR_STEPPED_P): Likewise.
35101 (CONST_VECTOR_ENCODED_ELT): Likewise.
35102 (const_vec_duplicate_p): Check for a duplicated vector encoding.
35103 (unwrap_const_vec_duplicate): Likewise.
35104 (const_vec_series_p): Check for a non-duplicated vector encoding.
35105 Say that the function only returns true for integer vectors.
35106 * emit-rtl.c: Include rtx-vector-builder.h.
35107 (gen_const_vec_duplicate_1): Delete.
35108 (gen_const_vector): Call gen_const_vec_duplicate instead of
35109 gen_const_vec_duplicate_1.
35110 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
35111 (gen_const_vec_duplicate): Use rtx_vector_builder.
35112 (gen_const_vec_series): Likewise.
35113 (gen_rtx_CONST_VECTOR): Likewise.
35114 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
35115 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
35116 Build a new vector rather than modifying a CONST_VECTOR in-place.
35117 (handle_special_swappables): Update call accordingly.
35118 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
35119 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
35120 Build a new vector rather than modifying a CONST_VECTOR in-place.
35121 (handle_special_swappables): Update call accordingly.
35123 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35125 * simplify-rtx.c (simplify_const_binary_operation): Use
35126 CONST_VECTOR_ELT instead of XVECEXP.
35128 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35130 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
35131 the selector elements to be different from the data elements
35132 if the selector is a VECTOR_CST.
35133 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
35134 ssizetype for the selector.
35136 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35138 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
35139 before testing each element individually.
35140 * tree-vect-generic.c (lower_vec_perm): Likewise.
35142 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35144 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
35145 * selftest-run-tests.c (selftest::run_tests): Call it.
35146 * vector-builder.h (vector_builder::operator ==): New function.
35147 (vector_builder::operator !=): Likewise.
35148 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
35149 (vec_perm_indices::all_from_input_p): New function.
35150 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
35151 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
35152 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
35153 instead of reading the VECTOR_CST directly. Detect whether both
35154 vector inputs are the same before constructing the vec_perm_indices,
35155 and update the number of inputs argument accordingly. Use the
35156 utility functions added above. Only construct sel2 if we need to.
35158 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35160 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
35161 the broadcast of the low byte.
35162 (expand_mult_highpart): Use an explicit encoding for the permutes.
35163 * optabs-query.c (can_mult_highpart_p): Likewise.
35164 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
35165 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
35166 (vectorizable_bswap): Likewise.
35167 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
35168 explicit encoding for the power-of-2 permutes.
35169 (vect_permute_store_chain): Likewise.
35170 (vect_grouped_load_supported): Likewise.
35171 (vect_permute_load_chain): Likewise.
35173 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35175 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
35176 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
35177 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
35178 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
35179 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
35180 (vect_gen_perm_mask_any): Likewise.
35182 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35184 * int-vector-builder.h: New file.
35185 * vec-perm-indices.h: Include int-vector-builder.h.
35186 (vec_perm_indices): Redefine as an int_vector_builder.
35187 (auto_vec_perm_indices): Delete.
35188 (vec_perm_builder): Redefine as a stand-alone class.
35189 (vec_perm_indices::vec_perm_indices): New function.
35190 (vec_perm_indices::clamp): Likewise.
35191 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
35192 (vec_perm_indices::new_vector): New function.
35193 (vec_perm_indices::new_expanded_vector): Update for new
35194 vec_perm_indices class.
35195 (vec_perm_indices::rotate_inputs): New function.
35196 (vec_perm_indices::all_in_range_p): Operate directly on the
35197 encoded form, without computing elided elements.
35198 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
35199 encoding. Update for new vec_perm_indices class.
35200 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
35201 the given vec_perm_builder.
35202 (expand_vec_perm_var): Update vec_perm_builder constructor.
35203 (expand_mult_highpart): Use vec_perm_builder instead of
35204 auto_vec_perm_indices.
35205 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
35206 vec_perm_indices instead of auto_vec_perm_indices. Use a single
35207 or double series encoding as appropriate.
35208 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
35209 vec_perm_indices instead of auto_vec_perm_indices.
35210 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
35211 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
35212 (vect_permute_store_chain): Likewise.
35213 (vect_grouped_load_supported): Likewise.
35214 (vect_permute_load_chain): Likewise.
35215 (vect_shift_permute_load_chain): Likewise.
35216 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
35217 (vect_transform_slp_perm_load): Likewise.
35218 (vect_schedule_slp_instance): Likewise.
35219 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
35220 (vectorizable_mask_load_store): Likewise.
35221 (vectorizable_bswap): Likewise.
35222 (vectorizable_store): Likewise.
35223 (vectorizable_load): Likewise.
35224 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
35225 vec_perm_indices instead of auto_vec_perm_indices. Use
35226 tree_to_vec_perm_builder to read the vector from a tree.
35227 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
35228 vec_perm_builder instead of a vec_perm_indices.
35229 (have_whole_vector_shift): Use vec_perm_builder and
35230 vec_perm_indices instead of auto_vec_perm_indices. Leave the
35231 truncation to calc_vec_perm_mask_for_shift.
35232 (vect_create_epilog_for_reduction): Likewise.
35233 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
35234 from auto_vec_perm_indices to vec_perm_indices.
35235 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
35236 instead of changing individual elements.
35237 (aarch64_vectorize_vec_perm_const): Use new_vector to install
35238 the vector in d.perm.
35239 * config/arm/arm.c (expand_vec_perm_d::perm): Change
35240 from auto_vec_perm_indices to vec_perm_indices.
35241 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
35242 instead of changing individual elements.
35243 (arm_vectorize_vec_perm_const): Use new_vector to install
35244 the vector in d.perm.
35245 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
35246 Update vec_perm_builder constructor.
35247 (rs6000_expand_interleave): Likewise.
35248 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
35249 (rs6000_expand_interleave): Likewise.
35251 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35253 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
35254 to qimode could truncate the indices.
35255 * optabs.c (expand_vec_perm_var): Likewise.
35257 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35259 * Makefile.in (OBJS): Add vec-perm-indices.o.
35260 * vec-perm-indices.h: New file.
35261 * vec-perm-indices.c: Likewise.
35262 * target.h (vec_perm_indices): Replace with a forward class
35264 (auto_vec_perm_indices): Move to vec-perm-indices.h.
35265 * optabs.h: Include vec-perm-indices.h.
35266 (expand_vec_perm): Delete.
35267 (selector_fits_mode_p, expand_vec_perm_var): Declare.
35268 (expand_vec_perm_const): Declare.
35269 * target.def (vec_perm_const_ok): Replace with...
35270 (vec_perm_const): ...this new hook.
35271 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
35272 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
35273 * doc/tm.texi: Regenerate.
35274 * optabs.def (vec_perm_const): Delete.
35275 * doc/md.texi (vec_perm_const): Likewise.
35276 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
35277 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
35278 expand_vec_perm for constant permutation vectors. Assert that
35279 the mode of variable permutation vectors is the integer equivalent
35280 of the mode that is being permuted.
35281 * optabs-query.h (selector_fits_mode_p): Declare.
35282 * optabs-query.c: Include vec-perm-indices.h.
35283 (selector_fits_mode_p): New function.
35284 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
35285 is defined, instead of checking whether the vec_perm_const_optab
35286 exists. Use targetm.vectorize.vec_perm_const instead of
35287 targetm.vectorize.vec_perm_const_ok. Check whether the indices
35288 fit in the vector mode before using a variable permute.
35289 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
35290 vec_perm_indices instead of an rtx.
35291 (expand_vec_perm): Replace with...
35292 (expand_vec_perm_const): ...this new function. Take the selector
35293 as a vec_perm_indices rather than an rtx. Also take the mode of
35294 the selector. Update call to shift_amt_for_vec_perm_mask.
35295 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
35296 Use vec_perm_indices::new_expanded_vector to expand the original
35297 selector into bytes. Check whether the indices fit in the vector
35298 mode before using a variable permute.
35299 (expand_vec_perm_var): Make global.
35300 (expand_mult_highpart): Use expand_vec_perm_const.
35301 * fold-const.c: Includes vec-perm-indices.h.
35302 * tree-ssa-forwprop.c: Likewise.
35303 * tree-vect-data-refs.c: Likewise.
35304 * tree-vect-generic.c: Likewise.
35305 * tree-vect-loop.c: Likewise.
35306 * tree-vect-slp.c: Likewise.
35307 * tree-vect-stmts.c: Likewise.
35308 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
35310 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
35311 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
35312 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
35313 (aarch64_vectorize_vec_perm_const): ...this new function.
35314 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
35315 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35316 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
35317 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
35318 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
35319 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35320 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
35322 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
35323 check for NEON modes.
35324 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
35325 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
35326 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
35327 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
35329 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
35330 the old VEC_PERM_CONST conditions.
35331 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
35332 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
35333 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
35334 (ia64_vectorize_vec_perm_const_ok): Merge into...
35335 (ia64_vectorize_vec_perm_const): ...this new function.
35336 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
35337 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
35338 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
35339 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
35340 * config/mips/mips.c (mips_expand_vec_perm_const)
35341 (mips_vectorize_vec_perm_const_ok): Merge into...
35342 (mips_vectorize_vec_perm_const): ...this new function.
35343 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
35344 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
35345 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
35346 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
35347 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
35348 (rs6000_expand_vec_perm_const): Delete.
35349 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
35351 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35352 (altivec_expand_vec_perm_const_le): Take each operand individually.
35353 Operate on constant selectors rather than rtxes.
35354 (altivec_expand_vec_perm_const): Likewise. Update call to
35355 altivec_expand_vec_perm_const_le.
35356 (rs6000_expand_vec_perm_const): Delete.
35357 (rs6000_vectorize_vec_perm_const_ok): Delete.
35358 (rs6000_vectorize_vec_perm_const): New function.
35359 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
35360 an element count and rtx array.
35361 (rs6000_expand_extract_even): Update call accordingly.
35362 (rs6000_expand_interleave): Likewise.
35363 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
35364 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
35365 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
35366 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
35367 (rs6000_expand_vec_perm_const): Delete.
35368 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
35369 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35370 (altivec_expand_vec_perm_const_le): Take each operand individually.
35371 Operate on constant selectors rather than rtxes.
35372 (altivec_expand_vec_perm_const): Likewise. Update call to
35373 altivec_expand_vec_perm_const_le.
35374 (rs6000_expand_vec_perm_const): Delete.
35375 (rs6000_vectorize_vec_perm_const_ok): Delete.
35376 (rs6000_vectorize_vec_perm_const): New function. Remove stray
35377 reference to the SPE evmerge intructions.
35378 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
35379 an element count and rtx array.
35380 (rs6000_expand_extract_even): Update call accordingly.
35381 (rs6000_expand_interleave): Likewise.
35382 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
35383 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
35385 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35387 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35389 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
35390 vector mode and that that mode matches the mode of the data
35392 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
35393 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
35394 directly using expand_vec_perm_1 when forcing selectors into
35396 (expand_vec_perm_var): New function, split out from expand_vec_perm.
35398 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35400 * optabs-query.h (can_vec_perm_p): Delete.
35401 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
35402 * optabs-query.c (can_vec_perm_p): Split into...
35403 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
35404 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
35405 particular selector is valid.
35406 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
35407 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
35408 (vect_grouped_load_supported): Likewise.
35409 (vect_shift_permute_load_chain): Likewise.
35410 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
35411 (vect_transform_slp_perm_load): Likewise.
35412 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
35413 (vectorizable_bswap): Likewise.
35414 (vect_gen_perm_mask_checked): Likewise.
35415 * fold-const.c (fold_ternary_loc): Likewise. Don't take
35416 implementations of variable permutation vectors into account
35417 when deciding which selector to use.
35418 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
35419 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
35420 with a false third argument.
35421 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
35422 to test whether the constant selector is valid and can_vec_perm_var_p
35423 to test whether a variable selector is valid.
35425 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35427 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
35428 * optabs-query.c (can_vec_perm_p): Likewise.
35429 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
35430 instead of vec_perm_indices.
35431 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
35432 (vect_gen_perm_mask_checked): Likewise,
35433 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
35434 (vect_gen_perm_mask_checked): Likewise,
35436 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35438 * optabs-query.h (qimode_for_vec_perm): Declare.
35439 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
35440 (qimode_for_vec_perm): ...this new function.
35441 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
35443 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
35445 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
35446 does not have a conditional at the top.
35448 2018-01-02 Richard Biener <rguenther@suse.de>
35450 * ipa-inline.c (big_speedup_p): Fix expression.
35452 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
35455 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
35458 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
35462 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
35463 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
35464 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
35465 cond_taken_branch_cost 3->4.
35467 2018-01-01 Jakub Jelinek <jakub@redhat.com>
35469 PR tree-optimization/83581
35470 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
35471 TODO_cleanup_cfg if any changes have been made.
35473 PR middle-end/83608
35474 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
35475 convert_modes if target mode has the right side, but different mode
35478 PR middle-end/83609
35479 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
35480 last argument when extracting from CONCAT. If either from_real or
35481 from_imag is NULL, use expansion through memory. If result is not
35482 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
35483 the parts directly to inner mode, if even that fails, use expansion
35486 PR middle-end/83623
35487 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
35488 check for bswap in mode rather than HImode and use that in expand_unop
35491 Copyright (C) 2018 Free Software Foundation, Inc.
35493 Copying and distribution of this file, with or without modification,
35494 are permitted in any medium without royalty provided the copyright
35495 notice and this notice are preserved.